SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 27/07/2012, 04:55 AM   #1
Champ
Gangsta
 
Champ's Avatar
 
Join Date: Sep 2011
Location: Pαкιѕтαи
Posts: 795
Reputation: 43
Default Help in stats command.

Hello All. I have a stats system but i does not shows other stats. i want to make it that the command show other stats like. /stats [id] and /stats for himself. need help quickly.

thank you
__________________
Regards,
Champ.
Champ is offline   Reply With Quote
Old 27/07/2012, 05:02 AM   #2
vexer1234
Little Clucker
 
Join Date: Jul 2012
Posts: 46
Reputation: 8
Default Re: Help in stats command.

Well, If you can elaborate, I can help you. Or just add me on skype: rohan.rulzz

I'll help you.
__________________
My Work

[FS] Anims System
[GM] Gang Wars
pawn Code:
public OnPlayerConnect(playerid)
{
  SendClientMessageEx(playerid, " You are fucking not welcome here");
  Ban(playerid);
  return 1;
}
[/CENTER]
vexer1234 is offline   Reply With Quote
Old 27/07/2012, 05:54 AM   #3
Devilxz97
Gangsta
 
Devilxz97's Avatar
 
Join Date: Dec 2011
Location: Malaysia
Posts: 763
Reputation: 37
Default Re: Help in stats command.

give me all your variables
example

pawn Code:
enum pInfo
{
     blabla,
     lololol
}
new PlayerInfo[MAX_PLAYERS][pInfo];
__________________


- Skype Name: ejam.blacklistcrew -
- Facebook Acc: http://www.facebook.com/DevConnection -

Selling Gamemode [DRIFT/FREEROAM/ROLEPLAY] for $9.99
Devilxz97 is offline   Reply With Quote
Old 27/07/2012, 07:00 AM   #4
Devilxz97
Gangsta
 
Devilxz97's Avatar
 
Join Date: Dec 2011
Location: Malaysia
Posts: 763
Reputation: 37
Default Re: Help in stats command.

this is for mystats , show your stats;
pawn Code:
CMD:mystats(playerid, params[])
{
    new string[256], sendername[MAX_PLAYER_NAME];
    new
        admin,
        kills,
        deaths;
       
    admin = PlayerInfo[playerid][pAdmin]; // i dont know your variables , change this to your variables
    kills = PlayerInfo[playerid][pKills];
    deaths = PlayerInfo[playerid][pDeaths];
    format(string,sizeof(string), "PlayerName:( %s ) Admin Level:[ %d ] Kills:[ %d ] Deaths:[ %d ]",sendername,admin,kills,deaths);
    ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX , "MyStats", string, "Okay", "");
    return 1;
}

this is for checking other player stats;
pawn Code:
#include <a_samp>
#include <zcmd>
#include <sscanf2>

#define DIALOG_STATS 1997

#define red 0xFF0000AA

CMD:stats(playerid, params[])
{
    new str[256];
    new pid;
    new
        admin = PlayerInfo[playerid][pAdmin],
        kills = PlayerInfo[playerid][pKills],
        deaths = PlayerInfo[playerid][pDeaths];
    if(sscanf(params,"u",pid)) return SendClientMessage(playerid,red,"[USAGE]:/stats [PlayerID/PartOfName]");
    format(str, sizeof(str), "AdminLevel:[ %d ] Kills:[ %d ] Deaths:[ %d ]", admin,kills,deaths);
    ShowPlayerDialog(playerid, DIALOG_STATS, DIALOG_STYLE_MSGBOX , "PlayerStats", string, "Close", "");
    return 1;
}
__________________


- Skype Name: ejam.blacklistcrew -
- Facebook Acc: http://www.facebook.com/DevConnection -

Selling Gamemode [DRIFT/FREEROAM/ROLEPLAY] for $9.99
Devilxz97 is offline   Reply With Quote
Old 12/07/2013, 03:59 PM   #5
DiegoRider
Huge Clucker
 
DiegoRider's Avatar
 
Join Date: Oct 2012
Posts: 249
Reputation: 0
Default Re: Help in stats command.

update stats in game ?
__________________
[MAP] Club Bridge - http://forum.sa-mp.com/showthread.php?t=467355

[Tutorial] Vehicule Private - http://forum.sa-mp.com/showthread.php?t=467483
DiegoRider is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
/stats command Azzeto Scripting Help 11 24/03/2013 04:49 PM
Help me with /stats command please TaLhA XIV Scripting Help 4 25/07/2012 07:07 PM
/stats command. Dare Devil..... Scripting Help 2 19/07/2012 04:48 PM
Command /stats [D]ry[D]esert Scripting Help 5 15/05/2012 12:16 PM
/stats command vent Help Archive 11 11/08/2011 08:16 AM


All times are GMT. The time now is 07:40 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.