2024-04-20_01-13-38.online-video-cutter.com.mp4
- deltaTime game loop with the possibility to cap to a specific framerate;
- multiplayer based on a server/client model and UDP reliable packets;
- server->client disconnection;
- non-blocking wait for client connections;
- improve UI elements;
- refactor;
TODO
Related issue: lsalzman/enet#80 (Useful for installation)
The project is developed on Visual Studio 2022 (MSVC v14.39.33519), with the following dependencies:
You can use the Microsoft Build Engine, from within the Visual Studio Command Prompt:
msbuild MultiplayerGame_VisualStudio/MultiplayerGame.sln
Or just open the solution and build the project.
The build will generate an executable file named MultiplayerGame.exe
in MultiplayerGame_VisualStudio/x64/Debug
or MultiplayerGame_VisualStudio/x64/Release
directories.
NB: to run the program you need SDL2.dll and SDL2_image.dll.
- You must first install sdl2 and enet development libraries:
sudo apt update
sudo apt install libsdl2-dev libsdl2-image-dev libenet-dev
- Then you can just compile using the makefile:
make
This will generate an executable file named multiplayer_game
.
Huge thanks to Parallel Realities and their fenomenal SDL2 tutorials. Go check them out on their website and on Itch.io, the code bundles are extremely cheap and they are insanely well made.