[SOLVED]Dialog /stats Bugged
#2

hmm, try this instead.

pawn Код:
dcmd_stats(playerid,params[])
{
  new gplayer;
  if(!params[0])gplayer = playerid;
  else gplayer=strval(params);
  if(!IsPlayerConnected(gplayer))return SendClientMessage(playerid,COLOR_RED,"Player not connected.");
  new tempstring[250];
  GivePlayerName(gplayer,tempstring,sizeof(tempstring));
  format(tempstring,sizeof(tempstring),"%s's Stats\n\nKills: %d\nDeaths: %d\nRatio: %0.1f\nMoney: %d",tempstring,PlayerInfo[gplayer][Kills], PlayerInfo[gplayer][Deaths], floatdiv(PlayerInfo[gplayer][Kills], PlayerInfo[gplayer][Deaths]),GetPlayerMoney(gplayer));
  ShowPlayerDialog(playerid,DIALOGID,DIALOG_STYLE_MSGBOX,"Stats",tempstring,"","Close");
  return 1;
}
Replace DIALOGID with a dialog id that won't interfere with other scripts.
Reply


Messages In This Thread
[SOLVED]Dialog /stats Bugged - by PotH3Ad - 08.01.2010, 20:58
Re: Dialog /stats Bugged - by Joe Staff - 08.01.2010, 21:09
Re: Dialog /stats Bugged - by PotH3Ad - 09.01.2010, 01:29

Forum Jump:


Users browsing this thread: 1 Guest(s)