BattleBossBlood_Generate.lua 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326
  1. ---@class BattleBossBlood__Generate_leftTime
  2. ---@field public gameObject UnityEngine.GameObject
  3. ---@field public text UnityEngine.UI.Text
  4. ---@class BattleBossBlood__Generate_buffTemp_num
  5. ---@field public gameObject UnityEngine.GameObject
  6. ---@field public text TMPro.TextMeshProUGUI
  7. ---@class BattleBossBlood__Generate_buffTemp_image
  8. ---@field public gameObject UnityEngine.GameObject
  9. ---@field public image UnityEngine.UI.Image
  10. ---@class BattleBossBlood__Generate_buffTemp
  11. ---@field public gameObject UnityEngine.GameObject
  12. ---@field public button UnityEngine.UI.Button
  13. ---@field public image BattleBossBlood__Generate_buffTemp_image
  14. ---@field public num BattleBossBlood__Generate_buffTemp_num
  15. ---@class BattleBossBlood__Generate_bossNature
  16. ---@field public gameObject UnityEngine.GameObject
  17. ---@field public image UnityEngine.UI.Image
  18. ---@class BattleBossBlood__Generate_bossIcon
  19. ---@field public gameObject UnityEngine.GameObject
  20. ---@field public image UnityEngine.UI.Image
  21. ---@field public button UnityEngine.UI.Button
  22. ---@class BattleBossBlood__Generate_bossName
  23. ---@field public gameObject UnityEngine.GameObject
  24. ---@field public text UnityEngine.UI.Text
  25. ---@class BattleBossBlood__Generate_bossBlood
  26. ---@field public gameObject UnityEngine.GameObject
  27. ---@field public image UnityEngine.UI.Image
  28. ---@class BattleBossBlood__Generate_bossBlood2
  29. ---@field public gameObject UnityEngine.GameObject
  30. ---@field public image UnityEngine.UI.Image
  31. ---@class BattleBossBlood__Generate_bossBloodNode
  32. ---@field public gameObject UnityEngine.GameObject
  33. ---@field public animator UnityEngine.Animator
  34. ---@class BattleBossBlood__Generate
  35. ---@field private gameObject UnityEngine.GameObject
  36. ---@field private transform UnityEngine.Transform
  37. ---@field private bossBloodNode BattleBossBlood__Generate_bossBloodNode
  38. ---@field private bossBlood2 BattleBossBlood__Generate_bossBlood2
  39. ---@field private bossBlood BattleBossBlood__Generate_bossBlood
  40. ---@field private bloodNum UnityEngine.GameObject
  41. ---@field private bossName BattleBossBlood__Generate_bossName
  42. ---@field private bossIcon BattleBossBlood__Generate_bossIcon
  43. ---@field private bossNature BattleBossBlood__Generate_bossNature
  44. ---@field private buffBox UnityEngine.GameObject
  45. ---@field private buffTemp BattleBossBlood__Generate_buffTemp
  46. ---@field private leftTime BattleBossBlood__Generate_leftTime
  47. ---@field private infinite UnityEngine.GameObject
  48. local BattleBossBloodView = class("BattleBossBloodView")
  49. function BattleBossBloodView:ctor()
  50. end
  51. ---@private
  52. function BattleBossBloodView:SetActive(result)
  53. self.gameObject:SetActive(result)
  54. end
  55. ---@private
  56. function BattleBossBloodView:InitGenerate(Root, data)
  57. self.transform = Root
  58. self.inited = true
  59. local tmp
  60. self:InitGenerate__1(Root,data)
  61. self:InitGenerate__2(Root,data)
  62. self:InitGenerate__3(Root,data)
  63. self:InitGenerate__4(Root,data)
  64. self:InitGenerate__5(Root,data)
  65. self:InitGenerate__6(Root,data)
  66. self:InitGenerate__7(Root,data)
  67. self:InitGenerate__8(Root,data)
  68. self:InitGenerate__9(Root,data)
  69. self:InitGenerate__10(Root,data)
  70. self:InitGenerate__11(Root,data)
  71. self:InitGenerate__12(Root,data)
  72. self:InitGenerate__13(Root,data)
  73. end
  74. ---@private
  75. function BattleBossBloodView:InitGenerate__1(Root, data)
  76. --[[
  77. BossBloodAnim
  78. --]]
  79. local tmp = Root:Find("BossBloodAnim").gameObject
  80. if tolua.getpeer(tmp) == nil then
  81. tolua.setpeer(tmp, {})
  82. end
  83. self.bossBloodNode = tmp
  84. tmp.animator = tmp:GetComponent(Enum.TypeInfo.Animator)
  85. tmp.animator.logWarnings = false
  86. end
  87. ---@private
  88. function BattleBossBloodView:InitGenerate__2(Root, data)
  89. --[[
  90. BossBloodAnim/BossBlood/BloodBar2
  91. --]]
  92. local tmp = Root:Find("BossBloodAnim/BossBlood/BloodBar2").gameObject
  93. if tolua.getpeer(tmp) == nil then
  94. tolua.setpeer(tmp, {})
  95. end
  96. self.bossBlood2 = tmp
  97. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  98. end
  99. ---@private
  100. function BattleBossBloodView:InitGenerate__3(Root, data)
  101. --[[
  102. BossBloodAnim/BossBlood/BloodBar
  103. --]]
  104. local tmp = Root:Find("BossBloodAnim/BossBlood/BloodBar").gameObject
  105. if tolua.getpeer(tmp) == nil then
  106. tolua.setpeer(tmp, {})
  107. end
  108. self.bossBlood = tmp
  109. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  110. end
  111. ---@private
  112. function BattleBossBloodView:InitGenerate__4(Root, data)
  113. --[[
  114. BossBloodAnim/BossBlood/num
  115. --]]
  116. local tmp = Root:Find("BossBloodAnim/BossBlood/num").gameObject
  117. if tolua.getpeer(tmp) == nil then
  118. tolua.setpeer(tmp, {})
  119. end
  120. self.bloodNum = tmp
  121. end
  122. ---@private
  123. function BattleBossBloodView:InitGenerate__5(Root, data)
  124. --[[
  125. BossBloodAnim/BossBlood/BossName/TextName
  126. --]]
  127. local tmp = Root:Find("BossBloodAnim/BossBlood/BossName/TextName").gameObject
  128. if tolua.getpeer(tmp) == nil then
  129. tolua.setpeer(tmp, {})
  130. end
  131. self.bossName = tmp
  132. tmp.text = tmp:GetComponent(Enum.TypeInfo.Text)
  133. end
  134. ---@private
  135. function BattleBossBloodView:InitGenerate__6(Root, data)
  136. --[[
  137. BossBloodAnim/BossHead/headboss
  138. --]]
  139. local tmp = Root:Find("BossBloodAnim/BossHead/headboss").gameObject
  140. if tolua.getpeer(tmp) == nil then
  141. tolua.setpeer(tmp, {})
  142. end
  143. self.bossIcon = tmp
  144. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  145. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  146. end
  147. ---@private
  148. function BattleBossBloodView:InitGenerate__7(Root, data)
  149. --[[
  150. BossBloodAnim/BossHead/nature
  151. --]]
  152. local tmp = Root:Find("BossBloodAnim/BossHead/nature").gameObject
  153. if tolua.getpeer(tmp) == nil then
  154. tolua.setpeer(tmp, {})
  155. end
  156. self.bossNature = tmp
  157. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  158. end
  159. ---@private
  160. function BattleBossBloodView:InitGenerate__8(Root, data)
  161. --[[
  162. BossBloodAnim/BossBuff
  163. --]]
  164. local tmp = Root:Find("BossBloodAnim/BossBuff").gameObject
  165. if tolua.getpeer(tmp) == nil then
  166. tolua.setpeer(tmp, {})
  167. end
  168. self.buffBox = tmp
  169. end
  170. ---@private
  171. function BattleBossBloodView:InitGenerate__9(Root, data)
  172. --[[
  173. BossBloodAnim/BossBuff/BuffItem
  174. --]]
  175. local tmp = Root:Find("BossBloodAnim/BossBuff/BuffItem").gameObject
  176. if tolua.getpeer(tmp) == nil then
  177. tolua.setpeer(tmp, {})
  178. end
  179. self.buffTemp = tmp
  180. tmp.button = tmp:GetComponent(Enum.TypeInfo.Button)
  181. end
  182. ---@private
  183. function BattleBossBloodView:InitGenerate__10(Root, data)
  184. --[[
  185. BossBloodAnim/BossBuff/BuffItem/Image
  186. --]]
  187. local tmp = Root:Find("BossBloodAnim/BossBuff/BuffItem/Image").gameObject
  188. if tolua.getpeer(tmp) == nil then
  189. tolua.setpeer(tmp, {})
  190. end
  191. self.buffTemp.image = tmp
  192. tmp.image = tmp:GetComponent(Enum.TypeInfo.Image)
  193. end
  194. ---@private
  195. function BattleBossBloodView:InitGenerate__11(Root, data)
  196. --[[
  197. BossBloodAnim/BossBuff/BuffItem/num
  198. --]]
  199. local tmp = Root:Find("BossBloodAnim/BossBuff/BuffItem/num").gameObject
  200. if tolua.getpeer(tmp) == nil then
  201. tolua.setpeer(tmp, {})
  202. end
  203. self.buffTemp.num = tmp
  204. tmp.text = tmp:GetComponent(Enum.TypeInfo.TextMeshProUGUI)
  205. end
  206. ---@private
  207. function BattleBossBloodView:InitGenerate__12(Root, data)
  208. --[[
  209. BossBloodAnim/BattleTime/LeftBattleTime
  210. --]]
  211. local tmp = Root:Find("BossBloodAnim/BattleTime/LeftBattleTime").gameObject
  212. if tolua.getpeer(tmp) == nil then
  213. tolua.setpeer(tmp, {})
  214. end
  215. self.leftTime = tmp
  216. tmp.text = tmp:GetComponent(Enum.TypeInfo.Text)
  217. end
  218. ---@private
  219. function BattleBossBloodView:InitGenerate__13(Root, data)
  220. --[[
  221. BossBloodAnim/BattleTime/infinite
  222. --]]
  223. local tmp = Root:Find("BossBloodAnim/BattleTime/infinite").gameObject
  224. if tolua.getpeer(tmp) == nil then
  225. tolua.setpeer(tmp, {})
  226. end
  227. self.infinite = tmp
  228. end
  229. ---@private
  230. function BattleBossBloodView:GenerateDestroy()
  231. if tolua.getpeer(self.buffTemp.num) ~= nil then
  232. tolua.setpeer(self.buffTemp.num, nil)
  233. end
  234. if tolua.getpeer(self.buffTemp.image) ~= nil then
  235. tolua.setpeer(self.buffTemp.image, nil)
  236. end
  237. if tolua.getpeer(self.bossBloodNode) ~= nil then
  238. tolua.setpeer(self.bossBloodNode, nil)
  239. end
  240. self.bossBloodNode = nil
  241. if tolua.getpeer(self.bossBlood2) ~= nil then
  242. tolua.setpeer(self.bossBlood2, nil)
  243. end
  244. self.bossBlood2 = nil
  245. if tolua.getpeer(self.bossBlood) ~= nil then
  246. tolua.setpeer(self.bossBlood, nil)
  247. end
  248. self.bossBlood = nil
  249. if tolua.getpeer(self.bloodNum) ~= nil then
  250. tolua.setpeer(self.bloodNum, nil)
  251. end
  252. self.bloodNum = nil
  253. if tolua.getpeer(self.bossName) ~= nil then
  254. tolua.setpeer(self.bossName, nil)
  255. end
  256. self.bossName = nil
  257. if tolua.getpeer(self.bossIcon) ~= nil then
  258. tolua.setpeer(self.bossIcon, nil)
  259. end
  260. self.bossIcon = nil
  261. if tolua.getpeer(self.bossNature) ~= nil then
  262. tolua.setpeer(self.bossNature, nil)
  263. end
  264. self.bossNature = nil
  265. if tolua.getpeer(self.buffBox) ~= nil then
  266. tolua.setpeer(self.buffBox, nil)
  267. end
  268. self.buffBox = nil
  269. if tolua.getpeer(self.buffTemp) ~= nil then
  270. tolua.setpeer(self.buffTemp, nil)
  271. end
  272. self.buffTemp = nil
  273. if tolua.getpeer(self.leftTime) ~= nil then
  274. tolua.setpeer(self.leftTime, nil)
  275. end
  276. self.leftTime = nil
  277. if tolua.getpeer(self.infinite) ~= nil then
  278. tolua.setpeer(self.infinite, nil)
  279. end
  280. self.infinite = nil
  281. self.transform = nil
  282. self.gameObject = nil
  283. self.inited = false
  284. end
  285. return BattleBossBloodView