Example #1
0
    //------------------------------------------------------------------------

    /*!
     *  @brief		更新処理
     */
    //------------------------------------------------------------------------
    public void Open(uint id)
    {
        SoundUtil.PlaySE(SEID.SE_BATLE_UI_OPEN);
        m_CharaId = id;
        m_Open    = true;

        initPanel();

        Label_text = GameTextUtil.GetText("battle_infotext4");

        //「ENEMY INFO」テキスト差し替え
        {
            uint area_category_id = ReplaceAssetManager.getAreaCategoryIDFromQuestID(BattleParam.m_QuestMissionID); //MainMenuParam.m_RegionIDからは直接は取らない(中断復帰時対策)
            MasterDataQuestAppearance[] questAppearance = MasterFinder <MasterDataQuestAppearance> .Instance.SelectWhere("where area_category_id = ?", area_category_id).ToArray();

            if (questAppearance.IsNullOrEmpty() == false)
            {
                //Label_text = GameTextUtil.GetText(questAppearance[0].enemy_info_text_key);
                // テキストキーではなく直接テキストが入っている
                Label_text = questAppearance[0].enemy_info_text_key;
            }
        }

        m_TargetWindowStep = eTargetWindowStep.OPEN_INIT;
    }
Example #2
0
    public void Hide()
    {
        if (m_Ready == false)
        {
            return;
        }
        m_Ready = false;

        SoundUtil.PlaySE(SEID.SE_MENU_RET);

        if (AndroidBackKeyManager.HasInstance)
        {
            //バックキーが押された時のアクションを解除
            AndroidBackKeyManager.Instance.StackPop(gameObject);
        }

        ShadowPanel.GetComponent <Image>().DOFade(FadeHideAlpha, AnimationTime);

        //Window.transform.DOScaleY(WindowHideScale, AnimationTime).OnComplete(() =>
        Window.GetComponent <RectTransform>().DOAnchorPosX(601, AnimationTime).OnComplete(() =>
        {
            if (hideAction != null)
            {
                hideAction();
            }
            DestroyObject(gameObject);
        });
    }
Example #3
0
 public void OnChangedSnapCarousel(bool isChange)
 {
     if (isChange == true)
     {
         SoundUtil.PlaySE(SEID.SE_MM_A03_TAB);
     }
 }
    void OpenLineUp(MasterDataStepUpGachaManage stepupgachamanage, uint assign_id)
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK);

        m_Canvas.enabled = false;

        string title = GameTextUtil.GetText("gacha_lineup_title1");

        if (stepupgachamanage.special_assign_id != 0 &&
            stepupgachamanage.special_assign_id == assign_id)
        {
            title = GameTextUtil.GetText("gacha_lineup_title2");
        }

        // タイトルにステップ数追加
        if (stepupgachamanage.step_num == 0)
        {
            // 初回ステップ
            title += GameTextUtil.GetText("gacha_lineup_step1");
        }
        else
        {
            title += string.Format(GameTextUtil.GetText("gacha_lineup_step2"), stepupgachamanage.step_num);
        }

        ScratchLineUpDialog lineupdialog = ScratchLineUpDialog.Create();

        lineupdialog.SetCamera(SceneObjReferMainMenu.Instance.m_MainMenuGroupCamera.GetComponent <Camera>());
        lineupdialog.setup(m_GachaMaster, stepupgachamanage, assign_id, true, title);
        lineupdialog.m_CloseAction = () =>
        {
            m_Canvas.enabled = true;
        };
    }
