For modders & mergers

I started merging my mod with your revolution mod and ran into problems right at the first file. I've got your version 1.61. Although I thought that our both versions include solver 0.17 there is difference in the code that isn't marked as new code from you and it's definetly no code from me. Can you help me jdog5000?
 
I started merging my mod with your revolution mod and ran into problems right at the first file. I've got your version 1.61. Although I thought that our both versions include solver 0.17 there is difference in the code that isn't marked as new code from you and it's definetly no code from me. Can you help me jdog5000?

The code on the right is the same in BTS 3.17, Solver 0.19 (I think 0.17 too) and Revolution 1.61.
You must have changed your code on the left.

Matze
 
Thanks MatzeHH. :goodjob:

Your absolutly right. I must have imported the code without notice from the 3.13 version. :crazyeye:
 
I figured it was something to do with the makefile, but it seems this is not true :/ Is having VC2003 the *only* way to build the debug dll?

And if so, is running with the debugger only possible when having VC2003 installed (ie because code:blocks doesn't have the necessary dlls)? Really I just need to find some problems, not to actually write any C++.
 
No, VC2003 is not the only way to get a debug setup working. glider1 and others have figured out how to do it with free legal tools, check out this thread (their debugging success is towards the end) and bug those involved to right up step-by-step instructions for the good of the community if they haven't already.

EDIT: Instructions from Refar can by found here.
 
Quick question - is there either an xml variable I can change, or somewhere where I can insert or manipulate a simple line of Python, to get barbarian civs (regardless of builder or military) to receive a settler when they go from barbarian --> minor civ?
 
In BarbarianCiv.py in the function createMinorCiv, there's a line which reads:

pyNewPlayer.initUnit(iWorker,cityX,cityY,1)

Right below this line add a copy which replaces iWorker with iSettler, so:

pyNewPlayer.initUnit(iSettler,cityX,cityY,1)

Be warned that Python is very particular about indentation, you should use spaces to line this up with the other line. Just for reference, the unit types I have set up are at this point in the file are:

[iWorker, iSettler, iScout, iBestDefender, iCounter, iAttack, iMobile, iAssaultShip]

iAssaultShip and possibly iScout may be set to None, indicating the civ cannot build a one of those yet.
 
Hey jdog,

I've been meaning to tell you this for a while. It's not realy a bug, per se, but more applicable to modders.

In my mod, I have disabled all starting techs. Accordingly, for the first few turns of each game, I get a Python exception regarding TechDiffusion.py. I assume that it is trying to diffuse techs but there are no techs to diffuse hence the error. Nothing game-breaking by any means, but I just wanted to bring it to your attention. If you need me to provide you with the exact error, just let me know.

Cheers,
ripple01
 
Using VC++2005 Express, following Refars instructions and using his makefile, I can reliably build the standard BtS 3.17 DLL. Taking a new copy of it and replacing applicable files with the source files for Revolution 1.65, I cannot complete a build. It compiles but won't link because of a problem with CyCityInterface2. Here's the message. (I set off items in quotes by inserting blank lines)
Code:
1>   Creating library Final_Release\CvGameCoreDLL.lib and object Final_Release\CvGameCoreDLL.exp
1>CvDLLPython.obj : error LNK2019: unresolved external symbol 

"void __cdecl CyCityPythonInterface2(class boost::python::class_<class CyCity,struct 
boost::python::detail::not_specified,struct boost::python::detail::not_specified,struct boost::python::detail::not_specified> &)" 

(?CyCityPythonInterface2@@YAXAAV?$class_@VCyCity@@Unot_specified@detail@python@boost@@U2345@U2345@@python@boost@@@Z) referenced in function 

"void __cdecl DLLPublishToPython(void)" 

(?DLLPublishToPython@@YAXXZ)
1>Final_Release\CvGameCoreDLL.dll : fatal error LNK1120: 1 unresolved externals
1>NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual C++ Toolkit 2003/bin/link.exe"' : return code '0x460'
1>Stop.
1>Project : error PRJ0019: A tool returned an error code from "Performing Makefile project actions"
1>Build log was saved at "file://c:\Users\Tholish\Desktop\CvGameCoreDLL\Final_Release\BuildLog.htm"
1>CvGameCoreDLL - 4 error(s), 0 warning(s)
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========

Build log contains pretty much the same information.

So, there's a function somewhere called DLLPublishToPython that looks in CyCityInterface2 at function CyCityPythonInterface2 and doesn't find it everything it wants?

What can I do to make this work right?


EDIT: the function DLLPublishToPython was in CvDLLPython. I commented out the call to CyCityInterface2 and put all the methods from CyCityInterface2 into CyCityInterface1 and it built. Don't know how it will play, or why it happened to me. Anyway.

ANOTHER EDIT: No ill effects.
 
I have discovered an interesting problem when adding a new feature to Rev DCM. The file xml/terrain/civ4terraininfos is very order dependent and there are other constants you must change when you add a feature.

Symptom: you define a new feature, you add it in WB, and next turn, the feature is deleted.

Workaround: in xml/globalaltdefines.xml, increment NUM_FEATURES. Make sure your new feature appears after the last game feature in the featureinfos file, but before the first battlefield feature.

Proposed solution: I don't know what is happening inside the sdk, but you should distinguish between the battlefield features and the game features in some other way. For example, add an xml tag bIsBattleFieldFeature. Then make sure that you do not rely on the constant and the order of the file to distinguish the two types.

(EDIT: it is more complicated than this, and subject to crashing. See this post for more information.)
 
I have no use for the larger TGA files in res/fonts in the RevolutionsDCM 2.5X. The standard one is large enough for anything that would not be grossly imbalanced until adjusted for. (More than 25 religions and corporations indeed! Maybe if you had lots of essentially unique resources...)

I could swear I saw where someone made a patch for removing it, but cannot find it now. How would I go about using the old, smaller tga?
 
Just began lurching around at the forums again. You can set the xml in the res folder for religions and corporations to 25 each and return to the old GameFont files. Now as for the bigger fonts it was the only way to crack open the limit that has been plaguing some other mods that wanted more.
 
Actually with 2.7 most scenarios will be able to load. At least any scenario that will work for vanilla BtS will work fine with 2.7, thanks to Tamudjin's fix the CvWBInterface.py, no more CTDs when they player numbers don't add up.
 
Actually with 2.7 most scenarios will be able to load. At least any scenario that will work for vanilla BtS will work fine with 2.7, thanks to Tamudjin's fix the CvWBInterface.py, no more CTDs when they player numbers don't add up.

Holy...seriously? :eek:

:worship: Tamudjin :worship:
 
Top Bottom