Handler.lua 6.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247
  1. local HeroLogic = require("hero.HeroLogic")
  2. local HeroBook = require("hero.HeroBook")
  3. local HeroEquip = require("hero.HeroEquip")
  4. local HeroTenZhiHuan = require("hero.HeroTenZhiHuan")
  5. local BagLogic = require("bag.BagLogic")
  6. local HeroStrategyLogic = require("hero.HeroStrategyLogic")
  7. local HeroGem = require("hero.HeroGem")
  8. local HeroExclusiveWeapon = require("hero.HeroExclusiveWeapon")
  9. local HeroPubLogic = require("hero.HeroPubLogic")
  10. -- 请求英雄详细信息:静态
  11. function CG_HERO_BAG_STATIC(human,msg)
  12. HeroLogic.sendHeroBagStatic(human,msg.id, msg.tuJian)
  13. end
  14. -- 请求英雄详细信息:动态
  15. function CG_HERO_BAG_DYNAMIC(human,msg)
  16. HeroLogic.sendHeroBagDynamic(human, msg.id, msg.index, true)
  17. end
  18. -- 请求英雄详细信息:动态
  19. function CG_HERO_BAG_DYNAMIC_BY_ID(human,msg)
  20. HeroLogic.sendHeroBagDynamicByID(human, msg.heroID,msg.star)
  21. end
  22. -- 请求预览觉醒信息
  23. function CG_HERO_JUEXING_QUERY(human,msg)
  24. HeroLogic.heroJueXingQuery(human,msg.id,msg.index)
  25. end
  26. -- 请求觉醒升星
  27. function CG_HERO_JUEXING_DO(human,msg)
  28. HeroLogic.heroJueXingDo(human,msg.id,msg.index,msg.inputIDList, msg.inputIndexList)
  29. end
  30. -- 购买容量
  31. function CG_HERO_CAP_BUY(human)
  32. HeroLogic.buyHeroCap(human)
  33. end
  34. -- 锁定英雄
  35. function CG_HERO_BAG_LOCK(human, msg)
  36. HeroLogic.lockHero(human, msg.type, msg.heroID, msg.heroIndex)
  37. end
  38. -- 英雄升级
  39. function CG_HERO_LEVEL_UP(human, msg)
  40. HeroLogic.heroLvUp(human, msg.id, msg.index)
  41. end
  42. -- 英雄升阶查询
  43. function CG_HERO_UPGRADE_QUERY(human, msg)
  44. HeroLogic.heroUpgradeQuery(human, msg.id, msg.index)
  45. end
  46. -- 英雄升阶
  47. function CG_HERO_UPGRADE_DO(human, msg)
  48. HeroLogic.heroUpgradeDo(human, msg.id, msg.index)
  49. end
  50. -- 英雄图鉴查询
  51. function CG_HERO_BOOK_QUERY_CS(human, msg)
  52. HeroBook.querySimple_CS(human, msg.camp)
  53. end
  54. -- 英雄图鉴列传
  55. function CG_HERO_BOOK_LIEZHUAN_QUERY(human, msg)
  56. HeroBook.CG_HERO_BOOK_LIEZHUAN_QUERY(human,msg.id)
  57. end
  58. -- 英雄图鉴列传奖励
  59. function CG_HERO_BOOK_LIEZHUAN_GET(human, msg)
  60. HeroBook.CG_HERO_BOOK_LIEZHUAN_GET(human, msg.id)
  61. end
  62. -- 请求英雄装备信息
  63. function CG_HERO_EQUIP_QUERY(human, msg)
  64. HeroEquip.query(human, msg.id, msg.index)
  65. end
  66. -- 穿装备
  67. function CG_HERO_EQUIP_PUTON(human, msg)
  68. HeroEquip.putOn(human, msg.heroID, msg.heroIndex, msg.bagIndex, nil)
  69. end
  70. -- 穿装备 一个英雄到另一个英雄
  71. function CG_HERO_EQUIP_PUTON_ON_PUT(human, msg)
  72. HeroEquip.putOnHero(human, msg.heroID, msg.heroIndex, msg.putHeroID, msg.putHeroIndex, msg.putHeroPos)
  73. end
  74. -- 脱装备
  75. function CG_HERO_EQUIP_PUTOFF(human, msg)
  76. HeroEquip.putOff(human, msg.heroID, msg.heroIndex, msg.pos, nil)
  77. end
  78. -- 一键穿装
  79. function CG_HERO_EQUIP_PUTON_QUICK(human, msg)
  80. HeroEquip.putOnQuick(human, msg.heroID, msg.heroIndex, msg.equipID1, msg.equipID2, msg.equipID3, msg.equipID4, msg.equipID5, msg.equipID6)
  81. end
  82. -- 一键脱装
  83. function CG_HERO_EQUIP_PUTOFF_QUICK(human, msg)
  84. HeroEquip.putOffQuick(human, msg.heroID, msg.heroIndex)
  85. end
  86. -- 激活水晶
  87. function CG_SHUIJING_JIHUO(human, msg)
  88. HeroEquip.jihuoShuijing(human, msg.heroID, msg.heroIndex)
  89. end
  90. -- 查询水晶转换信息
  91. function CG_SHUIJING_TRANS_QUERY(human, msg)
  92. HeroEquip.shuijingTransQuery(human, msg.heroID, msg.heroIndex)
  93. end
  94. -- 水晶转换
  95. function CG_SHUIJING_TRANS_DO(human, msg)
  96. HeroEquip.shuijingTransDo(human, msg.heroID, msg.heroIndex)
  97. end
  98. -- 水晶保存
  99. function CG_SHUIJING_TRANS_SAVE(human, msg)
  100. HeroEquip.shuijingTransSave(human, msg.heroID, msg.heroIndex)
  101. end
  102. -- 水晶升级信息查询
  103. function CG_SHUIJING_UPLV_QUERY(human, msg)
  104. HeroEquip.shuijingUpLvQuery(human, msg.type, msg.heroID, msg.heroIndex)
  105. end
  106. -- 水晶升级
  107. function CG_SHUIJING_UPLV_DO (human, msg)
  108. HeroEquip.shuijingUpLvDo(human, msg.type, msg.heroID, msg.heroIndex)
  109. end
  110. -- 神器升级查询
  111. function CG_SHENQI_UPLV_QUERY(human, msg)
  112. HeroEquip.shenqiUpLvQuery(human, msg.heroID, msg.heroIndex)
  113. end
  114. -- 神器升级
  115. function CG_SHENQI_UPLV_DO(human, msg)
  116. HeroEquip.shenqiUpLvDo(human, msg.heroID, msg.heroIndex, msg.equipIDList, msg.equipCntList)
  117. end
  118. -- 查看分享英雄的信息
  119. function CG_HERO_SHARE_DATA(human, msg)
  120. HeroLogic.shareData(human, msg.uuid, msg.heroIndex, msg.nChatType, msg.nServerIndex)
  121. end
  122. -- 重生查询
  123. function CG_HERO_CHONGSHENG_QUERY(human,msg)
  124. HeroLogic.heroChongShengQuery(human,msg.id,msg.index)
  125. end
  126. -- 重生操作
  127. function CG_HERO_CHONGSHENG_DO(human,msg)
  128. HeroLogic.heroChongShengDo(human,msg.id,msg.index)
  129. end
  130. -- 回退查询
  131. function CG_HERO_HUITUI_QUERY(human, msg)
  132. HeroLogic.sendHuituiQuery(human, msg.heroID, msg.heroIndex)
  133. end
  134. -- 回退操作
  135. function CG_HERO_HUITUI(human, msg)
  136. HeroLogic.huituiHero(human, msg.heroID, msg.heroIndex)
  137. end
  138. function CG_HERO_LIKE(human)
  139. end
  140. function CG_HERO_STRATEGY_QUERY(human,msg)
  141. HeroStrategyLogic.StrategyQueryByHeroID(human,msg.heroID)
  142. end
  143. function CG_HERO_DETAIL_MSG_QUERY(human,msg)
  144. HeroStrategyLogic.heroDetailMsgQuery(human,msg.uuid,msg.heroIndex,msg.heroID)
  145. end
  146. function CG_HERO_GL_DOT_QUERY(human)
  147. HeroStrategyLogic.heroGlDot(human)
  148. end
  149. function CG_HERO_BAG_DOTS(human)
  150. HeroLogic.sendBagDots(human)
  151. end
  152. function CG_HERO_RESET_QUERY(human, msg)
  153. HeroLogic.resetHeroQuery(human, msg.heroID, msg.heroIndex)
  154. end
  155. function CG_HERO_RESET(human, msg)
  156. HeroLogic.resetHero(human, msg.heroID, msg.heroIndex)
  157. end
  158. -- 英雄置换查询
  159. function CG_HERO_TEN_ZHIHUAN_QUERY(human)
  160. HeroTenZhiHuan.query(human)
  161. end
  162. -- 英雄置换
  163. function CG_HERO_TEN_ZHIHUAN(human, msg)
  164. HeroTenZhiHuan.zhihuan(human, msg.fiveId, msg.heroIndexList)
  165. end
  166. function CG_HERO_BOOK_SINGLE_QUERY(human,msg)
  167. HeroBook.queryHeroBookById(human,msg.heroID,msg.star)
  168. end
  169. ----------------------------------------------宝石——--------------------------------------
  170. function CG_HERO_GEM_LEVELUP_QUERY(human,msg)
  171. HeroGem.getGemData(human, msg.heroID, msg.heroIndex, msg.pos)
  172. end
  173. function CG_HERO_GEM_UPGRADEGEM(human,msg)
  174. HeroGem.upgradeGem(human, msg.heroID, msg.heroIndex, msg.pos)
  175. end
  176. ---------------------------------------专属武器------------------------------------------------
  177. function CG_HERO_EXCLUSIVE_WEAPON_QUERY(human,msg)
  178. HeroExclusiveWeapon.Query(human, msg.heroID, msg.heroIndex)
  179. end
  180. function CG_HERO_EXCLUSIVE_WEAPON_UPGRADE(human,msg)
  181. HeroExclusiveWeapon.UpgradeWeapon(human, msg.heroID, msg.heroIndex)
  182. end
  183. function CG_HERO_EXCLUSIVE_WEAPON_BOOK_QUERY(human,msg)
  184. HeroExclusiveWeapon.BookQuery(human, msg.heroID)
  185. end
  186. ---------------------------------------英雄酒馆------------------------------------------------
  187. function CG_HEROPUB_QUERY(human,msg)
  188. HeroPubLogic.PubQuery(human)
  189. end
  190. function CG_HEROPUB_ACTIVATE(human,msg)
  191. HeroPubLogic.ActivatePubAtrr(human, msg.index)
  192. end