Example #5
0
 public override bool OnPickup(Player player)
 {
     SoundUtil.PlayVanillaSound(SoundID.NPCDeath7, player);
     MyPlayer.ModPlayer(player).AddKi(MyPlayer.ModPlayer(player).OrbHealAmount, false, false);
     CombatText.NewText(new Rectangle((int)player.position.X, (int)player.position.Y, player.width, player.height), new Color(51, 204, 255), 50, false, false);
     return(false);
 }
    /// <summary>
    /// 合并成功处理
    /// </summary>
    public void mergeDeal(float mergeAnimDuration)
    {
        transform.DOScale(new Vector3(1, 1, 1), mergeAnimDuration).OnComplete
            (delegate()
        {
            if (gameObject.GetComponent <CompositeCollider2D>() == null)
            {
                CompositeCollider2D collider2D = gameObject.AddComponent <CompositeCollider2D>();
                collider2D.geometryType        = CompositeCollider2D.GeometryType.Polygons;
                collider2D.generationType      = CompositeCollider2D.GenerationType.Synchronous;
            }

            //合并特效
            if (gameParticleControl != null)
            {
                //gameParticleControl.playMergeParticle(transform);
            }
            //摇晃镜头
            shakeCamer();
            SoundUtil.playSoundClipForMerge();
            //让缸体恢复移动
            Rigidbody2D thisRB = transform.GetComponent <Rigidbody2D>();
            if (thisRB != null)
            {
                thisRB.constraints = RigidbodyConstraints2D.None;
            }
            CommonData.IsDargMove = true;
            //检测是否完成游戏
            checkFinshGame();
        }
            );
    }
    public void OnSelectFriend(FriendDataItem _unit)
    {
        if (!m_FixFriendUnit ||
            m_FixFriendLinkUnit)
        {
            int _index = UserDataAdmin.Instance.SearchHelperIndex(_unit.FriendData.user_id);
            if (_index == -1)
            {
                return;
            }
        }

        SoundUtil.PlaySE(SEID.SE_MENU_OK2);

        m_SelectFriend = _unit.FriendData;

        Dialog dlg = Dialog.Create(DialogType.DialogUnit);
        dlg.setUnitInfo(m_SelectFriend);
        dlg.SetDialogText(DialogTextType.Title, m_SelectFriend.user_name);
        dlg.SetDialogText(DialogTextType.SubTitle, string.Format(GameTextUtil.GetText("questfriend_text1"), m_SelectFriend.user_rank.ToString()));
        dlg.SetDialogTextFromTextkey(DialogTextType.YesText, "common_button7");
        dlg.SetDialogEvent(DialogButtonEventType.YES, () =>
        {
            startQuest();
        });
        dlg.SetDialogTextFromTextkey(DialogTextType.NoText, "common_button1");
        dlg.Show();
    }
Example #8
0
    private void OnSelectBoss(int index)
    {
        if (index < 0 ||
            m_bReady == false)
        {
            return;
        }

        if (m_SelectIndex == index)
        {
            return;
        }

        SoundUtil.PlaySE(SEID.SE_MM_A03_TAB);

        m_bReady = false;

        m_SelectIndex = index;

        float movePos = BOSS_POS_OFFSET * (m_Events.Count - index - 1);

        moveBossPos(movePos, () =>
        {
            //ボタン状態更新
            updateButton();

            //背景BG更新
            LoadBackgroundTexture().Load();

            //ボス変更コールバック
            OnChengedBoss(m_Events[m_SelectIndex]);

            m_bReady = true;
        });
    }
Example #9
0
    public bool IsCangeTime()
    {
        // public MAINMENU_SEQ getReplaceNextPage(MAINMENU_SEQ eNextPage)
        // copy
        if (MainMenuParam.m_ReturnTitleTime != DateTime.MaxValue &&
            TimeManager.Instance != null &&
            TimeManager.Instance.m_TimeNow != null)
        {
            //--------------------------------
            // タイトルログイン時に設定された時間をすぎたらタイトルに戻す
            //--------------------------------
            if (TimeManager.Instance.m_TimeNow >= MainMenuParam.m_ReturnTitleTime)
            {
                DialogManager.Open1B("CHANGE_DAY", "CHANGE_DAY_DETAIL", "common_button1", true, false).
                SetOkEvent(() =>
                {
                    SceneCommon.Instance.GameToTitle();
                    SoundUtil.PlaySE(SEID.SE_MENU_OK2);
                });

                return(true);
            }
        }

        return(false);
    }
Example #10
0
    public void Hide()
    {
        if (m_Ready == false)
        {
            return;
        }
        m_Ready = false;

        SoundUtil.PlaySE(SEID.SE_MENU_RET);

        if (AndroidBackKeyManager.HasInstance)
        {
            //バックキーが押された時のアクションを解除
            AndroidBackKeyManager.Instance.StackPop(gameObject);
        }

        if (hideAction != null)
        {
            hideAction(scoreInfo);
        }

        gameObject.transform.DOScaleY(WindowHideScale, AnimationTime).OnComplete(() =>
        {
            RewardList.Clear();
            UnityUtil.SetObjectEnabledOnce(gameObject, false);
            m_Show = false;
        });
    }
