Fixed AI bugs, added basic level for AI