Look at my code
void OnStart()
{
// use "ScriptArea_1" on "servunt_grunt_1" enemy => calls "MonsterFunc1"
AddUseItemCallback("", "key_tomb_2", "prison_2", "KeyOnDoor", true);
// use "key_tomb_3" on "castle_4" door => calls "KeyOnDoor"
AddUseItemCallback("", "key_tomb_3", "castle_4", "KeyOnDoor", true);
}
void MonsterFunc1(string &in asParent, string &in asChild , int alState)
{
SetEntityActive("servant_grunt_1" , true);
void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("castle_4", false, true);
RemoveItem(asItem);
PlaySoundAtEntity("", "unlock_door.snt", "castle_4", 0.0f, true);
}
I have fatal error. Unexpected end of the file. I can't understand what i did wrong. Help!