Example #11
0
 public IconLevelUpEffect Show()
 {
     SoundUtil.PlaySE(SEID.SE_MM_D04_LEVEL_UP);
     SoundUtil.PlaySE(SEID.VOICE_INGAME_MM_LEVELUP);
     PlayAnimation(AnimationName);
     return(this);
 }
Example #12
0
    public void OnSelectTab(int index)
    {
        if (TabIndex == index)
        {
            return;
        }

        SoundUtil.PlaySE(SEID.SE_MENU_OK);

        TabIndex = index;

        switch (TabIndex)
        {
        case 0:
            IsViewGetAll = false;
            break;

        case 1:
        {
            IsViewGetAll   = true;
            IsActiveGetAll = (RewardList.Count != 0) ? true : false;
        }
        break;
        }

        setScrollTop();
        scrollContent.resetCurrtent();
        scrollContent.Initialize(this);
    }
Example #13
0
        private void autocorrelationButton_Click(object sender, EventArgs e)
        {
            if (_audio != null)
            {
                actionStateLabel.Text = "PROCESSING";
                List <int> frequencies = _audio.Autocorrelation();
                string     freqText    = "";

                foreach (int freq in frequencies)
                {
                    freqText += freq.ToString() + " Hz (T = " + (1.0f / freq) + " s), ";
                }

                actionStateLabel.Text = "";
                CharWindow autoCorelation = new CharWindow();
                autoCorelation.setPropert();

                autoCorelation.Histogram.Series.Add("AutoCorelation");
                autoCorelation.Text = "AutoCorelation";
                autoCorelation.Histogram.Series["AutoCorelation"].ChartType  = System.Windows.Forms.DataVisualization.Charting.SeriesChartType.FastLine;
                autoCorelation.Histogram.Series["AutoCorelation"].MarkerSize = 2;
                autoCorelation.Histogram.ChartAreas[0].AxisX.Title           = "Index";
                autoCorelation.Histogram.ChartAreas[0].AxisY.Title           = "AutoCorelation value";

                for (int i = 0; i < _audio.autoCorrelations[0].Count(); i++)
                {
                    autoCorelation.Histogram.Series["AutoCorelation"].Points.AddXY(i, _audio.autoCorrelations[0][i] / (32768.0f * 32768.0f * 100));
                }

                autoCorelation.Show();

                SoundUtil.SaveSound(_audio.fileName, _audio.sampleRate, _audio.chunkSize, frequencies);
                MessageBox.Show(freqText, "Autocorrelation frequencies");
            }
        }
Example #14
0
    void OnGameDataDelete()
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK);
        Dialog newDialog = Dialog.Create(DialogType.DialogYesNo).SetStrongYes();

        newDialog.SetDialogTextFromTextkey(DialogTextType.Title, "he177q_title");
        newDialog.SetDialogTextFromTextkey(DialogTextType.MainText, "he177q_content");
        newDialog.SetDialogTextFromTextkey(DialogTextType.YesText, "common_button4");
        newDialog.SetDialogTextFromTextkey(DialogTextType.NoText, "common_button5");
        newDialog.SetDialogEvent(DialogButtonEventType.YES, () =>
        {
            Dialog nextDialog = Dialog.Create(DialogType.DialogYesNo).SetStrongYes();
            nextDialog.SetDialogTextFromTextkey(DialogTextType.Title, "he178q_title");
            nextDialog.SetDialogTextFromTextkey(DialogTextType.MainText, "he178q_content");
            nextDialog.SetDialogTextFromTextkey(DialogTextType.YesText, "common_button4");
            nextDialog.SetDialogTextFromTextkey(DialogTextType.NoText, "common_button5");
            nextDialog.SetDialogEvent(DialogButtonEventType.YES, () =>
            {
                SendUserRenew();
            });
            nextDialog.EnableFadePanel();
            nextDialog.DisableCancelButton();
            nextDialog.Show();
        });
        newDialog.EnableFadePanel();
        newDialog.DisableCancelButton();
        newDialog.Show();
    }
