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
[help]Key wont unlock door
Lemorz56 Offline
Junior Member

Posts: 10
Threads: 3
Joined: Oct 2011
Reputation: 0
#1
Exclamation  [help]Key wont unlock door

Hello, Ive made a map with a door and a key, when i use the key on the door it says "Cannot Use Item This Way". heres my .hps file. (ALSO the key's (one key) name is "monsterdoorkey" and the door "monsterdoor")
void OnStart()
{
AddUseItemCallback("", "monsterdoorkey", "monsterdoor", "LockFunction", true);
}

void LockFunction(string &in asItem, string &in asEntity)
{
    SetSwingDoorLocked("monsterdoor", false, true);
    PlaySoundAtEntity("", "unlock_door", "door1", 0, false);
    RemoveItem("monsterdoorkey1");
}

And heres my lang file
<LANGUAGE>
       <CATEGORY Name="CustomStoryMain">
          <Entry Name="Description">This is an story and a little remake of Martin's AKA "Marwin" House. Have FUN!.[br]Thank You For Playing And Downloading This Map![br]support me at youtube Z3bProductions[br]Also bring an extra pairofpants! HEHEH</Entry>
       </CATEGORY>
      
     <CATEGORY Name="Inventory">
       <Entry Name="ItemDesc_monsterdoorkey">Key To Hallway</Entry>
       <Entry Name="ItemName_monsterdoorkey">Hallway Key</Entry>
     </CATEGORY>
      
</LANGUAGE>


also anyone who knows how to make a note/text appear on pickup?
(This post was last modified: 10-23-2011, 11:46 AM by Lemorz56.)
10-23-2011, 11:01 AM
Find


Messages In This Thread
[help]Key wont unlock door - by Lemorz56 - 10-23-2011, 11:01 AM
RE: [help]Key wont unlock door - by Lemorz56 - 10-23-2011, 12:13 PM



Users browsing this thread: 1 Guest(s)