Counter Wheels

General discussion about ZunTzu in English.

Moderators: Ichibrothers, Cambronne

Post Reply
gmgoncal
Posts: 4
Joined: 27 Nov 2009, 05:00
Location: USA, CA

Counter Wheels

Post by gmgoncal »

Jerome mentioned counter wheels in a couple of topics and I spent the last day or so experimenting with them to see what could be done. Now, maybe this is self-evident to most, but, in case there is someone else out there interested in adding a counter wheel I will share what I have found as it may save them some time of trial and error. (For those who don't know what I mean by a counter wheel, it is simply a counter with numbers all around the edge(s). Using the facing/rotate feature of counters -- i.e., turning the mouse wheel when the counter is activated -- you can rotate the counter to select one of the numbers along the edge, as a means of keeping track of victory points, health, etc. The counter's shape can have the same number of edges as the numbers being tracked -- i.e, a hexagon for tracking up to 6, an octagon for tracking up to 8, etc. -- or it could just be a circle. It makes no difference. What you are after is that at some point, after you spin the mouse wheel, a number be displayed at the location you are using to keep track of the numbers.)

First point, and most important, as far as I can tell, is that counter wheels are best used for counters with a number of sides that are divisors/factors of 24. That is 1, 2, 3, 4, 6, 8, 12 or 24 sides. (Obviously, for our purposes 1 and 2 are not relevant.) If you take any counter and rotate it, you will see that it takes 24 clicks of the mouse wheel for it to come back to its original position. Maybe there is a way to change that number, maybe it is hard coded. Not sure, but 24 is what I found to be the magic number. So, if you create a 24 sided counter wheel with numbers 1 - 24 around the edges, you will get a different number at the top of the wheel every time you rotate the mouse wheel. If you create a 6 sided counter wheel with numbers 1-6 around the edges, you will get a different number at the top of the wheel every four times you rotate the mouse wheel, etc. However, if you create an 18 sided counter wheel with numbers 1-18 around the egdges, you will sometimes get a number at the top of the wheel when you roate the mouse wheel, but sometimes the counter will stop in between two numbers -- because 18 is not a divisor of 24. So, this means that if you want a counter that goes from 1 to 9, knowing that 9 is not a divisor of 24, you must choose a counter with enough edges to include all the numbers, but still is a divisor of 24. You could, for example, use a 12 sided counter, number the first nine edges 1 through 9 consecutively, and leave the three last edges blank. Now, the problem that I have not been able to surmount is what to do if you need a counter wheel to keep track of numbers up to 25? Not sure that there is a solution to that. Again, as far as I can tell, 24 is the magic number.

Second point, depending on how large your counter wheel is (i.e, how many pixels in size) and how many numbers you use, it can be pretty hard to tell what number you have selected because the numbers might be fairly close to each other. I have found that you can put another counter on top of the counter wheel, and using a mask, have a window on the second counter through which the selected number shows through. In essence this is simply replicating what you get with a counter wheel in real life -- 2 pieces of cardboard, the one in the back has the numbers, the one in the front has a whole cut out for you to see the numbers, and another whole for you to rotate the wheel in the back. So, if you create a graphic with a mask that cuts out a window and another whole to rotate the wheel, you can simply stack it on top of your counter wheel. (actually, when you turn the counter wheel, that counter will pop on top when it is activated, but will pop back again when you are done and move the mouse away.) Because the counters are stacked you will see that the top counter will want to offset, as it is supposed to do when two counters are stacked. You can turn off stacking at the lower right hand corner of the board to prevent this from happening and make the counters sit nicely one on top of the other. Of course, this solution may not work in a game where you actually need your other game pieces to stack in the normal way.

Not sure if any of this was clear to anybody, but, again, may be it can help someone down the line.
Yours, George.
bggames01
120
Posts: 38
Joined: 09 Nov 2009, 23:58
Contact:

Post by bggames01 »

Instead of having a counter wheel, and another counter to mask the wheel, why don't you draw the "wheel" numbers onto the layout graphic, and only use the masking wheel with the hole. If you rotate the wheel with the masked hole you will also cycle trough the numbers.

You can either draw the numbers in a circle around the counter wheel, like:
____1
__6 (l) 2
__5 ( ) 3
____4
Or draw the numbers behind the wheel and use the masked window:
___([1])
__( . . . )
___( . .)
gmgoncal
Posts: 4
Joined: 27 Nov 2009, 05:00
Location: USA, CA

Post by gmgoncal »

Brilliant! Sometimes you are too close to something to see some good alternatives
User avatar
Jerome
Site Admin
Posts: 974
Joined: 22 Jun 2006, 21:31
Location: France
Contact:

Post by Jerome »

I confirm that rotation works by increments of 1/24 of a turn.
Jerome, ZunTzu developer.
Post Reply