Stop switching awareness states so fast
This commit is contained in:
@@ -715,7 +715,6 @@ var AISprite = function(game, x, y, key, frame) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
setAwarenessState(this, state);
|
|
||||||
if ( this.awareness_change_enabled == false &&
|
if ( this.awareness_change_enabled == false &&
|
||||||
state != STATE_ALERTED ) {
|
state != STATE_ALERTED ) {
|
||||||
return;
|
return;
|
||||||
@@ -729,6 +728,8 @@ var AISprite = function(game, x, y, key, frame) {
|
|||||||
this);
|
this);
|
||||||
this.awareness_timer.start()
|
this.awareness_timer.start()
|
||||||
|
|
||||||
|
setAwarenessState(this, state);
|
||||||
|
|
||||||
if ( this.awareness_effect !== null ) {
|
if ( this.awareness_effect !== null ) {
|
||||||
this.awareness_effect.alive = false;
|
this.awareness_effect.alive = false;
|
||||||
this.awareness_effect.destroy();
|
this.awareness_effect.destroy();
|
||||||
|
|||||||
Reference in New Issue
Block a user