Esempio n. 1
0
 public void setMusicPrompt(FMOD.MusicPrompt prompt)
 {
     if (m_prompt == null) {
         m_prompt = prompt;
     }
 }
        public RESULT prepareCue(uint id, ref MusicPrompt prompt)
        {
            RESULT result = RESULT.OK;
            IntPtr mpraw = new IntPtr();
            MusicPrompt mpnew = null;

            try
            {
                result = FMOD_MusicSystem_PrepareCue(musicsystemraw, id, ref mpraw);
            }
            catch
            {
                result = RESULT.ERR_INVALID_PARAM;
            }
            if (result != RESULT.OK)
            {
                return result;
            }

            if (prompt == null)
            {
                mpnew = new MusicPrompt();
                mpnew.setRaw(mpraw);
                prompt = mpnew;
            }
            else
            {
                prompt.setRaw(mpraw);
            }

            return result;
        }
Esempio n. 3
0
    public void loadMusicCue(FmodMusicCue cue)
    {
        if (m_musicSystem != null && !cue.isLoaded()) {
            FMOD.RESULT result = FMOD.RESULT.OK;
            FMOD.MusicPrompt prompt = new FMOD.MusicPrompt();

            result = m_musicSystem.prepareCue((uint)cue.Id, ref prompt);
            if (result == FMOD.RESULT.OK) {
                cue.setMusicPrompt(prompt);
            }
        }
    }