Script Request Thread #5

Anybody knows how to script /refund command for a RP server

Like when you type /refund dialog shows up and you can pick a option like :

-Money
-Level
-Bank Money
-Arms Dealer Skill Job Level
etc.
Reply

Hello,
im not able to create a command like /avi ! when a player do /avi or /Avi, It say : correct usage : /avi [Question] !
when a Player do /avi .... if im online, it says : Your Question Has Been Submitted !
and when im offline, it says : Avi is Not Online !

and i can reply them with /qreply !

Hope you can do That for me !!
Thanks
Reply

ZCMD based:

pawn Code:
CMD:avi(playerid,params[])
{
    new pname[MAX_PLAYER_NAME],pID,string[200];
    for(new i , slots = GetMaxPlayers(); i < slots; i++)
    {
        GetPlayerName(i, pname, sizeof(pname));
        if(!strcmp(pname,"Avi",true))//AVi your name
        {
            pID = i;
        }
    }
    if(pID)
    {
        if(strlen(params))
        {
            GetPlayerName(pID, pname, sizeof(pname));
            format(string, sizeof(string), "[Sent Message to %s]: %s", pname, params);
                    SendClientMessage(playerid, -1 , string);
                   GetPlayerName(playerid, pname, sizeof(pname));
                    format(string, sizeof(string), "[Message from %s(%i)]: %s", pname, playerid, params);
            SendClientMessage(pID,-1,string);
        }else   SendClientMessage(playerid, -1, "Enter a message");
    }else   SendClientMessage(playerid, -1, "Avi is not connected!");
    return 1;
}

Just give a try, and sorry for my bad scripting habits :>
Reply

not worked !
Reply

When enter wrong password server automatic kick him.
Reply

diablo 3 account for the following

Server must include
--
Gang Wars LS only
Groves n Ballas only
Spawn with - spray cans, deagles, shotgun, ak, snipers(any combination of 3) - 99 health 99 armor
Items spawned = ban
Anti-lag script - http://forum.sa-mp.com/showthread.ph...light=anti-lag
200 ping limit
Only street bikes, bmx, and mountain bikes
Vehicles spawned = ban
Visual hit icons
No interiors except bank/properties
Saved accounts/stats/money
Kill streaks

Working anti-hack for aimbots
Anti AFK/Pause
--

if you can do all of this and are interested in a diablo 3 account please message me
Reply

Hello,

Based on the NPC documentation.

It lacks features that one could make : I allready programmed a system of waypoints to create "intelligent" bots, but I really need function like this or a plugin like CNPC.


Have a nice day and thanks for all .
Reply

i want a capturable gang zone script.. with 20 Second timer..

in simple i want a capturable gang zone when a player stands there for 20 seconds he will get 5 scores + 5000 Money..
Reply

Quote:
Originally Posted by DwayneB
View Post
Anybody knows how to script /refund command for a RP server

Like when you type /refund dialog shows up and you can pick a option like :

-Money
-Level
-Bank Money
-Arms Dealer Skill Job Level
etc.
Command:

