Hi, im working on a chase sequence in my custom story, I've managed to figure out how to slam the door with some creepy effects thanks to the wiki.
I've been trying to get the door locked just after it slams.. But it doesnt work.
void func_slam(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("doorslammer", true, true);
SetSwingDoorLocked("doorslammer", false, true);
PlaySoundAtEntity("", "react_breath_slow.snt", "Player", 0, false);
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
PlaySoundAtEntity("", "close_door.snt", "Player", 0, false);
PlaySoundAtEntity("", "fear2.snt", "Player", 0, false);
GiveSanityDamage(5.0f, true);
}
Figured it, sorry for this dumb post.. had to change the false value for locked door...
Im such a noob....