Specific questions about unit frames managing in combat animations

The place to post your WML questions and answers.

Moderator: Forum Moderators

Forum rules
  • Please use [code] BBCode tags in your posts for embedding WML snippets.
  • To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
Post Reply
Spitoven
Posts: 10
Joined: December 2nd, 2019, 2:52 pm

Specific questions about unit frames managing in combat animations

Post by Spitoven »

Hello! :D

I have two questions I couldn't solve by looking into WML examples:

- How can I display two different defense animations for the same unit depending on it getting hit or missed?

- How can I horizontaly flip an unit image within an attack_anim frame tag (other than calling for another image)? I tried using ~FL and it didn't work... More specifically, I tried:
- image="units/natives/fishbreath.png~FL:400" => image not found
- image="units/natives/fishbreath.png:400"~FL => image not flipped
- image="units/natives/fishbreath.png:400~FL" => image not flipped

Thank you! ^_^

EDIT: I'm on version 1.15.15 :geek:
User avatar
Straff
Posts: 86
Joined: September 27th, 2020, 2:53 pm

Re: Specific questions about unit frames managing in combat animations

Post by Straff »

Code: Select all

image="units/natives/fishbreath.png~FL()"
gnombat
Posts: 706
Joined: June 10th, 2010, 8:49 pm

Re: Specific questions about unit frames managing in combat animations

Post by gnombat »

Spitoven wrote: August 7th, 2021, 3:48 pm - How can I display two different defense animations for the same unit depending on it getting hit or missed?
Does the lancer do this?
Spitoven
Posts: 10
Joined: December 2nd, 2019, 2:52 pm

Re: Specific questions about unit frames managing in combat animations

Post by Spitoven »

gnombat wrote: August 7th, 2021, 8:32 pm
Spitoven wrote: August 7th, 2021, 3:48 pm - How can I display two different defense animations for the same unit depending on it getting hit or missed?
Does the lancer do this?
Oh, thank you! Didn't notice that one! :D
Straff wrote: August 7th, 2021, 4:44 pm

Code: Select all

image="units/natives/fishbreath.png~FL()"
Oh... thanks, but... where do I put the duration then? (400) ^_^
Post Reply