13.07.2010, 20:19
Ahm because there something messed up with that when i used it..
anyway returning to ZCMD..
when i write my zcmd
it dones perfectly, but when command is done it shows that is unknown command.. I am using return 1 at the end of the ZCMD... looks like this..
anyway returning to ZCMD..
when i write my zcmd
it dones perfectly, but when command is done it shows that is unknown command.. I am using return 1 at the end of the ZCMD... looks like this..
pawn Код:
CMD:givemoney(playerid,params[])
{
if(IsPlayerConnected(playerid))
{
new playa,money,string[64],sendername[MAX_PLAYER_NAME],giveplayer[MAX_PLAYER_NAME],tmp[256];
if(PlayerInfo[playerid][pAdmin] >= 1338)
{
money = strval(tmp);
if(sscanf(params, "ui", playa,money))
{SendClientMessage(playerid,COLOR_GREY,"Lietojums: /givemoney <Spēlētāja ID> <Naudas Daudzums>");return 1;}
if(IsPlayerConnected(playa))
{
PlayerInfo[playa][pMoneyH] += money;
GetPlayerName(playa, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, 256, "AdmWarning: Administrators %s iedeva %s $%d.", sendername,giveplayer,money);
ABroadCast(COLOR_YELLOW,string,1);
}
else {SendClientMessage(playerid,COLOR_GREY,"Nepareizs spēlētāja ID");}
}
else{SendClientMessage(playerid,COLOR_GREY,"Tu nevari izmantot љo komandu!");}
}
return 1;
}