Single Player bugs and crashes v35 plus (SVN) - After the 18th of August 2014

I'm seeing this in the combat odds window and in action:
Wooden Spearman with final combat strength of 12 VS Melee; killed one of my merged Obsidian Swordsmen easily. He went on to slaughter my tribal guardian; I sure regretted not having any ranged or mounted units close by.

I will provide a save the next time I see this, I see it quite often as I'm experimenting with adding that tag to unit combat classes.

Encountered the bug again; here's the save: Link
I updated my civic modmod to match what was used in this save; if you are to debug it you should apply the modmod.

The Neanderthal close to my spiked clubman has 90% vs melee when he should only have 10%.
 
Encountered the bug again; here's the save: View attachment 399385
I updated my civic modmod to match what was used in this save; if you are to debug it you should apply the modmod.

The Neanderthal close to my spiked clubman has 90% vs melee when he should only have 10%.

Thanks - I'll take a look but probably won't try to install the modmod first. This should be unrelated.
 
Thanks - I'll take a look but probably won't try to install the modmod first. This should be unrelated.
I don't know about that as the tag that is bugged for these units are specific to my mod.

Look at this, just noticed the stats of my slinger close to my city: View attachment 399386
Seems like it is not only that one tag though, there might be something wrong with most tags placed in unitcombat classes. for the slinger it would be these tags:
Spoiler :
Code:
		<UnitCombatInfo>
			<Type>UNITCOMBAT_THROWING</Type>
			<Description>TXT_KEY_UNITCOMBAT_THROWING</Description>
			<iCaptureProbabilityModifierChange>5</iCaptureProbabilityModifierChange>
			<iCaptureResistanceModifierChange>-5</iCaptureResistanceModifierChange>
[B][U]			<iHillsDefense>15</iHillsDefense>
			<iCityDefense>10</iCityDefense>
			<iChanceFirstStrikesChange>1</iChanceFirstStrikesChange>[/U][/B]
			<bForMilitary>1</bForMilitary>
			<Button>Art/Interface/Buttons/units/sparth/categories/throwing_units.dds</Button>
		</UnitCombatInfo>

AND

		<UnitCombatInfo>
			<Type>UNITCOMBAT_WEAPON_DIST_SLING</Type>
			<Description>TXT_KEY_UNITCOMBAT_WEAPON_DIST_SLING</Description>
			[B][U]<iChanceFirstStrikesChange>2</iChanceFirstStrikesChange>[/U][/B]
			<Button>Art/Interface/Buttons/units/sparth/categories/wields_distance.dds</Button>
		</UnitCombatInfo>

AND

		<UnitCombatInfo>
			<Type>UNITCOMBAT_COMBATANT</Type>
			<Description>TXT_KEY_UNITCOMBAT_COMBATANT</Description>
			[U][B]<iEarlyWithdrawChange>50</iEarlyWithdrawChange>[/B][/U]
			<iCaptureResistanceModifierChange>10</iCaptureResistanceModifierChange>
			<bForMilitary>1</bForMilitary>
			<Button>Art/Interface/Buttons/units/sparth/categories/combatants.dds</Button>
		</UnitCombatInfo>
 
I don't know about that as the tag that is bugged for these units are specific to my mod.

Look at this, just noticed the stats of my slinger close to my city: View attachment 399386
Seems like it is not only that one tag though, there might be something wrong with most tags placed in unitcombat classes. for the slinger it would be these tags:
Spoiler :
Code:
		<UnitCombatInfo>
			<Type>UNITCOMBAT_THROWING</Type>
			<Description>TXT_KEY_UNITCOMBAT_THROWING</Description>
			<iCaptureProbabilityModifierChange>5</iCaptureProbabilityModifierChange>
			<iCaptureResistanceModifierChange>-5</iCaptureResistanceModifierChange>
[B][U]			<iHillsDefense>15</iHillsDefense>
			<iCityDefense>10</iCityDefense>
			<iChanceFirstStrikesChange>1</iChanceFirstStrikesChange>[/U][/B]
			<bForMilitary>1</bForMilitary>
			<Button>Art/Interface/Buttons/units/sparth/categories/throwing_units.dds</Button>
		</UnitCombatInfo>

