Skip to content
This repository was archived by the owner on Sep 15, 2024. It is now read-only.

Commit 015f46f

Browse files
protect from malformed packet data
1 parent 55ee74f commit 015f46f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Scripts/Netcode/Common/SPacketPlayerPositions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public override void Read(PacketReader reader)
3737
var x = reader.ReadFloat();
3838
var y = reader.ReadFloat();
3939

40-
PlayerPositions.Add(id, new Vector2(x, y));
40+
PlayerPositions[id] = new Vector2(x, y);
4141
}
4242
}
4343

0 commit comments

Comments
 (0)