The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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
Need help to make key react when use for door.
ZxBrad Offline
Member

Posts: 140
Threads: 29
Joined: Mar 2011
Reputation: 0
#1
Need help to make key react when use for door.

Hey i just made a really small script a key to door script and i got the key item name and description working and all i need is just having it work on the door and i got the script done. But the door just doesnt want to work with the door heres my script

Quote:////////////////////////////
// Run first time starting map
void OnStart()
{
SetMessage("Journal", "start", 8.0f);
AddUseItemCallback("", "doorkey_1", "castle_1", "UsedKeyOnDoor", true);
}
void UsedKeyOnCabinet(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("castle_1", false, true);
PlaySoundAtEntity("", "unlock_door", "castle_1", 0, false);
RemoveItem("doorkey_1");
}

plz and thx for some replys.

WARNING: Noob Doesn't Know How To Script.
[Image: xcn384.gif]

04-06-2011, 11:08 PM
Find


Messages In This Thread
Need help to make key react when use for door. - by ZxBrad - 04-06-2011, 11:08 PM



Users browsing this thread: 2 Guest(s)