Please check this code out for me please
#8

Quote:
Originally Posted by _Zeus
Посмотреть сообщение
Not that, the line I posted.
Do this just correct the code for me so i can see this cause am getting confuse
Код:
CMD:setadmin(playerid,params[])
{
	new id,level;
	if(IsPlayerAdmin(playerid))
	{
	    if(sscanf(params,"ud",id,level))
		{
	        return SendClientMessage(playerid, 0xFF0000AA, "Usage: /givecash <playerid/name> <amount>");
		}
		else
		{
		    if(level > 5) return error
			}
		    else
		    {
					new INI:File = INI_Open(UserPath(id));
					INI_WriteInt(File,"Admin",level);
					INI_Close(File);
			}
		}
 }
 else
 {
	SendClientMessage(playerid, COL_RED, "That id is not connected");
	}
}
Код:
C:\Users\score_000\Desktop\Server\gamemodes\Unoffical.pwn(337) : error 017: undefined symbol "error"
C:\Users\score_000\Desktop\Server\gamemodes\Unoffical.pwn(339) : warning 217: loose indentation
C:\Users\score_000\Desktop\Server\gamemodes\Unoffical.pwn(339) : error 029: invalid expression, assumed zero
C:\Users\score_000\Desktop\Server\gamemodes\Unoffical.pwn(346) : warning 209: function "cmd_setadmin" should return a value
C:\Users\score_000\Desktop\Server\gamemodes\Unoffical.pwn(347) : error 010: invalid function or declaration
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


3 Errors.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 4 Guest(s)