I'll try them out, i'll tell how it went !
Here is how i editet my script from you guys,
////////////////////////////
//run when entering map
void OnStart()
{
AddUseItemCallback("", "key_study_1", "Freedom", "KeyOnDoor", true);
AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
}
void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Freedom", false, true);
PlaySoundAtEntity("", "unlock_door", "Freedom ", 0, false);
RemoveItem("key_study_1");
}
void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_brute_2", true);
SetEntityPlayerInteractCallback("cabinetmetal", "Spawn", true);
}
void Spawn(string &in asEntity)
{
SetEntityActive("corpse_male_1", true);
AddTimer("Scare", 0.5f, "Scare1");
}
void scare1(string &in asTimer)
{
GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare.snt", "Player", 0, false);
}
////////////////////////////
//Run when entering map
void OnEnter()
{
////////////////////////////
// Run when leaving map
void OnLeave()
}
void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Freedom", false, true);
PlaySoundAtEntity("", "unlock_door", "
Freedom ", 0, false);
RemoveItem("key_study_1");
}
void MonsterFunction(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("servant_brute_2", true);
SetEntityPlayerInteractCallback("cabinetmetal", "Spawn", true);
}
{
SetEntityActive("corpse_male_1", true);
AddTimer("Scare", 0.5f, "Scare1");
}
void scare1(string &in asTimer)
{
GiveSanityDamage(10, true);
PlaySoundAtEntity("", "react_scare.snt", "Player", 0, false);
}
////////////////////////////
//Run when entering map
void OnEnter()
{
////////////////////////////
// Run when leaving map
void OnLeave()
{
------------------------------------------------
---------------------------
FATAL ERROR
---------------------------
FATAL ERROR: Could not load script file 'custom_stories/Robin's Hell/custom_stories/Robin's Hell/maps/Robin's Hell.hps'!
main (54, 1) : ERR : Expected ',' or ';'
---------------------------
OK
---------------------------
This is so wierd