Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: on Wed 16/03/2005 19:15:47

Title: Need help with disabling interaction...
Post by: on Wed 16/03/2005 19:15:47
in my game,  My character talks to an NPC and says somthing like I'm going to axe you,  my character changes his view to an axing animation,  runs a loop and then the npc changes his view to his dying animation.  this all works fine,  my problem is that you can still look and talk to the NPC after he has died.  I dont want to delete him after he dies,  is there some way I can disable interacting with him?
Title: Re: Need help with disabling interaction...
Post by: Ishmael on Wed 16/03/2005 19:26:50
Just use some variables.

at the beginning of the room script:

int axed;

and in the interaction:

if (axed == 0) {
  // axing stuff goes here
  axed = 1;
} else {
  // after death axing stuff goes here
}
Title: Re: Need help with disabling interaction...
Post by: on Thu 17/03/2005 15:52:47
oh right.... oops.  I feel stupid now.  thanks for you're help!