Calling the script function SetOrientation(GetOrientation()) (or SetTransform(m) with CHANGED m[2]) inside OnUpdate()/EOnSimulate() results in an additional tick of the physical simulation, even if the orientation of the object is not changed.
This manifests itself as accelerated motion of the machine, with GetVelocity() or GetSpeedometer() showing the speed corresponding to what it would have been without calling the orientation function. It is also confirmed by natural distance speed measurement.
Description
Description
Details
Details
- Severity
- Minor
- Resolution
- Open
- Reproducibility
- Always
- Operating System
- Windows 10 x64
- Operating System Version
- 22H2
- Category
- Engine
Steps To Reproduce
#ifdef SERVER
modded class CarScript
{
override void OnUpdate( float dt ) { super.OnUpdate(dt); this.SetOrientation(this.GetOrientation()); }
}
//Or
modded class CarScript
{
override void EOnSimulate(IEntity other, float dt)
{
super.EOnSimulate(other,dt);
vector m[4] this.GetTransform(m); m[2] = this.GetDirection() this.SetTransform(m); }
}
#endif
Additional Information
I also found a possibly similar report, but not described correctly or in enough detail.
https://feedback.bistudio.com/T172796
Event Timeline
Comment Actions
I admit that I should have added the [DayZ Modding] tag. But now I can't find a way to add it.