Exemplo n.º 1
0
 /**
  * setMoved is called with an argument of true each time the piece is moved. The argument is false
  * when the unit is marked as not moved.
  */
 public void setMoved(boolean justMoved) {
   if (justMoved) {
     recordCurrentPosition();
     final Map map = getMap();
     startMapId = map != null ? map.getId() : null;
   } else {
     clearTrail();
     myBoundingBox = null;
   }
   redraw();
 }
Exemplo n.º 2
0
 public void redraw() {
   final Map m = getMap();
   if (m != null) {
     m.repaint(getMyBoundingBox());
   }
 }