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:
Ceikry
2023-01-26 13:59:28 +00:00
committed by Ryan
parent e4b799c44a
commit a100affda2
3156 changed files with 24205 additions and 30585 deletions
@@ -0,0 +1,55 @@
package content.global.dialogue
import core.api.dumpBeastOfBurden
import core.api.dumpContainer
import core.api.sendMessage
import core.game.dialogue.DialogueFile
import core.tools.START_DIALOGUE
/**
* Represents the dialogue shown when the user presses
* "Deposit Beast of Burden" button on the Bank Interface.
*
* @author vddCore
*/
class BankDepositDialogue : DialogueFile() {
override fun handle(componentID: Int, buttonID: Int) {
when (stage) {
START_DIALOGUE -> options(
"Deposit Inventory",
"Deposit Worn Equipment",
"Deposit Beast of Burden",
"Cancel"
).also { stage++ }
1 -> when (buttonID) {
1 -> player?.let {
end()
if (it.inventory.isEmpty) {
sendMessage(it, "You have nothing in your inventory that you can deposit.")
} else {
dumpContainer(it, it.inventory)
}
}
2 -> player?.let {
end()
if (it.equipment.isEmpty) {
sendMessage(it, "You have no equipment that you can deposit.")
} else {
dumpContainer(it, it.equipment)
}
}
3 -> player?.let {
end()
dumpBeastOfBurden(it)
}
4 -> end()
}
}
}
}
@@ -0,0 +1,57 @@
package content.global.dialogue
import core.api.openInterface
import core.api.sendDialogue
import core.api.sendItemDialogue
import core.game.node.item.Item
import org.rs09.consts.Components
import org.rs09.consts.Items
import core.game.dialogue.DialogueFile
import core.tools.START_DIALOGUE
/**
* Represents the dialogue shown when the user presses
* the "?" button on the Bank Interface.
*
* @author vddCore
*/
class BankHelpDialogue : DialogueFile() {
override fun handle(componentID: Int, buttonID: Int) {
when (stage) {
START_DIALOGUE -> options(
"Check Bank Value",
"Banking Assistance",
"Close"
).also { stage++ }
1 -> when (buttonID) {
1 -> player?.let {
end()
val wealth = it.bank.wealth
if (wealth > 0) {
val word = if (wealth != 1) "coins" else "coin"
sendItemDialogue(
it,
Item(Items.COINS_995, wealth),
"<br>Your bank is worth <col=a52929>${wealth}</col> ${word}."
)
} else {
sendDialogue(it, "You have no valuables in your bank.")
}
}
2 -> player?.let {
end()
it.bank.close()
openInterface(it, Components.BANK_V2_HELP_767)
}
3 -> end()
}
}
}
}
@@ -0,0 +1,181 @@
package content.global.dialogue
import core.api.*
import core.game.node.entity.player.Player
import core.game.node.entity.player.link.IronmanMode
import core.plugin.Initializable
import core.game.dialogue.IfTopic
import core.game.dialogue.Topic
import content.global.handlers.npc.BankerNPC
import core.tools.END_DIALOGUE
import core.tools.START_DIALOGUE
@Initializable
class BankerDialogue(player: Player? = null) : core.game.dialogue.DialoguePlugin(player) {
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
when (stage) {
START_DIALOGUE -> when {
hasIronmanRestriction(player, IronmanMode.ULTIMATE) -> {
npcl(
core.game.dialogue.FacialExpression.ANNOYED,
"My apologies, dear ${if (player.isMale) "sir" else "madam"}, " +
"our services are not available for Ultimate ${if (player.isMale) "Ironmen" else "Ironwomen"}"
).also { stage = END_DIALOGUE }
}
else -> {
npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Good day, how may I help you?"
).also {
if (hasAwaitingGrandExchangeCollections(player)) {
stage++
} else {
stage += 2
}
}
}
}
1 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Before we go any further, I should inform you that you " +
"have items ready for collection from the Grand Exchange."
).also { stage++ }
2 -> showTopics(
Topic(core.game.dialogue.FacialExpression.FRIENDLY, "I'd like to access my bank account, please.", 10),
IfTopic(
core.game.dialogue.FacialExpression.FRIENDLY,
"I'd like to switch to my ${getBankAccountName(player, true)} bank account.",
13,
hasActivatedSecondaryBankAccount(player)
),
IfTopic(
core.game.dialogue.FacialExpression.FRIENDLY,
"I'd like to open a secondary bank account.",
20,
!hasActivatedSecondaryBankAccount(player)
),
Topic(core.game.dialogue.FacialExpression.FRIENDLY, "I'd like to check my PIN settings.", 11),
Topic(core.game.dialogue.FacialExpression.FRIENDLY, "I'd like to collect items.", 12),
Topic(core.game.dialogue.FacialExpression.ASKING, "What is this place?", 3),
)
3 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"This is a branch of the Bank of Gielinor. We have branches in many towns."
).also { stage++ }
4 -> playerl(
core.game.dialogue.FacialExpression.ASKING,
"And what do you do?"
).also { stage++ }
5 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"We will look after your items and money for you. " +
"Leave your valuables with us if you want to keep them safe."
).also { stage = END_DIALOGUE }
10 -> {
openBankAccount(player)
end()
}
11 -> {
openBankPinSettings(player)
end()
}
12 -> {
openGrandExchangeCollectionBox(player)
end()
}
13 -> {
toggleBankAccount(player)
npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Your active bank account has been switched. " +
"You can now access your ${getBankAccountName(player)} account."
).also { stage = 2 }
}
20 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Certainly. We offer secondary accounts to all our customers."
).also { stage++ }
21 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"The secondary account comes with a standard fee of 5,000,000 coins. The fee is non-refundable " +
"and account activation is permanent."
).also { stage++ }
22 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"If your inventory does not contain enough money to cover the costs, we will complement " +
"the amount with the money inside your primary bank account."
).also { stage++ }
23 -> npcl(
core.game.dialogue.FacialExpression.ASKING,
"Knowing all this, would you like to proceed with opening your secondary bank account?"
).also { stage++ }
24 -> showTopics(
Topic(core.game.dialogue.FacialExpression.HAPPY, "Yes, I am still interested.", 25),
Topic(core.game.dialogue.FacialExpression.ANNOYED, "Actually, I've changed my mind.", 26)
)
25 -> {
when (activateSecondaryBankAccount(player)) {
SecondaryBankAccountActivationResult.ALREADY_ACTIVE -> {
npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Your bank account was already activated, there is no need to pay twice."
).also { stage = END_DIALOGUE }
}
SecondaryBankAccountActivationResult.INTERNAL_FAILURE -> {
npcl(
core.game.dialogue.FacialExpression.ANNOYED,
"I must apologize, the transaction was not successful. Please check your " +
"primary bank account and your inventory - if there's money missing, please " +
"screenshot your chat box and contact the game developers."
).also { stage = END_DIALOGUE }
}
SecondaryBankAccountActivationResult.NOT_ENOUGH_MONEY -> {
npcl(
core.game.dialogue.FacialExpression.ANNOYED,
"It appears that you do not have the money necessary to cover the costs " +
"associated with opening a secondary bank account. I will be waiting here " +
"until you do."
).also { stage = END_DIALOGUE }
}
SecondaryBankAccountActivationResult.SUCCESS -> {
npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Your secondary bank account has been opened and can be accessed through any " +
"of the Bank of Gielinor's employees. Thank you for choosing our services."
).also { stage = END_DIALOGUE }
}
}
}
26 -> npcl(
core.game.dialogue.FacialExpression.FRIENDLY,
"Very well. Should you decide a secondary bank account is needed, do not hesitate to " +
"contact any of the Bank of Gielinor's stationary employees. We will be happy to help."
).also { stage = END_DIALOGUE }
}
return true
}
override fun getIds(): IntArray = BankerNPC.NPC_IDS
}
@@ -0,0 +1,77 @@
package content.global.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 plugin used for the fur trader.
* @author 'Vexia
* @version 1.0
*/
@Initializable
public final class FurTradePlugin extends DialoguePlugin {
/**
* Constructs a new {@code FurTradePlugin} {@code Object}.
*/
public FurTradePlugin() {
/**
* empty.
*/
}
/**
* Constructs a new {@code FurTradePlugin} {@code Object}.
* @param player the player.
*/
public FurTradePlugin(Player player) {
super(player);
}
@Override
public DialoguePlugin newInstance(Player player) {
return new FurTradePlugin(player);
}
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Would you like to trade in fur?");
stage = 0;
return true;
}
@Override
public boolean handle(int interfaceId, int buttonId) {
switch (stage) {
case 0:
interpreter.sendOptions("Select an Option", "Yes.", "No.");
stage = 1;
break;
case 1:
switch (buttonId) {
case 1:
end();
npc.openShop(player);
break;
case 2:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "No, thanks.");
stage = 20;
break;
}
break;
case 20:
end();
break;
}
return true;
}
@Override
public int[] getIds() {
return new int[] { 573 };
}
}
@@ -0,0 +1,166 @@
package content.global.dialogue
import content.global.skill.farming.FarmerPayOptionDialogue
import content.global.skill.farming.Farmers
import content.global.skill.farming.FarmingPatch
import core.game.node.entity.npc.NPC
import core.game.node.entity.player.Player
import core.game.node.item.Item
import core.plugin.Initializable
import org.rs09.consts.Items
import core.tools.END_DIALOGUE
@Initializable
class GardenerDialoguePlugin(player: Player? = null) : core.game.dialogue.DialoguePlugin(player) {
override fun newInstance(player: Player?): core.game.dialogue.DialoguePlugin {
return GardenerDialoguePlugin(player)
}
override fun open(vararg args: Any?): Boolean {
npc = args[0] as NPC
options("Would you look after my crops for me?","Can you sell me something?")
return true
}
override fun handle(interfaceId: Int, buttonId: Int): Boolean {
when(stage){
0 -> when(buttonId){
1 -> player("Would you look after my crops for me?").also { stage = 10 }
2 -> player("Can you sell me something?").also { stage = 30 }
}
10 -> npc("I might. Which one were you thinking of?").also { stage++ }
11 -> when(npc.id){
Farmers.ELSTAN.id, Farmers.LYRA.id -> options("The north-western allotment.","The south-eastern allotment.").also { stage = 15 }
Farmers.DANTAERA.id, Farmers.KRAGEN.id -> options("The north allotment.","The south allotment.").also { stage = 15 }
else -> player("Uh, that one.").also { stage++ }
}
12 -> npc("Oh, right. My bad.").also { stage++ }
13 -> checkPatch(player,Farmers.forId(npc.id)!!.patches[0])
15 -> when(buttonId){
1 -> checkPatch(player,Farmers.forId(npc.id)!!.patches[0])
2 -> checkPatch(player,Farmers.forId(npc.id)!!.patches[1])
}
30 -> npc("That depends on whether I have it to sell.","What is it that you're looking for?").also { stage++ }
31 -> options("Some plant cure.","A bucket of compost.","A rake.","(See more items)").also { stage = 32 }
32 -> when(buttonId){
1 -> player("Some plant cure.").also { stage = 100 }
2 -> player("A bucket of compost.").also { stage = 200 }
3 -> player("A rake.").also { stage = 300 }
4 -> options("A watering can.","A gardening trowel.","A seed dibber.","(See previous items)").also { stage++ }
}
33 -> when(buttonId){
1 -> player("A watering can.").also { stage = 400 }
2 -> player("A gardening trowel.").also { stage = 500 }
3 -> player("A seed dibber.").also { stage = 600 }
4 -> options("Some plant cure.","A bucket of compost.","A rake.","(See more items)").also { stage = 32 }
}
100 -> npc("Plant cure, eh? I might have some put aside for myself.","Tell you what, I'll sell you some plant cure","for 25 gp if you like.").also { stage++ }
101 -> options("Yes, that sounds like a fair price.","No thanks, I can get that much cheaper.").also { stage++ }
102 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,25))){
player.inventory.add(Item(Items.PLANT_CURE_6036))
} else {
player.sendMessage("You need 25 gp to pay for that.")
}
}
2 -> end()
}
200 -> npc("A bucket of compost, eh? I might have one spare...","tell you what, I'll sell it to you for 35 gp if you like.").also { stage++ }
201 -> options("Yes, that sounds fair.","No thanks, I can get that cheaper.").also { stage++ }
202 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,35))){
player.inventory.add(Item(Items.COMPOST_6032))
} else {
player.sendMessage("You need 35 gp to pay for that.")
}
}
2 -> end()
}
300 -> npc("A rake, eh? I might have one spare...","tell you what, I'll sell it to you for 15 gp if you like.").also { stage++ }
301 -> options("Yes, that sounds fair.","No thanks, I can get that cheaper.").also { stage++ }
302 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,15))){
player.inventory.add(Item(Items.RAKE_5341))
} else {
player.sendMessage("You need 15 gp to pay for that.")
}
}
2 -> end()
}
400 -> npc("A watering can, eh? I might have one spare...","tell you what, I'll sell it to you for 25 gp if you like.").also { stage++ }
401 -> options("Yes, that sounds fair.","No thanks, I can get that cheaper.").also { stage++ }
402 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,25))){
player.inventory.add(Item(Items.WATERING_CAN8_5340))
} else {
player.sendMessage("You need 25 gp to pay for that.")
}
}
2 -> end()
}
500 -> npc("A gardening trowel, eh? I might have one spare...","tell you what, I'll sell it to you for 15 gp if you like.").also { stage++ }
501 -> options("Yes, that sounds fair.","No thanks, I can get that cheaper.").also { stage++ }
502 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,15))){
player.inventory.add(Item(Items.GARDENING_TROWEL_5325))
} else {
player.sendMessage("You need 15 gp to pay for that.")
}
}
2 -> end()
}
600 -> npc("A seed dibber, eh? I might have one spare...","tell you what, I'll sell it to you for 15 gp if you like.").also { stage++ }
601 -> options("Yes, that sounds fair.","No thanks, I can get that cheaper.").also { stage++ }
602 -> when(buttonId){
1 -> {
player("Yes, that sounds like a fair price.").also { stage = END_DIALOGUE }
if(player.inventory.remove(Item(995,15))){
player.inventory.add(Item(Items.SEED_DIBBER_5343))
} else {
player.sendMessage("You need 15 gp to pay for that.")
}
}
2 -> end()
}
}
return true
}
fun checkPatch(player: Player,fPatch: FarmingPatch){
if(fPatch.getPatchFor(player).isWeedy()){
npc("You don't have anything planted in that patch.","Plant something and I might agree to look after it for you.").also { stage = END_DIALOGUE }
} else if(fPatch.getPatchFor(player).isGrown()){
npc("That patch is already fully grown!","I don't know what you want me to do with it!").also { stage = END_DIALOGUE }
} else if(fPatch.getPatchFor(player).protectionPaid) {
npc("Are you alright? You've already", "paid me for that.").also { stage = END_DIALOGUE }
} else {
end()
player.dialogueInterpreter.open(FarmerPayOptionDialogue(fPatch.getPatchFor(player)),npc)
}
}
override fun getIds(): IntArray {
return Farmers.values().map(Farmers::id).toIntArray()
}
}
@@ -0,0 +1,117 @@
package content.global.dialogue;
import core.game.dialogue.DialoguePlugin;
import core.game.dialogue.FacialExpression;
import core.plugin.Initializable;
import org.rs09.consts.Items;
import core.game.node.entity.npc.NPC;
import core.game.node.entity.player.Player;
import core.game.node.entity.player.link.diary.DiaryType;
import core.game.node.item.Item;
import core.tools.RandomFunction;
/**
* Handles the man dialogues.
*
* @author 'Vexia
*/
@Initializable
public class ManDialoguePlugin extends DialoguePlugin {
private static final Item CIDER = new Item(Items.CIDER_5763);
/**
* The NPC ids that use this dialogue plugin.
*/
private static final int[] NPC_IDS = {1, 2, 3, 4, 5, 6, 16, 24, 25, 170, 351, 352, 353, 354, 359, 360, 361, 362, 363, 726, 727, 728, 729, 730, 1086, 2675, 2776, 3224, 3225, 3227, 5923, 5924,};
public ManDialoguePlugin() {
}
public ManDialoguePlugin(Player player) {
super(player);
}
@Override
public DialoguePlugin newInstance(Player player) {
return new ManDialoguePlugin(player);
}
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
if (npc == null)
return false;
if (args.length > 1
&& args[1] instanceof Item
&& ((Item) args[1]).equals(CIDER)
&& player.getInventory().remove(CIDER)) {
// Seers achievement diary
if (!player.getAchievementDiaryManager().getDiary(DiaryType.SEERS_VILLAGE).isComplete(0, 6)) {
if (player.getAttribute("diary:seers:pub-cider", 0) >= 4) {
player.setAttribute("/save:diary:seers:pub-cider", 5);
player.getAchievementDiaryManager().getDiary(DiaryType.SEERS_VILLAGE).updateTask(player, 0, 6, true);
} else {
player.setAttribute("/save:diary:seers:pub-cider", player.getAttribute("diary:seers:pub-cider", 0) + 1);
}
}
npc("Ah, a glass of cider, that's very generous of you. I", "don't mind if I do. Thanks!");
stage = 999;
return true;
}
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Hello, how's it going?");
stage = RandomFunction.random(0, 5);
if (stage == 1) {
stage = 0;
}
return true;
}
@Override
public boolean handle(int interfaceId, int buttonId) {
switch (stage) {
case 0:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "I'm very well thank you.");
stage = 999;
break;
case 999:
end();
break;
case 2:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Who are you?");
stage = 20;
break;
case 3:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "I'm fine, how are you?");
stage = 30;
break;
case 4:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "No, I don't want to buy anything!");
stage = 999;
break;
case 5:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "I think we need a new king. The one we've got isn't", "very good.");
stage = 999;
break;
case 20:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm a bold adventurer.");
stage = 21;
break;
case 21:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Ah, a very noble profession.");
stage = 999;
break;
case 30:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Very well thank you.");
stage = 999;
break;
}
return true;
}
@Override
public int[] getIds() {
return NPC_IDS;
}
}
@@ -0,0 +1,81 @@
package content.global.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;
/**
* Handles the generic shop keeper dialogue.
* @author Vexia
*/
@Initializable
public final class
ShopkeeperDialogue extends DialoguePlugin {
/**
* Constructs a new {@code ShopkeeperDialogue} {@code Object}.
*/
public ShopkeeperDialogue() {
/**
* empty.
*/
}
/**
* Constructs a new {@code ShopkeeperDialogue} {@code Object}.
* @param player the player.
*/
public ShopkeeperDialogue(Player player) {
super(player);
}
@Override
public DialoguePlugin newInstance(Player player) {
return new ShopkeeperDialogue(player);
}
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Can I help you at all?");
stage = 0;
return true;
}
@Override
public boolean handle(int interfaceId, int buttonId) {
switch (stage) {
case 0:
interpreter.sendOptions("Select an Option", "Yes, please. What are you selling?", "No, thanks.");
stage = 1;
break;
case 1:
switch (buttonId) {
case 1:
player("Yes, please. I'd like to see your stock.");
stage = 11;
break;
case 2:
player("No thanks, I must be going now.");
stage = 10;
break;
}
break;
case 10:
end();
break;
case 11:
end();
npc.openShop(player);
break;
}
return true;
}
@Override
public int[] getIds() {
return new int[] { 523, 522, 520, 521, 1699,555 };
}
}
@@ -0,0 +1,236 @@
package content.global.dialogue;
import core.game.dialogue.DialoguePlugin;
import core.game.node.entity.npc.NPC;
import core.game.node.entity.player.Player;
import core.game.node.entity.player.link.diary.DiaryType;
import core.game.system.task.Pulse;
import core.game.world.GameWorld;
import core.game.world.update.flag.context.Animation;
import core.plugin.Initializable;
import core.tools.RandomFunction;
/**
* Represents the town crier dialogue plugin.
* @author 'Vexia
*/
@Initializable
public final class TownCrierDialogue extends DialoguePlugin {
/**
* Constructs a new {@code TownCrierDialogue} {@code Object}.
*/
public TownCrierDialogue() {
/**
* empty.
*/
}
/**
* Constructs a new {@code TownCrierDialogue} {@code Object}.
* @param player the player.
*/
public TownCrierDialogue(Player player) {
super(player);
}
@Override
public DialoguePlugin newInstance(Player player) {
return new TownCrierDialogue(player);
}
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
npc("Hear ye! Hear ye! Player Moderators massive help to ", GameWorld.getSettings().getName().substring(0, GameWorld.getSettings().getName().length() - 3) + "-");
stage = 1;
return true;
}
@Override
public boolean handle(int interfaceId, int buttonId) {
switch (stage) {
case 1:
npc("Oh, hello citizen. Are you here to find out about Player", "Moderators? Or perhaps would you like to know about the", "laws of the land?");
stage = 2;
break;
case 2:
options("Tell me about Player Moderators.", "Tell me about the Rules of " + GameWorld.getSettings().getName() + ".", "Can you give me a handy tip please?", "Bye!");
stage = 3;
break;
case 3:
switch (buttonId) {
case 1:
player("Tell me about Player Moderators.");
stage = 50;
break;
case 2:
player("Tell me about the Rules of " + GameWorld.getSettings().getName() + ".");
stage = 70;
break;
case 3:
player("Can you give me a handy tip please?");
stage = 100;
break;
case 4:
player("Bye!");
stage = 400;
break;
}
break;
case 400:
npc("Nice meeting you.");
stage = 401;
break;
case 401:
end();
break;
case 50:
npc("Of course. What would you like to know?");
stage = 51;
break;
case 51:
options("What is a Player Moderator?", "What can Player Moderators do?", "How do I become a Player Moderator?", "What can Player Moderators not do?");
stage = 52;
break;
case 52:
switch (buttonId) {
case 1:
player(" What is a Player Moderator?");
stage = 150;
break;
case 2:
npc("What can Player Moderators do?");
stage = 160;
break;
case 3:
player("How do I become a Player Moderator?");
stage = 170;
break;
case 4:
player("What can Player Moderators not do?");
stage = 180;
break;
}
break;
case 70:
player.lock(4);
npc("At once. Take a look at my book here.");
npc.animate(new Animation(6866));
GameWorld.getPulser().submit(new Pulse(4) {
@Override
public boolean pulse() {
//player.getDialogueInterpreter().open(496107759); // TODO rulebook broken
return true;
}
});
// Find out about the Rules of Conduct from the Draynor<br><br>Town Crier
if (npc.getId() == 6136) {
player.getAchievementDiaryManager().finishTask(player, DiaryType.LUMBRIDGE, 0, 10);
}
stage = 71;
break;
case 71:
end();
break;
case 100:
int rand = RandomFunction.random(1, 5);
switch (rand) {
case 1:
npc("If the chat window is moving too quickly to report a", "player accurately, run to a quiet spot and review the chat", "at your leisure!");
stage = 2;
break;
case 2:
npc("If you're lost and have no idea where to go, use the Home", "Teleporter spell for free!");
stage = 2;
break;
case 3:
npc("Make your recovery questions and answers hard to guess", "but easy to remember.");
stage = 2;
break;
case 4:
npc("Beware of players trying to lue you into the wilderness.", "Your items cannot be returned if you lose them!");
stage = 2;
break;
default:
npc("" + GameWorld.getSettings().getName() + " will never email you asking for your log-in details.");
stage = 2;
break;
}
break;
case 150:
npc("Player Moderators are normal players of the game, just", "like you. However, since they have shown themselves to be", "trustworthy and active reporters, they have been invited", "by Jagex to monitor the game and take appropriate");
stage = 151;
break;
case 151:
npc("reward when they see rule breaking. You can spot a Player", "Moderator in game by looking at the chat screen - when a", "Player Moderator speaks, a silver crown appears to the", "left of their name. Remember, if there's no silver crown");
stage = 152;
break;
case 152:
npc("there, they are not a Player Moderator! You can check", "out the website if you'd like more information.");
stage = 153;
break;
case 153:
player("Thanks!");
stage = 154;
break;
case 154:
npc("Is there anything else you'd like to know?");
stage = 51;
break;
case 160:
npc("Player Moderators, or 'P-mods', have the ability to mute", "rule breakers and " + GameWorld.getSettings().getName() + " view their reports as a priority so", "that reward is taken as quickly as possible. P-Mods also", "have acces to the Player Moderator Centre. Within the");
stage = 161;
break;
case 161:
npc("Centre are tools to help them Moderate " + GameWorld.getSettings().getName() + ".", "These tools include dedicated forums, the Player", "Moderator Guidelines and the Player Moderator Code of", "Conduct.");
stage = 153;
break;
case 170:
npc("" + GameWorld.getSettings().getName() + " picks players who spend their time and effort to", "help better the " + GameWorld.getSettings().getName() + " community. To increase your", "chances of becoming a Player Moderator:");
stage = 171;
break;
case 171:
npc("Keep your account secure! This is very important, as a", "player with poor security will never be a P-Mod. Read our", "Security Tips for more information.");
stage = 173;
break;
case 173:
npc("Play by the rules! The rules of " + GameWorld.getSettings().getName() + " are enforced", "for a reason, to make the game a fair and enjoyable", "environment for all.");
stage = 174;
break;
case 174:
npc("Report accuratley! When " + GameWorld.getSettings().getName() + " consider an account for", "review they look for quality, not quantity. Ensure your", "reports are of a high quality by following the report", "guidelines.");
stage = 175;
break;
case 175:
npc("Be nice to each other! Treat others as you would", "want to be treated yourself. Respect your fellow player.", "More information can be found on the website.");
stage = 153;
break;
case 180:
npc("P-Mods cannot ban your account - they can only report", "offences. " + GameWorld.getSettings().getName() + " then take reward based on the evidence", "received. If you lose your password or get scamme dby", "another player, P_Mods cannot help you get your account");
stage = 181;
break;
case 181:
npc("back. All they can do is recommend you to go to Player", "Support. They cannot retrieve any items you may have", "lost and they certainly do not recieve any free items", "from " + GameWorld.getSettings().getName() + " for moderating the game. They are players");
stage = 182;
break;
case 182:
npc("who give their all to help the community, out of the", "goodness of their hearts! P-mods do not work for " + GameWorld.getSettings().getName() + "", "and so cannot make you a Moderator, or recommend", "other accounts to become Moderators. If you wish yo");
stage = 183;
break;
case 183:
npc("become a Moderator, feel free to ask me!");
stage = 153;
break;
}
return true;
}
@Override
public int[] getIds() {
return new int[] { 6135, 6136, 6137, 6138, 6139 };
}
}