Changed Awake/Start to OnAwake
This commit is contained in:
@@ -19,7 +19,7 @@ public class AppleAudioSource : MonoBehaviour
|
|||||||
public int sourcePriority;
|
public int sourcePriority;
|
||||||
|
|
||||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||||
void Start()
|
void OnEnable()
|
||||||
{
|
{
|
||||||
audioSource = GetComponent<AudioSource>();
|
audioSource = GetComponent<AudioSource>();
|
||||||
AudioManager.Instance.RegisterNewAudioSource(this);
|
AudioManager.Instance.RegisterNewAudioSource(this);
|
||||||
@@ -29,10 +29,6 @@ public class AppleAudioSource : MonoBehaviour
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Awake()
|
|
||||||
{
|
|
||||||
Start();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void InitializeAudioSource()
|
public void InitializeAudioSource()
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user