• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!

Pick Weakest Unit

Status
Not open for further replies.

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,202
Firstly by difining what weak means.

If you mean lowest approximate duribility then you use the simple minimum algerthim for on the sum of health and shield for all units to select from.

Basically if there is 1 or more valid units to effect, get the first one and then note it as the lowest. The compare the second (if one exists) to the lowest and if it is lower, make it the lowest. Repeat until all units are checked and you will have your lowest.
 
Status
Not open for further replies.
Top