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
Key to door Script help
ZxBrad Offline
Member

Posts: 140
Threads: 29
Joined: Mar 2011
Reputation: 0
#1
Key to door Script help

Im making a little test migjigger.
And I have a door and a key on my lvl editor and i want the key to open that specific door, it works its just the name of the key doesnt pop up, it just says
"Picked Up"

And when i use it on the door the key doesnt go away. here is the script

Quote:////////////////////////////
// Run first time starting map
void OnStart()
{
AddUseItemCallback("", "awesomekey_1", "castle_1", "UsedKeyOnDoor", true);
}

void UsedKeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("castle_1", false, true);
PlaySoundAtEntity("", "unlock_door", "castle_1", 0, false);
RemoveItem("awesomekey_1");
}
////////////////////////////
// Run when entering map
void OnEnter()
{

}

////////////////////////////
// Run when leaving map
void OnLeave()
{

}

o and here is my extra english

Quote:<LANGUAGE>
<RESOURCES>
</RESOURCES>
<CATEGORY Name="CustomStoryMain">
<Entry Name="Description">Just a brief description!</Entry>
</CATEGORY>
<CATEGORY Name="Inventory">
<EntryName="ItemName_awesomekey_1">Awesome Key</Entry>
<Entry Name="ItemDesc_awesomekey_1">Key to your moms bedroom</Entry>
</CATEGORY>
</LANGUAGE>

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

(This post was last modified: 03-23-2011, 08:02 PM by ZxBrad.)
03-23-2011, 08:01 PM
Find


Messages In This Thread
Key to door Script help - by ZxBrad - 03-23-2011, 08:01 PM
RE: Key to door Script help - by palistov - 03-23-2011, 08:23 PM
RE: Key to door Script help - by ZxBrad - 03-23-2011, 08:29 PM
RE: Key to door Script help - by Viperdream - 03-23-2011, 08:58 PM
RE: Key to door Script help - by ZxBrad - 03-23-2011, 09:12 PM
RE: Key to door Script help - by MrBigzy - 03-23-2011, 09:51 PM
RE: Key to door Script help - by Russ Money - 03-24-2011, 01:02 AM
RE: Key to door Script help - by Austums - 03-24-2011, 01:10 AM
RE: Key to door Script help - by Russ Money - 03-24-2011, 01:22 AM
RE: Key to door Script help - by Austums - 03-24-2011, 01:23 AM
RE: Key to door Script help - by Pandemoneus - 03-24-2011, 01:34 AM
RE: Key to door Script help - by Austums - 03-24-2011, 01:35 AM
RE: Key to door Script help - by Russ Money - 03-24-2011, 02:00 AM



Users browsing this thread: 3 Guest(s)