#1

I do not out an order for a job
/confession [Nick / ID] [amount of one-99k] - To confess one player, and it was five crimes cancel them.

Can you help me?
Reply
#2

What? I've only understand that you need some command.
Can you explain a little what this command will do?
Reply
#3

Priest will serve her and when someone drops it serves them five murders
Reply
#4

help me please?
Reply
#5

Since you didn't tell me how your system works and what exactly you want in command.

I made it very simple.
If you have any question please ask, I'll be glad to help you.

This is the command ( uses ZCMD and sscanf ) :

pawn Код:
COMMAND:confession(playerid, params[])
{
    // Here should go your system like if(playerinfo[playerid][isapriest] == 1)
    new id,ammount;
    if(!sscanf(params,"ud", id, ammount))
    {
        if(IsPlayerConnected(id))
        {
            if(ammount >= 1000 || ammount <= 99000)
            {
                new string[128], name[MAX_PLAYER_NAME], Pname[MAX_PLAYER_NAME];
                new Pwanted = GetPlayerWantedLevel(id);
                GetPlayerName(playerid, name, sizeof(name));
                GetPlayerName(id, Pname, sizeof(Pname));
                SetPlayerWantedLevel(id, Pwanted - 5);
                format(string, sizeof(string), " %s has confessted you his sins.",Pname);
                SendClientMessage(playerid, 0xFFFF00FF, string);
                format(string, sizeof(string), "Priest %s has heard your sins and you soccessfully made a confession.",name);
                SendClientMessage(id, 0xFFFF00FF, string);
                GivePlayerMoney(id, -ammount);
            }
            else return SendClientMessage(playerid, 0xFF0000FF, "Please use ammount between 1000 and 99000");

        }
        else return SendClientMessage(playerid, 0xFF0000FF, "This player is not online.");
    }
    else return SendClientMessage(playerid, 0xFFFF00FF,"Usage: /confession [PlayerID] [Ammount]");
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)