mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2025-12-09 16:45:44 -07:00
Fixed seers diary inferno adze bonus
Fixed Thormac staff enchantment
This commit is contained in:
parent
89edf78e54
commit
1ff19880ef
3 changed files with 7 additions and 8 deletions
|
|
@ -12,7 +12,6 @@ class MysticStaffEnchantInterface : InterfaceListener {
|
|||
override fun defineInterfaceListeners() {
|
||||
on(INTERFACE_332) { player, _, _, buttonID, _, _ ->
|
||||
val staff = buttonMap[buttonID] ?: return@on true
|
||||
val price = if (inEquipment(player, Items.SEERS_HEADBAND_14631)) 27000 else 40000
|
||||
|
||||
if (!inInventory(player, staff.basicID)) {
|
||||
sendMessage(player, "You don't have a${if (StringUtils.isPlusN(getItemName(staff.basicID))) "n" else ""} ${getItemName(staff.basicID)} to enchant.")
|
||||
|
|
@ -21,12 +20,12 @@ class MysticStaffEnchantInterface : InterfaceListener {
|
|||
|
||||
closeInterface(player)
|
||||
|
||||
if (!inInventory(player, Items.COINS_995, price)) {
|
||||
sendNPCDialogue(player, NPCs.THORMAC_389, "I need ${String.format("%,d", price)} coins for materials. Come back when you have the money!", FacialExpression.NEUTRAL)
|
||||
if (!inInventory(player, Items.COINS_995, 40000)) {
|
||||
sendNPCDialogue(player, NPCs.THORMAC_389, "I need ${String.format("%,d", 40000)} coins for materials. Come back when you have the money!", FacialExpression.NEUTRAL)
|
||||
return@on true
|
||||
}
|
||||
|
||||
if (removeItem(player, Item(staff.basicID, 1)) && removeItem(player, Item(Items.COINS_995, price))) {
|
||||
if (removeItem(player, Item(staff.basicID, 1)) && removeItem(player, Item(Items.COINS_995, 40000))) {
|
||||
sendNPCDialogue(player, NPCs.THORMAC_389, "Just a moment... hang on... hocus pocus abra-cadabra... there you go! Enjoy your enchanted staff!", FacialExpression.NEUTRAL)
|
||||
addItem(player, staff.enchantedID, 1)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -93,7 +93,9 @@ class WoodcuttingListener : InteractionListener {
|
|||
).send()
|
||||
|
||||
//add woodcutting experience
|
||||
player.getSkills().addExperience(Skills.WOODCUTTING, resource.getExperience())
|
||||
rewardAmount = calculateRewardAmount(player, reward) // calculate amount
|
||||
val experience: Double = calculateExperience(player, resource, rewardAmount)
|
||||
player.getSkills().addExperience(Skills.WOODCUTTING, experience, true)
|
||||
|
||||
//nullcheck the fire, and only if it exists award the firemaking XP
|
||||
val fire = Log.forId(reward)
|
||||
|
|
|
|||
|
|
@ -9,7 +9,6 @@ import core.game.node.entity.npc.NPC
|
|||
import core.game.node.entity.player.Player
|
||||
import core.plugin.Initializable
|
||||
import core.tools.END_DIALOGUE
|
||||
import org.rs09.consts.Items
|
||||
import org.rs09.consts.NPCs
|
||||
import content.data.Quests
|
||||
|
||||
|
|
@ -43,8 +42,7 @@ class ThormacDialogue(player: Player? = null) : DialoguePlugin(player) {
|
|||
)
|
||||
|
||||
ENCHANT_DIALOGUE -> {
|
||||
val cost = if (player.equipment.contains(Items.SEERS_HEADBAND_14631, 1)) 27 else 40
|
||||
npcl(FacialExpression.HAPPY, "Yes, it'll cost you $cost,000 coins for the materials needed though. " +
|
||||
npcl(FacialExpression.HAPPY, "Yes, it'll cost you 40,000 coins for the materials needed though. " +
|
||||
"Which sort of staff did you want enchanting?").also { stage++ }
|
||||
}
|
||||
ENCHANT_DIALOGUE + 1 -> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue