Edit party morale for battle

Users who are viewing this thread

Efe Karacar said:
That exists by default, no?


Ok then....

How do we go about editing the calculations for morale?

Such as:

removing or lowering the penalties for having heroes in your party

decrease the party size morale penalty


 
party size, heroes, food bonuses, skills, and so on are done through script_get_player_party_morale_values

battle morale is done through script_count_casualties_and_adjust_morale

there's a morale penalty for accidentally shooting one of your men in battle at script_check_friendly_kills

there's a morale increase from looting a village at mnu_village_loot_complete

there's a huge morale drop from leaving men behind to cover a retreat at mnu_encounter_retreat_confirm (under mno_leave_behind)

there's a morale penalty for hiring prisoners at mnu_camp_recruit_prisoners (under camp_recruit_prisoners_accept)

in general, i would search for instances of script_change_party_morale and script_change_player_party_morale -- there's one in module_simple_triggers regarding your men starving
 
Those morale scripts are larger and not the same as other modules so telling him the name of the script and not the actual part of the script to change doesn't really help.
 
wolonggong said:
Those morale scripts are larger and not the same as other modules so telling him the name of the script and not the actual part of the script to change doesn't really help.


I appreciate the input, but it really does help.

I use notepad++ for editing the module and it gave me something to search for......

now if i can just figure out exactly what effects changing these values will have. 
 
wolonggong said:
Those morale scripts are larger and not the same as other modules so telling him the name of the script and not the actual part of the script to change doesn't really help.
You have got to be kidding me...

wld427 said:
I appreciate the input, but it really does help.

I use notepad++ for editing the module and it gave me something to search for......

now if i can just figure out exactly what effects changing these values will have.
Trial and error is the way to go. Instead of changing values willy nilly, you should comment out the old lines you want to change and enter new lines with the change you're trying out. That way if you're wrong, you can at least put it back to the way it was without trouble
 
phlpp said:
wolonggong said:
Those morale scripts are larger and not the same as other modules so telling him the name of the script and not the actual part of the script to change doesn't really help.
You have got to be kidding me...

wld427 said:
I appreciate the input, but it really does help.

I use notepad++ for editing the module and it gave me something to search for......

now if i can just figure out exactly what effects changing these values will have.
Trial and error is the way to go. Instead of changing values willy nilly, you should comment out the old lines you want to change and enter new lines with the change you're trying out. That way if you're wrong, you can at least put it back to the way it was without trouble


That is a very good tip and much easier than saving a backup and trying to find the line again :smile:
 
Back
Top Bottom