Wednesday, 19 August 2009

Levelling up

Been working on the level implementation. Was originally going to work out paths dynamically using some mad pathfinding algorithm. But then I thought, it's tile based, let's just use tiles for AI paths. So I did.

You can have up to four different paths - as described on the wiki here: http://code.google.com/p/gntowerdefence/wiki/LevelDesign

There's no code to parse these AI paths yet (there was no original requirement for them). I'm thinking either you have a 'Directions[aiPath].Direction' property on a Tile object which the monsters query, or you have a completely separate collection of AiPath objects... open to suggestions :)

Here's a screenshot - blue: start; purple: goal; red: mountpoint; green: path; arrows: aipaths

No comments:

Post a Comment