Add a missing undefined check in the attack code
Fix a typo in tower construction