diff --git a/lua/stats.lua b/lua/stats.lua index 111084b9..57c3bd4a 100644 --- a/lua/stats.lua +++ b/lua/stats.lua @@ -629,18 +629,6 @@ function wesnoth.update_stats(original) if sorts_owned.amulet or sorts_owned.ring or sorts_owned.cloak or sorts_owned.limited then table.insert(new_overlays, "misc/orb-overlay.png") end - local has_leadership_item = false - for _, eff in loti.unit.effects(remade) do - if eff.apply_to == "new_ability" then - local abilities = wml.get_child(eff, "abilities") - if abilities and wml.get_child(abilities, "leadership") then - has_leadership_item = true - end - end - end - if has_leadership_item then - table.insert(new_overlays, "misc/fist-overlay.png") - end local overlays_object = { "object", { visual_provider = true, { "effect", { apply_to = "overlay", add = table.concat(new_overlays, ",")}}}} table.insert(visible_modifications, overlays_object) diff --git a/units/Argan_lich.cfg b/units/Argan_lich.cfg index 7abd4987..955770a8 100644 --- a/units/Argan_lich.cfg +++ b/units/Argan_lich.cfg @@ -109,7 +109,7 @@ Advancements with crossbow add great precision." image="portraits/humans/marshal.png" [/portrait] [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} {ABILITY_SOUL_EATER} {ABILITY_REGENERATES} {ABILITY_SUBMERGE} diff --git a/units/Duke.cfg b/units/Duke.cfg index e500ab86..9c3bb67f 100644 --- a/units/Duke.cfg +++ b/units/Duke.cfg @@ -39,7 +39,7 @@ impact=75 [/resistance] [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} {ABILITY_CHARGE_LEADERSHIP} [/abilities] [attack] @@ -237,7 +237,7 @@ [effect] apply_to=remove_ability [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [/effect] [effect] diff --git a/units/Elvish_Warlord.cfg b/units/Elvish_Warlord.cfg index 2063792b..d2db0544 100644 --- a/units/Elvish_Warlord.cfg +++ b/units/Elvish_Warlord.cfg @@ -38,7 +38,7 @@ image="portraits/elves/captain.png" [/portrait] [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} {ABILITY_MARKSMAN_LEADERSHIP} [/abilities] [attack] @@ -318,7 +318,7 @@ [effect] apply_to=remove_ability [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [/effect] [effect] diff --git a/units/Fire_Dragon.cfg b/units/Fire_Dragon.cfg index e2e33239..bda3a233 100644 --- a/units/Fire_Dragon.cfg +++ b/units/Fire_Dragon.cfg @@ -8,7 +8,7 @@ image="units/enemies/fire-dragon.png" {DEFENSE_ANIM_RANGE "units/monsters/fire-dragon.png" "units/monsters/fire-dragon.png" {SOUND_LIST:DRAKE_HIT} melee} [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] hitpoints=101 movement_type=drakefly diff --git a/units/Goblin_Warbaner.cfg b/units/Goblin_Warbaner.cfg index 4c36bc9c..695a5e1a 100644 --- a/units/Goblin_Warbaner.cfg +++ b/units/Goblin_Warbaner.cfg @@ -20,7 +20,7 @@ die_sound={SOUND_LIST:GOBLIN_DIE} {DEFENSE_ANIM "units/orcs/goblinwarbanner.png" "units/orcs/goblinwarbanner.png" {SOUND_LIST:GOBLIN_HIT} } [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [portrait] size=400 @@ -323,7 +323,7 @@ [effect] apply_to=remove_ability [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [/effect] [effect] diff --git a/units/Infernal_Knight.cfg b/units/Infernal_Knight.cfg index c80b6db0..859923b0 100644 --- a/units/Infernal_Knight.cfg +++ b/units/Infernal_Knight.cfg @@ -23,7 +23,7 @@ description= _ "Tales are told of the mightiest warriors and generals, who, cursed with hate and stung by betrayal, have experimented with demonic magic and returned back to this world as Infernal Knights. Wielding the same weapons as in life, they command both fire and the Undead in their quest for revenge." die_sound=lich-die.ogg [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} {ABILITY_SUBMERGE} [/abilities] [portrait] @@ -300,7 +300,7 @@ [effect] apply_to=remove_ability [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [/effect] [effect] diff --git a/units/Lich_King.cfg b/units/Lich_King.cfg index 019afe58..053f4e38 100644 --- a/units/Lich_King.cfg +++ b/units/Lich_King.cfg @@ -19,7 +19,7 @@ description= _ "Lich Kings are powerful undead warriors with free will and magic powers. Unlike other undead, they are not obeying a master, they are raising and controlling their minions, and unlike liches, they are leading their minions into battles." die_sound=lich-die.ogg [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} {ABILITY_SUBMERGE} [/abilities] [portrait] @@ -387,7 +387,7 @@ [effect] apply_to=remove_ability [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [/effect] [effect] diff --git a/units/The_Prince.cfg b/units/The_Prince.cfg index 328fcd7b..8cd6be6e 100644 --- a/units/The_Prince.cfg +++ b/units/The_Prince.cfg @@ -45,7 +45,7 @@ arcane=60 [/resistance] [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] #textdomain wesnoth-units [attack] diff --git a/units/corruption.cfg b/units/corruption.cfg index 09178cd6..8b3584ff 100644 --- a/units/corruption.cfg +++ b/units/corruption.cfg @@ -673,7 +673,7 @@ [/portrait] {DEFENSE_ANIM "units/elves-wood/captain-defend.png" "units/elves-wood/captain.png" {SOUND_LIST:ELF_HIT}} [abilities] - {ABILITY_LEADERSHIP} + {ABILITY_LEADERSHIP_LOTI} [/abilities] [attack] name=sword diff --git a/utils/abilities.cfg b/utils/abilities.cfg index c42528d6..ae623c21 100644 --- a/utils/abilities.cfg +++ b/utils/abilities.cfg @@ -1,3 +1,27 @@ +#textdomain wesnoth-help + +#define ABILITY_LEADERSHIP_LOTI + # same what mainline but with overlay_image_self attribute + [leadership] + id=leadership + value="(25 * (level - other.level))" + cumulative=no + name= _ "leadership" + female_name= _ "female^leadership" + description= _ "This unit can lead other troops in battle. + +All adjacent lower-level units from the same side deal 25% more damage for each difference in level." + special_note={INTERNAL:SPECIAL_NOTES_LEADERSHIP} + affect_self=no + overlay_image_self="misc/fist-overlay.png" + [affect_adjacent] + [filter] + formula="level < other.level" + [/filter] + [/affect_adjacent] + [/leadership] +#enddef + #textdomain wesnoth-loti #define WEAPON_SPECIAL_PLAGUE_TYPE_LOTI TYPE LANGUAGE_TYPE [plague] @@ -561,6 +585,7 @@ Enemy units cannot see this unit during dawn or dusk, except if they have units female_name={NAME}+_" ("+{INTENSITY}+_")" description= _ "Adjacent allies will do "+{INTENSITY}+_"% more damage." affect_self=no + overlay_image_self="misc/fist-overlay.png" [affect_adjacent] adjacent=n,ne,se,s,sw,nw [/affect_adjacent] @@ -577,6 +602,7 @@ Enemy units cannot see this unit during dawn or dusk, except if they have units description= _ "This unit can lead your own units that are next to it, making them fight better. Adjacent own units of lower level will do more damage in battle. When a unit adjacent to, of a lower level than, and on the same side as a unit with Leadership engages in combat, its attacks do 25% more damage times the difference in their levels." special_note = _"The leadership of this unit enables adjacent units of the same side to deal more damage in combat, though this only applies to units of lower level." affect_self=no + overlay_image_self="misc/fist-overlay.png" [affect_adjacent] [filter] formula="level < " + {LEVEL} diff --git a/utils/item_list.cfg b/utils/item_list.cfg index 93f71a9f..5a95f20b 100644 --- a/utils/item_list.cfg +++ b/utils/item_list.cfg @@ -18,7 +18,7 @@ #define ITEM_LIST #wmllint: markcheck off [object] - name= _ "Glitch Item" #Never drops, but the first item on the list always has some problems. + name= _ "Glitch Item" #Never drops, but the first item on the list always has some problems. image=items/book1.png number=0 sort=limited @@ -1079,6 +1079,7 @@ Stand up and see the sky turn bright" Adjacent own units will do 30% more damage and will have 20% better resistances." affect_self=no + overlay_image_self="misc/fist-overlay.png" [affect_adjacent] adjacent=n,ne,se,s,sw,nw [/affect_adjacent] @@ -1250,7 +1251,7 @@ Adjacent own units will do 30% more damage and will have 20% better resistances. flavour=_"If you cannot outrun the knights, why do you even try?" [/object] [object] - name= _ "Boots of Evanescence" # I am not a fan of that band. They are nothing compared to many other female-fronted metal bands. And women as frontmen aren't badass enough anyway. + name= _ "Boots of Evanescence" # I am not a fan of that band. They are nothing compared to many other female-fronted metal bands. And women as frontmen aren't badass enough anyway. image="items/boots.png~GS()~O(50%)" defence=5 number=71 @@ -1376,7 +1377,7 @@ Adjacent own units will do 30% more damage and will have 20% better resistances. flavour=_"Under black skies, people start losing faith that the sun will ever rise." [/object] [object] - name= _ "Colossally Colossal Arch-Devilish Blade of Universal Annihilation" #Just parodying the prefixes and suffixes of random items in other games + name= _ "Colossally Colossal Arch-Devilish Blade of Universal Annihilation" #Just parodying the prefixes and suffixes of random items in other games image=items/sword.png number=80 sort=sword @@ -1400,6 +1401,7 @@ Adjacent own units will do 30% more damage and will have 20% better resistances. Adjacent own units will do 20% more damage and will have 10% better resistances." affect_self=no + overlay_image_self="misc/fist-overlay.png" [affect_adjacent] adjacent=n,ne,se,s,sw,nw [/affect_adjacent] @@ -8561,7 +8563,7 @@ Showshaunshog proved him wrong by collecting condensed water from smoke." arcane_resist=30 flavour=_"Do not justify your actions with the name of a man made deity." [/object] - [object] #Been formerly cheaper! + [object] #Been formerly cheaper! name= _ "Purity" image=items/leather-pack.png number=539 # Out of order! @@ -9456,7 +9458,7 @@ Showshaunshog proved him wrong by collecting condensed water from smoke." [object] name= _ "Dugi's Wrath" image=items/leather-pack.png - number=600 #Highest index - will be the last one listed, because it is the strongest - and probably unobtainable + number=600 #Highest index - will be the last one listed, because it is the strongest - and probably unobtainable sort=weaponword obsidians=3 topazes=3