Remove filthy void knight purchase option

This commit is contained in:
ceikry
2021-06-25 17:33:38 -05:00
parent 2b1450d06a
commit 506608329b
2 changed files with 17 additions and 51 deletions
@@ -61,8 +61,7 @@ public final class VoidKnightDialogue extends DialoguePlugin {
public boolean handle(int interfaceId, int buttonId) { public boolean handle(int interfaceId, int buttonId) {
switch (stage) { switch (stage) {
case 0: case 0:
options("Who are you?", "What is this place?", options("Who are you?", "What is this place?", "I'm fine thanks.");
"Ask about Penance gear.", "I'm fine thanks.");
stage = 1; stage = 1;
break; break;
case 1: case 1:
@@ -76,10 +75,6 @@ public final class VoidKnightDialogue extends DialoguePlugin {
stage = 20; stage = 20;
break; break;
case 3: case 3:
player("I'd like to see your available Penance gear.");
stage = 40;
break;
case 4:
player("I'm fine thanks."); player("I'm fine thanks.");
stage = 30; stage = 30;
break; break;
@@ -242,51 +237,6 @@ public final class VoidKnightDialogue extends DialoguePlugin {
case 30: case 30:
end(); end();
break; break;
case 40:
npc("How did you know we were supplying that kind of stuff?",
"*sigh* Well, I suppose I can help you out.",
"Here's what I have in stock.");
stage = 41;
break;
case 41:
interpreter.sendOptions("Select an Option", "Fighter Torso",
"Fighter Hat", "Ranger Hat", "Runner Hat", "Healer Hat");
stage = 42;
break;
case 42:
switch (buttonId) {
case 1:
npc("You've taken an interest in the Fighter Torso I have",
"in stock. That'll cost one hundred and fifty points.");
reward = new Item(10551);
stage = 43;
break;
case 2:
npc("You've taken an interest in the Fighter Hat I have",
"in stock. That'll cost one hundred and fifty points.");
reward = new Item(10548);
stage = 43;
break;
case 3:
npc("You've taken an interest in the Ranger Hat I have",
"in stock. That'll cost one hundred and fifty points.");
reward = new Item(10550);
stage = 43;
break;
case 4:
npc("You've taken an interest in the Runner Hat I have",
"in stock. That'll cost one hundred and fifty points.");
reward = new Item(10549);
stage = 43;
break;
case 5:
npc("You've taken an interest in the Healer Hat I have",
"in stock. That'll cost one hundred and fifty points.");
reward = new Item(10547);
stage = 43;
break;
}
break;
case 43: case 43:
if (player.getSavedData().getActivityData().getPestPoints() < 150) { if (player.getSavedData().getActivityData().getPestPoints() < 150) {
player("I don't have that many points at the moment."); player("I don't have that many points at the moment.");
+16
View File
@@ -944,4 +944,20 @@ object ContentAPI {
player.dialogueInterpreter.sendInput(!numeric, prompt) player.dialogueInterpreter.sendInput(!numeric, prompt)
player.setAttribute("runscript",handler) //Handled in RunScriptPacketHandler player.setAttribute("runscript",handler) //Handled in RunScriptPacketHandler
} }
/**
* Forces an NPC to "flee" from a player or other entity
* @param entity the entity to make flee
* @param from the entity to flee from
*/
@JvmStatic
fun flee(entity: Entity, from: Entity){
lock(entity, 5)
face(entity, from, 5)
val diffX = entity.location.x - from.location.x
val diffY = entity.location.y - from.location.y
forceWalk(entity, entity.location.transform(diffX,diffY,0), "DUMB")
}
} }