Fixed a bug that prevented progression in tutorial island
Fixed a bug that caused woodcutting to take slightly longer Fixed a bug that caused the woodcutting axe message to print more often than it should Fixed a bug that caused fishing to not print its fishing attempt message Fixed a bug that caused fishing to take slightly longer Fixed a bug that would cause nechryaels to lose interest in the player when their minions attacked Made sure the grand exchange tests always clean up the GEDB
This commit is contained in:
@@ -47,14 +47,16 @@ class FishingListener : InteractionListener{
|
||||
return restartScript(player)
|
||||
|
||||
if (state == 0) {
|
||||
sendMessage(player, "You attempt to catch some fish...")
|
||||
}
|
||||
|
||||
if (state == 1) {
|
||||
if (!checkRequirements(player, op, node))
|
||||
return clearScripts(player)
|
||||
forager?.let {
|
||||
val dest = player.location.transform(player.direction)
|
||||
Pathfinder.find(it, dest).walk(it)
|
||||
}
|
||||
anim(player, op)
|
||||
return delayScript(player, 5)
|
||||
}
|
||||
|
||||
anim(player, op)
|
||||
@@ -74,7 +76,8 @@ class FishingListener : InteractionListener{
|
||||
player.incrementAttribute("$STATS_BASE:$STATS_FISH")
|
||||
rewardXP(player, Skills.FISHING, fish.experience)
|
||||
|
||||
return restartScript(player)
|
||||
setCurrentScriptState(player, 1)
|
||||
return keepRunning(player)
|
||||
}
|
||||
|
||||
private fun anim(player: Player, option: FishingOption) {
|
||||
|
||||
@@ -6,9 +6,7 @@ import content.data.tables.BirdNest
|
||||
import content.global.skill.farming.FarmingPatch.Companion.forObject
|
||||
import content.global.skill.skillcapeperks.SkillcapePerks
|
||||
import content.global.skill.skillcapeperks.SkillcapePerks.Companion.isActive
|
||||
import core.api.delayScript
|
||||
import core.api.finishedMoving
|
||||
import core.api.sendMessage
|
||||
import core.api.*
|
||||
import core.cache.def.impl.ItemDefinition
|
||||
import core.game.container.impl.EquipmentContainer
|
||||
import core.game.event.ResourceProducedEvent
|
||||
@@ -61,13 +59,14 @@ class WoodcuttingListener : InteractionListener {
|
||||
return true
|
||||
|
||||
if (state == 0) {
|
||||
sendMessage(player, "You swing your axe at the tree...")
|
||||
}
|
||||
|
||||
if (state == 1) {
|
||||
if (!checkWoodcuttingRequirements(player, resource, node)) {
|
||||
player.scripts.reset()
|
||||
return true
|
||||
}
|
||||
animateWoodcutting(player)
|
||||
sendMessage(player, "You swing your axe at the tree...")
|
||||
return delayScript(player, 3)
|
||||
}
|
||||
|
||||
animateWoodcutting(player)
|
||||
@@ -129,7 +128,8 @@ class WoodcuttingListener : InteractionListener {
|
||||
|
||||
delayScript(player, 3)
|
||||
rollDepletion(player, node.asScenery(), resource)
|
||||
return true
|
||||
setCurrentScriptState(player, 1)
|
||||
return keepRunning(player)
|
||||
}
|
||||
|
||||
private fun rollDepletion(player: Player, node: Scenery, resource: WoodcuttingNode): Boolean {
|
||||
|
||||
@@ -67,6 +67,11 @@ class NechryaelBehavior : NPCBehavior(*Tasks.NECHRYAELS.npcs) {
|
||||
list.remove(spawn)
|
||||
setAttribute(self, ATTR_SPAWNS, list)
|
||||
}
|
||||
|
||||
override fun shouldIgnoreMultiRestrictions(self: NPC, victim: Entity): Boolean {
|
||||
val list = getSpawns(self)
|
||||
return victim == self.properties.combatPulse.getVictim() || list.contains(victim.properties.combatPulse.getVictim())
|
||||
}
|
||||
}
|
||||
|
||||
class DeathspawnBehavior : NPCBehavior(NPCs.DEATH_SPAWN_1614) {
|
||||
|
||||
Reference in New Issue
Block a user