Index: binaries/data/mods/public/simulation/components/Loot.js
===================================================================
--- binaries/data/mods/public/simulation/components/Loot.js
+++ binaries/data/mods/public/simulation/components/Loot.js
@@ -19,8 +19,7 @@
{
let ret = {};
for (let res of Resources.GetCodes())
- ret[res] = +(this.template[res] || 0);
-
+ ret[res] = ApplyValueModificationsToEntity("Loot/"+res, +(this.template[res] || 0), this.entity);
return ret;
};
Index: binaries/data/mods/public/simulation/data/technologies/advanced_unit_bonus.json
===================================================================
--- binaries/data/mods/public/simulation/data/technologies/advanced_unit_bonus.json
+++ binaries/data/mods/public/simulation/data/technologies/advanced_unit_bonus.json
@@ -3,22 +3,29 @@
"icon": "upgrade_advanced.png",
"tooltip": "Units promoted to the advanced class gain a lot of quality: 20% extra health, 1 extra armor level of every type, 20% extra attack for melee units, 4m extra range and 5% better precision for ranged units, faster movement speeds and extra heal speed and range for healers.",
"modifications": [
- {"value": "Health/Max", "multiply": 1.2 },
- {"value": "Armour/Hack", "add": 1 },
- {"value": "Armour/Pierce", "add": 1 },
- {"value": "Armour/Crush", "add": 1 },
- {"value": "Attack/Capture/Value", "add": 0.4 },
- {"value": "ResourceGatherer/BaseSpeed", "multiply": 0.5 },
- {"value": "UnitMotion/WalkSpeed", "add": 0.5, "affects": "Infantry"},
- {"value": "UnitMotion/WalkSpeed", "add": 1, "affects": "Cavalry" },
- {"value": "Attack/Ranged/MaxRange", "add": 4, "affects": "Ranged" },
- {"value": "Vision/Range", "add": 4, "affects": "Ranged" },
- {"value": "Attack/Ranged/Spread", "multiply": 0.95, "affects": "Ranged" },
- {"value": "Attack/Melee/Hack", "multiply": 1.2, "affects": "Melee" },
- {"value": "Attack/Melee/Pierce", "multiply": 1.2, "affects": "Melee" },
- {"value": "Vision/Range", "add": 3, "affects": "Healer" },
- {"value": "Heal/Range", "add": 3, "affects": "Healer" },
- {"value": "Heal/HP", "add": 5, "affects": "Healer" }
+ {"value": "Health/Max", "multiply": 1.2 },
+ {"value": "Armour/Hack", "add": 1 },
+ {"value": "Armour/Pierce", "add": 1 },
+ {"value": "Armour/Crush", "add": 1 },
+ {"value": "Attack/Capture/Value", "add": 0.4 },
+ {"value": "ResourceGatherer/BaseSpeed", "multiply": 0.5 },
+ {"value": "UnitMotion/WalkSpeed", "add": 0.5, "affects": "Infantry" },
+ {"value": "UnitMotion/WalkSpeed", "add": 1, "affects": "Cavalry" },
+ {"value": "Attack/Ranged/MaxRange", "add": 4, "affects": "Ranged" },
+ {"value": "Vision/Range", "add": 4, "affects": "Ranged" },
+ {"value": "Attack/Ranged/Spread", "multiply": 0.95, "affects": "Ranged" },
+ {"value": "Attack/Melee/Hack", "multiply": 1.2, "affects": "Melee" },
+ {"value": "Attack/Melee/Pierce", "multiply": 1.2, "affects": "Melee" },
+ {"value": "Vision/Range", "add": 3, "affects": "Healer" },
+ {"value": "Heal/Range", "add": 3, "affects": "Healer" },
+ {"value": "Heal/HP", "add": 5, "affects": "Healer" },
+ {"value": "Loot/food", "add": 5 },
+ {"value": "Loot/wood", "add": 5, "affects": "Infantry" },
+ {"value": "Loot/wood", "add": 5, "affects": "Cavalry" },
+ {"value": "Loot/stone", "add": 5, "affects": "Sling" },
+ {"value": "Loot/metal", "add": 5, "affects": "Sword" },
+ {"value": "Loot/xp", "multiply": 1.2, "affects": "Infantry" },
+ {"value": "Loot/xp", "multiply": 1.2, "affects": "Cavalry" }
],
"affects": ["Advanced Unit", "Elite Unit"]
}
Index: binaries/data/mods/public/simulation/data/technologies/elite_unit_bonus.json
===================================================================
--- binaries/data/mods/public/simulation/data/technologies/elite_unit_bonus.json
+++ binaries/data/mods/public/simulation/data/technologies/elite_unit_bonus.json
@@ -3,22 +3,29 @@
"icon": "upgrade_elite.png",
"tooltip": "Units trained to the elite class gain a lot of quality: 20% extra health, 1 extra armor level of every type, 20% extra attack for melee units, extra range and better precision for ranged units, faster movement speeds and extra heal speed and range for healers.",
"modifications": [
- {"value": "Health/Max", "multiply": 1.2 },
- {"value": "Armour/Hack", "add": 1 },
- {"value": "Armour/Pierce", "add": 1 },
- {"value": "Armour/Crush", "add": 1 },
- {"value": "Attack/Capture/Value", "add": 0.4 },
- {"value": "ResourceGatherer/BaseSpeed", "multiply": 0.5 },
- {"value": "UnitMotion/WalkSpeed", "add": 0.5, "affects": "Infantry"},
- {"value": "UnitMotion/WalkSpeed", "add": 1, "affects": "Cavalry" },
- {"value": "Attack/Ranged/MaxRange", "add": 4, "affects": "Ranged" },
- {"value": "Vision/Range", "add": 4, "affects": "Ranged" },
- {"value": "Attack/Ranged/Spread", "multiply": 0.95, "affects": "Ranged" },
- {"value": "Attack/Melee/Hack", "multiply": 1.2, "affects": "Melee" },
- {"value": "Attack/Melee/Pierce", "multiply": 1.2, "affects": "Melee" },
- {"value": "Vision/Range", "add": 3, "affects": "Healer" },
- {"value": "Heal/Range", "add": 3, "affects": "Healer" },
- {"value": "Heal/HP", "add": 5, "affects": "Healer" }
+ {"value": "Health/Max", "multiply": 1.2 },
+ {"value": "Armour/Hack", "add": 1 },
+ {"value": "Armour/Pierce", "add": 1 },
+ {"value": "Armour/Crush", "add": 1 },
+ {"value": "Attack/Capture/Value", "add": 0.4 },
+ {"value": "ResourceGatherer/BaseSpeed", "multiply": 0.5 },
+ {"value": "UnitMotion/WalkSpeed", "add": 0.5, "affects": "Infantry" },
+ {"value": "UnitMotion/WalkSpeed", "add": 1, "affects": "Cavalry" },
+ {"value": "Attack/Ranged/MaxRange", "add": 4, "affects": "Ranged" },
+ {"value": "Vision/Range", "add": 4, "affects": "Ranged" },
+ {"value": "Attack/Ranged/Spread", "multiply": 0.95, "affects": "Ranged" },
+ {"value": "Attack/Melee/Hack", "multiply": 1.2, "affects": "Melee" },
+ {"value": "Attack/Melee/Pierce", "multiply": 1.2, "affects": "Melee" },
+ {"value": "Vision/Range", "add": 3, "affects": "Healer" },
+ {"value": "Heal/Range", "add": 3, "affects": "Healer" },
+ {"value": "Heal/HP", "add": 5, "affects": "Healer" },
+ {"value": "Loot/food", "add": 5 },
+ {"value": "Loot/wood", "add": 5, "affects": "Infantry" },
+ {"value": "Loot/wood", "add": 5, "affects": "Cavalry" },
+ {"value": "Loot/stone", "add": 5, "affects": "Sling" },
+ {"value": "Loot/metal", "add": 5, "affects": "Sword" },
+ {"value": "Loot/xp", "multiply": 1.2, "affects": "Infantry" },
+ {"value": "Loot/xp", "multiply": 1.2, "affects": "Cavalry" }
],
"affects": ["Elite Unit"]
}
Index: binaries/data/mods/public/simulation/templates/units/spart_champion_infantry_sword.xml
===================================================================
--- binaries/data/mods/public/simulation/templates/units/spart_champion_infantry_sword.xml
+++ binaries/data/mods/public/simulation/templates/units/spart_champion_infantry_sword.xml
@@ -24,10 +24,6 @@
units/spart_champion_infantry_sword.png
phase_town
-
- 2.0
- 2.0
-
units/spartans/champion_infantry_sword.xml