Last 5 user using the command
#4

I don't know how to explain, so I did an example. Don't just copy and paste, try to understand what I did.

PHP код:
new lastGiveMoneyCommandUses[5][144];
// 5 because you want the latest 5, 144 because it's the chat limit (in case of big reasons)
//In your give money command:
{
    
lastGiveMoneyCommandUses[4] = lastGiveMoneyCommandUses[3];
    
lastGiveMoneyCommandUses[3] = lastGiveMoneyCommandUses[2];
    
lastGiveMoneyCommandUses[2] = lastGiveMoneyCommandUses[1];
    
lastGiveMoneyCommandUses[1] = lastGiveMoneyCommandUses[0];
    
format(lastGiveMoneyCommandUses[0], 144"%s gave %d to %s, reason: %s"adminNameamountplayerNamereason);
}
SendLastGiveMoneyCommandUses(playerid)
{
    
SendClientMessage(playerid, -1" ————— LAST 5 ADMIN USING /givemoney —————");
    
SendClientMessage(playerid, -1lastGiveMoneyCommandUses[0]);
    
SendClientMessage(playerid, -1lastGiveMoneyCommandUses[1]);
    
SendClientMessage(playerid, -1lastGiveMoneyCommandUses[2]);
    
SendClientMessage(playerid, -1lastGiveMoneyCommandUses[3]);
    
SendClientMessage(playerid, -1lastGiveMoneyCommandUses[4]);
    return 
1;

Reply


Messages In This Thread
Last 5 user using the command - by DGRP - 17.02.2017, 02:55
Re: Last 5 user using the command - by SyS - 17.02.2017, 09:38
Re: Last 5 user using the command - by AbyssMorgan - 17.02.2017, 10:05
Re: Last 5 user using the command - by renatog - 17.02.2017, 13:30
Respuesta: Last 5 user using the command - by Eloy - 17.02.2017, 13:58

Forum Jump:


Users browsing this thread: 2 Guest(s)