Please Help me fixing my elevator jitter bug
Guys,
please help me fixing my elevator / train jitter bug!
I want to fix this now for more than a year, now that we have a community developing crew and also
we combat guys have access to the engine, I should finally be able to fix this somehow.
A vid about the problem I'll be talking about:
See this jitter of the Elevator? I'll be moving the elevator OnUpdate() with SetOrigin().
Any idea, what I could do to fix this ??
I can't find my old post, someone posted something about a time differ at client / server.
Anybody knows a bit more about this?
please help me fixing my elevator / train jitter bug!
I want to fix this now for more than a year, now that we have a community developing crew and also
we combat guys have access to the engine, I should finally be able to fix this somehow.
A vid about the problem I'll be talking about:
See this jitter of the Elevator? I'll be moving the elevator OnUpdate() with SetOrigin().
Any idea, what I could do to fix this ??
I can't find my old post, someone posted something about a time differ at client / server.
Anybody knows a bit more about this?
Comments
Should be fixed in 267.
Pretty much the first thing I fixed once I got engine access.
So maybe... just maybe those smelting buckets won't suck quite so hard anymore?
However, I hope that being moved by properly lag-compensated entities will work smoothly in 267...
Seriously though, do apply.
https://docs.google.com/spreadsheet/viewform?formkey=dEVyVlRkUDRibHNXQWM2MHFXWXBwVkE6MQ#gid=0
:-)
I think they should just be taken out and replaced with static props.
So you should be able to have smoothly working Elevators/Trains again.
Though unfortunately, NS2 movement lacks momentum - if you are standing on a moving train and jump straight up, you don't move with the train while in the air.
Can be fixed though, just needs to rewrite all the NS2 movement code... *urk*... :-)
You CAN turn on physics for the objects in the cinematic, but because they are not lag-compensated, you will get instant client/server desync if you touch them ... which results in a lot of shuddering and jittering.
Which is why physics was turned off for them.
Actually, for whatever reason, the buckets in smelting are a prop animation, rolled into a cinematic... I guess so that the bucket pouring animations can have the appropriate particles accompanying them?
all you have to do is keeping track of the velocity of the platform you are on and once you leave it, just add the platforms velocity to the player. PlatformMoveMixin.lua ! :P
All games had this issue. The main issue reside in the fact that the elevator is moved by the server and all clients have to synchronize with this information. same for cars and other buckets. The best i saw was in GTA. But it s far from perfect.
1 obvious lag problem
2 side effect of lag would be some programmed behavior like gravity. Example: when the elevator goes down a little fast and lag is too high it creates a situation in which the player character lands constantly on the ground while the feet should never leave the floor.
Apply a constraint never really works for many reasons like:
*It doesn't remove the lag issue
*It forces to write some dedicated Code applied through an entity (most of the time)
*Hit detection has to function when the elevator is moving. At least look real.
I believe OP results are ok for now as it's not supposed to be implemented in the game in the first place (also commander view issues).
Maybe make it a box like a real elevator with doors would allow to isolate and to glue the player on the elevator platform.
But that s a bargain. Smooth animation vs action in game etc..
edit damn mobile phone.