guard Builders class against simplayers
This commit is contained in:
@@ -35,6 +35,8 @@ world.beforeEvents.playerLeave.subscribe((event) => {
|
|||||||
});
|
});
|
||||||
world.afterEvents.worldLoad.subscribe((event) => {
|
world.afterEvents.worldLoad.subscribe((event) => {
|
||||||
for (const player of world.getAllPlayers()) {
|
for (const player of world.getAllPlayers()) {
|
||||||
|
if (!player)
|
||||||
|
continue;
|
||||||
Builders.onJoin(player.id);
|
Builders.onJoin(player.id);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Reference in New Issue
Block a user