Suchar
Recruit
TaleWorlds.MountAndBlade.dll
You can change part of this file with dnSpy (Edit IL instructions->Method…).
Rambo limit
Here you can change the leash for your AI, sadly in dnSpy is possible to only change exception for cavalry to infantry (including archers, skirmishers etc.) with “DismountedClass” (num *= 3.2f will change leash to 15 meters max).
Cavalry can sometimes get stuck in one place (Cavalry will use native leash for infantry !) so players will often have to use “F1, F1”, but what is a little problem for cavalry, is actually a solution to blockade infantry rambo which bait AI (huge problem on skirmishers balance).
Round timers
This is what it looks like on my dll, you should test your timer starting from this settings.
Timer (pointRemovalTimeInSeconds) is only responsible for timer before choosing the last flag/when two flags disappear, timer roundtimelimit from config file is responsible only for max time of the round. So with 420f in dll and 720 in config file, the round will have 12 min and 2 flags will disappear after 7 min. 2f, 2f isn't working for sure, a team with one flag has 2 stars of morale after 5 minutes. 1f, 1f makes morale decrease slower, in the fight for the last flag both teams had still 4 stars near the end of the 12 min round (1 min before end of the round), it should be good with 15 min round. It's possible to change morale multiplayers to 0,7 or 1,4 etc.
General
I will focus only on non-obvious things which aren't described in the beginning of the xml files.
mpcharacters.xml
Here you can change the basic equipment and skills of units (first player unit and AI units have separate ids !)
Mevalion and Palatine Guard needs change in skill points:
mpclassdivisions.xml
melee_ai="-" - it looks like it is responsible for AI skill in blocking attacks, it will be better to increase it for specific units (like 100 for heavy infantry/heavy cavalry, 90 for 2handed units, 70 for skirmisher etc.) to reduce rambo possibilities.
ranged_ai="-" - is responsible for possible range of shoot, the best option is increase it to 100 for every dismounted archer/skirmisher only for fix of AI behavior (AI blindness is generating too many problems in competitive matches).
You can add many “Effect” in one perk, it’s needed to fix the behavior of skirmishers.
mpitems.xml
Here you can find items used in mpclassdivisions.xml and mpcharacters.xml (and parameters for them: bows, crossbows, horses etc.), changing armor or weight of armor won’t change anything in the game.
mp_crafting_pieces.xml
File holds pieces used to create items in mpitems.xml.
In “piece_type="Blade"” is possible to change damage_type="Cut" to Blunt etc.
“damage_factor="-"” is responsible for actual damage of weapons.
To blades you can add “Flags”:
native_parameters.xml
Here you need to change:
item_usage_sets.xml
Here I only blocked the "polearm_couch" with:
so cavalry can’t fulfill all requirements at the same time.
Units Balance
Skirmisher
These are tested and minimal parameters which forces skirmishers AI to finally work properly. You must implement these bonuses in mpclassdivisions.xml to skirmishers perks (watch out for “game_mode=” !)
You can change part of this file with dnSpy (Edit IL instructions->Method…).
Rambo limit
Code:
// Token: 0x060024A1 RID: 9377 RVA: 0x000895B8 File Offset: 0x000877B8
private int PlayerDistanceToFormation(MissionPeer missionPeer)
{
float num = 0f;
if (missionPeer != null && missionPeer.ControlledAgent != null && missionPeer.ControlledFormation != null)
{
float num2 = missionPeer.ControlledFormation.GetAveragePositionOfUnits(true, true).Distance(missionPeer.ControlledAgent.Position.AsVec2);
float num3 = missionPeer.ControlledFormation.OrderPosition.Distance(missionPeer.ControlledAgent.Position.AsVec2);
num += num2 + num3;
if (missionPeer.ControlledFormation.PhysicalClass.IsMounted())
{
num *= 0.8f;
}
}
return (int)num;
}
Here you can change the leash for your AI, sadly in dnSpy is possible to only change exception for cavalry to infantry (including archers, skirmishers etc.) with “DismountedClass” (num *= 3.2f will change leash to 15 meters max).
Cavalry can sometimes get stuck in one place (Cavalry will use native leash for infantry !) so players will often have to use “F1, F1”, but what is a little problem for cavalry, is actually a solution to blockade infantry rambo which bait AI (huge problem on skirmishers balance).
Round timers
Code:
// Token: 0x06002AA5 RID: 10917 RVA: 0x0009DC60 File Offset: 0x0009BE60
case MultiplayerGameType.Captain:
this._moraleMultiplierForEachFlag = 1f;
this._pointRemovalTimeInSeconds = 420f; - 7 minutes
this._moraleMultiplierOnLastFlag = 1.5f;
return;
This is what it looks like on my dll, you should test your timer starting from this settings.
Timer (pointRemovalTimeInSeconds) is only responsible for timer before choosing the last flag/when two flags disappear, timer roundtimelimit from config file is responsible only for max time of the round. So with 420f in dll and 720 in config file, the round will have 12 min and 2 flags will disappear after 7 min. 2f, 2f isn't working for sure, a team with one flag has 2 stars of morale after 5 minutes. 1f, 1f makes morale decrease slower, in the fight for the last flag both teams had still 4 stars near the end of the 12 min round (1 min before end of the round), it should be good with 15 min round. It's possible to change morale multiplayers to 0,7 or 1,4 etc.
General
I will focus only on non-obvious things which aren't described in the beginning of the xml files.
mpcharacters.xml
Here you can change the basic equipment and skills of units (first player unit and AI units have separate ids !)
Mevalion and Palatine Guard needs change in skill points:
- Mevalion - in “Polearm” to 250 (only 2handed with so low skill)
- Palatine Guard - in "Crossbow" to 250 (these unit have one perk with crossbow)
mpclassdivisions.xml
melee_ai="-" - it looks like it is responsible for AI skill in blocking attacks, it will be better to increase it for specific units (like 100 for heavy infantry/heavy cavalry, 90 for 2handed units, 70 for skirmisher etc.) to reduce rambo possibilities.
ranged_ai="-" - is responsible for possible range of shoot, the best option is increase it to 100 for every dismounted archer/skirmisher only for fix of AI behavior (AI blindness is generating too many problems in competitive matches).
You can add many “Effect” in one perk, it’s needed to fix the behavior of skirmishers.
mpitems.xml
Here you can find items used in mpclassdivisions.xml and mpcharacters.xml (and parameters for them: bows, crossbows, horses etc.), changing armor or weight of armor won’t change anything in the game.
mp_crafting_pieces.xml
File holds pieces used to create items in mpitems.xml.
In “piece_type="Blade"” is possible to change damage_type="Cut" to Blunt etc.
“damage_factor="-"” is responsible for actual damage of weapons.
To blades you can add “Flags”:
- "CanCrushThrough" - hit can pierce the upper block (but you need to hit this block with a specific part of your weapon, it won’t allow you to spam hits).
- "CanHook" - allow you to hit few units with one hit
- "CanDismount"
- "BonusAgainstShield" -
I didn’t test it but maybe it will reduce needed "ShieldDamage" bonus for skirmishers.It increases "ShieldDamage" by around 2 times. I recommend starting working on skirmisher with this because "ShieldDamage" added in perk (in mpclassdivisions.xml) will influence all weapons used by skirmisher.
native_parameters.xml
Here you need to change:
- "running_backward_speed_multiplier" (for example to 0,55) - it needed to be changed because if the enemy is near, your units are starting to move like Michael Jackson and it blocks possibilities of maneuvering with troops.
- “ranged_target_radius_multiplier" - is responsible for the distance on which AI sees the enemy, need change to fix skirmisher/archer behavior. Value between 3.2 - 3.5 should be fine (I use 3.8. Too high “ranged_target_radius_multiplier" and too low “Ranged_ai” will end with archers/skirmishers shooting 5 meters before the actual enemy position, the same problem will happen with too big tickrate, so doesn't use tickrate higher than “90” ! (https://forums.taleworlds.com/index...elins-ai-shooting-before-their-target.461979/ example how it will look).
item_usage_sets.xml
Here I only blocked the "polearm_couch" with:
Code:
<flags>
<flag
name="requires_no_mount" />
<flag
name="requires_no_shield" />
<flag
name="passive_usage" />
</flags>
so cavalry can’t fulfill all requirements at the same time.
Units Balance
Skirmisher
Code:
<ConditionalEffect>
<Conditions>
<Condition
type="AgentStatus"
agent_status="OnFoot" />
</Conditions>
<Effects>
<Effect
type="DrivenProperty"
value="-0.7"
driven_property="WeaponWorstMobileAccuracyPenalty"
is_ratio="true" />
<Effect
type="DrivenProperty"
driven_property="MaxSpeedMultiplier" - optional - speeds up the units movement
value="0.02" />
</Effects>
</ConditionalEffect>
<Effect
type="DrivenProperty"
value="-0.9"
driven_property="WeaponWorstUnsteadyAccuracyPenalty"
is_ratio="true" />
<Effect
type="DrivenProperty"
value="-0.9"
driven_property="WeaponBestAccuracyWaitTime"
is_ratio="true" />
<Effect
type="DrivenProperty"
value="1.3"
driven_property="ThrustOrRangedReadySpeedMultiplier" /> - speeds up preparations for the throw
These are tested and minimal parameters which forces skirmishers AI to finally work properly. You must implement these bonuses in mpclassdivisions.xml to skirmishers perks (watch out for “game_mode=” !)
Code:
<Effect
type="ThrowingWeaponSpeed" - removes “throwing balloons” effect from javelins but it increase javelins damage two times (with 0,30) so you must change javelins blades dmg in mp_crafting_pieces.xml
value="0.30" />
<Effect
type="ShieldDamage" - it will increase dmg taken by shields and it depends on how many javelins will break a shield, I recommend minimum 3 javelins/1 shield. If you want, you can decrease normal damage to the body but skirmishers will be useless if the shield will need more than 3 javelins to break (3 javelins is quantity which player need to throw to shield, AI often needs to throw more javelins but it’s a moment when skirmishers are effective).
value="1.55" />
Last edited: