#Animation doesnt play correctly

1 messages · Page 1 of 1 (latest)

storm raptor
#

I'm trying to change the walking animation while holding an item (katana). I managed to change it, but it only changes if the player walks while equipping the sword (both at the same time).
If I equip the sword and then walk, the animation doesn't activate.

The first picture is the code to play a "breathing" animation while standing still.

I should clarify that I don't know how to program, and I did this with the help of AI and my basic scripting knowledge. and Sorry if the label is not correct I don't know which one to put

storm raptor
#

Animation doesnt play correctly

tight siren
#

You're treating Tool.Equipped as a boolean when it is an event.

#

Tool.Equipped doesn't return a value based on if the tool is equipped. Rather, it fires a connected function when the tool is equipped.

#
  • If you wish to make a variable to tell when the tool is equipped, you can bind a function to the .Equipped event and change the variable accordingly when the player equips and unequips the weapon (also use tool.Unequipped:)