Topic: Freeze effect and prediction
I post here what I found to make a proper freeze effect in Teeworlds. Maybe it's known, but so far, I've haven't see it in both DDRace en OpenFNG. When the tee is frozen, the server should send new tune params with these parameters:
m_GroundControlAccel = 0.0f;
m_GroundJumpImpulse = 0.0f;
m_AirJumpImpulse = 0.0f;
m_AirControlAccel = 0.0f;
m_HookLength = 0.0f;
m_GroundControlSpeed = 0.0f; //Optional because it will not change anything in practice (thx to heinrich5991)
m_AirControlSpeed = 0.0f; //Optional because it will not change anything in practice (thx to heinrich5991)
That way, the client know that your tee can't move or jump. Of course, you must send back old tune params when the freeze effect is gone. I've implemented it for InfClass and it works well.