Change walkstyle
#1

I have seif_walk.inc but i dont know how to make a script like this one in the picture, is there any around?

No CJ RUN.
Reply
#2

just an Animation on a Dialog
Reply
#3

Example:

pawn Код:
#define DIALOG_ANIMATIONS 1 // on top of script, change 1 to any AVAILABLE dialog ID.
pawn Код:
CMD:walkstyles(playerid, params[])
{
      ShowPlayerDialog(playerid, DIALOG_ANIMATIONS, DIALOG_STYLE_LIST, "Walk Styles", "Style1\nStyle2\nStyle3", "Select", "Cancel");
      return 1;
}
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
        case DIALOG_ANIMATIONS:
        {
            if(response) // checks if he pressed Button 1 (Select)
            {
                switch(listitem)
                {
                    case 0: // Walk style 1.
                    {
                        ApplyAnimation(...);
                    }
                    case 1: // Walk style 2.
                    {
                        ApplyAnimation(...);
                    }
                    case 2: // Walk style 3.
                    {
                        ApplyAnimation(...);
                    }
                }
            }
        }
        return 1;
}
https://sampwiki.blast.hk/wiki/ShowPlayerDialog
https://sampwiki.blast.hk/wiki/OnDialogResponse
Reply
#4

Quote:
Originally Posted by Sandiel
Посмотреть сообщение
Example:

pawn Код:
#define DIALOG_ANIMATIONS 1 // on top of script, change 1 to any AVAILABLE dialog ID.
pawn Код:
CMD:walkstyles(playerid, params[])
{
      ShowPlayerDialog(playerid, DIALOG_ANIMATIONS, DIALOG_STYLE_LIST, "Walk Styles", "Style1\nStyle2\nStyle3", "Select", "Cancel");
      return 1;
}
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
        case DIALOG_ANIMATIONS:
        {
            if(response) // checks if he pressed Button 1 (Select)
            {
                switch(listitem)
                {
                    case 0: // Walk style 1.
                    {
                        ApplyAnimation(...);
                    }
                    case 1: // Walk style 2.
                    {
                        ApplyAnimation(...);
                    }
                    case 2: // Walk style 3.
                    {
                        ApplyAnimation(...);
                    }
                }
            }
        }
        return 1;
}
https://sampwiki.blast.hk/wiki/ShowPlayerDialog
https://sampwiki.blast.hk/wiki/OnDialogResponse
Thanks bro fixed.
Reply
#5

Could you possibly explain how to do something like this, but instead of a walk animation, use it to set a certain talking animation for when people talk IG?
Reply
#6

Quote:
Originally Posted by Noesis
Посмотреть сообщение
Could you possibly explain how to do something like this, but instead of a walk animation, use it to set a certain talking animation for when people talk IG?
https://sampwiki.blast.hk/wiki/OnPlayerText
https://sampwiki.blast.hk/wiki/ApplyAnimation
Reply
#7

This should be posted on the include thread.
Reply
#8

Thank you Stigg
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)