 moveUnit = (source, dest, unit) ->
   tile = getTile(dest)
   tile.html("<span class='unit-icon team-#{unit.team}-unit'></span>")
-  getTile(source).html("")
+  tile.data("unitId", unit.id)
+  getTile(source).html("").removeData("unitId")
   currentUnit().location = dest
 
 $("#play").click ->

    window.iid = window.setInterval(nextTick, window.replaySpeed)
  false



    $("#{id} .info-hp").html("")
    $("#{id} .other-info").html("")

highlightPath = (path) ->
  for qr in path
    $("#tile-#{qr[0]}-#{qr[1]}").addClass("path")
