SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 25/08/2015, 02:52 PM   #1
Andy5
Big Clucker
 
Andy5's Avatar
 
Join Date: Mar 2015
Location: -
Posts: 53
Reputation: 0
Exclamation [HELP]Error !!

i was try to compiling something , and i got an error can someone help me to fix it

The Code :


PHP Code:
public Robbery(playerid)
{
   new 
string[256];
   new 
PlayerName[MAX_PLAYER_NAME];
   
GetPlayerName(playeridPlayerNamesizeof(PlayerName));
   {
        if(
Robbed[playerid] == 0);
        {
            if(
IsPlayerInRangeOfPoint(playerid5,2208.1985,-1072.3022,1050.4766))
            {
                     new 
Earning 500 random(500);
                    
format(stringsizeof(string), "%s Robbed %d from The Tatto Shop"Name(playerid), Earning);
                       
SendClientMessageToAll(COLOR_GREY,string);
                    
SendClientMessage(playeridCOLOR_RED"Rob Complete");
                      
GivePlayerMoney(playerid,Earning);
                      
Robbed[playerid] = 1;
                      
SetTimerEx("AbleRobbing"30000false"i"playerid);
                      
SetPlayerWantedLevel(playerid,GetPlayerWantedLevel(playerid)+1);
                      
SetPlayerScore(playerid,GetPlayerScore(playerid)+2);
                
            }


        }
            
    }
        

Error :

Code:
C:\Users\ma\Downloads\fp.pwn(367) : error 036: empty statement
Line (367) >>
Code:
        if(Robbed[playerid] == 0);
Andy5 is offline   Reply With Quote
Old 25/08/2015, 02:58 PM   #2
Boot
Big Clucker
 
Join Date: May 2014
Posts: 68
Reputation: 9
Default Re: [HELP]Error !!

Remove the brackets after GetPlayerName function.
Boot is offline   Reply With Quote
Old 25/08/2015, 03:14 PM   #3
[KHK]Khalid
Gangsta
 
[KHK]Khalid's Avatar
 
Join Date: Jan 2012
Location: Alexandria, Egypt
Posts: 854
Reputation: 136
Default Re: [HELP]Error !!

There's an extra semi-colon, remove it. It should be:

pawn Code:
if(Robbed[playerid] == 0)
[KHK]Khalid is offline   Reply With Quote
Old 25/08/2015, 06:47 PM   #4
Andy5
Big Clucker
 
Andy5's Avatar
 
Join Date: Mar 2015
Location: -
Posts: 53
Reputation: 0
Default Re: [HELP]Error !!

Quote:
Originally Posted by [KHK]Khalid View Post
There's an extra semi-colon, remove it. It should be:

pawn Code:
if(Robbed[playerid] == 0)
works thanks
Andy5 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
error 017: undefined symbol,fatal error 107: too many error messages on one line Slicebook Scripting Help 11 04/05/2014 08:30 PM
fatal error 111: user error: sscanf (possibly the PAWN version) already defined? minijackc Scripting Help 2 15/01/2013 04:17 AM
An error has occured. (Error ID: 1064, You have an error in your SQL syntax; check the manual that corresponds.... rati555 Scripting Help 1 14/09/2012 07:45 PM
Registered plate stock error 'error 076: syntax error in the expression, or invalid function call' Deal-or-die Scripting Help 2 25/06/2012 03:12 PM
I get tagmismatch error, But i cant find any error error Swiftz Help Archive 1 16/04/2011 04:31 AM


All times are GMT. The time now is 10:38 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.