Attack Animation

How can i do attack animation like if i attack it comes up an slash animation.I think i have to animate the items dath way but im not shure.If someone can post me a tutorial on how to do it.

ty

Doesnt work wen i try it player doesnt do dmg

Sub OnAttack(Index, Damage)
Dim Target

If Int(Damage) > 0 Then
If Int(GetPlayerTarget(Index)) > 0 Then Call SpellAnim(27, GetPlayerMap(index), GetNpcX(GetPlayerMap(index), GetPlayerTargetNpc(index)), GetNpcY(GetPlayerMap(index), GetPlayerTargetNpc(index)))
Target = GetPlayerTarget(Index)
Call DamagePlayer(Index, Target, Damage)
Else
Target = GetPlayerTargetNPC(Index)
Call DamageNPC(Index, Target, Damage)
End If
End If
End Sub

I’m pretty sure it’s supposed to go at the very top?

Sub OnAttack(Index, Damage)
   Dim Target
         Call SpellAnim(27, GetPlayerMap(index), GetNpcX(GetPlayerMap(index), GetPlayerTargetNpc(index)), GetNpcY(GetPlayerMap(index), GetPlayerTargetNpc(index)))
   If Int(Damage) > 0 Then
      If Int(GetPlayerTarget(Index)) > 0 Then 
         Target = GetPlayerTarget(Index)
         Call DamagePlayer(Index, Target, Damage)
      Else
         Target = GetPlayerTargetNPC(Index)
         Call DamageNPC(Index, Target, Damage)
      End If
   End If
End Sub

Idk though.

gona try

Perfect work ty  :azn:

And 1 more question do you know a program dath can help me make paperdoll more easy i am making an side scroll game

That’s as easy as it’ll get, Check out the Graphics Tutorials. there’s some pretty good “Techniques” there.

ty  :azn:

Log in to reply