SA-MP Forums

Go Back   SA-MP Forums > SA-MP > Bug Reports

Reply
 
Thread Tools Display Modes
Old 03/03/2015, 06:10 PM   #1
BeckzyBoi
High-roller
 
Join Date: Dec 2006
Posts: 1,588
Reputation: 76
Default streamed in paused players facing north

Title says it all. When a player streams in for another player and they are paused they will be facing north (0.0) until they unpause then their facing angle is updated properly for other players.
BeckzyBoi is offline   Reply With Quote
Old 03/03/2015, 07:26 PM   #2
Abagail
High-roller
 
Join Date: Dec 2013
Location: GetPlayerPos(playerid, pos); Scripter/Mapper.
Posts: 3,333
Reputation: 389
Default Re: streamed in paused players facing north

That's because paused players don't send data to the server. That's the reason why AFK systems are able to detect when a player AFK's - OnPlayerUpdate stops being called. Simply, it's meant to be this way.
Abagail is offline   Reply With Quote
Old 03/03/2015, 11:22 PM   #3
BeckzyBoi
High-roller
 
Join Date: Dec 2006
Posts: 1,588
Reputation: 76
Default Re: streamed in paused players facing north

Quote:
Originally Posted by Abagail View Post
That's because paused players don't send data to the server. That's the reason why AFK systems are able to detect when a player AFK's - OnPlayerUpdate stops being called. Simply, it's meant to be this way.
GetPlayerFacingAngle returns the correct angle of the player, not 0.0. So I wouldn't say it's meant to be this way.
BeckzyBoi is offline   Reply With Quote
Old 04/03/2015, 02:53 AM   #4
ikey07
High-roller
 
ikey07's Avatar
 
Join Date: Jul 2010
Location: Latvia,Riga
Posts: 1,371
Reputation: 180
Default Re: streamed in paused players facing north

It returns last received angle I believe.
__________________
ikey07 is offline   Reply With Quote
Old 04/03/2015, 02:59 AM   #5
BeckzyBoi
High-roller
 
Join Date: Dec 2006
Posts: 1,588
Reputation: 76
Default Re: streamed in paused players facing north

Yeah so if GetPlayerFacingAngle returns the correct angle there's no reason for the player to be facing north paused or not.
BeckzyBoi is offline   Reply With Quote
Old 05/03/2015, 04:15 AM   #6
muzammilfreeman
Huge Clucker
 
muzammilfreeman's Avatar
 
Join Date: Dec 2014
Location: In The World Of Roleplay.
Posts: 306
Reputation: 41
Default Re: streamed in paused players facing north

Er.. seems to be criticel
__________________
Server Information:

SA-MP: samp.ne-rp.net
FORUMS: www.ne-rp.net/forums
TeamSpeak3: ts.ne-rp.net
UCP: cp.ne-rp.net
Shop: shop.ne-rp.net

JOIN NOW TO EXPLORE AMAZING FEATURES[STABLE 40+ DAILY PLAYERBASE]
muzammilfreeman is offline   Reply With Quote
Old 02/02/2017, 10:39 AM   #7
~Error
Big Clucker
 
~Error's Avatar
 
Join Date: Nov 2011
Location: Ohio
Posts: 63
Reputation: 0
Default Re: streamed in paused players facing north

Sorry for bump
I actually wondered if someone have a solutions
__________________
Viva La PAWN!
~Error is offline   Reply With Quote
Old 02/02/2017, 03:49 PM   #8
Lordzy
High-roller
 
Join Date: Mar 2012
Location: NetherRealm
Posts: 2,824
Reputation: 1074
Default Re: streamed in paused players facing north

OnPlayerUpdate will not be called for paused players. So you can use the last received angle update of the player.
Code:
new
    Float:g_PlayerLastAngle[MAX_PLAYERS];

public OnPlayerUpdate(playerid) {

    GetPlayerFacingAngle(playerid, g_PlayerLastAngle[playerid]);
    return 1;
}

//if player is paused, use the last received angle.
__________________
[Include]safeDialogs - Complete protection against dialog responses! (dialog ids, list-items, input-text of list-item and user)

I don't play at any SA-MP servers now. If you see anyone with my name, that's not me.
Lordzy is offline   Reply With Quote
Old 02/02/2017, 04:32 PM   #9
Sew_Sumi
High-roller
 
Join Date: Jun 2008
Posts: 4,348
Reputation: 262
Default Re: streamed in paused players facing north

Quote:
Originally Posted by Lordzy View Post
Code:
//if player is paused, use the last received angle.
Read the thread, that is what already happens... If you GetPlayerFacingAngle on a tabbed player, you get the last known angle...
Sew_Sumi is offline   Reply With Quote
Old 03/02/2017, 03:26 AM   #10
Lordzy
High-roller
 
Join Date: Mar 2012
Location: NetherRealm
Posts: 2,824
Reputation: 1074
Default Re: streamed in paused players facing north

Quote:
Originally Posted by Sew_Sumi View Post
Read the thread, that is what already happens... If you GetPlayerFacingAngle on a tabbed player, you get the last known angle...
I only read the first post, my bad.

SetPlayerPos/SetPlayerFacingAngle will not work for paused players AFAIK so there's no way in correcting it. However, I've experienced that setting virtual worlds might work. Even for a paused player, when virtual world is set, it affects them. Try setting the facing angle to last known angle and then switch the virtual world to current once again. I'm not sure if that works but it's only an assumption. Virtual worlds used to be set for older SA-MP versions so I cannot guarantee you about the current version.

If what I said works, you'll have to do it constantly.
__________________
[Include]safeDialogs - Complete protection against dialog responses! (dialog ids, list-items, input-text of list-item and user)

I don't play at any SA-MP servers now. If you see anyone with my name, that's not me.
Lordzy is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Registration Causes Lag [ MYSQL ]. 50-100 Players getting Paused at a time iAnonymous Scripting Help 13 05/08/2014 12:00 AM
paused players.... burnuk General 5 01/04/2013 01:46 AM
Is it possible to auto kick paused players without using onplayerupdate? 101 Scripting Help 13 17/01/2013 06:19 PM
Detecting paused players? Twisted_Insane Scripting Help 6 14/04/2012 05:24 PM
Kicking Paused Players Michael[NBK] Scripting Help 3 11/11/2011 08:53 PM


All times are GMT. The time now is 02:01 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.