Dialog Box Command help
#1

Hello all i m dope i make my own server all admin commands done But i need a dialog box of these commands Can anyone here to make it?? if not so no need to make dialog box just make a simple like admin lvl 1 can use /level 1 commands LEVEL 1 - 8 please sir anyone can?



Normal Player Commands

/afk (Green colour) Like [PName] [ID] Has away from keyboard
/Back Same [Has back to his activity]
/antistealing (to enable/disable the antistealing for your personal vehicle)
/mycar (to teleport to you your personal vehicle)
/zadminhelp (to see some commands)
/savepersonalcar Chance to /vbuy (for vips, to save a personal vehicle)
/replacepersonalcar (for vips, to replace your personal vehicle)
/admins (to see all Online Admins)
/report [id] [reason] (to report a cheater)
/countdown (countdown for races)
/pm [id] [message] (sends a personal message)
/veh [nome] [col1] [col2] (to spawn a vehicle. example: "/veh elegy" will spawn a elegy)
/changename [old nome] [new nome] (to change your name) ---> defult is disabled
/carcolor [col1] [col2] (to change your vehicle's colors)
/votekick [id] [reason] (voting to kick a player)
/voteban [id] [reason] (voting to ban a player)
/voteccars (voting to remove spawned vehicles => from command /veh)
* dopeboy1040 slaps [id] (To slap to a player) around a bit with a large trout.

THEN NOw ADMINS COMMANDS WITH THEIR LEVELS

LEVEL 1 COMMANDS

/playersrecord (to see the Max number of players ever been in server)
/admincolor (to set yourself Admincolor => defult is GOLD)
/asay [messaggio] (public admin chat. color=blue)
/reports (to see last 3 reports)
/reportsoff (to close last reports window)
/fix (To fix your vehicle)
/admincmd1 (to see a list of all admin comands)
/getip [id] (To see Player Info: IP and all names that player used in the past)
/playerdata [id] (To see all stats of a player)
/setskintome [skin id] (to set yourself a skin)


LEVEL 2 COMMANDS

/announce [messaggio] (Big announce from admins in the middle of the screen)
/jetp (it gives you a Jetpack)
/lock (To Lock your vehicle)
/unlock (To UnLock your vehicle)
/setweather [weather id] (To change server weather)
/settime [hour] (To change server's world time)
/admincmd2 (to see the list of the admin commands which have action on EVERY PLAYER CONNECTED)
/spec [id] (you can watch a player with his CAMERA = Spectating mode ON)
/specoff [id] (Spectating mode OFF)


LEVEL 3 COMMANDS

/heal [id] [health] (To set health to a player)
/healall[ID] Give all heal and armour
/armour [id] [armour] (To set armour to a player)
/fixpv (To fix the vehicle to a player)
/flip (To flip your vehicle)
/gmx (To restart GM)
/forbidword [word] (to censure a word)
/muted (to see who (online players) is muted)
/unmute [id] (To unmute a player)
/warn [id] [reason] (To give warnings to a player)
/kick [id] [reason] (To kick a player)
/burn [id] (To burn a player)
/givecar [id] [car name] (To Give a vehicle to a player)
/explode [id] (To explode to a player)
/goto [id] (To teleport yourself to an other player)
/get [id] (To teleport a player to you)


LEVEL 4 COMMAND

/freeze [id] (To Freeze a player)
/unfreeze[id] (To unfreeze a player)
/jailed (to see who (online players) is jailed)
/jail [id] [minutes] (To jail a player for some minutes [from 1 to 84525164412])
/unjail [id] (To UnJail a player)
/kick [id] [reason] (To kick a player)
/ban [id] [reason] (To BAN a player)
/eject [id] (To Eject a player from his vehicle)
/disarm [id] (To reset weapons to a player)
/die [id] (To kill a player)
/setplayerweater [id] [weather id](To set a weather to a player)
/setplayertime [id] [hour] (To set a hour to a player)
/aheal (To set health to 100 to all players)
/aarmour (To set armour to MaxArmour to all players => 99)



LEVEL 5

/rangeban [id] [reason] (To BAN a player more powerfully)
/crash [id] (To Crash the game to a player)
/setname [id] [new name] (To set a different name to a player)
/givemoney [id] [ammount] (To give money to a player)
/setscore [id] [score] (To set score to a player)
/setplayerinterior [id] [int id] (To set an interior "interior" to a player "id")
/vixualworld [1-2] (Change you world]


LEVEL 6 COMMANDS

/ccars (to remove ALL spawned vehicles: it deletes only spawned vehicles witl /veh. Not vehicles in GM!!!)
/cchat (to clear all chat)
/reset [id] (To reset weapons, health, armour and money to a player)
/resetwarnings [id] (To Reset all warnings: warnings from command /warn, Flood-warnings, Ping-Warnings)
/setskin [id] [skin id] (To set a skin to a player)
/teleplayer [id] [player] (To teleport a player "id" to an other player "player")



LEVEL 7 COMMANDS

/vgoto [id] (To tele you to a player with your vehicle)
/vget [id] (To teleport a player to you with his vehicle)
/setgravity [gravity] (8 is standard gravity)
/tempadmin [id] [level] (To make a player admin only for ONE connection)
/weapon [id] [weapon name] [ammo] (To give a weapon to a player)
/getvhealth [id] (If a player is in a vehicle, it checks his vehicle's health)
/setvhealth [id] (If a player is in a vehicle, it sets health to his vehicle)
/removeweapon [id] [weapon] (to remove a weapon to a player)
/amute (To mute all players)
/aunmute (To unmute all players)
/afreeze (To Freeze all players)
/aunfreeze (To Unfreeze all players)
/asetskin [SKIN ID] (Set all player skin]



LEVEL 8 COMMANDS

/god (GOD MODE On)
/sgod (GOD MODE Off)
/reloadzadmin (to reload Zadmin4.2)
/unloadzadmin (to unload Zadmin4.2)
/makemegodadmin (ONLY FOR ADMIN RCON: First login to make yourself admin. It will set you MaxAdminLevel = 10)
/makeadmin [id] [level] (To make a player admin)
/makevip [id] [level] (to make a new VIP)
/removevip [id] (to remove a VIP)
/ajail (To jail all players)
/aunjail (To unjail all players)
/akick (To kick all players => Not who uses it)
/aban (To ban all players => Not who uses it)
/adisarm (To disarm all players)
/areset (To reset all to all players)
/asetskin (To set a skin to all players)
/aslap (To slap all players)
/aexplode (To explode all players)
/aget (To get all players to you)
/adie (To kill all players)
/aweapon [weapon name] [ammo] (To give a weapon to all players)
Reply
#2

Can some one responce me??

Anyone Who is call him self scripter?
Reply
#3

Code:
CMD:help(playerid, params[])
{
        new alevel = PlayerInfo[playerid][pAdmin];
        new string[16000];
        if(alevel > 0)
        {
        strcat(string,  "Normal Player Commands");
        strcat(string,  "Commands here.");
        }
        if(alevel >= 1)
        {
            strcat(string,  "LEVEL 1 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 2)
        {
            strcat(string,  "LEVEL 2 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 3)
        {
            strcat(string,  "LEVEL 3 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 4)
        {
            strcat(string,  "LEVEL 4 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 5)
        {
            strcat(string,  "LEVEL 5 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 6)
        {
            strcat(string,  "LEVEL 6 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 7)
        {
            strcat(string,  "LEVEL 7 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
        if(alevel >= 8)
        {
            strcat(string,  "LEVEL 8 COMMANDS\n");
            strcat(string,  "Commands here\n");
        }
	    return 1;
}
Reply
#4

Hmm..

PHP Code:
new string[16000]; 
Legit.
Reply
#5

Quote:
Originally Posted by Logic_
View Post
Hmm..

PHP Code:
new string[16000]; 
Legit.
XDDD
Reply
#6

Code:
Warning:Symbol is never used "Help"
so what this?

If i use /help in my server so its can't exixts show me Know server command

Then When i add #include <zcmd> so give me this error

Code:
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(385) : warning 202: number of arguments does not match definition
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(534) : error 017: undefined symbol "PlayerInfo"
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(534) : warning 215: expression has no effect
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(534) : error 001: expected token: ";", but found "]"
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(534) : error 029: invalid expression, assumed zero
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\grandlarc.pwn(534) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
I Add them in grandlarc

Can i make a new FS For this?

when i make FS then it show me this

Code:
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\Admin_cmds.pwn(240) : error 017: undefined symbol "PlayerInfo"
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\Admin_cmds.pwn(240) : warning 215: expression has no effect
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\Admin_cmds.pwn(240) : error 001: expected token: ";", but found "]"
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\Admin_cmds.pwn(240) : error 029: invalid expression, assumed zero
C:\Users\Ali Computer\Desktop\ALL IN ONE\0.3z\gamemodes\Admin_cmds.pwn(240) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#7

PHP Code:
//----------------------------------------------------------
//
//  GRAND LARCENY  1.0
//  A freeroam gamemode for SA-MP 0.3
//
//----------------------------------------------------------
#include <a_samp>
#include <core>
#include <float>
#include "../include/gl_common.inc"
#include "../include/gl_spawns.inc"
#pragma tabsize 0
//----------------------------------------------------------
#define COLOR_WHITE         0xFFFFFFFF
#define COLOR_NORMAL_PLAYER 0xFFBB7777
#define CITY_LOS_SANTOS     0
#define CITY_SAN_FIERRO     1
#define CITY_LAS_VENTURAS     2
new total_vehicles_from_files=0;
// Class selection globals
new gPlayerCitySelection[MAX_PLAYERS];
new 
gPlayerHasCitySelected[MAX_PLAYERS];
new 
gPlayerLastCitySelectionTick[MAX_PLAYERS];
new 
Text:txtClassSelHelper;
new 
Text:txtLosSantos;
new 
Text:txtSanFierro;
new 
Text:txtLasVenturas;
new 
thisanimid=0;
new 
lastanimid=0;
//----------------------------------------------------------
main()
{
    print(
"\n---------------------------------------");
    print(
"Running Fun World Of Dope Boy Server Enjoy");
    print(
"---------------------------------------\n");
}
//----------------------------------------------------------
public OnPlayerConnect(playerid)
{
    
GameTextForPlayer(playerid,"~u~Welcome Player Enjoy Here",4000,4);
      
SendClientMessage(playerid,COLOR_WHITE,"Welcome to {88AA88}Fun{FFFFFF} world {88AA88}Of{FFFFFF} All Friend Server");
      
      
// class selection init vars
      
gPlayerCitySelection[playerid] = -1;
    
gPlayerHasCitySelected[playerid] = 0;
    
gPlayerLastCitySelectionTick[playerid] = GetTickCount();
    
//SetPlayerColor(playerid,COLOR_NORMAL_PLAYER);
    //Kick(playerid);
    
    /*
    Removes vending machines
    RemoveBuildingForPlayer(playerid, 1302, 0.0, 0.0, 0.0, 6000.0);
    RemoveBuildingForPlayer(playerid, 1209, 0.0, 0.0, 0.0, 6000.0);
    RemoveBuildingForPlayer(playerid, 955, 0.0, 0.0, 0.0, 6000.0);
    RemoveBuildingForPlayer(playerid, 1775, 0.0, 0.0, 0.0, 6000.0);
    RemoveBuildingForPlayer(playerid, 1776, 0.0, 0.0, 0.0, 6000.0);
    */
    
    /*
    new ClientVersion[32];
    GetPlayerVersion(playerid, ClientVersion, 32);
    printf("Player %d reports client version: %s", playerid, ClientVersion);*/
     
return 1;
}
//----------------------------------------------------------
public OnPlayerSpawn(playerid)
{
    if(
IsPlayerNPC(playerid)) return 1;
    
    new 
randSpawn 0;
    
    
SetPlayerInterior(playerid,0);
    
TogglePlayerClock(playerid,0);
     
ResetPlayerMoney(playerid);
    
GivePlayerMoney(playerid30000);
    if(
CITY_LOS_SANTOS == gPlayerCitySelection[playerid]) {
         
randSpawn random(sizeof(gRandomSpawns_LosSantos));
         
SetPlayerPos(playerid,
         
gRandomSpawns_LosSantos[randSpawn][0],
         
gRandomSpawns_LosSantos[randSpawn][1],
         
gRandomSpawns_LosSantos[randSpawn][2]);
        
SetPlayerFacingAngle(playerid,gRandomSpawns_LosSantos[randSpawn][3]);
    }
    else if(
CITY_SAN_FIERRO == gPlayerCitySelection[playerid]) {
         
randSpawn random(sizeof(gRandomSpawns_SanFierro));
         
SetPlayerPos(playerid,
         
gRandomSpawns_SanFierro[randSpawn][0],
         
gRandomSpawns_SanFierro[randSpawn][1],
         
gRandomSpawns_SanFierro[randSpawn][2]);
        
SetPlayerFacingAngle(playerid,gRandomSpawns_SanFierro[randSpawn][3]);
    }
    else if(
CITY_LAS_VENTURAS == gPlayerCitySelection[playerid]) {
         
randSpawn random(sizeof(gRandomSpawns_LasVenturas));
         
SetPlayerPos(playerid,
         
gRandomSpawns_LasVenturas[randSpawn][0],
         
gRandomSpawns_LasVenturas[randSpawn][1],
         
gRandomSpawns_LasVenturas[randSpawn][2]);
        
SetPlayerFacingAngle(playerid,gRandomSpawns_LasVenturas[randSpawn][3]);
    }
    
SetPlayerColor(playerid,0xFF1C1CFF);
    
SetPlayerColor(playerid,0x1E05FAFF);
    
SetPlayerColor(playerid,0xF2BE0DFF);
    
SetPlayerColor(playerid,0x4E4E4EFF);
    
SetPlayerColor(playerid,0x8080FFFF);
    
SetPlayerColor(playerid,0xFFFF00FF);
    
SetPlayerColor(playerid,0xFFFFFFFF);
    
SetPlayerColor(playerid,0xFF00FFFF);
    
SetPlayerColor(playerid,0x80FF00FF);
    
    
//SetPlayerSkillLevel(playerid,WEAPONSKILL_PISTOL,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_PISTOL_SILENCED,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_DESERT_EAGLE,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_SHOTGUN,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_SAWNOFF_SHOTGUN,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_SPAS12_SHOTGUN,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_MICRO_UZI,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_MP5,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_AK47,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_M4,200);
    //SetPlayerSkillLevel(playerid,WEAPONSKILL_SNIPERRIFLE,200);*/
    
    
GivePlayerWeapon(playerid,24,100);
    
GivePlayerWeapon(playerid,36,100);
    
GivePlayerWeapon(playerid,26,100);
    
GivePlayerWeapon(playerid,9,100);
    
GivePlayerWeapon(playerid,16,100);
    
GivePlayerWeapon(playerid,18,100);
    
GivePlayerWeapon(playerid,27,100);
    
GivePlayerWeapon(playerid,42,100);
    
GivePlayerWeapon(playerid,43,100);
    
GivePlayerWeapon(playerid,46,100);
    
GivePlayerWeapon(playerid,22,100);
    return 
1;
}
//----------------------------------------------------------
public OnPlayerDeath(playeridkilleridreason)
{
    new 
playercash;
    
    
// if they ever return to class selection make them city
    // select again first
    
gPlayerHasCitySelected[playerid] = 0;
    
    if(
killerid == INVALID_PLAYER_ID) {
        
ResetPlayerMoney(playerid);
    } else {
        
playercash GetPlayerMoney(playerid);
        if(
playercash 0)  {
            
GivePlayerMoney(killeridplayercash);
            
ResetPlayerMoney(playerid);
        }
    }
       return 
1;
}
//----------------------------------------------------------
ClassSel_SetupCharSelection(playerid)
{
       if(
gPlayerCitySelection[playerid] == CITY_LOS_SANTOS) {
        
SetPlayerInterior(playerid,11);
        
SetPlayerPos(playerid,508.7362,-87.4335,998.9609);
        
SetPlayerFacingAngle(playerid,0.0);
        
SetPlayerCameraPos(playerid,508.7362,-83.4335,998.9609);
        
SetPlayerCameraLookAt(playerid,508.7362,-87.4335,998.9609);
    }
    else if(
gPlayerCitySelection[playerid] == CITY_SAN_FIERRO) {
        
SetPlayerInterior(playerid,3);
        
SetPlayerPos(playerid,-2673.8381,1399.7424,918.3516);
        
SetPlayerFacingAngle(playerid,181.0);
        
SetPlayerCameraPos(playerid,-2673.2776,1394.3859,918.3516);
        
SetPlayerCameraLookAt(playerid,-2673.8381,1399.7424,918.3516);
    }
    else if(
gPlayerCitySelection[playerid] == CITY_LAS_VENTURAS) {
        
SetPlayerInterior(playerid,3);
        
SetPlayerPos(playerid,349.0453,193.2271,1014.1797);
        
SetPlayerFacingAngle(playerid,286.25);
        
SetPlayerCameraPos(playerid,352.9164,194.5702,1014.1875);
        
SetPlayerCameraLookAt(playerid,349.0453,193.2271,1014.1797);
    }
    
}
//----------------------------------------------------------
// Used to init textdraws of city names
ClassSel_InitCityNameText(Text:txtInit)
{
      
TextDrawUseBox(txtInit0);
    
TextDrawLetterSize(txtInit,1.25,3.0);
    
TextDrawFont(txtInit0);
    
TextDrawSetShadow(txtInit,0);
    
TextDrawSetOutline(txtInit,1);
    
TextDrawColor(txtInit,0xEEEEEEFF);
    
TextDrawBackgroundColor(txtClassSelHelper,0x000000FF);
}
//----------------------------------------------------------
ClassSel_InitTextDraws()
{
    
// Init our observer helper text display
    
txtLosSantos TextDrawCreate(10.0380.0"Los Santos");
    
ClassSel_InitCityNameText(txtLosSantos);
    
txtSanFierro TextDrawCreate(10.0380.0"San Fierro");
    
ClassSel_InitCityNameText(txtSanFierro);
    
txtLasVenturas TextDrawCreate(10.0380.0"Las Venturas");
    
ClassSel_InitCityNameText(txtLasVenturas);
    
// Init our observer helper text display
    
txtClassSelHelper TextDrawCreate(10.0415.0,
       
" Press ~b~~k~~GO_LEFT~ ~w~or ~b~~k~~GO_RIGHT~ ~w~to switch cities.~n~ Press ~r~~k~~PED_FIREWEAPON~ ~w~to select.");
    
TextDrawUseBox(txtClassSelHelper1);
    
TextDrawBoxColor(txtClassSelHelper,0x222222BB);
    
TextDrawLetterSize(txtClassSelHelper,0.3,1.0);
    
TextDrawTextSize(txtClassSelHelper,400.0,40.0);
    
TextDrawFont(txtClassSelHelper2);
    
TextDrawSetShadow(txtClassSelHelper,0);
    
TextDrawSetOutline(txtClassSelHelper,1);
    
TextDrawBackgroundColor(txtClassSelHelper,0x000000FF);
    
TextDrawColor(txtClassSelHelper,0xFFFFFFFF);
}
//----------------------------------------------------------
ClassSel_SetupSelectedCity(playerid)
{
    if(
gPlayerCitySelection[playerid] == -1) {
        
gPlayerCitySelection[playerid] = CITY_LOS_SANTOS;
    }
    
    if(
gPlayerCitySelection[playerid] == CITY_LOS_SANTOS) {
        
SetPlayerInterior(playerid,0);
           
SetPlayerCameraPos(playerid,1630.6136,-2286.0298,110.0);
        
SetPlayerCameraLookAt(playerid,1887.6034,-1682.1442,47.6167);
        
        
TextDrawShowForPlayer(playerid,txtLosSantos);
        
TextDrawHideForPlayer(playerid,txtSanFierro);
        
TextDrawHideForPlayer(playerid,txtLasVenturas);
    }
    else if(
gPlayerCitySelection[playerid] == CITY_SAN_FIERRO) {
        
SetPlayerInterior(playerid,0);
           
SetPlayerCameraPos(playerid,-1300.8754,68.0546,129.4823);
        
SetPlayerCameraLookAt(playerid,-1817.9412,769.3878,132.6589);
        
        
TextDrawHideForPlayer(playerid,txtLosSantos);
        
TextDrawShowForPlayer(playerid,txtSanFierro);
        
TextDrawHideForPlayer(playerid,txtLasVenturas);
    }
    else if(
gPlayerCitySelection[playerid] == CITY_LAS_VENTURAS) {
        
SetPlayerInterior(playerid,0);
           
SetPlayerCameraPos(playerid,1310.6155,1675.9182,110.7390);
        
SetPlayerCameraLookAt(playerid,2285.2944,1919.3756,68.2275);
        
        
TextDrawHideForPlayer(playerid,txtLosSantos);
        
TextDrawHideForPlayer(playerid,txtSanFierro);
        
TextDrawShowForPlayer(playerid,txtLasVenturas);
    }
}
//----------------------------------------------------------
ClassSel_SwitchToNextCity(playerid)
{
    
gPlayerCitySelection[playerid]++;
    if(
gPlayerCitySelection[playerid] > CITY_LAS_VENTURAS) {
        
gPlayerCitySelection[playerid] = CITY_LOS_SANTOS;
    }
    
PlayerPlaySound(playerid,1052,0.0,0.0,0.0);
    
gPlayerLastCitySelectionTick[playerid] = GetTickCount();
    
ClassSel_SetupSelectedCity(playerid);
}
//----------------------------------------------------------
ClassSel_SwitchToPreviousCity(playerid)
{
    
gPlayerCitySelection[playerid]--;
    if(
gPlayerCitySelection[playerid] < CITY_LOS_SANTOS) {
        
gPlayerCitySelection[playerid] = CITY_LAS_VENTURAS;
    }
    
PlayerPlaySound(playerid,1053,0.0,0.0,0.0);
    
gPlayerLastCitySelectionTick[playerid] = GetTickCount();
    
ClassSel_SetupSelectedCity(playerid);
}
//----------------------------------------------------------
ClassSel_HandleCitySelection(playerid)
{
    new 
Keys,ud,lr;
    
GetPlayerKeys(playerid,Keys,ud,lr);
    
    if(
gPlayerCitySelection[playerid] == -1) {
        
ClassSel_SwitchToNextCity(playerid);
        return;
    }
    
// only allow new selection every ~500 ms
    
if( (GetTickCount() - gPlayerLastCitySelectionTick[playerid]) < 500 ) return;
    
    if(
Keys KEY_FIRE) {
        
gPlayerHasCitySelected[playerid] = 1;
        
TextDrawHideForPlayer(playerid,txtClassSelHelper);
        
TextDrawHideForPlayer(playerid,txtLosSantos);
        
TextDrawHideForPlayer(playerid,txtSanFierro);
        
TextDrawHideForPlayer(playerid,txtLasVenturas);
        
TogglePlayerSpectating(playerid,0);
        return;
    }
    
    if(
lr 0) {
       
ClassSel_SwitchToNextCity(playerid);
    }
    else if(
lr 0) {
       
ClassSel_SwitchToPreviousCity(playerid);
    }
}
//----------------------------------------------------------
public OnPlayerRequestClass(playeridclassid)
{
    if(
IsPlayerNPC(playerid)) return 1;
    if(
gPlayerHasCitySelected[playerid]) {
        
ClassSel_SetupCharSelection(playerid);
        return 
1;
    } else {
        if(
GetPlayerState(playerid) != PLAYER_STATE_SPECTATING) {
            
TogglePlayerSpectating(playerid,1);
            
TextDrawShowForPlayer(playeridtxtClassSelHelper);
            
gPlayerCitySelection[playerid] = -1;
        }
      }
    
    return 
0;
}
//----------------------------------------------------------
public OnGameModeInit()
{
    
SetGameModeText("Event/War/Drift");
    
ShowPlayerMarkers(PLAYER_MARKERS_MODE_GLOBAL);
    
ShowNameTags(1);
    
SetNameTagDrawDistance(40.0);
    
EnableStuntBonusForAll(0);
    
DisableInteriorEnterExits();
    
SetWeather(2);
    
SetWorldTime(11);
    
UsePlayerPedAnims();
    
//ManualVehicleEngineAndLights();
    //LimitGlobalChatRadius(300.0);
    
    
ClassSel_InitTextDraws();
    
// Player Class
    
AddPlayerClass(2,1759.0189,-1898.1260,13.5622,266.4503,24,24,999,26,99,34,999);
    
// SPECIAL
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/trains.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/pilots.txt");
       
// LAS VENTURAS
     
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/lv_law.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/lv_airport.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/lv_gen.txt");
    
    
// SAN FIERRO
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/sf_law.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/sf_airport.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/sf_gen.txt");
    
    
// LOS SANTOS
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/ls_law.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/ls_airport.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/ls_gen_inner.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/ls_gen_outer.txt");
    
    
// OTHER AREAS
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/whetstone.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/bone.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/flint.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/tierra.txt");
    
total_vehicles_from_files += LoadStaticVehiclesFromFile("vehicles/red_county.txt");
    
printf("Total vehicles from files: %d",total_vehicles_from_files);
    return 
1;
}
//----------------------------------------------------------
public OnPlayerUpdate(playerid)
{
    if(!
IsPlayerConnected(playerid)) return 0;
    if(
IsPlayerNPC(playerid)) return 1;
    
// changing cities by inputs
    
if( !gPlayerHasCitySelected[playerid] &&
        
GetPlayerState(playerid) == PLAYER_STATE_SPECTATING ) {
        
ClassSel_HandleCitySelection(playerid);
        return 
1;
    }
    
    
// No weapons in interiors
//    if(GetPlayerInterior(playerid) != 0 && GetPlayerWeapon(playerid) != 0) {
      //  SetPlayerArmedWeapon(playerid,0); // fists
       // return 0; // no syncing until they change their weapon
//    }
    
    // Don't allow minigun
    //if(GetPlayerWeapon(playerid) == WEAPON_MINIGUN) {
       // Kick(playerid);
       // return 0;
    //}
    
    /* No jetpacks allowed
    if(GetPlayerSpecialAction(playerid) == SPECIAL_ACTION_USEJETPACK) {
        Kick(playerid);
        return 0;
    }*/
    /* For testing animations
    new msg[128+1];
    new animlib[32+1];
    new animname[32+1];
    thisanimid = GetPlayerAnimationIndex(playerid);
    if(lastanimid != thisanimid)
    {
        GetAnimationName(thisanimid,animlib,32,animname,32);
        format(msg, 128, "anim(%d,%d): %s %s", lastanimid, thisanimid, animlib, animname);
        lastanimid = thisanimid;
        SendClientMessage(playerid, 0xFFFFFFFF, msg);
    }*/
    
return 1;
}
//----------------------------------------------------------
public OnPlayerCommandText(playeridcmdtext[])
{
    if (
strcmp("/Parkour3"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -2496.7410,2383.1858,14.7261);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To ParkOur Place");
        return 
1;
    }
    if (
strcmp("/mb"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -1461.5648,495.3752,18.2815);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To Militry Base");
        return 
1;
    }
    if (
strcmp("/stuntchilliad"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -2316.6655,-1598.5460,484);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To High Mount Chilliad");
        return 
1;
    }
    if (
strcmp("/chapel"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid2471.9209,917.3948,10.8203);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To Wedding Place");
        return 
1;
    }
    if (
strcmp("/mountain"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -2869.9761,2593.8892,269.9079);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To Server Mountain");
        return 
1;
    }
    if (
strcmp("/sfa"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -1657.5554,-164.9463,14.1720);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To Sun Faista Area");
        return 
1;
    }
    if (
strcmp("/farm"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -128.3215,-185.1312,1.8754);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To Sun Farm Land");
        return 
1;
    }
    if (
strcmp("/sftun1"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -2702.7671,228.6286,4.1797);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To SF Tune 1");
        return 
1;
    }
    if (
strcmp("/sftune2"cmdtexttrue10) == 0)
    {
        
SetPlayerPos(playerid, -2702.7671,228.6286,4.1797);
        
SendClientMessage(playerid0x00DD37FF"You Have Been Teleported To SF Tune 2");
        return 
1;
    }
        return 
0;
}
//***************************************************************************************************
CMD:Help(playeridparams[])
{
        new 
string[16000];
        new 
alevel PlayerInfo[playerid][pAdmin];
        new 
string[16000];
        if(
alevel 0)
        {
        
strcat(string,  "Normal Player Commands");
        
strcat(string,  "/sfa /mb /sftune1 ,/sftune2, /parkour3 , /farm , Comming soon ");
        }
        if(
alevel >= 1)
        {
            
strcat(string,  "LEVEL 1 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 2)
        {
            
strcat(string,  "LEVEL 2 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 3)
        {
            
strcat(string,  "LEVEL 3 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 4)
        {
            
strcat(string,  "LEVEL 4 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 5)
        {
            
strcat(string,  "LEVEL 5 COMMANDS\n");
            
strcat(string,  "Cbla bla bla bla\n");
        }
        if(
alevel >= 6)
        {
            
strcat(string,  "LEVEL 6 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 7)
        {
            
strcat(string,  "LEVEL 7 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        if(
alevel >= 8)
        {
            
strcat(string,  "LEVEL 8 COMMANDS\n");
            
strcat(string,  "bla bla bla bla\n");
        }
        return 
1;
}
CMD:help(playeridparams[])
{
        new 
string[16000];
        new 
alevel PlayerInfo[playerid][pAdmin];
        new 
string[16000];
        if(
alevel 0)
        {
        
strcat(string,  "Normal Player Commands");
        
strcat(string,  "Commands here.");
        }
        if(
alevel >= 1)
        {
            
strcat(string,  "LEVEL 1 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 2)
        {
            
strcat(string,  "LEVEL 2 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 3)
        {
            
strcat(string,  "LEVEL 3 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 4)
        {
            
strcat(string,  "LEVEL 4 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 5)
        {
            
strcat(string,  "LEVEL 5 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 6)
        {
            
strcat(string,  "LEVEL 6 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 7)
        {
            
strcat(string,  "LEVEL 7 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        if(
alevel >= 8)
        {
            
strcat(string,  "LEVEL 8 COMMANDS\n");
            
strcat(string,  "Commands here\n");
        }
        return 
1;

My Gamemode can you fix it?
Reply
#8

You don't have any variable to store the player admin. So your script is having only the RCON admin system.
And from what I have seen you also don't save anything when the player leaves.
I suggest you to add something to save playerdata (aka Register/Login system), then you will be able to work on your admin system.
Reply
#9

Don't Say That These Commands Are Scripted By You :/
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)