Is it possible to "PlayerSpectatePlayer" when you're on the logging screen - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen (
/showthread.php?tid=242278)
Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
anumaz - 19.03.2011
Hi, I wanted to know if it was possible to spectate another player(NPC in this case) when you're on the logging screen, when you connect. Aka - making the Toggle&PlayerSpectate... under the "public OnPlayerConnect" ?
Thanks
Re: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
xDeadlyBoy - 19.03.2011
why don't you check it out?
i think it's possible.
Re: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
Sascha - 19.03.2011
it's not possible at "OnPlayerConnect" when you are showing the Login Dialog.. however it would be possible at "OnPlayerRequestClass" if I'm right..
Re: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
xDeadlyBoy - 19.03.2011
Quote:
Originally Posted by Sascha
it's not possible at "OnPlayerConnect" when you are showing the Login Dialog.. however it would be possible at "OnPlayerRequestClass" if I'm right..
|
who said he is using a login dialog? and still, i don't think it should avoid him to do it.
and the class selections buttons using the same method of dialog.
Re: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
Sascha - 19.03.2011
it's not because of the dialog..
it's because of the function itself..
"OnPlayerConnect" is called at the time when you have that "Beach view" at LS...
OnPlayerRequestClass is called just after that action... if he calls his Login Dialog (if he has one) at "OnPlayerRequestClass" he would have exact the feature that he wants to have...
Re : Re: Is it possible to "PlayerSpectatePlayer" when you're on the logging screen -
anumaz - 19.03.2011
Quote:
Originally Posted by xDeadlyBoy
why don't you check it out?
i think it's possible.
|
I tried, maybe I did an error, so I was just making sure.
Quote:
Originally Posted by Sascha
it's not possible at "OnPlayerConnect" when you are showing the Login Dialog.. however it would be possible at "OnPlayerRequestClass" if I'm right..
|
I can't get it to work... er...
pawn Код:
public OnPlayerRequestSpawn( playerid )
{
SetTimerEx("LoadFav", 11000, false , "i" , playerid );
TogglePlayerSpectating(playerid, 1);
PlayerSpectatePlayer(playerid, 0);
SetTimer("aftercamera", 10000, 1);
SendClientMessage(playerid, -1, "LOADING");
return 1;
}
forward aftercamera(playerid);
public aftercamera(playerid)
{
TogglePlayerSpectating(playerid, 0);
}
public OnPlayerSpawn( playerid )
{
SetPlayerPos(playerid, 2181.9321,1682.9525,11.0676);
SetPlayerFacingAngle(playerid, 91.38);
SetCameraBehindPlayer(playerid);
return 1;
}