The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 906 - File: showthread.php PHP 7.2.24-0ubuntu0.18.04.17 (Linux)
File Line Function
/showthread.php 906 errorHandler->error



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 Error with scripts
MaksoPL Offline
Member

Posts: 51
Threads: 26
Joined: Mar 2014
Reputation: 0
#1
Error with scripts

Hi. I've got an error with a script:
main (10,1) Unexpected token '{'
main (15,16) Expected identifier
main (16,1) Unexpected token '}'

My .hps file:

void OnStart()
{
SetSanityDrainDisabled(true);

GiveItemFromFile("lantern", "lantern.ent");

for(int i=0;i< 25;i++) GiveItemFromFile("tinderbox_"+i, "tinderbox.ent");
}

{
AddEntityCollideCallback("Player", "12_girl_scream", "GirlScream", true, 1);
AddEntityCollideCallback("Player", "message1", "Message1", true, 1);
AddEntityCollideCallback("Player", "message2", "Message2", true, 1);
}
PlaySoundAtArea("12_girl_scream", "12_girl_scream.snt", "GirlScream01", 0, false);
}
void Message1(string &in asChild, string &in asParent, int alState)
{
SetMessage("Messages", "Wiadomosc1", 10);
}

void Message2(string &in asChild, string &in asParent, int alState)
{
SetMessage("Messages", "Wiadomosc2", 10);
}

void OnEnter()
{
PlayMusic("07_amb", true, 1.0f, 4.0f, 1, true);

}
What i've must do?
01-15-2015, 01:53 PM
Find


Messages In This Thread
Error with scripts - by MaksoPL - 01-15-2015, 01:53 PM
RE: Error with scripts - by DnALANGE - 01-15-2015, 02:18 PM
RE: Error with scripts - by PutraenusAlivius - 01-16-2015, 02:58 PM
RE: Error with scripts - by DnALANGE - 01-16-2015, 03:06 PM



Users browsing this thread: 1 Guest(s)