Mercenary price

Users who are viewing this thread

I think I can see what your problem is. As you have probably noticed, all troops have rating generated automatically. It takes several factors into account, mainly troop's skills, proficiencies and equipment rating. Equipment rating is, again, generated automatically. Mod assigns rating to each item, finds the one with highest rating, assigns it 100%, and other items receive their respective percentages. When calculating troop rating, this percentage is taken into account, not the actual numeric rating. The final price is based on troop's overall rating, with cost increased for mercenaries and cavalrymen. So if you want to reduce the price, you can:
-modify equipment
-modify troop's rating by tweaking it's skills, proficiencies and equip
-modify the script which generates the actual price (which would be script_hub_determine_purchase_cost in Center Management)

Or, if you feel like it, you can overhaul the whole system - there is a slot_troop_purchase_cost which holds troop's price. You could just assign a static number to this slot (ideally, you would do this in hub_scripts, where abilities, prerequisites and such are assigned) and just change script_hub_determine_purchase_cost to generate a rating, based on your static cost, and return that in reg1. Apparently, the game engine needs script_hub_determine_purchase_cost, so don't skip on that.
 
Leifdin said:
I think I can see what your problem is. As you have probably noticed, all troops have rating generated automatically. It takes several factors into account, mainly troop's skills, proficiencies and equipment rating. Equipment rating is, again, generated automatically. Mod assigns rating to each item, finds the one with highest rating, assigns it 100%, and other items receive their respective percentages. When calculating troop rating, this percentage is taken into account, not the actual numeric rating. The final price is based on troop's overall rating, with cost increased for mercenaries and cavalrymen. So if you want to reduce the price, you can:
-modify equipment
-modify troop's rating by tweaking it's skills, proficiencies and equip
-modify the script which generates the actual price (which would be script_hub_determine_purchase_cost in Center Management)

Or, if you feel like it, you can overhaul the whole system - there is a slot_troop_purchase_cost which holds troop's price. You could just assign a static number to this slot (ideally, you would do this in hub_scripts, where abilities, prerequisites and such are assigned) and just change script_hub_determine_purchase_cost to generate a rating, based on your static cost, and return that in reg1. Apparently, the game engine needs script_hub_determine_purchase_cost, so don't skip on that.


Thank you for your help!!

If I had well understand, I need to modify "script_hub_determine_purchase_cost" in Center Management.
In witch file I'll find it?
Module_script.py?


Sorry if I made mystake in my so poor english! It's not my native language.
 
Hi Leifdin,

After some test, i had modify the valor 175 to 5 from (store_div, ":tier", ":rating_total", 5),

Code:
  # This is done prior to scaling rating up based on mounted/ranged.  It is a true representation of how strong a unit is.

		(store_div, ":tier", ":rating_total", 5), # I change 175 to 5

		(val_max, ":tier", 1),
		(troop_set_slot, ":troop_no", slot_troop_tier, ":tier"),


... and apparently this work!


Thank you my friend!
....
 
Back
Top Bottom