[Help] SetPlayerFacingAngle 4 different coordinations
#1

It works ty
Reply
#2

Here you go, you will just need to acess the last part of the array 2D.
pawn Код:
new Float:gAngles[4][1] = //grove
{
    {30.0},
    {60.0},
    {90.0},
    {120.0}
};
// if you wish make random angles just do the same as the spawns.
new rand = random(sizeof(gAngles));
SetPlayerFacingAngle( playerid,gAngles[rand][0]);

//or this way.

new Float:gRandomSpawns[4][4] = //grove
{
    {2509.3162,-1654.4011,13.6194,30.0},
    {2511.2471,-1688.7179,13.5511,60.0},
    {2471.9990,-1686.6086,13.5078,90.0},
    {2509.3162,-1654.4011,13.6194,120.0}
};
SetPlayerFacingAngle(playerid,gRandomSpawns[rand][3]); // here,we are acessing the last part of the array 2D, there's the angle.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)