Civ4 XML Editor

Nice program! runs fine on my computer.. could save some time when editing XML.. are you planing on makeing it able to create new elements in the near future.. would make it a nice tool to have when reskining units or createing new...
 
GarretSidzaka,
Thanks for the good idea concerning the file database. As mentioned above I'll be uploading a new version soon. I'll place that one in the database.

The keyboard arrows work OK for me. What kind of problems are you having?

i wasnt able to scroll with the arrow keys while in the program. i just checked its still doing it for me, but the PgUP and PgDN still work
 
Is it possible that the NumLock key is on? Sorry, if you already checked this, I just wanted to make sure.
 
Zebra 9,
I'm working on an improved version of the program that allows the user to clone and delete parts of the XML file. When I upload that I'll also include the source code (hopefully within the next week).
I'm also trying to find the solution to a problem that some users are having when trying to run the program in windows XP. The above post by Jesus Civs explains the problem. I would like to fix that before uploading the next version. Does anybody have any ideas on what could be causing it? I'm using Py2exe to convert the python program to an executable. I think py2exe is assuming that there will be a certian dll file on the user's computer, but it's not on all computers.
I think your right about the assumed dll. If you want we could try converting it to an exe on a windows XP system to see if it works then.

If needed, I have an XP system with python 2.5, win32, py2exe, and am willing to download additional python addons and compile this for you.;)
 
Thanks for the offer Zebra 9, but I already tried that and it didn't work. If you would like to give it a shot anyway, I'll be uploading the source code with a new version in the near future. I guess it's always possible that a different computer might provide different results. All I ask is that you don't change the source code in any way.


For the record, I have compiled the program on two computers - one Vista and one XP. I have attempted to run the program on 6 computers - one Vista and five XP. It runs fine on all but one computer, and that computer just had a fresh install of XP (along with all of the updates). It looks like the editor requires a DLL file that doesn't come with XP, but get installed by some other piece of software at a later time.


Once I release the source code. Another possible solution would be to have people that are experiencing the problem download the Python interperter and just run the source code. If somebody wants to try it I'll provide the link and instructions.
 
I just posted a new version of the editor. The link, along with a description are located in the first post of this thread.
 
Just download SysInternals File Monitor, run that, then run the compiled editor, watch the File Monitor display: it will list which dll's are being accessed.
It's probably the vb6 runtime dll's.
 
Huh, thats strange, well I'm DLing. Is alright with you if I use the xml reading code to read XML files for my MOD Maker? I will give you full credit for the reader code.
 
Sure, no problem.
 
Well, I have the same problem as Jesus Civs. :(

The programm shows an error and write the following lines in the log file:
Code:
Traceback (most recent call last):
  File "Civ4 XML Editor v109.py", line 15, in <module>
  File "win32ui.pyc", line 12, in <module>
  File "win32ui.pyc", line 10, in __load
ImportError: DLL load failed: &#25351;&#23450;&#12373;&#12428;&#12383;&#12514;&#12472;&#12517;&#12540;&#12523;&#12364;&#35211;&#12388;&#12363;&#12426;&#12414;&#12379;&#12435;&#12290;

May be it happens because I use Japanese Windows OS? I switched the default language for non-unicode programms to English, but it didn't help... :confused:
 
While I have an idea what is causing the problem, I can't find any information on how to fix it.

There is a way to possibly get around the problem. If you or JesusCivs would like to try it, I'd be interested in hearing what happens.

First you need to download and install the Python interpreter. It's located at: http://www.python.org/download/releases/2.5.2/. Most people will want the version labeled "For x86 processors". Then double click on the Civ4 XML Editor v109.pyw icon. It's located in the "Source Files" folder located within the "Civ4 XML Editor v109" folder.

If anybody tries this please let us know what happens, it would be a big help for other people experiencing the same problem.

Fujisan,
I don't think that the "default language for non-unicode programs" setting would cause this problem. Since you're using the Japanese version of Windows, I'd also be interested in hearing how the editor handles the encoding within your XML files.
 
Headlock,
Let me know what you think of the editor. I prefer using my editor for Civ4 files over notepad++, but then I'm probably a little biased.
 
First you need to download and install the Python interpreter. It's located at: http://www.python.org/download/releases/2.5.2/. Most people will want the version labeled "For x86 processors". Then double click on the Civ4 XML Editor v109.pyw icon. It's located in the "Source Files" folder located within the "Civ4 XML Editor v109" folder.

If anybody tries this please let us know what happens, it would be a big help for other people experiencing the same problem.

Ok. I did as you wrote. And "EditorGlobals.pyc" (9KB) appeared in the "Source Files" folder.

But the Editor still does not work. :(

I wonder, does this problem relate somehow with XML-errors on non-english Windows, about which I reported in the Civ4 BTS - Bug Reports?
 
Fujisan,
Thanks for trying that.
It probably doesn't have anything to do with the XML-errors issue, since the program fails before it attempts to load an XML file. You would have to run the program from within the Python editor to get the actual error message.
 
GarretSidzaka,
I think I now see what you where talking about concerning the keyboard arrows. There was no keyboard command to edit an item once the arrow keys where used to select it. I am working on a new version and the Enter key can be used to edit an object in the Element List.

The next version will also have the ability to clone and delete items in the Class List. That means you can do things like add a new unit to the game by just pressing the insert key when you have a similar unit selected. You will still have to edit some items in it's Element List to finish the unit, but the editor makes that easy.
 
If you want the error messages without using the python console just add
Code:
sys.stderr = open("errors.txt", "w")
then have him send errors.txt to you.
 
Back
Top Bottom