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 do I use void ChangeMap? [SOLVED]
Melvin Offline
Member

Posts: 245
Threads: 38
Joined: Jun 2012
Reputation: 5
#7
RE: How do I use void ChangeMap?

(08-07-2012, 03:41 AM)andyrockin123 Wrote: Sorry, the callback I wrote was off the top of my head so I mixed up the Boolean and Int spots Tongue
Here's a fix:


////////////////////////////
// Run when first time starting map
void OnStart()
{
AddEntityCollideCallback("Player", "Music", "StartMusic", true, 1);
AddEntityCollideCallback("Player", "PlayerSleep", "FunctionOne", true, 1);
}

void FunctionOne(string &in asParent, string &in asChild, int alState)
{
ChangeMap("Floor_2_Night.map", "SpawnAfterTeleport", "", "");
}

void StartMusic(string &in asParent, string &in asChild, int alState)
{
PlayMusic("Beforethestorm.ogg", true, 0.4, 8, 1, true);
}
Omg it worked! You are getting a spot in the credits, FOR SURE! Now I'm going to make an awesome custom story, I'm so full of ideas! thanks dude!!! Just one thing for the looks, how do I script it so that it looks like I woke up lying on the ground?

[Image: 25F7U37.png]
08-07-2012, 03:49 AM
Website Find


Messages In This Thread
How do I use void ChangeMap? [SOLVED] - by Melvin - 08-07-2012, 02:59 AM
RE: How do I use void ChangeMap? - by Adny - 08-07-2012, 03:05 AM
RE: How do I use void ChangeMap? - by Melvin - 08-07-2012, 03:17 AM
RE: How do I use void ChangeMap? - by Melvin - 08-07-2012, 03:38 AM
RE: How do I use void ChangeMap? - by Adny - 08-07-2012, 03:41 AM
RE: How do I use void ChangeMap? - by Melvin - 08-07-2012, 03:49 AM



Users browsing this thread: 1 Guest(s)