This library mod is for other modders to include in their mods. There is no point downloading this on its own as a player.
UnitStat Background Mod v.ZF = FE 1.34
As part of making the game have greater depth, which is the purpose of any mod, I will be releasing a UnitStat Background mod. The purpose of this library-type mod is to flag unittypes, items and traits with certain UnitStats that will allow the modders to identify them in various scenarios. It is a bit difficult to explain, so I will simply give an example: Imagine a dragon has UnitStat_BG_IsDragon = 1. Then we put this modifier on a weapon:
The result is a weapon that gains +10 accuracy whenever it attacks against a dragon. Voilá, a dragon-slaying weapon. Or a trait. Such UnitStats can also be referred to in Calculate tags in spells, for example to make a damage spell deal even more damage against a dragon.
Note that this mod will only function as a library of back-ground unitstats. It will be up to the modders to use the unitstats as they see fit.
I want to open up the floor for what unitstat flags the modding community expect to find in such a mod.
This is my planned list of unitstats. Note that these unitstats will not have defaultvalue set to 0 for all units, they will simply have 0 by virtue of not having it.
UnitStat_BG_IsUsingMount - 1 for mounted units, 0 for un-mounted units
Unit UnitStats: (stats marked ^ are given through traits to help players understand what is what)
UnitStat_BG_IsChampion - 1 for champions and sovereigns
UnitStat_BG_IsSovereign - 1 for sovereigns, 0 for others (note that everyone with IsSovereign also have IsChampion)
UnitStat_BG_IsMilitia^ - 1 for city militia, 0 for all others
UnitStat_BG_IsHumanoid - 1 for any unit that resembles a human in shape, not necessarily in size
UnitStat_BG_IsNotAlive^ - 1 for any unit that does not have blood pumping in its veins, is incapable of consuming nutrition, and is incapable of reproduction
UnitStat_BG_IsEmpire - 1 for sovereigns, champions and designed units from empire factions. 0 for others
UnitStat_BG_IsKingdom - 1 for sovereigns, champions and designed units from Kingdom factions. 0 for others
UnitStat_BG_IsRace_ - These unitstats are given to mark all champions, sovereigns and designed units from certain racetypes. These are the "races" that appear in Unit Details when you create a normal unit. The wildcard (*) is replaced by the name of the race as it appears in-game. The vanilla game contains 10 races that have the following names: Altarians, Mancers, Ironeers, Amarians, Tarthans, Krax, Wraiths, Trogs, Urxen, Quendar. For example, all of the race Altarians have UnitStat_BG_IsRace_Altarians = 1
UnitStat_BG_IsMonster - for all units considered monsters. Note that this applies to recruited monsters as well. Anything that is not humanoid is considered a monster.
UnitStat_BG_IsDragon - 1 for dragon monsters, 0 for others
UnitStat_BG_IsElemental - 1 for elementals, 0 for others
UnitStat_BG_IsBeast - 1 for beasts, 0 for others
UnitStat_BG_IsTwisted - 1 for Twisted creatures, 0 for others
UnitStat_BG_IsConstruct - 1 for construct creatures, 0 for others (basically golems)
UnitStat_BG_IsDemon^ - 1 for demons, 0 for others
UnitStat_BG_IsGod^ - 1 for the 5 elemental gods found in the wildlands and other godtype units at your discretion, 0 for others
UnitStat_BG_IsSummoned^ - 1 for units that are specifically summoned through magical spells, and NOT those trained. 0 for others
UnitStat_BG_IsImmortal^ - 1 for certain units that cannot die from old age. In the core game, these include: Titans, Dragons and Butchermen, Elemental gods (NOT all elementals!). 0 for all others. Keep in mind constructs are not immortal and may die from old age (they basically turn to dust after a few thousand years), but they are also UnitStat_BG_IsNotAlive^ 1.
UnitStat_BG_IsOversized^ - It is 1 for units that are substantially larger than a single human-sized mounted man. Note that this indicates that a singular unit of this sort is oversized - a unit does not become oversized if it goes from 1 to 9 members. Dragons, Giant Slags, Giant Drakes, elemental gods, and so on. It is 0 for all others.
UnitStat_BG_IsMale - 1 for units specifically marked male. 0 for others. Note: This is only applied to champions and sovereigns and troops. Practically noone else has a gender. It is perfectly possible for a unit to have 0 in both _IsMale and _IsFemale.
UnitStat_BG_IsFemale - 1 for units specifically marked female. 0 for others. Note: This is only applied to champions and sovereigns and troops. Practically noone else has a gender. It is perfectly possible for a unit to have 0 in both _IsMale and _IsFemale.
UnitStat_BG_IsFlying^ - 0 (default) = incapable of flight. 1 = Capable of Flying (does not need to be constantly flying)
Other Custom UnitStats:
UnitStat_BG_HasInjuries - 0 for all, each injury suffered by a champion adds +1. Note that there are many "flaws" that are NOT injuries. This tag is specifically for champion injuries suffered due to incapacitation in combat.
UnitStat_BG_Spellbooks - between 0 and 5, depending on how many spellbooks this champion/sov/unit has. It is enough to have rank 1 in a spellbook to get +1 in this unitstat.
UnitStat_BG_GreyMagic - Between 0 and 25+, depending on how many spelltraits this champion/sov/unit has. Each spelltrait adds 1, so a champion with Death2 Fire3 would have UnitStat_BG_GreyMagic = 5.
A_Additive_TileYieldGrain - Faction-wide bonus additive to Grains. Ex: +1 Grain in every city
A_Additive_TileYieldMaterials - Faction-wide bonus additive to Materials. Ex: -1 Material in every city
A_Additive_TileYieldEssence - Faction-wide bonus additive to Essence. Ex: -1 Essence in every city
UnitStat_BG_IsInSwamp - 0 for all units, 1 for those who are occupying a Swamp tile on the strategic map
UnitStat_BG_IsInPlains - 0 for all units, 1 for those who are occupying a Plains tile on the strategic map
UnitStat_BG_IsInHills - 0 for all units, 1 for those who are occupying a Hills tile on the strategic map
UnitStat_BG_IsInDesert - 0 for all units, 1 for those who are occupying a Desert tile on the strategic map
UnitStat_BG_IsInForest - 0 for all units, 1 for those who are occupying a Forest tile on the strategic map
UnitStat_BG_IsInCity - 0 for all units, 1 for those who are occupying a City tile on the strategic map
UnitStat_BG_IsInRiver - 0 for all units, 1 for those who are occupying a River tile on the strategic map
UnitStat_BG_IsUsingSmallShield - 1 for units with a small or normal shield equipped, 0 for others. Does not mark tower shields.
UnitStat_BG_IsUsingTowerShield - 1 for units with a tower shield equipped, 0 for others. Does not mark non-tower shields
UnitStat_BG_IsUsingSpear - 1 for units with a spear, 0 for others
UnitStat_BG_IsUsingStaff - 1 for units with a staff, 0 for others
UnitStat_BG_IsUsingBow - 1 for units with a bow, 0 for others
UnitStat_BG_IsUsingMace - 1 for units with a mace, 0 for others
UnitStat_BG_IsUsingSword - 1 for units with a sword, 0 for others
UnitStat_BG_IsUsingAxe - 1 for units with a axe, 0 for others
UnitStat_BG_IsUsingDagger - 1 for units with a dagger, 0 for others
UnitStat_BG_IsUsingTwoHanded - 1 for units with a Two-handed weapon equipped, 0 for others. This counts for all weaponry that requires both hands to use, such as staffs, bows and spear.
UnitStat_BG_IsUsingOneHanded - 1 for units with a one-handed weapon equipped, 0 for others.
UnitStat_BG_IsUsingDualWield - 1 for units with two one-handed weapons equipped, 0 for others
UnitStat_BG_IsWearingLeather - This value is between 0 and 7 - each equipped leatherpiece adds 1, chest and leggings add 2 instead of 1
UnitStat_BG_IsWearingChainmail - This value is between 0 and 7 - each equipped chainmailpiece adds 1, chest and leggings add 2 instead of 1
UnitStat_BG_IsWearingPlate - This value is between 0 and 7 - each equipped platepiece adds 1, chest and leggings add 2 instead of 1
UnitStat_Bg_MagicalNature - A custom value given to items of a magical nature. Any non-magical item should have nothing (0). As a base-line, magical items will start at UnitStat_Bg_MagicalNature = 100. Particularly powerful, or reality-bending items might have 200 or even 300. There is no clear line between rarity of items and this stat, because the game has many "uncommon" magical and non-magical items. Items will display their number in the item tooltip, unless it is 0 in case it won't be mentioned. Accessories can also have this stat.
UnitStat_BG_IsRanged - 1 for any weapon that turns the main attack of a unit into a ranged attack. 0 for others
UnitStat_BG_IsMelee - 1 for any melee weapon, and any unarmed monster. 0 for others