23.10.2011, 12:22
(
Последний раз редактировалось Madsen; 23.10.2011 в 12:23.
Причина: problem with [pawn][/pawn]
)
so i want to make random checkpoints, but i do not know how to save the location of the random checkpoint here is what i got so far
pawn Код:
new Float:locesc[][3] =
{
{1429.0435,-1872.7736,13.1115},
{1935.4012,-1773.3212,13.1099},
{1961.9923,-2188.9326,13.2740},
{2676.4375,-2502.9500,13.2783},
{2222.2273,-1339.5552,23.7110},
{2727.4810,-1259.9392,59.2934},
{2170.8638,-1004.4625,62.5303},
{1639.8905,-1169.4454,55.4806},
{1297.7617,-1570.0330,13.1100},
{839.8412,-1610.1801,13.1112},
{371.1917,-1646.8229,32.4500},
{524.4382,-1421.0612,15.6804},
{1058.3478,-1329.7805,13.1099},
{1372.9076,-942.0881,33.9146},
{1337.7911,-2458.1152,7.5310}
};
Onplayeentercheckpoint
if (IsPlayerInRangeOfPoint(playerid, 12, 1027.8938,-1038.5903,31.0843)) // checkpoint 1 escaper
{
new pointesc = random(sizeof(locesc));
DisablePlayerCheckpoint(playerid);
SetPlayerCheckpoint(playerid, locesc[pointesc][0], locesc[pointesc][1],locesc [pointesc][2], 12);
}