diff --git a/src/declarations/prototypes.d.ts b/src/declarations/prototypes.d.ts index b9dc5da62..6bd693224 100644 --- a/src/declarations/prototypes.d.ts +++ b/src/declarations/prototypes.d.ts @@ -7,7 +7,7 @@ interface Creep { inRampart: boolean; approxMoveSpeed: number; bodypartCounts: { [bodypart in BodyPartConstant]: number }; - isHuman: true; + isPlayer: true; } interface PowerCreep { diff --git a/src/prototypes/Room.ts b/src/prototypes/Room.ts index 8c4342a40..9523cc688 100644 --- a/src/prototypes/Room.ts +++ b/src/prototypes/Room.ts @@ -114,7 +114,7 @@ Object.defineProperty(Room.prototype, 'sourceKeepers', { Object.defineProperty(Room.prototype, 'playerHostiles', { get() { if (!this._playerHostiles) { - this._playerHostiles = _.filter(this.hostiles, (creep: Creep) => creep.isHuman); + this._playerHostiles = _.filter(this.hostiles, (creep: Creep) => creep.isPlayer); } return this._playerHostiles; },