Making townsfolk report you to a guard

This commit is contained in:
2014-06-19 20:54:51 -07:00
parent 30d44babe3
commit 23148f4d6d

View File

@@ -1062,7 +1062,7 @@ var AISprite = function(game, x, y, key, frame) {
} }
if ( this.target !== null ) { if ( this.target !== null ) {
var targetseesyou = false; var targetseesyou = false;
if (typeof this.target.canSeeSprite !== undefined) { if (this.target.canSeeSprite) {
if (this.target.canSeeSprite(this) == true) if (this.target.canSeeSprite(this) == true)
targetseesyou = true; targetseesyou = true;
} }