Quick Modding Questions Thread

The times I have had that happen it was either

1) a graphical problem with the last or next item

OR

2) XML problem with the next item - and error in the Class Infos entry or mismatch between the class and default on the Class Infos and in the unit/building Infos.

I have lot's of units and buildings. And i am check next units/building Bomber and Broadcast Tower and i can't see any irregularity. Do you have some another idea or advice ?
 
@Dancing Hoskuld

I tested all units and buildings in World Builder and all are OK there. Maybe Sevopedia have some limit for all numbers of entity (buildings, units, promotions and etc).
 
Not that Caveman2Cosmos has discovered:lol:

Yes, C2C have GB and GB of stuffs, i forgot that :lol: have you some another idea what can cause this problem or what to check more ?
 
Testing in world builder does not find the problem where the default unit/building in the Class file does not match any in the Infos file. I found that out when I typed the name of a unit backwards in the default unit.
 
Testing in world builder does not find the problem where the default unit/building in the Class file does not match any in the Infos file. I found that out when I typed the name of a unit backwards in the default unit.

FIXED, @Dancing Hoskuld

You can't believe what is cause the problem. CIV4NewConceptInfos.xml is cause the problem, i added some new concept for bombard exp and that make problem, i removed them.

Removed:
Code:
		<NewConceptInfo>
			<Type>CONCEPT_BOMBARD_EXPERIENCE</Type>
			<Description>TXT_KEY_CONCEPT_BOMBARD_EXPERIENCE</Description>
			<Civilopedia>TXT_KEY_CONCEPT_BOMBARD_EXPERIENCE_PEDIA</Civilopedia>
		</NewConceptInfo>

Spoiler :
0QaPepM.jpg
 
I want to make Simple Color Utility (not important for description so much) to make modding easier for modders.
RGB have range from 0 to 255 for each color (R, G, B) and for Alpha.
In BTS range is from 0.00 to 1.00.
My question Is:
0.00 (BTS) equal 0 (RGB)
1.00 (BTS) equal 255 (RGB) ?

Code:
		<ColorVal>
			<Type>COLOR_CLEAR</Type>
			<fRed>1.00</fRed>
			<fGreen>1.00</fGreen>
			<fBlue>1.00</fBlue>
			<fAlpha>0.00</fAlpha>
		</ColorVal>
		<ColorVal>
			<Type>COLOR_ALPHA_GREY</Type>
			<fRed>0.1</fRed>
			<fGreen>0.1</fGreen>
			<fBlue>0.1</fBlue>
			<fAlpha>0.45</fAlpha>
		</ColorVal>
 
Yes. You can easily go into any painting program (or use the internet, really), select your desired colour, and divide the RGB values by 255.
 
Yes, it is.
 
Which python function clear plot ?
Example on plot (TERRAIN_GRASS) i have BONUS_IRON, FEATURE_FOREST, IMPROVEMENT_MINE, UNIT_AXEMAN.
I want to only stay TERRAIN_GRASS, which function or functions clear this ?
I make some python unit (some python nuke, which will clear all on TERRAIN_GRASS), because i ask this.
 
The barbarians need the prerequisite tech, much like the (proper) civilizations do. Tech spreads slowly from civs to barbarians. The exact formula for the barbarian's research per turn is in CvTeam.cpp:
Code:
changeResearchProgress(((TechTypes)iI),
  ((getResearchCost((TechTypes)iI) *
  ((GC.getDefineINT("BARBARIAN_FREE_TECH_PERCENT") * iCount) /
  iPossibleCount)) / 100), getLeaderID());
* researchCost(...) is the cost of the respective tech.
* iCount is the number of civs that know the tech.
* iPossibleCount is the number of civs that are still alive.
* BARBARIAN_FREE_TECH_PERCENT is defined as 3; divided by 100 that's 3 percent.
Usually, several techs are "researched" in parallel this way.
 
I am trying to make some changes to the main interface Python and want to test them in isolation. I created a new mod which just contains the mod ini file and a copy of the BtS CvMainInterface.py file. However it does not allow me to start any games as both the Play Now and Custom Game options are greyed out.

Does anyone know what it is that I also need to copy across? I want the bare minimum of stuff so I get to understand exactly what I am doing.
 
What is in your ini file? Have you let the game create it?

Edit: for me, you just need the MainInterface file and that's it. I never create an ini file as it is created automatically. Then you can customise it if you want.
 
Guys, I want to add several duplicates of buildings to the game, for example having two pyramids wonders instead of one, simply by copying the already existing pyramid code and using it again, using same art files as well.

Do I only need to only add a new entry in BuildingClassInfos and BuildingInfos? is that it?
Or do I need to add entries to CIV4CityLSystem as well?

Also Is there a limit to how many buildings I can add this way? Because I may be adding some 300 of them!... :shifty:

I basically want to give each civ their own version of a wonder to build if they want to. So that Each civ can build any wonder they want, such that if more than one civ wants to build a pyramid ..they can. Some of you might think "so just increase the number of instances allowed for the building in BuildingClassInfos!" ...but actually that doesn't work, there are issues with that. So I have to have separate buildings if I want to do this.

So is there a limits I need to worry about?
 
Well actually... the reason I think increasing number of instances worldwide wouldn't work for a wonder is because it will allow not only other civs to build the same wonder (which is what I want), but also it will allow the same player to build more than one (which I don't want). And If I allow only 1 instance per players but many for the world, I think what will happen is that if that player captures an enemy city that has a wonder that the player also already has, the second pyramid will disappear because the player isn't allowed to have 2, and I don't want that!

Am I correct in my interpretation about this?
 
I think you do this by having one building class with many building types. So all would have BUILDINGCLASS_PYRAMID but then you would have BUILDING_PYRAMID_ENGLAND, BUILDING_PYRAMID_GERMANY and so on. Assign each civ one BUILDING_ and then make them not capture in the building infos file.
 
Back
Top Bottom