X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibr2c2%2Fblockallocator.h;h=b401233593793a52743ef9bfb0967e4f27005197;hb=HEAD;hp=cd6dfd5949d58aa49ec346079fcf8624241f1fd0;hpb=6eba064c477836843a2647d777e95823a96dda43;p=r2c2.git diff --git a/source/libr2c2/blockallocator.h b/source/libr2c2/blockallocator.h index cd6dfd5..b401233 100644 --- a/source/libr2c2/blockallocator.h +++ b/source/libr2c2/blockallocator.h @@ -44,6 +44,7 @@ private: const Block *stop_at_block; bool reserving; bool advancing; + bool reserve_pending; public: BlockAllocator(Train &); @@ -65,6 +66,8 @@ public: bool has_block(const Block &) const; bool is_block_current(const Block &) const; + void tick(); + private: void reserve_more(); bool reserve_block(const BlockIter &); @@ -83,6 +86,7 @@ private: void block_reserved(Block &, const Train *); void sensor_state_changed(Sensor &, Sensor::State); void update_next_sensor(Sensor *); + void halt_event(bool); public: void save(std::list &) const;