[Help]More than 1 Spawn Place
#1

how should i make the order for making other camera angles in OnPlayerRequestClass,example i have a spawn at Area51 in the radar room,so i want to make another class with different camera angles how should i make it?
Here is what i added in OnPlayerRequest

Код:
{
	SetPlayerPos(playerid, 222.1653,1823.0802,6.4141);
	SetPlayerFacingAngle(playerid, 269.1334);
	SetPlayerCameraPos(playerid, 224.1104,1823.0507,6.4141);
	SetPlayerCameraLookAt(playerid, 222.1653,1823.0802,6.4141);
	return 1;
}
Reply
#2

To be honest, I don't think thats possible! Correct me if Im wrong...
Reply
#3

Quote:
Originally Posted by Tigerbeast11
To be honest, I don't think thats possible! Correct me if Im wrong...
It's absolutely possible.
pawn Код:
new Float:randomSpawn[2][3] = {
{0000.0,0000.0,0000.0}, // change the coordinates
{0000.0,0000.0,0000.0} // change the coordinates
};
pawn Код:
new rand = random(sizeof(randomSpawn));
SetPlayerPos(playerid, randomSpawn[rand][0], randomSpawn[rand][1], randomSpawn[rand][2]);
SetPlayerFacingAngle(playerid, 270.0);
Reply
#4

No,not random spawn,i want when a player wants to choose a class,then i want to make 2 different spawn places.
Reply
#5

Quote:
Originally Posted by Luka™
Quote:
Originally Posted by Tigerbeast11
To be honest, I don't think thats possible! Correct me if Im wrong...
It's absolutely possible.
pawn Код:
new Float:randomSpawn[2][3] = {
{0000.0,0000.0,0000.0}, // change the coordinates
{0000.0,0000.0,0000.0} // change the coordinates
};
pawn Код:
new rand = random(sizeof(randomSpawn));
SetPlayerPos(playerid, randomSpawn[rand][0], randomSpawn[rand][1], randomSpawn[rand][2]);
SetPlayerFacingAngle(playerid, 270.0);
Why couldnt you have replied to my post about random spawns I needed this! Cheers!
Reply
#6

Quote:
Originally Posted by Danikov
No,not random spawn,i want when a player wants to choose a class,then i want to make 2 different spawn places.
Like I said, not possible!
Reply
#7

Put this under OnPlayerSpawn
pawn Код:
new playerclass = GetPlayerSkin(playerid);

if(playerclass == CLASS_ID || playerclass == CLASS_ID || playerclass == CLASS_ID)
{
    SetPlayerPos(...);
    SetPlayerFacingAngle(...);
    SetPlayerInterior(...);
    .....................
}
Quote:
Originally Posted by Tigerbeast11
Quote:
Originally Posted by Danikov
No,not random spawn,i want when a player wants to choose a class,then i want to make 2 different spawn places.
Like I said, not possible!
Don't spam the topic.
Reply
#8

the new player class should be at top?and where should be

Quote:

if(playerclass == CLASS_ID || playerclass == CLASS_ID || playerclass == CLASS_ID)
{
SetPlayerPos(...);
SetPlayerFacingAngle(...);
SetPlayerInterior(...);
.....................
}

Reply
#9

pawn Код:
public OnPlayerSpawn(playerid)
{
    new playerclass = GetPlayerSkin(playerid);
   
    if(playerclass == CLASS_ID /* || playerclass == CLASS_ID || playerclass == CLASS_ID || playerclass == CLASS_ID */) // class_id put a skin id that you want
    {
        SetPlayerPos(...); // coordinates to spawn player
       // SetPlayerFacingAngle(...); // use this if you want
       // SetPlayerInterior(...); // set interior if you want
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)