Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //----------------------------------[GOTO]-----------------------------------------------
- if(!strcmp(cmd,"/goto",true) || !strcmp(cmd,"/gotoid",true))
- {
- if(!(PlayerInfo[playerid][pAdmin] >= 2))
- return SendClientMessage(playerid, COLOR_GRAD2, "You are not authorized to use this command.");
- // process command
- tmp = strtok(cmdtext, idx);
- if(!strlen(tmp))
- {
- SendClientMessage(playerid, COLOR_WHITE,"USAGE: /goto [playerid] or /goto [place]");
- SendClientMessage(playerid, COLOR_WHITE,"Set your teleport destination with /mark");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( GENERAL: ls sf lvlsair sfair saints county gasstation VIP ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( GENERAL: mark ls sf lv lsair sfair saints county gasstation ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( GENERAL: tower chiliad airstrip bayside bank pier int1 bloodbowl ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( GENERAL: gym paintball 24/7 ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( OTHER: underwater jet battlefield 8track kickstart dirtbike dam ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( FACTIONS: hitman ss fbi rcsd demorgan ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( FAMILIES HQ: vla grove ballas rich ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( TUNE GARAGES: tune1 tune2 tune3 ))");
- SendClientMessage(playerid, COLOR_LIGHTRED,"(( POINTS: mp1 mf1 mp2 mf2 dh df cl sprunk ffc aec prison ))");
- return 1;
- }
- new
- p=1,
- Float:a = GetPlayerFacingAngle(playerid,a),
- destination[64] = " ",
- lookupid = ReturnUser(tmp);
- if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER) p=0;
- if(lookupid != INVALID_PLAYER_ID)
- {
- if(lookupid != playerid)
- {
- if(!gPlayerLogged[lookupid])
- return SendClientMessage(playerid, COLOR_GRAD2,"That player hasn't spawned yet.");
- if(GetPlayerState(lookupid) == PLAYER_STATE_SPECTATING)
- return SendClientMessage(playerid, COLOR_GRAD2,"That player is spectating someone.");
- }
- new
- Float:x,
- Float:y,
- Float:z,
- i = GetPlayerInterior(lookupid),
- v = GetPlayerVirtualWorld(lookupid);
- if(IsPlayerInAnyVehicle(lookupid))
- {
- GetVehicleZAngle(GetPlayerVehicleID(lookupid),a);
- } else {
- GetPlayerFacingAngle(lookupid,a);
- }
- GetPlayerPos(lookupid,x,y,z);
- Teleport(playerid,x,y+2,z,a,i,v,p);
- destination = PlayerName(lookupid);
- }
- else if(!strcmp(tmp,"lspd",true) || !strcmp(tmp,"ls",true))
- {
- destination = "Los Santos Police Department";
- Teleport(playerid,1529.6,-1691.2,13.3,a,0,0,p);
- }
- else if(!strcmp(tmp,"aryan",true))
- {
- destination = "Aryan Brotherhood HQ";
- Teleport(playerid, 2270.7239,-86.0490,26.5025,a,0,0,p);
- }
- else if(!strcmp(tmp,"int1",true))
- {
- destination = "Interior 1";
- Teleport(playerid,1411.1451,-0.5155,1000.9236,a,1,0,p);
- }
- else if(!strcmp(tmp,"gym",true))
- {
- destination = "Ganton Gym";
- Teleport(playerid,2225.4001,-1724.4464,13.5632,a,0,0,p);
- }
- else if(!strcmp(tmp,"lsair",true))
- {
- destination = "Los Santos Airport";
- Teleport(playerid,1934.9127,-2290.6362,13.5469,a,0,0,p);
- }
- else if(!strcmp(tmp,"sfair",true) || !strcmp(tmp,"sf",true))
- {
- destination = "San Fierro Airport";
- Teleport(playerid,-1417.0,-295.8,14.1,a,0,0,p);
- }
- else if(!strcmp(tmp,"lvair",true) || !strcmp(tmp,"lv",true))
- {
- destination = "Las Venturas Airport";
- Teleport(playerid,1699.2,1435.1, 10.7,a,0,0,p);
- }
- else if(!strcmp(tmp,"jet",true))
- {
- destination = "private jet";
- Teleport(playerid,1.71875, 30.4062, 1200.34,a,1,0,0);
- }
- else if (!strcmp(tmp,"chiliad",true))
- {
- destination = "Mt. Chiliad";
- Teleport(playerid,-2317.5325,-1644.9664,483.7031,a,0,0,p);
- }
- else if (!strcmp(tmp,"demorgan",true))
- {
- destination = "Area 51 - Demorgan";
- Teleport(playerid,202.1886,1881.4122,17.2199,37.8779,0,0,p);
- }
- else if (!strcmp(tmp,"airstrip",true))
- {
- destination = "Desert Airstrip";
- Teleport(playerid,357.5273,2513.8701,16.5856,a,0,0,p);
- }
- else if (!strcmp(tmp,"tower",true) || !strcmp(tmp,"sky",true))
- {
- destination = "Star Tower";
- Teleport(playerid,1543.9886,-1353.7587,329.4735,a,0,0,p);
- }
- else if (!strcmp(tmp,"bayside",true))
- {
- destination = "Bayside Heliport";
- Teleport(playerid,-2252.2944,2335.5396,4.8125,a,0,0,p);
- }
- else if (!strcmp(tmp,"underwater",true) || !strcmp(tmp,"under",true))
- {
- destination = "under the sea";
- Teleport(playerid,-1005.3044,657.4559,-39.0847,a,0,0,p);
- }
- else if (!strcmp(tmp,"bank",true))
- {
- destination = "The Bank";
- Teleport(playerid,1462.395751,-1016.391174,25.84375,a,0,0,p);
- }
- else if (!strcmp(tmp,"pier",true))
- {
- destination = "the fishing pier";
- Teleport(playerid,364.9920,-2059.7288,15.3990,a,0,0,p);
- }
- else if (!strcmp(tmp,"battlefield",true) || !strcmp(tmp,"battle",true))
- {
- destination = "the battlefield";
- Teleport(playerid,-972.4957,1060.9830,1345.6690,a,10,0,p);
- }
- else if (!strcmp(tmp,"dam",true))
- {
- destination = "the Sherman Dam";
- Teleport(playerid,-715.0000,2062.0000,60.0000,a,0,0,p);
- }
- else if (!strcmp(tmp,"bloodbowl",true))
- {
- destination = "Bloodbowl Arena";
- Teleport(playerid,-1394.5928,996.4797,1033.8864,a,15,0,p);
- }
- else if (!strcmp(tmp,"8track",true))
- {
- destination = "8-Track Stadium";
- Teleport(playerid,-1406.3815,-262.7644,1043.4290,346.8336,7,0,p);
- }
- else if (!strcmp(tmp,"dirtbike",true))
- {
- destination = "Dirtbike Stadium";
- Teleport(playerid,-1436.2065,-642.5217,1049.5261,167.3703,4,0,p);
- }
- else if (!strcmp(tmp,"kickstart",true))
- {
- destination = "Kickstart Stadium";
- Teleport(playerid,-1447.2618,1604.3374,1052.5220,263.7223,14,0,p);
- }
- else if (!strcmp(tmp,"hitman",true))
- {
- destination = "Hitman Agency - SF HQ";
- Teleport(playerid,-2535.1885,-688.6639,139.3203,335.7327,0,0,p);
- }
- else if (!strcmp(tmp,"ss",true))
- {
- destination = "Secret Society";
- Teleport(playerid,-51.5869,-275.1585,5.4297,353.7715,0,0,p);
- }
- else if (!strcmp(tmp,"fbi",true))
- {
- destination = "FBI Department";
- Teleport(playerid,1040.2537,1019.9399,11.0000,174.6930,0,0,p);
- }
- else if (!strcmp(tmp,"paintball",true))
- {
- destination = "Paintball Arena";
- Teleport(playerid,1798.1211,-1169.2134,23.8281,a,0,0,p);
- }
- else if (!strcmp(tmp,"24/7",true))
- {
- destination = "24/7 Store";
- Teleport(playerid,1314.5610,-913.7150,38.1331,a,0,0,p);
- }
- else if (!strcmp(tmp,"tune1",true))
- {
- destination = "Lowrider Tuning Shop";
- Teleport(playerid,2644.9026,-2005.4315,13.3828,a,0,0,p);
- }
- else if (!strcmp(tmp,"vip",true))
- {
- destination = "VIP";
- Teleport(playerid,1133.2164,-9.1820,1000.6797,a,12,0,p);
- }
- else if (!strcmp(tmp,"tune2",true))
- {
- destination = "Los Santos Tuning Shop";
- Teleport(playerid,1025.1035,-1039.0695,31.5661,a,0,0,p);
- }
- else if (!strcmp(tmp,"tune3",true))
- {
- destination = "San Fierro Tuning Shop";
- Teleport(playerid,-2702.4583,217.1397,4.1797,a,0,0,p);
- }
- else if (!strcmp(tmp,"mp1",true))
- {
- destination = "Material Pickup 1";
- Teleport(playerid,1430.8533,-1327.6997,13.5657,a,0,0,p);
- }
- else if (!strcmp(tmp,"mf1",true))
- {
- destination = "Material Factory 1";
- Teleport(playerid,2183.5547,-2279.0374,13.5469,a,0,0,p);
- }
- else if (!strcmp(tmp,"mp2",true))
- {
- destination = "Material Pickup 2";
- Teleport(playerid,2397.6951,-2012.1493,13.5537,a,0,0,p);
- }
- else if (!strcmp(tmp,"mf2",true))
- {
- destination = "Material Factory 2";
- Teleport(playerid,2289.1423,-1116.5608,37.9766,a,0,0,p);
- }
- else if (!strcmp(tmp,"dh",true))
- {
- destination = "Drug House";
- Teleport(playerid,2174.9119,-1669.4958,15.0716,a,0,0,p);
- }
- else if (!strcmp(tmp,"df",true))
- {
- destination = "Drug Factory";
- Teleport(playerid,53.8947,-284.2078,1.6548,a,0,0,p);
- }
- else if (!strcmp(tmp,"cl",true))
- {
- destination = "Crack Labaratory";
- Teleport(playerid,2360.7083,-1161.9872,27.6096,a,0,0,p);
- }
- else if (!strcmp(tmp,"sprunk",true))
- {
- destination = "Sprunk Factory";
- Teleport(playerid,1342.1078,286.7178,19.5615,a,0,0,p);
- }
- else if (!strcmp(tmp,"ffc",true))
- {
- destination = "Fossil Fuel Company";
- Teleport(playerid,2648.7205,-2109.0586,13.5469,a,0,0,p);
- }
- else if (!strcmp(tmp,"aec",true))
- {
- destination = "Auto Export Company";
- Teleport(playerid,2753.0408,-2433.9844,13.6484,a,0,0,p);
- }
- else if (!strcmp(tmp,"rcsd",true))
- {
- destination = "Sheriff's Department";
- Teleport(playerid,625.7545,-588.1606,16.7991,a,0,0,p);
- }
- else if (!strcmp(tmp,"rich",true))
- {
- destination = "Richmond";
- Teleport(playerid,393.7295,-1241.3582,52.0572,a,0,0,p);
- }
- else if (!strcmp(tmp,"county",true))
- {
- destination = "General County Hospital";
- Teleport(playerid,2002.0876,-1448.0087,13.5606,a,0,0,p);
- }
- else if (!strcmp(tmp,"saints",true))
- {
- destination = "All Saints Hospital";
- Teleport(playerid,1188.8627,-1330.2386,13.5606,a,0,0,p);
- }
- else if (!strcmp(tmp,"ballas",true))
- {
- destination = "Glen Park - Ballas";
- Teleport(playerid,1971.5403,-1147.4678,25.8117,a,0,0,p);
- }
- else if (!strcmp(tmp,"grove",true))
- {
- destination = "Grove Street";
- Teleport(playerid,2496.1221,-1670.3540,13.3359,a,0,0,p);
- }
- else if(!strcmp(tmp,"prison",true) || !strcmp(tmp,"ls",true))
- {
- destination = "Los Santos Prison";
- Teleport(playerid,2055.98,-2033.31,867.25,a,0,0,p);
- }
- else if (!strcmp(tmp,"vla",true))
- {
- destination = "Varrios Los Aztecas Bar";
- Teleport(playerid,2785.3215,-1610.6592,10.9219,a,0,0,p);
- }
- else
- {
- return SendClientMessage(playerid, COLOR_FADE1,"Invalid destination.");
- }
- // format string and send to player
- format(string, sizeof(string),"Teleporting to %s",destination);
- SendClientMessage(playerid, COLOR_GRAD2,string);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment