"IndexOutofRangeException" error type

Discuss game box design and sharing.

Moderators: Ichibrothers, Cambronne

Post Reply
User avatar
johannhorangi
010
Posts: 33
Joined: 14 Nov 2010, 07:57
Location: Versailles

"IndexOutofRangeException" error type

Post by johannhorangi »

Hello,

After I have put new counters or new maps in the html file of the box, sometimes I receive this error message when I try to open formerly scripted scenarios :

"Erreur de type IndexOutofRangeException
L'index se trouve en dehors des limites du tableau".

(In English, it probably reads :
"IndexOutofRangeException error type
The index is out of the board limits")

The only way I have found to solve it is to erase all the data about the setup that appear in the first part of the scenario file. But then I have to rebuild the scenario setup (organizing maps and counters on the gameboard).

Is there a solution to solve the problem without having to do the setup again ?
User avatar
Bill Barrett
231
Posts: 351
Joined: 25 May 2008, 13:25

Post by Bill Barrett »

Yes, you have to be aware that if you add or remove counters/cards or terrains in a gamebox, all the counter/card/terrain index numbers (in scenario files) beyond the point that you make the change should be increased or reduced respectively.

It doesn't matter if you haven't yet laid out any scenarios, but if you have (as you've discovered) ZunTzu will report this error (or appear to "scramble" the components).

The simple answer is never to set up scenarios until you're absolutely sure of the exact number of components. Even a small change to the "supply" number of a counter can mess things up.

You could load up each scenario in notepad and change the relevant numbers by hand, but this will usually be too time consuming or error-prone. I don't have this problem anymore because I wrote a small program to do this for me automatically, but I'd need to do some more work on it before I make it available to others...
User avatar
johannhorangi
010
Posts: 33
Joined: 14 Nov 2010, 07:57
Location: Versailles

Post by johannhorangi »

Ok, thank you.
User avatar
Bill Barrett
231
Posts: 351
Joined: 25 May 2008, 13:25

Post by Bill Barrett »

If you have a lot of scenarios to redo, why not send me your gamebox and I'll have a go at fixing them for you (using my program)?
User avatar
johannhorangi
010
Posts: 33
Joined: 14 Nov 2010, 07:57
Location: Versailles

Post by johannhorangi »

Hello,

That's very kind of you, thank you.
I send you details by pm.
Actually the box is my last "Blindes Français au Combat" box : the author asked me to add a counter I had forgotten, and to do some small improvements.
Anyway it won't be a too big amount of work : the scenarios I did only featured maps and terrains, as the deployments of counters are frequently semi-free.
User avatar
Bill Barrett
231
Posts: 351
Joined: 25 May 2008, 13:25

Post by Bill Barrett »

Johann,

I'll have them fixed for you Wednesday night :wink:

Regards Bill.
User avatar
Bill Barrett
231
Posts: 351
Joined: 25 May 2008, 13:25

Post by Bill Barrett »

PM sent... :)
Post Reply