Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Sistema de GPS com mapicon by GuiLopeS
- // Aproveitem bem essa fs é facil de entender!
- #define FILTERSCRIPT
- #include <a_samp>
- #include <zcmd>
- #if defined FILTERSCRIPT
- #define GPS 1777
- #define GPSL 1778
- #define GPSP 1779
- #define GPST 1780
- #define GPSH 1781
- #define GPSM 1782
- #define GPSG 1783
- #define CorGPSVerde 0x009059FF
- #else
- #endif
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- if(dialogid == GPS)
- {
- if(response)
- {
- if(listitem == 0)
- {
- ShowPlayerDialog(playerid, GPSL, DIALOG_STYLE_LIST, "{CCCCCC}Locais Diversos:", "{3366FF}Local para tirar licenças\n{3366FF}Prefeitura\n{3366FF}Base principal do servidor\n{3366FF}Departamento da Polícia", "Selecionar", "Voltar");
- }
- else if(listitem == 1)
- {
- ShowPlayerDialog(playerid, GPSP, DIALOG_STYLE_LIST, "{CCCCCC}Locais das profissões:", "{FF6600}Transportes\n{00C900}Honestas\n{FB0000}Mafia\n{E6E6E6}Governo", "Selecionar", "Voltar");
- }
- else if(listitem == 2)
- {
- RemovePlayerMapIcon(playerid, 69);
- SendClientMessage(playerid, -1, "{FF0000}!GPS Desligado!");
- }
- }
- }
- if(dialogid == GPSL)
- {
- if(response)
- {
- if(listitem == 0)
- {
- SetPlayerMapIcon(playerid, 69, 263.5748,1419.3909,10.6054, 41, 0, MAPICON_GLOBAL); //Licenças
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 1)
- {
- SetPlayerMapIcon(playerid, 69, 318.9544,870.1324,20.3990, 41, 0, MAPICON_GLOBAL); //Prefeitura
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 2)
- {
- SetPlayerMapIcon(playerid, 69, 45.1479,782.1489,39.0371, 41, 0, MAPICON_GLOBAL); //Base
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 3)
- {
- SetPlayerMapIcon(playerid, 69, 318.9544,870.1324,20.3990, 41, 0, MAPICON_GLOBAL); //Departamento da Polícia
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- }
- }
- if(dialogid == GPSP)
- {
- if(response)
- {
- if(listitem == 0)
- {
- ShowPlayerDialog(playerid, GPST, DIALOG_STYLE_LIST, "{CCCCCC}Escolha:", "{FFB300}Petroleiro\n{FFB300}Minerador\n{FFB300}Carregador\n{FFB300}Transportador\n{FFF600}Motorista de Carreta\n{80FFFF}Piloto", "Selecionar", "Voltar");
- }
- else if(listitem == 1)
- {
- ShowPlayerDialog(playerid, GPSH, DIALOG_STYLE_LIST, "{CCCCCC}Escolha:", "{FFF600}Taxista\n{696969}Mecânico\n{CD6839}Funcionário do Dnit\n{FF1493}Agênte dos Correios\n{00CD66}Motorista de Ônibus", "Selecionar", "Voltar");
- }
- else if(listitem == 2)
- {
- ShowPlayerDialog(playerid, GPSM, DIALOG_STYLE_LIST, "{CCCCCC}Escolha:", "{C90000}Mafia\n{C90000}Info", "Selecionar", "Voltar");
- }
- else if(listitem == 3)
- {
- ShowPlayerDialog(playerid, GPSG, DIALOG_STYLE_LIST, "{CCCCCC}Escolha:", "{B22222}Bombeiro\n{08008B}Policial\n{8B008B}Advogado\n{008B8B}Médico", "Selecionar", "Voltar");
- }
- }
- }
- if(dialogid == GPST)
- {
- if(response)
- {
- if(listitem == 0)
- {
- SetPlayerMapIcon(playerid, 69, 263.5748,1419.3909,10.6054, 41, 0, MAPICON_GLOBAL); //Petroleiro
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 1)
- {
- SetPlayerMapIcon(playerid, 69, 318.9544,870.1324,20.3990, 41, 0, MAPICON_GLOBAL); //Minerador
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 2)
- {
- SetPlayerMapIcon(playerid, 69, -504.6494,-559.7720,25.5234, 41, 0, MAPICON_GLOBAL); //Carregador
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 3)
- {
- SetPlayerMapIcon(playerid, 69, 2717.5540,-2496.4570,13.6641, 41, 0, MAPICON_GLOBAL); //Transportador
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 4)
- {
- SetPlayerMapIcon(playerid, 69, 1287.7468,-629.8488,14.1484, 41, 0, MAPICON_GLOBAL); //Motorista de Carreta
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 5)
- {
- SetPlayerMapIcon(playerid, 69, 1917.2087,-2641.4160,13.5469, 41, 0, MAPICON_GLOBAL); //Piloto
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- }
- }
- if(dialogid == GPSH)
- {
- if(response)
- {
- if(listitem == 0)
- {
- SetPlayerMapIcon(playerid, 69, -2041.9374,450.9368,35.1723, 41, 0, MAPICON_GLOBAL); //Taxista
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 1)
- {
- SetPlayerMapIcon(playerid, 69, -1898.1252,-1699.6882,21.7500, 41, 0, MAPICON_GLOBAL); //Mecanico
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 2)
- {
- SetPlayerMapIcon(playerid, 69, 161.1844,-22.6044,1.5781, 41, 0, MAPICON_GLOBAL); //Dnit
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 3)
- {
- SetPlayerMapIcon(playerid, 69, 2343.7930,2738.2839,10.8203, 41, 0, MAPICON_GLOBAL); //Correio
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 4)
- {
- SetPlayerMapIcon(playerid, 69, 1220.7992,-1814.7672,16.5938, 41, 0, MAPICON_GLOBAL); //Motorista de Onibus
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- }
- }
- if(dialogid == GPSM)
- {
- if(response)
- {
- if(listitem == 0)
- {
- SetPlayerMapIcon(playerid, 69, -368.7520,2219.4758,42.4912, 41, 0, MAPICON_GLOBAL); //Mafioso
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 1)
- {
- SendClientMessage(playerid, -1, "{B52600}[!]Novas profissões em desenvolvimento!");
- }
- }
- }
- if(dialogid == GPSG)
- {
- if(response)
- {
- if(listitem == 0)
- {
- SetPlayerMapIcon(playerid, 69, -2044.6509,59.6098,28.3906, 41, 0, MAPICON_GLOBAL); //Bombeiro
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 1)
- {
- SetPlayerMapIcon(playerid, 69, 1549.7046,-1633.5668,13.5451, 41, 0, MAPICON_GLOBAL); //Policia
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 2)
- {
- SetPlayerMapIcon(playerid, 69, 1473.1677,-1769.4954,18.7958, 41, 0, MAPICON_GLOBAL); //Advogado
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- else if(listitem == 3)
- {
- SetPlayerMapIcon(playerid, 69, 1179.2963,-1319.9264,14.1624, 41, 0, MAPICON_GLOBAL); //Medico
- SendClientMessage(playerid, CorGPSVerde, "!GPS: Vá até o local marcado no mapa!");
- }
- }
- }
- if(dialogid == GPSL)
- {
- if(!response) return ShowPlayerDialog(playerid, GPS, DIALOG_STYLE_LIST, "{009059}GPS - Servidor {FFFFFF}BRT ®", "{CCCCCC}Locais Diversos\nLocais das profissões\n{FF0000}Desligar GPS", "Selecionar", "Sair");
- }
- if(dialogid == GPSP)
- {
- if(!response) return ShowPlayerDialog(playerid, GPS, DIALOG_STYLE_LIST, "{009059}GPS - Servidor {FFFFFF}BRT ®", "{CCCCCC}Locais Diversos\nLocais das profissões\n{FF0000}Desligar GPS", "Selecionar", "Sair");
- }
- if(dialogid == GPST)
- {
- if(!response) return ShowPlayerDialog(playerid, GPSP, DIALOG_STYLE_LIST, "{CCCCCC}Locais das profissões:", "{FF6600}Transportes\n{00C900}Honestas\n{FB0000}Mafia\n{E6E6E6}Governo", "Selecionar", "Voltar");
- }
- if(dialogid == GPSH)
- {
- if(!response) return ShowPlayerDialog(playerid, GPSP, DIALOG_STYLE_LIST, "{CCCCCC}Locais das profissões:", "{FF6600}Transportes\n{00C900}Honestas\n{FB0000}Mafia\n{E6E6E6}Governo", "Selecionar", "Voltar");
- }
- if(dialogid == GPSM)
- {
- if(!response) return ShowPlayerDialog(playerid, GPSP, DIALOG_STYLE_LIST, "{CCCCCC}Locais das profissões:", "{FF6600}Transportes\n{00C900}Honestas\n{FB0000}Mafia\n{E6E6E6}Governo", "Selecionar", "Voltar");
- }
- if(dialogid == GPSG)
- {
- if(!response) return ShowPlayerDialog(playerid, GPSP, DIALOG_STYLE_LIST, "{CCCCCC}Locais das profissões:", "{FF6600}Transportes\n{00C900}Honestas\n{FB0000}Mafia\n{E6E6E6}Governo", "Selecionar", "Voltar");
- }
- return 1;
- }
- public OnPlayerClickPlayer(playerid, clickedplayerid, source)
- {
- return 1;
- }
- CMD:gps(playerid){
- ShowPlayerDialog(playerid, GPS, DIALOG_STYLE_LIST, "{009059}GPS - Servidor {FFFFFF}BRT ® By GuiLopeS", "{CCCCCC}Locais Diversos\nLocais das profissões\n{FF0000}Desligar GPS", "Selecionar", "Sair");
- return 1;
- }
- public OnPlayerUpdate(playerid)
- {
- if (IsPlayerInRangeOfPoint(playerid, 3.0, 263.5748,1419.3909,10.6054))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 318.9544,870.1324,20.3990))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 45.1479,782.1489,39.0371))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 318.9544,870.1324,20.3990))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 263.5748,1419.3909,10.6054))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 318.9544,870.1324,20.3990))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, -504.6494,-559.7720,25.5234))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 2717.5540,-2496.4570,13.6641))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1287.7468,-629.8488,14.1484))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1917.2087,-2641.4160,13.5469))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, -2041.9374,450.9368,35.1723))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, -1898.1252,-1699.6882,21.7500))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 161.1844,-22.6044,1.5781))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 2343.7930,2738.2839,10.8203))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1220.7992,-1814.7672,16.5938))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, -368.7520,2219.4758,42.4912))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, -2044.6509,59.6098,28.3906))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1549.7046,-1633.5668,13.5451))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1473.1677,-1769.4954,18.7958))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- else if (IsPlayerInRangeOfPoint(playerid, 3.0, 1179.2963,-1319.9264,14.1624))
- {
- RemovePlayerMapIcon(playerid, 69);
- }
- return 1;
- }
Add Comment
Please, Sign In to add comment