Log when a character joins a zone

This commit is contained in:
Dennis Postma 2024-09-28 02:18:06 +02:00
parent cc9eada654
commit 10a231b54c

View File

@ -43,6 +43,9 @@ export default class CharacterJoinEvent {
// let other clients know of new character
this.io.to(zone.id.toString()).emit('zone:character:join', character)
// Log
gameLogger.info(`User ${character.id} joined zone ${zone.id}`)
// send over zone and characters to socket
callback({ zone, characters: CharacterManager.getCharactersInZone(zone) })
} catch (error: any) {