Added support to fire off a discord alert to a webhook (set in server config as server.openrsc_integration_webhook) when Wormbrain's map piece is collected so that rsc plate pures are possible
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
package content.global.skill.magic
|
||||
|
||||
import core.game.event.SpellCastEvent
|
||||
import core.api.log
|
||||
import core.game.node.Node
|
||||
import core.game.node.entity.player.Player
|
||||
import core.game.node.entity.player.link.SpellBookManager
|
||||
import core.tools.Log
|
||||
import core.tools.SystemLogger
|
||||
|
||||
@@ -34,6 +36,7 @@ object SpellListeners {
|
||||
val method = get(button,type,node?.id ?: 0,book) ?: get(button,type,book) ?: return
|
||||
try {
|
||||
method.invoke(player, node)
|
||||
player.dispatch(SpellCastEvent(SpellBookManager.SpellBook.valueOf(book.uppercase()), button, node))
|
||||
} catch (e: IllegalStateException){
|
||||
player.removeAttribute("spell:runes")
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user