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
Expected '('
X5KillerKlownzX Offline
Junior Member

Posts: 6
Threads: 2
Joined: Apr 2013
Reputation: 0
#8
RE: Expected '('

(04-16-2013, 08:41 AM)Someone else Wrote:
(04-16-2013, 06:17 AM)JustAnotherPlayer Wrote: It's
void OnLeave
{
}
Actually it is:
void OnLeave()
{
    //code here
}


Also there should not be a semicolon after the ending function:
void ending(string &in asTimer);

So final code would look like:
void OnLeave()
{
    //code here
}

void ending(string &in asTimer)
{
    StartCredits("ending_alexander.ogg", false, "Ending", "MainCredits", 9001);
}

I highly recommend indenting lines withing functions and if statements as shown above as it can make your code way easier to read, and keep track of.

Yes. I will do that, but i copied that code, and removed the //code here cause i didnt have a code there. I am still getting an error but it is a different one. Now it is something like, "main (8,2) : ERR : Unexpected token '{' " I will send the code.

void OnLeave()
{
  
}

void ending(string &in asTimer);

{                                                                                            
    StartCredits("ending_alexander.ogg", false, "Ending", "MainCredits", 9001); This goes with StartCredits
}



Thats my code... Plz tell me what I done wrong.
04-16-2013, 12:04 PM
Find


Messages In This Thread
Expected '(' - by X5KillerKlownzX - 04-15-2013, 10:14 PM
RE: Expected '(' - by WALP - 04-16-2013, 12:37 AM
RE: Expected '(' - by 7heDubz - 04-16-2013, 12:48 AM
RE: Expected '(' - by X5KillerKlownzX - 04-16-2013, 01:50 AM
RE: Expected '(' - by PutraenusAlivius - 04-16-2013, 06:17 AM
RE: Expected '(' - by Som1Lse - 04-16-2013, 08:41 AM
RE: Expected '(' - by X5KillerKlownzX - 04-16-2013, 12:04 PM
RE: Expected '(' - by Traggey - 04-16-2013, 09:24 AM
RE: Expected '(' - by Adrianis - 04-16-2013, 12:36 PM
RE: Expected '(' - by PutraenusAlivius - 04-16-2013, 02:49 PM
RE: Expected '(' - by 7heDubz - 04-17-2013, 12:01 AM



Users browsing this thread: 1 Guest(s)