Advertisement
Pepito123

Untitled

Feb 14th, 2016
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.04 KB | None | 0 0
  1. new bool:IGPS // V.new
  2.  
  3. enum Info //Enum
  4. {
  5. IAdministrador,
  6. bool:IGPS
  7. };
  8.  
  9. new Informacion[MAX_PLAYERS][Info];
  10.  
  11. // El define
  12.  
  13. #define DIALOGO_GPS 1
  14.  
  15. // CMDgps editar.
  16.  
  17. CMD:gps(playerid, params[])
  18. {
  19. if(Informacion[playerid][IGPS] == true)
  20. {
  21. new str[150];
  22. format(str,sizeof(str),"%s mira su gps.",NombreSinGuion(playerid));
  23. ProxDetector(30.0, playerid, str, C_ROLEAR,C_ROLEAR,C_ROLEAR,C_ROLEAR,C_ROLEAR);
  24. ShowPlayerDialog(playerid, DIALOGO_GPS, DIALOG_STYLE_LIST, "GPS: Puntos de interés.", "Concesionarias\nBancos\n24/7\nTrabajos\nEdificios del gobierno\nTiendas de ropa\nVer mapa", "Siguiente", "Cerrar");
  25. }
  26. else SendClientMessage(playerid, -1, "No tenés un GPS, adquiere uno en un 24/7.");
  27. return 1;
  28. }
  29.  
  30. // Stock, si ya está, eliminar, lo puse por las dudas, carlo shamaja
  31. stock NombreSinGuion(playerid)
  32. {
  33. new string[24];
  34. GetPlayerName(playerid,string,24);
  35. new str[24];
  36. strmid(str,string,0,strlen(string),24);
  37. for(new i = 0; i < MAX_PLAYER_NAME; i++)
  38. {
  39. if (str[i] == '_') str[i] = ' ';
  40. }
  41. return str;
  42. }
  43. //Dialogo definido antes...
  44. if(dialogid == DIALOGO_GPS)
  45. {
  46. if(listitem == 0) //Concesionarias
  47. {
  48. SetPlayerCheckpoint(playerid, -2664.1511,260.4601,4.6328, 2);
  49. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  50. }
  51. if(listitem == 1) //Bancos
  52. {
  53. SetPlayerCheckpoint(playerid, -1712.8448,-9.8965,3.6359, 2);
  54. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  55. }
  56. if(listitem == 2) //24 7
  57. {
  58. SetPlayerCheckpoint(playerid, -2527.5630,210.6770,11.0938, 2);
  59. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  60. }
  61. if(listitem == 3) //Trabajos
  62. {
  63. SetPlayerCheckpoint(playerid, -1874.0024,-218.3038,18.3750, 2);
  64. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  65. }
  66. if(listitem == 4) //E. del gob.
  67. {
  68. SetPlayerCheckpoint(playerid, -1992.0472,374.2901,35.1719, 2);
  69. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  70. }
  71. if(listitem == 5) //Tiendas re ropa
  72. {
  73. SetPlayerCheckpoint(playerid, -2102.1704,-186.0735,35.3444, 2);
  74. SendClientMessage(playerid, -1, "Se marcó la ubicación en el mapa.");
  75. }
  76. if(listitem == 6) //Ver mapa
  77. {
  78. SendClientMessage(playerid, -1, "Agregar en pawno, lo que quieras acá.");
  79. DisablePlayerCheckpoint(playerid);
  80. }
  81. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement