jakobhellermann / bevy-inspector-egui

Inspector plugin for the bevy game engine
Apache License 2.0
1.1k stars 164 forks source link

Running code when a resource is modified #178

Open ThePuzzledDev opened 5 months ago

ThePuzzledDev commented 5 months ago

Is there a build in way to check if a resource was modified or do I have to manually have prev_value and check against that?

jakobhellermann commented 5 months ago

bevy-inspector-egui should work with regular bevy change detection, so checking Res<Resource>.is_changed() should work cheatbook.