Bug Reports and Discussion

Has anyone else noticed that invisible units aren't invisible to the AI? No matter where I am or who I'm attacking (Basium and Dain so far) my shadows always get counter attacked the next turn. I know it's not Dies Diei since I own it.
 
I remember a change in MNAI that made hawks see invisible units.
 
I put this Q in FAQ,but was asked to put it here.Playing as Flauros and cant build the command post with my great commander(I have military strategy),not sure if its a bug(the guy who sent me here seemed to think so I guess) or im missing something.save enclosed.thanks.Well it would be but I cant work out how to remove it from the FAQ thread to here.sorry.

EDIT;ignore me,im a total muppet-didnt realise the diffrence between great commander and great generals.doh
 
I believe this would class as a bug.When a divided soul explores a lair and gets the trap event,if you sever soul the following turn to escape from the the trap your divided soul remains "unable to move" even after you,ve teleported to rejoin the soul.
 
I was finally able to track down a CTD when playing Kuriotates with my local ExtraModMod version (but the same should apply to MNAI). Here is the fix and an explanation:

In CvCity.cpp, CvCity::setPlotRadius(int iNewValue):

Spoiler :
Code:
		m_iPlotRadius = iNewValue;
		CvPlot* pLoopPlot;

//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//		if (iNewValue < getPlotRadius())
		if (iNewValue < iOldPlotRadius)
//<<<<Unofficial Bug Fix: End Modify
		{
//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//			for (int iI=8; iI<NUM_CITY_PLOTS; iI++)
			for (int iI = 0; iI < iOldPlotRadius; iI++)
//<<<<Unofficial Bug Fix: End Modify
			{
				/*That workers in outliing plots are not struck there...*/
				if (isWorkingPlot(iI) == true)
				{
					setWorkingPlot(iI, false);
				}
			}
		}

//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//		for (int iI=8; iI<NUM_CITY_PLOTS; iI++)
		for (int iI = 0; iI < iOldPlotRadius; iI++)
//<<<<Unofficial Bug Fix: End Modify
		{
			pLoopPlot = plotCity(getX_INLINE(), getY_INLINE(), iI);
			if (pLoopPlot != NULL)
			{
				pLoopPlot->updateWorkingCity();
			}
		}

should be

Spoiler :
Code:
		[B]//m_iPlotRadius = iNewValue;[/B]
		CvPlot* pLoopPlot;

//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//		if (iNewValue < getPlotRadius())
		if (iNewValue < iOldPlotRadius)
//<<<<Unofficial Bug Fix: End Modify
		{
//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//			for (int iI=8; iI<NUM_CITY_PLOTS; iI++)
			for (int iI = 0; iI < [B]calculateNumCityPlots( iOldPlotRadius )[/B]; iI++)
//<<<<Unofficial Bug Fix: End Modify
			{
				/*That workers in outliing plots are not struck there...*/
				if (isWorkingPlot(iI) == true)
				{
					setWorkingPlot(iI, false);
				}
			}
		}
		
		[B]m_iPlotRadius = iNewValue;[/B]

//>>>>Unofficial Bug Fix: Modified by Denev 2010/07/13
//		for (int iI=8; iI<NUM_CITY_PLOTS; iI++)
		for (int iI = 0; iI < [B]calculateNumCityPlots( iOldPlotRadius )[/B]; iI++)
//<<<<Unofficial Bug Fix: End Modify
		{
			pLoopPlot = [B]GC.getMapINLINE().plotINLINE((getX_INLINE() + GC.getCityPlotX()[iI]), (getY_INLINE() + GC.getCityPlotY()[iI]))[/B];
			if (pLoopPlot != NULL)
			{
				pLoopPlot->updateWorkingCity();
			}
		}

The iOldPlotRadius in the loop is obviously wrong, and also disguises the other bug, that m_iPlotRadius should be updated only after isWorkingPlot() is used (otherwise triggering an assert). Since m_iPlotRadius has to be updated before pLoopPlot->updateWorkingCity() is called, I had to change the selection of pLoopPlot to a plotRadius-agnostic method.

In CvPlot.cpp, CvPlot::updateWorkingCity():

Spoiler :
Code:
	pOldWorkingCity = getWorkingCity();

	if ( pOldWorkingCity != pBestCity )
	{
	// lfgr bugfix 06/2015
	// The old city may have a smaller radius by now.
	//	if (pOldWorkingCity != NULL)
		if ( pOldWorkingCity != NULL && pOldWorkingCity->getCityPlotIndex( this ) != -1 )
		{
			
			pOldWorkingCity->setWorkingPlot(this, false);
		}
	// lfgr end

		if (pBestCity != NULL)

This is for the call at the end of the code above.
 
I've got 6 mana of each type and no holy cities. I don't *think* it has anything to do with my programming, is anyone else getting this bug?
 

Attachments

  • Too much mana.jpg
    Too much mana.jpg
    279.2 KB · Views: 83
Again, it might just be my python but when the Avatar of Wrath came, I lost 2 of my 3 prophets and I got an altar of the lunnator without me asking for it to be built (and the game congratulated me on building my first national wonder).

EDIT: 1 of my prophets remained normal, 1 became enraged (I don't think great people should become enraged), and one built the Altar of the Lunnotar without my permission
 
I was just trying to use the PyHelp tag in Civ4SpellInfos.xml (to make my version of the Drown spell warn the player about how much gold it will cost), and found that python expressions placed there do not seem to be evaluated at all. Nothing I put there seems to make any difference in the game. Even when I intentionally place bugs there they won't know up in the error logs.

I think Tholal must have borrowed the XML schema and python code for this mechanism from lfgr without copying essential sections of C++ code needed to make those do anything.
 
I believe this would class as a bug.When a divided soul explores a lair and gets the trap event,if you sever soul the following turn to escape from the the trap your divided soul remains "unable to move" even after you,ve teleported to rejoin the soul.

That damn Cage effect has been the source of so many problems...

I was finally able to track down a CTD when playing Kuriotates with my local ExtraModMod version (but the same should apply to MNAI). Here is the fix and an explanation:

Thanks! I'll have to look at the explanation later but this is something that had been bothering me (never saw a CTD but have seen those assert errors). Glad to have it fixed!

IMHO (and I'm bad player for a reason...) the AI shouldn't build forts adjacent to their cities because it gives enemies a safe place to attack from.

Agreed. This is one of those issues that I have tried to fix with no success.

I've got 6 mana of each type and no holy cities. I don't *think* it has anything to do with my programming, is anyone else getting this bug?

Havent seen this.


I was just trying to use the PyHelp tag in Civ4SpellInfos.xml (to make my version of the Drown spell warn the player about how much gold it will cost), and found that python expressions placed there do not seem to be evaluated at all.

I think lfgr has a fix for this. I'll merge it when I get things setup again.
 
I think lfgr has a fix for this. I'll merge it when I get things setup again.

He does. I have been using his dll for my last few releases, and have PyHelp tags working to explain essentially every spell now.

There was some discussion about possibly switching some of those PyHelp tags to be automatically generated in the dll instead. It would probably be more efficient for C++ to handle showing the details of xml-only spells.


I was recently thinking might be best for the <PyHelp> tags to override the <Help> tag when mousing over a unit. I would like to be able to include more general descriptions of spells in the 'pedia but not have redundant or irrelevant details clutter the screen when using a PyHelp tag to show what the spell will actually do in that context.

PyHelp tags for promotions would also be a nice touch, so we can explain what their <PyPerTurn> effects will do.
 
Hey all, just found a new, rather annoying bug.

Had an HN privateer turn up, and run a blockade mission. My Vicar cast Revealing Light, or whatever, and revealed it as Shieam, whom I am at war with. My frigate then proceeded to destroy it, but the blockade remained. Won't go away, nothing in worldbuilder to turn it off, making peace with the Shieam does nothing, and the blockade remains with no ship.
 
I find it really annoying that forming a Permanent Alliance with a player (or at least forcing such alliances in python) cancels the open borders agreement between the teams first and ejects the new ally's units from your territory rather than letting them stay there.



I'm afraid I don't have a saved game, but on a few rare occasions I have found that my hidden nationality units were able to capture neutral player's forts and cities.
 
Hey all, just found a new, rather annoying bug.

Had an HN privateer turn up, and run a blockade mission. My Vicar cast Revealing Light, or whatever, and revealed it as Shieam, whom I am at war with. My frigate then proceeded to destroy it, but the blockade remained. Won't go away, nothing in worldbuilder to turn it off, making peace with the Shieam does nothing, and the blockade remains with no ship.

i've had similar happen quite a few times. barbarian tortoises do the same thing. kill em and the blockade still there. definite reproducible common bug. and it never goes away, that's the worst part. "oh your civ is dead and gone but you still have a blockade. so cool"
 
I had that blockade thing myself maybe a year or 2 ago. At the time I was running an old version of the mod and just updated and haven't seen it since, guess the bug is still there somewhere thou.

A couple of issues I've seen recently (in the past couple days) I found a stack of 10 orthus' axes (a few tiles away a barb axeman had an 11th one) right beside Acheron's city that is on the border to the Svartalfar lands. From where orthus died I think it's highly likely that the svartalfar are the ones who killed him (the bannor and elohim are also on that landmass but they are pretty far away and orthus died only a few tiles from the svartalfar capital). Thing is the svartalfar don't have poisons or sorcery yet so no world hero nor illusionist so I don't know how they could have made any copies of the axe (unless anyone has any ideas?).

I had a cultist that was able to release himself from a cage, is that intended?
 
Top Bottom