Frictional Games Forum (read-only)
How to 'Wake Up' (For intros, etc) - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Articles (https://www.frictionalgames.com/forum/forum-40.html)
+---- Thread: How to 'Wake Up' (For intros, etc) (/thread-4626.html)

Pages: 1 2 3


How to 'Wake Up' (For intros, etc) - DamnNoHtml - 09-20-2010

This is a simple script used primarily for intros. This simulates the effects of being on the ground and slowly waking up. (As in the main game)

If you want this to happen as the game starts, simply put
wakeUp();
in the onStart() block of code.[/code]

Code:
void wakeUp () {
    FadeOut(0);     // Instantly fades the screen out. (Good for starting the game)
    FadeIn(20);      // Amount of seconds the fade in takes
    FadeImageTrailTo(2, 2);
    FadeSepiaColorTo(100, 4);
    SetPlayerActive(false);    
    FadePlayerRollTo(50, 220, 220);                 // "Tilts" the players head
    FadeRadialBlurTo(0.15, 2);
    SetPlayerCrouching(true);              // Simulates being on the ground
    AddTimer("trig1", 11.0f, "beginStory");            // Change '11.0f' to however long you want the 'unconciousness' to last
}

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



RE: How to 'Wake Up' (For intros, etc) - theDARKW0LF - 09-21-2010

Wow and I was just about to ask how to do that! Thanks a bunch!

EDIT: So should I copy all of what you just posted in the code box?


RE: How to 'Wake Up' (For intros, etc) - jens - 09-21-2010

Yeah, copy all the code in the box and then also add wakeUp(); to your onstart section.


RE: How to 'Wake Up' (For intros, etc) - house - 11-16-2010

This guys a pro!


RE: How to 'Wake Up' (For intros, etc) - Frontcannon - 11-16-2010

I think there are some good sounds too that could be used for this..


RE: How to 'Wake Up' (For intros, etc) - Everlone - 11-17-2010

thanks, good work. I make my own wake up but i will try yours Smile i think it could be better then my Wink


RE: How to 'Wake Up' (For intros, etc) - house - 11-19-2010

Is there a way to make the wakeup from the begining of the game Amnesia? That would change my life forever.


RE: How to 'Wake Up' (For intros, etc) - Chilton - 11-20-2010

(11-19-2010, 07:18 PM)house Wrote: Is there a way to make the wakeup from the begining of the game Amnesia? That would change my life forever.

Yes - Lots and lots of scripting, and a bit of luck


RE: How to 'Wake Up' (For intros, etc) - LoneWolf - 11-21-2010

I use this wakeup, but at the beginnign before you get up my screen shakes horribly and i cant look around. No idea why this is but its annoying and i have no idea how to fix it.


RE: How to 'Wake Up' (For intros, etc) - Chilton - 11-21-2010

(11-21-2010, 01:27 PM)LoneWolf Wrote: I use this wakeup, but at the beginnign before you get up my screen shakes horribly and i cant look around. No idea why this is but its annoying and i have no idea how to fix it.

Is your spawn partially in any objects, or in the ground at all? It could also be too high. Try refining the spawn area a touch

Failing that, have you modified it at all?