SA-MP Forums Archive
move camera at class selection - 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: move camera at class selection (/showthread.php?tid=359197)



move camera at class selection - Pro_Scriptor - 13.07.2012

ok my gang war server has class selection in which when we move class selection to grove street the camera is placed at groove street and when we move to ballas the camera is at ballas place like this
PHP код:
       case 8..11: {
         
GameTextForPlayer(playerid"~n~~n~~n~~n~~n~~n~~n~~n~~n~~y~Ballas"30003);
         
SetPlayerPos(playerid2012.8110,-1199.6431,20.0234);
         
SetPlayerCameraPos(playerid2016.9944,-1199.9324,20.1287);
         
SetPlayerCameraLookAt(playerid2012.8110,-1199.6431,20.0234);
         
SetPlayerFacingAngle(playerid268.5099);
         
ApplyAnimation(playerid,"GHANDS""gsign2LH",4.0,1,1,1,1,1);
       }
       case 
12..15: {
         
GameTextForPlayer(playerid"~n~~n~~n~~n~~n~~n~~n~~n~~n~~y~Grove Families"30003);
         
SetPlayerPos(playerid2468.6868,-1660.0106,13.3356);
         
SetPlayerCameraPos(playerid2462.4019,-1658.0359,13.3047);
         
SetPlayerCameraLookAt(playerid2468.6868,-1660.0106,13.3356);
         
SetPlayerFacingAngle(playerid70.7120);
         
ApplyAnimation(playerid,"LOWRIDER""RAP_B_Loop",4.0,1,1,1,1,1);
       } 
so i want when on layer is selecting class the camera should move to that postion


Re: move camera at class selection - clarencecuzz - 13.07.2012

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    switch(classid)
    {
        case 8 .. 11:
        {
             GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~p~Ballas", 3000, 3);
             SetPlayerPos(playerid, 2012.8110,-1199.6431,20.0234);
             SetPlayerCameraPos(playerid, 2016.9944,-1199.9324,20.1287);
             SetPlayerCameraLookAt(playerid, 2012.8110,-1199.6431,20.0234);
             SetPlayerFacingAngle(playerid, 268.5099);
             ApplyAnimation(playerid,"GHANDS", "gsign2LH",4.0,1,1,1,1,1);
        }
        case 12 .. 15:
        {
             GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~g~Grove Families", 3000, 3);
             SetPlayerPos(playerid, 2468.6868,-1660.0106,13.3356);
             SetPlayerCameraPos(playerid, 2462.4019,-1658.0359,13.3047);
             SetPlayerCameraLookAt(playerid, 2468.6868,-1660.0106,13.3356);
             SetPlayerFacingAngle(playerid, 70.7120);
             ApplyAnimation(playerid,"LOWRIDER", "RAP_B_Loop",4.0,1,1,1,1,1);
        }
    }
    return 1;
}



Re: move camera at class selection - kbalor - 13.07.2012

clarence check your private message. i need your help.


Re: move camera at class selection - Pro_Scriptor - 23.07.2012

Quote:
Originally Posted by clarencecuzz
Посмотреть сообщение
pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    switch(classid)
    {
        case 8 .. 11:
        {
             GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~p~Ballas", 3000, 3);
             SetPlayerPos(playerid, 2012.8110,-1199.6431,20.0234);
             SetPlayerCameraPos(playerid, 2016.9944,-1199.9324,20.1287);
             SetPlayerCameraLookAt(playerid, 2012.8110,-1199.6431,20.0234);
             SetPlayerFacingAngle(playerid, 268.5099);
             ApplyAnimation(playerid,"GHANDS", "gsign2LH",4.0,1,1,1,1,1);
        }
        case 12 .. 15:
        {
             GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~g~Grove Families", 3000, 3);
             SetPlayerPos(playerid, 2468.6868,-1660.0106,13.3356);
             SetPlayerCameraPos(playerid, 2462.4019,-1658.0359,13.3047);
             SetPlayerCameraLookAt(playerid, 2468.6868,-1660.0106,13.3356);
             SetPlayerFacingAngle(playerid, 70.7120);
             ApplyAnimation(playerid,"LOWRIDER", "RAP_B_Loop",4.0,1,1,1,1,1);
        }
    }
    return 1;
}
whats the difference between mine and yours