New unit damaged state coming

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

New unit damaged state coming

ComradeKev
Administrator
In working up the airbase logic, I'm finding that it'd be nice to be able to define a third state of being for a unit other than the base and _hit state.  This third state will be _disabled.

I hacked an image up  the attachment to this post, but if someone would like to do something for inclusion with the next release, that'd be great.  I was thinking the broken image of the air/naval bases would be the one for disabled, and I added some flames to the base image to be used as the _hit icon.

This way, a player can visually determine which of his units are hit, but still functional -vs those that should be repaired immediately.
If emailing me at ComradeKev at yahoo.com , please add TripleA to the subject line
Reply | Threaded
Open this post in threaded view
|

Re: New unit damaged state coming

squid_daddy
This post was updated on .
noticed today after updating that there is now a conflict in BattleDisplay with my current code.
you added a parameter to the tabledata constructor for disabled units. these calls were modified in my
support patch.

Simple to fix, but just pointing out, my support patch will become increasingly invalid the more
shared code like this is modified in the meantime.

for the record there is an important error in my patch here.
i call
Collection unitCategories = UnitSeperator.categorize(units, null, false, false, true);
it should be
Collection unitCategories = UnitSeperator.categorize(units, null, false, false, false);

need to process categories in order they appear in units, not the rather arbitrary order
the categorize sort returns in, as units is pre-sorted in strength order.
that doesn't effect the contents of the categories, only the order they come back in.
so without sorting a disabled unit for example might appear in the column either before or
after a non-disabled one.



 
Reply | Threaded
Open this post in threaded view
|

Re: New unit damaged state coming

ComradeKev
Administrator
Understood, thanks for updating it. I'm trying to find a good place to stop the scrambling code I'm working on so I can apply your patch. It'll be pretty soon though.
If emailing me at ComradeKev at yahoo.com , please add TripleA to the subject line