Fixed error where attacking didn't work. Added basic logging.