net.dreditor.audio 0.0.0-stage → 0.1.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.attestation.p7m +0 -0
- package/ClearAudioSourceOnTitleScreen.cs +51 -0
- package/ClearAudioSourceOnTitleScreen.cs.meta +11 -0
- package/CreditsMusic.cs +64 -0
- package/CreditsMusic.cs.meta +11 -0
- package/CreditsMusicUnity.cs +22 -0
- package/CreditsMusicUnity.cs.meta +11 -0
- package/DREditor.Audio.asmdef +19 -0
- package/DREditor.Audio.asmdef.meta +7 -0
- package/EnvironmentSFXMananger.cs +160 -0
- package/EnvironmentSFXMananger.cs.meta +11 -0
- package/EnvironmentSFXManangerBase.cs +24 -0
- package/EnvironmentSFXManangerBase.cs.meta +11 -0
- package/Music.cs +27 -0
- package/Music.cs.meta +11 -0
- package/MusicFMOD.cs +32 -0
- package/MusicFMOD.cs.meta +11 -0
- package/MusicManager.cs +436 -0
- package/MusicManager.cs.meta +11 -0
- package/MusicManagerBase.cs +115 -0
- package/MusicManagerBase.cs.meta +11 -0
- package/MusicSaver.cs +127 -0
- package/MusicSaver.cs.meta +11 -0
- package/MusicTextHandler.cs +119 -0
- package/MusicTextHandler.cs.meta +11 -0
- package/OnVoiceLineSettingChanged.cs +69 -0
- package/OnVoiceLineSettingChanged.cs.meta +11 -0
- package/OptionVolume.cs +76 -0
- package/OptionVolume.cs.meta +11 -0
- package/PlaySelectAudioOnUIChange.cs +42 -0
- package/PlaySelectAudioOnUIChange.cs.meta +11 -0
- package/PlaySubmitSFXOnClick.cs +23 -0
- package/PlaySubmitSFXOnClick.cs.meta +11 -0
- package/Playlist.cs +81 -0
- package/Playlist.cs.meta +11 -0
- package/PlaylistEditor.cs +358 -0
- package/PlaylistEditor.cs.meta +11 -0
- package/PlaylistFMOD.cs +39 -0
- package/PlaylistFMOD.cs.meta +11 -0
- package/SFXManager.cs +348 -0
- package/SFXManager.cs.meta +11 -0
- package/SFXManagerBase.cs +38 -0
- package/SFXManagerBase.cs.meta +11 -0
- package/Samples~/Audio_Event_Save_Handler.prefab +57 -0
- package/Samples~/Audio_Event_Save_Handler.prefab.meta +7 -0
- package/Samples~/Credits_Music_Unity.prefab +66 -0
- package/Samples~/Credits_Music_Unity.prefab.meta +7 -0
- package/Samples~/Dialogue_Click_Sound_Player_DRE.prefab +76 -0
- package/Samples~/Dialogue_Click_Sound_Player_DRE.prefab.meta +7 -0
- package/Samples~/Environment_SFX_Manager.prefab +146 -0
- package/Samples~/Environment_SFX_Manager.prefab.meta +7 -0
- package/Samples~/Environment_SFX_Manager_Shell.prefab +96 -0
- package/Samples~/Environment_SFX_Manager_Shell.prefab.meta +7 -0
- package/Samples~/Environment_Source.prefab +130 -0
- package/Samples~/Environment_Source.prefab.meta +7 -0
- package/Samples~/Music_Manager.prefab +146 -0
- package/Samples~/Music_Manager.prefab.meta +7 -0
- package/Samples~/Music_Manager_Shell.prefab +75 -0
- package/Samples~/Music_Manager_Shell.prefab.meta +7 -0
- package/Samples~/Music_Source.prefab +144 -0
- package/Samples~/Music_Source.prefab.meta +7 -0
- package/Samples~/On_Voice_Line_Setting_Changed.prefab +53 -0
- package/Samples~/On_Voice_Line_Setting_Changed.prefab.meta +7 -0
- package/Samples~/Play_Select_Audio_On_UI_Change.prefab +46 -0
- package/Samples~/Play_Select_Audio_On_UI_Change.prefab.meta +7 -0
- package/Samples~/SFX_Manager.prefab +397 -0
- package/Samples~/SFX_Manager.prefab.meta +7 -0
- package/Samples~/SFX_Manager_Shell.prefab +53 -0
- package/Samples~/SFX_Manager_Shell.prefab.meta +7 -0
- package/Samples~/SFX_Source.prefab +130 -0
- package/Samples~/SFX_Source.prefab.meta +7 -0
- package/Samples~/Select_SFX_On_Setting_Changed.prefab +51 -0
- package/Samples~/Select_SFX_On_Setting_Changed.prefab.meta +7 -0
- package/Samples~/Sound_Manager.prefab +473 -0
- package/Samples~/Sound_Manager.prefab.meta +7 -0
- package/Samples~/Sound_Manager_Events.prefab +261 -0
- package/Samples~/Sound_Manager_Events.prefab.meta +7 -0
- package/Samples~/Sound_Manager_Shell.prefab +370 -0
- package/Samples~/Sound_Manager_Shell.prefab.meta +7 -0
- package/Samples~/Sound_Player_DRE.prefab +47 -0
- package/Samples~/Sound_Player_DRE.prefab.meta +7 -0
- package/Samples~/StopAllAudio.asset +14 -0
- package/Samples~/StopAllAudio.asset.meta +8 -0
- package/Samples~/UI_Cancel_Source.prefab +130 -0
- package/Samples~/UI_Cancel_Source.prefab.meta +7 -0
- package/Samples~/UI_Select_Source.prefab +130 -0
- package/Samples~/UI_Select_Source.prefab.meta +7 -0
- package/Samples~/UI_Submit_Source.prefab +130 -0
- package/Samples~/UI_Submit_Source.prefab.meta +7 -0
- package/Samples~/Voice_SFX_Manager.prefab +146 -0
- package/Samples~/Voice_SFX_Manager.prefab.meta +7 -0
- package/Samples~/Voice_SFX_Manager_Shell.prefab +49 -0
- package/Samples~/Voice_SFX_Manager_Shell.prefab.meta +7 -0
- package/Samples~/Voice_Source.prefab +130 -0
- package/Samples~/Voice_Source.prefab.meta +7 -0
- package/SelectSFXOnSceneEvent.cs +22 -0
- package/SelectSFXOnSceneEvent.cs.meta +11 -0
- package/SoundManager.cs +191 -0
- package/SoundManager.cs.meta +11 -0
- package/SoundManagerBase.cs +73 -0
- package/SoundManagerBase.cs.meta +11 -0
- package/SoundPlayerDRE.cs +27 -0
- package/SoundPlayerDRE.cs.meta +11 -0
- package/SoundPlayerDREUnity.cs +29 -0
- package/SoundPlayerDREUnity.cs.meta +11 -0
- package/SoundService.cs +11 -0
- package/SoundService.cs.meta +11 -0
- package/StopEnvAudioToTitle.cs +17 -0
- package/StopEnvAudioToTitle.cs.meta +11 -0
- package/VOManagerBase.cs +29 -0
- package/VOManagerBase.cs.meta +11 -0
- package/VoiceSFXManager.cs +105 -0
- package/VoiceSFXManager.cs.meta +11 -0
- package/package.json +39 -4
- package/package.json.meta +7 -0
- package/README.md +0 -3
package/.attestation.p7m
ADDED
|
Binary file
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
using UnityEngine;
|
|
3
|
+
using DREditor.Services;
|
|
4
|
+
|
|
5
|
+
#if FMOD_UNITY
|
|
6
|
+
using FMODUnity;
|
|
7
|
+
#endif
|
|
8
|
+
|
|
9
|
+
namespace DREditor.Audio
|
|
10
|
+
{
|
|
11
|
+
/// <summary>
|
|
12
|
+
///
|
|
13
|
+
/// </summary>
|
|
14
|
+
[ClassHeader(nameof(IToTitleScreen) +
|
|
15
|
+
"\n\n")]
|
|
16
|
+
public class ClearAudioSourceOnTitleScreen : MonoBehaviour, IToTitleScreen
|
|
17
|
+
{
|
|
18
|
+
#if FMOD_UNITY
|
|
19
|
+
/// <summary>
|
|
20
|
+
///
|
|
21
|
+
/// </summary>
|
|
22
|
+
[Tooltip("")]
|
|
23
|
+
[SerializeField] protected StudioEventEmitter audioSource = null;
|
|
24
|
+
#else
|
|
25
|
+
/// <summary>
|
|
26
|
+
///
|
|
27
|
+
/// </summary>
|
|
28
|
+
[Tooltip("")]
|
|
29
|
+
[SerializeField] protected AudioSource audioSource = null;
|
|
30
|
+
#endif
|
|
31
|
+
|
|
32
|
+
/// <inheritdoc/>
|
|
33
|
+
public virtual void ToTitleScreen()
|
|
34
|
+
{
|
|
35
|
+
if (audioSource != null)
|
|
36
|
+
ClearSource();
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/// <summary>
|
|
40
|
+
///
|
|
41
|
+
/// </summary>
|
|
42
|
+
protected virtual void ClearSource()
|
|
43
|
+
{
|
|
44
|
+
#if FMOD_UNITY
|
|
45
|
+
audioSource.Event = "";
|
|
46
|
+
#else
|
|
47
|
+
audioSource.clip = null;
|
|
48
|
+
#endif
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
package/CreditsMusic.cs
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
using DREditor.EventObjects;
|
|
3
|
+
using DREditor.Services;
|
|
4
|
+
using System.Collections;
|
|
5
|
+
using System.Collections.Generic;
|
|
6
|
+
using UnityEngine;
|
|
7
|
+
|
|
8
|
+
namespace DREditor.Audio
|
|
9
|
+
{
|
|
10
|
+
/// <summary>
|
|
11
|
+
///
|
|
12
|
+
/// </summary>
|
|
13
|
+
public abstract class CreditsMusic : MonoBehaviour
|
|
14
|
+
{
|
|
15
|
+
/// <summary>
|
|
16
|
+
///
|
|
17
|
+
/// </summary>
|
|
18
|
+
[Tooltip("")]
|
|
19
|
+
[SerializeField] protected SceneEventListener onLeavingCredits = null;
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
/// <summary>
|
|
23
|
+
///
|
|
24
|
+
/// </summary>
|
|
25
|
+
protected abstract void Start();
|
|
26
|
+
|
|
27
|
+
/// <summary>
|
|
28
|
+
///
|
|
29
|
+
/// </summary>
|
|
30
|
+
protected virtual void OnEnable() => onLeavingCredits.Response.AddListener(FadeMusicOnLeaving);
|
|
31
|
+
|
|
32
|
+
/// <summary>
|
|
33
|
+
///
|
|
34
|
+
/// </summary>
|
|
35
|
+
protected virtual void OnDisable() => onLeavingCredits.Response.RemoveListener(FadeMusicOnLeaving);
|
|
36
|
+
|
|
37
|
+
/// <summary>
|
|
38
|
+
///
|
|
39
|
+
/// </summary>
|
|
40
|
+
protected virtual void FadeMusicOnLeaving() => ServiceLocator.GetService<MusicManagerBase>().FadeMusic();
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
/// <summary>
|
|
44
|
+
///
|
|
45
|
+
/// </summary>
|
|
46
|
+
/// <typeparam name="T"></typeparam>
|
|
47
|
+
/// <param name="musicEvents"></param>
|
|
48
|
+
/// <returns></returns>
|
|
49
|
+
protected virtual IEnumerator PlayMusicTracks<T>(List<T> musicEvents)
|
|
50
|
+
{
|
|
51
|
+
for (int i = 0; i < musicEvents.Count; i++)
|
|
52
|
+
{
|
|
53
|
+
ServiceLocator.GetService<MusicManagerBase>().PlayMusic(musicEvents[i], true);
|
|
54
|
+
|
|
55
|
+
yield return new WaitUntil(() => ServiceLocator.GetService<MusicManagerBase>().MusicIsPlaying());
|
|
56
|
+
|
|
57
|
+
while (ServiceLocator.GetService<MusicManagerBase>().MusicIsPlaying())
|
|
58
|
+
yield return null;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
yield break;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
using System.Collections.Generic;
|
|
3
|
+
using UnityEngine;
|
|
4
|
+
|
|
5
|
+
namespace DREditor.Audio
|
|
6
|
+
{
|
|
7
|
+
/// <summary>
|
|
8
|
+
///
|
|
9
|
+
/// </summary>
|
|
10
|
+
public class CreditsMusicUnity : CreditsMusic
|
|
11
|
+
{
|
|
12
|
+
/// <summary>
|
|
13
|
+
///
|
|
14
|
+
/// </summary>
|
|
15
|
+
[Tooltip("")]
|
|
16
|
+
[SerializeField] protected List<AudioClip> musicEvents = new();
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
/// <inheritdoc/>
|
|
20
|
+
protected override void Start() => StartCoroutine(PlayMusicTracks(musicEvents));
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "DREditor.Audio",
|
|
3
|
+
"rootNamespace": "",
|
|
4
|
+
"references": [
|
|
5
|
+
"FMODUnity",
|
|
6
|
+
"DREditor",
|
|
7
|
+
"Unity.TextMeshPro",
|
|
8
|
+
"DREditor.EventObjectServices"
|
|
9
|
+
],
|
|
10
|
+
"includePlatforms": [],
|
|
11
|
+
"excludePlatforms": [],
|
|
12
|
+
"allowUnsafeCode": false,
|
|
13
|
+
"overrideReferences": false,
|
|
14
|
+
"precompiledReferences": [],
|
|
15
|
+
"autoReferenced": true,
|
|
16
|
+
"defineConstraints": [],
|
|
17
|
+
"versionDefines": [],
|
|
18
|
+
"noEngineReferences": false
|
|
19
|
+
}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
using DREditor.Saving;
|
|
3
|
+
using System.Collections.Generic;
|
|
4
|
+
#if !FMOD_UNITY
|
|
5
|
+
using System.Linq;
|
|
6
|
+
#endif
|
|
7
|
+
using UnityEngine;
|
|
8
|
+
#if FMOD_UNITY
|
|
9
|
+
using FMODUnity;
|
|
10
|
+
#endif
|
|
11
|
+
|
|
12
|
+
namespace DREditor.Audio
|
|
13
|
+
{
|
|
14
|
+
/// <summary>
|
|
15
|
+
///
|
|
16
|
+
/// </summary>
|
|
17
|
+
[ClassHeader(nameof(EnvironmentSFXManangerBase) + ", " + nameof(IDRESaveable) + ", " + nameof(IDRELoadable) +
|
|
18
|
+
"\n\n")]
|
|
19
|
+
public class EnvironmentSFXMananger : EnvironmentSFXManangerBase, IDRESaveable, IDRELoadable
|
|
20
|
+
{
|
|
21
|
+
/// <summary>
|
|
22
|
+
///
|
|
23
|
+
/// </summary>
|
|
24
|
+
[Header("")]
|
|
25
|
+
[Divider]
|
|
26
|
+
[Tooltip("")]
|
|
27
|
+
[SerializeField] bool debugLogs = false;
|
|
28
|
+
#if FMOD_UNITY
|
|
29
|
+
/// <summary>
|
|
30
|
+
///
|
|
31
|
+
/// </summary>
|
|
32
|
+
[Tooltip("")]
|
|
33
|
+
[EventRef][SerializeField] protected string LastPlayedEnv = "";
|
|
34
|
+
#else
|
|
35
|
+
/// <summary>
|
|
36
|
+
///
|
|
37
|
+
/// </summary>
|
|
38
|
+
[Tooltip("")]
|
|
39
|
+
[SerializeField] protected AudioClip LastPlayedEnv = null;
|
|
40
|
+
#endif
|
|
41
|
+
|
|
42
|
+
[Header("")]
|
|
43
|
+
[Divider]
|
|
44
|
+
#if FMOD_UNITY
|
|
45
|
+
/// <summary>
|
|
46
|
+
///
|
|
47
|
+
/// </summary>
|
|
48
|
+
[Tooltip("")]
|
|
49
|
+
[SerializeField] protected StudioEventEmitter environmentSFXSource = null;
|
|
50
|
+
#else
|
|
51
|
+
/// <summary>
|
|
52
|
+
///
|
|
53
|
+
/// </summary>
|
|
54
|
+
[Tooltip("")]
|
|
55
|
+
[SerializeField] protected AudioSource environmentSFXSource = null;
|
|
56
|
+
#endif
|
|
57
|
+
/// <summary>
|
|
58
|
+
///
|
|
59
|
+
/// </summary>
|
|
60
|
+
[Tooltip("")]
|
|
61
|
+
[SerializeField] protected List<AudioClip> envSounds = new();
|
|
62
|
+
|
|
63
|
+
/// <summary>
|
|
64
|
+
///
|
|
65
|
+
/// </summary>
|
|
66
|
+
[Tooltip("")]
|
|
67
|
+
[SerializeField] protected string envSaveKey = "EnvData";
|
|
68
|
+
|
|
69
|
+
/// <inheritdoc/>
|
|
70
|
+
protected override void InitializeService()
|
|
71
|
+
{
|
|
72
|
+
base.InitializeService();
|
|
73
|
+
#if FMOD_UNITY
|
|
74
|
+
if (environmentSFXSource == null)
|
|
75
|
+
environmentSFXSource = GetComponentInChildren<StudioEventEmitter>();
|
|
76
|
+
#else
|
|
77
|
+
if (environmentSFXSource == null)
|
|
78
|
+
environmentSFXSource = GetComponentInChildren<AudioSource>();
|
|
79
|
+
#endif
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/// <inheritdoc/>
|
|
83
|
+
public override void PlayEnv<T>(T name)
|
|
84
|
+
{
|
|
85
|
+
#if FMOD_UNITY
|
|
86
|
+
if (name is string eventName && eventName != "")
|
|
87
|
+
{
|
|
88
|
+
environmentSFXSource.Stop();
|
|
89
|
+
|
|
90
|
+
environmentSFXSource.Event = eventName;
|
|
91
|
+
|
|
92
|
+
LastPlayedEnv = eventName;
|
|
93
|
+
|
|
94
|
+
environmentSFXSource.Play();
|
|
95
|
+
|
|
96
|
+
if (debugLogs)
|
|
97
|
+
UnityEngine.Debug.LogWarning("REPORT: Playing Environment: " + eventName);
|
|
98
|
+
}
|
|
99
|
+
#else
|
|
100
|
+
if (name is AudioClip clip && clip != null)
|
|
101
|
+
{
|
|
102
|
+
environmentSFXSource.Stop();
|
|
103
|
+
|
|
104
|
+
environmentSFXSource.clip = clip;
|
|
105
|
+
|
|
106
|
+
LastPlayedEnv = clip;
|
|
107
|
+
|
|
108
|
+
environmentSFXSource.Play();
|
|
109
|
+
|
|
110
|
+
if (debugLogs)
|
|
111
|
+
UnityEngine.Debug.LogWarning("Playing Environment: " + clip);
|
|
112
|
+
}
|
|
113
|
+
#endif
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
/// <inheritdoc/>
|
|
117
|
+
public override void StopEnv()
|
|
118
|
+
{
|
|
119
|
+
if (debugLogs)
|
|
120
|
+
UnityEngine.Debug.LogWarning("REPORT: Reset Environment SFX.");
|
|
121
|
+
#if FMOD_UNITY
|
|
122
|
+
LastPlayedEnv = "";
|
|
123
|
+
#else
|
|
124
|
+
LastPlayedEnv = null;
|
|
125
|
+
#endif
|
|
126
|
+
environmentSFXSource.Stop();
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
#if FMOD_UNITY
|
|
130
|
+
/// <inheritdoc/>
|
|
131
|
+
public virtual void Save(Dictionary<string, object> saveDatas) => saveDatas[envSaveKey] = LastPlayedEnv;
|
|
132
|
+
#else
|
|
133
|
+
public virtual void Save(Dictionary<string, object> saveData) => saveData[envSaveKey] = LastPlayedEnv.name;
|
|
134
|
+
#endif
|
|
135
|
+
/// <inheritdoc/>
|
|
136
|
+
public virtual void Load(Dictionary<string, object> saveDatas) => LoadEnv(saveDatas[envSaveKey]);
|
|
137
|
+
|
|
138
|
+
/// <summary>
|
|
139
|
+
///
|
|
140
|
+
/// </summary>
|
|
141
|
+
/// <typeparam name="T"></typeparam>
|
|
142
|
+
/// <param name="name"></param>
|
|
143
|
+
protected virtual void LoadEnv<T>(T name)
|
|
144
|
+
{
|
|
145
|
+
#if FMOD_UNITY
|
|
146
|
+
if (name is string loadName)
|
|
147
|
+
if (loadName == "" && debugLogs)
|
|
148
|
+
UnityEngine.Debug.LogWarning("ALERT: Couldn't find Saved Ambience, no Environment sound playing.");
|
|
149
|
+
else if (loadName != "")
|
|
150
|
+
PlayEnv(loadName);
|
|
151
|
+
#else
|
|
152
|
+
if (name is string loadName)
|
|
153
|
+
if (loadName == null && debugLogs)
|
|
154
|
+
UnityEngine.Debug.LogWarning("ALERT: Couldn't find Saved Ambience, no Environment sound playing.");
|
|
155
|
+
else if (loadName != null)
|
|
156
|
+
envSounds.FirstOrDefault(clip => clip.name == loadName);
|
|
157
|
+
#endif
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
|
|
3
|
+
namespace DREditor.Audio
|
|
4
|
+
{
|
|
5
|
+
/// <summary>
|
|
6
|
+
///
|
|
7
|
+
/// </summary>
|
|
8
|
+
/// <remarks></remarks>
|
|
9
|
+
public abstract class EnvironmentSFXManangerBase : SoundService<EnvironmentSFXManangerBase>
|
|
10
|
+
{
|
|
11
|
+
/// <summary>
|
|
12
|
+
///
|
|
13
|
+
/// </summary>
|
|
14
|
+
/// <typeparam name="T"></typeparam>
|
|
15
|
+
/// <param name="eventName"></param>
|
|
16
|
+
public abstract void PlayEnv<T>(T eventName);
|
|
17
|
+
|
|
18
|
+
/// <summary>
|
|
19
|
+
///
|
|
20
|
+
/// </summary>
|
|
21
|
+
/// <remarks></remarks>
|
|
22
|
+
public abstract void StopEnv();
|
|
23
|
+
}
|
|
24
|
+
}
|
package/Music.cs
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
//DRPlaylist script Author: SeleniumSoul for DREditor
|
|
2
|
+
using UnityEngine;
|
|
3
|
+
|
|
4
|
+
namespace DREditor.Audio
|
|
5
|
+
{
|
|
6
|
+
/// <summary>
|
|
7
|
+
///
|
|
8
|
+
/// </summary>
|
|
9
|
+
[System.Serializable]
|
|
10
|
+
public class Music
|
|
11
|
+
{
|
|
12
|
+
/// <summary>
|
|
13
|
+
///
|
|
14
|
+
/// </summary>
|
|
15
|
+
[SerializeField] protected string title;
|
|
16
|
+
|
|
17
|
+
/// <summary>
|
|
18
|
+
///
|
|
19
|
+
/// </summary>
|
|
20
|
+
public string Title { set { title = value; } get { return title; } }
|
|
21
|
+
|
|
22
|
+
/// <summary>
|
|
23
|
+
///
|
|
24
|
+
/// </summary>
|
|
25
|
+
public AudioClip BGM;
|
|
26
|
+
}
|
|
27
|
+
}
|
package/Music.cs.meta
ADDED
package/MusicFMOD.cs
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
//Author: Benjamin "Sweden" Jillson : Discord: sweden_gaming For Project Eden's Garden
|
|
2
|
+
#if FMOD_UNITY
|
|
3
|
+
using FMODUnity;
|
|
4
|
+
using UnityEngine;
|
|
5
|
+
using UnityEngine.Serialization;
|
|
6
|
+
|
|
7
|
+
namespace DREditor.Audio
|
|
8
|
+
{
|
|
9
|
+
/// <summary>
|
|
10
|
+
///
|
|
11
|
+
/// </summary>
|
|
12
|
+
[System.Serializable]
|
|
13
|
+
public class MusicFMOD
|
|
14
|
+
{
|
|
15
|
+
/// <summary>
|
|
16
|
+
///
|
|
17
|
+
/// </summary>
|
|
18
|
+
[FormerlySerializedAs("Title")]
|
|
19
|
+
[SerializeField] protected string title;
|
|
20
|
+
|
|
21
|
+
/// <summary>
|
|
22
|
+
///
|
|
23
|
+
/// </summary>
|
|
24
|
+
public string Title { set { title = value; } get { return title; } }
|
|
25
|
+
|
|
26
|
+
/// <summary>
|
|
27
|
+
///
|
|
28
|
+
/// </summary>
|
|
29
|
+
[EventRef] public string BGM;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
#endif
|