pawn Code:
CMD:refund(playerid, params[])
{
    if(IsPlayerConnected(playerid)) {
        new giveplayerid;
        if(sscanf(params, "u", giveplayerid)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /refund [playerid]");
        if(PlayerInfo[playerid][pAdmin] < 2) {
            SendClientMessage(playerid, COLOR_GREY,"   You are not authorized to use that command !");
            return 1;
        }
        if(IsPlayerConnected(giveplayerid)) {
            if(giveplayerid != INVALID_PLAYER_ID) {
                RefundingID[playerid] = giveplayerid;
                ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel");
            }
        }
    }
    return 1;
}
Dialog:
pawn Code:
if(dialogid == 48) //refund
    {
        if(!IsPlayerConnected(RefundingID[playerid]) || RefundingID[playerid] == INVALID_PLAYER_ID)
        {
            RefundingID[playerid] = 999; RefundingNumber[playerid] = 999;
            SendClientMessage(playerid, COLOR_GREY, "   That player is Offline / Invalid ID !");
            return 1;
        }
        if(!response) //cancel
        {
            RefundingNumber[playerid] = 999;
            ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
        }
        if(response)
        {
            if(!strlen(inputtext)) //no text inputted
            {
                RefundingNumber[playerid] = 999;
                ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                return 1;
            }
            new giveplayer[MAX_PLAYER_NAME];
            new amount;
            amount = strval(inputtext);
            new year, month, day;
            getdate(year, month, day);
            new stat = RefundingNumber[playerid];
            new giveplayerid = RefundingID[playerid];
   GetPlayerName(playerid, sendername, sizeof(sendername));
            GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
            switch(stat)
            {
                case 0: //Level
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pLevel] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 1: //Cash
                {
                    RefundingNumber[playerid] = 999;
                    ResetPlayerCash(giveplayerid);
                    GivePlayerCash(giveplayerid, amount);
                    format(string, sizeof(string), "* You have set %s's Cash to $%d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Cash to $%d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Cash to $%d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 2: //Bank
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pAccount] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Bank Account to $%d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Bank Account to $%d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Bank Account to $%d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 3: //Materials
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pMats] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Materials to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Materials to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Materials to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 4: //Crack
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pCrack] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Crack to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Crack to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Crack to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 5: //Pot
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pPot] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Pot to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Pot to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Pot to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 6: //Arms Dealer
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pArmsSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Arms Dealer Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Arms Dealer Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Arms Dealer Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 7: //Carjacker
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pJackSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Car Jacker Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Car Jacker Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Car Jacker Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 8: //Detective
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pDetSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Detective Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Detective Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Detective Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 9: //Lawyer
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pLawSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Lawyer Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Lawyer Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Lawyer Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 10: //Mechanic
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pMechSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Mechanic Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Mechanic Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Mechanic Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 11: //Drug Dealer
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pDrugsSkill] = lvl; //edit
                    //
                    PlayerInfo[giveplayerid][pDrugsSkill] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Drug Dealer Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Drug Dealer Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Drug Dealer Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 12: //Sex
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pSexSkill] = lvl; //edit
                    //
                    PlayerInfo[giveplayerid][pSexSkill] = amount; //edit
                    format(string, sizeof(string), "* You have set %s's Sex Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Sex Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Sex Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 13: //Boxing
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pBoxSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Boxing Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Boxing Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Boxing Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit
                   
                }
                case 14: //Fishing
                {
                    RefundingNumber[playerid] = 999;
                    //
                    new lvl;
                    if(amount == 1) { lvl = 0;}
                    else if(amount == 2) { lvl = 50; }
                    else if(amount == 3) { lvl = 100; }
                    else if(amount == 4) { lvl = 200; }
                    else if(amount == 5) { lvl = 400; }
                    else { SendClientMessage(playerid, COLOR_GREY, "   Amount can't be below 0 or above 5 !"); ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); return 1; } //edit
                    PlayerInfo[giveplayerid][pFishSkill] = lvl; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Fishing Level to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Fishing Level to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Fishing Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit

                }
                case 15: //Weap Restrict
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pWRestricted] = amount; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Weapon Restriction to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Weapon Restriction to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Fishing Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit

                }
                case 16: //Gang Warns
                {
                    RefundingNumber[playerid] = 999;
                    PlayerInfo[giveplayerid][pGangWarn] = amount; //edit
                    //
                    format(string, sizeof(string), "* You have set %s's Gang Warnings to %d.", GetPlayerNameEx(giveplayerid), amount); //edit
                    SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
                    format(string, sizeof(string), "* Administrator %s has set your Gang Warnings to %d.", GetPlayerNameEx(playerid), amount); //edit
                    SendClientMessage(giveplayerid, COLOR_LIGHTBLUE, string);
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    format(string, sizeof(string), "[%d/%d/%d] %s has set %s's Fishing Level to %d", day, month, year, GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid), amount); //edit

                }
                default:
                {
                    ShowPlayerDialog(playerid, 47, DIALOG_STYLE_LIST, "Stat Refund","Level\nCash\nBank\nMaterials\nCrack\nPot\nArms Dealer Skill\nCarjacker Skill\nDetective Skill\nLawyer Skill\nMechanic Skill\nDrug Dealer Skill\nSex Skill\nBoxing Skill\nFishing Skill\nRestricted Weapon Time\nGang Warnings", "Proceed", "Cancel"); //refund
                    SendClientMessage(giveplayerid, COLOR_GREY, "   Invalid stat code !");
                    return 1;
                }
            }
            OnPlayerStatsUpdate(giveplayerid);
        }
    }

You will need to modify it to your own setting thou, as I just pulled it out of a script I don't really use...or work on.
Reply

Hey...I am looking for two commands (based on zcmd if possible).
One would be /rape , where you rape someone , he loses some hp and he jumps into the air when it happens , and it would be a random thing, like 75% chance of success on the cmd working, and when it doesnt work, it would say "failed" or something.
Here is what I have , but it always gives the failed message on screen (oh and It would have to work only when you are , lets say , 2m away from the person or a bit less?)
pawn Code:
CMD:rape(playerid, params[])
{
    new targetid;
    if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, -1, "Usage: /rape [playerid]");
    else if(!IsPlayerConnected(targetid)) return SendClientMessage(playerid, -1, "Invalid player specified.");
    else if(targetid == playerid) return SendClientMessage(playerid, -1, "You can't rape yourself!");
    new success = random(4);
    if(success == 1)
    {
        new Float:oldhealth, Float:oldx, Float:oldy, Float:oldz;
        GetPlayerHealth(targetid, oldhealth);
        SetPlayerHealth(targetid, oldhealth - 20);
        PlayerPlaySound(targetid,1190,0.0,0.0,0.0);
        GetPlayerPos(targetid, oldx, oldy, oldz);
        SetPlayerPos(targetid, oldx, oldy, oldz + 3);
    }
    new fail = random(4);
    if(fail ==2)
    {
        SendClientMessage(playerid,-1,"The person got away, you've failed to rape him");
    }
    return 1;
}
Ok and the other zcmd which I cant get my head through is one that would be on command /sit 8 , your player does the lying down on his side animation.
First , I cant find the animation name, and secondly I dont understand the tutorials (but I dont want a filterscript neither)

