SA-MP Forums Archive
CreateDynamicCP y definir Checkpoints IDs. - 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: Español/Spanish (https://sampforum.blast.hk/forumdisplay.php?fid=29)
+---- Thread: CreateDynamicCP y definir Checkpoints IDs. (/showthread.php?tid=423638)



CreateDynamicCP y definir Checkpoints IDs. - jwalker - 18.03.2013

Hola, estoy haciendo un sistema con checkpoints pero necesito definirlos por IDs a cada uno para que no se bugeen їcуmo harнa eso? La otra duda es como pasar esto:

PHP код:
SetPlayerCheckpoint(playerid1607.3693,1815.2408,10.82033.0); 
A CreateDynamicCP, que modificarle y que parбmetros agregarle para que no de error de tag mismatch.


Respuesta: CreateDynamicCP y definir Checkpoints IDs. - Fluid016 - 18.03.2013

pawn Код:
new chekcpoint;

checkpoint = SetPlayerCheckpoint(....);
Lo mismo con CreateDynamicCP, y que error te larga?


Respuesta: CreateDynamicCP y definir Checkpoints IDs. - jwalker - 18.03.2013

PHP код:
warning 213tag mismatch
 warning 204
symbol is assigned a value that is never used"checkpoint1" 
Cуdigo:

PHP код:
if(listitem == 0
{
new 
checkpoint1;
 
checkpoint1 CreateDynamicCP(playerid1607.3693,1815.2408,10.82033.0);




Respuesta: CreateDynamicCP y definir Checkpoints IDs. - OTACON - 18.03.2013

pawn Код:
#include <a_samp>
#include <streamer>
new micheckpoint;

public OnGameModeInit() {
    micheckpoint = CreateDynamicCP(Float:x, Float:y, Float:z, Float:size, worldid = -1, interiorid = -1, playerid = -1, Float:distance = 100.0);
    return 1;
}



Respuesta: CreateDynamicCP y definir Checkpoints IDs. - jwalker - 19.03.2013

їComo seria un ejemplo de uno?


Respuesta: CreateDynamicCP y definir Checkpoints IDs. - OTACON - 19.03.2013

Quote:
Originally Posted by jwalker
Посмотреть сообщение
їComo seria un ejemplo de uno?
¬¬

pawn Код:
#include <a_samp>
#include <streamer>
new micheckpoint;

public OnGameModeInit() {
    micheckpoint = CreateDynamicCP(1607.3693,1815.2408,10.8203, 3.0, -1, -1, -1, 100.0);
    return 1;
}



Respuesta: CreateDynamicCP y definir Checkpoints IDs. - jwalker - 19.03.2013

PHP код:
warning 204symbol is assigned a value that is never used"checkpointhospital" 
Y lo estoy usando.


Respuesta: CreateDynamicCP y definir Checkpoints IDs. - adri1 - 19.03.2013

Quote:
Originally Posted by jwalker
Посмотреть сообщение
PHP код:
warning 204symbol is assigned a value that is never used"checkpointhospital" 
Y lo estoy usando.
pawn Код:
public OnPlayerEnterDynamicCP(playerid, checkpointid)
{
if(checkpointid == checkpointhospital)
{
SendClientMessage(playerid, -1, "Entraste en el checkpoint 'hospital'");
}
return 1;
}



Respuesta: CreateDynamicCP y definir Checkpoints IDs. - jwalker - 19.03.2013

Sigue largando el mismo Warning, asн puse todo:

Acб marca el checkpoint.

PHP код:
 if(listitem == 0//
            
{
            new 
checkpointhospital;
               
checkpointhospital CreateDynamicCP(1607.3693,1815.2408,10.82033.0, -1, -1, -1100.0);
            } 
Y esta callback:

PHP код:
public OnPlayerEnterDynamicCP(playeridcheckpointid)
{
new 
checkpointhospital;
if(
checkpointid == checkpointhospital)
{
//
}
return 
1;




Respuesta: CreateDynamicCP y definir Checkpoints IDs. - adri1 - 19.03.2013

No hay que declarar de nuevo checkpointhospital, ya lo estб.

Borra new checkpointhospital;, el que estб dentro de OnPlayerEnterDynamicCP