Is there a way if a player fell out of map?
#1

Okay so sometimes it happens that when a player is getting spawned due to whatever reasons he fells out of map and ends up in blueberry bugged with CJ skin.
Is there any way to detect that and to respawn it if he's felling down?
Also, how to avoid this issue? I have new spawning coords and changed them several times and this issue arises randomly out of blue
Reply
#2

Check if the player is falling with animation,
get the ground Z level on his current X and Y position (I use colanders for precision),
Check if the player's Z coordinate is inferior to that of the ground level,
Reply
#3

Quote:
Originally Posted by Eoussama
Посмотреть сообщение
Check if the player is falling with animation,
get the ground Z level on his current X and Y position (I use colanders for precision),
Check if the player's Z coordinate is inferior to that of the ground level,
What are some of the ways to avoid this bug? This issue wasn't present in the previous spawn coords. My spawn coords are a little modified, there's no custom objects, I even increased the value of z coord by 2 to let the world load below the player but this issue still occurs randomly.

Do you think I should do a timer which checks every one second to do what you said? Also how can I check if player is falling?
Reply
#4

I freeze the player for 3 seconds at "OnPlayerSpawn" but still this issue comes out randomly.
Reply
#5

If your server is public, send me the IP and I'll join and rejoin a few times, what you're saying doesn't really make sense unless it's coding related
Reply
#6

Quote:
Originally Posted by WillyP
Посмотреть сообщение
If your server is public, send me the IP and I'll join and rejoin a few times, what you're saying doesn't really make sense unless it's coding related
I don't have it public yet, I'm working at it.

I've also noticed something strange -
Usually when a player spawns. I send him a ClientMessage.

But when the player falls off the map, the client message doesn't appear either. It's like - OnPlayerSpawn isn't called at all.

The player isn't armed either, but OnPlayerSpawn was supposed to arm him.

Is it a bug that OnPlayerSpawn isn't called everytime?
Reply
#7

Possibly something in your code is conflicting with other parts causing the player to spawn somewhere different to where you have specified, as well as the lack of message and weapons. Can't really decipher the issue without having a go or looking at some coding
Reply
#8

Quote:
Originally Posted by WillyP
Посмотреть сообщение
Possibly something in your code is conflicting with other parts causing the player to spawn somewhere different to where you have specified, as well as the lack of message and weapons. Can't really decipher the issue without having a go or looking at some coding
It was a very very shitty issue.
Earlier the random spawning coordinates were 5
I decreased them to 3 but I forgot to adjust the "random" keyword.
So it was supposed to use 5 random coordinates but was having 3 so it was spawning me in blueberry when other 2 were called.
LOL, Stupid me. But thanks for trying to help means a lot.

Edit: I'm out of reps, I'll make sure to rep you.
Reply
#9

Don't worry, we all make mistakes
Reply
#10

another potential fall out of map:

if you respawn a vehicle while a player is surfing on it he will be teleported to blueberry (0, 0, 0)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)