Need some help! untrechable code and invaild expression,assumed zero(4
#1

Here is my problem:

Код:
D:\Users\ROBERT\Desktop\AVS.pwn(1744) : warning 225: unreachable code
D:\Users\ROBERT\Desktop\AVS.pwn(1746) : error 029: invalid expression, assumed zero
D:\Users\ROBERT\Desktop\AVS.pwn(1746) : error 029: invalid expression, assumed zero
D:\Users\ROBERT\Desktop\AVS.pwn(1746) : error 029: invalid expression, assumed zero
D:\Users\ROBERT\Desktop\AVS.pwn(1746) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Here is the script part that couses problems...

Код:
if(strcmp(cmd,"/car",true)==0)//warning 225: unreachable code
if(IsPlayerConnected(playerid))//error 029: invalid expression, assumed zero (3x same error comes here)
Here is the pastebin version of whole FS..please try to find solution.

Reply
#2

The problem is quite clear...you are returning a value (that returned by CallLocalFunction) before the warning line. It is unreachable!

If you don't understand how it is unreachable, look through the pawn_lang.pdf for return statements (and honestly you should have looked there anyway to find the error/warning and how to fix it).
Reply
#3

Can you paste me the code part that i need to put in?
Reply
#4

There is no code you need to put in, you would need to delete some! And I don't know why you added the code you did in there, as you probably don't know what it does. You should read pawn_lang.pdf before attempting any coding or editing.
Reply
#5

PHP код:
    if(strcmp(cmdtext,"/car",true)==0)//warning 225: unreachable code
    

Use this and just remove this
PHP код:
if(IsPlayerConnected(playerid)) 
Reply
#6

I did it like you sayd,but it still says the same 3x invaild expression ,assumed zero and unrechable code :/

-Any other solutions?
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)