Dugy / Legend_of_the_Invincibles

An add-on campaign for the Battle for Wesnoth game
GNU General Public License v3.0
40 stars 22 forks source link

Animation missing error #291

Open arobinson opened 3 years ago

arobinson commented 3 years ago

image

LotI2-Across the Barren Land-Auto-Save48.gz

To reproduce advance Miry to a chaos rider in the cave

dalong76 commented 3 years ago

I believe the cause is that the item Overdrawer gives you a bonus attack which is a clone of the original crossbow attack. Since the chaos rider has no crossbow attack, there is no attack to clone, thus no animation to clone, and thus you get that error. Not easy to fix.

Dugy commented 3 years ago

Yeah, I didn't think about leftover items when designing the bonus attacks. There are basically two solution to this:

  1. If no attack to derive the bonus from is found, the bonus attack does not appear
  2. Add a basic attack animation to every unit that can have leftover items The first option is far easier to implement. The second option would be much more interesting from the point of allowing players to create interesting units, however, it leads to additional problems like liches (and everything they can advance to) that can have leftover items from pretty much any type due to the necromancy ability.

What do you guys think about it?

dalong76 commented 3 years ago

I don't think your second is worth the effort. A third possibility is to create a generic animation for the bonus attack. In this case, the generic animation would be just the missile. The unit doesn't move, but the missile flies, so there is animation. It isn't perfect, but it is far easier. A melee attack could be just a generic weapon swinging around.