Thanks everyone

pd:if you want to help script this dm server, pm me :d
Reply

need zcmd command for slap
Reply

PlayAudioStreamForPlayer without TextDraw exists?
Reply

Quote:
Originally Posted by tixzor
View Post
need zcmd command for slap
Code:
CMD:slap(playerid, params[])
{
	if(PlayerInfo[playerid][AdminLevel] >= 1)
	{
	    new id;
	    if(!sscanf(params, "u", id))
		{
			new Name[MAX_PLAYER_NAME], PlayerName[MAX_PLAYER_NAME], string[128], Float:px, Float:py, Float:pz;
			GetPlayerName(playerid, Name, sizeof(Name));
			GetPlayerName(id, PlayerName, sizeof(PlayerName));
			GetPlayerPos(id, px, py, pz);
			SetPlayerPos(playerid, px, py, pz+10);
			format(string, sizeof(string), "You have been slapped by administrator %s.", Name);
			SendClientMessage(id, 0xFFFFFFFF, string);
			format(string, sizeof(string), "You slapped %s.", PlayerName);
			SendClientMessage(playerid, 0xFFFFFFFF, string);
			return 1;
		}
		else return SendClientMessage(playerid, 0xFFFFFFFF, "USAGE: /slap [PlayerId/PartOfName]");
	}
	else return SendClientMessage(playerid, 0xFFFFFFFF, "You are not admin of this great community..");
}
here you go.
Reply

Hey im looking for a command like: /adminhelp [Your message]
Then all admin levels (1,2,3,4,5) will get a message with the message of the player and the playerID, And it would be nice if there is a little sound ringing when someone is using it (what only the admins can hear).

Hop it isnt so hard to make,

thanks
Reply

pawn Code:
COMMAND:adminhelp(playerid,params[])
{
    new text[128];
    if(sscanf(params, "s[128]", text))SendClientMessage(playerid, RED, "Usage: /adminhelp [Text]");
    SendClientMessage(playerid,RED,"Your question has been sent to online admins!");
    new Name[MAX_PLAYER_NAME], KickMessage[128];
    GetPlayerName(playerid, Name, sizeof(Name));
    format(KickMessage, sizeof(KickMessage), "[Question]:%s(%d):%s", Name, playerid,text);
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i) == 1)  /* if(PlayerInfo[i][pAdmin] >= 1)  Change it with yours */ SendClientMessage(i,      YELLOW, KickMessage); PlayerPlaySound(i, 1130, 0.0, 0.0, 0.0);
    }
    return 1;
}
Not sure if sound will work.
Reply

Quote:
Originally Posted by lordturhan
View Post
pawn Code:
COMMAND:adminhelp(playerid,params[])
{
    new text[128];
    if(sscanf(params, "s[128]", text))SendClientMessage(playerid, RED, "Usage: /adminhelp [Text]");
    SendClientMessage(playerid,RED,"Your question has been sent to online admins!");
    new Name[MAX_PLAYER_NAME], KickMessage[128];
    GetPlayerName(playerid, Name, sizeof(Name));
    format(KickMessage, sizeof(KickMessage), "[Question]:%s(%d):%s", Name, playerid,text);
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
    if(IsPlayerConnected(i) == 1)  /* if(PlayerInfo[i][pAdmin] >= 1)  Change it with yours */ SendClientMessage(i,      YELLOW, KickMessage); PlayerPlaySound(i, 1130, 0.0, 0.0, 0.0);
    }
    return 1;
}

Not sure if sound will work.

Well can I set the RED to: {FF0000} ?
Reply

Sure?
Reply

Help me please. Bus route for rp server.



Please Help Us
Reply

hi , im looking for hmm , my forum/website link show up every 2 minutes under the small map in game
Reply

Who can give me a vehicle filterscript or script using dialog. that destroy car within 3mins using a timer after the player exit the vehicle. Also destroy car after the player spawn another car. Really need this script.
Reply


Forum Jump:


Users browsing this thread: 26 Guest(s)