How can I use the script to make an interaction play out differently depending on weather a certain npc is in the room?
Long story short, if the player clicks on a door while the character is in the room they will not allow the player to use the door,
but if the character isn't in the room, the player can use the door. I have everything else worked out, except which script command
to use in order to determine whether the npc is in the room.
It's one of those things that is mystifying until you see it, and then it's obvious:
if(cCharacter.Room == player.Room)
{
// Do stuff
}
(Assuming the NPC in question is called cCharacter)
I tried it, and it worked.
Many thanks for your help!