mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-09 07:46:20 +00:00
* Instrument editor now uses TGUI (#81923) ## About The Pull Request Instruments now use TGUI as their editor which is pretty cool. It's mostly a 1:1 remake of the HTML UI except I did make a change to make the playback options a little more compact, leaving some more space for the editor before you have to scroll, and some other minor things that were made to make the UI hopefully nicer to look at and mess with. When there's a song to play - While playing, Repeat section can't be edited  Help section and UI when there's no song put in  ## Why It's Good For The Game It is yet another step in finishing up https://hackmd.io/XLt5MoRvRxuhFbwtk4VAUA?view Instruments especially were in a poor spot because they didn't respect things like ``IN_USE`` to not refresh if it's not the "UI" you are on, and such. ## Changelog 🆑 refactor: Instruments now use TGUI. /🆑 --------- Co-authored-by: Ghom <42542238+Ghommie@ users.noreply.github.com> * Instrument editor now uses TGUI --------- Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com> Co-authored-by: Ghom <42542238+Ghommie@ users.noreply.github.com>
27 lines
954 B
Plaintext
27 lines
954 B
Plaintext
#define INSTRUMENT_MIN_OCTAVE 1
|
|
#define INSTRUMENT_MAX_OCTAVE 9
|
|
#define INSTRUMENT_MIN_KEY 0
|
|
#define INSTRUMENT_MAX_KEY 127
|
|
|
|
/// Max number of playing notes per instrument.
|
|
#define CHANNELS_PER_INSTRUMENT 128
|
|
|
|
/// Minimum length a note should ever go for
|
|
#define INSTRUMENT_MIN_TOTAL_SUSTAIN 0.1
|
|
/// Maximum length a note should ever go for
|
|
#define INSTRUMENT_MAX_TOTAL_SUSTAIN (5 SECONDS)
|
|
|
|
/// These are per decisecond.
|
|
#define INSTRUMENT_EXP_FALLOFF_MIN 1.025 //100/(1.025^50) calculated for [INSTRUMENT_MIN_SUSTAIN_DROPOFF] to be 30.
|
|
#define INSTRUMENT_EXP_FALLOFF_MAX 10
|
|
|
|
/// Minimum volume for when the sound is considered dead.
|
|
#define INSTRUMENT_MIN_SUSTAIN_DROPOFF 0
|
|
|
|
#define SUSTAIN_LINEAR "Linear"
|
|
#define SUSTAIN_EXPONENTIAL "Exponential"
|
|
|
|
// /datum/instrument instrument_flags
|
|
#define INSTRUMENT_LEGACY (1<<0) //Legacy instrument. Implies INSTRUMENT_DO_NOT_AUTOSAMPLE
|
|
#define INSTRUMENT_DO_NOT_AUTOSAMPLE (1<<1) //Do not automatically sample
|