Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
  • 0
furyweb

Sprite movement while performing action

Question

May sound daft but here goes...     So I want the sprite to move forward while performing an animation (attack). Is this possible at all?. Its a range attacked but steps forward as its throwing the projectile.

Share this post


Link to post

4 answers to this question

Recommended Posts

  • 0

yea, just have the enemy do Chase actions during their attack animations, with only the actual release of the projectile/melee attack being the respective attack action you're using. If you want them to move while releasing the projectile/meleeing as well, you can make the actual attack action be 0 tics long and the next state being the same frame of animation, but with another Chase action. This will cause the attack to happen and instantly start chasing again, creating the illusion of the enemy attacking while moving.

 

a little bit of a jumbled explanation so just let me know if you need pictures to go along with it or something c:

Share this post


Link to post
  • 0

if i understand you correctly frien  than what you wanna do is run the animation first, then the attack, So;

 

BADY A 1 A_Chasetarget

BADY B 1 (step frame)

BADY A 0 A_Firecustommissile(x,x,x,x)

BADY A 1 (frame to catch balance?)

 

This is the only way i could think to do it, unless you wanna use a thrust thing, which would probably go too far.

I hope this helps.

 

EDIT:

Bonnie said this way better, so i edited my post to *somewhat* match his description.

I find that experimentation is the greatest teacher, as far as speeds as whatknot. 

but it is up to you. 

 

P.s, Good question!

Edited by zaszthedestroyer

Share this post


Link to post
  • 0

When using A_Chase inside an attack animation, make sure to use it with appropriate parameters and possibly flags (see here) to prevent it from automatically jumping into melee attack state when coming into melee range or back at the start of the ranged attack animation when randomly deciding to perform another ranged attack despite being in the middle of performing one.

Share this post


Link to post
  • 0

Hexen does that, so if you're using ZDoom, you can simply look at how afrits and bishops are doing it.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×