Streaming large object count

Hello again, I'm working on our fire system for our game and I have a question about how much resources something would use and if there is another way to handle it.

Currently, we have a fire system in place where fire spreads throughout a building. In the new system I built for it, there are a few issues with the growth over the network. The fire grows at different rates and spreads a little differently for each player over the network, I believe because there is nothing really syncing them other than the events taking place, such as a door opening to fuel a fire.

That being said, would it be resource heavy to stream the temperature change of the fires (float) and current temperature of the fires (float)? In the current scene there are about 150 of these objects, and in later builds there could be a lot more. I am concerned that would be a lot of information to stream, but can't really think of any effective ways to make sure they are all synced, as the fires need to be the same on every machine otherwise some people see fires where others do not. Granted not all of the objects have to stream, just the active ones.

What are your thoughts on this and as usual, I greatly appreciate your time and input :)


  • I would avoid syncing a lot of objects and using a PhotonView each. This will ruin bandwidth and can bring down performance, too.
    In best case, you would sync that an object starts burning and each client can just simulate the fire on that object independently. You might want to use a single timestamp to tell others when the objects began to burn, so they can catch up any time that the package traveled.
    You should track which fires you already synced and only send new ones. In best case, you'd identify each with an int ID. You could use a PhotonView's ID if you wanted to if you don't observe anything with the PhotonView.

    Can new players join a running game or is everyone there from the beginning?
  • Everyone joins at the beginning. So I suppose I could set it up so that if a fire is started an RPC runs that sets the growth/temperature change for that fire for all players, instead of letting that number changed based on others around it before. Let it based on fires around them, but if it ignites set it to the same for all players.

    That way they grow at the same rate, need to make that frame rate independent as well.

    The big problem before was that the temperature change would be different for different players, which caused lots of issues, so if I can set their temperature to be the same and the change to be the same it should help if not resolve the issue.

    I'll try that out, thank you :)

    Also, should I be concerned about this error I'm getting on one player?
    "Received unknown status code: QueueIncomingReliableWarning"
  • I'm glad you are trying the other variant. Let us know if it works out!

    The warning is not too serious but still worth noting. You get a lot of reliable messages in a very short time. This can be a spike (which is ok) or it can be a permanent issue. If it happens permanently, you get more messages than you execute and dispatch and this will sooner or later fill your memory and stall your game or connection.

    You are on a good track to reduce number of messages though, so it should go away with the changes.