Esempio n. 1
0
 /**
  * Move the map origin to a new location
  *
  * @param location
  */
 public void setLocation(final Location location) {
   // origin.setSC(location.scX, location.scY, 0);
   origin.set(location);
   ani.stop();
   final Avatar avatar = World.getAvatar();
   if (avatar != null) {
     avatar.animationFinished(false);
   }
   elevation = World.getMap().getElevationAt(origin);
   dX = 0;
   dY = 0;
   dL = -elevation;
   Camera.getInstance().markEverythingDirty();
 }
Esempio n. 2
0
 /**
  * Fix avatar's position in the middle of the screen and Z-Order
  *
  * @param av
  */
 public void glueAvatarToOrigin(final Avatar av) {
   av.setScreenPos(
       origin.getDcX() - dX, (origin.getDcY() - dY) + dL, origin.getDcZ(), Layers.CHARS);
 }