AND

		<UnitCombatInfo>
			<Type>UNITCOMBAT_WEAPON_DIST_SLING</Type>
			<Description>TXT_KEY_UNITCOMBAT_WEAPON_DIST_SLING</Description>
			[B][U]<iChanceFirstStrikesChange>2</iChanceFirstStrikesChange>[/U][/B]
			<Button>Art/Interface/Buttons/units/sparth/categories/wields_distance.dds</Button>
		</UnitCombatInfo>

AND

		<UnitCombatInfo>
			<Type>UNITCOMBAT_COMBATANT</Type>
			<Description>TXT_KEY_UNITCOMBAT_COMBATANT</Description>
			[U][B]<iEarlyWithdrawChange>50</iEarlyWithdrawChange>[/B][/U]
			<iCaptureResistanceModifierChange>10</iCaptureResistanceModifierChange>
			<bForMilitary>1</bForMilitary>
			<Button>Art/Interface/Buttons/units/sparth/categories/combatants.dds</Button>
		</UnitCombatInfo>

Ah... now that IS interesting. Very curious indeed. Maybe it does have to do with that.

Are those setup as modular adjustments to the combat classes or in the core? I suppose probably modular right? Might be the problem lies in the modular loading for combat classes somehow. That's something that's not been heavily tested.

I take it the Barb in the above save has some kind of UnitCombat Combat modifier in a modular unitcombat adjustment as well?
 
Ah... now that IS interesting. Very curious indeed. Maybe it does have to do with that.

Are those setup as modular adjustments to the combat classes or in the core? I suppose probably modular right? Might be the problem lies in the modular loading for combat classes somehow. That's something that's not been heavily tested.

Nope, still haven't made my modmod modular; core changes only.


There is of course the possibility that I have some typos in the xml somewhere that makes all entries act strange, but I have a feeling that something is afoot with stats placed in combat classes in general; possibly only triggered when there is similar stats in different combat classes for the same unit.
 
hmm... I investigated the core mod on combat class modifiers and most seem to be working though what I found was that many are not, as in they aren't showing up on the unit at all. Not flawed... just not there. I'm not sure if its the tag itself and/or just a display issue or what at the moment.

So what this means really is that I need to review them all and see what is or is not going haywire and why. Sheesh. I've got a lot of planned new uses taking shape there too so it does need repaired asap. I'll take a look at your modmod if I need to. In the meantime I want to be sure the tags are simply working properly in general. Once I'm sure of that I can see if the modmod stuff has something strange taking place itself.
 
After some investigation, there is some evidence to suggest that it may have to do with any tags that involve unitcombats within the unitcombat xml. They require a second load process and it's possible that another modder has changed the way those should now be programmed. I'm not sure how it should be resolved at the moment but I suspect that any use of those tags, such as UnitCombatPercentChangeModifier on UnitCombats may be causing quite a few things to go completely haywire.

It will take a lot of testing to see if I can find how to change the programming on the load procedures for those tags correctly... IF that's the problem.

But you may be able to help me determine if it is. While I'm going to bed here and going to work in the morning, perhaps during that time you could see if removing any usage of any UnitCombat specifying tags on UnitCombat type definitions tends to clear everything else up.

I also found that there's probably some tags that have some simple display flaws. But I think that's a separate issue.

This really sucks to be having this issue... there's a number of things I want to do with tags like that! URGH! I may be able to sort it out but this is the kind of bug that could take weeks to solve. (Assuming I even can.)


Ok, further investigation...
This is really really really really strange.
I'm finding that there are numerous tags that DO work as designed. Couldn't find an error actually.

However, I think there IS a tag that's causing trouble. It's not the UnitCombatPercent tag but its something. What we'll need to do is test one tag at a time and see which one is causing values to go wild and out of whack.

I suspect the tag causing this wild value assignment on all the unitcombat tags may be making it so that you can't see the tag values on affected units in the pedia - I loaded most tags with proxy values and this was the result on an affected unit. So I'm thinking the offending tag is indeed among those in the unitcombat section. Perhaps you could test one at a time for me and let me know when one goes whacky. I'll be looking as I can.
 
