Hi,
I am thinking of making a simple strategical RISK like game with MMF2. The approach I am thinking of taking is to generate a 2D map and place irregular hit sections over it...
But how do I represent an irregular hit section?
Hi,
I am thinking of making a simple strategical RISK like game with MMF2. The approach I am thinking of taking is to generate a 2D map and place irregular hit sections over it...
But how do I represent an irregular hit section?

Are these sections going to be different all the time?
No; the hit sections are set according to the outline of each territory on the map (which is fixed)
why don´t you use Actives?
I suppose I could. I could slice up each territory into its own active object, or have the outline of each territory as an active object.Originally Posted by templer
Alternatively, I could store all the polygonal points in an array or some sort of data structure and check for a hit. The only problem is what sort of tool I could use to generate all those points.


it depends on how many you will have. If you want user generated maps, or really really big maps, you'd want to story the collision mask in an array of some sort and load it somehow to check for points. However, this is incredibly complicated when applied to irregular surfaces. Elsewise you could store the collision mask on a grid of sorts, having points defined by what square they lie on predetermined, and finding the closest one a mouse click lies near. However, with a sparse spacing, you would have inaccurate clicks, and with dense spacing, the array could potentially be very very large (storing the ownership of every single pixel on screen would be tantamount to a BMP image of that size, potentially hundreds of megabytes for a large map).
So yeah, use active objects and call it a day.
That would definitely take a while for the artist to get the art ready...but I suppose I could whip up dummy hit-areas by using the magic wand in Photoshop.Originally Posted by Pixelthief
Hopefully there is a way to define polygonal hit section soon (I have checked various extensions, but no luck)
If all of the areas are different colors, you could check pixel color.Originally Posted by CKX


O_o thats a good idea
You don't need an artist for that... if the problem is that your map is all one piece, use *invisible* actives for collision detection. They don't have to be 100% pixel-accurate, just close polygon approximations. The user won't care if 2 of the 1000 pixels in Western Australia aren't properly mapped.