Thursday, July 20, 2006

africa map game progress 2

I've written a small prototype to solve the name pop up problem for the smaller countries. Still not finished but here is a draft. It's probably best to put all the names onto the countries programmatically. This is an essential feature for the small countries. I've updated the country array 2D (countryObjectName, countryName) to help achieve this. Have made the mouse pointer change into a hand when it passes over a country. I have just one small country on the prototype (Gambia)

Further challenges / problems:
  • Mouse pointer does not change to hand if you move from one country to another touching or overlapping country
  • For the small countries I need two versions of the name, one for the final map (the position of the name depends on where the country fits into the final map) and another for when the user is moving the country (pops up above the country)
  • the country borders on verson 6b are messy. I plan to make all the countries again using the template showing borders as a clean starting point.
WHAT I'VE LEARNT FROM THIS

I had problems achieving some of the above.

Setting the Depth of the country name so that it appears in front of the country. You can set the Depth of Objects but I can't find a way to set the Depth of programmed text independent to the Object Depth on which the text is programmed. In the end I had to program the drawn text on a new object which is in front of all the other objects.

I felt rusty in my programming skills - one of my goals in the africagame project is to overcome this rust by programming more regulary and setting myself some real challenges. It took me a while before I decided to solve the small country name problem by creating a prototype to just focus on this. Things moved a lot faster once I had setup the protoype.

The african border template looks really good (clean). I now realise that I can make better versions of individual countries by starting from this template, rather than cutting out from the original map. So I've wasted some time here.

I suppose that some time wasting is inevitable due to lack of experience but it does pay to think ahead and get an overview of what is required and the best way to do it.

africaBorderTemplate

No comments: