UIForceGuideView_Generate.lua 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. ---@class UIForceGuide__Generate_boliPoint_text
  2. ---@field public gameObject UnityEngine.GameObject
  3. ---@field public text UnityEngine.UI.Text
  4. ---@class UIForceGuide__Generate_boliPoint
  5. ---@field public gameObject UnityEngine.GameObject
  6. ---@field public rectTransform UnityEngine.RectTransform
  7. ---@field public text UIForceGuide__Generate_boliPoint_text
  8. ---@class UIForceGuide__Generate_targetPoint
  9. ---@field public gameObject UnityEngine.GameObject
  10. ---@field public rectTransform UnityEngine.RectTransform
  11. ---@class UIForceGuide__Generate_maskPoint
  12. ---@field public gameObject UnityEngine.GameObject
  13. ---@field public rectTransform UnityEngine.RectTransform
  14. ---@field public image UnityEngine.UI.Image
  15. ---@field public button UnityEngine.UI.Button
  16. ---@class UIForceGuide__Generate_mask
  17. ---@field public gameObject UnityEngine.GameObject
  18. ---@field public guideMask GuideMask
  19. ---@field public image UnityEngine.UI.Image
  20. ---@field public uIEventTriggerListener UIEventTriggerListener
  21. ---@class UIForceGuide__Generate_bG
  22. ---@field public gameObject UnityEngine.GameObject
  23. ---@field public image UnityEngine.UI.Image
  24. ---@class UIForceGuide__Generate
  25. ---@field private gameObject UnityEngine.GameObject
  26. ---@field private transform UnityEngine.Transform
  27. ---@field private uIEventHandler UIEventHandler
  28. ---@field private bG UIForceGuide__Generate_bG
  29. ---@field private mask UIForceGuide__Generate_mask
  30. ---@field private guidePoint UnityEngine.GameObject
  31. ---@field private maskPoint UIForceGuide__Generate_maskPoint
  32. ---@field private targetPoint UIForceGuide__Generate_targetPoint
  33. ---@field private boliPoint UIForceGuide__Generate_boliPoint
  34. local UIForceGuideView = class("UIForceGuideView", require("UIViewBase"))
  35. function UIForceGuideView:ctor()
  36. end
  37. ---@private
  38. function UIForceGuideView:SetActive(result)
  39. self.gameObject:SetActive(result)
  40. end
  41. ---@private
  42. function UIForceGuideView:InitGenerate(Root, data)
  43. self.transform = Root
  44. self.inited = true
  45. if self.super.Init then
  46. self.super.Init(self)
  47. end
  48. local tmp
  49. self:InitGenerate__1(Root,data)
  50. self:InitGenerate__2(Root,data)
  51. self:InitGenerate__3(Root,data)
  52. self:InitGenerate__4(Root,data)
  53. self:InitGenerate__5(Root,data)
  54. self:InitGenerate__6(Root,data)
  55. self:InitGenerate__7(Root,data)
  56. self:InitGenerate__8(Root,data)
  57. end
  58. ---@private
  59. function UIForceGuideView:InitGenerate__1(Root, data)
  60. --[[
  61. Root
  62. --]]
  63. self.uIEventHandler = Root:GetComponent(Enum.TypeInfo.UIEventHandler)
  64. end
  65. ---@private
  66. function UIForceGuideView:InitGenerate__2(Root, data)
  67. --[[
  68. Alpha/BG
  69. --]]
  70. local tmp = Root:Find("Alpha/BG").gameObject
  71. if tolua.getpeer(tmp) == nil then
  72. tolua.setpeer(tmp, {})
  73. end
  74. self.bG = tmp
  75. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  76. end
  77. ---@private
  78. function UIForceGuideView:InitGenerate__3(Root, data)
  79. --[[
  80. GuideBox/Mask
  81. --]]
  82. local tmp = Root:Find("GuideBox/Mask").gameObject
  83. if tolua.getpeer(tmp) == nil then
  84. tolua.setpeer(tmp, {})
  85. end
  86. self.mask = tmp
  87. tmp.guideMask = tmp:GetComponent(Enum.TypeInfo.GuideMask)
  88. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  89. tmp.uIEventTriggerListener = tmp:GetComponent(Enum.TypeInfo.UIEventTriggerListener)
  90. end
  91. ---@private
  92. function UIForceGuideView:InitGenerate__4(Root, data)
  93. --[[
  94. GuideBox/GuidePoint
  95. --]]
  96. local tmp = Root:Find("GuideBox/GuidePoint").gameObject
  97. if tolua.getpeer(tmp) == nil then
  98. tolua.setpeer(tmp, {})
  99. end
  100. self.guidePoint = tmp
  101. end
  102. ---@private
  103. function UIForceGuideView:InitGenerate__5(Root, data)
  104. --[[
  105. GuideBox/MaskPoint
  106. --]]
  107. local tmp = Root:Find("GuideBox/MaskPoint").gameObject
  108. if tolua.getpeer(tmp) == nil then
  109. tolua.setpeer(tmp, {})
  110. end
  111. self.maskPoint = tmp
  112. tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
  113. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  114. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  115. end
  116. ---@private
  117. function UIForceGuideView:InitGenerate__6(Root, data)
  118. --[[
  119. GuideBox/TargetPoint
  120. --]]
  121. local tmp = Root:Find("GuideBox/TargetPoint").gameObject
  122. if tolua.getpeer(tmp) == nil then
  123. tolua.setpeer(tmp, {})
  124. end
  125. self.targetPoint = tmp
  126. tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
  127. end
  128. ---@private
  129. function UIForceGuideView:InitGenerate__7(Root, data)
  130. --[[
  131. GuideBox/BoliPoint
  132. --]]
  133. local tmp = Root:Find("GuideBox/BoliPoint").gameObject
  134. if tolua.getpeer(tmp) == nil then
  135. tolua.setpeer(tmp, {})
  136. end
  137. self.boliPoint = tmp
  138. tmp.rectTransform = tmp:GetComponent(Enum.TypeInfo.RectTransform)
  139. end
  140. ---@private
  141. function UIForceGuideView:InitGenerate__8(Root, data)
  142. --[[
  143. GuideBox/BoliPoint/Talk/bg/Text
  144. --]]
  145. local tmp = Root:Find("GuideBox/BoliPoint/Talk/bg/Text").gameObject
  146. if tolua.getpeer(tmp) == nil then
  147. tolua.setpeer(tmp, {})
  148. end
  149. self.boliPoint.text = tmp
  150. tmp.text = tmp:GetComponent(Enum.TypeInfo.Text)
  151. end
  152. ---@private
  153. function UIForceGuideView:GenerateDestroy()
  154. if tolua.getpeer(self.boliPoint.text) ~= nil then
  155. tolua.setpeer(self.boliPoint.text, nil)
  156. end
  157. if tolua.getpeer(self.bG) ~= nil then
  158. tolua.setpeer(self.bG, nil)
  159. end
  160. self.bG = nil
  161. if tolua.getpeer(self.mask) ~= nil then
  162. tolua.setpeer(self.mask, nil)
  163. end
  164. self.mask = nil
  165. if tolua.getpeer(self.guidePoint) ~= nil then
  166. tolua.setpeer(self.guidePoint, nil)
  167. end
  168. self.guidePoint = nil
  169. if tolua.getpeer(self.maskPoint) ~= nil then
  170. tolua.setpeer(self.maskPoint, nil)
  171. end
  172. self.maskPoint = nil
  173. if tolua.getpeer(self.targetPoint) ~= nil then
  174. tolua.setpeer(self.targetPoint, nil)
  175. end
  176. self.targetPoint = nil
  177. if tolua.getpeer(self.boliPoint) ~= nil then
  178. tolua.setpeer(self.boliPoint, nil)
  179. end
  180. self.boliPoint = nil
  181. self.transform = nil
  182. self.gameObject = nil
  183. self.inited = false
  184. end
  185. return UIForceGuideView