XML error

Do you need help installing or using ZunTzu? Would you like to report a bug?

Moderators: Ichibrothers, Cambronne

User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

XML error

Post by Ichibrothers »

Jerome,
First off, program looks GREAT!! Looking forward to getting things up and running!

Second, I know NOTHING about .XML

Here is the problem...
Created a game box and got this error on launch:

Error of type XmlException: Data at the root level
is invalid. Line 1, position1.

Here is my game-box.xml (created with Windows Wordpad, saved as text only):

Code: Select all

<?xml version="1.0" encoding="windows-1252" ?>
<game-box version="1.0"
	name="Honey Springs"
	description="The Battle of Honey Springs, Creek Nation - July 13, 1863."
	copyright="2007 Lawrence P. Duffield"
	startup-scenario="HS.zts">
	icon="icon.bmp">
	<dice-hand type="D6"> 
		<dice count="1" color="ffffff" pips="000000" /> 
	</dice-hand>
	<map name="Honey Springs" image-file="Honey Springs.jpg" resolution="300 dpi" />	<counter-sheet name="Counters" 
		front-image-file="hsc front.jpg" front-resolution="300 dpi" 		
		back-image-file="hsc back.jpg" back-resolution="300 dpi">
		<counter-section rows="2" columns="9" 
		front-left="334" front-top="0" front-right="1501" front-bottom="334" 
		back-left="334" back-top="0" back-right="1501" back-bottom="334" /> 
 	</counter-sheet>
 </game-box>
If I double click the file "game-box.xml", it opens in Internet Explorer no problem. The heading appears the same as in Jena 1806, so I am lost. Should the .xml be saved in .rtf or .txt mode?

Any help would be appreciated. Still need to figure out how to add the coordinates for the counters and everything should work out well.

Thanks,
Bill
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Re: XML error

Post by Jerome »

Hi Bill!

Just remove the ">" after startup-scenario="HS.zts".
Jerome, ZunTzu developer.
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

Jerome,
Thanks for the quick reply, but unfortunately that did not help. No time to deal with it now. I'll try again in a couple of days when I get home from work.

Thanks,
Bill
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Post by Jerome »

The "game-box.xml" file looks OK, so there must be an error in your "HS.zts" file.
Could you please show me its content?
It should start with:

Code: Select all

<?xml version="1.0" encoding="windows-1252" ?>
Jerome, ZunTzu developer.
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

Jerome.
Here is the .zts file:

<?xml version="1.0" encoding="Windows-1252"?>
<game
game-box="Honey Springs"
scenario-name="Battle of Honey Springs"
scenario-description="Creek Nation, July 13, 1863"
scenario-copyright="Lawrence P. Duffield">
<layout board="Honey Springs" />
<layout board="Counters" />
</game>



This is the dummy scenario file as I have yet to get the game box to load.

Bill


Edit:
Tried the .zts file with and without a space between 1252" and ?>

Also, edited the Jena 1806 game-box.xml with the Honey Springs info, and STILL got the XML error! All very frustrating...lol! These counters are two-sided. Should....type="TwoSided"....appear in the game box.xml as it does in the Jena gamebox?
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

Oh...by the way:

I'm running MS Vista Home Edition. Is Vista the problem? Jena 1806 works PERFECTLY!


Bill
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Post by Jerome »

Everything looks fine except that you wrote "Window-1252" with a "w" in upper-case instead of "windows-1252".
Can you fix it and try again?
Jerome, ZunTzu developer.
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

No Jerome. Still does not work...same XML error message.

BTW: I made the dummy scenario by copying the "How to add Scenarios" text example. Uppercase "W" there.

Maybe it is just something wrong with my computer, though Jena works fine.

Using Wordpad, what format should the .xml be saved? DOS .txt, Unicode .txt? I opened my game-box.xml in Internet Explorer and "saved-as", but that still did not work.

Bill
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

SUCCESS!!!!!!! :D :P :) Not sure which it was, but I had some characters in the .zts file that were in bold font, so I made sure to set everything to regular. Also, I may have saved the .zts in .rtf format....so tried saving it in .txt only, and it WORKS!!!!!! Just for giggles, I tried to build a different game-box using some other material.....it worked straight off! So I was really at a loss as to why the first one would not work...but it does now!

Thanks for all you help Jerome!!! Really looking forward to getting some game boxes made!!! One drawback of VASSAL is that you really have to KNOW a game's rules to make a top notch module. It is paramount to understand the relationship between the various counters, units, markers, etc. But, with ZunTzu, you can have a game-box up and running in moments! Then learn the rules as you play!!! Well done!!!

Thanks Again!! :D :D 8)

Bill
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Post by Jerome »

Hurray!! :D
Yes, the file has to be saved in plain text format (".txt"). I will indicate that in the tutorial. :oops:

As far as I know, you're the first one to test ZunTzu on Vista. I'm a bit pessimistic about Vista's support for audioconferencing. Did you try hosting a game?
Jerome, ZunTzu developer.
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

No not yet. When I do, I'll be sure to report back!!!

Thanks again!

Bill
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

Jerome wrote: Did you try hosting a game?

Hmmm.....clicked on "Host" and it said port 1805 is already in use! Try another port. Not sure what do do now. How can I find out what is using port 1805? Looked around in Firewall settings....allowed ZunTzu through them. No idea? BTW: Do you open your game first, and then select "Host"....or set up the connection and then start the game?

Bill
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Post by Jerome »

Ichibrothers wrote:clicked on "Host" and it said port 1805 is already in use! Try another port. Not sure what do do now. How can I find out what is using port 1805? Looked around in Firewall settings....allowed ZunTzu through them. No idea?
Typically that message is displayed when your router is UPnP compliant but ZunTzu failed to automatically open the port for some reason (for instance you have already manually forwarded port 1805 in your router). Is it the case?
Ichibrothers wrote:BTW: Do you open your game first, and then select "Host"....or set up the connection and then start the game?
You can do both.
If you open a game before hosting, players who don't have the game box registered in their libraries will be unable to join. ZunTzu will display a message to those players but still it may be confusing.
If you open a game after players have started to join, players who don't have the game box registered in their libraries will be disconnected. A message will be displayed.
Jerome, ZunTzu developer.
User avatar
Ichibrothers
211
Posts: 70
Joined: 15 Jul 2007, 16:27
Location: Rutland, MA

Post by Ichibrothers »

Jerome wrote:Typically that message is displayed when your router is UPnP compliant but ZunTzu failed to automatically open the port for some reason (for instance you have already manually forwarded port 1805 in your router). Is it the case?

No idea. Do not know much about routers and all that.

Bill
User avatar
Epaminonda
Posts: 12
Joined: 27 Mar 2008, 06:11
Location: Australia

Re: XML error

Post by Epaminonda »

Jerome wrote:Hi Bill!

Just remove the ">" after startup-scenario="HS.zts".
There is the same error in the "First Blood - Guadalcanal Campaign" game-box.xml file. However, the game seems to work and he just displayed a warning when you add it to the Game Library.

BTW, ZunTzu is really impressive. I have just started out with Vassal (I'm an old grognard that doesn't play since more than 10 years ago), which already left me very impressed, but here it is well beyond my wildest expectations...
:)

Well Done Jerome!!
Post Reply