[FilterScript] Sistema de GPS
#1

Olб.. eu sempre busquei sistemas de GPS pro meu servidor, porem nunca encontrei um que realmente me ajuda-se, entгo decidi criar um eu mesmo..

Код:
#include <a_samp>

#pragma tabsize 0
#define GPS 7505

public OnPlayerCommandText(playerid, cmdtext[])
{
    if(!strcmp("/gps", cmdtext, true))
{
       ShowPlayerDialog(playerid, GPS, DIALOG_STYLE_LIST, "TITULO DO DIALOG", "LOCAL 1 \nLOCAL 2", "Selecionar", "Cancelar");
       return 1;
}

	return 0;
}

// PARA CRIAR MAIS LOCAIS, BASTA COPIAR, COLAR E ADICIONAR O LOCAL NA DIALOG, NUNCA ESQUECENDO DE ALTERAR O LISTITEM PARA O NUMERO SEGUINTE AO ANTERIOR..

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
   if(dialogid == GPS)
   {
      if(response)
      {
          if(listitem == 0) // LOCAL 1
          {
                SetPlayerCheckpoint(playerid, x,y,z,8.0); // COLOQUE SUA CORDENADA.. || 8.0 = Distancia da Identificaзгo
                SendClientMessage(playerid, 0xFFFFFFAA, "Foi criado um Checkpoint em seu mapa..");
                return 1;
          }
          if(listitem == 1) // LOCAL 2
          {
                SetPlayerCheckpoint(playerid, x,y,z,8.0); // COLOQUE SUA CORDENADA.. || 8.0 = Distancia da Identificaзгo
                SendClientMessage(playerid, 0xFFFFFFAA, "Foi criado um Checkpoint em seu mapa..");
                return 1;
          }
           }
       }
	return 0;
}

public OnPlayerEnterCheckpoint(playerid)
{
    DisablePlayerCheckpoint(playerid); // Destroi o CheckPoint Ao Ficar Encima do Mesmo..
    return true;
}

//                             SISTEMA DE GPS                                 //

//--------------------------------CREDITOS------------------------------------//

//------------------------- -...MarcoAurelio...-------------------------------//

//-----------------------------...ipsLeon...----------------------------------//

//DEIXAR SEMPRE O ULTIMO RETURN DA PUBLIC ONDIALOGRESPONSE NO VALOR 0(FALSE):D//

//----------------------------------------------------------------------------//
//                             FAЗA BOM USO :D                                //
Espero que gostem..

Credits: MarcoAurelio | ipsLeon
Reply


Messages In This Thread
Sistema de GPS - by MarcoAurelio - 22.09.2015, 21:00
Re: Sistema de GPS - by .Skool_. - 22.09.2015, 21:47
Re: Sistema de GPS - by MarcoAurelio - 22.09.2015, 23:31
Re: Sistema de GPS - by MkeY - 23.09.2015, 04:21
Re: Sistema de GPS - by MarcoAurelio - 23.09.2015, 06:55
Re: Sistema de GPS - by Sky™ - 24.09.2015, 13:17
Re: Sistema de GPS - by MarcoAurelio - 24.09.2015, 16:55

Forum Jump:


Users browsing this thread: 1 Guest(s)