       height: 48
   numShips: (shipKey) ->
     return d3.round(@props.damage / @ships[shipKey].ehp, 1)
+  getInitialState: ->
+    return {
+      ship: null
+    }
+  componentDidMount: ->
+    shipToUse = null
+    numShips = 0
+    # find a good candidate ship to show, first ship that results in less than 100
+    # stamps
+    for name, ship of @ships
+      shipToUse = name
+      numShips = @numShips(name)
+      if numShips < 100
+        break
+    @setState {ship: shipToUse}
   render: ->
     if @props.damage == 0
       return null
     else
-      shipToUse = null
-      numShips = 0
-      # find a good candidate ship to show, first ship that results in less than 100
-      # stamps
-      for name, ship of @ships
-        shipToUse = name
-        numShips = @numShips(name)
-        if numShips < 100
-          break
+      if not @state.ship
+        return null
+
+      shipToUse = @state.ship
 
       ship = @ships[shipToUse]
       numShips = @numShips(shipToUse)

        stamps.push dom.div(divOpts, dom.img(imgOpts))

      return dom.div {className: 'row'},
        dom.h4 {className: 'pull-left'},
          dom.em null,
            "You dealt enough damage to kill #{numShips} "

      years = numFmt(d3.round(travelSeconds / 60 / 60 / 24/ 365, 1))
      distanceText = "#{vehicle.name} would take #{years} years
                      to cover your total distance."
      return dom.h4 {className: 'pull-right'},
        dom.em(null,distanceText)
    else
      return null
)
