Tayk
(Tayk)
April 18, 2018, 12:53pm
1
Hey,
i’m using fast (Speed = 10000) Projectiles with a Lifetime of 0,1 sec.
Shown here: - YouTube
As you can see the lifetime sometimes doesnt get replicated correctly and the projectiles travel a greater distance than intended (2 hits = dead).
What can cause this?
Cheers
if it’s a C++ project, we need to see some code
Tayk
(Tayk)
April 18, 2018, 6:47pm
3
Yeah it’s a cpp project
I’ve tested a bit and the problem is that the fluctuations in the lifespan are way too high
thats ~50 units difference
without lag etc…
just create a new template project
set the MaxSpeed and InitialSpeed of the projectile to 10000 and InitialLifeSpan to 0,1
When i get back home i can post some code if you need it.
my projectiles should only travel a limited range and currently this seems like the best setup, but for a responsive game this is too much
i could do a HitResult check and see if the distance is bigger than my range, but i’m not sure how much impact this has on performance
is there an other way for achieving this?
thanks in advance
it is probably because of the multiplayer latency. if you for example delete the projectile on server, it still exists on client until the signal arrives.