Replace a bunch of magic numbers & Fix Mackerel Spelling (#559)

* Convert Some NPCActions Magic Numbers

* IntelliJ Reformat NpcActions.java

* Convert Magic Numbers In Dye.java

* Convert More Magic Numbers In NpcActions.java

* Convert More NpcActions.java Magic Numbers

* Plugins: Replace Magic Numbers

* Skills: Cooking: Replaced all Item/Object Magic Numbers & Fixed Mackerel spelling

* Food: Fixed Mackerel spelling

* Skills: Fishing: Replace Magic Numbers

* Skills: Mining: Replace Magic Numbers

* IntelliJ Code Reformat Changed Files
This commit is contained in:
Josh Shippam
2023-01-30 00:11:12 +00:00
committed by GitHub
parent 15d6b9f35a
commit aab9cfe951
18 changed files with 2678 additions and 2754 deletions
@@ -6,6 +6,7 @@ import com.rs2.event.SubscribesTo
import com.rs2.event.impl.ObjectFirstClickEvent
import com.rs2.game.content.skills.core.Mining
import com.rs2.game.players.Player
import com.rs2.world.clip.Region
@SubscribesTo(ObjectFirstClickEvent::class)
class ObjectFirstClick : EventSubscriber<ObjectFirstClickEvent> {
@@ -16,6 +17,10 @@ class ObjectFirstClick : EventSubscriber<ObjectFirstClickEvent> {
player.packetSender.sendMessage("[click= object], [type= first], [id= ${player.objectId}], [location= x:${player.objectX} y:${player.objectY} ]")
}
if (!Region.objectExists(player.objectId, player.objectX, player.objectY, player.heightLevel)) {
return
}
// if its a rock we can mine, mine it
if (Mining.rockExists(event.gameObject)) {
player.mining.startMining(player, event.gameObject, player.objectX, player.objectY, player.clickObjectType)