Hello everybody. I am currently making my first map and I for the life of me CAN NOT GET THE KEY TO WORK!!!
when I pick it up it says "Picked up" and the key has no description. and will not work on the door. I have named the key in the right place and everything. Here is my Coding and lang files.
void OnStart()
{
AddUseItemCallback("", "key_1", "castle_silent.ent", "unlockdoor", true);
}
void unlockdoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked(asEntity, false, true);
PlaySoundAtEntity("", "unlock_door", asEntity, 0, false);
RemoveItem(key_1);
}
void OnLeave()
{
}
and my extra_English.lang
</LANGUAGE>
<CATEGORY Name ="Inventory">
<Entry Name="ItemName_Key_1">Key</Entry>
<Entry Name="ItemDesc_Key_1">"lawls"</Entry>
</CATEGORY>
</LANGUAGE>
If anyone could help me I would be forever in debt XD