Fixed AI System issues

AI system works inside main core now