Random Spawn Help :(
#1

Vehicle and Player random spawn be

{2218.12915039,1613.92199707,999.63289697},
{2220.36425781,1571.91381836,999.61470850},
{2182.41430664,1591.57788086,999.62574658},
Reply
#2

Helpp
Reply
#3

pawn Код:
new
    Float: iRandSpawns[][] = {
    {2218.12915039,1613.92199707,999.63289697},
    {2220.36425781,1571.91381836,999.61470850},
    {2182.41430664,1591.57788086,999.62574658}
};

new
    iRand = random(sizeof(iRandSpawns));

SetPlayerPos(playerid, iRandSpawns[iRand][0], iRandSpawns[iRand][1], iRandSpawns[iRand][2]);
Reply
#4

Quote:
Originally Posted by [L3th4l]
Посмотреть сообщение
pawn Код:
new
    Float: iRandSpawns[][] = {
    {2218.12915039,1613.92199707,999.63289697},
    {2220.36425781,1571.91381836,999.61470850},
    {2182.41430664,1591.57788086,999.62574658}
};

new
    iRand = random(sizeof(iRandSpawns));

SetPlayerPos(playerid, iRandSpawns[iRand][0], iRandSpawns[iRand][1], iRandSpawns[iRand][2]);
Noo
player and venicle to
Reply
#5

help
Reply
#6

pawn Код:
new
    Float: iRandSpawns[][] = {
    {2218.12915039,1613.92199707,999.63289697},
    {2220.36425781,1571.91381836,999.61470850},
    {2182.41430664,1591.57788086,999.62574658}
};

new
    iRand = random(sizeof(iRandSpawns)),
    Float:playerX,
    Float:playerY,
    Float:playerZ,
    playerveh;

SetPlayerPos(playerid, iRandSpawns[iRand][0], iRandSpawns[iRand][1], iRandSpawns[iRand][2]);

GetPlayerPos(playerid, playerX, playerY, playerZ);

playerveh = CreateVehicle(playerX, playerY, playerZ, time);

OnPlayerSpawn(playerid)
{
    PutPlayerInVehicle(playerid, playerveh);
    // other stuff
    return 1;
}
Reply
#7

error;

C:\Users\Yasin\Desktop\Untitled.pwn(59) : error 017: undefined symbol "playerveh"
C:\Users\Yasin\Desktop\Untitled.pwn(86) : warning 213: tag mismatch
C:\Users\Yasin\Desktop\Untitled.pwn(86) : error 017: undefined symbol "time"
C:\Users\Yasin\Desktop\Untitled.pwn(86) : warning 204: symbol is assigned a value that is never used: "playerveh"
C:\Users\Yasin\Desktop\Untitled.pwn(86 -- 91) : warning 217: loose indentation
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)