【m】增添Reinitialize()重新初始化方法
This commit is contained in:
@@ -20,6 +20,7 @@ namespace Stary.Evo.AudioCore
|
||||
SFX = new SFXPlayer(audioSourcePool);
|
||||
Music = new MusicPlayer(audioSourcePool);
|
||||
}
|
||||
|
||||
#region 语音
|
||||
|
||||
/// <summary>
|
||||
@@ -118,5 +119,18 @@ namespace Stary.Evo.AudioCore
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 重新初始化
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static void Reinitialize()
|
||||
{
|
||||
if (audioSourcePool == null) Initialize();
|
||||
|
||||
StopVoice();
|
||||
StopAllSFX();
|
||||
StopMusic();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "com.staryevo.audiocore",
|
||||
"version": "1.0.13",
|
||||
"version": "1.0.14",
|
||||
"displayName": "04.AudioCore",
|
||||
"description": "音频播放工具",
|
||||
"unity": "2021.3",
|
||||
|
||||
Reference in New Issue
Block a user