Devlog 4: A player!
At long last, I am back with another devlog! Starting college again meant I needed to take a minute to get back into the swing of development, then the whole Unity runtime fee debacle happened and I suddenly didn't feel so good about making games reliant on that company - or any, for that matter. I think for my future projects I'll stick with Godot (FOSS for the win!)
However, time has passed since then, and I have come to terms with the fact that I am too far into this project to change engines, and Godot probably couldn't do this kind of mesh generation anyway. As such, I've been working away. That work has been on a new tool, one which I hope to release eventually, for creating client-side prediction and reconcilaition in Unity in a way that is networking-agnostic and simple to use. I got tired of having to rework different systems to work with Riptide or Fishnet or Netcode for GameObjects, so I made a sort of middle-man API that handles all the prediction and reconcilation for you, you just need to provide it with the methods for sending, recieving, and handling all the input and state data. So, after a few weeks of developing that on-and-off, it was time to put it to the test!
Surprisingly, it was a pretty massive success. It took not even an afternoon for me to have the system implemented in game. I have no doubt that overtime I'll discover some horrific bugs that I'll spend much longer fixing, but as it stands the fact that I can have a client walking around feeling responsive, behaving correctly, without any major issues, is pretty incredible. I remember tearing my hear out trying to make prediction work for my previous project, Broken Home (currently on hiatus), so this is a nice breath of fresh air.
Also, I made some changes to the world generation system. Until now, it has used cubic chunks of 40x40x40 tiles. Using this system I have just not been able to get the performance I wanted. The trouble is, the majority of these chunks has absolutely nothing of interest to generate, being either entirely empty or entirely full with the exception of where the air meets the surface. Primarily I wanted to use cubic chunks to allow for more expandability in future should I want to implement gamemodes with greater verticality. However, the performance cost was just not worth it. Overall, by switching from cubic chunks on a 3D chunkmap to a flat 2D chunkmap with chunks measuring 20x128x20 - plus some other structural changes to the system - I have reduced the time taken to generate the initial worldspawn from 20 seconds to 0.4 seconds. That's a pretty huge improvement.
Up next: syncing the world state.
Files
Get Build Fight Game
Build Fight Game
Status | In development |
Author | peterkcodes |
Genre | Shooter |
More posts
- V0.11.1 ChangelogDec 08, 2023
- V0.11.0 ChangelogDec 05, 2023
- 0.10.1 ChangelogDec 04, 2023
- 0.10.0 ChangelogDec 04, 2023
- Version 0.9.0Nov 29, 2023
- Version 0.8.0Nov 21, 2023
- Version 0.7.0 ChangelogNov 21, 2023
- Devlog #9: New Player & New PlacesNov 06, 2023
- V0.6.0 ChangelogNov 06, 2023
- v0.5.0 Changelog (+ how to play)Nov 01, 2023
Leave a comment
Log in with itch.io to leave a comment.