Example #15
0
 /// <summary>
 /// API結果:失敗:ユーザー削除
 /// </summary>
 void SendUserRenewError(ServerApi.ResultData _data)
 {
     if (_data.m_PacketCode == API_CODE.API_CODE_USER_CREATE_UUID_ERR)
     {
         //----------------------------------------
         // UUIDが既に使われている
         // →UUIDの再構築は内部的に行われるので、再度トライしてみる
         //----------------------------------------
         SendUserRenew();
     }
     else
     {
         Dialog newDialog = Dialog.Create(DialogType.DialogOK);
         newDialog.SetDialogTextFromTextkey(DialogTextType.Title, "ERROR_MSG_WIDEUSE_TITLE");
         newDialog.SetDialogTextFromTextkey(DialogTextType.MainText, "ERROR_MSG_WIDEUSE");
         newDialog.SetDialogTextFromTextkey(DialogTextType.OKText, "common_button1");
         newDialog.SetDialogEvent(DialogButtonEventType.OK, new System.Action(() =>
         {
         }));
         newDialog.EnableFadePanel();
         newDialog.DisableCancelButton();
         newDialog.Show();
         SoundUtil.PlaySE(SEID.SE_MENU_NG);
     }
 }
    public void TakeDamage(int count)
    {
        if (IsInvlunerable)
        {
            return;
        }

        int newLifeCount = LifeCount - count;

        if (newLifeCount < 0)
        {
            // Start respawn
            _respawnPos    = GameManager.Instance.LevelGenerator.GetRespawnPosition(this.gameObject);
            _respawnPos.z  = transform.position.z;
            _timeToRespawn = Vector3.Distance(transform.position, _respawnPos) / RespawnSpeed;
            _respawnDir    = (_respawnPos - transform.position).normalized;
            ToggleRespawning(true);
        }
        else
        {
            var cameraController = GameManager.Instance.Cameras[PlayerId].GetComponent <CameraController>();
            if (cameraController)
            {
                cameraController.Shake(0.15f, 0.15f);
            }

            BloodParticleSystem.Stop();
            BloodParticleSystem.Play();

            Instantiate(HeartSpawner, transform.position, Quaternion.identity);
        }
        LifeCount = newLifeCount;

        SoundUtil.PlayRandomSound(HitSounds, _audioSource);
    }
    //----------------------------------------------------------------------------

    /*!
     *          @brief	進化演出ステップ:「Evolve!」を表示
     *          @note
     */
    //----------------------------------------------------------------------------
    void ExecStep_110_EvolveMsg()
    {
        //-------------------
        // トリガー処理
        //-------------------
        if (m_WorkStepTriger == true)
        {
            m_LayoutEvolve.AddSwitchRequest(LAYER_EVOLVE_ACTIVE, false);

            //----------------------------------------
            // 進化ボイス再生
            //----------------------------------------
            SoundUtil.PlaySE(SEID.VOICE_INGAME_MM_EVOLVE);


            //----------------------------------------
            // SE再生
            //----------------------------------------
            SoundUtil.PlaySE(SEID.SE_MM_D10_EVOLVE_COMP);
        }

        //-------------------
        // 更新完遂待ち
        //-------------------
        m_WorkStepDelta += Time.deltaTime;
        if (m_WorkStepDelta >= 0.5f)
        {
            m_LayoutEvolve.AddSwitchRequest(LAYER_EVOLVE_EMPTY, true);
            m_WorkStep++;
        }
    }
