1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

WoC Lite(made for merging)

Discussion in 'Civ4 - Mod Components' started by johny smith, Apr 12, 2009.

  1. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    Diplomacy fix worked! :)

    Here is another error:

    Orion Veteran :cool:
     

    Attached Files:

  2. johny smith

    johny smith Deity

    Joined:
    Mar 10, 2007
    Messages:
    2,273
    I am not getting that error though. The error means the CIV4BuildingsSchema.xml does not have "<element type="bDCMNukesOkay" minOccurs="0"/>". Is the schema the same in the DCM folder as in the download?

    Here is the schema I have in case.
     
  3. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    They are identical. Problem persists...

    Orion Veteran :cool:
     
  4. johny smith

    johny smith Deity

    Joined:
    Mar 10, 2007
    Messages:
    2,273
    Well if any building was added can be the only thing I can think of. If you added any buildings replace the schema with that one. It has to be some building loading from the wrong schema. Not many other possibilities really. I will look at my upload it it persists to see if I missed something.
     
  5. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    Problem fixed:

    1. The naming convention must be CIV4BuildingsSchema.xml. Can't put "DCM_" or anything else in front.

    2. All new buildings added must have the new schema file.

    Once I made those changes, it worked. Thanks for your help.

    Note: I like having the DCM mod in it's own folder. :goodjob:

    Sincerely,

    Orion Veteran :cool:
     
  6. johny smith

    johny smith Deity

    Joined:
    Mar 10, 2007
    Messages:
    2,273
    Yes sorry I should of said that. All schema has to have the same exact name. Yes everything new added has to have the matching schema file. Anything units, leaderheads, or etc.

    DCM I think I will split up into more pieces when I get the chance as well. So it easier to know what is being loaded.
     
  7. xienwolf

    xienwolf Deity

    Joined:
    Oct 4, 2007
    Messages:
    10,589
    Location:
    Location! Location!
    I'm in need of a bit of assistance if any of the major code-monkeys happen to be checking up on this thread (or if you are getting familiar enough with things by now Johny).


    I imported WoC Lite (the very early version, then some enhancements from later versions) and attempted to keep myself from cleaning things up as I went through since I was quite likely to be wrong about some of them being purely for debug information. Tested things with loading the mod and it all worked fine, so then I cleaned up a bit and started adding all of Kael's and my own new fields to the CopyNonDefaults routines.

    As I was about 50% through with setting up the new fields, I decided to test them with a module that I knew worked before the merge and only used those files I had already set up. Worked like a charm, even when I added a few fields which would not have been possible with Firaxis modular loading. Problem is, while testing out something else, I happened to figure out that this entire time I had NEVER tested loading a savegame (a huge mistake which I shouldn't have made).


    So, long rambling story aside: I broke my mod. It loads wonderfully, it plays as well as it ever has. But loading a savegame results in an instant CtD. There was a lot of new stuff involving savefiles and loading in this merge, I am reasonably certain I haven't touched any of it, but rather just imported it all directly. But I might have needed to add something to it, or might have accidentally removed some thing from it somewhere along the way.


    So, if anyone has some time, I'd love a bit of assistance. And the nice thing is that while you are in the code you can swipe any of the few hundred fields added by Kael and myself in FfH/FF DLL work, some of which might prove quite nice for WoC to have available ;)


    The zipfile is huge, but you just have to place the folder in your Mods directory and it should run. The included CvGameCoreDLL folder (parallel to Assets) contains everything required to compile in either Codeblocks or VS2008++, as long as you have your system set up already to be capable of such compilations already (the whole libraries thing and whatnot).
     
  8. TAfirehawk

    TAfirehawk WoC Team Manager

    Joined:
    Aug 25, 2006
    Messages:
    2,326
    Location:
    Florida
    I remember us having savegame problems....like over a year ago, so I don't remember the details unfortunately. I may see if mrgenie remembers anything or maybe I can find something in the SVN logs. Personally I stayed out of the code and mrgenie did it all but now I am getting in to the code but can't be of much help just yet. The WoC Lite really needs to stand on its own as a modcomp for doing "proper" modular loading that any modder can use. The WoC Full then would have all the goodies of dozens of fantastic modders' work combined in to a modular SDK.

    And yes I would love to see FfH/FF added to the WoC Full SDK :)
     
  9. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    I performed a search to get a list of all files that were modified since 27 May 2009. The list is fairly small and should narrow your search. There is a very high probability that your CTD bug is in one of these files. Best I can do for now.

    CvGameCoreDLL.dll
    CIV4PromotionInfos.xml
    CvEventManager.py
    CvPediaCivilization.py
    CIV4GameText_Modcomp.xml
    CIV4GameText_Other.xml
    CIV4ProcessInfo.xml
    CIV4CivicInfos.xml
    CIV4BuildingInfos.xml
    CIV4ArtDefines_Unit.xml
    CvGameUtils.py
    CvCivicsScreen.py

    Respectfully,

    Orion Veteran :cool:
     
  10. johny smith

    johny smith Deity

    Joined:
    Mar 10, 2007
    Messages:
    2,273
    I am swamped with things to do. But will try to give a look as soon as I can. I have not had any save game problems with the WoC Lite yet so far. But there has been more recent problems I know in the Full version with save games. Sorry for slow response I will look at it.
     
  11. xienwolf

    xienwolf Deity

    Joined:
    Oct 4, 2007
    Messages:
    10,589
    Location:
    Location! Location!
    No problem, it is almost certainly something that is based in my merging or my code, so I don't EXPECT help, but it never hurts to allow people the opportunity to do so :)

    Thanks for the search Orion :) I am 100% certain that the issue is completely in the DLL, and in the new materials I merged from WoCLite or wrote to support it as well.
     
  12. avain

    avain (key)

    Joined:
    Jul 29, 2006
    Messages:
    2,770
    Location:
    Budapest, EU
    Hi Johny,

    I don't know if this has been reported before, but in WoC RevDCM at least the
    <iDCMBombRange>
    <iDCMBombAccuracy>
    tags are not WoC compliant,
    meaning they are lost if a WoC modular XML unit overwrites (only) some (other) tags of the unit.
     
  13. johny smith

    johny smith Deity

    Joined:
    Mar 10, 2007
    Messages:
    2,273
    I might of missed something. I am still learning as I go. But what I saw in the WoC Full I used as an example in my dll for the file for the DCM tags. There is an extra tag in the Full I left out. I mean the same RevDCM code just different xml lines slightly used. So if something is not working in this let me know please.

    I got some modular python idea that I am working on. I finally figured out zmodularpython anyway. So I loaded some python events modular and was going to look at it more. Just need some more time to play with it.

    I was wondering if it sounded crazy to make a screen that checks all globals defines loaded and allow it to be configured outside of the BUG screen. I mean as it lights up the text as green if something is on and red if off like in shows now. Except for anything when it is loaded was my idea instead of adding them manually ahead of time. Meaning it finds all globals defines.

    I mean a whole separate screen. Anyway was going to try to look into it. And thought about trying to get change player and change civ in one screen. Maybe autoplay as one. Just need to see what I can do. Well probably crazy thoughts.
     
  14. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    Both are compliant in RevDCM! Please Check out the following file:

    RevolutionDCM\Assets\Modules\DCM\DCM_CIV4UnitInfos.xml

    I like giving ranged bombardment to units like the Catapult and all Tanks. I made my easy changes to the DCM_CIV4UnitInfos.xml file and instantly these units now have ranged bombardment capability. :D

    Example:

    Code:
    <UnitInfo>
    	<Type>UNIT_CATAPULT</Type>
    	<iDCMBombRange>1</iDCMBombRange>
    	<iDCMBombAccuracy>50</iDCMBombAccuracy>
    </UnitInfo>
    
    Respectfully,


    Orion Veteran :cool:
     
  15. mamba

    mamba Deity

    Joined:
    Aug 23, 2007
    Messages:
    2,520
    Your example does not fit avains problem description, so it does not prove him wrong ;)
     
  16. xienwolf

    xienwolf Deity

    Joined:
    Oct 4, 2007
    Messages:
    10,589
    Location:
    Location! Location!
    Aye, he says that if after THAT module you posted, you had another which only changed the <Description>, it would clear out the iDCMBombRange & iDCMBombAccuracy

    (ie - Modules can INSERT those values, but will ALWAYS overwrite them, with a default if not expressly included)
     
  17. OrionVeteran

    OrionVeteran Deity

    Joined:
    Dec 25, 2003
    Messages:
    2,443
    Location:
    Newport News VA
    I'm really not trying to prove anyone wrong, I just wanted to provide an example of how the tags work in RevDCM. I believe they will also work in WoC 1.2.

    1. You import the DCM folder
    2. Reference the DCM folder in the MLF_CIV4ModularLoadingControls.xml file
    3. Swap out your schema files
    4. Make your python updates
    5. Update the CvGameCoreDLL.dll file (the hardest part).

    If I missed something, please let me know.

    Respectfully,

    Orion Veteran :cool:
     
  18. xienwolf

    xienwolf Deity

    Joined:
    Oct 4, 2007
    Messages:
    10,589
    Location:
    Location! Location!
    FireHawk & Genie: Is there somewhere in the WoC forums I can bug you to see if you can recall how/where savegames broke for you previously, or what I may have messed up myself? Not entirely appropriate for this Modcomp I guess to puzzle it out here.

    I ran under Debug DLL a few times, always breaks in a strange place, doing itterations over promotions IIRC. I set up breakpoints in numerous locations which seem involved with loading a savegame (but haven't yet hunted ones involved with unloading a current game, seems it would be a waste of time though with what I found). Anyway, the only one to fire at all was:

    Code:
    	case CONTROL_QUICK_LOAD:
    		if (!(isNetworkMultiPlayer()))	// SP only!
    		{
    			gDLL->QuickLoad();
    		}
    		break;
    
    
    Which is in CvGame::doControl.

    When that one fired, it was the response to hitting SHIFT F8, so I told the game to continue assuming a later one would fire, THEN I can start stepping through the code, but it broke instantly. On second run, I stepped with it, and as it broke during gDLL->QuickLoad();, which is an EXE function. So it is breaking VERY early. I tried a normal load routine, didn't have a breakpoint in the right spot to step those, but it also broke near instantly.



    Mostly hoping that this might ring some bells :) Going on vacation soon, so I'll be infrequent for posting, but hopefully have plenty of time to try and debug further.
     
  19. TAfirehawk

    TAfirehawk WoC Team Manager

    Joined:
    Aug 25, 2006
    Messages:
    2,326
    Location:
    Florida
    xienwolf,

    Do you have the WoC SVN? If so, update 923 lists mrgenie marking a spot in CvInitCore.cpp for savegame compatibility method. Update 950 makes "Part 1" functional but not complete...it edits a lot of files, too many to list here.

    I don't see anything else in the SVN log but I will be looking in to the Mantis Bugtracker history a bit later.
     
  20. xienwolf

    xienwolf Deity

    Joined:
    Oct 4, 2007
    Messages:
    10,589
    Location:
    Location! Location!

Share This Page