#Feedback on cache system concept

1 messages · Page 1 of 1 (latest)

civic trellis
#

I drew up this cache system concept since I noticed the amount of data being recieved by the client was rather high, like jumping up from 1.5kb/s to 11kb/s from an explosion smg at 40 shots/second. Granted, the explosions I made do require a lot of data and while I have prototyped a data compression and decompression algorithm (eg; converting booleans to 1s and 0s), and made a bulk vfx handler, 9.5 extra kb/s for one guy doing a slightly intensive action is a lot.

Now I could just give the client all the data for all the predefined explosions when they join and be done with it, but the problem is that this game is planned to have to be very dynamic and algorithmic; I'm talking the game constantly generating new VFX, like shooting a rocket and it explodes even larger with a new, different color. So if repeat occurrences of an effect happen, it needs to be able to just store it.

The problem is that I'm rather new to this and I can't find any resources online for this specific purpose. So I'm just trying to collect any feedback from more experienced developers, because I ain't wanna program allat only for it to be terrible at its job.

quick moat
#

Read about object pooling

fathom onyxBOT
#

studio** You are now Level 4! **studio

unreal shoal
#

From my understanding sounds like you are sending vfx stuff from server to client.

Thats poor game design and should be changed

Client should generate the vfx based on specific info from server. For example, type, position, size

The actual generation of the vfx should be done on client as any vfx is not important to be accurately replicated to each client.

Again from my understanding thats what you are doing and if not, ignore what i said lol

civic trellis
#

for example, explosions - just a metatable that when packed, compresses itself down into a table of more optimized datatypes, then when recieved on the client in the bulk fx script, is unpacked, converted back into a metatable, and exploded

#

the server just tells the client the information to make an explosion object

#

but yes if the explosion were handled on the server that would indeed be very bad