Added positional audio support
Added positional audio for combat and cannons Added numerous missing audio effects for various item equips and charge spells
This commit is contained in:
@@ -280,7 +280,7 @@ abstract class CombatSwingHandler(var type: CombatStyle?) {
|
||||
if (audio == null || audio.id == 0) {
|
||||
audio = audios[0]
|
||||
}
|
||||
entity.asPlayer().audioManager.send(audio, true)
|
||||
entity.asPlayer().audioManager.send(audio, true, entity.location)
|
||||
}
|
||||
} else {
|
||||
entity.asPlayer().audioManager.send(2564)
|
||||
@@ -288,7 +288,7 @@ abstract class CombatSwingHandler(var type: CombatStyle?) {
|
||||
} else if (entity is NPC && victim is Player) {
|
||||
val npc = entity.asNpc()
|
||||
val audio = npc.getAudio(0)
|
||||
audio?.send(victim.asPlayer(), true)
|
||||
audio?.send(victim.asPlayer(), true, entity.location)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import core.game.node.entity.Entity
|
||||
import core.game.node.entity.impl.Animator.Priority
|
||||
import core.game.node.entity.impl.Projectile
|
||||
import core.game.node.entity.player.Player
|
||||
import core.game.node.entity.player.link.audio.Audio
|
||||
import core.game.node.entity.player.link.TeleportManager
|
||||
import core.game.node.entity.player.link.diary.DiaryType
|
||||
import core.game.node.entity.skill.Skills
|
||||
@@ -169,6 +170,7 @@ class ModernListeners : SpellListener("modern"){
|
||||
}
|
||||
}
|
||||
visualizeSpell(player,BONE_CONVERT_ANIM, BONE_CONVERT_GFX)
|
||||
player.audioManager.send(Audio(114))
|
||||
removeRunes(player)
|
||||
addXP(player,if(bananas) 25.0 else 65.0)
|
||||
setDelay(player,false)
|
||||
|
||||
+2
@@ -1,6 +1,7 @@
|
||||
package rs09.game.node.entity.state.newsys.states
|
||||
|
||||
import core.game.node.entity.player.Player
|
||||
import core.game.node.entity.player.link.audio.Audio
|
||||
import core.game.system.task.Pulse
|
||||
import org.json.simple.JSONObject
|
||||
import rs09.game.node.entity.state.newsys.PlayerState
|
||||
@@ -35,6 +36,7 @@ class GodspellChargedState(player: Player? = null) : State(player) {
|
||||
override fun pulse(): Boolean {
|
||||
player.sendMessage("Your magical charge fades away.")
|
||||
player.clearState("godcharge")
|
||||
player.audioManager.send(Audio(1650))
|
||||
pulse = null
|
||||
return true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user