Expand description
Helpful types and macros when writing simulation logic
Re-exports§
pub use crate::SimulationInitOptions;pub use crate::diff_ser::DiffSerializer;pub use crate::multiplayer_tradeoff;pub use crate::multiplayer_tradeoff;pub use crate::networked_types::primitive::usize32;pub use crate::simulation_controller::GameContext;pub use crate::tick::TickID;pub use crate::tick::TickInfo;pub use crate::multiplayer_tradeoff::*;
Macros§
- debug
- Logs a message at the debug level.
- error
- Logs a message at the error level.
- info
- Logs a message at the info level.
- multiplayer_
tradeoff - Although all game logic code is meant to be interpreted as server authoritative and from the server’s top-down perspective controlling everything, you as the game developer can choose how each of your game mechanics feel, on a spectrum between “responsive+potentially incorrect” to “laggy+definitely correct”. Game state is always eventually consistent, but this macro lets you decide when and where to execute logic in order to fine-tune game feel. This is possible because the engine executes each simulation tick multiple times across the server and all connected clients, requiring game logic to be deterministic depending on the chosen trade-off.
- warn
- Logs a message at the warn level.