private static bool TitleDDStartConfirm() { bool ret = false; P_TitleBackWDest = DDConsts.Screen_W; DDEngine.FreezeInput(); for (; ;) { DDMouse.UpdatePos(); if (DDMouse.L.GetInput() == 1) { int x = DDMouse.X; int y = DDMouse.Y; if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(270, 280, 370, 320)) == false) // はい { ret = true; break; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(520, 280, 690, 320)) == false) // いいえ { break; } } DrawWall(); DrawTitleBack(); PrintByFont.SetPrint(); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(" セーブデータを消去します。よろしいですか?"); PrintByFont.Print(""); PrintByFont.Print(" は い い い え"); DDEngine.EachFrame(); } return(ret); }
private static void TitleConfigResetPlayData() { DDEngine.FreezeInput(); for (; ;) { DDMouse.UpdatePos(); if (DDMouse.L.GetInput() == 1) { int x = DDMouse.X; int y = DDMouse.Y; if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(270, 280, 370, 320)) == false) // はい { // TODO SE // TODO reset play data SaveData.HasSaveData = false; // セーブデータもリセットする必要あり。 break; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(520, 280, 690, 320)) == false) // いいえ { break; } } DrawWall(); DrawTitleBack(); PrintByFont.SetPrint(); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(""); PrintByFont.Print(" プレイデータを消去します。よろしいですか?"); PrintByFont.Print(""); PrintByFont.Print(" は い い い え"); DDEngine.EachFrame(); } }
private static void TitleConfig() { P_TitleBackWDest = DDConsts.Screen_W; DDEngine.FreezeInput(); for (; ;) { DDMouse.UpdatePos(); if (DDUtils.IsPound(DDMouse.L.GetInput())) { int x = DDMouse.X; int y = DDMouse.Y; if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(270, 120, 470, 160)) == false) // [960x540] { DDMain.SetScreenSize(960, 540); } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(530, 120, 800, 160)) == false) // [1440x810] { DDMain.SetScreenSize(1440, 810); } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(270, 160, 470, 200)) == false) // [1920x1080] { DDMain.SetScreenSize(1920, 1080); } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(530, 160, 800, 200)) == false) // [フルスクリーン] { int w = DDGround.MonitorRect.W; int h = (DDConsts.Screen_H * DDGround.MonitorRect.W) / DDConsts.Screen_W; if (DDGround.MonitorRect.H < h) { h = DDGround.MonitorRect.H; w = (DDConsts.Screen_W * DDGround.MonitorRect.H) / DDConsts.Screen_H; if (DDGround.MonitorRect.W < w) { throw new DDError(); } } DDMain.SetScreenSize(DDGround.MonitorRect.W, DDGround.MonitorRect.H); DDGround.RealScreenDraw_L = (DDGround.MonitorRect.W - w) / 2; DDGround.RealScreenDraw_T = (DDGround.MonitorRect.H - h) / 2; DDGround.RealScreenDraw_W = w; DDGround.RealScreenDraw_H = h; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(400, 240, 530, 280)) == false) { DDGround.MusicVolume += 0.01; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(550, 240, 690, 280)) == false) { DDGround.MusicVolume -= 0.01; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(700, 240, 900, 280)) == false) { DDGround.MusicVolume = DDConsts.DefaultVolume; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(400, 320, 530, 360)) == false) { DDGround.SEVolume += 0.01; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(550, 320, 690, 360)) == false) { DDGround.SEVolume -= 0.01; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(700, 320, 900, 360)) == false) { DDGround.SEVolume = DDConsts.DefaultVolume; } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(270, 400, 600, 440)) == false) { TitleConfigResetPlayData(); } else if (DDUtils.IsOut(new D2Point(x, y), D4Rect.LTRB(830, 480, 930, 520)) == false) { break; } DDGround.MusicVolume = DoubleTools.ToRange(DDGround.MusicVolume, 0.0, 1.0); DDGround.SEVolume = DoubleTools.ToRange(DDGround.SEVolume, 0.0, 1.0); } DrawWall(); DrawTitleBack(); PrintByFont.SetPrint(); PrintByFont.Print(""); PrintByFont.Print(" 設定"); PrintByFont.Print(""); PrintByFont.Print(" 画面サイズ [960x540] [1440x810]"); PrintByFont.Print(" [1920x1080] [フルスクリーン]"); PrintByFont.Print(""); PrintByFont.Print(string.Format(" BGM音量 {0:F2} [上げる] [下げる] [デフォルト]", DDGround.MusicVolume)); PrintByFont.Print(""); PrintByFont.Print(string.Format(" SE音量 {0:F2} [上げる] [下げる] [デフォルト]", DDGround.SEVolume)); PrintByFont.Print(""); PrintByFont.Print(" プレイデータリセット"); PrintByFont.Print(""); PrintByFont.Print(" [戻る]"); DDEngine.EachFrame(); } }