Music Events
作者:rebot | 分类:模组
Minecraft 版本: 1.20.1
平台: forge
标签: adventure management utility
Music Events is a highly configurable mod that provides extensive control over both vanilla game and custom music. It allows for the creation of intricate, situational audio tracks such as ambient music, combat themes, or context-specific soundtracks. It features an intuitive and user friendly in-game GUI that vastly facilitates the mod's configuration and it's the primary way to setup the mod.
As a developer, YOUR FEEDBACK HELPS ME A LOT! If you have questions, need help, or want clarification about my mod, you are welcome to join my Discord and i'll give you a detailed explanation as soon as i'm able to:
Watch a guide on how to setup Horror themed soundtracks:
Syntax used for the Horror themed sountracks ``` # ========================================== # UNIVERSAL SETTINGS # ========================================== [universal] server_nbt_sync = ["warden_spawn_tracker"] # ========================================== # EVENTS (TRIGGERS) # ========================================== [[events.mobs]] event_name = "warden_undetected_4" priority = 204 detection_range = 25.0 sync_group = "warden_proximity" resource_name = ["minecraft:warden"] [[events.player]] event_name = "shrieker" priority = 300 event_delay = 6.0 nbt_match = ["{warden_spawn_tracker:{warning_level:1}}"] [[events.mobs]] event_name = "warden_undetected_3" priority = 203 detection_range = 50.0 sync_group = "warden_proximity" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "warden_undetected_2" priority = 202 detection_range = 75.0 sync_group = "warden_proximity" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "warden_detected_4" priority = 214 detection_range = 25.0 mob_targeting = true sync_group = "warden_proximity_detected" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "warden_detected_3" priority = 213 detection_range = 50.0 mob_targeting = true sync_group = "warden_proximity_detected" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "warden_detected_2" priority = 212 detection_range = 75.0 mob_targeting = true sync_group = "warden_proximity_detected" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "warden_detected_1" priority = 211 detection_range = 100.0 mob_targeting = true sync_group = "warden_proximity_detected" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "angel" priority = 100 detection_range = 50.0 mob_targeting = true require_fov = 2 resource_name = ["weeping_angels:weeping_angel"] [[events.mobs]] event_name = "warden_undetected_1" priority = 201 detection_range = 100.0 sync_group = "warden_proximity" resource_name = ["minecraft:warden"] [[events.mobs]] event_name = "dweller" priority = 101 mob_targeting = true require_fov = 1 resource_name = ["cave_dweller:cave_dweller"] ```The mod strictly supports audio files in the .ogg format.
Configuration is handled primarily through a dedicated in-game GUI.
GUI ACCESS:
Press the F6 key to open the interface.
MODIFYING VANILLA MUSIC:
- Navigate to the Events tab.
- Create a new event (e.g., dimensions) and assign its priority.
- Define the required parameters (e.g., add resource_name and set to minecraft:overworld).
- Select Register Audio and search for the desired audio file.
- Note: Searches use the internal file name (e.g., Haggstrom is stored as hal3).
- Note: Hover over a file in the dropdown list to preview the audio.
- Click Save and then Reload to apply the configuration.
USING CUSTOM AUDIO FILES:
- Open the Audios folder using the GUI.
- Place custom .ogg files (and create subfolders if you want to keep it more organized) into the designated directory.
- Link the tracks to events using the standard Register Audio procedure.
GUI Panels Overview:
- Universal: Manages default parameter values that apply globally across all newly created events. Event-specific parameters will override the Universal settings.
- Events: Handles the creation of custom events and the configuration of their respective parameters.
- Audios: Manages configuration settings for individual audio tracks.
- Sync Groups: Provides an overview and management interface for events bound together using the
sync_groupparameter.
Event Types, Modifiers, and Examples:
Each event evaluates contextual conditions before triggering audio playback.
Universal Parameters (Default event configuration pool):
Spoiler - play_when_paused = true/false: Determines if the audio track is allowed to play while the game menu is paused. - muffling_when_paused = 1.0: A muffling effect multiplier applied during game pauses. (Recommended: 1.0). - underwater_muffling = 1.0: A muffling effect multiplier applied when the player is submerged. (Recommended: 1.0). - gui_muffling = 1.0: A muffling effect multiplier applied when a GUI screen is active. (Recommended: 1.0). - gui_muffling_delay = 20: The delay (in seconds) before the GUI muffling effect takes place. - gui_muffling_blacklist = ["InventoryScreen"]: A list of GUI classes that bypass the muffling effect. **Use the mod's debug screen to know the GUI you're currently looking at.** - pause_volume_multiplier = 0.5: A volume control multiplier applied when the game is paused. - remember_track = true/false: If enabled, the event remembers the last track it played before going inactive and will replay it upon reactivation instead of picking a random new track. - resume_from_timestamp = true/false: If enabled, when an event reactivates, it resumes playback straight from the exact point (timestamp) it was paused at. - seamless_handoff = true/false: Enables smooth track transitions. If Event A transitions into Event B, and both share the currently playing track in their playlist, the track will seamlessly continue playing without restarting or fading out. - fade_in = 2.0 / fade_out = 2.0: Specifies the audio volume transition duration (in seconds) when an event activates or deactivates. - persistence = 10.0: Defines the duration (in seconds) the event will forcefully remain active and continue playing music after its activation requirements are no longer met (e.g., staying in combat for 10s after monsters are dead). - time_between_audio = 60.0: Specifies the cooldown duration (in seconds) before the event can trigger subsequent track playbacks after a track has finished. - jukebox_behavior = "ignore"/"pause"/"muffle": Determines how tracks react to nearby vanilla jukeboxes playing music discs. - cooldown_group_time = 120.0 / cooldown_group_events = ["eventA", "eventB"]: Links track cooldowns across multiple distinct events. If one event finishes a track, all events listed in `cooldown_group_events` will share the specified `cooldown_group_time` before they are permitted to play again. - mob_blacklist = ["minecraft:slime", "minecraft:vex"]: A list of entity IDs that are prevented from activating the mobs events globally. - priority = 50: Integer value determining the playback hierarchy when multiple events are active simultaneously. Higher values take precedence. - hard_interrupt = true/false: Enforces immediate termination of the current audio track, bypassing and ignoring standard persistance and fade-out parameters. - locked = true / unlocks_event = "phase_2" / relock_when_inactive = true: State management parameters allowing sequential event activations. An event can be `locked` by default and only become active when another event calls its `unlocks_event`. - sync_group = "battlefield_crescendo": Assigns events to a synchronized group. Sequential events within the same `sync_group` will inherit the exact playback timestamp of the previously active track. Useful for layered or multi-phase audio files that share the same tempo/layout. - server_nbt_sync = ["warden_spawn_tracker"]: A comma-separated list of root NBT keys that the server should actively sync for the nbt_match parameter.Audio Track Parameters:
Spoiler - volume = 1.0: Multiplier for the audio track's volume level. - weight = 50: Determines the playback probability when an event has multiple registered audio tracks. Higher weights drastically increase the chance of selection. - require_all_events = true/false: If true, it requires all events strictly listed within the `target_events` array to be active simultaneously for the track to play. - target_events = ["overworld_day", "overworld_night"]: Defines a specific list of events to which the track belongs and checks for activation. - upgrade_delay = 5.0 / upgrade_fade_in = 3.0 / upgrade_fade_out = 3.0: Easing configurations for dynamic track upgrades. A track currently playing can seamlessly 'upgrade' to this track if the event conditions are met, utilizing these isolated crossfade timings specifically bypassing standard event fading. - start_time = 15.5: Dictates the timestamp (in seconds) where the track playback initiates. By setting it to 15.5, the track will always start playing 15 and a half seconds inwards, skipping the intro. - start_x = 2: Configures repetition. The track will repeat exactly 2 times before completing. - loop_start = 10.0 / loop_end = 60.0: Creates an isolated internal playback loop. The track starts normally, but when the playback reaches `loop_end` (e.g., 60.0 seconds), it will seamlessly teleport back to `loop_start` (e.g., 10.0 seconds) and repeat that sub-section endlessly based on the `start_x` value. - play_once = 1/2/3/4/5: Determines how frequently a track can be replayed. It accepts the following numerical values: - 1 (Round Robin): The track will not play again until all other available tracks for the active event have been played. - 2 (Event Lifetime): The track plays only once as long as the event remains continuously active. - 3 (Session): The track plays only once per world join. Resets when logging out and back in. - 4 (JVM Session): The track plays only once per game launch. Resets when Minecraft is completely restarted. - 5 (Persistent World): The track plays only once in a given world, ever. Stored persistently. - interruptible = true/false: Specifies whether the track can be forcefully interrupted by a higher-priority event. Tracks flagged as `false` act as a shield and will refuse to be paused, always playing from start to finish. - breakthrough_priority = 500: Overrides the track's uninterruptible state. Even if the track acts as a shield, any event with a priority equal to or higher than 500 can forcefully break through and interrupt it. - interrupt_whitelist = ["boss_phase_2"]: An exclusive list of event names permitted to bypass the interruptible flag and pause the track, regardless of priorities.Specific Event Types and Constraints:
- Mobs: Activates based on entity proximity.
- Kill: Activates upon entity death.
- Inventory: Activates when items reside in specific inventory locations.
- Player: Evaluates player's exact internal condition.
- Zones: Fixed coordinate-based volumetric trigger.
-
Raid: Evaluates pillager raid variables.
Spoiler - min_wave = 1 / max_wave = 5: Enforces upper and lower bounds on the active pillager raid wave levels. - status = "active"/"victory"/"loss"/"stopped"/"any": Verifies a specific raid progression state. -
Statistic: Evaluates internal player statistics tracking.
- Dimensions / Biomes / Time / Weather / Gamemode / Difficulty / Structure / Advancement / PvP / Riding / GUI / Effect:
Evaluated through a unifiedresource_nameparameter providing standard string matching arrays.
Commands & Debugging:
The mod provides several commands under the base /musicevents command to manage the state machine and track audio directly from the chat:
Additionally, a built-in debug screen can be toggled with the F4 key by default. The debug screen acts as an active overlay to help you configure parameters, understand how the mod calculates priorities, which audio track is playing, and what parameters are forcefully affecting track behavior during runtime.
请登录后举报
暂无评论,抢个沙发吧~