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

Excel file for editing civ4 xml files

Discussion in 'Civ4 - Utility Programs' started by talchas, Mar 23, 2006.

  1. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    This is a MS excel file that can be adapted to edit just about any Civ4 xml file. Currently it has the ability to edit units and promotions. Each unit/promotion is one column, and each property is a row. You can both import and export data to and from the xml files.

    Before exporting, change cell B1 in whichever sheet you are editing to point to where you want to save the xml file. If you import an xml file, the script will automatically change this to wherever you imported the file from.

    You can use the buttons on the left to show and hide groups of items.

    When you open the file, excel will probably ask you whether to enable or disable macros. If you disable macros you won't be able to import or export data.

    Thanks to Kael for giving me the idea to write this, and the makers of homeworld 2 for giving me the idea to make it based on a series of commands.

    EDIT:
    Added sheets for unitclasses and techs. Fixed the problem with the civilopedia in the promotion sheet, it is now disabled by default.
     

    Attached Files:

  2. sgrig

    sgrig Comrade

    Joined:
    Nov 29, 2001
    Messages:
    1,123
    Location:
    Isaac Newton's College
    Wow this is great! It really simplifies the job of editing XML files.
     
  3. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    I forgot to mention that this creates xml files that are usable with my Civilopedia Promotion Info mod, and regular Civ4 will complain if you use this. If you don't want to use my mod, delete the Civilopedia row (row 10) from the xls file and it won't add that tag.
     
  4. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    I've added unitclasses and techs to this now and fixed the promotion problem. What would you people like next?
     
  5. boneys26

    boneys26 BTS Play session tester

    Joined:
    Nov 24, 2005
    Messages:
    839
    Location:
    Coventry, England

    could you do some bottons for all the dif air units there are as were stuck with the old ones:goodjob:
     
  6. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    What do you mean? Are you asking me to make buttons? Because if you are, you wouldn't like the results. I can't draw worth beans.
     
  7. boneys26

    boneys26 BTS Play session tester

    Joined:
    Nov 24, 2005
    Messages:
    839
    Location:
    Coventry, England

    lol I'm the same. oh well do you know how to start a mod i'm new to this and all i've picked up so far is xml :sad:
     
  8. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
  9. Gunner

    Gunner Emperor

    Joined:
    Aug 21, 2004
    Messages:
    1,389
    Location:
    Goochland, VA
    Wow, this thing is amazing. Thanks talchas :goodjob:
     
  10. Crighton

    Crighton Emperor

    Joined:
    Jan 3, 2006
    Messages:
    1,136
    sitting at work, found a few good threads then I randomly scroll down and see this thread.

    Thank you sir.

    ~C
     
  11. boneys26

    boneys26 BTS Play session tester

    Joined:
    Nov 24, 2005
    Messages:
    839
    Location:
    Coventry, England
    could you add building infos too? building class infos
     
  12. woodelf

    woodelf Bard

    Joined:
    Jun 12, 2003
    Messages:
    15,036
    Location:
    Gallery
    Wow, quite impressive talchas. It makes me wish I had Excel at home now...
     
  13. Gunner

    Gunner Emperor

    Joined:
    Aug 21, 2004
    Messages:
    1,389
    Location:
    Goochland, VA
    Just checking, but should this still work for the new patch?
     
  14. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    I think so. Make sure you reimport all the files though if you want the latest changes and don't have any data in the file you would lose.
     
  15. wotan321

    wotan321 Emperor

    Joined:
    Oct 25, 2001
    Messages:
    1,218
    Location:
    NC, USA
    This looks to be a great app, thanks for the hard work in putting it together. The thing is... I only need it to work on the tech tree of a mod, but the tab for techs gives me an error message when I click on the "Import Tech Data" button. I have changed cell B1 to the correct civ4techinfos.xml file. Anyway, when I press the "import tech data" button... or the Export button for that matter, I get an error msg in Excel that says "FFH-talchas.xls could not be found". What have I done wrong?

    Secondly, will this thing work then with new and different techs?
     
  16. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    About the error - not your fault, the xls is adapted from something I did for FFH, and stupid excel must have made it refer to the FFH xls file when I copied it over. Since I only tested when the FFH xls was in the same folder, I never saw it.

    It will work with new techs as long as they follow the same layout. However, it overwrites the old xml file, so import before doing any changes. I'll put out a new, fixed version soon.
     
  17. wotan321

    wotan321 Emperor

    Joined:
    Oct 25, 2001
    Messages:
    1,218
    Location:
    NC, USA
    Thanks, that would be great. We really appreciate your hard work on this.
     
  18. talchas

    talchas Prince

    Joined:
    Jan 3, 2006
    Messages:
    428
    Fixed .
     
  19. stgelven

    stgelven Prince

    Joined:
    Apr 22, 2003
    Messages:
    398
    Location:
    pays de loire - france
    great work! very usefull i think your tool is the only one xml editor that run properly !

    can you make possible to edit all xml files? could be usefull for translation for ex. or editing buildings or whatever possible with civ 4 xml files.

    Edit: it seems this version is not compatible with 1.61
     
  20. erikg88

    erikg88 Warlord

    Joined:
    Nov 15, 2003
    Messages:
    130
    Is it possible to make this work with OpenOffice?
     

Share This Page