mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2025-12-21 09:02:07 -07:00
Corrected XP rate options
Fixed some minor tutorial island bugs
This commit is contained in:
parent
abdcc34702
commit
3f499d1244
4 changed files with 34 additions and 10 deletions
|
|
@ -137,19 +137,19 @@ object TutorialInteractionReceiver : EventHook<InteractionEvent>
|
|||
}
|
||||
|
||||
//Prospect rock - Tin
|
||||
31 -> if(MiningNode.forId(event.target.id).identifier == 2.toByte() && event.option == "prospect"){
|
||||
31 -> if(MiningNode.forId(event.target.id)?.identifier?.equals(2.toByte()) == true && event.option == "prospect"){
|
||||
setAttribute(entity, "tutorial:stage", 32)
|
||||
TutorialStage.load(entity, 32)
|
||||
}
|
||||
|
||||
//Prospect rock- Copper
|
||||
33 -> if(MiningNode.forId(event.target.id).identifier == 1.toByte() && event.option == "prospect"){
|
||||
33 -> if(MiningNode.forId(event.target.id)?.identifier?.equals(1.toByte()) == true && event.option == "prospect"){
|
||||
setAttribute(entity, "tutorial:stage", 34)
|
||||
TutorialStage.load(entity, 34)
|
||||
}
|
||||
|
||||
//Mine rock - Tin
|
||||
35 -> if(MiningNode.forId(event.target.id).identifier == 2.toByte() && event.option == "mine"){
|
||||
35 -> if(MiningNode.forId(event.target.id)?.identifier?.equals(2.toByte()) == true && event.option == "mine"){
|
||||
setAttribute(entity, "tutorial:stage", 36)
|
||||
TutorialStage.load(entity, 36)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -98,20 +98,33 @@ class TutorialMagicTutorDialogue(player: Player? = null) : DialoguePlugin(player
|
|||
0 -> options("Set Ironman Mode (current: ${player.ironmanManager.mode.name})", "Change XP Rate (current: ${player.skills.experienceMutiplier}x)", "I'm ready now.").also { stage++ }
|
||||
1 -> when(buttonId){
|
||||
1 -> options("None","Standard","Hardcore (Permadeath!)","Ultimate","Nevermind.").also { stage = 10 }
|
||||
2 -> options("1.0x","2.5x","5.0x","10x","20x").also { stage = 20 }
|
||||
2 -> options("1.0x","2.5x","5.0x","10x").also { stage = 20 }
|
||||
3 -> npcl(FacialExpression.FRIENDLY, "Well, you're all finished here now. I'll give you a reasonable number of starting items when you leave.").also { stage = 30 }
|
||||
}
|
||||
|
||||
10 -> {
|
||||
val mode = IronmanMode.values()[buttonId - 1]
|
||||
player.dialogueInterpreter.sendDialogue("You set your ironman mode to: ${mode.name}.")
|
||||
player.ironmanManager.mode = mode
|
||||
stage = 0
|
||||
if(buttonId < 5)
|
||||
{
|
||||
val mode = IronmanMode.values()[buttonId - 1]
|
||||
player.dialogueInterpreter.sendDialogue("You set your ironman mode to: ${mode.name}.")
|
||||
player.ironmanManager.mode = mode
|
||||
if (player.skills.experienceMutiplier == 10.0 && mode != IronmanMode.HARDCORE) player.skills.experienceMutiplier = 5.0
|
||||
}
|
||||
else
|
||||
{
|
||||
handle(interfaceId, 0)
|
||||
}
|
||||
}
|
||||
|
||||
20 -> {
|
||||
val rates = arrayOf(1.0,2.5,5.0,10.0,20.0)
|
||||
val rates = arrayOf(1.0,2.5,5.0,10.0)
|
||||
val rate = rates[buttonId - 1]
|
||||
if(rate == 10.0 && player.ironmanManager.mode != IronmanMode.HARDCORE) {
|
||||
player.dialogueInterpreter.sendDialogue("10.0x is only available to Hardcore Ironmen!")
|
||||
stage = 0
|
||||
return true
|
||||
}
|
||||
player.dialogueInterpreter.sendDialogue("You set your XP rate to: ${rate}x.")
|
||||
player.skills.experienceMutiplier = rate
|
||||
stage = 0
|
||||
|
|
@ -138,6 +151,15 @@ class TutorialMagicTutorDialogue(player: Player? = null) : DialoguePlugin(player
|
|||
player.inventory.add(*STARTER_PACK)
|
||||
player.bank.add(*STARTER_BANK)
|
||||
|
||||
if(player.ironmanManager.mode == IronmanMode.HARDCORE)
|
||||
{
|
||||
setAttribute(player, "/save:permadeath", true)
|
||||
}
|
||||
else if(player.skills.experienceMutiplier == 10.0)
|
||||
{
|
||||
player.skills.experienceMutiplier = 5.0
|
||||
}
|
||||
|
||||
//This overwrites the stuck dialogue after teleporting to Lumbridge for some reason
|
||||
//Dialogue from 2007 or thereabouts
|
||||
//Original is five lines, but if the same is done here it will break. Need to find another way of showing all this information.
|
||||
|
|
|
|||
|
|
@ -42,12 +42,14 @@ class TutorialMasterChefDialogue(player: Player? = null) : DialoguePlugin(player
|
|||
{
|
||||
sendItemDialogue(player, Items.BUCKET_OF_WATER_1929, "The Master Chef gives you another bucket of water.")
|
||||
addItem(player, Items.BUCKET_OF_WATER_1929)
|
||||
TutorialStage.load(player, 19)
|
||||
return false
|
||||
}
|
||||
if(!inInventory(player, Items.POT_OF_FLOUR_1933))
|
||||
{
|
||||
sendItemDialogue(player, Items.POT_OF_FLOUR_1933, "The Master Chef gives you another pot of flour.")
|
||||
addItem(player, Items.POT_OF_FLOUR_1933)
|
||||
TutorialStage.load(player, 19)
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ class TutorialMiningInstructorDialogue(player: Player? = null) : DialoguePlugin(
|
|||
}
|
||||
}
|
||||
|
||||
34 -> when(stage) {
|
||||
34,35 -> when(stage) {
|
||||
0 -> npcl(FacialExpression.FRIENDLY, "Absolutely right, ${player.username}. These two ore types can be smelted together to make bronze.").also { stage++ }
|
||||
1 -> npcl(FacialExpression.FRIENDLY, "So now you know what ore is in the rocks over there, why don't you have a go at mining some tin and copper? Here, you'll need this to start with.").also { stage++ }
|
||||
2 -> {
|
||||
|
|
@ -82,7 +82,7 @@ class TutorialMiningInstructorDialogue(player: Player? = null) : DialoguePlugin(
|
|||
}
|
||||
}
|
||||
|
||||
40 -> when(stage){
|
||||
40,41 -> when(stage){
|
||||
0 -> npcl(FacialExpression.FRIENDLY, "Okay, I'll show you how to make a dagger out of it. You'll be needing this..").also { stage++ }
|
||||
1 -> {
|
||||
addItem(player, Items.HAMMER_2347)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue