Implemented water filling sounds for filling water vessels from all water sources

Implemented specific bucket water filling sound when filling from a well
Implemented emptying sounds for emptying vessels
Implemented cow milking sound
Implemented sound when smelting at a furnace
Implemented sound when smelting cannonballs at a furnace
Implemented sound when glassblowing
Fixed herb cleaning sound
Fixed regular wood door opening and closing sounds
Implemented metal door/gate opening and closing sounds
Implemented fence opening and closing sounds
Added Camelot castle main gate in door_configs.json
Fixed Sinclair mansion main gate to be a metal type door in door_configs.json
Implemented drinking sound when drinking from a waterskin in the desert
Implemented desert magic carpet travel take off and landing sound
Implemented desert magic carpet travel jingle/music
Fence around Falador cow farm is now properly identified as a fence and opens correctly
Fence id 34780 is now properly identified as a fence in door_configs.json so it opens correctly
Fence id 8810 is now properly identified as a fence in door_configs.json so it opens correctly
Fence id 2050-2051 is now properly identified as a fence in door_configs.json so it opens correctly
Fence id 1553 now has the correct open id in door_configs.json so it opens correctly
Fixed music tracks Relleka(289), Saga(290), and Borderlands(291) so they now play in their correct locations
Implemented jingle/music for sailing/chartering a ship(Trader crewmembers)
Implemented jingle/music for sailing/chartering a ship from/to Port Sarim/Karamja
Implemented jingle/music for sailing/chartering a ship from/to Port Sarim/Entrana
Implemented jingle/music for sailing/chartering a ship from/to Relleka/Neitiznot
Implemented jingle/music for sailing/chartering a ship from/to Relleka/Jatizso
Implemented jingle/music for sailing/chartering a ship from/to Ardougne/Brimmhaven
Implemented jingle/music for sailing/chartering a ship from/to Port Sarim/Pest control
Fixed the music player to be more authentic. Now when songs end they will repeat instead of playing a random inauthentic song. The loop function now works correctly so the currently playing song will play endlessly without changing as the player moves.
Implemented playJingle function in contentAPI.kt
This commit is contained in:
Zerken
2023-06-21 14:57:01 +00:00
committed by Ryan
parent 1672646e87
commit cef956722a
23 changed files with 141 additions and 26 deletions
+12
View File
@@ -70,6 +70,9 @@ import core.tools.*
import core.game.world.update.flag.*
import core.game.world.update.flag.context.*
import core.game.requirement.*
import core.net.packet.PacketRepository
import core.net.packet.context.MusicContext
import core.net.packet.out.MusicPacket
import java.util.regex.*
import java.io.*
import kotlin.math.*
@@ -553,6 +556,15 @@ fun getAudio(id: Int, volume: Int = 10, delay: Int = 1): Audio {
return Audio(id, volume, delay)
}
/**
* Plays a jingle by id
* @param player the player to play the jingle for
* @param jingleId the jingle to play
*/
fun playJingle(player: Player, jingleId: Int) {
PacketRepository.send(MusicPacket::class.java, MusicContext(player, jingleId, true))
}
/**
* Impact an enemy with the given amount of damage and the given hitsplat type
* @param entity the entity to damage