Fixed the mining level requirement of perfect gold ore to be 40 instead of 46

Resolved a issue where gold rock scenery was rewarding perfect gold ore on gold rocks outside of the Witchaven dungeon
Familiars are no longer allowed in some places they shouldn't be
The Grand Tree mine's roots now properly animate and play the correct sound when pushing them
The correct thieving level is now required for Varrock pickpocket diary task
Added the correct dialogue message to inspecting the cactus with the red scarf from tourist trap
Corrected Dagganoth Prime talisman drops
Arctic pines now reward 40 xp authentic to Jan of 2009 instead of Sept of 2009
All farming patch tree chop rates have been corrected
Fixed an issue where the player would continue to chop farming patch trees after they get chopped down
Fixed the typo in the word Jenkiins -> Jenkins
This commit is contained in:
Zerken
2023-09-10 15:24:56 +00:00
committed by Ryan
parent ac5c31747f
commit cbeb422411
10 changed files with 65 additions and 23 deletions
@@ -19,6 +19,7 @@ import core.game.node.scenery.Scenery
import core.game.node.scenery.SceneryBuilder
import core.game.system.command.sets.STATS_BASE
import core.game.system.command.sets.STATS_ROCKS
import core.game.world.map.zone.ZoneBorders
import core.tools.RandomFunction
import core.tools.prependArticle
import org.rs09.consts.Items
@@ -89,6 +90,12 @@ class MiningListener : InteractionListener {
player.setAttribute("/save:jewellery-charges:bracelet-of-clay", charges)
}
}
//If the player is mining gold in the witchaven dungeon, reward family crest perfect gold ore
val familyCrestGoldOreArea = ZoneBorders(2733, 9695, 2741, 9683)
if (reward == Items.GOLD_ORE_444 && inBorders(player, familyCrestGoldOreArea)) {
reward = Items.PERFECT_GOLD_ORE_446
}
val rewardName = getItemName(reward).lowercase()
// Send the message for the resource reward
@@ -275,7 +275,7 @@ public enum MiningNode{
COAL_49(42035,452, (byte) 8),
//Gold
GOLD_ORE_0( 2099, 452, (byte) 20),
GOLD_ORE_0( 2099, 452, (byte) 9),
GOLD_ORE_1( 2098, 450, (byte) 9),
GOLD_ORE_2( 2611, 21298, (byte) 9),
GOLD_ORE_3( 2610, 21297, (byte) 9),
@@ -573,13 +573,6 @@ public enum MiningNode{
reward = 12630;
level = 46;
break;
case 20:
respawnRate = 50 | 100 << 16;
experience = 17.5;
rate = 0.6;
reward = 446;
level = 46;
break;
}
}
private static HashMap<Integer, MiningNode> NODE_MAP = new HashMap<>();
@@ -15,6 +15,7 @@ import core.game.event.ResourceProducedEvent
import core.game.interaction.Clocks
import core.game.interaction.IntType
import core.game.interaction.InteractionListener
import core.game.interaction.QueueStrength
import core.game.node.Node
import core.game.node.entity.impl.Projectile
import core.game.node.entity.npc.NPC
@@ -77,7 +78,7 @@ class WoodcuttingListener : InteractionListener {
val reward = resource.getReward()
val rewardAmount: Int
if (tool.id == Items.INFERNO_ADZE_13661 && RandomFunction.roll(4)) {
if (tool.id == Items.INFERNO_ADZE_13661 && reward != Items.BARK_3239 && RandomFunction.roll(4)) {
sendMessage(player, "You chop some logs. The heat of the inferno adze incinerates them.")
Projectile.create(
player, null,
@@ -115,6 +116,8 @@ class WoodcuttingListener : InteractionListener {
//send the message for the resource reward
if (resource == WoodcuttingNode.DRAMEN_TREE) {
player.packetDispatch.sendMessage("You cut a branch from the Dramen tree.")
} else if (reward == Items.BARK_3239 && rewardAmount == 0) {
player.packetDispatch.sendMessage("You chop away some bark, but it falls to pieces before you can pick it up.")
} else {
player.packetDispatch.sendMessage("You get some " + ItemDefinition.forId(reward).name.lowercase(Locale.getDefault()) + ".")
}
@@ -159,6 +162,12 @@ class WoodcuttingListener : InteractionListener {
if (fPatch != null) {
val patch = fPatch.getPatchFor(player)
patch.setCurrentState(patch.getCurrentState() + 1)
node.isActive = false
playAudio(player, TREE_FALLING_2734)
queueScript(player, 2, QueueStrength.SOFT) {
node.isActive = true
return@queueScript stopExecuting(player)
}
}
return true
}
@@ -249,12 +258,12 @@ class WoodcuttingListener : InteractionListener {
}
// Bark
if (reward == 3239) {
// If we receive the item, give the full experience points otherwise give the base amount
if (reward == Items.BARK_3239) {
// If we receive the item, give the experience points
if (amount >= 1) {
experience = 275.2
experience = 82.5
} else {
amount = 1
return 0.0
}
}
@@ -265,7 +265,7 @@ public enum WoodcuttingNode {
reward = 10810;
respawnRate = 75 | 130 << 16;
rate = 0.73;
experience = 140.2;
experience = 40.0;
level = 54;
rewardAmount = 35;
baseLow = 6;
@@ -344,6 +344,10 @@ public enum WoodcuttingNode {
experience = 37.5;
level = 15;
rewardAmount = 10;
baseLow = 32;
baseHigh = 100;
tierModLow = 16;
tierModHigh = 50;
break;
case 20:
reward = 1519;
@@ -352,6 +356,10 @@ public enum WoodcuttingNode {
experience = 67.8;
level = 30;
rewardAmount = 20;
baseLow = 16;
baseHigh = 50;
tierModLow = 8;
tierModHigh = 25;
break;
case 21:
reward = 1517;
@@ -360,6 +368,10 @@ public enum WoodcuttingNode {
experience = 100.0;
level = 45;
rewardAmount = 30;
baseLow = 8;
baseHigh = 25;
tierModLow = 4;
tierModHigh = 12.5;
break;
case 22:
reward = 1515;
@@ -368,6 +380,10 @@ public enum WoodcuttingNode {
experience = 175.0;
level = 60;
rewardAmount = 40;
baseLow = 4;
baseHigh = 12.5;
tierModLow = 2;
tierModHigh = 6.25;
break;
case 23:
reward = 1513;
@@ -376,6 +392,10 @@ public enum WoodcuttingNode {
experience = 250.0;
level = 75;
rewardAmount = 50;
baseLow = 2;
baseHigh = 6;
tierModLow = 1;
tierModHigh = 3;
break;
}
}