Taking Object before Use

Hello everyone ,
I’m a newbie and going through the tutorial. I created a function that revives Bob and everything works great except that I don’t have to take the defibrillator first.

Any help would be appreciated


Should you have to take it? I'm not sure why that seems necessary.

If you want to make the player take it first, you'd need to add an if statement to the function. I think one of the conditions you can enter in the GUI is "player has object" or similar; so just use that to check if they have the defibrillator before you start. Make sure to add an else clause to tell the player that they can't use this object without picking it up.


command : revive Bob;help bob;save bob;help bob

1a. if player does not hold object "defibrillator"
1b. script"You need to get a defibrillator first, in order to revive Bob"

2a. if object "defibrillator" is visible
2b. script: "You need to pick up the "defibrillator"... Quick...Bob needs your help!"

3a. if player holds object "defibrillator"
3b. script;" You manage to get the device working and moments later, Bob's eyes flicker and he starts to show signs of reviving"


This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums