SA-MP Forums Archive
[Ajuda] Race Checkpoint - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Race Checkpoint (/showthread.php?tid=489142)



Race Checkpoint - xPaulistaa - 20.01.2014

Como pega as coordenadas corretas da mesma?

Eu peguei algumas, mas, estгo com as "setas" apontando pro lugar errado..


Re: Race Checkpoint - JonathanFeitosa - 20.01.2014

Type of checkpoint.0-Normal, 1-Finish, 2-Nothing(Only the checkpoint without anything on it), 3-Air normal, 4-Air finish
Fonte: Wiki

Код:
SetPlayerRaceCheckpoint(playerid,1,X13 ,X12, X12, X23, X23, X23, BlбJFS);
Eu fiz isso um dia desses, pode ajudar um pouco a estudar.

Entendendo o AutoPoints[Parametro 1][Parametro 2]


Seguinte, o SetPlayerRaceCheckpoint ler duas coordenadas. Veja um exemplo:

Vocк olha um code desses:
Код:
SetPlayerRaceCheckpoint(playerid, 0, AutoPoints[1][0], AutoPoints[1][1], AutoPoints[1][2],AutoPoints[2][0], AutoPoints[2][1], AutoPoints[2][2], 10);
[...]
E diz e agora

Entendendo o primeiro parametro do AutoPoint

Eu quero uma corrida de 5 Checkspoints, como fazer isso?

PHP код:
Checkpoint 1
Checkpoint 2
Checkpoint 3
Checkpoint 4
Checkpoint 5 
Veja como funciona:

Tabela
O inicio Checkpoint 1 e o prуximo Checkpoint 2
O inicio Checkpoint 2 e o proximo Checkpoint 3
O inicio Checkpoint 3 e o prуximo Checkpoint 4
O inicio Checkpoint 4 e o prуximo Checkpoint 5
O inicio Checkpoint 5 e o prуximo Checkpoint 5 ( SEMPRE NO ЪLTIMO REPETE 2X )


Код:
SetPlayerRaceCheckpoint(playerid, 0, AutoPoints[1][0], AutoPoints[1][1], AutoPoints[1][2],AutoPoints[2][0], AutoPoints[2][1], AutoPoints[2][2], 10);
[...]
Ai vocк se pergunta, porque 1, 1, 1, 2, 2 ,2 ? Foi como eu falei na tabela acima.
Mas porque repete 2 vezes? Simples, й por causa do segundo parвmetro.

Entendendo o segundo parвmetro do AutoPoint

Код:
SetPlayerRaceCheckpoint(playerid, 0, AutoPoints[1][0], AutoPoints[1][1], AutoPoints[1][2],AutoPoints[2][0], AutoPoints[2][1], AutoPoints[2][2], 10);
[...]
Porque sempre 0, 1, 2 ? Simples, sгo suas coordenadas do CheckPoint X Y Z que estгo definidas no GameMode.
Sempre serб 0, 1, 2.

Simples nгo? Aprimore seu conhecimento, й de graзa!
Veja esse sistema

PS: Tente aprender, qualquer coisa й sу falar


Re: Race Checkpoint - xPaulistaa - 20.01.2014

Quote:
Originally Posted by JonathanFeitosa
Посмотреть сообщение
Type of checkpoint.0-Normal, 1-Finish, 2-Nothing(Only the checkpoint without anything on it), 3-Air normal, 4-Air finish
Fonte: Wiki

Код:
SetPlayerRaceCheckpoint(playerid,1,X13 ,X12, X12, X23, X23, X23, BlбJFS);
Nгo era isso, mas, eu acabei de ver aqui, e aprendi ^^


Re: Race Checkpoint - FallweN - 20.01.2014

Estude isso https://sampwiki.blast.hk/wiki/SetPlayerRaceCheckpoint te ajudarб bastante


Re: Race Checkpoint - valdirdd - 20.01.2014

Faz o seguinte

Quote:

SetPlayerRaceCheckpoint(playerid, type, Float, Float:y, Float:z, Float:nextx, Float:nexty, Float:nextz, Floatize);

type й o modelo no checkpoint se vocк estб usando o da seta e o 0 que й o normal o que tem uma bandeira й o 1 que eo checkpoint de final da corrida
o Float, Float:y, Float:z й posiзгo onde vai criar o Checkpoint
Float:nextx, Float:nexty, Float:nextz й a posiзгo onde й o proximo checkpoint ou no caso pra onde a seta vai apontar
Floatize й o tamanho no checkpoint