Infantry Square Mod

Moderators: rbodleyscott, Slitherine Core, Gothic Labs

Post Reply
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Infantry Square Mod

Post by Cronos09 »

I added the Square script from FoG2 to P&S: https://drive.google.com/open?id=1EoGgl ... iw0SNlCBeQ (it's only a set of scripts, not a ready scenario)
To describe the infantry square in P&S, I give a quote from the FoG2 manual with my changes:
Units having a number of 900 (or 450 if multiplier is 50% etc) or more with bayonets and being on the open ground can form square. This uses the unit’s entire move allowance for the turn (but it still has a free turn - 45 degr). Units in square:
1. Are immune to flank or rear charges.
2. Cannot charge.
3. Never pursue even if raw.
4. Use their entire movement allowance to move 1 square, turn or leave square. After leaving square an unit has a free angle to turn (45 degr).
5. Have higher Close Combat Rating and less Shooting Attack Rating (about 65-70%% in comparison with their non-square formation).
6. Get more losses from enemy musket/arquebus and artillery fire.
7. Get all bonuses from bayonets against cavalry charges.
8. Have the arc of fire of 150 degr, and it is a full volley.
A unit cannot form or leave square while in close combat or it is behind obstacles. A unit in square automatically leaves square when it routs.
Leaving square also uses up the unit's full movement allowance for the turn. But it can shoot after leaving square as well as after the formation of the square and turn 45 degr.
You can activate-deactivate this mode with the right click on the unit like in FoG2. After activating the square mode the Sq icon will appear next to the unit flag in addition to writing to the infoboard. A player can only have 5 square formations simultaneously.
I removed bayonet bonuses from infantry units while they are not in the square formations. Thus, the cavalry becomes the main shock force on the battlefield.
Updated 20.10.2019.
Image

Image

Image

Image
Last edited by Cronos09 on Sun Oct 20, 2019 1:59 pm, edited 1 time in total.
Paul59
General - King Tiger
General - King Tiger
Posts: 3808
Joined: Tue Jul 21, 2015 11:26 pm

Re: Infantry Square Mod

Post by Paul59 »

Many thanks for this Cronos, it's always good to see modders still working on this game.

Is it possible to introduce Group Moves from FOG2 to P&S?


cheers

Paul
Field of Glory II Scenario Designer - Age of Belisarius, Rise of Persia, Wolves at the Gate and Swifter than Eagles.

Field of Glory II Medieval Scenario Designer.

FOGII TT Mod Creator

Warhammer 40,000: Sanctus Reach Tournament Scenario Designer.
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Re: Infantry Square Mod

Post by Cronos09 »

Hi, Paul!

I tried to add this feature to my General mod, especially there are already commands/groups in it. It was not difficult to add neccessary scripts, but as a result I had problems with unit routfinding when a unit had another unit on its rout at the initial position. I had to comment/remove SetUnitRouteMask command, as it's absent in the P&S battlescript. As I see it allows to change routefinding calculations for the required units.
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28047
Joined: Sun Dec 04, 2005 6:25 pm

Re: Infantry Square Mod

Post by rbodleyscott »

Cronos09 wrote: Sun Sep 15, 2019 12:49 pm Hi, Paul!

I tried to add this feature to my General mod, especially there are already commands/groups in it. It was not difficult to add neccessary scripts, but as a result I had problems with unit routfinding when a unit had another unit on its rout at the initial position. I had to comment/remove SetUnitRouteMask command, as it's absent in the P&S battlescript. As I see it allows to change routefinding calculations for the required units.
Yes, it does, it allows them to ignore specified other units when routefinding, so they don't try and route round each other.

Unfortunately this is one of the features that was added in the ARCHON engine, and there is no equivalent in the STUB engine used for P&S.

Hence I don't think that group movement, in formation, is possible to Mod into P&S.
Richard Bodley Scott

Image
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Re: Infantry Square Mod

Post by Cronos09 »

Command Move in P&S "on crutches".
In view of the above reasons, I added a restriction on the movement of units in a command/group to the "Move Command" script. An unit can move in a command/group if it has not another unit of its own group in front of it at the angle of 120 degr (6 squares in front of the unit). Thus, a command of three rows can be moved forward with three clicks on the "Move Whole Command" button:

Image Image

Image Image

"Turn Command" script works in P&S without problem:

Image Image
Athos1660
Major-General - Elite Tiger I
Major-General - Elite Tiger I
Posts: 2563
Joined: Wed May 29, 2019 3:23 pm

Re: Infantry Square Mod

Post by Athos1660 »

Well done! :-)
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Re: Infantry Square Mod

Post by Cronos09 »

I found a way to use a more appropriate visual display square formations in P&S:
Image

Image

Image

Image
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28047
Joined: Sun Dec 04, 2005 6:25 pm

Re: Infantry Square Mod

Post by rbodleyscott »

Nicely done!
Richard Bodley Scott

Image
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Re: Infantry Square Mod

Post by Cronos09 »

Thank you. There is a simple way to relate unit conversion to their Type Index, eg:

Code: Select all

  // Replace Unit
	i = GetUnitTypeIndex(me);
	i+= 120;
	GetUnitTypeString(i); 
	RemoveUnit(me, 1);
	id = AddUnit(x, y, side, GetWorkString(), 1);
True in this case you have to order the necessary units in SQUADS.csv in a certain order.
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28047
Joined: Sun Dec 04, 2005 6:25 pm

Re: Infantry Square Mod

Post by rbodleyscott »

Cronos09 wrote: Thu Apr 23, 2020 7:32 am Thank you. There is a simple way to relate unit conversion to their Type Index, eg:

Code: Select all

  // Replace Unit
	i = GetUnitTypeIndex(me);
	i+= 120;
	GetUnitTypeString(i); 
	RemoveUnit(me, 1);
	id = AddUnit(x, y, side, GetWorkString(), 1);
True in this case you have to order the necessary units in SQUADS.csv in a certain order.
Yes, it is a clever workaround. No doubt I could have done a similar workaround in FOG2, but fortunately, being able to request engine changes, I was able to implement a more general solution.
Richard Bodley Scott

Image
StuccoFresco
Sergeant Major - Armoured Train
Sergeant Major - Armoured Train
Posts: 591
Joined: Sun Feb 10, 2019 11:10 am

Re: Infantry Square Mod

Post by StuccoFresco »

Very nice indeed.
Adebar
Sergeant First Class - Panzer IIIL
Sergeant First Class - Panzer IIIL
Posts: 399
Joined: Tue Oct 14, 2014 10:39 pm
Location: HRR

Re: Infantry Square Mod

Post by Adebar »

Great ideas, and very well done!
Image

IC XC
NI KA
Cronos09
Staff Sergeant - Kavallerie
Staff Sergeant - Kavallerie
Posts: 304
Joined: Thu Feb 22, 2018 4:28 pm

Re: Infantry Square Mod

Post by Cronos09 »

StuccoFresco, Adebar thank you. The ideas are inspired by FoG2.
Post Reply

Return to “Modders Corner”