- moved attack related functions gui.js functions into main.js