Latest Posts

Topic: Testing tools

chuckw
Avatar
Topic Opener
Joined: 2010-03-15, 15:23
Posts: 945
Ranking
One Elder of Players
Location: New York - USA
Posted at: 2010-12-31, 17:59

In developing for WL, there arise occasions when some preliminary testing is desired before committing a change to the trunk. This forum thread is intended to discuss tools and techniques for testing anything from code to graphics and sound content.


I see little people.

Top Quote
chuckw
Avatar
Topic Opener
Joined: 2010-03-15, 15:23
Posts: 945
Ranking
One Elder of Players
Location: New York - USA
Posted at: 2010-12-31, 18:04

I posted this entry first in the Graphics forum, but due to its technical nature I thought I'd solicit input from readers of this forum, too.

I'd like to create a reference tool that one could use when designing buildings and other immovable objects for use on the game board.

There are rigid size restrictions for immovables owing to the potential paths that roads may take to and around them.

To test whether a newly designed building will "fit" well, currently I have needed to actually start up a test version of the game after placing the new building's file(s) into it. Then, I have to "build" the building and construct the roads around it to get an idea of the building's impact. This time-consuming process must be repeated every time a test is desired.

While the empty_building Blender template contains a very handy reference object for constructing the 3D model, it does not allow testing of the final rendered size and map placement.

The tool I would like to create for use would be a png file which contains a 2D grid of triangles that mirrors the one used on the game board (i.e. the maps) and from which the roads are derived. That grid is described in the AboutGeometry document. The test grid would have the same physical scale and edge angles as found in the game.

This tool would then provide a handy gauge that could circumvent the need to fire up an actual game as it would require only a 2D graphics editor like GIMP.

So, can someone tell me or lead me to the data I'll need to construct the gauge? Certainly, if another reference method is available, I'd love to learn about it.

After giving this idea of the gauge a little thought and reading the AboutGeometry document closer, I am creating the gauge image as follows:

The document states the sides of the triangles are equal to one another and have a value of 1 which is then multiplied by a factor of 64 pixels.

It goes on to say that the "viewing angle" is such that the resulting view depicts the triangles as half as high as they are long.

So, I will create a png with grid size of 32 pixels and run my sides at 45 degrees with bases 64 pixels in length. This should give me the result I desire which is the ability to plot a hexagon the size of the plot of land on which the immovable (building) will sit.

Now the question is how are the roads plotted in reference to this triangular map grid?

Does anyone see any holes in this logic?


I see little people.

Top Quote
chuckw
Avatar
Topic Opener
Joined: 2010-03-15, 15:23
Posts: 945
Ranking
One Elder of Players
Location: New York - USA
Posted at: 2010-12-31, 22:53

Here is the result, to scale, of the approach I outlined above:
map gauge
The yellow point represents the hotspot of the construction site. The red hexagon represents the path on which the closest roads could be built for small and medium buildings. The green line indicates the closest roads for a large building.

This seems to be confirmed when I overlay a screen capture from the game.


I see little people.

Top Quote