Added RayCasting to AI Logic

I also added some small improvements to the ai, but they still don't use
the path yet. I'll keep working on it.