Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Adjusting Max Cohesion of models

Tue Oct 28, 2014 6:53 pm

I am trying to reflect the Polish armies low morale and cohesion at the beginning of the Russo-Polish War of 1920. I want the Polish Army to have a lower than normal maximum cohesion for various models at the start of the game. Then at various times, introduce an event which would increase the maximum cohesion of models to reflect the increasing cohesion and morale of the Polish army as the Reds approach Warsaw.

Unfortuately, looking at the script commands in the wiki, I have only found commands which adjust current cohesion rather than max cohesion for models.

So have I missed a script command that changes the maximum cohesion of models? If not, is there another approach to simulating the same effect of reduced maximum cohesion? I definitely do not want to make a bunch of duplicate models with different maximum cohesion levels.


Hopefully someone can help me out. This is a vital event for simulating changes in the performance of the Polish Army.

Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Tue Oct 28, 2014 7:34 pm

I did find this command which appears to adjust maximum cohesion. However it is tied to a local area bonus command which I don't want to do but I guess I could. It seems a very round about method of achieving what I need.

cohLocalAreaBonus = 10 // bonus to max cohesion if at home

Also abilities can increase or decrease max cohesion. So the game can definitely change max cohesion. I just can't find a straight command that I can use in an event to simply change the max cohesion of family groups.

Something like this would be ideal for my purposes:

<;SetCohesionPerc Value> Set the Cohesion of the Subunit to a percent Value :( Integer 1 to 100)
of it's maximum

It adjusts cohesion by a percentage. But it appears to adjust cohesion, not max cohesion.

So anyone know of a script command for adjusting max cohesion without tying it to area or region?

User avatar
Pocus
Posts: 25659
Joined: Wed Oct 19, 2005 7:37 am
Location: Lyon (France)

Wed Oct 29, 2014 9:58 am

Not possible...
Image


Hofstadter's Law: "It always takes longer than you expect, even when you take into account Hofstadter's law."

Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Wed Oct 29, 2014 3:23 pm

Thanks, I will see if I can do some workaround using the areabonus.

BTW, a script command adjusting max cohesion would be very useful for scenario designers. The ability to adjust max cohesion up or down would be an excellent way to simulate various conditions impacting the performance of an army for longer time periods than a simple, short impact cohesion change.

User avatar
Bohémond
Posts: 2799
Joined: Wed May 14, 2008 8:47 pm

Wed Oct 29, 2014 3:56 pm

And what about ;
<;ChgPtsCohesion ValueInPts> parameter with AlterCuSubUnit command.

It does not allow to set the maximum value but can modify it.

Regards
Marco, perché vai così forte in salita?» «Per abbreviare la mia agonia.

Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Wed Oct 29, 2014 6:04 pm

Bohémond wrote:And what about ;
<;ChgPtsCohesion ValueInPts> parameter with AlterCuSubUnit command.

It does not allow to set the maximum value but can modify it.

Regards


I think that command would give you a temporary change in current cohesion either up or down in points not percentages-even possibly above max cohesion-not sure. But keeping it there would be the problem. Eventually, cohesion will settle down at max
cohesion as defined by the model.

I am actually going to test "cohLocalAreaBonus = 10 // bonus to max cohesion if at home" this command with alterCuSubUnit. It is a script command and might work with AlterCuSubUnit. Something like this to test it.

---------------------------------
StartEvent 999
Conditions NULL
TurnIndex 10|11|12
Actions NULL
SelectSubUnits Area $Theater_Western|FactionTags $POL|Families $famline $famcavalry
AlterCuSubUnit ApplyToList|CohLocalAreaBonus = 10
EndEvent NULL
------------------------------------------------

Although cohLocalAreaBonus may only be useable with the HomeAreaBonus definition. I will find out. I don't want to use the HomeAreaBonus process because the bonuses are limited to a specific Theater and penalties occur outside the Theater. Basically the conditions just wouldn't work for what I am trying to simulate.

If CohLocalAreaBonus does not work with AlterCuSubUnit, I can do something similiar by creating new models and events for a tech upgrade. A quick look and it seems I would need 22 new models and 22 new events.... :( . All I can say is thank goodness for copy and paste.

User avatar
Pocus
Posts: 25659
Joined: Wed Oct 19, 2005 7:37 am
Location: Lyon (France)

Thu Oct 30, 2014 10:00 am

CohLocalAreaBonus is simply a global variable and is not a scripting command.
Image


Hofstadter's Law: "It always takes longer than you expect, even when you take into account Hofstadter's law."

Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Thu Oct 30, 2014 4:28 pm

Thanks, I was going to test it this weekend but that saves me some time. Looks like it is going to be the new models and events route.

Jagger2013
General of the Army
Posts: 641
Joined: Sat Apr 27, 2013 2:14 am

Thu Oct 30, 2014 4:39 pm

Thanks, I was going to test it this weekend but that saves me some time. Looks like it is going to be the new models and events route.

Return to “Modding AGE engine games”

Who is online

Users browsing this forum: No registered users and 7 guests