Open w0ss4g3 opened 1 year ago
Video showing the behaviour. https://www.youtube.com/watch?v=N4f8vJfursM
Not found anything unusual in weapon actor state/properties. There present base and velocity after pickup, but if it clean in BecomeItem - issue not resolved. Look like issue related to native side state, not unrealscript state.
Also in bugged drop I see flicker weapon in small view in different places on screen.
And it update position really slow, Once per few frames.
On this sshots showed one same drop.
I think it is render issue based on some internal things,
We're going to start testing a fix for this in 469d. Here's some context on this problem:
Initial state:
- Player is holding a weapon. The weapon's RemoteRole is ROLE_SimulatedProxy. That means the client will simulate any changes in weapon physics on the client side
Player throws weapon:
- Server calls Botpack.TournamentWeapon.DropFrom. This changes the weapon's physics to PHYS_Falling, the RemoteRole to ROLE_DumbProxy, and bSimFall to true.
- While bSimFall is true, the server replicates changes in the Weapon's Physics/Acceleration/bBounce properties to the client
- In this case, the server tells the client the weapon has started falling
- The client then simulates the fall locally
Weapon lands on the floor:
- Server calls Botpack.TournamentWeapon.Pickup.Landed and changes bSimFall to false. This means the server will no longer replicate the weapon's Physics/Acceleration/bBounce properties to the client
- Because of this, the server does not tell the client that the Physics of the weapon are now PHYS_None
- The client has simulated the fall though, so the client knows the Physics are PHYS_None
Player picks up dropped weapon:
- Server calls Engine.Inventory.BecomeItem. The RemoteRole goes back to ROLE_SimulatedProxy. Physics are still PHYS_None
Player throws the weapon again:
- Another call to Botpack.TournamentWeapon.DropFrom. Physics change to PHYS_Falling again on the server, but the server is too stupid to realize that it needs to inform the client
- Why? Because the last time the server thought the Physics property was relevant to the client, the weapon was also falling
Issue still happen on 469d (e preview):
Some weapons drop with lags. Some weapons drop as small size, until not reach ground.
It much less from what be before, but still, not what feel like expected.
The animation when throwing a weapon on the first occurrence is smooth. If you pick up the weapon again and throw it, it will be unsmooth/jagged. This also seems to apply to weapons being dropped when a player dies.
The only appears to apply to dedicated servers - offline remains smooth after many drop/pickups.
Steps to reproduce on multiplayer server:
Think this happens in 436 too.
Thanks