AI server: replaced a manual range check (doesn't even use their standard logic...)