Repository reorganisation
Unified kotlin and java into just src/main Unified the rs09 and core packages Took all content out of the core package, and placed it into the new content package Reorganised all source code relating to content to be easier to find and explore
This commit is contained in:
@@ -0,0 +1,61 @@
|
||||
package content.global.skill.summoning.familiar;
|
||||
|
||||
import core.plugin.Initializable;
|
||||
import core.game.dialogue.DialogueInterpreter;
|
||||
import core.game.dialogue.DialoguePlugin;
|
||||
import core.game.node.entity.player.Player;
|
||||
|
||||
/**
|
||||
* Handles the remote viewing dialogue.
|
||||
* @author Vexia
|
||||
*/
|
||||
@Initializable
|
||||
public final class RemoteViewDialogue extends DialoguePlugin {
|
||||
|
||||
/**
|
||||
* The familiar instance.
|
||||
*/
|
||||
private Familiar familiar;
|
||||
|
||||
/**
|
||||
* Constructs a new {@code RemoteViewDialogue} {@code Object}.
|
||||
*/
|
||||
public RemoteViewDialogue() {
|
||||
/**
|
||||
* empty.
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a new {@code RemoteViewDialogue} {@code Object}.
|
||||
* @param player the player.
|
||||
*/
|
||||
public RemoteViewDialogue(final Player player) {
|
||||
super(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DialoguePlugin newInstance(Player player) {
|
||||
return new RemoteViewDialogue(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean open(Object... args) {
|
||||
familiar = (Familiar) args[0];
|
||||
options("North", "East", "South", "West", "Straight up");
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean handle(int interfaceId, int buttonId) {
|
||||
end();
|
||||
RemoteViewer.create(player, familiar, familiar.getViewAnimation(), RemoteViewer.ViewType.values()[-1 + buttonId]).startViewing();
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getIds() {
|
||||
return new int[] { DialogueInterpreter.getDialogueKey(RemoteViewer.DIALOGUE_NAME) };
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user