CMD:giveweapon(playerid,params[])
{
new pAdmin[MAX_PLAYERS];
if(pAdmin[playerid] <= 4 && !IsPlayerAdmin(playerid)) // If they are not RCON admin
{
// Then it sends this message
SendClientMessage(playerid,-1,"You are not authorised to use this command.");
return 1;
}
new
weaponid,
targetid,
ammo;
if(sscanf(params,"uii",targetid,weaponid,ammo))
{
// If they typed the command wrong then show them this
SendClientMessage(playerid,-1,"USAGE: /giveweapon [playerid] [weaponid] [ammo]");
return 1;
}
else
{
GivePlayerWeapon(targetid,weaponid,ammo);
return 1;
}
}
CMD:giveweapon(playerid,params[])
{
new pAdmin[MAX_PLAYERS];
if(pAdmin[playerid] <= 2 && !IsPlayerAdmin(playerid)) // If they are not RCON admin
{
// Then it sends this message
SendClientMessage(playerid,-1,"You are not authorised to use this command.");
return 1;
}
new
weaponid,
targetid,
ammo;
if(sscanf(params,"uii",targetid,weaponid,ammo))
{
// If they typed the command wrong then show them this
SendClientMessage(playerid,-1,"USAGE: /giveweapon [playerid] [weaponid] [ammo]");
return 1;
}
else
{
GivePlayerWeapon(targetid,weaponid,ammo);
return 1;
}
}
CMD:giveweapon(playerid,params[])
{
new pAdmin[MAX_PLAYERS];
if(pAdmin[playerid] <= 2 && !IsPlayerAdmin(playerid)) // If they are not RCON admin
{
// Then it sends this message
SendClientMessage(playerid,-1,"You are not authorised to use this command.");
return 1;
}
new
weaponid,
targetid,
ammo;
if(sscanf(params,"uii",targetid,weaponid,ammo))
{
// If they typed the command wrong then show them this
SendClientMessage(playerid,-1,"USAGE: /giveweapon [playerid] [weaponid] [ammo]");
return 1;
}
else
{
GivePlayerWeapon(targetid,weaponid,ammo);
return 1;
}
}
Thanks You. Now i have problem when anyone conneect now is Trucking server i want change to Player (name) (id) Connected to International Trucking
|
new var0[201];
new var1[256];
new var2[256];
GetPlayerIp(playerid, var2, 256);
GetPlayerName(playerid, var0, 201);
format(var1, 256, "{828282}===> %s [ ID: %d ] Entered In Server [ IP: %s ] <===", var0, playerid, var2);
SendClientMessageToAll(0xBBC8CBAA, var1);
CMD:giveweapon(playerid,params[])
{
new pAdmin[MAX_PLAYERS];
if(pAdmin[playerid] <= 2))
{
// Then it sends this message
SendClientMessage(playerid,-1,"You are not authorised to use this command.");
return 1;
}
new
weaponid,
targetid,
ammo;
if(sscanf(params,"uii",targetid,weaponid,ammo))
{
// If they typed the command wrong then show them this
SendClientMessage(playerid,-1,"USAGE: /giveweapon [playerid] [weaponid] [ammo]");
return 1;
}
else
{
GivePlayerWeapon(targetid,weaponid,ammo);
return 1;
}
}
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(181) : warning 225: unreachable code
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(181) : warning 217: loose indentation
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(184) : warning 217: loose indentation
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(778) : warning 217: loose indentation
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(1499) : error 029: invalid expression, assumed zero
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(1505) : warning 225: unreachable code
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
1 Error.
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(181) : warning 225: unreachable code // The Code is not available for access in Mode
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(181) : warning 217: loose indentation // Poorly Indented Lines
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(184) : warning 217: loose indentation // Poorly Indented Lines
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(778) : warning 217: loose indentation // Poorly Indented Lines
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(1499) : error 029: invalid expression, assumed zero
C:\Documents and Settings\rado\Desktop\truck server\gamemodes\PPC_Trucking.pwn(1505) : warning 225: unreachable code // The Code is not available for access in Mode
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
1 Error.