Advertisement
Guest User

Untitled

a guest
Aug 28th, 2015
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. using UnityEngine;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4.  
  5. public class GameSystem : MonoBehaviour {
  6.  
  7. void Start()
  8. {
  9. //Always call the init function first to use SoundsManager component
  10. SoundsManager.init();
  11.  
  12.  
  13. SoundsManager.instance.PlaySound (SoundsManager.AUDIO_INGAME, new Dictionary<string, object>{
  14. {SoundsManager.AUDIO_OPT_FADEIN,true},
  15. {SoundsManager.AUDIO_OPT_LOOP,true},
  16. {SoundsManager.AUDIO_OPT_VOLUME,0.5}
  17. });
  18. }
  19.  
  20. void OnDestroy()
  21. {
  22. SoundsManager.instance.FadeOutSound (SoundsManager.AUDIO_INGAME);
  23. }
  24. }
  25.  
  26. /*
  27. CREDIT
  28. ihsanberahim.com
  29. fiction-labs.com
  30. pkmedia.com.my
  31. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement