RuneHive-Tarnish
Neural OSRS Enhancement Framework
Loading...
Searching...
No Matches
SeersClimbInteraction.java
1package com.osroyale.content.skill.impl.agility.obstacle.impl;
2
3import com.osroyale.content.skill.impl.agility.obstacle.ObstacleInteraction;
4import com.osroyale.game.Animation;
5import com.osroyale.game.task.Task;
6import com.osroyale.game.world.World;
7import com.osroyale.game.world.entity.mob.player.Player;
8import com.osroyale.game.world.position.Position;
9
10public interface SeersClimbInteraction extends ObstacleInteraction {
11
12 @Override
13 default void start(Player player) {
14 }
15
16 @Override
17 default void onExecution(Player player, Position start, Position end) {
18 player.animate(new Animation(getAnimation()));
19 World.schedule(new Task(1) {
20 int count = 0;
21
22 @Override
23 public void execute() {
24 if (count == 0) {
25 player.move(new Position(player.getX(), player.getY(), player.getHeight() + 1));
26 player.animate(new Animation(1118));
27 } else if (count == 2) {
28 player.move(end);
29 player.animate(new Animation(65535));
30 this.cancel();
31 }
32 count++;
33 }
34 });
35 }
36
37 @Override
38 default void onCancellation(Player player) {
39 }
40}