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] ANOTHER ERROR UNEXPECTED END OF FILE!
Tripication Offline
Member

Posts: 172
Threads: 19
Joined: Dec 2011
Reputation: 6
#4
RE: [SCRIPT] ANOTHER ERROR UNEXPECTED END OF FILE!

(01-11-2012, 01:51 PM)flamez3 Wrote: void StartEffectEmotionFlash("basementdoortext","dooropen","00_laugh.snt")
{
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
}

You haven't used a callback for that; and you are using strings in syntax's. When do you want the StartEffectMotionFlash to happen?
I completely missed that part.

Also, even if it is wrong, you should get into the habit of putting spaces after your commas. so rather than
("basementdoortext","dooropen","00_laugh.snt")

Use
("basementdoortext", "dooropen", "00_laugh.snt")

But dont actually use that, its wrong, so for now your script should be like this

void OnStart()

{
AddEntityCollideCallback("Player", "musicareabasement", "MusicPlay", true, 0);
AddEntityCollideCallback("Player", "basementdoorsmash", "func_slam", true, 1);

}

void MusicPlay(string &in asParent, string &in asChild, int alState)
{
PlayMusic("Music_01.ogg" , true , 10 , 2.0f , 0 , true);
}

void func_slam(string &in asParent, string &in asChild, int alState)
{
SetPropHealth("basementdoor", 0.0f);
SetPropHealth("basementcorpse:, 0.0f);
PlaySoundAtEntity("", "scare_human_noises.snt", "Player", 0, false);
}

[Image: speedart__2___yoshimitsu_by_kamofudge-d4yo6kk.png]
(This post was last modified: 01-11-2012, 02:04 PM by Tripication.)
01-11-2012, 01:56 PM
Find


Messages In This Thread
RE: [SCRIPT] ANOTHER ERROR UNEXPECTED END OF FILE! - by Tripication - 01-11-2012, 01:56 PM



Users browsing this thread: 1 Guest(s)