Athena, you do have the right idea in mind but for this game I do not need it to be anywhere near that complex (in the future however I would like to try my hand at building games that involve more complex arrangements like this).

This particular enemy only really needs to a follow an absolute pre-defined path and not stray from it at all (or perhaps have slight variations if it hits a solid object, although I'm not sure what to do on that one).

Either that or a mix of that and going after the player if he is in a certain range (defined in pixels) and yeah line of sight for enemies would just be awesome to make and play around with it but that much isn't necessary for how it is for now.

This game isn't something I planned heavily from the beginning, as usual it just a very small part of an idea that popped into my head, I started it, and just built and changed things from there, it could end up as an MMORPG for all I know (although I highly doubt it lol).

The most difficult factor for me, or the problem of starting to build the AI is how on earth I should handle it.

This enemy will be a sprite as apart of TSpriteEngine (for collision with the player and it's DoMove procedure). But what do I need to do in order to have him walk one way a certain distance and then come back the other way and repeat.

I mean I could certainly think a few long winded and messy ways of using a ton of booleans and variables to count time and just automatically swap the enemy around but I feel that there is probably a better way of handling this.

Any thoughts on that?

To explain the game a little more, well if you check my BLOCKBASH thread in the uhh "your projects" section I think and you will see basically the kind of game it is, although it has changed considerably since (size, graphics and some inner workings), but the idea and how it works is still the same.