Beispiel #1
0
    void OnMouseDown()
    {
        if (TurnAndPhase.OnAction())
        {
            return;
        }
        if (!Mouse.CheckMouseOutMenu())
        {
            return;
        }
        if (mode)
        {
            switch (TurnAndPhase.type)
            {
            case (int)TurnAndPhase.Type.Move:
                if (Unit.playerPosition == grid)
                {
                    break;
                }
                Unit.playerPosition = grid;
                GameCamera.TrackPlayer();
                player.SendMessage("MovePlayer", root);
                break;

            case (int)TurnAndPhase.Type.Attack:
                if (Unit.GetEnemyNum(grid) == -1)
                {
                    break;
                }
                player.SendMessage("AttackPlayer", grid);
                break;

            case (int)TurnAndPhase.Type.Buff:
                player.SendMessage("BuffPlayer");
                break;

            case (int)TurnAndPhase.Type.Debuff:
                if (Unit.GetEnemyNum(grid) == -1)
                {
                    break;
                }
                player.SendMessage("DebuffPlayer", grid);
                break;

            case (int)TurnAndPhase.Type.Extra:
                Unit.playerPosition = grid;
                GameCamera.TrackDig();
                CutIn.StartCut(player);
                //player.SendMessage("ExtraPlayer");
                break;
            }
        }
    }
Beispiel #2
0
        override public void Initialize()
        {
            cutIn = GameObject.Find("cutIn").GetComponent <CutIn>();

            if (nowActor.attackType.ultimate && nowActor.chargeReady)
            {
                cutIn.id = nowActor.attackType.cutIn;
                cutIn.Init();
                cutIn.StartSequence();
            }
            _isPlaying = false;
            battleMgr.AttackAnimation = (float)(nowActor.attackType.AttackTime / 60);
        }
Beispiel #3
0
    //マウスクリック
    void OnMouseDown()
    {
        switch (TurnAndPhase.type)
        {
        case (int)TurnAndPhase.Type.Buff:
            SendMessage("BuffPlayer");
            Status.PlayerStatus(true);
            break;

        case (int)TurnAndPhase.Type.Extra:
            CutIn.StartCut(this);
            //SendMessage("ExtraPlayer");
            Status.PlayerStatus(true);
            break;
        }
    }
Beispiel #4
0
        private void ShowSecond()
        {
            First.IsVisible = false;
            if (!string.IsNullOrEmpty(_achivementCode))
            {
                StartPrayText.Text = "実績解禁!!";
            }
            StartPray.IsVisible = true;
            Sound.Pray();
            Sound.PrayVoice();
            MagicCircle.Show(this, 3000, () =>
            {
                StartPray.IsVisible = false;
                Flash.Show(this, 1000, () =>
                {
                    Second.IsVisible = true;
                    var masters      = CodeMasterServce.GetMasters <JobMaster>();
                    var target1      = string.IsNullOrEmpty(_achivementCode) ? CodeMasterServce.GetNameRandom() : CodeMasterServce.GetNameRandomByAttribute(_achivementCode);
                    var target2      = masters[MyRandom.GetRandom(masters.Count)];
                    var gotName      = new Name(target1, target2);

                    var name               = new Chu2Name();
                    name.BindingContext    = gotName;
                    name.ShowAttribute     = true;
                    name.ShowAttributeType = true;
                    name.ShowParameter     = true;
                    GetResult.Children.Add(name);

                    var image               = new Charactor();
                    image.BindingContext    = gotName;
                    image.HorizontalOptions = LayoutOptions.End;
                    Second.Children.Insert(0, image);

                    _current.CountUpPray();

                    var hasName = _current.Names.FirstOrDefault(n => n.Attribute == gotName.Attribute);

                    if (hasName != null)
                    {
                        BackButton.IsVisible = false;
                        Device.StartTimer(TimeSpan.FromSeconds(3), () =>
                        {
                            SelectItem.Show(this, "同じ属性の二つ名を既に持っています。二つ名を入れ替えますか?",
                                            new List <SelectItem.Item>()
                            {
                                new SelectItem.Item()
                                {
                                    Label    = "二つ名を入れ替える",
                                    Selected = () => {
                                        _current.Names.Remove(hasName);
                                        AddNewName(gotName);
                                        Device.StartTimer(TimeSpan.FromSeconds(2), () => { Back(); return(false); });
                                    }
                                },
                                new SelectItem.Item()
                                {
                                    Label    = "キャンセル",
                                    Selected = () => {
                                        CutIn.Show(this, "二つ名の取得をキャンセルしました", 3, () => { Back(); });
                                    }
                                }
                            });
                            return(false);
                        });
                    }
                    else
                    {
                        AddNewName(gotName);
                    }
                });
            });
        }
Beispiel #5
0
 // Start is called before the first frame update
 private void Awake()
 {
     cutIn = this;
 }
Beispiel #6
0
 private void FinishBattleWin(Name selectedName)
 {
     Enemy.RobName(selectedName);
     Current.AddNewName(selectedName);
     CutIn.Show(this, NameList.SelectedName.Chu2Name + NameList.SelectedName.Job + "を手に入れました", 3, () => { Back(); });
 }