Example #18
0
    public void SelectUnitLongPress(UnitGridContext _unit)
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK2);
        //ユニット詳細画面へ
        if (MainMenuManager.HasInstance)
        {
            UnitDetailInfo _info = MainMenuManager.Instance.OpenUnitDetailInfo();
            if (_info == null)
            {
                return;
            }
            PacketStructUnit _subUnit = UserDataAdmin.Instance.SearchLinkUnit(_unit.UnitData);
            _info.SetUnitFavorite(_unit.UnitData, _subUnit, _unit);
            _info.SetCloseAction(() =>
            {
                //選択されてるユニットがお気に入り登録されたら選択を解除する
                if (IsSelectSaleUnit(_unit.UnitData.unique_id) &&
                    _unit.IsActiveFavoriteImage)
                {
                    //選択解除
                    SetUnitUnselected(_unit);
                    //ステータス更新
                    SetupSaleStatusValue();
                }

                //IconType更新
                SetupUnitIconType(_unit);

                //更新データ反映
                m_UnitGrid.UpdateBaseItem(_unit);
            });
        }
    }
        public override void Kill(int timeLeft)
        {
            Player player = Main.player[projectile.owner];

            SoundUtil.PlayCustomSound("Sounds/Awakening", player, 1.5f);
            Projectile.NewProjectile(player.Center.X - 40, player.Center.Y + 90, 0, 0, mod.ProjectileType("SSJ1AuraProjStart"), 0, 0, player.whoAmI);
        }
    //----------------------------------------------------------------------------

    /*!
     *          @brief	進化演出ステップ:キャラを進化後シルエットへ
     *          @note
     */
    //----------------------------------------------------------------------------
    void ExecStep_100_CharaSwitch()
    {
        //-------------------
        // トリガー処理
        //-------------------
        if (m_WorkStepTriger == true)
        {
            if (m_CharaMeshAnim != null)
            {
                m_CharaMeshAnim.PlayAnimation(AnimationClipResultEvol.EVOL_ANIM.CHARA_SWITCH_AFTER);
            }

            //----------------------------------------
            // SE再生
            //----------------------------------------
            SoundUtil.PlaySE(SEID.SE_MM_D09_EVOLVE_ROLL);
        }

        //-------------------
        // 更新完遂待ち
        //-------------------
        if (m_CharaMeshAnim != null &&
            m_CharaMeshAnim.ChkAnimationPlaying() == true
            )
        {
            return;
        }

        m_CharaMeshAnim.StopAnimationClip();
        m_WorkStep++;
    }
Example #21
0
    public void OnSelectReturn()
    {
        if (!IsReady())
        {
            return;
        }

        if (!backkey)
        {
            return;
        }

        SoundUtil.PlaySE(SEID.SE_MENU_RET);
        // [DG0-4795] 【5.4.0】「チュートリアル」中の「ユニット詳細」画面>「ユニット画像」画面にて「もどる」ボタンをタップした際、適切な画面に戻らない場合がある
        // DG0-4231でチュートリアルガチャ後の名前入力時に詳細画面表示が残らない対応が追加されたが,
        // マスター選択のユニット詳細にも影響しており、拡大表示の後に閉じる挙動になっていた.
        // 戻るか、閉じるかの判定条件としてチュートリアル中でチュートリアルステップ番号(スクラッチ後の名前入力画面の603かどうか)を見るようにした.
        if ((TutorialManager.IsExists == false ||
             (TutorialManager.IsExists == true &&
              UserDataAdmin.Instance.m_StructPlayer.renew_tutorial_step != 603)) &&
            (m_CurrentType == ToggleType.None ||
             m_CurrentType == ToggleType.Evolve)
            )
        {
            OnSelectToggle(ToggleType.Status, false);
        }
        else
        {
            m_CloseAction();
            Hide();
        }
    }
Example #22
0
    private void Apply(CharacterLogic character)
    {
        switch (Type)
        {
        case PlatformType.Thorny:
        {
            if (character.IsInvlunerable)
            {
                return;
            }

            active_ = false;
            character.TakeDamage(1);
            GetComponent <SpriteRenderer>().color = new Color(0, 0, 0, 0);
            Particles.Play();

            SoundUtil.PlayRandomSound(Sounds, _audioSource);

            break;
        }

        default:
            break;
        }
    }
