Implemented pickpocketing for NPCs in Rellekka
Added dialogue for shopkeeper Kofi and shop assistant Changed examine text of Kofi and added shop assistant Rewrote Karamja man dialogue to Kotlin Rewrote Monkey dialogue to Kotlin Rewrote Zambo dialogue to Kotlin
This commit is contained in:
@@ -135,7 +135,7 @@ enum class Pickpockets(val ids: IntArray, val requiredLevel: Int, val low: Doubl
|
||||
GUARD(intArrayOf(9, 32, 206, 296, 297, 298, 299, 344, 345, 346, 368, 678, 812, 9, 32, 296, 297, 298, 299, 2699, 2700, 2701, 2702, 2703, 3228, 3229, 3230, 3231, 3232, 3233, 3241, 3407, 3408, 4307, 4308, 4309, 4310, 4311, 5919, 5920), 40, 50.0, 240.0, 46.5, 2,2,5, WeightBasedTable.create(
|
||||
WeightedItem(Items.COINS_995,30,30,1.0,true)
|
||||
)),
|
||||
FREMENNIK_CITIZEN(intArrayOf(2462), 45, 65.0, 240.0, 65.0, 2, 2, 5, WeightBasedTable.create(
|
||||
FREMENNIK_CITIZEN(intArrayOf(1305, 1306, 1308, 1309, 1310, 1311, 1312, 1313, 1314, 2462), 45, 65.0, 240.0, 65.0, 2, 2, 5, WeightBasedTable.create(
|
||||
WeightedItem(Items.COINS_995,40,40,1.0,true)
|
||||
)),
|
||||
BEARDED_BANDIT(intArrayOf(1880, 1881, 6174), 45, 50.0, 240.0, 65.0, 5,5,5, WeightBasedTable.create(
|
||||
|
||||
@@ -1,69 +0,0 @@
|
||||
package content.region.karamja.dialogue;
|
||||
|
||||
import core.game.dialogue.DialoguePlugin;
|
||||
import core.game.dialogue.FacialExpression;
|
||||
import core.game.node.entity.npc.NPC;
|
||||
import core.plugin.Initializable;
|
||||
import core.game.node.entity.player.Player;
|
||||
|
||||
/**
|
||||
* Represents the karamja man dialogue plugin.
|
||||
* @author 'Vexia
|
||||
* @version 1.0
|
||||
*/
|
||||
@Initializable
|
||||
public final class KaramajaManDialogue extends DialoguePlugin {
|
||||
|
||||
/**
|
||||
* Constructs a new {@code KaramajaManDialogue} {@code Object}.
|
||||
*/
|
||||
public KaramajaManDialogue() {
|
||||
/**
|
||||
* empty.
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a new {@code KaramajaManDialogue} {@code Object}.
|
||||
* @param player the player.
|
||||
*/
|
||||
public KaramajaManDialogue(Player player) {
|
||||
super(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DialoguePlugin newInstance(Player player) {
|
||||
return new KaramajaManDialogue(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean open(Object... args) {
|
||||
npc = (NPC) args[0];
|
||||
interpreter.sendDialogues(player, FacialExpression.HAPPY, "Hello, how's it going?");
|
||||
stage = 0;
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean handle(int interfaceId, int buttonId) {
|
||||
switch (stage) {
|
||||
case 0:
|
||||
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Not too bad, but I'm a little worried about the increase", "of goblins these days.");
|
||||
stage = 1;
|
||||
break;
|
||||
case 1:
|
||||
interpreter.sendDialogues(player, FacialExpression.HAPPY, "Don't worry, I'll kill them.");
|
||||
stage = 2;
|
||||
break;
|
||||
case 2:
|
||||
end();
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getIds() {
|
||||
return new int[] { 3915 };
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
package content.region.karamja.dialogue
|
||||
|
||||
import core.game.dialogue.DialoguePlugin
|
||||
import core.game.dialogue.FacialExpression
|
||||
import core.game.node.entity.npc.NPC
|
||||
import core.game.node.entity.player.Player
|
||||
import core.plugin.Initializable
|
||||
import core.tools.END_DIALOGUE
|
||||
import core.tools.START_DIALOGUE
|
||||
import org.rs09.consts.NPCs
|
||||
|
||||
@Initializable
|
||||
class KaramjaManDialogue(player: Player? = null) : DialoguePlugin(player) {
|
||||
|
||||
override fun newInstance(player: Player?): DialoguePlugin {
|
||||
return KaramjaManDialogue(player)
|
||||
}
|
||||
|
||||
|
||||
override fun open(vararg args: Any?): Boolean {
|
||||
npc = args[0] as NPC
|
||||
playerl(
|
||||
FacialExpression.FRIENDLY, "Hello, how's it going?"
|
||||
).also { stage = START_DIALOGUE }
|
||||
return true
|
||||
}
|
||||
|
||||
|
||||
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
|
||||
when (stage) {
|
||||
0 -> npcl(
|
||||
FacialExpression.HALF_GUILTY,
|
||||
"Not too bad, but I'm a little worried about the increase of goblins these days."
|
||||
).also { stage++ }
|
||||
|
||||
1 -> playerl(
|
||||
FacialExpression.HAPPY, "Don't worry, I'll kill them."
|
||||
).also { stage = END_DIALOGUE }
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun getIds(): IntArray {
|
||||
return intArrayOf(NPCs.MAN_3915)
|
||||
}
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
package content.region.karamja.dialogue;
|
||||
|
||||
import core.game.dialogue.DialoguePlugin;
|
||||
import core.game.dialogue.FacialExpression;
|
||||
import core.plugin.Initializable;
|
||||
import core.game.node.entity.player.Player;
|
||||
|
||||
/**
|
||||
* The dialogue for the desert monkey.
|
||||
* @author 'Vexia
|
||||
*/
|
||||
@Initializable
|
||||
public final class MonkeyDialogue extends DialoguePlugin {
|
||||
|
||||
/**
|
||||
* Constructs a new {@code MonkeyDialogue} {@code Object}.
|
||||
*/
|
||||
public MonkeyDialogue() {
|
||||
/**
|
||||
* empty.
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a new {@code MonkeyDialogue} {@code Object}.
|
||||
* @param player the player.
|
||||
*/
|
||||
public MonkeyDialogue(final Player player) {
|
||||
super(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DialoguePlugin newInstance(Player player) {
|
||||
return new MonkeyDialogue(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean open(Object... args) {
|
||||
player("Hey little man, how's it goin'?");
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean handle(int interfaceId, int buttonId) {
|
||||
switch (stage) {
|
||||
case 0:
|
||||
npc("Ukkuk oook! Eeek aka, ahh aka gonk.");
|
||||
stage++;
|
||||
break;
|
||||
case 1:
|
||||
player(FacialExpression.HALF_GUILTY,"Yeah.");
|
||||
stage = 5;
|
||||
break;
|
||||
case 5:
|
||||
end();
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@Override
|
||||
public int[] getIds() {
|
||||
return new int[] { 2301 };
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
package content.region.karamja.dialogue
|
||||
|
||||
import core.game.dialogue.DialoguePlugin
|
||||
import core.game.dialogue.FacialExpression
|
||||
import core.game.node.entity.npc.NPC
|
||||
import core.game.node.entity.player.Player
|
||||
import core.plugin.Initializable
|
||||
import core.tools.END_DIALOGUE
|
||||
import core.tools.START_DIALOGUE
|
||||
import org.rs09.consts.NPCs
|
||||
|
||||
@Initializable
|
||||
class MonkeyDialogue(player: Player? = null) : DialoguePlugin(player) {
|
||||
|
||||
override fun newInstance(player: Player?): DialoguePlugin {
|
||||
return MonkeyDialogue(player)
|
||||
}
|
||||
|
||||
override fun open(vararg args: Any?): Boolean {
|
||||
npc = args[0] as NPC
|
||||
playerl(
|
||||
FacialExpression.ASKING, "Hey little man, how's it goin'?"
|
||||
).also { stage = START_DIALOGUE }
|
||||
return true
|
||||
}
|
||||
|
||||
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
|
||||
when (stage) {
|
||||
0 -> npc("Ukkuk oook! Eeek aka, ahh aka gonk.").also { stage++ }
|
||||
|
||||
1 -> playerl(
|
||||
FacialExpression.HALF_GUILTY, "Yeah."
|
||||
).also { stage = END_DIALOGUE }
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun getIds(): IntArray {
|
||||
return intArrayOf(NPCs.MONKEY_2301)
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,49 @@
|
||||
package content.region.karamja.dialogue
|
||||
|
||||
import core.api.openNpcShop
|
||||
import core.game.dialogue.DialoguePlugin
|
||||
import core.game.dialogue.FacialExpression
|
||||
import core.game.node.entity.npc.NPC
|
||||
import core.game.node.entity.player.Player
|
||||
import core.plugin.Initializable
|
||||
import core.tools.END_DIALOGUE
|
||||
import core.tools.START_DIALOGUE
|
||||
import org.rs09.consts.NPCs
|
||||
|
||||
@Initializable
|
||||
class MusaPointShopDialogue(player: Player? = null) : DialoguePlugin(player) {
|
||||
|
||||
override fun newInstance(player: Player?): DialoguePlugin {
|
||||
return MusaPointShopDialogue(player)
|
||||
}
|
||||
|
||||
override fun open(vararg args: Any?): Boolean {
|
||||
npc = args[0] as NPC
|
||||
npcl(
|
||||
FacialExpression.FRIENDLY, "Can I help you at all?"
|
||||
).also { stage = START_DIALOGUE }
|
||||
return true
|
||||
}
|
||||
|
||||
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
|
||||
when (stage) {
|
||||
0 -> options("Yes please. What are you selling?", "No thanks.").also { stage++ }
|
||||
|
||||
1 -> when (buttonId) {
|
||||
1 -> {
|
||||
openNpcShop(player, NPCs.SHOPKEEPER_532)
|
||||
end()
|
||||
}
|
||||
|
||||
2 -> playerl(
|
||||
FacialExpression.FRIENDLY, "No thanks."
|
||||
).also { stage = END_DIALOGUE }
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun getIds(): IntArray {
|
||||
return intArrayOf(NPCs.SHOPKEEPER_532, NPCs.SHOP_ASSISTANT_533)
|
||||
}
|
||||
}
|
||||
@@ -1,77 +0,0 @@
|
||||
package content.region.karamja.dialogue;
|
||||
|
||||
import core.game.dialogue.DialoguePlugin;
|
||||
import core.game.dialogue.FacialExpression;
|
||||
import core.game.node.entity.npc.NPC;
|
||||
import core.plugin.Initializable;
|
||||
import core.game.node.entity.player.Player;
|
||||
|
||||
/**
|
||||
* Represents the dialogue plugin used for zambo.
|
||||
* @author 'Vexia
|
||||
* @version 1.0
|
||||
*/
|
||||
@Initializable
|
||||
public final class ZamboDialogue extends DialoguePlugin {
|
||||
|
||||
/**
|
||||
* Constructs a new {@code ZamboDialogue} {@code Object}.
|
||||
*/
|
||||
public ZamboDialogue() {
|
||||
/**
|
||||
* empty.
|
||||
*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a new {@code ZamboDialogue} {@code Object}.
|
||||
* @param player the player.
|
||||
*/
|
||||
public ZamboDialogue(Player player) {
|
||||
super(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DialoguePlugin newInstance(Player player) {
|
||||
return new ZamboDialogue(player);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean open(Object... args) {
|
||||
npc = (NPC) args[0];
|
||||
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Hey, are you wanting to try some of my fine wines", "and spririts? All brewed locally on Karamja island.");
|
||||
stage = 0;
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean handle(int interfaceId, int buttonId) {
|
||||
switch (stage) {
|
||||
case 0:
|
||||
interpreter.sendOptions("Select an Option", "Yes, please.", "No, thank you");
|
||||
stage = 1;
|
||||
break;
|
||||
case 1:
|
||||
switch (buttonId) {
|
||||
case 1:
|
||||
end();
|
||||
npc.openShop(player);
|
||||
break;
|
||||
case 2:
|
||||
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "No, thank you.");
|
||||
stage = 20;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case 20:
|
||||
end();
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int[] getIds() {
|
||||
return new int[] { 568 };
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,54 @@
|
||||
package content.region.karamja.dialogue
|
||||
|
||||
import core.api.openNpcShop
|
||||
import core.game.dialogue.DialoguePlugin
|
||||
import core.game.dialogue.FacialExpression
|
||||
import core.game.node.entity.npc.NPC
|
||||
import core.game.node.entity.player.Player
|
||||
import core.plugin.Initializable
|
||||
import core.tools.END_DIALOGUE
|
||||
import core.tools.START_DIALOGUE
|
||||
import org.rs09.consts.NPCs
|
||||
|
||||
@Initializable
|
||||
class ZamboDialogue(player: Player? = null) : DialoguePlugin(player) {
|
||||
|
||||
override fun newInstance(player: Player?): DialoguePlugin {
|
||||
return ZamboDialogue(player)
|
||||
}
|
||||
|
||||
override fun open(vararg args: Any?): Boolean {
|
||||
npc = args[0] as NPC
|
||||
npcl(
|
||||
FacialExpression.ASKING,
|
||||
" Hey, are you wanting to try some of my fine wines and spirits? All brewed locally on Karamja."
|
||||
).also { stage = START_DIALOGUE }
|
||||
return true
|
||||
}
|
||||
|
||||
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
|
||||
when (stage) {
|
||||
0 -> options("Yes, please.", "No, thank you.").also { stage++ }
|
||||
|
||||
1 -> when (buttonId) {
|
||||
1 -> playerl(
|
||||
FacialExpression.FRIENDLY, "Yes, please."
|
||||
).also { stage++ }
|
||||
|
||||
2 -> playerl(
|
||||
FacialExpression.FRIENDLY, "No, thank you."
|
||||
).also { stage = END_DIALOGUE }
|
||||
}
|
||||
|
||||
2 -> {
|
||||
openNpcShop(player, NPCs.ZAMBO_568)
|
||||
end()
|
||||
}
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
override fun getIds(): IntArray {
|
||||
return intArrayOf(NPCs.ZAMBO_568)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user