public static HUDSounds Instance()
    {
        if (m_Instance == null)
        {
            m_Instance = new HUDSounds();
            uint _bankID;
            AkSoundEngine.LoadBank("HUD", AkSoundEngine.AK_DEFAULT_POOL_ID, out _bankID);
        }

        return(m_Instance);
    }
    public static HUDSounds Instance()
    {
        if(m_Instance == null)
        {
            m_Instance = new HUDSounds();
            uint _bankID;
            AkSoundEngine.LoadBank("HUD", AkSoundEngine.AK_DEFAULT_POOL_ID, out _bankID);
        }

        return m_Instance;
    }
Example #3
0
        public PaintGunMod(PaintGun_GameSession session) : base(MOD_NAME, session)
        {
            string msg = "### PaintGun v23";

            VRage.Utils.MyLog.Default.WriteLineAndConsole(msg);
            Log.Info(msg);

            session.SetUpdateOrder(MyUpdateOrder.AfterSimulation); // define what update types the modAPI session comp should trigger

            DisablePaintGunVanillaShoot();

            // Systems
            Caches            = new Caches(this);
            Constants         = new Constants(this);
            PlayerHandler     = new PlayerHandler(this);
            NetworkLibHandler = new NetworkLibHandler(this);

            if (IsPlayer)
            {
                TextAPI    = new TextAPI(this);
                DrawUtils  = new DrawUtils(this);
                GameConfig = new GameConfig(this);
            }

            // Features
            Palette  = new Palette(this);
            Painting = new Painting(this);

            if (IsPlayer)
            {
                CheckPlayerField      = new CheckPlayerField(this);
                Settings              = new Settings(this);
                PaletteInputHandler   = new PaletteInputHandler(this);
                PaletteScheduledSync  = new PaletteScheduledSync(this);
                HUDSounds             = new HUDSounds(this);
                LocalToolHandler      = new LocalToolHandler(this);
                LocalToolDescription  = new LocalToolDescription(this);
                SelectionGUI          = new SelectionGUI(this);
                ToolHandler           = new ToolHandler(this);
                ChatCommands          = new ChatCommands(this);
                Notifications         = new Notifications(this);
                PaletteHUD            = new PaletteHUD(this);
                ColorPickerGUIWarning = new ColorPickerGUIWarning(this);
                ConfigMenuHandler     = new ConfigMenuHandler(this);
            }

            if (Constants.EnableTestComponent)
            {
                TestComp = new TestComp(this);
            }
        }
Example #4
0
 void Start()
 {
     MainMenuInit ();
     LevelsInit ();
     buttonSounds = hudController.gameObject.GetComponent<HUDSounds> ();
 }