fix(world): resolve traffic freeze, player vehicle kick, mob npcs, void falls, subway fast-travel, and timeline playback

This commit is contained in:
CAtlas0784 committed 2026-09-18 16:11:34 +07:00
1 parent 67bdbae24b
commit 8470c3d413
9 files changed
+233 -123

No files matched your search

@@ -25,9 +25,12 @@ internal sealed class TrafficAndCrowdDriver : ITrafficVehicleDriver, IUrbanCrowd
await GameRouter.DestroyDirectAsync(session, entityId, "traffic-despawn");
}
private readonly System.Collections.Concurrent.ConcurrentDictionary<ulong, int> _moveTokens = new();
public async Task SendVehicleMoveAsync(
TcpSession session, ulong entityId, float x, float y, float z, float yaw, float vx, float vz)
{
var token = _moveTokens.AddOrUpdate(entityId, 1, (_, cur) => unchecked(cur + 1));
var moveData = new SceneMethods.RaidVehicleSyncData
{
Id = entityId,
@@ -35,8 +38,8 @@ internal sealed class TrafficAndCrowdDriver : ITrafficVehicleDriver, IUrbanCrowd
FacingDirection = yaw,
EulerAngles = new SceneMethods.UxVector3(0f, yaw, 0f),
Velocity = new SceneMethods.UxVector3(vx, 0f, vz),
Bits = [],
MoveToken = 0,
Bits = [1, 0, 0, 0],
MoveToken = token,
};
await session.NotifyAsync(MethodId.SyncVehicleMove, UxSerializer.Serialize(moveData), CancellationToken.None);
GameRouter.TrackVehicleMove(entityId, x, y, z, yaw);