Exemplo n.º 1
0
    // fileName为sound文件夹的相对路径,
    public static void PLAY_AUDIO_WINDOW(txUIObject obj, string fileName, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = mCommandSystem.newCmd <CommandWindowPlayAudio>(false);

        cmd.mSoundFileName = fileName;
        cmd.mLoop          = loop;
        cmd.mVolume        = volume;
        mCommandSystem.pushCommand(cmd, obj);
    }
Exemplo n.º 2
0
    //--------------------------------------------------------------------------------------------------------------------------------------------------------
    // 音效
    public static void PLAY_AUDIO_WINDOW(txUIObject obj, SOUND_DEFINE sound, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = mCommandSystem.newCmd <CommandWindowPlayAudio>(false);

        cmd.mSound  = sound;
        cmd.mLoop   = loop;
        cmd.mVolume = volume;
        mCommandSystem.pushCommand(cmd, obj);
    }
Exemplo n.º 3
0
    // fileName为sound文件夹的相对路径,
    public static void PLAY_AUDIO(txUIObject obj, string fileName, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = newCmd(out cmd, false);

        cmd.mSoundFileName = fileName;
        cmd.mLoop          = loop;
        cmd.mVolume        = volume;
        pushCommand(cmd, obj);
    }
Exemplo n.º 4
0
    public static void PLAY_AUDIO(txUIObject obj, SOUND_DEFINE sound, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = newCmd(out cmd, false);

        cmd.mSound  = sound;
        cmd.mLoop   = loop;
        cmd.mVolume = volume;
        pushCommand(cmd, obj);
    }
Exemplo n.º 5
0
    public static void PLAY_AUDIO_WINDOW_DELAY(LayoutScript script, txUIObject obj, float delayTime, SOUND_DEFINE sound, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = mCommandSystem.newCmd <CommandWindowPlayAudio>(false, true);

        cmd.mSound  = sound;
        cmd.mLoop   = loop;
        cmd.mVolume = volume;
        mCommandSystem.pushDelayCommand(cmd, obj, delayTime);
        script.addDelayCmd(cmd);
    }
Exemplo n.º 6
0
    public static CommandWindowPlayAudio PLAY_AUDIO_DELAY(LayoutScript script, txUIObject obj, float delayTime, SOUND_DEFINE sound, bool loop, float volume)
    {
        CommandWindowPlayAudio cmd = newCmd(out cmd, false, true);

        cmd.mSound  = sound;
        cmd.mLoop   = loop;
        cmd.mVolume = volume;
        pushDelayCommand(cmd, obj, delayTime);
        script.addDelayCmd(cmd);
        return(cmd);
    }