Facebook Twitter YouTube Frictional Games | Forum | Newsletter | Dev Blog | Dev Wiki | Support | Shelf | Store

Privacy Policy


Thread Closed 
 
Thread Rating:
  • 3 Votes - 3.67 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to 'Wake Up' (For intros, etc)
Author Message
DamnNoHtml Offline
Senior Member

Posts: 386
Joined: Sep 2010
Reputation: 11
Post: #1
How to 'Wake Up' (For intros, etc)
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]

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);
}
09-20-2010 11:26 PM
Find all posts by this user
theDARKW0LF Offline
Member

Posts: 150
Joined: Sep 2010
Reputation: 0
Post: #2
RE: How to 'Wake Up' (For intros, etc)
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?

Check out my custom stories(1)(2)!
09-21-2010 02:44 AM
Find all posts by this user
jens Offline
Frictional Games

Posts: 3,107
Joined: Apr 2006
Reputation: 103
Post: #3
RE: How to 'Wake Up' (For intros, etc)
Yeah, copy all the code in the box and then also add wakeUp(); to your onstart section.
09-21-2010 06:10 AM
Visit this user's website Find all posts by this user
house Offline
Member

Posts: 194
Joined: Oct 2010
Reputation: 1
Post: #4
RE: How to 'Wake Up' (For intros, etc)
This guys a pro!

11-16-2010 11:34 PM
Find all posts by this user
Frontcannon Offline
Senior Member

Posts: 538
Joined: Jul 2010
Reputation: 0
Post: #5
RE: How to 'Wake Up' (For intros, etc)
I think there are some good sounds too that could be used for this..


╔═════════════════╗
☺ Smoke weed everyday ☺
╚═════════════════╝
11-16-2010 11:35 PM
Find all posts by this user
Everlone Offline
Member

Posts: 178
Joined: Oct 2010
Reputation: 2
Post: #6
RE: How to 'Wake Up' (For intros, etc)
thanks, good work. I make my own wake up but i will try yours Smile i think it could be better then my Wink

[Image: 555233.jpg]
11-17-2010 06:29 AM
Find all posts by this user
house Offline
Member

Posts: 194
Joined: Oct 2010
Reputation: 1
Post: #7
RE: How to 'Wake Up' (For intros, etc)
Is there a way to make the wakeup from the begining of the game Amnesia? That would change my life forever.

11-19-2010 07:18 PM
Find all posts by this user
Chilton Offline
Member

Posts: 138
Joined: Sep 2010
Reputation: 0
Post: #8
RE: How to 'Wake Up' (For intros, etc)
(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
11-20-2010 02:49 AM
Find all posts by this user
LoneWolf Offline
Senior Member

Posts: 305
Joined: Sep 2010
Reputation: 0
Post: #9
RE: How to 'Wake Up' (For intros, etc)
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.
11-21-2010 01:27 PM
Find all posts by this user
Chilton Offline
Member

Posts: 138
Joined: Sep 2010
Reputation: 0
Post: #10
RE: How to 'Wake Up' (For intros, etc)
(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?
11-21-2010 01:30 PM
Find all posts by this user
Thread Closed 




User(s) browsing this thread: 1 Guest(s)