RE: Add all simple scripts here!
Okay problem: I dont have any errors in this script but why this doesnt work?
Full Script:
void OnStart()
{
AddEntityCollideCallback("Player" , "Origin" , "scareactive" , true , 1);
}
void scareactivate(string &in asParent , string &in asChild , int alState)
{
SetEntityActive("monster_1" , true);
}
////////////////////////////
// Run when entering map
void OnEnter()
{
AddUseItemCallback("", "key_1", "door_1", "KeyOnDoor", true);
AddUseItemCallback("", "key_2", "door_2", "KeyOnDoor2", true);
}
////////////////////////////
// Run when leaving map
void OnLeave()
{
}
////////////////////////////
// Actual functions
void KeyOnDoor(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("door_1", false, true);
PlaySoundAtEntity("", "unlock_door.snt", "door_1", 0.0f, false);
RemoveItem("key_1");
AddDebugMessage("KeyOnDoor", false);
}
void KeyOnDoor2(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("door_2", false, true);
PlaySoundAtEntity("", "unlock_door.snt", "door_1", 0.0f, true);
}
I have not activated Monster entity and all names alright but why monster doesnt appears in the marked area?
“Life is a game, play it”
|