StoryE7P1.cs 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. using System;
  2. using System.Collections;
  3. using UnityEngine;
  4. public class StoryE7P1 : BaseBehaviour
  5. {
  6. private bool _e7p2
  7. {
  8. get
  9. {
  10. return RoundStorage.Get("E7_P2", false);
  11. }
  12. set
  13. {
  14. RoundStorage.Set("E7_P2", value);
  15. }
  16. }
  17. private bool _e7p4
  18. {
  19. get
  20. {
  21. return RoundStorage.Get("E7_P4", false);
  22. }
  23. set
  24. {
  25. RoundStorage.Set("E7_P4", value);
  26. }
  27. }
  28. private bool _e7p5
  29. {
  30. get
  31. {
  32. return RoundStorage.Get("E7_P5", false);
  33. }
  34. }
  35. private bool _e7guide
  36. {
  37. get
  38. {
  39. return RoundStorage.Get("E7_guide", false);
  40. }
  41. set
  42. {
  43. RoundStorage.Set("E7_guide", value);
  44. }
  45. }
  46. private void Start()
  47. {
  48. this.guide.SetActive(this._e7guide);
  49. if (!this._e7p2)
  50. {
  51. base.StartCoroutine(this.P1Coroutine());
  52. }
  53. else
  54. {
  55. this._supplyBoxAction.gameObject.SetActive(false);
  56. }
  57. if (this._e7p5 && !this._e7p4)
  58. {
  59. this._e7p4 = true;
  60. R.Audio.PlayVoiceOver("e7t5", null, false);
  61. }
  62. }
  63. private IEnumerator P1Coroutine()
  64. {
  65. yield return this._supplyBoxAction.WaitForBreak();
  66. this._e7guide = true;
  67. this.guide.SetActive(true);
  68. this._e7p2 = true;
  69. yield return R.Audio.PlayVoiceOver("e7t2", null, false);
  70. yield break;
  71. }
  72. [SerializeField]
  73. private SupplyBoxAction _supplyBoxAction;
  74. [SerializeField]
  75. private GameObject guide;
  76. }