Examples of oppositeDirection()


Examples of games.stendhal.common.Direction.oppositeDirection()

      direction = directions.get(size - 1);

      // as an effect of the poisoning, the player's controls
      // are switched to make it difficult to navigate.
      if (isPoisoned()) {
        direction = direction.oppositeDirection();
      }

      setDirection(direction);
      setSpeed(getBaseSpeed());
    } else if (stopOnNone) {
View Full Code Here

Examples of games.stendhal.common.Direction.oppositeDirection()

      if (!zone.collides(rpEntity, x, y)) {
        move(player, rpEntity, x, y);
        // Stop players running toward to make trapping harder. Don't
        // stop anyone just following a path (again to make annoying
        // others harder)
        if (dir.oppositeDirection() == rpEntity.getDirection()
            && !rpEntity.hasPath()) {
          rpEntity.stop();
        }
      }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.