Im working on a multiplayer project. its a army strategy game. hopefully 10+ online players(or as many as possible).
so far i have a seperate block based level editor so users can prebuild there own levels and castles for use before they start games. its finally working well.
its a 3d game but its a birds eye view so all the real data about positions can be transfered to players in two dimensions. So the editor is making good use of simple strings of block locations to save to txt files and send levels to other players with rpc for rebuild.
now the level system is good and im starting on player interaction.
so i am dealing with a hope of 10 players with multiple cararacters and possibly
10’s of thousands of blocks, so obviosly im going to need the machines to hold a lot of info to search.
I guess im asking for any ideas or advise on the most efficient way to do that!
right now i am considering large strings with parce and split functions.
(its block based movement so if a level was 100 by 100,all the locations could be numbered to 1 to 1000)
in string format i could just add one location number followed by maybe a number to represent how may tall the blocks are on the location. the device would just need to call “contains” and “split” and “parce” on the very big string. the two numbers would be smaller RPC call than several Vector3’s with numbers after the decimal points that are worthless to may game right?
unitys standard alternative would be pushing objects into a array and checking Vector3 locations in a “for” loop or raycasing up to get a count or maybe gameobject.find in a loop of 1000’s of blocks? I fear this standard sort of thing would slow my game before i get to my size goal.
anyways i havent been at this game development thing for too long. i hope there are some experts here that could hopefully give any alternative advise for speed and proficiency when processing super big amounts of data or bandwidth with a block based game before i spend my nights scripting at a proccess!