Package org.rsbot.script.wrappers

Examples of org.rsbot.script.wrappers.RSObject.interact()


    }
    if (getScore() >= 10) {
      final RSObject exit = objects.getNearest(15010);
      if (exit != null) {
        if (calc.tileOnScreen(exit.getLocation())) {
          if (exit.interact("Exit")) {
            return random(4000, 4200);
          }
        } else {
          camera.setCompass('s');
          walking.walkTileOnScreen(exit.getLocation());
View Full Code Here


    if (pillar != null) {
      if (calc.distanceTo(pillar) > 2 && !pillar.isOnScreen()) {
        walking.walkTileOnScreen(pillar.getLocation());
        return random(500, 600);
      }
      if (pillar.interact("Tag")) {
        final int before = getScore();
        for (int i = 0; i < 50; i++) {
          if (getScore() > before) {
            return random(50, 100);
          }
View Full Code Here

    }

    if (getMyPlayer().getLocation().equals(new RSTile(2911, 4576))) {
      if (getMyPlayer().getAnimation() == -1) {
        final RSObject ob = objects.getNearest(3634);
        ob.interact("Touch");
        return random(5000, 6000);
      }
    }
    if (usePath.equals("None")) {
      getPath();
View Full Code Here

    if (readyToLeave) {
      final RSObject portal = objects.getNearest(PORTAL_ID);
      if (portal != null) {
        final RSTile portalLocation = portal.getLocation();
        if (portal.isOnScreen()) {
          portal.interact("Enter");
          return random(3000, 4000);
        } else {
          walking.walkTileMM(portalLocation.randomize(2, 2));
          return random(1500, 2000);
        }
View Full Code Here

      if (doorDir != 'a' && !getMyPlayer().isMoving()) {
        if (camera.getAngle() - turnCameraTo() < 30 || camera.getAngle() - turnCameraTo() > 30) {
          camera.setAngle(turnCameraTo());
        }
        final RSObject obj = objects.getTopAt(walkToTile, Objects.TYPE_BOUNDARY);
        if (obj != null && obj.interact("Open") || atDoor(walkToTile, doorDir)) {
          return random(2750, 3250);
        }
      }
    }
View Full Code Here

      return random(200, 650);
    } else if (talkDone) {//We have finished talking to reaper
      final RSObject portal = objects.getNearest(45803);//get portal
      camera.turnTo(portal);//turn
      if (calc.distanceTo(portal) <= 4) {
        portal.interact("Enter");//Leave
        return random(1200, 1400);
      } else {
        walking.walkTileMM(portal.getLocation()); //walk portal
        return random(1000, 1300);
      }
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.