forked from noxious/server
Fixed left-overs from #293
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
import ZoneCharacter from './zoneCharacter'
|
||||
|
||||
import { UUID } from '#application/types'
|
||||
import { Character } from '#entities/character'
|
||||
import { Zone } from '#entities/zone'
|
||||
import zoneEventTileRepository from '#repositories/zoneEventTileRepository'
|
||||
@ -21,7 +22,7 @@ class LoadedZone {
|
||||
this.characters.push(zoneCharacter)
|
||||
}
|
||||
|
||||
public async removeCharacter(id: number) {
|
||||
public async removeCharacter(id: UUID) {
|
||||
const zoneCharacter = this.getCharacterById(id)
|
||||
if (zoneCharacter) {
|
||||
await zoneCharacter.savePosition()
|
||||
@ -29,7 +30,7 @@ class LoadedZone {
|
||||
}
|
||||
}
|
||||
|
||||
public getCharacterById(id: number): ZoneCharacter | undefined {
|
||||
public getCharacterById(id: UUID): ZoneCharacter | undefined {
|
||||
return this.characters.find((c) => c.character.id === id)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user