Scrap Mechanic
WASD Converter
Massiv latency buildup when in multiplayer (Survival)
Hi

i converted this and your Camera Converter mod to Survival. We found out, if you connect the WASD Converter with a seat and sit on it, over a short period of time it builds up a massive amount of latency for the clients in multiplayer, regardless if your driving or not. The latency can go up over 10 seconds in under 5 minutes. When you destroy the converter, the game for the clients catches up and the latency returns to normal. I currently not tested it with the Camera Converter, but i suspect the same problem there. Also the Yaw/Pitch/Roll Outputs of the Camera Converter have no motor functionality with the new upgradeable motors from survival. It only outputs positive signals. The old creative motors work as intended. Would be nice, if you would look into this. You don't have to upload an update to steam right away, but a link to a fixed version would be nice, if you have the time for it.

Love your mods, keep up the good work ;)

PS: tested game version 4.4

Edit: Disconnecting the Converter from the seat is enough to fix the latency
Edit: Only a seat and the converter are enough to start the buildup, no motor required
Отредактировано KitsuSenpai; 28 мая. 2020 г. в 2:22
< >
Сообщения 15 из 5
TechnologicNick  [Разработчик] 28 мая. 2020 г. в 13:09 
Thanks for the report.

I haven't tested it in multiplayer at all since survival mode came out. I noticed vanilla logic gates have the exact same problem you're describing when changing their state repeatedly.

I'll do some more investigating when I have the time for it.
Nice, thx in advance, i really appreciate that. Hope you find something useful.

And yeah we noticed that too, 0 tick logic clocks are pushing the latency really fast.
Hey, I took just a quick look at the code and I have a feeling it might be the fact that you're sending updates through the server on every single update, not just when it's needed; when the state has changed etc. I could be wrong and I don't currently have a way to test it out, but it could be something worth looking into.

For a quick fix I'd just change the last else to elseif and compare the current value to the previous as the previous if statements already do that, or just simply wrap it all up in a check if it's changed at all

EDIT: That's under XYZ_Converter.server_onFixedUpdate()
Отредактировано Faupi 🐾; 4 июн. 2020 г. в 5:14
Thanks for the info, i'll look into that and make some tests. It could reduce the latency a fair bit, but we also noticed latency buildup with the vanilla logic gates. But for a first fix this should do.

EDIT:

I wrapped a change statement around each update, as mentioned by @Faupi, so it only triggers once, if you press/release the button. That will fix most, if not all lag that would build up. But I didn't tested this yet.

I also found out, that the A and D Converter where broken in survival, because the getPoseWeight() function is out of bounds with the new seats. You have to use getSteeringAngle() to get them work in survival. They output integer between -1 and 1 just like getPower() and work with the old seats, too.

The setPower() function doesn't work with the new survival engines anymore. They require isActive() to receive power with setPower(). You could redefine some function, but changing the WASD Converters back to Logic Output only again and adding Steer and Power Converters for Power Outputs would be the easier approach.
Отредактировано KitsuSenpai; 4 июн. 2020 г. в 19:00
TechnologicNick  [Разработчик] 6 июн. 2020 г. в 18:04 
Yeah I haven't looked into this at all since I posted the message. The A and D converters seemed to work fine in creative. I assume the creative seat isn't scripted.
< >
Сообщения 15 из 5
Показывать на странице: 1530 50