Ejemplo n.º 1
0
        public override void UpDate()
        {
            if (!this.savedata.havefolder[1] && !this.savedata.havefolder[2] || this.nextmenu)
            {
                this.subMenu.UpDate();
            }
            else
            {
                this.Control();
                switch (this.nowscene)
                {
                case FolderSelect.SCENE.fadein:
                    if (this.Alpha > 0)
                    {
                        this.Alpha -= 51;
                        break;
                    }
                    this.nowscene = FolderSelect.SCENE.select;
                    break;

                case FolderSelect.SCENE.select:
                    if (this.frame % 10 == 0)
                    {
                        this.cursolanime = !this.cursolanime;
                        break;
                    }
                    break;

                case FolderSelect.SCENE.goOrEq:
                    if (this.frame % 10 == 0)
                    {
                        ++this.cursolanime2;
                    }
                    if (this.cursolanime2 >= 3)
                    {
                        this.cursolanime2 = 0;
                        break;
                    }
                    break;

                case FolderSelect.SCENE.fadeout:
                    if (this.Alpha < byte.MaxValue)
                    {
                        this.Alpha += 51;
                        break;
                    }
                    if (this.gonext)
                    {
                        this.subMenu.Init();
                        this.nextmenu = true;
                    }
                    else
                    {
                        this.topmenu.Return();
                    }
                    break;
                }
            }
            this.FlamePlus();
        }
Ejemplo n.º 2
0
 public FolderSelect(IAudioEngine s, Player p, SceneMain m, TopMenu t, SaveData save)
     : base(s, p, t, save)
 {
     this.main = m;
     this.main.FolderReset();
     this.nowscene = FolderSelect.SCENE.fadein;
     this.subMenu  = new FolderEdit(this.sound, p, m, t, this, save);
     this.Alpha    = byte.MaxValue;
     this.FolderCheckAll();
 }
Ejemplo n.º 3
0
 public void Back()
 {
     this.nextmenu = false;
     this.nowscene = FolderSelect.SCENE.fadein;
     if (this.savedata.havefolder[1] || this.savedata.havefolder[2])
     {
         return;
     }
     this.gonext   = false;
     this.nowscene = FolderSelect.SCENE.fadeout;
     this.topmenu.Return();
 }
Ejemplo n.º 4
0
        private void Control()
        {
            switch (this.nowscene)
            {
            case FolderSelect.SCENE.select:
                if (Input.IsPress(Button.Up))
                {
                    this.sound.PlaySE(SoundEffect.movecursol);
                    --this.select;
                    if (!this.savedata.havefolder[1] && this.select == 1)
                    {
                        --this.select;
                    }
                    if (this.select < 0)
                    {
                        if (this.savedata.havefolder[2])
                        {
                            this.select = 2;
                        }
                        else if (this.savedata.havefolder[1])
                        {
                            this.select = 1;
                        }
                    }
                    this.Topchip = 0;
                }
                if (Input.IsPress(Button.Down))
                {
                    this.sound.PlaySE(SoundEffect.movecursol);
                    ++this.select;
                    if (!this.savedata.havefolder[1] && this.select == 1)
                    {
                        ++this.select;
                    }
                    if (this.select > 2)
                    {
                        this.select = 0;
                    }
                    this.Topchip = 0;
                }
                if (Input.IsPress(Button._A))
                {
                    this.sound.PlaySE(SoundEffect.decide);
                    this.goOrEq   = this.select == 2;
                    this.nowscene = FolderSelect.SCENE.goOrEq;
                }
                if (Input.IsPress(Button._B))
                {
                    this.sound.PlaySE(SoundEffect.cancel);
                    this.gonext   = false;
                    this.nowscene = FolderSelect.SCENE.fadeout;
                }
                if (Input.IsPress(Button._Select) && this.savedata.efolder != this.select)
                {
                    if (!this.savedata.FlagList[8] && this.canEq[this.select])
                    {
                        this.sound.PlaySE(SoundEffect.bright);
                        this.savedata.efolder = this.select;
                    }
                    else
                    {
                        this.sound.PlaySE(SoundEffect.error);
                    }
                }
                if (Input.IsPress(Button._R))
                {
                    this.sound.PlaySE(SoundEffect.movecursol);
                    this.Topchip += 8;
                }
                if (!Input.IsPress(Button._L))
                {
                    break;
                }
                this.sound.PlaySE(SoundEffect.movecursol);
                this.Topchip -= 8;
                break;

            case FolderSelect.SCENE.goOrEq:
                if (Input.IsPress(Button.Down) || Input.IsPress(Button.Up))
                {
                    this.sound.PlaySE(SoundEffect.movecursol);
                    if (this.select != 2)
                    {
                        this.goOrEq = !this.goOrEq;
                    }
                }
                if (Input.IsPress(Button._A))
                {
                    if (!this.goOrEq)
                    {
                        this.sound.PlaySE(SoundEffect.decide);
                        this.gonext   = true;
                        this.nowscene = FolderSelect.SCENE.fadeout;
                    }
                    else if (!this.savedata.FlagList[8] && this.canEq[this.select])
                    {
                        if (this.savedata.efolder != this.select)
                        {
                            this.sound.PlaySE(SoundEffect.bright);
                            this.savedata.efolder = this.select;
                        }
                        else
                        {
                            this.sound.PlaySE(SoundEffect.cancel);
                        }
                        this.nowscene = FolderSelect.SCENE.select;
                        this.goOrEq   = false;
                    }
                    else
                    {
                        this.sound.PlaySE(SoundEffect.error);
                    }
                }
                if (!Input.IsPress(Button._B))
                {
                    break;
                }
                this.sound.PlaySE(SoundEffect.cancel);
                this.nowscene = FolderSelect.SCENE.select;
                break;
            }
        }