Example #23
0
    /// <summary>
    /// エリア選択
    /// </summary>
    /// <param name="area_id"></param>
    private void SelectArea(uint area_id, bool bSE = false)
    {
        if (m_SelectAreaIndex == (int)area_id)
        {
            return;
        }

        if (bSE)
        {
            SoundUtil.PlaySE(SEID.SE_MENU_OK);
        }

        if (m_SelectAreaIndex != -1)
        {
            m_QuestSelect.EpisodeList[m_SelectAreaIndex].SelectImage = m_UnSelectSprite;
            m_QuestSelect.EpisodeList[m_SelectAreaIndex].IsSelected  = false;
        }
        m_SelectAreaIndex = (int)area_id;

        m_QuestSelect.EpisodeList[m_SelectAreaIndex].SelectImage = m_SelectSprite;
        m_QuestSelect.EpisodeList[m_SelectAreaIndex].IsSelected  = true;

        m_QuestSelect.EpisodeTitle = m_QuestSelect.EpisodeList[m_SelectAreaIndex].master.area_name;

        setupQuest();

        m_UpdateLayoutCount = 5;

        //選択保存
        MainMenuParam.SetSaveSelectNormal(m_MasterAreaCategory.fix_id, m_QuestSelect.EpisodeList[m_SelectAreaIndex].master.fix_id);
    }
Example #24
0
    /// <summary>
    /// 詳細ボタンを押したとき
    /// </summary>
    void OnClickDetailButton()
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK);

        MainMenuParam.m_DialogEventScheduleData = m_QuestSelect.m_EventMaster;
        MainMenuManager.Instance.Header.OpenGlobalMenu(GLOBALMENU_SEQ.EVENTSCHEDULE);
    }
Example #25
0
    // Update is called once per frame
    void Update()
    {
        if (m_CurrentTime > 0)
        {
            {
                int old_sec     = m_OldTime / 10;
                int current_sec = m_CurrentTime / 10;
                if (current_sec >= 0 &&
                    current_sec < 9 &&
                    current_sec + 1 == old_sec)
                {
                    // スプライトの切り替えでなくオブジェクトを切り替えている理由:画像の中心位置が数字毎に異なっている場合があるため.
                    for (int idx = 0; idx < m_CountNum.Length; idx++)
                    {
                        m_CountNum[idx].SetActive(idx == current_sec);
                    }

                    if (m_CountNumAnimObj != null)
                    {
                        m_CountNumAnimObj.SetActive(true);
                    }
                    if (m_CountNumAnim != null)
                    {
                        m_CountNumAnim.Stop();
                        m_CountNumAnim.Play(InGameDefine.ANIM_COUNTDOWN);
                    }

                    if (m_BgAnimObj != null)
                    {
                        m_BgAnimObj.SetActive(true);
                    }
                    if (m_BgAnim != null)
                    {
                        m_BgAnim.Stop();
                        m_BgAnim.Play(InGameDefine.ANIM_COUNTDOWNBACK);
                        if (m_GaugeSpriteRenderer != null)
                        {
                            m_GaugeSpriteRenderer.color = m_GaugeColor[current_sec];
                        }
                    }

                    SoundUtil.PlaySE(se_array[current_sec]);
                }

                m_OldTime = m_CurrentTime;
            }
        }
        else
        {
            if (m_CountNumAnimObj != null)
            {
                m_CountNumAnimObj.SetActive(false);
            }

            if (m_BgAnimObj != null)
            {
                m_BgAnimObj.SetActive(false);
            }
        }
    }
