06-27-2014, 10:40 AM
i already saw a QUESTION on the forum of someone that asked this.. how to do a place.. when you go there the plank will break and you will fall...
i tried this but it doesn't work! i think my hps file is good to ?
This is my hps file.. and if you see , my plank name is BoardCreak and my area name is BreakingArea ...
i tried this but it doesn't work! i think my hps file is good to ?
PHP Code:
void OnLeave()
{
}
void OnStart()
{
AddUseItemCallback("", "sleutel1", "deur1", "UsedKeyOnDoor", true);
AddEntityCollideCallback("Player", "BreakingArea", "BoardCreak", true, 1);
}
void UsedKeyOnDoor (string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("deur1", false, true);
PlaySoundAtEntity("", "unlock_door.snt", "deur1", 0, false);
RemoveItem("sleutel1");
}
void BoardCreak(string&in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("WoodCreaking", "CREAKINGNOISE.snt", "BreakingArea", 0.15f, false);
AddTimer("ImFaaaalling", 3.34f, "StartFalling");
}
void StartFalling(string &in asTimer)
{
SetPropHealth("Board", 0);
}
This is my hps file.. and if you see , my plank name is BoardCreak and my area name is BreakingArea ...