The interesting thing is that it seems like all the tags currently in use in the core are working fine. So whatever the chaos-inducing tag is, once found, it can probably be addressed and may be found to not even be critical somehow.

Most integers have been checked at this point and I don't think those are the culprits unless its one later in the list.
 
Calculation bug: I checked food also, so food and production/hammer is calculating +% from resources correctly when you build +1% buildings, only +% from resources when you build +1% buildings in gold calculation is missing. How long to fix this? My addiction is calling. ;)
 
Calculation bug: I checked food also, so food and production/hammer is calculating +% from resources correctly when you build +1% buildings, only +% from resources when you build +1% buildings in gold calculation is missing. How long to fix this? My addiction is calling. ;)
At least the weekend most likely. That's complicated stuff.

I am now getting blank buildings from the current SVN?? something about tourism stuff i believe??
What gives you indication it has to do with tourism? Not saying it doesn't... just that those are primary buildings, not wonders and usually tourism is on wonders.

I wonder what could be causing this now. Could be a bad tag on buildings I suppose... strange considering we've been testing this for a while now and there's been no building tag programming changes in a very long time. Art perhaps? Ugh... I'm not even sure how to go about diagnosing this one.
 
At least the weekend most likely. That's complicated stuff.


What gives you indication it has to do with tourism? Not saying it doesn't... just that those are primary buildings, not wonders and usually tourism is on wonders.

I wonder what could be causing this now. Could be a bad tag on buildings I suppose... strange considering we've been testing this for a while now and there's been no building tag programming changes in a very long time. Art perhaps? Ugh... I'm not even sure how to go about diagnosing this one.

the reason i said tourism is because when i click on the blank spot it has a tourism listing on the left, (see attached i had), also did NOT have this before Joseph put in the changes he just made? I looked over his changes and didnt see anything wrong??
 
Ah... I see it now. Thanks for pointing it out. I doubt it has much to do with tourism but maybe those are autobuildings FOR tourism that don't have a number of things defined because they are intended to be autobuilt and thus don't need the button art and so on. Somehow they were tweaked so that they can now come up in the build list. That's my theory at the moment then. (But not having a name tag is still odd.)
 
Ah... I see it now. Thanks for pointing it out. I doubt it has much to do with tourism but maybe those are autobuildings FOR tourism that don't have a number of things defined because they are intended to be autobuilt and thus don't need the button art and so on. Somehow they were tweaked so that they can now come up in the build list. That's my theory at the moment then. (But not having a name tag is still odd.)
I found the issue.

Will explain in an edit.

Edit: @Joe.

When you removed some of the crime auto-buildings you probably didn't know that they had attached stats from a different xml; namely Tourism_CIV4BuildingInfos.xml.
This XML puts additional information into buildings that are defined elsewhere. So when you removed for example the BUILDING_CRIME_ROGUEMERCENARIES from SpecialBuildings_CIV4BuildingInfos.xml
it was still defined in the tourism XML like this:
Spoiler :
Code:
	<BuildingInfo>
		<BuildingClass>BUILDINGCLASS_CRIME_ROGUEMERCENARIES</BuildingClass>
		<Type>BUILDING_CRIME_ROGUEMERCENARIES</Type>
			<PropertyManipulators>
			  <PropertySource>
			    <PropertySourceType>PROPERTYSOURCE_CONSTANT</PropertySourceType>
			    <PropertyType>PROPERTY_TOURISM</PropertyType>
			    <iAmountPerTurn>-4</iAmountPerTurn>
			  </PropertySource>
			</PropertyManipulators>
		</BuildingInfo>
	<BuildingInfo>
A building without name, pedia, button art nor requirements. It only has a sole stat of -4 tourism.

Removing the entries of the crimes that you removed from this xml as well would fix SO's problems.
 
Ah... I see it now. Thanks for pointing it out. I doubt it has much to do with tourism but maybe those are autobuildings FOR tourism that don't have a number of things defined because they are intended to be autobuilt and thus don't need the button art and so on. Somehow they were tweaked so that they can now come up in the build list. That's my theory at the moment then. (But not having a name tag is still odd.)

am also getting this in a brand NEW game
 
Back
Top Bottom