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
Script Help Fadein ? or Wake up
Straxedix Offline
Senior Member

Posts: 426
Threads: 52
Joined: Mar 2014
Reputation: 5
#11
RE: Fadein ? or Wake up

Uffffff
So lang need to get only ???
SetMessage
And Hps got (string& asTextCategory, string& asTextEntry, float afTime); ?

Can make .lang what to copy and .hps what to copy pleaseee Sad Sad

03-08-2014, 02:23 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#12
RE: Fadein ? or Wake up

(03-08-2014, 02:23 PM)Straxedix Wrote: Uffffff
So lang need to get only ???
SetMessage
And Hps got (string& asTextCategory, string& asTextEntry, float afTime); ?

Can make .lang what to copy and .hps what to copy pleaseee Sad Sad
ffs

SetMessage(string& asTextCategory, string& asTextEntry, float afTime); should be in the HPS.

<CATEGORY Name="TextCategory">
<Entry Name="TextEntry"> Insert message here</Entry>
</CATEGORY>

Should be in the Lang.

"Veni, vidi, vici."
"I came, I saw, I conquered."
03-08-2014, 02:29 PM
Find
Straxedix Offline
Senior Member

Posts: 426
Threads: 52
Joined: Mar 2014
Reputation: 5
#13
RE: Fadein ? or Wake up

i set all like that
and in .hps file
SetMessage(string& asTextCategory, string& asTextEntry, float afTime);
so it come error says:Expexcted indentifier

03-08-2014, 02:39 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#14
RE: Fadein ? or Wake up

(03-08-2014, 02:39 PM)Straxedix Wrote: i set all like that
and in .hps file
SetMessage(string& asTextCategory, string& asTextEntry, float afTime);
so it come error says:Expexcted indentifier

You changed the string names according to your HPS. Example:
Spoiler below!

HPS
PHP Code: (Select All)
SetMessage("ExampleCategory""ExampleText"0); 

LANG
PHP Code: (Select All)
<CATEGORY Name="ExampleCategory">
<
Entry Name="ExampleText">This is the text that will appear.</Entry>
</
CATEGORY

It'll appear in game as;
PHP Code: (Select All)
This is the text that will appear


"Veni, vidi, vici."
"I came, I saw, I conquered."
(This post was last modified: 03-08-2014, 02:44 PM by PutraenusAlivius.)
03-08-2014, 02:44 PM
Find
Straxedix Offline
Senior Member

Posts: 426
Threads: 52
Joined: Mar 2014
Reputation: 5
#15
RE: Fadein ? or Wake up

.lang looks like this now
<CATEGORY Name="TextCategory">
<Entry Name="TextEntry">What Happened? Where im i?</Entry>
</CATEGORY>
.hps looks like this now
SetMessage(string& TextCategory, string& TextEntry, float 0);

and again same error

03-08-2014, 02:51 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#16
RE: Fadein ? or Wake up

(03-08-2014, 02:51 PM)Straxedix Wrote: .lang looks like this now
<CATEGORY Name="TextCategory">
<Entry Name="TextEntry">What Happened? Where im i?</Entry>
</CATEGORY>
.hps looks like this now
SetMessage(string& TextCategory, string& TextEntry, float 0);

and again same error

Correction:
It's SetMessage("TextCategory", "TextEntry", 0);

"Veni, vidi, vici."
"I came, I saw, I conquered."
03-08-2014, 02:55 PM
Find
Straxedix Offline
Senior Member

Posts: 426
Threads: 52
Joined: Mar 2014
Reputation: 5
#17
RE: Fadein ? or Wake up

.lang looks
SetMessage("TextCategory", "TextEntry", 0);
same error i sooo anoying you and im sorry but let's fix it Sad Sad Sad

(This post was last modified: 03-08-2014, 03:00 PM by Straxedix.)
03-08-2014, 03:00 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#18
RE: Fadein ? or Wake up

(03-08-2014, 03:00 PM)Straxedix Wrote: .lang looks
SetMessage("TextCategory", "TextEntry", 0);
same error i sooo anoying you and im sorry but let's fix it Sad Sad Sad

Lang was correct, but the HPS wasn't.

That was supposed to be in the HPS so yeah. It's okay as long as you're learning.

"Veni, vidi, vici."
"I came, I saw, I conquered."
03-08-2014, 03:01 PM
Find
Straxedix Offline
Senior Member

Posts: 426
Threads: 52
Joined: Mar 2014
Reputation: 5
#19
RE: Fadein ? or Wake up

oh god my misstake in TYPING it is in .hps not in .lang

but again same error iwn it is in .hps

SomethingRidiculous
lang it's ok
hps
look like this:


void OnStart()
{
wakeUp();
}

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);
}
SetMessage("TextCategory", "TextEntry", 0);

have idea what went wrong ???

(This post was last modified: 03-08-2014, 03:12 PM by Straxedix.)
03-08-2014, 03:03 PM
Find
PutraenusAlivius Offline
Posting Freak

Posts: 4,713
Threads: 75
Joined: Dec 2012
Reputation: 119
#20
RE: Fadein ? or Wake up

SetMessage is not defined in a callback function. Functions like SetMessage and AddEntityCollideCallback, etc. has to be on one of the brackets.

PHP Code: (Select All)
void OnStart()
{
wakeUp();
}

void wakeUp () {
FadeOut(0); // Instantly fades the screen out. (Good for starting the game)
FadeIn(20); // Amount of seconds the fade in takes
FadeImageTrailTo(22);
FadeSepiaColorTo(1004);
SetPlayerActive(false); 
FadePlayerRollTo(50220220); // "Tilts" the players head
FadeRadialBlurTo(0.152);
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();
SetMessage("TextCategory""TextEntry"0);
SetPlayerActive(true);
FadePlayerRollTo(03333); // Change all settings to defaults
FadeRadialBlurTo(0.01);
FadeSepiaColorTo(04);
SetPlayerCrouching(false);
FadeImageTrailTo(0,1);


"Veni, vidi, vici."
"I came, I saw, I conquered."
03-08-2014, 03:16 PM
Find




Users browsing this thread: 1 Guest(s)