Network : Tracking large amount of objects

Community Forums/General Help/Network : Tracking large amount of objects

RifRaf(Posted 2015) [#1]
Ok, so i've recently become interested in guantlet style game coding. Im now struggling with many issues one if the best way to track soo many objects over a network for multi player in such a game.

Now im not completely new to network management in a game, I made TinyTanks Online that while unpopular and gathering dust has a very well written Network code that has no visible lag or issues even over poor connections.

But im still scratching my head on tracking 100s of game objects over a network.

Some obvious things are , update only active objects. If it doesnt see a player and isnt doing anything no need to update it in real time.. But there are still soooooo many potential active bad guys.

Is anyone familiar with the proven methods used in games like Guantlet and HammerWatch ?


*(Posted 2015) [#2]
Personally I would use a random system like Shagwanas in the code archive and get each player to spawn em local via a set level spawn seed. This should be the same for each player then just have the network track the killed ones so they get removed on everyones computers :)


Matty(Posted 2015) [#3]
There used to be an article on gamasutra many years ago about this exact question it referred to age of empires an example. Basically it's about running the same simulation on each machine and the server only handling msgs about user input. All the clients do the tracking. To stop cheating you can also run it on the server and do some kind of checksum at each frame.


RifRaf(Posted 2015) [#4]
Interesting.

I'll have tho think on this for some time. Initially my mind wanders to a hybrid of what you have there.. Letting clients run their own mechanics at the same logical rate as everyone else.. Server sending individual grouping data a few objects at a time to sync them if needed.

Testing and research required i suppose.. I tried searching various net resources such as Gamasutra but my search terms are too generic to find any articles about this exact question.


Matty(Posted 2015) [#5]
http://www.gamasutra.com/view/feature/131503/1500_archers_on_a_288_network_.php

First search result typing in "gamasutra age of empires multiplayer article"

Should be helpful....


Matty(Posted 2015) [#6]
Oh....depending on what you are making there is another issue that you may come up against which I don't the article addresses. ....



Floating point imprecision.


Different cpus etc will potentially cause the simulation to diverge if floating point calculations are used.


RifRaf(Posted 2015) [#7]
Ive been in contact with the devs for HammerWatch and what they do is send the destination point for objects and let each client track the path.. if the destination changes that is then updated over the network.


-=Darkheart=-(Posted 2015) [#8]
It's a good article but is it still relevant now? it's 14 years old... 28.8k modems are long past and the need to be quite so tight is probably past too.


Matty(Posted 2015) [#9]
Definitely still relevant - the technique is still very valid and useful.

Although if modern hardware can handle 1000s of networked objects all updated at once then that's all good - but using a technique like this with modern hardware you could perhaps do even more....maybe 1000,000s?

A technique like this scales really well.


*(Posted 2015) [#10]
@RifRaf: thats a good idea and one I didnt think of, will keep that one in me noggin as it will be very handy in the future :)