Create a generic entity-component system framework, or find an already existing one.
Setup all of the components and systems we will need, and move all of the current code into the systems.
The components will need a nice way of synchronizing over the network. Maybe this could be on the entity level to work well with spatial partitioning, and only send a subset of the entities to certain clients.
We will also need an event system:
This needs to handle attacking/items/health/stats/entity management/etc.
Basically an entity could send an event to another entity which causes damage or something.
Sending events to specific entities
Entities sending events to the world
Events for creating new entities, destroying entities, etc.
We really need events for creating entities, so we can have spawner entities, which spawn zombies, or bullets, or items, or whatever.
Events synchronizing across the network (mainly just from the server to the clients - the clients shouldn't be able to send these kinds of events to the server, only input packets and stuff)
Refer to the Entity-Component System document on Google Drive.
Create a generic entity-component system framework, or find an already existing one.
Setup all of the components and systems we will need, and move all of the current code into the systems.
The components will need a nice way of synchronizing over the network. Maybe this could be on the entity level to work well with spatial partitioning, and only send a subset of the entities to certain clients.
We will also need an event system: This needs to handle attacking/items/health/stats/entity management/etc. Basically an entity could send an event to another entity which causes damage or something. Sending events to specific entities Entities sending events to the world Events for creating new entities, destroying entities, etc. We really need events for creating entities, so we can have spawner entities, which spawn zombies, or bullets, or items, or whatever. Events synchronizing across the network (mainly just from the server to the clients - the clients shouldn't be able to send these kinds of events to the server, only input packets and stuff)
Refer to the Entity-Component System document on Google Drive.