-
Notifications
You must be signed in to change notification settings - Fork 14
Multiplayer, AI, Replays, anything else?
Note that this approach features further advantages: Moving the whole game logic to the server allows you to create multiplayer games with a minimum of additional effort. Player input events are sent to the server and processed there, while game logic events are routed to the client and used for updating the UI.
AI systems generate events just like player input would do. This way, the game logic doesn’t care whether input has been actually generated by players or AI – they’re processed in the exact same way.
Scripting support can be added to the game by causing game events through a debug console or cheat window. Finally, storing all events along with timestamps allows you to easily create replay files for re-creating game experiences at a later time. Verbose log files can be created the same way.