following this tutorial: http://jspro.com/series/battle-on-the-high-seas/