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
Wake Up Script Problems
Oscar House Offline
Senior Member

Posts: 302
Threads: 3
Joined: Nov 2010
Reputation: 9
#4
RE: Wake Up Script Problems

////////////////////////////
// Run first time starting map
void OnStart()
{
AddUseItemCallback("", "Key1", "Unlock1", "UsedKeyOnDoor1", true);
FadeOut(0);
FadeIn(20);
FadeImageTrailTo(2, 2);
FadeSepiaColorTo(100, 4);
SetPlayerActive(false);
FadePlayerRollTo(50, 220, 220);
FadeRadialBlurTo(0.15, 2);
SetPlayerCrouching(true);
AddTimer("trig1", 11.0f, "beginStory");
}

void beginStory(string &in asTimer)
{
ChangePlayerStateToNormal();
SetPlayerActive(true);
FadePlayerRollTo(0, 33, 33);
FadeRadialBlurTo(0.0, 1);
FadeSepiaColorTo(0, 4);
SetPlayerCrouching(false);
FadeImageTrailTo(0,1);
}

void UsedKeyOnDoor1(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Unlock1", false, true);
PlaySoundAtEntity("", "unlock_door", "Unlock1", 0, false);
RemoveItem("Key1");
}


////////////////////////////
// Run when entering map
void OnEnter()
{
PlayMusic("04_amb.ogg", true, 1.0f, 0, 0, true);
}


////////////////////////////
// Run when leaving map
void OnLeave()
{

}

There. See if that works.

[Image: 2exldzm.png]
(This post was last modified: 01-29-2011, 07:25 PM by Oscar House.)
01-29-2011, 07:22 PM
Find


Messages In This Thread
Wake Up Script Problems - by Henriksen - 01-29-2011, 06:19 PM
RE: Wake Up Script Problems - by Robby - 01-29-2011, 06:23 PM
RE: Wake Up Script Problems - by Henriksen - 01-29-2011, 07:12 PM
RE: Wake Up Script Problems - by Oscar House - 01-29-2011, 07:22 PM
RE: Wake Up Script Problems - by rmdashrf - 01-29-2011, 07:59 PM



Users browsing this thread: 1 Guest(s)