Twotribes Manpower bug, GD1938v3

Discuss and post your mods and scenarios here for others to download.

Moderator: Vic

Post Reply
User avatar
ernieschwitz
Posts: 4245
Joined: Tue Sep 15, 2009 3:46 pm
Location: Denmark

Twotribes Manpower bug, GD1938v3

Post by ernieschwitz »

Ok,

I've been looking into the bug, and so far found nothing. So I am going to ask you... What edits did you actually make. Did you change any of the code, or stringlists?
Creator of High Quality Scenarios for:
  • Advanced Tactics Gold
    DC: Warsaw to Paris
    DC: Community Project.
Try this Global WW2 Scenario: https://www.vrdesigns.net/scenario.php?nr=280
User avatar
Twotribes
Posts: 6466
Joined: Fri Feb 15, 2002 10:00 am
Location: Jacksonville NC
Contact:

RE: Twotribes Manpower bug, GD1938v3

Post by Twotribes »

No all I did is double production of all production facilities (well a made complexes 15k production), I added a few cargo premades to starting cities and added a few units to a couple headquarters. Also add some PP to each nation.

I am pretty sure but not positive that China went to 15k neg after the first transfer or so of Soviet Equipment and that Britain went to neg after the Indians produced more units in manpower then Indian contributes.

The British were doing it before in 101 with no changes.
Favoritism is alive and well here.
User avatar
ernieschwitz
Posts: 4245
Joined: Tue Sep 15, 2009 3:46 pm
Location: Denmark

RE: Twotribes Manpower bug, GD1938v3

Post by ernieschwitz »

It is very strange.

I looked at all the things I could think of. I looked in the code, and nothing seemed wrong. I looked in the stringlists (They govern how much manpower there is in each location. Non-locations add nothing to manpower). I looked in the variables that you can set to a fixed value, and nothing was out of the ordinary, or looked wrong.

Basically I am at a loss, so far.

I might send the file to Vic for analysis.
Creator of High Quality Scenarios for:
  • Advanced Tactics Gold
    DC: Warsaw to Paris
    DC: Community Project.
Try this Global WW2 Scenario: https://www.vrdesigns.net/scenario.php?nr=280
User avatar
ernieschwitz
Posts: 4245
Joined: Tue Sep 15, 2009 3:46 pm
Location: Denmark

RE: Twotribes Manpower bug, GD1938v3

Post by ernieschwitz »

I might be on to something.

Both the two countries (China and Britain) have very high numbers when it comes to their population base. It might be that the numbers added together, coupled with that both countries have played the card to increase their manpower levels is responsible (level 4 both). I need to do more investigating.
Creator of High Quality Scenarios for:
  • Advanced Tactics Gold
    DC: Warsaw to Paris
    DC: Community Project.
Try this Global WW2 Scenario: https://www.vrdesigns.net/scenario.php?nr=280
User avatar
ernieschwitz
Posts: 4245
Joined: Tue Sep 15, 2009 3:46 pm
Location: Denmark

RE: Twotribes Manpower bug, GD1938v3

Post by ernieschwitz »

I was right!

Bug confirmed, and fixed.

The fix will cause a slight downward adjustment in manpower gains. Not much, about 1-4 less for some countries, at their current recruitment levels.

Example: Before the fix Japan had 1021 own manpower, and 402 for other sources. After the fix it is 1017 and 399.

This change is due to the way things are done when calculating in ATG. If you divide something by 10, it rounds down to nearest whole number. So the remainders are not considered. So if you want to multiply something by 1.3 you would have to do it by multiplying first with 13, and then dividing by 10. I had to switch some of the dividing and multiplying to a different order, thus there are some slight rounding issues. Not big stuff, but still, thought I'd mention it.

The problem was that a certain amount of digits is reserved for the size of a number. If calculations bring that number above the digits allowed, the computer interprets it as there is a minus sign ahead of the number instead. I was hitting that number.

I'll put it into the next version I get uploaded (1.0.2)
Creator of High Quality Scenarios for:
  • Advanced Tactics Gold
    DC: Warsaw to Paris
    DC: Community Project.
Try this Global WW2 Scenario: https://www.vrdesigns.net/scenario.php?nr=280
User avatar
Twotribes
Posts: 6466
Joined: Fri Feb 15, 2002 10:00 am
Location: Jacksonville NC
Contact:

RE: Twotribes Manpower bug, GD1938v3

Post by Twotribes »

The Chinese stopped being negative but the British still are. Not sure what changed.
Favoritism is alive and well here.
User avatar
ernieschwitz
Posts: 4245
Joined: Tue Sep 15, 2009 3:46 pm
Location: Denmark

RE: Twotribes Manpower bug, GD1938v3

Post by ernieschwitz »

Overflow. Once the negative numbers get too big, they revert back again.
Creator of High Quality Scenarios for:
  • Advanced Tactics Gold
    DC: Warsaw to Paris
    DC: Community Project.
Try this Global WW2 Scenario: https://www.vrdesigns.net/scenario.php?nr=280
Post Reply

Return to “Mods and Scenarios”