SA-MP Forums Archive
Need help - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Need help (/showthread.php?tid=247234)



Need help - SpiderWalk - 08.04.2011

I want to know how to create a command /stats


Re: Need help - SpiderWalk - 08.04.2011

HOw to do it?


Re: Need help - XFlawless - 08.04.2011

Stop double posting and use search.


Re: Need help - xir - 08.04.2011

pawn Код:
COMMAND:stats(playerid, params[])
{
    new pID;
    if(sscanf(params, "u", pID)) return SendClientMessage(playerid, -1, "Usage: /stats <playerid>");
    if(pID == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1, "This player is not connected");
    new string[128], Float:armour, Float:health;
    GetPlayerHealth(pID,health);
    GetPlayerArmour(pID, armour);
    format(string, sizeof(string), "Health: %0.f - Armour: %.2f", health,armour);
    SendClientMessage(playerid, -1, string);
    return 1;
}
with zcmd & sscanf


Re: Need help - Malcor - 08.04.2011

u need Dini to save the systems. for the simple one.

pawn Код:
if (strcmp("/Title", cmdtext, true, 10) == 0)
        {
        SendClientMessage(playerid, 0xFFFFFFFF,"=================={990000}*San Andreas Racers ID*{FFFFFF}==================");
        new PName[MAX_PLAYER_NAME], string[128 + MAX_PLAYER_NAME];
        GetPlayerName(playerid,PName,sizeof(PName));
        format(string,sizeof(string),"[NAME] : {990000}%s",PName);
        SendClientMessage(playerid,0xFFFFFFFF,string);
        SendClientMessage(playerid, 0xFFFFFFFF,"[TITLE] : {990000}Newcomer");
        SendClientMessage(playerid, 0xFFFFFFFF,"[SIGN] : {990000}Authorized by the San Andreas Driving Government");
        SendClientMessage(playerid, 0xFFFFFFFF,"===========================================================");
        }