28.07.2009, 16:19
Hello everyone, today I'm working on a new thing for a game mode, what I want it to do is, for the rcon admins, when they type /enter at a point, they are in a new place. this is what I got, but I get 4 errors, can anyone help?
forwarded
The pickups VV
under OnGameModeInit();
Rest of the code (the problem part)
When I compile, I get these messages VV
-- Line 653
please help if you can !
forwarded
Код:
forward OnPlayerPickupPickup (playerid, pickupid);
Код:
new adminenterpickup; new adminexitpickup;
Код:
adminenterpickup = CreatePickup (1239, 1, 794.3425,-1811.2014,13.0234); adminexitpickup = CreatePickup(1239, 1, 1726.1801,-1641.0100,20.2245);
Код:
public OnPlayerPickupPickup(playerid, pickupid)
{
if (pickupid == adminenterpickup) && IsPlayerAdmin(playerid); && strcmp(cmd, "/enter", true) == 0);
{
SendClientMessage(playerid, 0xFF0000FF, "Welcome to the admin spot rcon admin!");
SetPlayerPos(1726.1801,-1641.0100,20.2245);
return 1;
}
else if (pickupid == adminexitpickup) && IsPlayerAdmin(playerid); && strcmp(cmd, "/exit", true) == 0);
{
SendClientMessage(playerid, 0xFF0000FF, "You leave the admin spot and respawn outside near the beach");
SetPlayerPos(794.3425,-1811.2014,13.0234);
return 1;
}
else if !IsPlayerAdmin(playerid);
{
return 0;
}
return 1;
}
Код:
C:\Documents and Settings\Administrator\Desktop\samp02Xserver.win32\gamemodes\sftdm.pwn(653) : error 029: invalid expression, assumed zero C:\Documents and Settings\Administrator\Desktop\samp02Xserver.win32\gamemodes\sftdm.pwn(653) : error 029: invalid expression, assumed zero C:\Documents and Settings\Administrator\Desktop\samp02Xserver.win32\gamemodes\sftdm.pwn(653) : error 017: undefined symbol "cmd" C:\Documents and Settings\Administrator\Desktop\samp02Xserver.win32\gamemodes\sftdm.pwn(653) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
Код:
if (pickupid == adminenterpickup) && IsPlayerAdmin(playerid); && strcmp(cmd, "/enter", true) == 0);

