[ajuda]Raio de comando
#1

eu meti isto assim:
pawn Код:
GameTextForPlayer(playerid,"Faзa /curar, e fique com a vida toda",0,0);
    if(strcmp(cmd, "/curar", true) == 0) {
        SendPlayerFormattedText(playerid,"Foste curado/a por 500$",0);
        SetPlayerHealth(playerid,55);
      GameTextForPlayer(playerid,"Estas curado/a.",5000,5);
      GivePlayerMoney(playerid, -500);
  return 0;
    }
para quando o player chegasse ao pй do pickup aparecesse "Faзa /curar, e fique com a vida toda", depois ele fizesse /curar e ficava com a vida toda, mas quando ele chega ao pй do pickup faz automaticamente, sem o comando
Reply
#2

usa if(IsPlayerInRangeOfPoint
Reply
#3

pawn Код:
if(strcmp(cmd, "/curar" , true) == 0)
  {
    if(IsPlayerInRangeOfPoint(playerid, 5.0, CORD X DO PICKUP AQUI, CORD Y DO PICKUP AQUI, CORD Z DO PICKUP AQUI))
    {
      SendClientMessage(playerid,COR_AQUI,"Foste curado/a por 500$");
      SetPlayerHealth(playerid,55);
      GivePlayerMoney(playerid, -500);
    }
    else
    {
      SendClientMessage(playerid, COR_AQUI, " Vocк nгo estб no ponto de cura ");
      return 1;
    }
    return 1;
  }
Reply
#4

Vocк pode criar um pickup por exemplo: Aquele "i" de informaзгo e adicionar essa mensagem "Faзa /curar, e fique com a vida toda" ae o jogador sу serб curado quando digitar o comando /curar.......Se for aquele coraзгo ele enche a vida automatico....
Reply
#5

Obrigado, mas o andmeida10 jб me ajudou.
Mas tenho outra duvida como fazer isso mas com um raio maior?
Reply
#6

https://sampwiki.blast.hk/wiki/IsPlayerInRangeOfPoint


Quote:
playerid The ID of the player you want to check the point range of.
Float:range The furthest distance the player can be to be in range. -------------> RAIO
Float The X coordinate of the point to check the range to.
Float:y The Y coordinate of the point to check the range to.
Float:z The Z coordinate of the point to check the range to.

Reply
#7

sabes como mover no mta um objecto, tipo uma estrada inclinada, sу sei mexer nos objectos(para cima, para baixo, para os lados, e mudar de angulo) agora isso nгo sei
Reply
#8

ctrl+shift+setas
Reply
#9

E sobre isto alguem Percebeu como editar?
http://forum.sa-mp.com/index.php?topic=128075.30
Reply
#10

pega photoshop, e edita o ficheiro samp_gui da pasta do teu GTA San Andreas
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)