Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*==============================================================================
- Credits
- ==============================================================================
- http://boylett.com/scripts/autoindent.php <--- For fixing 3 loose intended warnings, thus making the script look more neater and readable
- http://weedarr.wikidot.com/interior <--- For interior IDs
- http://wiki.sa-mp.com/ <--- For the usage of GameTextForPlayer,public OnDialogResponse and a lot more
- http://forum.sa-mp.com/showthread.php?t=91354 <--- Zeex For ZCMD
- http://forum.sa-mp.com/showthread.php?t=576114 <--- Yashas For I-ZCMD(which i used)*/
- //==============================================================================
- // Includes
- //==============================================================================
- #include <a_samp>
- #include <izcmd>
- #include <sscanf2>
- //==============================================================================
- // Defines
- //==============================================================================
- #define FILTERSCRIPT
- //_________________________________Options______________________________________
- #define ADMIN IsPlayerAdmin(playerid)//change line to match your admin system at the moment it is rcon admin
- #define ONLY_ADMIN true //Change true to false if you want every one to use the cmds
- #define TELE_DIALOG 7323//Change this number to change the dialog number
- //________________________________COLORS________________________________________
- #define RED 0xFF0000FF
- #define GREEN 0x00FF00FF
- #define BLUE 0x0000FFFF
- //_____________________________Short forms______________________________________
- #define SCM SendClientMessage
- #define VEH IsPlayerInAnyVehicle
- #define SPP SetPlayerPos
- #define SPI SetPlayerInterior
- #define GT GameTextForPlayer
- #define RPW ResetPlayerWeapons
- #if defined FILTERSCRIPT
- //==============================================================================
- // Call Backs
- //==============================================================================
- public OnFilterScriptInit()
- {
- print("\n===================================================================");
- print("____________Interior Teleport system by TURBO loading....____________");
- print("________Interior Teleport system by TURBO Successfully Loaded________");
- print("=====================================================================\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- print("\n===================================================================");
- print("____________Interior Teleport system by TURBO Unloading....____________");
- print("________Interior Teleport system by TURBO Successfully Unloaded________");
- print("=====================================================================\n");
- return 1;
- }
- #endif
- //commands
- CMD:intcredits(playerid,params[])
- {
- SCM(playerid,BLUE,"Interior Teleport System FS(filterscript)");
- SCM(playerid,BLUE,"Was made by Turbo");
- SCM(playerid,BLUE,"Special thanks to: http://weedarr.wikidot.com for interior ids");
- SCM(playerid,BLUE,"Special thanks to: Zeex for zcmd(Yashas for i-zcmd)");
- return 1;
- }
- CMD:inttele(playerid,params[])
- {
- #if ONLY_ADMIN == true
- if(!ADMIN) return 0;
- #endif
- ShowPlayerDialog(playerid,TELE_DIALOG,DIALOG_STYLE_LIST,"Interior Teleports","Shamal\nAndromeda\nAmmunation booths\nAmmunation range\nArea51\nlibertycityoutside\nlibertycityinside\nwarehouse 1\nwarehouse 2\nbank\ndirt track\npleasure domes\nbattle field\nSan Fierro Police HQ\nLos Santos Police HQ\nLas Ventras Police HQ\n8track\nBlood bowl\nKickstart\nHiddenroom","Select","Close");
- return 1;
- }
- CMD:intcmds(playerid,params[])
- {
- SCM(playerid,BLUE,"/inttele: Displays the list of teleports");
- SCM(playerid,BLUE,"/intcmds: Displays the interior teleport related commands");
- SCM(playerid,BLUE,"/killme: Kills yourself(once you teleport you cannot come back, use this cmd instead");
- SCM(playerid,BLUE,"/intcredits: Displays the credits of interior teleport");
- SCM(playerid,BLUE,"/adminkill: kills the player specified");
- return 1;
- }
- CMD:killme(playerid,params[])
- {
- SetPlayerHealth(playerid,0);
- SendClientMessage(playerid,RED,"You have killed your self");
- GameTextForPlayer(playerid,"~r~You killed your self",10000,2);
- return 1;
- }
- CMD:adminkill(playerid,params[])
- {
- if(!ADMIN) return 0;
- {
- new id,string[128];
- if(sscanf(params, "u", id)) return SCM(playerid,RED, "[ERROR]:/adminkill [ID]");
- if(!IsPlayerConnected(id)) return SCM(playerid,RED, "[ERROR]: Wrong ID!");
- SetPlayerHealth(id,0);
- GameTextForPlayer(id,"Admin killed you",10000,2);
- SCM(id,GREEN,"Admin has killed you");
- format(string,sizeof(string),"You killed player %s!",GetName(playerid));
- SCM(playerid,BLUE,string);
- format(string,sizeof(string),"[ADMIN]Has killed %s!",GetName(id));
- SendClientMessageToAll(GREEN,string);
- }
- return 1;
- }
- stock GetName(playerid)
- {
- new name[MAX_PLAYER_NAME];
- GetPlayerName(playerid, name, sizeof(name));
- return name;
- }
- CMD:gotopos(playerid, params[])
- {
- if(!ADMIN) return 0;
- new Float:POS[3];
- if(sscanf(params, "fff", POS[0], POS[1], POS[2])) return SendClientMessage(playerid,RED, "[ERROR]: /gotopos X Y Z (note just spaces no , or - between coordinates");
- SetPlayerPos(playerid, POS[0], POS[1], POS[2]);
- return 1;
- }
- // Functions of dialogs
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- if(dialogid == TELE_DIALOG)
- {
- if(response)
- {
- switch(listitem)
- {
- case 0:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,1.808619,32.384357,1199.59375);
- SPI(playerid,1);
- SCM(playerid,GREEN,"You have teleported to shamal interior successfully");
- GT(playerid,"~b~Welcome to~r~ shamal",5000,3);
- }
- }
- case 1:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,315.745086,984.969299,1958.919067);
- SPI(playerid,9);
- SCM(playerid,GREEN,"You have teleported to andromada interior successfully");
- GT(playerid,"~b~Welcome to~r~ andromada",5000,3);
- }
- }
- case 2:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,302.292877,-143.139099,1004.062500);
- SPI(playerid,7);
- SCM(playerid,GREEN,"You have teleported to ammunation booths successfully");
- GT(playerid,"~b~Welcome to~r~ ammunation booths",5000,3);
- }
- }
- case 3:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,298.507934,-141.647048,1004.054748);
- SPI(playerid,7);
- SCM(playerid,GREEN,"You have teleported to ammunation range successfully");
- GT(playerid,"~b~Welcome to~r~ ammunation range",5000,3);
- }
- }
- case 4:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,223.431976,1872.400268,13.73437);
- SPI(playerid,0);
- SCM(playerid,GREEN,"You have teleported to Area 51 successfully");
- GT(playerid,"~b~Welcome to~r~ area 51",5000,3);
- }
- }
- case 5:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-729.276000,503.086944,1371.971801);
- SPI(playerid,1);
- SCM(playerid,GREEN,"You have teleported to Liberty City Outside successfully");
- GT(playerid,"~b~Welcome to~r~ Liberty City ~n~ ~g~Outside",5000,3);
- }
- }
- case 6:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-794.806396,497.738037,1376.195312);
- SPI(playerid,1);
- SCM(playerid,GREEN,"You have teleported to Liberty City Inside successfully");
- GT(playerid,"~b~Welcome to~r~ Liberty City ~n~ ~g~Inside",5000,3);
- }
- }
- case 7:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,1412.639892,-1.787510,1000.924377);
- SPI(playerid,1);
- SCM(playerid,GREEN,"You have teleported to WareHouse 1 successfully");
- GT(playerid,"~b~Welcome to~r~ WareHouse 1",5000,3);
- }
- }
- case 8:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,1302.519897,-1.787510,1001.028259);
- SPI(playerid,18);
- SCM(playerid,GREEN,"You have teleported to WareHouse 2 successfully");
- GT(playerid,"~b~Welcome to~r~ WareHouse 2",5000,3);
- }
- }
- case 9:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,2315.952880,-1.618174,26.742187);
- SPI(playerid,0);
- SCM(playerid,GREEN,"You have teleported to Bank interior successfully");
- GT(playerid,"~b~Welcome to~r~ Bank",5000,3);
- }
- }
- case 10:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-1444.645507,-664.526000,1053.572998);
- SPI(playerid,4);
- SCM(playerid,GREEN,"You have teleported to Dirt Track successfully");
- GT(playerid,"~b~Welcome to~r~ Dirt Track",5000,3);
- }
- }
- case 11:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-2640.762939,1406.682006,906.460937);
- SPI(playerid,3);
- SCM(playerid,GREEN,"You have teleported to Pleasure Domes successfully");
- GT(playerid,"~b~Welcome to~r~ Pleasure Domes",5000,3);
- }
- }
- case 12:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-975.975708,1060.983032,1345.671875);
- SPI(playerid,10);
- SCM(playerid,GREEN,"You have teleported to RC battle field successfully");
- GT(playerid,"~b~Welcome to~r~ Battle field",5000,3);
- }
- }
- case 13:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,246.375991,109.245994,1003.218750);
- SPI(playerid,10);
- SCM(playerid,GREEN,"You have teleported to Sanfierro Police HQ successfully");
- GT(playerid,"~b~Welcome to~r~ SF Police HQ",5000,3);
- }
- }
- case 14:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,246.783996,63.900199,1003.640625);
- SPI(playerid,6);
- SCM(playerid,GREEN,"You have teleported to Los Santos Police HQ successfully");
- GT(playerid,"~b~Welcome to~r~ LS Police HQ",5000,3);
- }
- }
- case 15:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,288.745971,169.350997,1007.171875);
- SPI(playerid,3);
- SCM(playerid,GREEN,"You have teleported to Las Venturas Police HQ successfully");
- GT(playerid,"~b~Welcome to~r~ LV Police HQ",5000,3);
- }
- }
- case 16:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-1398.065307,-217.028900,1051.115844);
- SPI(playerid,7);
- SCM(playerid,GREEN,"You have teleported to 8-Track successfully");
- GT(playerid,"~b~Welcome to~r~ 8-Track",5000,3);
- }
- }
- case 17:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-1398.103515,937.631164,1036.479125);
- SPI(playerid,15);
- SCM(playerid,GREEN,"You have teleported to BloodBowl successfully");
- GT(playerid,"~b~Welcome to~r~ BloodBowl",5000,3);
- }
- }
- case 18:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,-1465.268676,1557.868286,1052.531250);
- SPI(playerid,14);
- SCM(playerid,GREEN,"You have teleported to KickStart successfully");
- GT(playerid,"~b~Welcome to~r~ KickStart",5000,3);
- }
- }
- case 19:
- {
- if(VEH(playerid))
- {
- SCM(playerid,RED,"[ERROR]:You cannot use this command while in a vehicle");
- }
- else
- {
- SPP(playerid,2131.507812,1600.818481,1008.359375);
- SPI(playerid,1);
- SCM(playerid,GREEN,"You have teleported to hidden room successfully");
- GT(playerid,"~b~Welcome to~r~ Hidden Room",5000,3);
- }
- }
- }
- return 1;
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement