🚨 Stop region saves with exactly 256 areas from wiping them
The count was clamped to 256 and then stored in a byte, wrapping to zero, so the server replaced the region with an empty area list.
This commit is contained in:
@@ -162,7 +162,7 @@ begin
|
|||||||
inherited Create($03, 0); //Admin Packet
|
inherited Create($03, 0); //Admin Packet
|
||||||
FStream.WriteByte($08); //Admin PacketID
|
FStream.WriteByte($08); //Admin PacketID
|
||||||
FStream.WriteStringNull(ARegionInfo.Name);
|
FStream.WriteStringNull(ARegionInfo.Name);
|
||||||
count := Min(ARegionInfo.Areas.Count, 256);
|
count := Min(ARegionInfo.Areas.Count, 255);
|
||||||
FStream.WriteByte(count);
|
FStream.WriteByte(count);
|
||||||
for i := 0 to count - 1 do
|
for i := 0 to count - 1 do
|
||||||
begin
|
begin
|
||||||
|
|||||||
Reference in New Issue
Block a user