Help OnPlayerSpawn.
#1

Hello. Well, this happen in my Old GameMode after 0.3d and now, on my scratch made GameMode that i am making to gain more experience.

After pressing Spawn button, this happens:


The code:
pawn Код:
public OnPlayerSpawn(playerid)
{
    SetPlayerPos(playerid, 10.0, 10.0, 10.0);
    return 1;
}
Thank you.
Reply
#2

try adding

pawn Код:
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
i have encounter such problems
Reply
#3

Are you spawning somewhere outside of san andreas?
Reply
#4

Quote:

Are you spawning somewhere outside of san andreas?

i think it doesn't matter but what matters the most is that you add

pawn Код:
AddPlayerClass
Reply
#5

Quote:
Originally Posted by RicaNiel
Посмотреть сообщение
try adding

pawn Код:
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
i have encounter such problems
Will try.

Quote:

Are you spawning somewhere outside of san andreas?

This cords are in Bluebery Acres. The place you spawn when no cords.. Just made it not spawn undersground.


EDIT:
Didn't work.
Reply
#6

did you make sure that AddPlayerClass was there? otherwise it would be like this.
Reply
#7

did it work?
Reply
#8

Quote:
Originally Posted by Dr.Heinz
Посмотреть сообщение
did you make sure that AddPlayerClass was there? otherwise it would be like this.
Now i have this, and still the same...

pawn Код:
public OnPlayerSpawn(playerid)
{
    return 1;
}
public OnPlayerRequestClass(playerid, classid)
{
    SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
    SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
    return 1;
}
Reply
#9

Quote:

Now i have this, and still the same...

are you going to add
the add selection class or not?
if not then leave the "OnPlayerRequestClass" blank

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    // leave it blank here
    return 1;
}
Reply
#10

Quote:
Originally Posted by RicaNiel
Посмотреть сообщение
are you going to add
the add selection class or not?
if not then leave the "OnPlayerRequestClass" blank

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    // leave it blank here
    return 1;
}
No, i will not add it.
I tried deleteing it and let only OnPlayerSpawn, i tried letting both, deleting OnPlayerSpawn, leaving them blank.. Nothing work......
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)