SA-MP Forums Archive
Is This Possible - 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)
+--- Thread: Is This Possible (/showthread.php?tid=311261)



Is This Possible - [D]ry[D]esert - 15.01.2012

Hello every one

i am thinking if this possible

PHP код:
public OnPlayerSpawn(playerid)
{
SetPlayerPos(playerid,1787.9059,-2014.8525,13.4793);
TogglePlayerControllable(playerid,0);
SetPlayerCameraPos(playerid,1789.6177,-2015.1742,13.4852);
SetPlayerCameraLookAt(playerid,1813.9497,-1866.1736,13.5704);
SetTimerEx("FristLook",20000,false,"i",playerid);
SendClientMessage(playerid,0xFFFFFFAA,"Is this possible ?");
return 
1;
}
forward FristLook(playerid);
public 
FristLook(playerid)
{
SetPlayerPos(playerid,1587.2069,-1014.5525,20.4793);
TogglePlayerControllable(playerid,0);
SetPlayerCameraPos(playerid,2526.6177,-2535.1742,13.4852);
SetPlayerCameraLookAt(playerid,1813.9497,-1866.1736,13.5704);
SetTimerEx("Seclook",20000,false,"i",playerid);
SendClientMessage(playerid,0xFFFFFFAA,"Is this possible ?");
return 
1;
}
forward SecLook(playerid);
public 
SecLook(playerid)
{
SetPlayerPos(playerid,4587.5369,-1324.5525,22.4793);
TogglePlayerControllable(playerid,0);
SetPlayerCameraPos(playerid,2521.6177,-23235.174212,13.42852);
SetPlayerCameraLookAt(playerid,8213.9497,-5866.1736,23.5704);
SetTimerEx("3rdlook",20000,false,"i",playerid);
SendClientMessage(playerid,0xFFFFFFAA,"Is this possible ?");
return 
1;
}
forward 3rdlook(playerid);
public 
3rdlook(playerid)
{
SetPlayerPos(playerid,1425.5369,-2414.5525,22.4793);
TogglePlayerControllable(playerid,1);
SetPlayerCameraPos(playerid,6521.6177,-7323.14212,13.42852);
SetPlayerCameraLookAt(playerid,3213.9497,-5166.1736,53.5704);
SendClientMessage(playerid,0xFFFFFFAA,"Is this possible ?");
return 
1;




Re: Is This Possible - Konstantinos - 15.01.2012

Only one way there is to find out. Test it!


Re: Is This Possible - [D]ry[D]esert - 17.01.2012

i test it but when i spawn it work till seclook then Timer Stop how can i make timers work in this case


Re: Is This Possible - jamesbond007 - 17.01.2012

capitals matter, you have ,

SetTimerEx("Seclook",20000,false,"i",playerid);

but the public is SecLook

rep++++++++++++++++


Re: Is This Possible - mineralo - 17.01.2012

why you in every public posted toglleplayercontrol(playerid,0) it's enough once at first public, in tethod it's should work and not need pos everytime the position of player, because you can just toggleplayercontrol and just post the camera look


Re: Is This Possible - [D]ry[D]esert - 17.01.2012

Quote:
Originally Posted by jamesbond007
Посмотреть сообщение
capitals matter, you have ,

SetTimerEx("Seclook",20000,false,"i",playerid);

but the public is SecLook

rep++++++++++++++++
Fixed = Worked Thanks + Rep

Quote:
Originally Posted by mineralo
Посмотреть сообщение
why you in every public posted toglleplayercontrol(playerid,0) it's enough once at first public, in tethod it's should work and not need pos everytime the position of player, because you can just toggleplayercontrol and just post the camera look


yea thanks i fix it but if i just leave the function like that are the camera pos gonna repeated ?

+
can i make
forward send(playerid);
public send(playerid)
{
SetTimerEx("Whatever",20000,false,"i",playerid);
SendClientMessage(playerid,RED,"Frist");
return 1;
}
forward Whatever(playerid);
public Whatever(playerid)
{
SetTimerEx("send",20000,false,"i",playerid);
SendClientMessage(playerid,RED,"sec");
return 1;
}


Re: Is This Possible - thimo - 17.01.2012

Yes that would repeat.