Example #26
0
    // 購入確認ダイアログボックス表示
    private void possible(ProductsListItemContex contex)
    {
        SoundUtil.PlaySE(SEID.SE_MENU_OK);
        Dialog newDialog = Dialog.Create(DialogType.DialogYesNo).SetStrongYes();

        newDialog.SetDialogTextFromTextkey(DialogTextType.Title, "sh126q_title");
        string mainFormat = GameTextUtil.GetText("sh126q_content1");

        newDialog.SetDialogText(DialogTextType.MainText, string.Format(mainFormat, contex.NameText, "", string.Format("{0:#,0}", contex.Price), string.Format("{0:#,0}", UnitPoint)));
        newDialog.SetDialogTextFromTextkey(DialogTextType.YesText, "common_button4");
        newDialog.SetDialogTextFromTextkey(DialogTextType.NoText, "common_button5");

        newDialog.SetDialogEvent(DialogButtonEventType.YES, new System.Action(() =>
        {
#if BUILD_TYPE_DEBUG
            Debug.Log("はい");
#endif
            purchase(contex);       // 購入処理
        }));
        newDialog.SetDialogEvent(DialogButtonEventType.NO, new System.Action(() =>
        {
#if BUILD_TYPE_DEBUG
            Debug.Log("いいえ");
#endif
        }));
        newDialog.Show();
    }
    /// <summary>
    /// パーティの全解除
    /// </summary>
    void OnUnitRelease()
    {
        //
        if (TutorialManager.IsExists)
        {
            return;
        }

        SoundUtil.PlaySE(SEID.SE_MENU_RET);

        if (m_PartyMemberUnitGroup == null)
        {
            return;
        }
        for (int i = 0; i < m_PartyMemberUnitGroup.Units.Count; ++i)
        {
            PartyMemberUnitContext unit = m_PartyMemberUnitGroup.Units[i];
            if (unit.PartyCharaIndex == GlobalDefine.PartyCharaIndex.LEADER)
            {
                continue;
            }
            RejectPartyUnit(unit, false);
        }
        CheckUnitSpace();
    }
    /// <summary>
    /// 決定ボタンが押されたとき
    /// </summary>
    void OnClickDecision()
    {
        //
        if (TutorialManager.IsExists)
        {
            return;
        }

        if (ServerApi.IsExists == true)
        {
            return;
        }

        if (CheckCostOver() == false)
        {
            SoundUtil.PlaySE(SEID.SE_MENU_OK2);
            SendUnitPartyAssign((success) =>
            {
                ReturnPage();
            });
        }
        else
        {
            // コストオーバーダイアログ
            Dialog newDialogCost = Dialog.Create(DialogType.DialogOK);
            newDialogCost.SetDialogTextFromTextkey(DialogTextType.Title, "un73q_title");
            newDialogCost.SetDialogTextFromTextkey(DialogTextType.MainText, "un73q_content");
            newDialogCost.SetDialogTextFromTextkey(DialogTextType.OKText, "common_button1");
            newDialogCost.SetDialogEvent(DialogButtonEventType.OK, new System.Action(() => { }));
            newDialogCost.Show();
            SoundUtil.PlaySE(SEID.SE_MENU_NG);
        }
    }
        public double[] TimeFiltration(int filterLength = 1025, double cutFreq = 550, int windowType = 2)
        {
            // d³ugoœæ sygna³u wynikowego bêdzie wynosi³a K(iloœæ próbek) + L(d³ugoœæ odpowiedzi impulsowej) - 1
            double[] result = new double[dataNormalized.Length + filterLength - 1];

            // obliczenie wspó³czynników filtra
            double[] filterFactors = SoundUtil.LowPassFilterFactors(cutFreq, sampleRate, filterLength);

            // wymno¿enie wspó³czynników przez funkcjê okna
            double[] filtered = SoundUtil.Windowing(filterFactors, windowType);

            List <float> data = dataNormalized.ToList();

            float[] zeros = new float[filterLength - 1];

            // uzupe³nienie okna zerami na pocz¹tku i koñcu
            data.InsertRange(0, zeros);
            data.AddRange(zeros);

            // wykonanie operacji splotu
            for (int i = filterLength - 1; i < data.Count; i++)
            {
                for (int j = 0; j < filtered.Length; j++)
                {
                    result[i - filterLength + 1] += data[i - j] * filtered[j];
                }
            }

            return(result);
        }
Example #30
0
 public void finishMovie()
 {
     m_TitleMovie.m_bPlayMovie = false;
     if (m_ScrMedia.GetCurrentState() != MediaPlayerCtrl.MEDIAPLAYER_STATE.END)
     {
         m_ScrMedia.Stop();
     }
     m_ScrMedia.DeleteVideoTexture();
     if (m_clear == true)
     {
         UnityUtil.SetObjectEnabledOnce(gameObject, false);
         if (m_destroy == true)
         {
             Destroy(gameObject);
         }
     }
     else
     {
         UnityUtil.SetObjectEnabled(m_kabe, true);
     }
     if (m_bgmid != BGMManager.EBGM_ID.eBGM_INIT)
     {
         SoundUtil.PlayBGM(m_bgmid, false);
     }
 }
 /**
  * Get an instance of SoundUtil
  */
 public static SoundUtil getInstance()
 {
     if(Instance == null)
         Instance = new SoundUtil();
     return Instance;
 }
Example #32
0
 /// <summary>
 /// Awake this instance.
 /// </summary>
 void Awake()
 {
     instance = this;
     Init();
 }