Animations at Player Selection?
#1

Hello Again
Do you know how I can get Anims at Skin Selection?
Lets say I want all my skins to /crossarms.

Thanks for the Answers
Reply
#2

Play the animation at OnPlayerRequestClass callback.
Here is the list of animations: https://sampwiki.blast.hk/wiki/Animations
Reply
#3

Quote:
Originally Posted by Don Correlli
Play the animation at OnPlayerRequestClass callback.
Here is the list of animations: https://sampwiki.blast.hk/wiki/Animations
This is the first time I do this with anims, how should I write it down?
Reply
#4

Here's an example of what he means:

pawn Code:
public OnPlayerRequestClass(playerid, classid)
{
    switch(classid)
    {
      case 0:
      {
        GameTextForPlayer(playerid,"~n~~n~~n~~g~Class 1",3000,3);
            {
            SetPlayerInterior(playerid, 0);
                SetPlayerPos(playerid, -1426.575805, 23.959726, 14.148437);
                SetPlayerFacingAngle(playerid, 219.106613);
                SetPlayerCameraPos(playerid, -1423.829833, 20.462652, 14.148437);
                SetPlayerCameraLookAt(playerid, -1426.575805, 23.959726, 14.148437);
                ApplyAnimation(playerid, "ON_LOOKERS", "wave_loop", 4.0, 1, 0, 0, 0, 0); // Example Animation
             }
      }
      case 1:
      {
            GameTextForPlayer(playerid,"~n~~n~~n~~b~Class 2",3000,3);
            {
            SetPlayerInterior(playerid, 0);
                SetPlayerPos(playerid, -1426.575805, 23.959726, 14.148437);
                SetPlayerFacingAngle(playerid, 219.106613);
                SetPlayerCameraPos(playerid, -1423.829833, 20.462652, 14.148437);
                SetPlayerCameraLookAt(playerid, -1426.575805, 23.959726, 14.148437);
                ApplyAnimation(playerid,"PLAYIDLES","TIME",4.1,1,1,1,1,1); // Example Animation
             }
      }
    }
    return 1;
}
Reply
#5

Quote:
Originally Posted by [B2K
Hustler ]
Here's an example of what he means:

pawn Code:
public OnPlayerRequestClass(playerid, classid)
{
    switch(classid)
    {
      case 0:
      {
        GameTextForPlayer(playerid,"~n~~n~~n~~g~Class 1",3000,3);
            {
            SetPlayerInterior(playerid, 0);
                SetPlayerPos(playerid, -1426.575805, 23.959726, 14.148437);
                SetPlayerFacingAngle(playerid, 219.106613);
                SetPlayerCameraPos(playerid, -1423.829833, 20.462652, 14.148437);
                SetPlayerCameraLookAt(playerid, -1426.575805, 23.959726, 14.148437);
                ApplyAnimation(playerid, "ON_LOOKERS", "wave_loop", 4.0, 1, 0, 0, 0, 0); // Example Animation
             }
      }
      case 1:
      {
            GameTextForPlayer(playerid,"~n~~n~~n~~b~Class 2",3000,3);
            {
            SetPlayerInterior(playerid, 0);
                SetPlayerPos(playerid, -1426.575805, 23.959726, 14.148437);
                SetPlayerFacingAngle(playerid, 219.106613);
                SetPlayerCameraPos(playerid, -1423.829833, 20.462652, 14.148437);
                SetPlayerCameraLookAt(playerid, -1426.575805, 23.959726, 14.148437);
                ApplyAnimation(playerid,"PLAYIDLES","TIME",4.1,1,1,1,1,1); // Example Animation
             }
      }
    }
    return 1;
}
Thanks everyone
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)