Hey im trying to scripting a door and my script looks like this !
Have i done something wrong beacuse when i use the key on the door i get a message
The Message goes like this : Cannot use this item this way!
If anyone have a clue please help me!
void OnStart()
{
AddUseItemCallback("", "Key1", "Door", "FUNCTION", true);
}
void FUNCTION(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Door", false, true);
PlaySoundAtEntity("", "unlock_door", "Door", 0, false);
RemoveItem("Key1");
}
SPERMAHAREN