Can't choose character!
#1

Hi!

I got a problem! I typed:

Код:
{
    // Don't use these lines if it's a filterscript
    SetGameModeText("San Andreas Deathmatch");
    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    AddPlayerClass(102, 1974.4895,-1157.0608,20.9505,95.6222, 30, 1000, 29, 1000, 27, 1000);
    return 1;
}
I should be able to play in the game between CJ and a Ballas! I can do this, but when I join my server, I am not able to see which charakter I am choosing! That means, the animations of the charakter are not there, I just have to spawn and luckily I reach one of them! What should I do, when I want be able to see which character I'm choosing?

Thanks
Reply
#2

You have to change camera position in OnPlayerRequestClass.
Reply
#3

So one more time, this is my Code for CJ and Ballas:
Код:
{
    // Don't use these lines if it's a filterscript
    SetGameModeText("San Andreas Deathmatch");
    AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
    AddPlayerClass(102, 1974.4895,-1157.0608,20.9505,95.6222, 30, 1000, 29, 1000, 27, 1000);
    return 1;
}
So what do I have to type in OnPlayerRequest?
Reply
#4

Please, I need help~~!!!
Reply
#5

Quote:
Originally Posted by MadeMan
You have to change camera position in OnPlayerRequestClass.
exactly!you must change the camera position in OnPlayerRequestClass
Reply
#6

This is it:
Код:
public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerTeamFromClass(playerid, classid);
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);//You did not put this in a callback.
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}
So what do I have to change, when I want to see the ballas or CJ?
Reply
#7

Nobody know what to do?
Reply
#8

Your camera position is incorrect - it's correctly sitting on-top of the player! Try to move it a few units in the y direction (that way the camera will be looking at the player, since they are facing north)

pawn Код:
SetPlayerCameraPos( playerid, 1958.3783, 1348.1572, 15.3746 );
Reply
#9

Should I go in Debug and make the coordinates in front of the fool?
Reply
#10

In my last reply I added a few units to the y position so the camera would be in front of, and look at, the player. You can go into debug and get new coordinates. The method I use is find the place I want the player to stand, type /save, then walk a few steps forward (without changing camera view), and type /save once more. Then I set up my functions like so:
pawn Код:
SetPlayerPos( playerid, /* x, y, z from first saved line */ );
SetPlayerFacingAngle( playerid, /* a from first saved line */ );
SetPlayerCameraPos( playerid, /* x, y, z from second line */ );
SetPlayerCameraLookAt( playerid, /* x, y, z from first saved line */ );
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)