#Predictive Spawning Triggered multiple times

1 messages · Page 1 of 1 (latest)

steep parrot
#

According to the documentation and in the samples, to prevent multiple spawn when spawn prediction is used before spawning the following should be checked:

SystemAPI.GetSingleton<NetworkTime>().IsFirstTimeFullyPredictingTick

But even while checking, if it is the first fully predicted tick, I spawn multiple entities.

The spawning logic happens in the PredictedSimulationSystemGroup.

Is there anything else needed to prevent the client to spawn multiple entities for only one spawn event?

The server works as expected and only spawns one entity.

steep parrot
#

After further investigation it seems that it works as expected, if the IsFirstTimeFullyPredictingTick is checked at the same place as the input and in the same job a bullet entity is spawned.

valid cedar
#

As you just said, if you want the predited spawning to happen once, You should use the IsFirstTimeFullyPredictingTick

#

we show that in our new HellNetcodeSample as well