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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
New To Scripting
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#2
RE: New To Scripting

It's:

void OnStart()
{
AddUseItemCallback("", "FrontDoorKey", "Front_door", "UsedKeyOnDoor", true);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
PlaySoundAtEntity("", "pick_key", "FrontDoorKey", 0, false);
SetSwingDoorLocked("Front_door", false, true);
PlaySoundAtEntity("", "unlock_door", "Front_door", 0, false);
RemoveItem("FrontDoorKey");
}



You had a few more innecessary things Wink

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
05-24-2013, 08:52 PM
Find


Messages In This Thread
New To Scripting - by ohheylookitsmax - 05-24-2013, 08:16 PM
RE: New To Scripting - by The chaser - 05-24-2013, 08:52 PM
RE: New To Scripting - by ohheylookitsmax - 05-24-2013, 09:12 PM
RE: New To Scripting - by FlawlessHappiness - 05-24-2013, 09:40 PM
RE: New To Scripting - by ohheylookitsmax - 05-24-2013, 11:24 PM
RE: New To Scripting - by FlawlessHappiness - 05-25-2013, 12:33 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 01:26 AM
RE: New To Scripting - by PutraenusAlivius - 05-25-2013, 02:03 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 02:10 AM
RE: New To Scripting - by PutraenusAlivius - 05-25-2013, 02:15 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 02:22 AM
RE: New To Scripting - by PutraenusAlivius - 05-25-2013, 02:54 AM
RE: New To Scripting - by Daemian - 05-25-2013, 02:56 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 03:19 AM
RE: New To Scripting - by Tomato Cat - 05-25-2013, 03:26 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 03:33 AM
RE: New To Scripting - by Romulator - 05-25-2013, 04:03 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 04:26 AM
RE: New To Scripting - by Romulator - 05-25-2013, 04:56 AM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 03:15 PM
RE: New To Scripting - by Romulator - 05-25-2013, 04:01 PM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 04:14 PM
RE: New To Scripting - by PutraenusAlivius - 05-25-2013, 03:51 PM
RE: New To Scripting - by Romulator - 05-25-2013, 04:17 PM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 04:28 PM
RE: New To Scripting - by Your Computer - 05-25-2013, 04:50 PM
RE: New To Scripting - by ohheylookitsmax - 05-25-2013, 05:28 PM
RE: New To Scripting - by Romulator - 05-25-2013, 04:42 PM



Users browsing this thread: 3 Guest(s)