Kinda of money hack
#1

how can i do that if the player gets more than 50000 in 2 second some message about that will send to the admins.
how can i do that?
Reply
#2

try this

pawn Код:
// add this in the top of the script

new plMoney[MAX_PLAYERS];
// add this in OnGameModeInit

SetTimer("CheckMoney", 100, true)

}
forward CheckMoney();
public CheckMoney()
{
  for(new i = 0; i < MAX_PLAYERS; i ++)
  {
    plMoney[i] = GetPlayerMoney(i);
    SetTimerEx("Money2", 2000, false, "d", i);
  }
}
forward Money2(i);
public Money2(i)
{
  new money2[MAX_PLAYERS];  
  money2[i] = GetPlayerMoney(i);
  new money3[MAX_PLAYERS];
  money3[i] = money2[i] - plMoney[i];
  if(money3[i] >= 50000)
  {
    new name[MAX_PLAYER_NAME]; GetPlayerName(i, name, sizeof(name));
    new str[256]; format(str, sizeof(str), "%s has got more than 50 000$ in 2 seconds !!", name);
    SendClientMessageToAll(COLOR_LIGHTRED, str);
  }
  return 0;
}
and if you are using a GF edit

try this

pawn Код:
// add this in the top of the script

new plMoney[MAX_PLAYERS];
// add this in OnGameModeInit

SetTimer("CheckMoney", 100, true)

}
forward CheckMoney();
public CheckMoney()
{
  for(new i = 0; i < MAX_PLAYERS; i ++)
  {
    plMoney[i] = GetPlayerMoney(i);
    SetTimerEx("Money2", 2000, false, "d", i);
  }
}
forward Money2(i);
public Money2(i)
{
  new money2[MAX_PLAYERS];  
  money2[i] = GetPlayerMoney(i);
  new money3[MAX_PLAYERS];
  money3[i] = money2[i] - plMoney[i];
  if(money3[i] >= 50000)
  {
    new name[MAX_PLAYER_NAME]; GetPlayerName(i, name, sizeof(name));
    new str[256]; format(str, sizeof(str), "%s has got more than 50 000$ in 2 seconds !!", name);
    ABroadCast(COLOR_LIGHTRED, str, 1);
  }
  return 0;
}

Reply
#3

tanks
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)