If I may make a humble suggestion, I've long thought it would be
useful to have a before-animation death even and then an
after-animation death event. Often you want dialogue with the dying
character, and it really doesn't make sense for the death animation to
fire _before_ his dialogue... what, is he speaking from beyond the
grave? But, you also often want dialogue unrelated to the character,
in which case you probably want the death animation firing first,
instead of randomly at the end of the dialogue - "oh, right, this
dialogue was because we just killed the bay guy".

In fact, often you want both of them - you want the bad guy to say
"argh, my comrades will avenge me", then for him to fall down dead,
then for the heroes to discuss their plans for the next scenario or
whatever. This can't be done easily ATM, as far as I know, but it
would be easy to do with this change - you just have a "before death"
event and a "die" event, in the "before death" event you have the
enemy leader's dialogue, in the "die" event you have everything that
happens _after_ the death animation of the enemy leader. In between is
the actual death of the leader, which occurs exactly as normal - this
is where the death animation occurs, where the unit with the kill
levels up, if applicable, etc.

Though I don't know anything about the actual code implementing this
stuff, from reading what you've written here this would make the
bugfix easier, AND it would actually make WML more useful, so I
thought I'd throw it out there.

~Turin

On Nov 25, 2007 12:54 AM, Eric S. Raymond <[EMAIL PROTECTED]> wrote:
> John McNabb <[EMAIL PROTECTED]>:
> > AIO has a "die" event in it for the bad guys, but it does not have an
> > endlevel tag inside the event.
> > Two brothers, does:
> >         [endlevel]
> >             result=victory
> >             bonus=yes
> >         [/endlevel]
> > Thus, in AIO, the victory is declared by the default check on whether
> > the sides have leaders, whereas in Two brothers the victory condition
> > is set inside the event, thus throwing the end_of_level exception...
>
> Yeah, I'd say that confirms it.
>
> I've looked into this, and it isn't going to be trivial to fix.  The
> problem is that simply moving the firing of the the die event to after
> the unit is deleted would solve this problem, but would make the unavailable
> to find by description when you're scripting death speeches.
>
> I suppose we could have the victory and defeat events do a scavenging pass
> that would look for units with HP <= 0 and delete them.
> --
>                 <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>
>
> _______________________________________________
>
> Wesnoth-dev mailing list
> Wesnoth-dev@gna.org
> https://mail.gna.org/listinfo/wesnoth-dev
>



-- 
Joseph Simmons

Túrin Turambar, master of doom, by doom mastered

_______________________________________________
Wesnoth-dev mailing list
Wesnoth-dev@gna.org
https://mail.gna.org/listinfo/wesnoth-dev

Reply via email to