Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to have more scripts then one at a time.[Solved]
MrCookieh Offline
Member

Posts: 157
Threads: 8
Joined: Jul 2011
Reputation: 0
#7
RE: How to have more scripts then one at a time.

Your script with the second key:
void OnStart()

{
AddUseItemCallback("", "Key1", "Door1", "KeyOnDoor", true);
AddUseItemCallback("", "Key2", "Door2", "KeyOnDoor2", true);
}

void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Door1", false, true);
PlaySoundAtEntity("", "unlock_door", "door1", 0, false);
RemoveItem("Key1");
}

void KeyOnDoor2(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Door2", false, true);
PlaySoundAtEntity("", "unlock_door", "door2", 0, false);
RemoveItem("Key2");
}

The Well: Descent - Take a look at it!
07-28-2011, 07:07 PM
Find


Messages In This Thread
RE: How to have more scripts then one at a time. - by MrCookieh - 07-28-2011, 07:07 PM



Users browsing this thread: 1 Guest(s)