Urban Defence - Squad performance oddities

Please post any bugs or technical issues found here for official support.

Moderator: Joel Billings

Post Reply
User avatar
Wiedrock
Posts: 1645
Joined: Tue Oct 11, 2022 7:44 pm
Location: Germany

Urban Defence - Squad performance oddities

Post by Wiedrock »

"SOLVED", see this Post further down


Important here, this is only related to Urban Combat on the Defence. Nothing else.
Not sure if how I test it in Editor is messing with things. But results seem somewhat constant throughout tests.
  • It seems as if StG44s inside Squads which are not classified "Assault Squads (115)" perform much worse. I've simply exchanged regular Kar98 for StG44 in this regular Rifle Squad and the performance went downhill 8x.
    Also compare the "Sturm Squad (-)" with the "Sturm Squad (-) MotRS" (Mot-Rifle Squad category) at the bottom. Those perform also ~8times worse (It'spossible that some of that is related to being "Mot", you can compare it to the different Pioneer Squads where you see the same when they get "Mot./RS/Assault" categorized.)
    Or the "Sturm Squad" and the "Sturm Squad RS" (Rifle Squad category). The latter having a ~3-4times worse performance just because Assault Squad was changed into Rifle Squad.
    Urban-Defence_StG in Rifle Squad.png
    Urban-Defence_StG in Rifle Squad.png (486.06 KiB) Viewed 415 times
    Urban-Defence_Squad43vanilla vs StG.png
    Urban-Defence_Squad43vanilla vs StG.png (279.38 KiB) Viewed 415 times
Further interesting is that "Pioneer Squad 39" outperforms the Upgunned Pio43/44 Squads.
Not sure what this is related to exactly, part may be having additional Device slots filled and additionally may it be that lower RoF in the Kar98s causes the Squad to rather use the Flamthrower and this makign it perform better?
Urban-Defence_PioSquads_vanilla.png
Urban-Defence_PioSquads_vanilla.png (210.62 KiB) Viewed 415 times
Last edited by Wiedrock on Thu May 29, 2025 12:04 am, edited 1 time in total.
User avatar
Joel Billings
Posts: 33494
Joined: Wed Sep 20, 2000 8:00 am
Location: Santa Rosa, CA
Contact:

Re: Urban Defence - Squad performance oddities

Post by Joel Billings »

You're getting so into the weeds with this testing that I think you've come up with questions that have gone beyond what we're going to answer. At one time Gary might have remembered what special effects he built into the system, but we're past that. Pavel would likely have to spend a lot of time in the debugger to try to figure out what's going on. At this point, I don't think we have the time to explore this.

On the bright side, Pavel was able to find a line of code that seems to explore why the mech squads were underperforming. The next update will include this change, and we're going to remove their armor in the data as it seems the armor was making them easier to destroy instead of just damage/disrupt. We're also reducing some of the ammo need reduction that rockets suffer in 1941 and 1942. These changes are in the current version we are testing. We may be coming to the end of our combat changes unless there's something else I find you've posted with saves that looks easier to get at.
All understanding comes after the fact.
-- Soren Kierkegaard
Teo41_ITA
Posts: 497
Joined: Thu Sep 02, 2021 12:45 pm

Re: Urban Defence - Squad performance oddities

Post by Teo41_ITA »

Joel Billings wrote: Mon May 26, 2025 7:35 pm These changes are in the current version we are testing.
If I start a new campaign, will those changes be retrofitted in my new game, once I upload the latest beta files?
User avatar
Joel Billings
Posts: 33494
Joined: Wed Sep 20, 2000 8:00 am
Location: Santa Rosa, CA
Contact:

Re: Urban Defence - Squad performance oddities

Post by Joel Billings »

The armor data change won't, but the code changes would impact all games. I don't expect the next update to come out before July at the earliest, so I wouldn't wait for it.
All understanding comes after the fact.
-- Soren Kierkegaard
User avatar
Joel Billings
Posts: 33494
Joined: Wed Sep 20, 2000 8:00 am
Location: Santa Rosa, CA
Contact:

Re: Urban Defence - Squad performance oddities

Post by Joel Billings »

You're not comparing units on the defense with those on the offense, are you? Clearly units on the defense shoot and hit more often. Are you saying there's something unique about certain weapons in urban defense?

As for the idea that SMG squads or Assault Squads are treated differently, Pavel could find no reference those by name in the combat code. Now it is possible that the aray is referenced in some way by numbers, but that would be harder to locate. The issue with mech squads was caused by the class Mech Infantry being treated differently than the class Infantry. The SMG and assault squads are class infantry so that doesn't explain anything. As for the slots, Pavel said that he knows that the first slot is critically important as the main weapon for artillery units. He's not sure if the first slot has a special status of some kind in infantry units. That's the extent of what we know without a very deep dive (and even then getting into Gary's head in the code and deciding how/when to make a change almost impossible. The impact of breaking a weapon into multiple different slots is unknown to us. I doubt Gary ever thought about it, so best not to do it.
All understanding comes after the fact.
-- Soren Kierkegaard
User avatar
Wiedrock
Posts: 1645
Joined: Tue Oct 11, 2022 7:44 pm
Location: Germany

Re: Urban Defence - Squad performance oddities

Post by Wiedrock »

Joel Billings wrote: Tue May 27, 2025 5:03 pm Are you saying there's something unique about certain weapons in urban defense?
I've found it not being the (StG44) weapons (see point no. 2), so that we can ignore, my initial testing wasn't in depth enuff.
Joel Billings wrote: Tue May 27, 2025 5:03 pm You're not comparing units on the defense with those on the offense, are you? Clearly units on the defense shoot and hit more often.
I am aware that there are differences between offense and defense - and rightfully so. I just found Urban defense having some oddities of which I had only reported the weirdest observations.
There is more when it comes to Urban Defense, see points 3+4 and I correct my initial guess on the StG44 in point 2.
There's just soo many things. :D

Again, it's all only in Urban defence!
I did 4 Attacks Urban and 4 Attacks Clear terrain to get the data shown in the diagrams. GER is always DEFence, SOV is always ATtacK.
Every "TESTER" Squad is exactly the same (see following pic). The only difference is the "Type" and for the Mech units I have an ARMored and an unarmored variant each.

When tested like this the only difference for the most tested Squads is the "Type" and all test scenarios ...Urban attacks(SOV), Clear/Light Wood attacks(SOV)+defence(GER) all make sense (except the normal "Mech issue") - see point no. 4 for the graphs!
So it is only the Urban Defense that is playing tricks on me!

Issues:
  1. Pioneers 39 perform better than Pioneer 44 (as reported initially) - In all othe instances the Pio44 is better as you can see in the following graph.
    ...generally they seem both somewhat "strong" (it's the Flamthrower hitting hundrets of elements)...
    Pioneers39vs44.png
    Pioneers39vs44.png (488.31 KiB) Viewed 315 times
    Pioneer Squad 39 vs 44 - Performance in URBAN DEFENCE issue.png
    Pioneer Squad 39 vs 44 - Performance in URBAN DEFENCE issue.png (25 KiB) Viewed 315 times
  2. The new Squad (with StG). I reported in in THIS THREAD because it only happens in Urban! :D
    - copying the normal Rifle Squad,
    - renaming it and
    - changing the Kar98 to StG44
    ...this gives a worse performance in URBAN DEFENCE - no idea what's causinging that - If I give the StG44 to the regular Squad it was fine SO IT's NOT THE StG44 ......and IT IS NOT THE RENAME :lol: ... and it is nto the slot since it is not happening in non-Urban! :lol: ....it only happens in Urban Defense with new Squad, in Clear terrain/Light forest the Squad works normal. ...I did nothing more then copy, rename, change weapon... That's why it's called "oddities". :mrgreen: ...and yes I am also going crazy by looking at this! :lol:
    Urban-Defense_Rifle Squads Urban vs Light Forest.png
    Urban-Defense_Rifle Squads Urban vs Light Forest.png (274.36 KiB) Viewed 315 times
  3. NEW: 50mm Mortars are overperforming in Urban Defense.
    As can be seen in the following, similar to the weird Pio performance being reverse in Urban Defence, the 50mm is outperforming 82mm Mortars and everyone else (except Pioneers) in Urban defence. Not sure why 50mm Mortars would be the 'big deal' in Urban Combat Defense? :mrgreen:
    50mm and Squads - Performance in URBAN DEFENCE issue.png
    50mm and Squads - Performance in URBAN DEFENCE issue.png (52.07 KiB) Viewed 315 times
  4. NEW: This is just a loose statement and may partially be related to the weird observation which was made in point "2" (creating new Squads which perform weird).
    It can be observed, that the Difference between Squad performance (in Urban Defense) is much larger than in the all the other cases (while being exactly the same Squads [except "Type"]), as can be seen in the above graph. Again a case where everything else works as guessed, but Urban Defense makes some weird shenanigans I can not explain.
    See the "TESTER RS" and "TESTER MotRS" outperforming others [collumn: urbanGERdef].
Joel Billings wrote: Tue May 27, 2025 5:03 pm As for the idea that SMG squads or Assault Squads are treated differently, Pavel could find no reference those by name in the combat code. Now it is possible that the aray is referenced in some way by numbers, but that would be harder to locate. The issue with mech squads was caused by the class Mech Infantry being treated differently than the class Infantry. The SMG and assault squads are class infantry so that doesn't explain anything. As for the slots, Pavel said that he knows that the first slot is critically important as the main weapon for artillery units.
Yea, as mentioned and pointed out in point no. 2 it is not the StG44 causing the issue but some other trick the urban defense is playing on me. So that Weapons work different in different Squads we can forget about again (I hope), that was me not analyzing/testing more situations.
Joel Billings wrote: Tue May 27, 2025 5:03 pm He's not sure if the first slot has a special status of some kind in infantry units. That's the extent of what we know without a very deep dive (and even then getting into Gary's head in the code and deciding how/when to make a change almost impossible. The impact of breaking a weapon into multiple different slots is unknown to us. I doubt Gary ever thought about it, so best not to do it.
This is a matter for the other Thread, this one is complex and confusing enuff already. I'll reply to you (this quote) in the other Thread.
User avatar
Wiedrock
Posts: 1645
Joined: Tue Oct 11, 2022 7:44 pm
Location: Germany

Re: Urban Defence - Squad performance oddities

Post by Wiedrock »

Found the reason to - I guess - all issues.

It must be related in some way to the ID in the long list of Ground Elements. (or alternatively the OB order [in my tests very similar for many elements] - but it's rather the Ground Element ID as you will see).

There is some kind of "comes first goes first". This can be seen amongst all the battle scenarios (attack/defense urban/nonurban...), but it is way more pronounced in Urban DEFENSE combat, massively more.

Issue 4:
The finding explains the general trend. Not the pronounciation of the Effect that massive in urban Defence only. This must be something about the Code.
NOTE: unarmored "MECH" in Urban behave somehow differently then in all other cases.
General Squads - order of slots in OB (mostly similar to ID).png
General Squads - order of slots in OB (mostly similar to ID).png (38.67 KiB) Viewed 282 times
Issue 1:
If I change the Pio39 and Pio44 slots in the List 84<->86 the Pio44 starts performing better in Urban Defense.
Urban-Defence_PioSquads_slots switched2.png
Urban-Defence_PioSquads_slots switched2.png (343.53 KiB) Viewed 282 times
Urban-Defence_PioSquads_slots switched.png
Urban-Defence_PioSquads_slots switched.png (643.33 KiB) Viewed 282 times
Issue 2:
The finding explains the issue with comparing a 600+ ID Squad with an ID:~80 pretty early one in the ID List.

Issue 3:
If I switch he last of my TESTER Squads, the Airlanding Section with the 50mm Mortar, the mortar sucks while the Airlanding guys rule.
Urban-Defence_Airldg and Mortar switched.png
Urban-Defence_Airldg and Mortar switched.png (1.03 MiB) Viewed 282 times
Post Reply

Return to “Tech Support”