Frictional Games Forum (read-only)

Full Version: [Script ]Make player go to sleep
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
How do i get the player to fall down on the floor while the camera is slowly tilted 90 degrees and then the screen goes black..?

(Sorry for bad english Tongue )
FadePlayerRollTo(float afX, float afSpeedMul, float afMaxSpeed);
FadeOut(1.0f);
(12-11-2011, 09:52 PM)flamez3 Wrote: [ -> ]FadePlayerRollTo(float afX, float afSpeedMul, float afMaxSpeed);
FadeOut(1.0f);
Or more specifically:

}
PlaySoundAtEntity("", "player_bodyfall.snt", "Player", 0, false);
MovePlayerHeadPos(0, -1.5f, 0, 1, 0.1f);
FadePlayerRollTo(90, 1, 2);
FadeOut(1.0f);
{
Okay, but now, how do i get the player to wake up again...
(12-12-2011, 10:23 AM)9903286 Wrote: [ -> ]Okay, but now, how do i get the player to wake up again...
FadeIn(1.0f);
MovePlayerHeadPos(0, 0f, 0, 3, 0.1f);
FadePlayerRollTo(0, 1, 2);

You might need to use timers