rust/hwphysics/src/time.rs
changeset 15767 a818a87fec52
parent 15282 478d5372eb4a
child 15768 704f00889f3a
--- a/rust/hwphysics/src/time.rs	Mon Nov 16 01:41:42 2020 +0300
+++ b/rust/hwphysics/src/time.rs	Tue Nov 17 01:04:15 2020 +0300
@@ -68,7 +68,7 @@
 
     pub fn register(&mut self, gear_id: GearId, timeout: Millis) -> EventId {
         let event_id = self.current_event_id;
-        self.current_event_id.wrapping_add(1);
+        self.current_event_id = self.current_event_id.wrapping_add(1);
         let event = TimeEvent {
             time: self.current_time + timeout,
             gear_id,