How we reduced bandwidth usage by 60x in Astro Force (Roblox RTS)

I just ran a personal test utilizing your V3 and noticed how terribly unoptimized Color3 values are.

The commented out code is referenced as “script incoming/outgoing” in the image below, while “script2 incoming/outgoing” is the code in the picture above that I’m running.

Although it may seem a bit impractical to be sending color3 values at 60 frames per second. This article and personal tests have made be realized how inefficient color3 values are in memory. For instance, the range of colors that can be displayed is an unsigned 8 bit integer value (2^8) ranging from 0-255. However, Roblox allows you to put in 64 bit integers into ALL 3 parameters in the color3 object. This means there’s about 192 bits being sent from server to client for NO reason, when it’s only necessary to be sending 24 bits.

2 Likes