use negative mob entity ids to avoid conflicts

This commit is contained in:
p2r3
2025-08-29 23:58:47 +03:00
parent ce903d088f
commit 6886dd59ce
2 changed files with 12 additions and 12 deletions

View File

@@ -118,7 +118,7 @@ void handlePacket (int client_fd, int length, int packet_id, int state) {
if (mob_data[i].type == 0) continue;
if ((mob_data[i].data & 31) == 0) continue;
sc_spawnEntity(
client_fd, 65536 + i, recv_buffer,
client_fd, -2 - i, recv_buffer,
mob_data[i].type, mob_data[i].x, mob_data[i].y, mob_data[i].z,
0, 0
);