diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-05 23:43:14 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2024-04-06 15:22:01 +0200 |
commit | 58a1faa9ccbf72eb37d3c5f5daf885a23fe98c88 (patch) | |
tree | ba2efaf0c5b2651874f39763de7e04a187030fb7 | |
parent | e532875c8e6d8fcad81c231a950adf93f8f114b6 (diff) |
a
-rw-r--r-- | src/critter.hpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/critter.hpp b/src/critter.hpp index 322d9bc7..30b81d33 100644 --- a/src/critter.hpp +++ b/src/critter.hpp @@ -29,7 +29,12 @@ struct critter final : object object_type type() const noexcept override; explicit operator critter_proto() const; - void update(size_t i, const Ns& dt) override; + void update(size_t i, const Ns& dt) override; // todo! return true when the position changed + // todo! + // add a field: last_update_frame. if doesn't equal to the current world's update + // frame, update() gets called and last_update_frame is set to current frame. + // when update() returns true, the *currently* iterated chunk gets rescanned from + // the beginning in editor's update world void update_movement(size_t& i, const Ns& dt, rotation r); void update_nonplayable(size_t& i, const Ns& dt); void set_keys(bool L, bool R, bool U, bool D); |