mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 05:30:05 +01:00
The Kevin De-cleodening: Custom elevator music (#75518)
I got the idea while riding an elevator the other day to make a remix of Title2 but Elevator-style. So I downloaded FLStudio, spent a couple of hours fighting with it, made a song, and opened this PR up. Later on, cats4gold contacted me saying they had the same exact idea, Title2 and all, and after I suggested the ide of combining both versions, we get the status of this PR today! Also our current looping sound system is very very bad, the problem people have with hearing elevator music outside the elevator is because the checks for stuff like volume falloff only happen when an audio starts playing, so if you stand besides an elevator button and hear the music, if you go far away you'll still hear it as if you're next to it. I don't know how to fix this so I didn't touch it, so hopefully someone else that does, does! :)
This commit is contained in:
@@ -10,6 +10,8 @@
|
||||
var/mid_length_vary = 0
|
||||
/// If we should always play each sound once per loop of all sounds. Weights here only really effect order, and could be disgarded
|
||||
var/each_once = FALSE
|
||||
/// Whether if the sounds should be played in order or not. Defaults to FALSE.
|
||||
var/in_order = FALSE
|
||||
/// Override for volume of start sound.
|
||||
var/start_volume
|
||||
/// (soundfile) Played before starting the mid_sounds loop.
|
||||
@@ -50,6 +52,8 @@
|
||||
var/loop_started = FALSE
|
||||
/// If we're using cut_mid, this is the list we cut from
|
||||
var/list/cut_list
|
||||
/// The index of the current song we're playing in the mid_sounds list, only used if in_order is used
|
||||
var/audio_index = 1
|
||||
|
||||
// Args
|
||||
/// Do we skip the starting sounds?
|
||||
@@ -169,6 +173,12 @@
|
||||
. = pick_weight(.)
|
||||
return .
|
||||
|
||||
if(in_order)
|
||||
. = play_from
|
||||
audio_index++
|
||||
if(audio_index > length(play_from))
|
||||
audio_index = 1
|
||||
return .[audio_index]
|
||||
|
||||
if(!length(cut_list))
|
||||
cut_list = shuffle(play_from.Copy())
|
||||
|
||||
@@ -1,18 +1,20 @@
|
||||
/datum/looping_sound/local_forecast
|
||||
start_sound = 'sound/ambience/music/local_forecast/local_forecast1.ogg'
|
||||
start_length = 5.83 SECONDS
|
||||
/datum/looping_sound/elevator_music
|
||||
start_sound = 'sound/ambience/music/elevator/elevator-01.ogg'
|
||||
start_length = 7.62 SECONDS
|
||||
|
||||
mid_sounds = list(
|
||||
'sound/ambience/music/local_forecast/local_forecast2.ogg' = 6,
|
||||
'sound/ambience/music/local_forecast/local_forecast3.ogg' = 5,
|
||||
'sound/ambience/music/local_forecast/local_forecast4.ogg' = 4,
|
||||
'sound/ambience/music/local_forecast/local_forecast5.ogg' = 3,
|
||||
'sound/ambience/music/local_forecast/local_forecast6.ogg' = 2,
|
||||
'sound/ambience/music/local_forecast/local_forecast7.ogg' = 1,
|
||||
'sound/ambience/music/elevator/elevator-01.ogg',
|
||||
'sound/ambience/music/elevator/elevator-02.ogg',
|
||||
'sound/ambience/music/elevator/elevator-03.ogg',
|
||||
'sound/ambience/music/elevator/elevator-04.ogg',
|
||||
'sound/ambience/music/elevator/elevator-05.ogg',
|
||||
'sound/ambience/music/elevator/elevator-06.ogg',
|
||||
'sound/ambience/music/elevator/elevator-07.ogg',
|
||||
'sound/ambience/music/elevator/elevator-08.ogg',
|
||||
)
|
||||
mid_length = 5.83 SECONDS
|
||||
mid_length = 7.62 SECONDS
|
||||
|
||||
end_sound = 'sound/ambience/music/local_forecast/local_forecast8.ogg'
|
||||
end_sound = 'sound/ambience/music/elevator/elevator-08.ogg'
|
||||
|
||||
volume = 20
|
||||
falloff_exponent = 5
|
||||
@@ -21,3 +23,6 @@
|
||||
ignore_walls = FALSE
|
||||
use_reverb = FALSE
|
||||
each_once = TRUE
|
||||
skip_starting_sounds = TRUE
|
||||
in_order = TRUE
|
||||
direct = TRUE
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
var/light_mask = "elev-light-mask"
|
||||
|
||||
/// The soundloop of elevator music
|
||||
var/datum/looping_sound/local_forecast/elevator_music
|
||||
var/datum/looping_sound/elevator_music/elevator_music
|
||||
/// Will the elevator music play?
|
||||
var/elevator_music_toggle = TRUE
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -60,10 +60,6 @@ https://freesound.org/people/ScottFerguson1/sounds/132846/
|
||||
parry.ogg is taken from loudernoises "Sword Clash" which is licensed under CC Attributions 0, which is mixed with a genhit.ogg
|
||||
https://freesound.org/people/loudernoises/sounds/334169/
|
||||
|
||||
local_forecast1.ogg to local_forecast8.ogg is "Local Forecast - Elevator" Kevin MacLeod (incompetech.com)
|
||||
Licensed under Creative Commons: By Attribution 4.0 License
|
||||
http://creativecommons.org/licenses/by/4.0/
|
||||
|
||||
|
||||
|
||||
revolutionary_tide.ogg is adapted from several audio samples:
|
||||
|
||||
Reference in New Issue
Block a user