Frictional Games Forum (read-only)

Full Version: Need various information
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Okay so, I need a script where the player falls down sideways and everything fades out, as if he faints. Problem is that I don't know how to do it, and I've tried using the original story's scripts for help, but I just can't understand them at all. Could you please teach me how to?

Or if you can't, but you can make the script, make the script for me?
Bump? I really need help
First, it depends if he is falling down a hole or not, but lets say that.

And so once the player collides with one of the areas in the shaft in the hole, stuff happens or you could add timers to be apart of the one single collide callback instead of many of them.

Code:
void OnStart()
{
     AddEntityCollideCallback("Player", "ScriptArea_1", "Func01", true, 1);
}
Func01(string &in asParent, string &in asChild, int alState)
{
     FadePlayerRollTo(110, 2, 3);
     FadeOut(5);
     AddTimer("", 5, "Func02");
}
Func02(string &in asTimer)
{
     PlaySoundAtEntity("", "player_bodyfall.snt", "Player", 0, false);
     ChangeMap("Map02", "PlayerStartArea_1", "", "");
}

The "ChangeMap" command teleports the player to a different map. Replace "Map02" with the name of your next map. The "PlayerStartArea_1", should be the name of the spawn in the next map for it is where the player will appear at once the map changes. The last 2 blanks can be left the way they are.
Ah, great! Now I can finish up my map! Thank you once again, I cannot explain my grattitude
Pages: 1 2 3