Hey, Dcrew here!
Just wanted to show off a creation here. (PM me if you wonder how it's done)
<img src="http://screensnapr.com/e/kckaAB.png" border="0">
The line is always between the Player and Enemy (can have as many enemies as you want) and set's the line's width to the distance between the Player and Enemy and set's the angle towards the Player and it's position at the Enemy.
When the Line touches obstacles or walls or (anything you want really) it turns Red. thus meaning it cannot see you! But when it's green it can see you, thus making it aim at you and see-ing you!
I think this is a really good idea for enemy AI in games and will go great with Pathfinding :D
Click here to Download the Source file <font color="red">(Main)</font>
Click here to Download the Source file <font color="blue">(Mirror)</font>