Update AI.js

ARGH I DON'T KNOW WHERE I BROKE IT, BUT I DID