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
iron maiden bursts open?
Cruzore Offline
Senior Member

Posts: 301
Threads: 2
Joined: Jun 2012
Reputation: 37
#3
RE: iron maiden bursts open?

Look at how Frictional Games made it in their map.
Here's a small copy of it:
(collide callback for this function not included)
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");
}

So, for the burst open part, experiment with this:

AddBodyImpulse("iron_maiden_2_leftDoor", -0.7, 0 , -0.7, "world");
AddBodyImpulse("iron_maiden_2_rightDoor", -0.7, 0 , 0.7, "world");

the iron_maiden_2 part should be the name of your iron maiden. leftDoor and rightDoor stay. Be sure to experiment with the numbers, since the bursting is in coordinates of world, and you might have placed it a other way than the one in the game.
(This post was last modified: 06-26-2012, 02:56 PM by Cruzore.)
06-26-2012, 02:55 PM
Find


Messages In This Thread
iron maiden bursts open? - by Hartmann - 06-26-2012, 01:14 PM
RE: iron maiden bursts open? - by modoscar - 06-26-2012, 02:36 PM
RE: iron maiden bursts open? - by Hartmann - 06-26-2012, 10:01 PM
RE: iron maiden bursts open? - by Cruzore - 06-26-2012, 02:55 PM



Users browsing this thread: 1 Guest(s)