IGMData_ConfirmRemAll.cs 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. using Microsoft.Xna.Framework;
  2. namespace OpenVIII
  3. {
  4. public partial class Junction
  5. {
  6. #region Classes
  7. private sealed class IGMData_ConfirmRemAll : IGMData.Dialog.Confirm
  8. {
  9. #region Methods
  10. public static IGMData_ConfirmRemAll Create(FF8String data, Icons.ID title, FF8String opt1, FF8String opt2, Rectangle pos) =>
  11. Create<IGMData_ConfirmRemAll>(data, title, opt1, opt2, pos, 1);
  12. public override bool Inputs_CANCEL()
  13. {
  14. base.Inputs_CANCEL();
  15. Junction.Data[SectionName.RemAll].Hide();
  16. Junction.SetMode(Mode.TopMenu_Off);
  17. return true;
  18. }
  19. public override bool Inputs_OKAY()
  20. {
  21. switch (CURSOR_SELECT)
  22. {
  23. case 0:
  24. skipsnd = true;
  25. AV.Sound.Play(31);
  26. base.Inputs_OKAY();
  27. if (Damageable.GetCharacterData(out var c))
  28. c.RemoveAll();
  29. Junction.Data[SectionName.RemAll].Hide();
  30. Junction.Data[SectionName.TopMenu_Off].Hide();
  31. Junction.SetMode(Mode.TopMenu);
  32. ((IGMData.Base)Junction.Data[SectionName.TopMenu]).CURSOR_SELECT = 0;
  33. Junction.Refresh();
  34. break;
  35. case 1:
  36. Inputs_CANCEL();
  37. break;
  38. default: return false;
  39. }
  40. return true;
  41. }
  42. #endregion Methods
  43. }
  44. #endregion Classes
  45. }
  46. }