Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to make Iron maiden slam doors shut.
lolmaster Offline
Member

Posts: 170
Threads: 9
Joined: Jul 2012
Reputation: 6
#5
RE: How to make Iron maiden slam doors shut.

...Or, if you actually want them to shut on their own, you can examine the games script for when the iron maiden opens and reverse it.

I have found it:

///////////////////////////////////////////////////
// Iron Maiden doors opening scare
void OpenIronMaiden(string &in asParent, string &in asChild, int alState)
{
AddDebugMessage("Scary iron maiden opening", false);

SetSwingDoorDisableAutoClose("iron_maiden_2", true);
SetSwingDoorClosed("iron_maiden_2", false, false);

/////////////////////////////////////////////
// Open iron maiden doors
AddBodyImpulse("iron_maiden_2_leftDoor", -0.7, 0 , -0.7, "world");
AddBodyImpulse("iron_maiden_2_rightDoor", -0.7, 0 , 0.7, "world");

AddTimer("TimerExtraMaidenImpulse", 0.1, "TimerExtraMaidenImpulse");

PlaySoundAtEntity("AreaIronMaidenEffect", "24_iron_maiden", "AreaIronMaidenEffect", 0.0f, false);

PlayerReact(0.5f);

CreateParticleSystemAtEntity("maidensmoke","ps_iron_maiden_event_smoke.ps", "AreaIronMaidenEffect", false);
StartScreenShake(0.1f, 0.1f, 0.0f, 0.1f);

// Disable trigger area and activate room sanity drain
SetEntityActive("AreaIronMaidenOpen", false);
SetEntityActive("AreaInsanityEffect_1", true);

GiveSanityDamage(10.0f, true);
SetRadialBlurStartDist(0.4f);
FadeRadialBlurTo(0.2f, 0.4f);

AddTimer("TimerActiveMaidenEmotion",1.5f,"TimerActiveMaidenEmotion");
}

void TimerExtraMaidenImpulse(string &asTimer)
{
AddBodyImpulse("iron_maiden_2_leftDoor", -0.7, 0 , -0.7, "world");
AddBodyImpulse("iron_maiden_2_rightDoor", -0.7, 0 , 0.7, "world");
}


08-23-2012, 01:38 PM
Find Reply


Messages In This Thread
RE: How to make Iron maiden slam doors shut. - by lolmaster - 08-23-2012, 01:38 PM



Users browsing this thread: 1 Guest(s)