[Ajuda] Correзгo de Dois Comandos PPC_Trucking.
#1

Galera to com duvida em dois comandos o primeiro й o /setlevel

Meu /setlevel й assim:
/setlevel [id] [level]
queria assim
/setlevel [id] [level] [dias]
Exemplo se eu colocar 3 dias o level dele volta ao 0 (zero)

Comando:
CLIQUE AQUI


O outro й o /abastecer, queria alem do /abastecer o /abastecertodos.

Meu /abastecer

CLIQUE AQUI


Base do GM: PPC_Trucking
Obs. Coloquei no PasteBin para nгo ficar muito grande.

Obrigado
Reply
#2

Tipo й sу usar um loop ... e se quer sу admin use bota uma if para verificar se й admin... n sei se ta certo fiz rapidinho aq e o outro comando to vendo aq tipo esse negocio de dias sу vendo as configuraзхes do seu gamemode pra poder fazer...
pawn Код:
COMMAND:abastecertodos(playerid, params[])
{
        // Setup local variables
        new vID;
    SendAdminText(playerid, "/abastecer", params);
        // Check if the player has logged in
        for(new i=0; i<MAX_PLAYERS; i++)
        {
            if (APlayerData[i][LoggedIn] == true)
            {
                // Check if the player's admin-level is at least 1
                if (APlayerData[i][PlayerLevel] >= 1)
                {
                        // Check if the player is inside a vehicle
                        if (IsPlayerInAnyVehicle(i))
                        {
                            // Get the vehicleid
                            vID = GetPlayerVehicleID(i);
                            // Refuel the vehicle
                            AVehicleData[vID][Fuel] = MaxFuel;
                                // Let the player know about it
                                SendClientMessage(i, 0x00FF00FF, "Todos os veiculos foram abastecidos.");
                        }
        }
                        else
                                SendClientMessage(i, 0x00FF00FF, "");
                }
                else
                    return 0;
        }
        else
            return 0;
 
        // Let the server know that this was a valid command
        return 1;
}
Reply
#3

Quote:
Originally Posted by Bruno Alves
Посмотреть сообщение
Tipo й sу usar um loop ... e se quer sу admin use bota uma if para verificar se й admin... n sei se ta certo fiz rapidinho aq e o outro comando to vendo aq tipo esse negocio de dias sу vendo as configuraзхes do seu gamemode pra poder fazer...
pawn Код:
COMMAND:abastecertodos(playerid, params[])
{
        // Setup local variables
        new vID;
    SendAdminText(playerid, "/abastecer", params);
        // Check if the player has logged in
        for(new i=0; i<MAX_PLAYERS; i++)
        {
            if (APlayerData[i][LoggedIn] == true)
            {
                // Check if the player's admin-level is at least 1
                if (APlayerData[i][PlayerLevel] >= 1)
                {
                        // Check if the player is inside a vehicle
                        if (IsPlayerInAnyVehicle(i))
                        {
                            // Get the vehicleid
                            vID = GetPlayerVehicleID(i);
                            // Refuel the vehicle
                            AVehicleData[vID][Fuel] = MaxFuel;
                                // Let the player know about it
                                SendClientMessage(i, 0x00FF00FF, "Todos os veiculos foram abastecidos.");
                        }
        }
                        else
                                SendClientMessage(i, 0x00FF00FF, "");
                }
                else
                    return 0;
        }
        else
            return 0;
 
        // Let the server know that this was a valid command
        return 1;
}
Vou testar Amanha, esse comando e comento aqui, o que mais vc precisaria para por o negocio de dias?
Reply
#4

sу do gm '-' mais sl to resolvendo uns problemas no meu ... mas vamos ver
Reply
#5

Quote:
Originally Posted by Bruno Alves
Посмотреть сообщение
sу do gm '-' mais sl to resolvendo uns problemas no meu ... mas vamos ver
Vish cara o GM? nгo seria algumas funзхes sу?
Reply
#6

Tentar fazer pra vocк nгo existe nй !
Se vocк quizer tentar aprender procure como fazer um sistema vip por dias e igual.
Reply
#7

Don poderia me passar um sistema de vip bom pra mim tentar fazer o q quero, ou c n um bom tuto?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)