Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Script created by Kris Yellow
- Everything is Original & Nothing is copied */
- #pragma tabsize 0
- #include <a_samp>
- #include <core>
- #include <float>
- #include <zcmd>
- #include <sscanf2>
- #include <time>
- #include <file>
- #define Prisoners 1
- #define Guards 2
- #define PrisonersColor 0x00FF00FF
- #define GuardsColor 0xFF8000FF
- //========================[Colors]==============================================
- #define COLOR_BITEM 0xE1B0B0FF
- #define COLOR_GRAD1 0xB4B5B7FF
- #define COLOR_GRAD2 0xBFC0C2FF
- #define COLOR_GRAD3 0xCBCCCEFF
- #define COLOR_GRAD4 0xD8D8D8FF
- #define COLOR_GRAD5 0xE3E3E3FF
- #define COLOR_GRAD6 0xF0F0F0FF
- #define COLOR_GREY 0xAFAFAFAA
- #define COLOR_GREEN 0x33AA33AA
- #define COLOR_RED 0xAA3333AA
- #define COLOR_BLACK 0x000001FF
- #define COLOR_BLUE 0x007BD0FF
- #define COLOR_LIGHTORANGE 0xFFA100FF
- #define COLOR_FLASH 0xFF000080
- #define COLOR_LIGHTRED 0xFF6347AA
- #define COLOR_LIGHTBLUE 0x33CCFFAA
- #define COLOR_LIGHTGREEN 0x9ACD32AA
- #define COLOR_YELLOW 0xFFFF00AA
- #define COLOR_LIGHTYELLOW 0xFFFF91FF
- #define COLOR_YELLOW2 0xF5DEB3AA
- #define COLOR_WHITE 0xFFFFFFAA
- #define COLOR_FADE1 0xE6E6E6E6
- #define COLOR_FADE2 0xC8C8C8C8
- #define COLOR_FADE3 0xAAAAAAAA
- #define COLOR_FADE4 0x8C8C8C8C
- #define COLOR_FADE5 0x6E6E6E6E
- #define COLOR_PURPLE 0xC2A2DAAA
- #define COLOR_DBLUE 0x2641FEAA
- #define COLOR_DOC 0xFF8282AA
- #define COLOR_DCHAT 0xF0CC00FF
- #define COLOR_NEWS 0xFFA500AA
- #define COLOR_OOC 0xE0FFFFAA
- #define TEAM_BLUE_COLOR 0x8D8DFF00
- #define TEAM_GROVE_COLOR 0x00AA00FF
- #define TEAM_AZTECAS_COLOR 0x01FCFFC8
- #define NEWBIE_COLOR 0x7DAEFFFF
- #define COLOR_HOUSETEXT 0xBDB388FF
- #define COLOR_ORANGE 0xFF830000
- #define BIZ_COLOR 0xBDB388FF
- #define SAMP_COLOR 0xAAC4E5FF
- #define COLOR_BIZ 0xE85D00FF
- //===========================[Neon]======================================
- #define NEON_RED 18647
- #define NEON_BLUE 18648
- #define NEON_GREEN 18649
- #define NEON_YELLOW 18650
- #define NEON_PINK 18651
- #define NEON_WHITE 18652
- //==============================================================================
- #define TCOLOR_NEWS 0xAD99BE00
- #define TCOLOR_VIP 0xECFF0000
- #define TCOLOR_WHITE 0xFFFFFF00
- #define TCOLOR_LIGHTGREEN 0x9ACD3200
- #define TCOLOR_NAVYBLUE 0x8D8DFF00
- #define TCOLOR_BEIGE 0xA5937000
- #define TCOLOR_GREY 0xBFC0C200
- #define TCOLOR_DARKGREY 0x52545900
- #define TCOLOR_BLUE 0x2641FE00
- #define TCOLOR_LIGHTBLUE 0x2B77A100
- #define TCOLOR_YELLOW 0xFFFF0000
- #define TCOLOR_HELP 0x00D700FF
- #define TCOLOR_FIND 0x9B0000AA
- #define TCOLOR_WANTED 0xFF0000AA
- #define TCOLOR_PRISON 0xF4A41900
- #define TCOLOR_APRISON 0xFD01FD00
- #define TCOLOR_HOSPITAL 0xAFAFAF00
- #define TCOLOR_PARAMEDIC 0xFF828200
- #define TCOLOR_SENATE 0x58585800
- //==============================================================================
- #define SCOLOR_RED 0xD9000000
- #define SCOLOR_PINK 0xFE81FE00
- #define SCOLOR_ORANGE 0xFF6A2200
- #define SCOLOR_YELLOW 0xF0F00000
- #define SCOLOR_CYAN 0x00E6E600
- #define SCOLOR_GREEN 0x00CA0000
- #define SCOLOR_BLUE 0x0058B000
- #define SCOLOR_BLACK 0x00000000
- #define SCOLOR_WHITE 0xFFFFFF00
- #define SCOLOR_MARKER 0xD90000FF
- new Float:PrisonerRandomSpawns[4][3] = {
- {2835.6602,3203.8933,4.5640},
- {2835.6602,3203.8933,4.5640},
- {2835.6602,3203.8933,4.5640},
- {2835.6602,3203.8933,4.5640}
- };
- new Float:GuardRandomSpawns[4][3] = {
- {2909.9231,3149.5176,3.6151},
- {2909.9231,3149.5176,3.6151},
- {2909.9231,3149.5176,3.6151},
- {2909.9231,3149.5176,3.6151}
- };
- #if defined filterscript
- public OnFilterScriptInIt()
- {
- print("\n--------------------------------------");
- print(" Blank Filterscript by your name here");
- print("--------------------------------------\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- #else
- main()
- {
- print("\n-----------------------------------------------------");
- print("Team Deathmatch, Created by Kris Yellow.");
- print("If your not Kris Yellow & you see this message, go die.");
- print("-------------------------------------------------------\n");
- }
- #endif
- public OnGameModeInit()
- {
- // Don't use these lines if it's a filterscript
- SetGameModeText("TDM v1.1");
- AddPlayerClass(287, 2835.6602,3203.8933,4.5640,236.2004, 0, 0, 0, 0, 0, 0);
- AddPlayerClass(50, 2909.9231,3149.5176,3.6151,16.7188, 0, 0, 0, 0, 0, 0);
- CreateObject(16113, 2798, 3142.8999023438, 2.9000000953674, 0, 0, 0);
- CreateObject(16118, 2879.3000488281, 3126.3000488281, -1.2000000476837, 0, 0, 270);
- CreateObject(16122, 2791.3999023438, 3237.6000976563, 0.89999997615814, 0, 0, 20);
- CreateObject(16120, 2820.3000488281, 3299.8000488281, 3.5, 0, 0, 270);
- CreateObject(16118, 2795.6000976563, 3180.6999511719, 2.2999999523163, 0, 0, 0);
- CreateObject(16118, 2838.599609375, 3123.599609375, -1.2999999523163, 0, 0, 269.99450683594);
- CreateObject(16118, 2954.6999511719, 3203.5, 2.7999999523163, 0, 0, 220);
- CreateObject(16118, 2910, 3128.7998046875, -1.2000000476837, 0, 0, 269.99450683594);
- CreateObject(16118, 2961, 3129.2998046875, 0, 0, 0, 90);
- CreateObject(16118, 2968.599609375, 3163.099609375, 0.10000000149012, 0, 0, 179.99450683594);
- CreateObject(16327, 2949.3994140625, 3166.19921875, 3.2000000476837, 0, 0, 180);
- CreateObject(16327, 2822.1999511719, 3169.3999023438, 3.2000000476837, 0, 0, 0);
- CreateObject(6205, 2879.8000488281, 3175.3000488281, 11.300000190735, 0, 0, 90);
- CreateObject(16118, 2917.3000488281, 3242.6999511719, 6.4000000953674, 0, 0, 219.99572753906);
- CreateObject(16118, 2902.6999511719, 3264.6999511719, 5.6999998092651, 0, 0, 250);
- CreateObject(7046, 2926.5, 3251.8000488281, 4.4000000953674, 0.999755859375, 0, 0);
- CreateObject(16120, 2855.3000488281, 3291.1999511719, 2.2999999523163, 0, 0, 24);
- CreateObject(16327, 2822.19921875, 3169.3994140625, 3.2000000476837, 0, 0, 0);
- CreateObject(6295, 2832.8000488281, 3274.6000976563, 28.5, 0, 0, 200);
- CreateObject(5309, 2856.3000488281, 3217, 8.8000001907349, 0, 0, 0);
- CreateObject(3928, 2838.7958984375, 3216.8115234375, 13.138463973999, 0, 0, 0);
- CreateObject(373, 2905.3999023438, 3176.1999511719, 3.2999999523163, 0, 0, 0);
- CreateObject(1240, 2905.3000488281, 3177.1000976563, 3.2999999523163, 0, 0, 0);
- Create3DTextLabel("Use /building to enter the building.", 0xAA3333AA, 2902.9429,3163.3945,3.8573, 30.0, 0, 0);
- Create3DTextLabel("Use /leave to leave the building.", 0xAA3333AA, 1403.1464,5.7318,1000.9064, 30.0, 0, 0);
- Create3DTextLabel("Use /building to go up the tower.", 0xAA3333AA, 2825.7295,3169.5178,3.9641, 30.0, 0, 0); //tower1
- Create3DTextLabel("Use /leave to go down the tower.", 0xAA3333AA, 2822.8540,3169.4224,14.2436, 30.0, 0, 0); //tower1
- Create3DTextLabel("Use /building to go up the tower.", 0xAA3333AA, 2945.9050,3166.4016,3.9097, 30.0, 0, 0); //tower2
- Create3DTextLabel("Use /leave to go down the tower.", 0xAA3333AA, 2949.1851,3166.5325,14.2436, 30.0, 0, 0); //tower2
- Create3DTextLabel("Use /building to go up the tower.", 0xAA3333AA, 2834.3372,3270.9084,7.2224, 30.0, 0, 0); //lighthouse
- Create3DTextLabel("Use /leave to go down the tower.", 0xAA3333AA, 2832.7791,3274.3074,49.9688, 30.0, 0, 0); //lighthouse
- Create3DTextLabel("Use /buy for a list of available items to purchase.", 0x00FFFFFF, 2906.3232,3178.5508,4.1217, 30.0, 0, 0); //lighthouse
- {
- UsePlayerPedAnims();
- }
- return 1;
- }
- public OnGameModeExit()
- {
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid)
- {
- SetPlayerPos(playerid,2812.2883,3180.3645,4.1534);
- SetPlayerCameraPos(playerid,2817.0037,3180.6880,4.1590);
- SetPlayerCameraLookAt(playerid,2820.5540,3180.8335,4.1616);
- SetPlayerFacingAngle(playerid, 180);
- ApplyAnimation(playerid,"DANCING","dnce_M_a",4.0,1,0,0,0,0);
- switch(classid)
- {
- case 0:
- {
- SetPlayerTeam(playerid, Prisoners);
- GameTextForPlayer(playerid, "~b~Prisoners", 1000, 3);
- }
- case 1:
- {
- SetPlayerTeam(playerid, Guards);
- GameTextForPlayer(playerid, "~r~Guards", 1000, 3);
- }
- }
- return 1;
- }
- public OnPlayerConnect(playerid)
- {
- new name[MAX_PLAYER_NAME+1], string[24+MAX_PLAYER_NAME+1];
- GetPlayerName(playerid, name, sizeof(name));
- format(string, sizeof(string), "Welcome to Team Deathmatch, %s.", name);
- SendClientMessage(playerid,0xFFFFFFAA, string);
- format(string, sizeof(string), "%s has now joined the server.", name);
- SendClientMessageToAll(0xFFFFFFAA, string);
- SendClientMessage(playerid, 0x00FFFFFF, "Please select a team then spawn.");
- SendClientMessage(playerid, 0x00FFFFFF, "Use /cmds for a list of available commands. Use /weapons for weapon tiers.");
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason)
- {
- new
- string[64],
- name[MAX_PLAYER_NAME];
- GetPlayerName(playerid,name,MAX_PLAYER_NAME);
- switch(reason)
- {
- case 0: format(string,sizeof string,"%s has left the server. (Time Out)",name);
- case 1: format(string,sizeof string,"%s has left the server. (Leaving)",name);
- case 2: format(string,sizeof string,"%s has left the server. (Kicked/Banned)",name);
- }
- SendClientMessageToAll(0xFFFFFFAA,string);
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- if(GetPlayerTeam(playerid) == Prisoners)
- {
- SetPlayerColor(playerid, PrisonersColor);
- SetPlayerRandomPrisonerSpawn(playerid);
- }
- else if(GetPlayerTeam(playerid) ==Guards)
- {
- SetPlayerColor(playerid, GuardsColor);
- SetPlayerRandomGuardSpawn(playerid);
- }
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- ResetPlayerWeapons(playerid);
- SendClientMessage(playerid, 0xFF66FFAA, "You have died and therfore lost $1000.");
- GivePlayerMoney(playerid, -1000);
- if(playerid != INVALID_PLAYER_ID) SetPlayerScore(playerid, GetPlayerScore(playerid) - 1);
- SetPlayerPos(playerid,2819.9048,3189.3564,4.3103);
- SetPlayerInterior(playerid, 0);
- new name[MAX_PLAYER_NAME+1], string[24+MAX_PLAYER_NAME+1];
- GetPlayerName(playerid, name, sizeof(name));
- format(string, sizeof(string), "You have killed %s and earnt $2500.", name);
- SendClientMessage(killerid, 0xFF66FFAA, string);
- GivePlayerMoney(killerid, 2500);
- if(killerid != INVALID_PLAYER_ID) SetPlayerScore(killerid, GetPlayerScore(killerid) + 1);
- return 1;
- }
- public OnVehicleSpawn(vehicleid)
- {
- return 1;
- }
- public OnVehicleDeath(vehicleid, killerid)
- {
- return 1;
- }
- public OnPlayerText(playerid,text[])
- {
- if(text[0] == '#')
- {
- new string[128]; GetPlayerName(playerid, string, sizeof(string));
- format(string, sizeof(string), "[Team] %s: %s", string, text[1]);
- printf("%s", string);
- for(new i = 0; i < MAX_PLAYERS; i++)
- {
- if(IsPlayerConnected(i) && GetPlayerTeam(i) == GetPlayerTeam(playerid)) SendClientMessage(i, GetPlayerColor(playerid), string);
- }
- return 0;
- }
- return 1;
- }
- CMD:lspd(playerid, params[])
- {
- SetPlayerPos(playerid, 1543.4667,-1676.3910,13.5565); //Quick CMD to TP me to LSPD for CCTV shit
- }
- CMD:removenos(playerid, params[])
- {
- if(!IsPlayerInAnyVehicle(playerid))
- {
- SendClientMessage(playerid,COLOR_RED,"Error: You are not in a vehicle.");
- }
- else
- {
- new vid = GetPlayerVehicleID(playerid);
- RemoveVehicleComponent(vid, 1010); //10x nos
- RemoveVehicleComponent(vid, 1009); //2x nos
- RemoveVehicleComponent(vid, 1008); //5x nos
- }
- return 1;
- }
- CMD:nos(playerid, params[])
- {
- if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,COLOR_RED,"Error: You are not in a vehicle.");
- {
- new vid = GetPlayerVehicleID(playerid);
- AddVehicleComponent(vid, 1010);
- PlayerPlaySound(playerid,1133,0.0,0.0,0.0);
- return 1;
- }
- }
- CMD:veh(playerid, params[])
- {
- ShowPlayerDialog(playerid, 4, DIALOG_STYLE_LIST, "Vehicle Menu", "Cheetah\nBanshee\nBullet\nHydra", "Select", "Cancel");
- return 1;
- }
- CMD:hq(playerid, params[])
- {
- if(IsPlayerInRangeOfPoint(playerid, 200, 2869.8030,3190.5867,4.3318))
- {
- SendClientMessage(playerid, 0xFF66FFAA, "You are already at base.");
- }
- else
- {
- SetPlayerPos(playerid,2869.8030,3190.5867,4.3318);
- }
- return 1;
- }
- CMD:fixvw(playerid, params[])
- {
- if(GetPlayerVirtualWorld(playerid) < 1)
- {
- SetPlayerVirtualWorld(playerid, 0);
- SendClientMessage(playerid, 0xFF66FFAA, "Your virtual world was fixed.");
- }
- else
- {
- SendClientMessage(playerid, 0xFF66FFAA, "Your virtual world is not bugged.");
- }
- }
- CMD:building(playerid, params[])
- {
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2902.7942, 3163.8582, 3.8653))
- {
- SetPlayerInterior(playerid,1);
- SetPlayerPos(playerid,1398.7748,-21.3895,1000.9068);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2825.7295,3169.5178,3.9641))
- {
- SetPlayerInterior(playerid,0);
- SetPlayerPos(playerid, 2822.8540,3169.4224,14.2436);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2945.9050,3166.4016,3.9097))
- {
- SetPlayerInterior(playerid,0);
- SetPlayerPos(playerid, 2949.1851,3166.5325,14.2436);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2834.3372,3270.9084,7.2224))
- {
- SetPlayerInterior(playerid,0);
- SetPlayerPos(playerid, 2832.7791,3274.3074,49.9688);
- }
- return 1;
- }
- CMD:leave(playerid, params[])
- {
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 1402.4431,6.1827,1000.9063))
- {
- SetPlayerInterior(playerid,0);
- SetPlayerPos(playerid,2902.6458,3163.9446,3.8669);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2822.8540,3169.4224,14.2436))
- {
- SetPlayerInterior(playerid, 0);
- SetPlayerPos(playerid, 2825.7295,3169.5178,3.9641);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2949.1851,3166.5325,14.2436))
- {
- SetPlayerInterior(playerid, 0);
- SetPlayerPos(playerid, 2945.9050,3166.4016,3.9097);
- }
- if(IsPlayerInRangeOfPoint(playerid, 4.0, 2832.7791,3274.3074,49.9688))
- {
- SetPlayerInterior(playerid, 0);
- SetPlayerPos(playerid, 2834.3372,3270.9084,7.2224);
- }
- return 1;
- }
- CMD:buy(playerid, params[])
- {
- if(IsPlayerInRangeOfPoint(playerid, 5.0, 2906.3232,3178.5508,4.1217))
- {
- ShowPlayerDialog(playerid, 1, DIALOG_STYLE_LIST, "Available Items", "Health (100) - $2000\nArmour(100) - $4000", "Purchase", "Cancel");
- }
- else
- {
- ShowPlayerDialog(playerid, 2, DIALOG_STYLE_MSGBOX, "Checkpoint Marker", "You are not in range to the /buy point,\nWould you like a marker to show where it is?", "Yes", "No");
- }
- return 1;
- }
- CMD:weapons(playerid, params[])
- {
- ShowPlayerDialog(playerid, 3, DIALOG_STYLE_LIST, "Weapons Tier", "Weapons Set 1\nWeapons Set 2\nWeapons Set 3", "Equip","Close");
- return 1;
- }
- CMD:cmds(playerid, params[])
- {
- SendClientMessage(playerid, 0x00FFFFFF, "");
- SendClientMessage(playerid, 0x00FFFFFF, "List of available commands: (Version v1.1)");
- SendClientMessage(playerid, 0x00FFFFFF, "__________________________________________________________________________________________________________________");
- SendClientMessage(playerid, 0x00FFFFFF, "");
- SendClientMessage(playerid, 0x00FFFFFF, "| /building | /leave | /hq | /fixvw | /weapons | /buy | /destroycar | /veh | /version | /fix | /nos | /removenos |");
- SendClientMessage(playerid, 0x00FFFFFF, "| /attachments |");
- SendClientMessage(playerid, 0x00FFFFFF, "__________________________________________________________________________________________________________________");
- SendClientMessage(playerid, 0x00FFFFFF, "");
- return 1;
- }
- CMD:admincmds(playerid, params[])
- {
- if (IsPlayerAdmin(playerid))
- {
- SendClientMessage(playerid, COLOR_RED, "Admin Commands: /givemoney /fine /specplayer /specvehicle /specoff");
- return 1;
- }
- else
- {
- SendClientMessage(playerid, COLOR_RED, "You are not an admin!");
- return 1;
- }
- }
- CMD:destroycar(playerid, params[])
- {
- new currentveh;
- currentveh = GetPlayerVehicleID(playerid);
- DestroyVehicle(currentveh);
- return 1;
- }
- CMD:version(playerid, params[])
- {
- ShowPlayerDialog(playerid, 5, DIALOG_STYLE_MSGBOX, "Version V2", "\nTransfered script from STRCMP to zCMD (Complete)\nAdded & Perfected /nos & /removenos\nAdded objects, /attachments (Filterscript)\nAdded a Killspree system", "Close", "");
- return 1;
- }
- CMD:fix(playerid, params[])
- {
- if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_RED, "You are not in a vehicle!");
- RepairVehicle(GetPlayerVehicleID(playerid));
- SendClientMessage(playerid, COLOR_RED, "You have repaired your vehicle.");
- return 1;
- }
- CMD:givemoney(playerid, params[])
- {
- if (IsPlayerAdmin(playerid))
- {
- new
- toplayerid,
- amount;
- if (!sscanf(params, "ii", toplayerid, amount))
- {
- if (toplayerid != INVALID_PLAYER_ID)
- {
- new
- message[40];
- GivePlayerMoney(toplayerid, amount);
- format(message, sizeof(message), "You received $%d from an admin.", amount);
- SendClientMessage(toplayerid, 0x00FF00FF, message);
- }
- else SendClientMessage(playerid, 0xFF0000FF, "Error: Player is not active.");
- }
- else SendClientMessage(playerid, COLOR_GRAD1, "Usage: /givemoney <playerid> <amount>");
- }
- else SendClientMessage(playerid, 0xFF0000FF, "Error: Only administrators can use this command.");
- return 1;
- }
- CMD:fine(playerid, params[])
- {
- if (IsPlayerAdmin(playerid))
- {
- new
- toplayerid,
- amount;
- if (!sscanf(params, "ii", toplayerid, amount))
- {
- if (toplayerid != INVALID_PLAYER_ID)
- {
- new
- message[41];
- GivePlayerMoney(toplayerid, -amount);
- format(message, sizeof(message), "You have been fined $%d by an admin.", amount);
- SendClientMessage(toplayerid, 0x00FF00FF, message);
- }
- else SendClientMessage(playerid, 0xFF0000FF, "Error: Player is not active.");
- }
- else SendClientMessage(playerid, COLOR_GRAD1, "Usage: /fine <playerid> <amount>");
- }
- else SendClientMessage(playerid, 0xFF0000FF, "Error: Only administrators can use this command.");
- return 1;
- }
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
- {
- return 1;
- }
- public OnPlayerExitVehicle(playerid, vehicleid)
- {
- DestroyVehicle(vehicleid);
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate)
- {
- return 1;
- }
- public OnPlayerEnterCheckpoint(playerid)
- {
- DisablePlayerCheckpoint(playerid);
- return 1;
- }
- public OnPlayerLeaveCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerEnterRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerLeaveRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnRconCommand(cmd[])
- {
- return 1;
- }
- public OnPlayerRequestSpawn(playerid)
- {
- return 1;
- }
- public OnObjectMoved(objectid)
- {
- return 1;
- }
- public OnPlayerObjectMoved(playerid, objectid)
- {
- return 1;
- }
- public OnPlayerPickUpPickup(playerid, pickupid)
- {
- return 1;
- }
- public OnVehicleMod(playerid, vehicleid, componentid)
- {
- return 1;
- }
- public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
- {
- return 1;
- }
- public OnVehicleRespray(playerid, vehicleid, color1, color2)
- {
- return 1;
- }
- public OnPlayerSelectedMenuRow(playerid, row)
- {
- return 1;
- }
- public OnPlayerExitedMenu(playerid)
- {
- return 1;
- }
- public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
- {
- return 1;
- }
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
- {
- return 1;
- }
- public OnRconLoginAttempt(ip[], password[], success)
- {
- return 1;
- }
- public OnPlayerUpdate(playerid)
- {
- return 1;
- }
- public OnPlayerStreamIn(playerid, forplayerid)
- {
- return 1;
- }
- public OnPlayerStreamOut(playerid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamIn(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamOut(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- if(dialogid == 1)
- {
- if(response)
- {
- if(listitem ==0)
- {
- if(GetPlayerMoney(playerid) < 1999)
- {
- SendClientMessage(playerid, 0x00FF00FF, "You need $2000.");
- }
- else
- {
- SetPlayerHealth(playerid, 100);
- GivePlayerMoney(playerid, -2000);
- SendClientMessage(playerid, 0x00FF00FF, "Health Refilled.");
- }
- }
- if(listitem ==1)
- {
- if(GetPlayerMoney(playerid) < 3999)
- {
- SendClientMessage(playerid, 0x00FF00FF, "You need $4000.");
- }
- else
- {
- SetPlayerArmour(playerid, 100);
- GivePlayerMoney(playerid, -4000);
- SendClientMessage(playerid, 0x00FF00FF, "Armour Refilled.");
- }
- }
- }
- }
- if(dialogid == 2)
- {
- if(response)
- {
- SetPlayerCheckpoint(playerid, 2906.7595,3178.9297,4.1284, 2.0);
- }
- }
- if(dialogid == 3)
- {
- if(response)
- {
- if(listitem == 0)
- {
- ResetPlayerWeapons(playerid);
- SendClientMessage(playerid, 0xFF0000AA, "You have selected tier 1.");
- GivePlayerWeapon(playerid, 4, 1);
- GivePlayerWeapon(playerid, 22, 9999999);
- GivePlayerWeapon(playerid, 25, 9999999);
- GivePlayerWeapon(playerid, 34, 9999999);
- GivePlayerWeapon(playerid, 16, 2);
- }
- if(listitem == 1)
- {
- ResetPlayerWeapons(playerid);
- SendClientMessage(playerid, 0xFF0000AA, "You have selected tier 2.");
- GivePlayerWeapon(playerid, 9, 1);
- GivePlayerWeapon(playerid, 24, 99999999);
- GivePlayerWeapon(playerid, 28, 99999999);
- GivePlayerWeapon(playerid, 25, 99999999);
- }
- if(listitem == 2)
- {
- ResetPlayerWeapons(playerid);
- SendClientMessage(playerid, 0xFF0000AA, "You have selected tier 3.");
- GivePlayerWeapon(playerid, 8, 1);
- GivePlayerWeapon(playerid, 24, 99999999);
- GivePlayerWeapon(playerid, 27, 99999999);
- GivePlayerWeapon(playerid, 31, 99999999);
- GivePlayerWeapon(playerid, 39, 3);
- }
- }
- }
- if(dialogid ==4)
- {
- if(listitem ==0)
- {
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid,x,y,z);
- CreateVehicle(415,x-3.0,y,z, 0.0, 1,1,15);
- return 1;
- }
- if(listitem ==1)
- {
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid,x,y,z);
- CreateVehicle(429,x-3.0,y,z, 0.0, 1,1,15);
- return 1;
- }
- if(listitem ==2)
- {
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid,x,y,z);
- CreateVehicle(541,x-3.0,y,z, 0.0, 1,1,15);
- return 1;
- }
- if(listitem ==3)
- {
- if(GetPlayerScore(playerid) < 30)
- {
- SendClientMessage(playerid, COLOR_RED, "You need a minimum score of 30 to use this.");
- }
- else
- {
- new Float:x, Float:y, Float:z;
- GetPlayerPos(playerid,x,y,z);
- CreateVehicle(520,x-3.0,y,z, 0.0, 1,1,15);
- return 1;
- }
- }
- else
- {
- SendClientMessage(playerid, COLOR_GRAD1, "You have canceled the vehicle dialog menu.");
- }
- }
- return 1;
- }
- public OnPlayerClickPlayer(playerid, clickedplayerid, source)
- {
- return 1;
- }
- forward SetPlayerRandomPrisonerSpawn(playerid);
- public SetPlayerRandomPrisonerSpawn(playerid)
- {
- new rand = random(sizeof(PrisonerRandomSpawns));
- SetPlayerPos(playerid, PrisonerRandomSpawns[rand][0], PrisonerRandomSpawns[rand][1], PrisonerRandomSpawns[rand][2]);
- return 1;
- }
- forward SetPlayerRandomGuardSpawn(playerid);
- public SetPlayerRandomGuardSpawn(playerid)
- {
- new rand = random(sizeof(GuardRandomSpawns));
- SetPlayerPos(playerid, GuardRandomSpawns[rand][0], GuardRandomSpawns[rand][1], GuardRandomSpawns[rand][2]);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement