Dune Wars - the Better BUG AI Edition

Colony Expenses seems to be zero whenever I hover over City Maintenance in the Financial Advisor for all players. Is that where you are looking?
No; I look in the maintenance hover text in the city screen.
I don't think the financial advisor distinguishes between the two.

AFAK, it only shows up if the city is not connected to the landmass that your palace (or forbidden palace) is on.

Take a look at attached save.
 

Attachments

  • Fremen.CivBeyondSwordSave
    367.7 KB · Views: 213
Right OK, the reason I could see it before in my game is because it seems quite heavily scaled by difficulty level so it hardly shows up on the lower ones.

It does show up in the Financial Advisor, but it shows only the integer part so where I had 0.78 total colony maintenance it was showing zero still.

The formula is more complex than just doubling it - it depends on various factors including population of the city and world-size and difficulty level scalings. The major factor is the number of other cities on the same continent as the colony - if your capital is on a island and all your other cities a on a big continent then it's really going to hurt you.

Here's the code for what it's worth.

Code:
int CvCity::calculateColonyMaintenanceTimes100() const
{
	if (GC.getGameINLINE().isOption(GAMEOPTION_NO_VASSAL_STATES))
	{
		return 0;
	}

	CvCity* pCapital = GET_PLAYER(getOwnerINLINE()).getCapitalCity();
	if (pCapital && pCapital->area() == area())
	{
		return 0;
	}

	int iNumCitiesPercent = 100;

	iNumCitiesPercent *= (getPopulation() + 17);
	iNumCitiesPercent /= 18;

	iNumCitiesPercent *= GC.getWorldInfo(GC.getMapINLINE().getWorldSize()).getColonyMaintenancePercent();
	iNumCitiesPercent /= 100;

	iNumCitiesPercent *= GC.getHandicapInfo(getHandicapType()).getColonyMaintenancePercent();
	iNumCitiesPercent /= 100;

	int iNumCities = (area()->getCitiesPerPlayer(getOwnerINLINE()) - 1) * iNumCitiesPercent;
	
	int iMaintenance = (iNumCities * iNumCities) / 100;

	iMaintenance = std::min(iMaintenance, (GC.getHandicapInfo(getHandicapType()).getMaxColonyMaintenance() * calculateDistanceMaintenanceTimes100()) / 100);

	FAssert(iMaintenance >= 0);

	return iMaintenance;
}

I'll remove the colonial maintenance component of maintenance and then set a value in GlobalDefines.xml that scales all other city maintenance so we can tune it.

Edit: I've have a separate variable in Global Defines for scaling Distance City Maintenance and Number of Cities City Maintenance so we can scale them independently if we want.
 
Thanks. I will digest the formula and come up with some suggestions.
Trickier to balance when it depends on difficulty level.
 
First off, thanks for all the work you guys have put into this mod, It's always fun to see what you've been up to.

Just wanted to let you know about a problem I had. I've installed from this thread, but I'm getting absolutely no text in the Diplomacy window. Looks like a BUG bug that has been reported in the first couple of pages of here.

The problem I think was that I had an existing install of BUG. The solution turned out to be deleting the My Games\Beyond the Sword\CustomAssets folder.

Hope this is helpful to someone.
 
Another little thing... The Ixian Skunkworks is only giving a 25% upgrade discount (not the 50% advertised). Looks like this is being overridden in the dll, but the cpp files you've shipped with seem to have the original BTS code only not your modifications.
 
Hi -- awesome mod, great work! I think I'm having a bug wherein all of the diplomacy dialogs are blank in the middle (where you are usually given options to agree/disagree with proposals). Offers (e.g., "Open Borders") still show up in the side columns, but there's no text at all in the middle section. The last version of Dune Wars worked fine for me, so I'm stumped as to what the problem could be.
 
Hi Luticus, welcome to Dune Wars. I think that issue was addressed by lordlunchtime two posts earlier...
 
There is a new version of Dune Wars 1.9.1 that adds multiplayer fixes from RevDCM 2.83, as well as other fixes and changes. Will write a full patch release note soon.
 
just played a game and the mod has greatly improved, fantastic work as always :)
i just noticed that you probably want to give the shield generator a much higher fVisibilityPriority, as of now they disappear if you build too many buildings in a city.

it also seems strange that some units paths can be researched with 'loopholes' in it. for example i got to las troopers without getting vendetta (guardians)
 
just played a game and the mod has greatly improved, fantastic work as always :)
i just noticed that you probably want to give the shield generator a much higher fVisibilityPriority, as of now they disappear if you build too many buildings in a city.

Thanks for that. I had no idea that the fVisibilityPriority could be used to fix this issue. The Force Shield has a value of 1 at the moment so raising it to 20,000 should do the trick.

tesb said:
it also seems strange that some units paths can be researched with 'loopholes' in it. for example i got to las troopers without getting vendetta (guardians)

I can see that it may be a problem that you can get Lasgun Weaponry for Lasgun Troopers without getting Vendettas for Heavy Troopers along the way. It could cause issues with unit upgrades, since you can only upgrade Master Guardsman to Heavy Trooper.
 
Top Bottom