warscript 0.0.1-dev.404878c

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (493) hide show
  1. package/LICENSE +23 -0
  2. package/binaryreader.d.ts +20 -0
  3. package/binaryreader.lua +50 -0
  4. package/binarywriter.d.ts +21 -0
  5. package/binarywriter.lua +90 -0
  6. package/core/dummy.d.ts +22 -0
  7. package/core/dummy.lua +133 -0
  8. package/core/game.d.ts +3 -0
  9. package/core/game.lua +24 -0
  10. package/core/mapbounds.d.ts +8 -0
  11. package/core/mapbounds.lua +12 -0
  12. package/core/thread.d.ts +8 -0
  13. package/core/thread.lua +40 -0
  14. package/core/types/ability.d.ts +4 -0
  15. package/core/types/ability.lua +10 -0
  16. package/core/types/async.d.ts +3 -0
  17. package/core/types/async.lua +2 -0
  18. package/core/types/camera.d.ts +4 -0
  19. package/core/types/camera.lua +21 -0
  20. package/core/types/cameraField.d.ts +15 -0
  21. package/core/types/cameraField.lua +38 -0
  22. package/core/types/color.d.ts +16 -0
  23. package/core/types/color.lua +93 -0
  24. package/core/types/destructable.d.ts +31 -0
  25. package/core/types/destructable.lua +245 -0
  26. package/core/types/effect.d.ts +31 -0
  27. package/core/types/effect.lua +209 -0
  28. package/core/types/frame.d.ts +140 -0
  29. package/core/types/frame.lua +882 -0
  30. package/core/types/game.d.ts +8 -0
  31. package/core/types/game.lua +41 -0
  32. package/core/types/group.d.ts +22 -0
  33. package/core/types/group.lua +94 -0
  34. package/core/types/handle.d.ts +48 -0
  35. package/core/types/handle.lua +169 -0
  36. package/core/types/image.d.ts +30 -0
  37. package/core/types/image.lua +121 -0
  38. package/core/types/internal/ability+cooldownRemaining.d.ts +1 -0
  39. package/core/types/internal/ability+cooldownRemaining.lua +0 -0
  40. package/core/types/item.d.ts +4 -0
  41. package/core/types/item.lua +6 -0
  42. package/core/types/missile.d.ts +22 -0
  43. package/core/types/missile.lua +233 -0
  44. package/core/types/order.d.ts +25 -0
  45. package/core/types/order.lua +55 -0
  46. package/core/types/player.d.ts +71 -0
  47. package/core/types/player.lua +448 -0
  48. package/core/types/playerCamera.d.ts +32 -0
  49. package/core/types/playerCamera.lua +162 -0
  50. package/core/types/playerColor.d.ts +40 -0
  51. package/core/types/playerColor.lua +203 -0
  52. package/core/types/rect.d.ts +39 -0
  53. package/core/types/rect.lua +152 -0
  54. package/core/types/region.d.ts +14 -0
  55. package/core/types/region.lua +84 -0
  56. package/core/types/sound.d.ts +69 -0
  57. package/core/types/sound.lua +247 -0
  58. package/core/types/tileCell.d.ts +13 -0
  59. package/core/types/tileCell.lua +100 -0
  60. package/core/types/timer.d.ts +36 -0
  61. package/core/types/timer.lua +230 -0
  62. package/core/types/timerDialog.d.ts +19 -0
  63. package/core/types/timerDialog.lua +95 -0
  64. package/core/types/unit.d.ts +10 -0
  65. package/core/types/unit.lua +24 -0
  66. package/core/types/widget.d.ts +5 -0
  67. package/core/types/widget.lua +2 -0
  68. package/core/util.d.ts +62 -0
  69. package/core/util.lua +464 -0
  70. package/core/vecmath/common.d.ts +18 -0
  71. package/core/vecmath/common.lua +29 -0
  72. package/core/vecmath/mat2.d.ts +73 -0
  73. package/core/vecmath/mat2.lua +261 -0
  74. package/core/vecmath/vec3.d.ts +47 -0
  75. package/core/vecmath/vec3.lua +350 -0
  76. package/core/vecmath/vec4.d.ts +54 -0
  77. package/core/vecmath/vec4.lua +400 -0
  78. package/crypto/ecc.d.ts +6 -0
  79. package/crypto/ecc.lua +1734 -0
  80. package/decl/index.d.ts +116 -0
  81. package/decl/native.d.ts +8198 -0
  82. package/destroyable.d.ts +20 -0
  83. package/destroyable.lua +31 -0
  84. package/engine/ability.d.ts +5 -0
  85. package/engine/ability.lua +7 -0
  86. package/engine/behavior.d.ts +28 -0
  87. package/engine/behavior.lua +181 -0
  88. package/engine/behaviour/ability/apply-buff.d.ts +38 -0
  89. package/engine/behaviour/ability/apply-buff.lua +126 -0
  90. package/engine/behaviour/ability/apply-unit-behavior.d.ts +12 -0
  91. package/engine/behaviour/ability/apply-unit-behavior.lua +36 -0
  92. package/engine/behaviour/ability/damage.d.ts +25 -0
  93. package/engine/behaviour/ability/damage.lua +75 -0
  94. package/engine/behaviour/ability/heal.d.ts +16 -0
  95. package/engine/behaviour/ability/heal.lua +35 -0
  96. package/engine/behaviour/ability/instant-impact.d.ts +6 -0
  97. package/engine/behaviour/ability/instant-impact.lua +25 -0
  98. package/engine/behaviour/ability.d.ts +40 -0
  99. package/engine/behaviour/ability.lua +175 -0
  100. package/engine/behaviour/unit/stun-immunity.d.ts +19 -0
  101. package/engine/behaviour/unit/stun-immunity.lua +67 -0
  102. package/engine/behaviour/unit.d.ts +20 -0
  103. package/engine/behaviour/unit.lua +75 -0
  104. package/engine/buff.d.ts +221 -0
  105. package/engine/buff.lua +1093 -0
  106. package/engine/constants.d.ts +7 -0
  107. package/engine/constants.lua +8 -0
  108. package/engine/index.d.ts +5 -0
  109. package/engine/index.lua +2 -0
  110. package/engine/internal/ability.d.ts +91 -0
  111. package/engine/internal/ability.lua +531 -0
  112. package/engine/internal/item/ability.d.ts +2 -0
  113. package/engine/internal/item/ability.lua +48 -0
  114. package/engine/internal/item+owner.d.ts +7 -0
  115. package/engine/internal/item+owner.lua +22 -0
  116. package/engine/internal/item.d.ts +86 -0
  117. package/engine/internal/item.lua +580 -0
  118. package/engine/internal/mechanics/ability-duration.d.ts +4 -0
  119. package/engine/internal/mechanics/ability-duration.lua +11 -0
  120. package/engine/internal/mechanics/area-damage.d.ts +2 -0
  121. package/engine/internal/mechanics/area-damage.lua +33 -0
  122. package/engine/internal/misc/dummy-units.d.ts +2 -0
  123. package/engine/internal/misc/dummy-units.lua +14 -0
  124. package/engine/internal/object-data/armor-increase.d.ts +2 -0
  125. package/engine/internal/object-data/armor-increase.lua +19 -0
  126. package/engine/internal/object-data/attribute-bonus.d.ts +2 -0
  127. package/engine/internal/object-data/attribute-bonus.lua +15 -0
  128. package/engine/internal/object-data/auto-attack-damage-increase.d.ts +2 -0
  129. package/engine/internal/object-data/auto-attack-damage-increase.lua +17 -0
  130. package/engine/internal/object-data/auto-attack-speed-increase.d.ts +2 -0
  131. package/engine/internal/object-data/auto-attack-speed-increase.lua +14 -0
  132. package/engine/internal/object-data/dummy-inventory.d.ts +2 -0
  133. package/engine/internal/object-data/dummy-inventory.lua +16 -0
  134. package/engine/internal/object-data/dummy-item.d.ts +2 -0
  135. package/engine/internal/object-data/dummy-item.lua +10 -0
  136. package/engine/internal/object-data/ghost-visible.d.ts +2 -0
  137. package/engine/internal/object-data/ghost-visible.lua +15 -0
  138. package/engine/internal/object-data/invulnerable.d.ts +2 -0
  139. package/engine/internal/object-data/invulnerable.lua +11 -0
  140. package/engine/internal/object-data/movement-speed-increase-factor.d.ts +2 -0
  141. package/engine/internal/object-data/movement-speed-increase-factor.lua +18 -0
  142. package/engine/internal/unit/ability.d.ts +143 -0
  143. package/engine/internal/unit/ability.lua +369 -0
  144. package/engine/internal/unit/allowed-targets.d.ts +17 -0
  145. package/engine/internal/unit/allowed-targets.lua +19 -0
  146. package/engine/internal/unit/band-aids/ancestral-spirit-cannibalize.d.ts +2 -0
  147. package/engine/internal/unit/band-aids/ancestral-spirit-cannibalize.lua +21 -0
  148. package/engine/internal/unit/bonus.d.ts +41 -0
  149. package/engine/internal/unit/bonus.lua +188 -0
  150. package/engine/internal/unit/buff.d.ts +38 -0
  151. package/engine/internal/unit/buff.lua +81 -0
  152. package/engine/internal/unit/expiration-timer.d.ts +22 -0
  153. package/engine/internal/unit/expiration-timer.lua +44 -0
  154. package/engine/internal/unit/ghost-counter.d.ts +12 -0
  155. package/engine/internal/unit/ghost-counter.lua +26 -0
  156. package/engine/internal/unit/invulnerability-counter.d.ts +12 -0
  157. package/engine/internal/unit/invulnerability-counter.lua +26 -0
  158. package/engine/internal/unit/missile.d.ts +42 -0
  159. package/engine/internal/unit/missile.lua +70 -0
  160. package/engine/internal/unit/movement-speed.d.ts +18 -0
  161. package/engine/internal/unit/movement-speed.lua +42 -0
  162. package/engine/internal/unit/summon-event.d.ts +12 -0
  163. package/engine/internal/unit/summon-event.lua +50 -0
  164. package/engine/internal/unit+ability.d.ts +9 -0
  165. package/engine/internal/unit+ability.lua +59 -0
  166. package/engine/internal/unit+bonus.d.ts +8 -0
  167. package/engine/internal/unit+bonus.lua +40 -0
  168. package/engine/internal/unit+damage.d.ts +69 -0
  169. package/engine/internal/unit+damage.lua +123 -0
  170. package/engine/internal/unit+rally.d.ts +10 -0
  171. package/engine/internal/unit+rally.lua +159 -0
  172. package/engine/internal/unit+spellSteal.d.ts +7 -0
  173. package/engine/internal/unit+spellSteal.lua +64 -0
  174. package/engine/internal/unit+transport.d.ts +12 -0
  175. package/engine/internal/unit+transport.lua +102 -0
  176. package/engine/internal/unit-missile-data.d.ts +2 -0
  177. package/engine/internal/unit-missile-data.lua +107 -0
  178. package/engine/internal/unit-missile-launch.d.ts +7 -0
  179. package/engine/internal/unit-missile-launch.lua +32 -0
  180. package/engine/internal/unit.d.ts +312 -0
  181. package/engine/internal/unit.lua +2430 -0
  182. package/engine/internal/utility.d.ts +2 -0
  183. package/engine/internal/utility.lua +13 -0
  184. package/engine/lightning.d.ts +51 -0
  185. package/engine/lightning.lua +303 -0
  186. package/engine/local-client.d.ts +16 -0
  187. package/engine/local-client.lua +86 -0
  188. package/engine/object-data/auxiliary/animation-name.d.ts +14 -0
  189. package/engine/object-data/auxiliary/animation-name.lua +2 -0
  190. package/engine/object-data/auxiliary/animation-qualifier.d.ts +53 -0
  191. package/engine/object-data/auxiliary/animation-qualifier.lua +2 -0
  192. package/engine/object-data/auxiliary/armor-sound-type.d.ts +8 -0
  193. package/engine/object-data/auxiliary/armor-sound-type.lua +2 -0
  194. package/engine/object-data/auxiliary/attachment-preset.d.ts +15 -0
  195. package/engine/object-data/auxiliary/attachment-preset.lua +29 -0
  196. package/engine/object-data/auxiliary/attack-type.d.ts +11 -0
  197. package/engine/object-data/auxiliary/attack-type.lua +2 -0
  198. package/engine/object-data/auxiliary/buff-polarity.d.ts +6 -0
  199. package/engine/object-data/auxiliary/buff-polarity.lua +2 -0
  200. package/engine/object-data/auxiliary/buff-resistance-type.d.ts +6 -0
  201. package/engine/object-data/auxiliary/buff-resistance-type.lua +2 -0
  202. package/engine/object-data/auxiliary/combat-classification.d.ts +46 -0
  203. package/engine/object-data/auxiliary/combat-classification.lua +206 -0
  204. package/engine/object-data/auxiliary/detection-type.d.ts +7 -0
  205. package/engine/object-data/auxiliary/detection-type.lua +2 -0
  206. package/engine/object-data/auxiliary/model-node-name.d.ts +12 -0
  207. package/engine/object-data/auxiliary/model-node-name.lua +2 -0
  208. package/engine/object-data/auxiliary/model-node-qualifier.d.ts +21 -0
  209. package/engine/object-data/auxiliary/model-node-qualifier.lua +2 -0
  210. package/engine/object-data/auxiliary/movement-type.d.ts +10 -0
  211. package/engine/object-data/auxiliary/movement-type.lua +2 -0
  212. package/engine/object-data/auxiliary/race.d.ts +14 -0
  213. package/engine/object-data/auxiliary/race.lua +2 -0
  214. package/engine/object-data/auxiliary/sound-preset-name.d.ts +8 -0
  215. package/engine/object-data/auxiliary/sound-preset-name.lua +2 -0
  216. package/engine/object-data/auxiliary/sound-set-name.d.ts +35 -0
  217. package/engine/object-data/auxiliary/sound-set-name.lua +2 -0
  218. package/engine/object-data/auxiliary/targeting-type.d.ts +8 -0
  219. package/engine/object-data/auxiliary/targeting-type.lua +2 -0
  220. package/engine/object-data/auxiliary/tech-tree-dependency.d.ts +16 -0
  221. package/engine/object-data/auxiliary/tech-tree-dependency.lua +8 -0
  222. package/engine/object-data/auxiliary/unit-classification.d.ts +19 -0
  223. package/engine/object-data/auxiliary/unit-classification.lua +50 -0
  224. package/engine/object-data/auxiliary/weapon-sound-type.d.ts +17 -0
  225. package/engine/object-data/auxiliary/weapon-sound-type.lua +2 -0
  226. package/engine/object-data/entry/ability-type/armor-increase.d.ts +8 -0
  227. package/engine/object-data/entry/ability-type/armor-increase.lua +26 -0
  228. package/engine/object-data/entry/ability-type/attribute-increase.d.ts +12 -0
  229. package/engine/object-data/entry/ability-type/attribute-increase.lua +52 -0
  230. package/engine/object-data/entry/ability-type/auto-attack-damage-increase.d.ts +8 -0
  231. package/engine/object-data/entry/ability-type/auto-attack-damage-increase.lua +26 -0
  232. package/engine/object-data/entry/ability-type/auto-attack-heal-reduction-effect.d.ts +12 -0
  233. package/engine/object-data/entry/ability-type/auto-attack-heal-reduction-effect.lua +52 -0
  234. package/engine/object-data/entry/ability-type/auto-attack-speed-increase.d.ts +8 -0
  235. package/engine/object-data/entry/ability-type/auto-attack-speed-increase.lua +26 -0
  236. package/engine/object-data/entry/ability-type/bash.d.ts +16 -0
  237. package/engine/object-data/entry/ability-type/bash.lua +78 -0
  238. package/engine/object-data/entry/ability-type/berserk.d.ts +10 -0
  239. package/engine/object-data/entry/ability-type/berserk.lua +39 -0
  240. package/engine/object-data/entry/ability-type/blank-configurable.d.ts +21 -0
  241. package/engine/object-data/entry/ability-type/blank-configurable.lua +249 -0
  242. package/engine/object-data/entry/ability-type/blank-passive.d.ts +7 -0
  243. package/engine/object-data/entry/ability-type/blank-passive.lua +28 -0
  244. package/engine/object-data/entry/ability-type/blizzard.d.ts +16 -0
  245. package/engine/object-data/entry/ability-type/blizzard.lua +78 -0
  246. package/engine/object-data/entry/ability-type/blood-lust.d.ts +12 -0
  247. package/engine/object-data/entry/ability-type/blood-lust.lua +52 -0
  248. package/engine/object-data/entry/ability-type/chain-lightning.d.ts +12 -0
  249. package/engine/object-data/entry/ability-type/chain-lightning.lua +52 -0
  250. package/engine/object-data/entry/ability-type/channel.d.ts +48 -0
  251. package/engine/object-data/entry/ability-type/channel.lua +140 -0
  252. package/engine/object-data/entry/ability-type/charge-gold-and-lumber.d.ts +14 -0
  253. package/engine/object-data/entry/ability-type/charge-gold-and-lumber.lua +65 -0
  254. package/engine/object-data/entry/ability-type/cleaving-attack.d.ts +8 -0
  255. package/engine/object-data/entry/ability-type/cleaving-attack.lua +26 -0
  256. package/engine/object-data/entry/ability-type/cluster-rockets.d.ts +18 -0
  257. package/engine/object-data/entry/ability-type/cluster-rockets.lua +91 -0
  258. package/engine/object-data/entry/ability-type/cripple.d.ts +12 -0
  259. package/engine/object-data/entry/ability-type/cripple.lua +52 -0
  260. package/engine/object-data/entry/ability-type/critical-strike.d.ts +18 -0
  261. package/engine/object-data/entry/ability-type/critical-strike.lua +91 -0
  262. package/engine/object-data/entry/ability-type/curse.d.ts +8 -0
  263. package/engine/object-data/entry/ability-type/curse.lua +26 -0
  264. package/engine/object-data/entry/ability-type/dark-summoning.d.ts +10 -0
  265. package/engine/object-data/entry/ability-type/dark-summoning.lua +39 -0
  266. package/engine/object-data/entry/ability-type/death-coil.d.ts +8 -0
  267. package/engine/object-data/entry/ability-type/death-coil.lua +26 -0
  268. package/engine/object-data/entry/ability-type/disease-cloud.d.ts +15 -0
  269. package/engine/object-data/entry/ability-type/disease-cloud.lua +65 -0
  270. package/engine/object-data/entry/ability-type/divine-shield.d.ts +5 -0
  271. package/engine/object-data/entry/ability-type/divine-shield.lua +12 -0
  272. package/engine/object-data/entry/ability-type/endurance-aura.d.ts +10 -0
  273. package/engine/object-data/entry/ability-type/endurance-aura.lua +39 -0
  274. package/engine/object-data/entry/ability-type/engineering-upgrade.d.ts +13 -0
  275. package/engine/object-data/entry/ability-type/engineering-upgrade.lua +88 -0
  276. package/engine/object-data/entry/ability-type/evasion.d.ts +8 -0
  277. package/engine/object-data/entry/ability-type/evasion.lua +26 -0
  278. package/engine/object-data/entry/ability-type/faerie-fire.d.ts +10 -0
  279. package/engine/object-data/entry/ability-type/faerie-fire.lua +39 -0
  280. package/engine/object-data/entry/ability-type/far-sight.d.ts +9 -0
  281. package/engine/object-data/entry/ability-type/far-sight.lua +26 -0
  282. package/engine/object-data/entry/ability-type/feral-spirit.d.ts +11 -0
  283. package/engine/object-data/entry/ability-type/feral-spirit.lua +39 -0
  284. package/engine/object-data/entry/ability-type/frenzy.d.ts +12 -0
  285. package/engine/object-data/entry/ability-type/frenzy.lua +52 -0
  286. package/engine/object-data/entry/ability-type/frost-nova.d.ts +12 -0
  287. package/engine/object-data/entry/ability-type/frost-nova.lua +52 -0
  288. package/engine/object-data/entry/ability-type/ghost-visible.d.ts +10 -0
  289. package/engine/object-data/entry/ability-type/ghost-visible.lua +39 -0
  290. package/engine/object-data/entry/ability-type/gold-mine.d.ts +12 -0
  291. package/engine/object-data/entry/ability-type/gold-mine.lua +52 -0
  292. package/engine/object-data/entry/ability-type/heal.d.ts +8 -0
  293. package/engine/object-data/entry/ability-type/heal.lua +26 -0
  294. package/engine/object-data/entry/ability-type/healing-salve.d.ts +22 -0
  295. package/engine/object-data/entry/ability-type/healing-salve.lua +78 -0
  296. package/engine/object-data/entry/ability-type/healing-spray.d.ts +18 -0
  297. package/engine/object-data/entry/ability-type/healing-spray.lua +91 -0
  298. package/engine/object-data/entry/ability-type/healing-wave.d.ts +12 -0
  299. package/engine/object-data/entry/ability-type/healing-wave.lua +52 -0
  300. package/engine/object-data/entry/ability-type/holy-light.d.ts +8 -0
  301. package/engine/object-data/entry/ability-type/holy-light.lua +26 -0
  302. package/engine/object-data/entry/ability-type/incinerate.d.ts +18 -0
  303. package/engine/object-data/entry/ability-type/incinerate.lua +91 -0
  304. package/engine/object-data/entry/ability-type/inner-fire.d.ts +14 -0
  305. package/engine/object-data/entry/ability-type/inner-fire.lua +65 -0
  306. package/engine/object-data/entry/ability-type/inventory.d.ts +16 -0
  307. package/engine/object-data/entry/ability-type/inventory.lua +78 -0
  308. package/engine/object-data/entry/ability-type/invulnerable.d.ts +5 -0
  309. package/engine/object-data/entry/ability-type/invulnerable.lua +12 -0
  310. package/engine/object-data/entry/ability-type/lightning-shield.d.ts +8 -0
  311. package/engine/object-data/entry/ability-type/lightning-shield.lua +26 -0
  312. package/engine/object-data/entry/ability-type/movement-speed-increase.d.ts +8 -0
  313. package/engine/object-data/entry/ability-type/movement-speed-increase.lua +26 -0
  314. package/engine/object-data/entry/ability-type/permanent-immolation.d.ts +8 -0
  315. package/engine/object-data/entry/ability-type/permanent-immolation.lua +26 -0
  316. package/engine/object-data/entry/ability-type/phoenix-morph.d.ts +25 -0
  317. package/engine/object-data/entry/ability-type/phoenix-morph.lua +130 -0
  318. package/engine/object-data/entry/ability-type/recall.d.ts +10 -0
  319. package/engine/object-data/entry/ability-type/recall.lua +39 -0
  320. package/engine/object-data/entry/ability-type/rejuvenation.d.ts +20 -0
  321. package/engine/object-data/entry/ability-type/rejuvenation.lua +65 -0
  322. package/engine/object-data/entry/ability-type/searing-arrows.d.ts +8 -0
  323. package/engine/object-data/entry/ability-type/searing-arrows.lua +26 -0
  324. package/engine/object-data/entry/ability-type/shock-wave.d.ts +10 -0
  325. package/engine/object-data/entry/ability-type/shock-wave.lua +39 -0
  326. package/engine/object-data/entry/ability-type/slow-poison.d.ts +12 -0
  327. package/engine/object-data/entry/ability-type/slow-poison.lua +52 -0
  328. package/engine/object-data/entry/ability-type/slow.d.ts +12 -0
  329. package/engine/object-data/entry/ability-type/slow.lua +52 -0
  330. package/engine/object-data/entry/ability-type/spell-damage-reduction.d.ts +10 -0
  331. package/engine/object-data/entry/ability-type/spell-damage-reduction.lua +39 -0
  332. package/engine/object-data/entry/ability-type/spiked-carapace.d.ts +12 -0
  333. package/engine/object-data/entry/ability-type/spiked-carapace.lua +52 -0
  334. package/engine/object-data/entry/ability-type/spirit-touch.d.ts +14 -0
  335. package/engine/object-data/entry/ability-type/spirit-touch.lua +65 -0
  336. package/engine/object-data/entry/ability-type/storm-bolt.d.ts +8 -0
  337. package/engine/object-data/entry/ability-type/storm-bolt.lua +26 -0
  338. package/engine/object-data/entry/ability-type/summon-quilbeast.d.ts +11 -0
  339. package/engine/object-data/entry/ability-type/summon-quilbeast.lua +39 -0
  340. package/engine/object-data/entry/ability-type/summon-water-elemental.d.ts +11 -0
  341. package/engine/object-data/entry/ability-type/summon-water-elemental.lua +39 -0
  342. package/engine/object-data/entry/ability-type.d.ts +148 -0
  343. package/engine/object-data/entry/ability-type.lua +1058 -0
  344. package/engine/object-data/entry/buff-type/applicable.d.ts +16 -0
  345. package/engine/object-data/entry/buff-type/applicable.lua +377 -0
  346. package/engine/object-data/entry/buff-type/blank.d.ts +8 -0
  347. package/engine/object-data/entry/buff-type/blank.lua +17 -0
  348. package/engine/object-data/entry/buff-type.d.ts +64 -0
  349. package/engine/object-data/entry/buff-type.lua +316 -0
  350. package/engine/object-data/entry/destructible-type.d.ts +21 -0
  351. package/engine/object-data/entry/destructible-type.lua +83 -0
  352. package/engine/object-data/entry/item-type/blank.d.ts +8 -0
  353. package/engine/object-data/entry/item-type/blank.lua +21 -0
  354. package/engine/object-data/entry/item-type.d.ts +49 -0
  355. package/engine/object-data/entry/item-type.lua +259 -0
  356. package/engine/object-data/entry/lightning-type.d.ts +37 -0
  357. package/engine/object-data/entry/lightning-type.lua +191 -0
  358. package/engine/object-data/entry/unit-type/blank.d.ts +6 -0
  359. package/engine/object-data/entry/unit-type/blank.lua +13 -0
  360. package/engine/object-data/entry/unit-type.d.ts +218 -0
  361. package/engine/object-data/entry/unit-type.lua +1306 -0
  362. package/engine/object-data/entry/upgrade/blank.d.ts +8 -0
  363. package/engine/object-data/entry/upgrade/blank.lua +22 -0
  364. package/engine/object-data/entry/upgrade.d.ts +59 -0
  365. package/engine/object-data/entry/upgrade.lua +238 -0
  366. package/engine/object-data/entry.d.ts +80 -0
  367. package/engine/object-data/entry.lua +634 -0
  368. package/engine/object-data/utility/object-data-entry-id-generator.d.ts +6 -0
  369. package/engine/object-data/utility/object-data-entry-id-generator.lua +63 -0
  370. package/engine/object-data/utility/order-type-string-id-factory.d.ts +9 -0
  371. package/engine/object-data/utility/order-type-string-id-factory.lua +368 -0
  372. package/engine/object-field/ability.d.ts +115 -0
  373. package/engine/object-field/ability.lua +471 -0
  374. package/engine/object-field/unit.d.ts +15 -0
  375. package/engine/object-field/unit.lua +49 -0
  376. package/engine/object-field.d.ts +84 -0
  377. package/engine/object-field.lua +444 -0
  378. package/engine/random.d.ts +10 -0
  379. package/engine/random.lua +9 -0
  380. package/engine/standard/entries/ability-type.d.ts +8 -0
  381. package/engine/standard/entries/ability-type.lua +8 -0
  382. package/engine/standard/entries/lightning-type.d.ts +16 -0
  383. package/engine/standard/entries/lightning-type.lua +16 -0
  384. package/engine/standard/entries/unit-type.d.ts +63 -0
  385. package/engine/standard/entries/unit-type.lua +63 -0
  386. package/engine/standard/entries/upgrade.d.ts +92 -0
  387. package/engine/standard/entries/upgrade.lua +92 -0
  388. package/engine/standard/fields/ability.d.ts +737 -0
  389. package/engine/standard/fields/ability.lua +749 -0
  390. package/engine/standard/pathing-textures.d.ts +6 -0
  391. package/engine/standard/pathing-textures.lua +7 -0
  392. package/engine/text-tag.d.ts +25 -0
  393. package/engine/text-tag.lua +109 -0
  394. package/engine/unit.d.ts +20 -0
  395. package/engine/unit.lua +31 -0
  396. package/event.d.ts +53 -0
  397. package/event.lua +269 -0
  398. package/exception.d.ts +17 -0
  399. package/exception.lua +53 -0
  400. package/file.d.ts +4 -0
  401. package/file.lua +42 -0
  402. package/global/math.d.ts +21 -0
  403. package/global/math.lua +72 -0
  404. package/global/vec2.d.ts +66 -0
  405. package/global/vec2.lua +159 -0
  406. package/index.d.ts +8 -0
  407. package/index.lua +9 -0
  408. package/lualib_bundle.lua +2629 -0
  409. package/math/vec2.d.ts +18 -0
  410. package/math/vec2.lua +42 -0
  411. package/math.d.ts +39 -0
  412. package/math.lua +91 -0
  413. package/net/signal.d.ts +11 -0
  414. package/net/signal.lua +56 -0
  415. package/net/socket.d.ts +9 -0
  416. package/net/socket.lua +26 -0
  417. package/network.d.ts +31 -0
  418. package/network.lua +194 -0
  419. package/objutil/ability.d.ts +710 -0
  420. package/objutil/ability.lua +3781 -0
  421. package/objutil/buff.d.ts +110 -0
  422. package/objutil/buff.lua +769 -0
  423. package/objutil/dummy.d.ts +2 -0
  424. package/objutil/dummy.lua +49 -0
  425. package/objutil/idgen.d.ts +9 -0
  426. package/objutil/idgen.lua +92 -0
  427. package/objutil/item.d.ts +38 -0
  428. package/objutil/item.lua +254 -0
  429. package/objutil/object.d.ts +43 -0
  430. package/objutil/object.lua +213 -0
  431. package/objutil/unit.d.ts +134 -0
  432. package/objutil/unit.lua +913 -0
  433. package/objutil/upgrade.d.ts +22 -0
  434. package/objutil/upgrade.lua +127 -0
  435. package/operation.d.ts +35 -0
  436. package/operation.lua +179 -0
  437. package/package.json +47 -0
  438. package/patch-lualib.d.ts +2 -0
  439. package/patch-lualib.lua +67 -0
  440. package/patch-natives.d.ts +11 -0
  441. package/patch-natives.lua +14 -0
  442. package/string.d.ts +106 -0
  443. package/string.lua +34 -0
  444. package/time/dayOfWeek.d.ts +97 -0
  445. package/time/dayOfWeek.lua +53 -0
  446. package/time/localDate.d.ts +145 -0
  447. package/time/localDate.lua +236 -0
  448. package/time/localDateTime.d.ts +133 -0
  449. package/time/localDateTime.lua +154 -0
  450. package/time/localTime.d.ts +87 -0
  451. package/time/localTime.lua +91 -0
  452. package/time/month.d.ts +146 -0
  453. package/time/month.lua +129 -0
  454. package/time/year.d.ts +117 -0
  455. package/time/year.lua +81 -0
  456. package/types.d.ts +13 -0
  457. package/types.lua +0 -0
  458. package/util/objectPool.d.ts +6 -0
  459. package/util/objectPool.lua +28 -0
  460. package/util/stream.d.ts +29 -0
  461. package/util/stream.lua +453 -0
  462. package/util/stringBuilder.d.ts +8 -0
  463. package/util/stringBuilder.lua +25 -0
  464. package/utility/arrays.d.ts +57 -0
  465. package/utility/arrays.lua +369 -0
  466. package/utility/base64.d.ts +23 -0
  467. package/utility/base64.lua +177 -0
  468. package/utility/bit-set.d.ts +18 -0
  469. package/utility/bit-set.lua +12 -0
  470. package/utility/functions.d.ts +5 -0
  471. package/utility/functions.lua +90 -0
  472. package/utility/json.d.ts +2 -0
  473. package/utility/json.lua +400 -0
  474. package/utility/linked-set.d.ts +49 -0
  475. package/utility/linked-set.lua +181 -0
  476. package/utility/lua-maps.d.ts +6 -0
  477. package/utility/lua-maps.lua +25 -0
  478. package/utility/lua-sets.d.ts +6 -0
  479. package/utility/lua-sets.lua +37 -0
  480. package/utility/lzw.d.ts +2 -0
  481. package/utility/lzw.lua +161 -0
  482. package/utility/observable-array.d.ts +17 -0
  483. package/utility/observable-array.lua +30 -0
  484. package/utility/preconditions.d.ts +23 -0
  485. package/utility/preconditions.lua +58 -0
  486. package/utility/records.d.ts +3 -0
  487. package/utility/records.lua +9 -0
  488. package/utility/reflection.d.ts +4 -0
  489. package/utility/reflection.lua +31 -0
  490. package/utility/strings.d.ts +2 -0
  491. package/utility/strings.lua +44 -0
  492. package/utility/types.d.ts +39 -0
  493. package/utility/types.lua +2 -0
@@ -0,0 +1,95 @@
1
+ local ____lualib = require("lualib_bundle")
2
+ local __TS__Class = ____lualib.__TS__Class
3
+ local __TS__ClassExtends = ____lualib.__TS__ClassExtends
4
+ local __TS__SetDescriptor = ____lualib.__TS__SetDescriptor
5
+ local ____exports = {}
6
+ local ____color = require("core.types.color")
7
+ local Color = ____color.Color
8
+ local ____handle = require("core.types.handle")
9
+ local Handle = ____handle.Handle
10
+ local createTimerDialog = CreateTimerDialog
11
+ local destroyTimerDialog = DestroyTimerDialog
12
+ local timerDialogSetTitle = TimerDialogSetTitle
13
+ local timerDialogSetTitleColor = TimerDialogSetTitleColor
14
+ local timerDialogSetTimeColor = TimerDialogSetTimeColor
15
+ local isTimerDialogDisplayed = IsTimerDialogDisplayed
16
+ local timerDialogDisplay = TimerDialogDisplay
17
+ ____exports.TimerDialog = __TS__Class()
18
+ local TimerDialog = ____exports.TimerDialog
19
+ TimerDialog.name = "TimerDialog"
20
+ __TS__ClassExtends(TimerDialog, Handle)
21
+ function TimerDialog.prototype.onDestroy(self)
22
+ destroyTimerDialog(self.handle)
23
+ return Handle.prototype.onDestroy(self)
24
+ end
25
+ function TimerDialog.create(self, timer)
26
+ return ____exports.TimerDialog:of(createTimerDialog(timer.handle))
27
+ end
28
+ __TS__SetDescriptor(
29
+ TimerDialog.prototype,
30
+ "title",
31
+ {
32
+ get = function(self)
33
+ return self._title or ""
34
+ end,
35
+ set = function(self, v)
36
+ timerDialogSetTitle(self.handle, v)
37
+ self._title = v
38
+ end
39
+ },
40
+ true
41
+ )
42
+ __TS__SetDescriptor(
43
+ TimerDialog.prototype,
44
+ "titleColor",
45
+ {
46
+ get = function(self)
47
+ return self._titleColor or Color.white
48
+ end,
49
+ set = function(self, v)
50
+ timerDialogSetTitleColor(
51
+ self.handle,
52
+ v.r,
53
+ v.g,
54
+ v.b,
55
+ v.a
56
+ )
57
+ self._titleColor = v
58
+ end
59
+ },
60
+ true
61
+ )
62
+ __TS__SetDescriptor(
63
+ TimerDialog.prototype,
64
+ "timeColor",
65
+ {
66
+ get = function(self)
67
+ return self._timeColor or Color.white
68
+ end,
69
+ set = function(self, v)
70
+ timerDialogSetTimeColor(
71
+ self.handle,
72
+ v.r,
73
+ v.g,
74
+ v.b,
75
+ v.a
76
+ )
77
+ self._timeColor = v
78
+ end
79
+ },
80
+ true
81
+ )
82
+ __TS__SetDescriptor(
83
+ TimerDialog.prototype,
84
+ "visible",
85
+ {
86
+ get = function(self)
87
+ return isTimerDialogDisplayed(self.handle)
88
+ end,
89
+ set = function(self, v)
90
+ timerDialogDisplay(self.handle, v)
91
+ end
92
+ },
93
+ true
94
+ )
95
+ return ____exports
@@ -0,0 +1,10 @@
1
+ /** @noSelfInFile */
2
+ import "../../engine/internal/unit";
3
+ import "../../engine/internal/unit/ability";
4
+ import "../../engine/internal/unit+damage";
5
+ import "../../engine/internal/unit+rally";
6
+ import "../../engine/internal/unit+spellSteal";
7
+ import "../../engine/internal/unit+transport";
8
+ export * from "../../engine/internal/unit";
9
+ export * from "../../engine/internal/unit+damage";
10
+ export * from "../../engine/internal/unit+rally";
@@ -0,0 +1,24 @@
1
+ local ____exports = {}
2
+ require("engine.internal.unit")
3
+ require("engine.internal.unit.ability")
4
+ require("engine.internal.unit+damage")
5
+ require("engine.internal.unit+rally")
6
+ require("engine.internal.unit+spellSteal")
7
+ require("engine.internal.unit+transport")
8
+ do
9
+ local ____export = require("engine.internal.unit")
10
+ for ____exportKey, ____exportValue in pairs(____export) do
11
+ if ____exportKey ~= "default" then
12
+ ____exports[____exportKey] = ____exportValue
13
+ end
14
+ end
15
+ end
16
+ do
17
+ local ____export = require("engine.internal.unit+damage")
18
+ for ____exportKey, ____exportValue in pairs(____export) do
19
+ if ____exportKey ~= "default" then
20
+ ____exports[____exportKey] = ____exportValue
21
+ end
22
+ end
23
+ end
24
+ return ____exports
@@ -0,0 +1,5 @@
1
+ /** @noSelfInFile */
2
+ import { Unit } from "./unit";
3
+ import { Item } from "./item";
4
+ import { Destructable } from "./destructable";
5
+ export type Widget = Unit | Item | Destructable;
@@ -0,0 +1,2 @@
1
+ local ____exports = {}
2
+ return ____exports
package/core/util.d.ts ADDED
@@ -0,0 +1,62 @@
1
+ /** @noSelfInFile */
2
+ /** @noselfinfile */
3
+ declare global {
4
+ interface Destroyable {
5
+ destroy(): void;
6
+ }
7
+ }
8
+ declare namespace ns {
9
+ /**
10
+ * Converts a numeric rawid into its string representation.
11
+ */
12
+ function id2s(id: number | string): string;
13
+ /**
14
+ * Converts a string rawid into its numeric representation.
15
+ */
16
+ function s2id(id: string | number): number;
17
+ /**
18
+ * Creates a "context" object unique to the specified id,
19
+ * that will stay the same even across map reloads.
20
+ */
21
+ function context<T>(id: string, initial: T): T;
22
+ /**
23
+ * Same as @see context , but uses a closure to compute the
24
+ * context value. The closure will be ran exactly once for
25
+ * each unique id.
26
+ */
27
+ function contextFn<T>(id: string, initializer: () => T): T;
28
+ /**
29
+ * Clones an array, preserving order.
30
+ */
31
+ function cloneArray<T>(array: readonly T[]): T[];
32
+ }
33
+ declare global {
34
+ var util: typeof ns;
35
+ }
36
+ declare global {
37
+ interface String {
38
+ /**
39
+ * Partitions a string into equal-sized chunks. The last chunk may be smaller if
40
+ * the string is not equally divisible by the specified length.
41
+ *
42
+ * @param length size of chunk
43
+ */
44
+ partition(length: number): string[];
45
+ }
46
+ }
47
+ type KeysOfType<T, U> = {
48
+ [P in Exclude<keyof T, "hook">]: T[P] extends U ? P : never;
49
+ }[Exclude<keyof T, "hook">];
50
+ declare global {
51
+ function hook<P extends KeysOfType<typeof globalThis, Exclude<(...args: any[]) => void, Record<string, unknown>>>>(p: P, hook: (...args: Parameters<(typeof globalThis)[P]>) => void): void;
52
+ }
53
+ declare global {
54
+ function fourCC(id: string): number;
55
+ }
56
+ declare namespace inner {
57
+ const orderId: (id: "blink" | "stop" | "load" | "sleep" | "absorb" | "acidbomb" | "acolyteharvest" | "ambush" | "ancestralspirit" | "ancestralspirittarget" | "animatedead" | "antimagicshell" | "attack" | "attackground" | "attackonce" | "attributemodskill" | "auraunholy" | "auravampiric" | "autodispel" | "autodispeloff" | "autodispelon" | "autoentangle" | "autoentangleinstant" | "autoharvestgold" | "autoharvestlumber" | "avatar" | "avengerform" | "awaken" | "banish" | "barkskin" | "barkskinoff" | "barkskinon" | "battleroar" | "battlestations" | "bearform" | "berserk" | "blackarrow" | "blackarrowoff" | "blackarrowon" | "blight" | "blizzard" | "bloodlust" | "bloodlustoff" | "bloodluston" | "board" | "breathoffire" | "breathoffrost" | "build" | "burrow" | "cannibalize" | "carrionscarabs" | "carrionscarabsinstant" | "carrionscarabsoff" | "carrionscarabson" | "carrionswarm" | "chainlightning" | "channel" | "charm" | "chemicalrage" | "cloudoffog" | "clusterrockets" | "coldarrows" | "coldarrowstarg" | "controlmagic" | "corporealform" | "corrosivebreath" | "coupleinstant" | "coupletarget" | "creepanimatedead" | "creepdevour" | "creepheal" | "creephealoff" | "creephealon" | "creepthunderbolt" | "creepthunderclap" | "cripple" | "curse" | "curseoff" | "curseon" | "cyclone" | "darkconversion" | "darkportal" | "darkritual" | "darksummoning" | "deathanddecay" | "deathcoil" | "deathpact" | "decouple" | "defend" | "detectaoe" | "detonate" | "devour" | "devourmagic" | "disassociate" | "disenchant" | "dismount" | "dispel" | "divineshield" | "doom" | "drain" | "dreadlordinferno" | "dropitem" | "drunkenhaze" | "earthquake" | "eattree" | "elementalfury" | "ensnare" | "ensnareoff" | "ensnareon" | "entangle" | "entangleinstant" | "entanglingroots" | "etherealform" | "evileye" | "faeriefire" | "faeriefireoff" | "faeriefireon" | "fanofknives" | "farsight" | "fingerofdeath" | "firebolt" | "flamestrike" | "flamingarrows" | "flamingarrowstarg" | "flamingattack" | "flamingattacktarg" | "flare" | "forceboard" | "forceofnature" | "forkedlightning" | "freezingbreath" | "frenzy" | "frenzyoff" | "frenzyon" | "frostarmor" | "frostarmoroff" | "frostarmoron" | "frostnova" | "getitem" | "gold2lumber" | "grabtree" | "harvest" | "heal" | "healingspray" | "healingward" | "healingwave" | "healoff" | "healon" | "hex" | "holdposition" | "holybolt" | "howlofterror" | "humanbuild" | "immolation" | "impale" | "incineratearrow" | "incineratearrowoff" | "incineratearrowon" | "inferno" | "innerfire" | "innerfireoff" | "innerfireon" | "instant" | "invisibility" | "lavamonster" | "lightningshield" | "loadarcher" | "loadcorpse" | "loadcorpseinstant" | "locustswarm" | "lumber2gold" | "magicdefense" | "magicleash" | "magicundefense" | "manaburn" | "manaflareoff" | "manaflareon" | "manashieldoff" | "manashieldon" | "massteleport" | "mechanicalcritter" | "metamorphosis" | "militia" | "militiaconvert" | "militiaoff" | "militiaunconvert" | "mindrot" | "mirrorimage" | "monsoon" | "mount" | "mounthippogryph" | "move" | "moveAI" | "nagabuild" | "neutraldetectaoe" | "neutralinteract" | "neutralspell" | "nightelfbuild" | "orcbuild" | "parasite" | "parasiteoff" | "parasiteon" | "patrol" | "patrolAI" | "phaseshift" | "phaseshiftinstant" | "phaseshiftoff" | "phaseshifton" | "phoenixfire" | "phoenixmorph" | "poisonarrows" | "poisonarrowstarg" | "polymorph" | "possession" | "preservation" | "purge" | "rainofchaos" | "rainoffire" | "raisedead" | "raisedeadoff" | "raisedeadon" | "ravenform" | "recharge" | "rechargeoff" | "rechargeon" | "rejuvination" | "renew" | "renewoff" | "renewon" | "repair" | "repairoff" | "repairon" | "replenish" | "replenishlife" | "replenishlifeoff" | "replenishlifeon" | "replenishmana" | "replenishmanaoff" | "replenishmanaon" | "replenishoff" | "replenishon" | "request_hero" | "requestsacrifice" | "restoration" | "restorationoff" | "restorationon" | "resumebuild" | "resumeharvesting" | "resurrection" | "returnresources" | "revenge" | "revive" | "roar" | "robogoblin" | "root" | "sacrifice" | "sanctuary" | "scout" | "selfdestruct" | "selfdestructoff" | "selfdestructon" | "sentinel" | "follow" | "smart" | "setrally" | "shadowsight" | "shadowstrike" | "shockwave" | "silence" | "slow" | "slowoff" | "slowon" | "soulburn" | "soulpreservation" | "spellshield" | "spellshieldaoe" | "spellsteal" | "spellstealoff" | "spellstealon" | "spies" | "spiritlink" | "spiritofvengeance" | "spirittroll" | "spiritwolf" | "stampede" | "standdown" | "starfall" | "stasistrap" | "steal" | "stomp" | "stoneform" | "stunned" | "submerge" | "summonfactory" | "summongrizzly" | "summonphoenix" | "summonquillbeast" | "summonwareagle" | "tankdroppilot" | "tankloadpilot" | "tankpilot" | "taunt" | "thunderbolt" | "thunderclap" | "tornado" | "townbelloff" | "townbellon" | "tranquility" | "transmute" | "unavatar" | "unavengerform" | "unbearform" | "unburrow" | "uncoldarrows" | "uncorporealform" | "undeadbuild" | "undefend" | "undivineshield" | "unetherealform" | "unflamingarrows" | "unflamingattack" | "unholyfrenzy" | "unimmolation" | "unload" | "unloadall" | "unloadallcorpses" | "unloadallinstant" | "unpoisonarrows" | "unravenform" | "unrobogoblin" | "unroot" | "unstableconcoction" | "unstoneform" | "unsubmerge" | "unsummon" | "unwindwalk" | "vengeance" | "vengeanceinstant" | "vengeanceoff" | "vengeanceon" | "volcano" | "voodoo" | "ward" | "waterelemental" | "wateryminion" | "web" | "weboff" | "webon" | "whirlwind" | "windwalk" | "wispharvest") => number;
58
+ }
59
+ declare global {
60
+ function orderId(...args: Parameters<typeof inner.orderId>): ReturnType<typeof inner.orderId>;
61
+ }
62
+ export {};
package/core/util.lua ADDED
@@ -0,0 +1,464 @@
1
+ local ____exports = {}
2
+ local ns = {}
3
+ do
4
+ --- Converts a numeric rawid into its string representation.
5
+ function ns.id2s(id)
6
+ if type(id) == "string" then
7
+ return id
8
+ else
9
+ return string.pack(">I4", id)
10
+ end
11
+ end
12
+ --- Converts a string rawid into its numeric representation.
13
+ function ns.s2id(id)
14
+ if type(id) == "number" then
15
+ return id
16
+ else
17
+ local numid = string.unpack(">I4", id)
18
+ return numid
19
+ end
20
+ end
21
+ _G.__contexts = _G.__contexts or ({})
22
+ local contexts = _G.__contexts
23
+ --- Creates a "context" object unique to the specified id,
24
+ -- that will stay the same even across map reloads.
25
+ function ns.context(id, initial)
26
+ contexts[id] = contexts[id] or initial
27
+ return contexts[id]
28
+ end
29
+ --- Same as
30
+ --
31
+ -- @see context , but uses a closure to compute the
32
+ -- context value. The closure will be ran exactly once for
33
+ -- each unique id.
34
+ function ns.contextFn(id, initializer)
35
+ if contexts[id] ~= nil then
36
+ return contexts[id]
37
+ else
38
+ local v = initializer()
39
+ contexts[id] = v
40
+ return v
41
+ end
42
+ end
43
+ --- Clones an array, preserving order.
44
+ function ns.cloneArray(array)
45
+ local clone = {}
46
+ for i = 1, #array do
47
+ clone[i] = array[i]
48
+ end
49
+ return clone
50
+ end
51
+ end
52
+ _G.util = ns
53
+ do
54
+ local ceil = math.ceil
55
+ local sub = string.sub
56
+ _G.string.partition = function(s, length)
57
+ local list = {}
58
+ local i = 1
59
+ for pos = 0, (ceil(#s / length) - 1) * length, length do
60
+ list[i] = sub(s, pos + 1, pos + length)
61
+ i = i + 1
62
+ end
63
+ return list
64
+ end
65
+ end
66
+ do
67
+ local hooked
68
+ function hooked(func, hooks)
69
+ return function(...)
70
+ local result = func(...)
71
+ for i = 1, #hooks do
72
+ hooks[i](...)
73
+ end
74
+ return result
75
+ end
76
+ end
77
+ local hooks = {}
78
+ local function hook(p, hook)
79
+ local list = hooks[p]
80
+ if not list then
81
+ list = {}
82
+ _G[p] = hooked(_G[p], list)
83
+ hooks[p] = list
84
+ end
85
+ list[#list + 1] = hook
86
+ end
87
+ _G.hook = hook
88
+ end
89
+ macro_define(
90
+ "fourCC",
91
+ function(id)
92
+ return tostring(util.s2id(id)) .. " "
93
+ end
94
+ )
95
+ _G.fourCC = util.s2id
96
+ local inner = {}
97
+ do
98
+ inner.orderId = (function()
99
+ local orders = {
100
+ absorb = 852529,
101
+ acidbomb = 852662,
102
+ acolyteharvest = 852185,
103
+ ambush = 852131,
104
+ ancestralspirit = 852490,
105
+ ancestralspirittarget = 852491,
106
+ animatedead = 852217,
107
+ antimagicshell = 852186,
108
+ attack = 851983,
109
+ attackground = 851984,
110
+ attackonce = 851985,
111
+ attributemodskill = 852576,
112
+ auraunholy = 852215,
113
+ auravampiric = 852216,
114
+ autodispel = 852132,
115
+ autodispeloff = 852134,
116
+ autodispelon = 852133,
117
+ autoentangle = 852505,
118
+ autoentangleinstant = 852506,
119
+ autoharvestgold = 852021,
120
+ autoharvestlumber = 852022,
121
+ avatar = 852086,
122
+ avengerform = 852531,
123
+ awaken = 852466,
124
+ banish = 852486,
125
+ barkskin = 852135,
126
+ barkskinoff = 852137,
127
+ barkskinon = 852136,
128
+ battleroar = 852599,
129
+ battlestations = 852099,
130
+ bearform = 852138,
131
+ berserk = 852100,
132
+ blackarrow = 852577,
133
+ blackarrowoff = 852579,
134
+ blackarrowon = 852578,
135
+ blight = 852187,
136
+ blink = 852525,
137
+ blizzard = 852089,
138
+ bloodlust = 852101,
139
+ bloodlustoff = 852103,
140
+ bloodluston = 852102,
141
+ board = 852043,
142
+ breathoffire = 852580,
143
+ breathoffrost = 852560,
144
+ build = 851994,
145
+ burrow = 852533,
146
+ cannibalize = 852188,
147
+ carrionscarabs = 852551,
148
+ carrionscarabsinstant = 852554,
149
+ carrionscarabsoff = 852553,
150
+ carrionscarabson = 852552,
151
+ carrionswarm = 852218,
152
+ chainlightning = 852119,
153
+ channel = 852600,
154
+ charm = 852581,
155
+ chemicalrage = 852663,
156
+ cloudoffog = 852473,
157
+ clusterrockets = 852652,
158
+ coldarrows = 852244,
159
+ coldarrowstarg = 852243,
160
+ controlmagic = 852474,
161
+ corporealform = 852493,
162
+ corrosivebreath = 852140,
163
+ coupleinstant = 852508,
164
+ coupletarget = 852507,
165
+ creepanimatedead = 852246,
166
+ creepdevour = 852247,
167
+ creepheal = 852248,
168
+ creephealoff = 852250,
169
+ creephealon = 852249,
170
+ creepthunderbolt = 852252,
171
+ creepthunderclap = 852253,
172
+ cripple = 852189,
173
+ curse = 852190,
174
+ curseoff = 852192,
175
+ curseon = 852191,
176
+ cyclone = 852144,
177
+ darkconversion = 852228,
178
+ darkportal = 852229,
179
+ darkritual = 852219,
180
+ darksummoning = 852220,
181
+ deathanddecay = 852221,
182
+ deathcoil = 852222,
183
+ deathpact = 852223,
184
+ decouple = 852509,
185
+ defend = 852055,
186
+ detectaoe = 852015,
187
+ detonate = 852145,
188
+ devour = 852104,
189
+ devourmagic = 852536,
190
+ disassociate = 852240,
191
+ disenchant = 852495,
192
+ dismount = 852470,
193
+ dispel = 852057,
194
+ divineshield = 852090,
195
+ doom = 852583,
196
+ drain = 852487,
197
+ dreadlordinferno = 852224,
198
+ dropitem = 852001,
199
+ drunkenhaze = 852585,
200
+ earthquake = 852121,
201
+ eattree = 852146,
202
+ elementalfury = 852586,
203
+ ensnare = 852106,
204
+ ensnareoff = 852108,
205
+ ensnareon = 852107,
206
+ entangle = 852147,
207
+ entangleinstant = 852148,
208
+ entanglingroots = 852171,
209
+ etherealform = 852496,
210
+ evileye = 852105,
211
+ faeriefire = 852149,
212
+ faeriefireoff = 852151,
213
+ faeriefireon = 852150,
214
+ fanofknives = 852526,
215
+ farsight = 852122,
216
+ fingerofdeath = 852230,
217
+ firebolt = 852231,
218
+ flamestrike = 852488,
219
+ flamingarrows = 852174,
220
+ flamingarrowstarg = 852173,
221
+ flamingattack = 852540,
222
+ flamingattacktarg = 852539,
223
+ flare = 852060,
224
+ forceboard = 852044,
225
+ forceofnature = 852176,
226
+ forkedlightning = 852587,
227
+ freezingbreath = 852195,
228
+ frenzy = 852561,
229
+ frenzyoff = 852563,
230
+ frenzyon = 852562,
231
+ frostarmor = 852225,
232
+ frostarmoroff = 852459,
233
+ frostarmoron = 852458,
234
+ frostnova = 852226,
235
+ getitem = 851981,
236
+ gold2lumber = 852233,
237
+ grabtree = 852511,
238
+ harvest = 852018,
239
+ heal = 852063,
240
+ healingspray = 852664,
241
+ healingward = 852109,
242
+ healingwave = 852501,
243
+ healoff = 852065,
244
+ healon = 852064,
245
+ hex = 852502,
246
+ holdposition = 851993,
247
+ holybolt = 852092,
248
+ howlofterror = 852588,
249
+ humanbuild = 851995,
250
+ immolation = 852177,
251
+ impale = 852555,
252
+ incineratearrow = 852670,
253
+ incineratearrowoff = 852672,
254
+ incineratearrowon = 852671,
255
+ inferno = 852232,
256
+ innerfire = 852066,
257
+ innerfireoff = 852068,
258
+ innerfireon = 852067,
259
+ instant = 852200,
260
+ invisibility = 852069,
261
+ lavamonster = 852667,
262
+ lightningshield = 852110,
263
+ load = 852046,
264
+ loadarcher = 852142,
265
+ loadcorpse = 852050,
266
+ loadcorpseinstant = 852053,
267
+ locustswarm = 852556,
268
+ lumber2gold = 852234,
269
+ magicdefense = 852478,
270
+ magicleash = 852480,
271
+ magicundefense = 852479,
272
+ manaburn = 852179,
273
+ manaflareoff = 852513,
274
+ manaflareon = 852512,
275
+ manashieldoff = 852590,
276
+ manashieldon = 852589,
277
+ massteleport = 852093,
278
+ mechanicalcritter = 852564,
279
+ metamorphosis = 852180,
280
+ militia = 852072,
281
+ militiaconvert = 852071,
282
+ militiaoff = 852073,
283
+ militiaunconvert = 852651,
284
+ mindrot = 852565,
285
+ mirrorimage = 852123,
286
+ monsoon = 852591,
287
+ mount = 852469,
288
+ mounthippogryph = 852143,
289
+ move = 851986,
290
+ moveAI = 851988,
291
+ nagabuild = 852467,
292
+ neutraldetectaoe = 852023,
293
+ neutralinteract = 852566,
294
+ neutralspell = 852630,
295
+ nightelfbuild = 851997,
296
+ orcbuild = 851996,
297
+ parasite = 852601,
298
+ parasiteoff = 852603,
299
+ parasiteon = 852602,
300
+ patrol = 851990,
301
+ patrolAI = 851991,
302
+ phaseshift = 852514,
303
+ phaseshiftinstant = 852517,
304
+ phaseshiftoff = 852516,
305
+ phaseshifton = 852515,
306
+ phoenixfire = 852481,
307
+ phoenixmorph = 852482,
308
+ poisonarrows = 852255,
309
+ poisonarrowstarg = 852254,
310
+ polymorph = 852074,
311
+ possession = 852196,
312
+ preservation = 852568,
313
+ purge = 852111,
314
+ rainofchaos = 852237,
315
+ rainoffire = 852238,
316
+ raisedead = 852197,
317
+ raisedeadoff = 852199,
318
+ raisedeadon = 852198,
319
+ ravenform = 852155,
320
+ recharge = 852157,
321
+ rechargeoff = 852159,
322
+ rechargeon = 852158,
323
+ rejuvination = 852160,
324
+ renew = 852161,
325
+ renewoff = 852163,
326
+ renewon = 852162,
327
+ repair = 852024,
328
+ repairoff = 852026,
329
+ repairon = 852025,
330
+ replenish = 852542,
331
+ replenishlife = 852545,
332
+ replenishlifeoff = 852547,
333
+ replenishlifeon = 852546,
334
+ replenishmana = 852548,
335
+ replenishmanaoff = 852550,
336
+ replenishmanaon = 852549,
337
+ replenishoff = 852544,
338
+ replenishon = 852543,
339
+ request_hero = 852239,
340
+ requestsacrifice = 852201,
341
+ restoration = 852202,
342
+ restorationoff = 852204,
343
+ restorationon = 852203,
344
+ resumebuild = 851999,
345
+ resumeharvesting = 852017,
346
+ resurrection = 852094,
347
+ returnresources = 852020,
348
+ revenge = 852241,
349
+ revive = 852039,
350
+ roar = 852164,
351
+ robogoblin = 852656,
352
+ root = 852165,
353
+ sacrifice = 852205,
354
+ sanctuary = 852569,
355
+ scout = 852181,
356
+ selfdestruct = 852040,
357
+ selfdestructoff = 852042,
358
+ selfdestructon = 852041,
359
+ sentinel = 852182,
360
+ follow = 851970,
361
+ smart = 851971,
362
+ setrally = 851980,
363
+ shadowsight = 852570,
364
+ shadowstrike = 852527,
365
+ shockwave = 852125,
366
+ silence = 852592,
367
+ sleep = 852227,
368
+ slow = 852075,
369
+ slowoff = 852077,
370
+ slowon = 852076,
371
+ soulburn = 852668,
372
+ soulpreservation = 852242,
373
+ spellshield = 852571,
374
+ spellshieldaoe = 852572,
375
+ spellsteal = 852483,
376
+ spellstealoff = 852485,
377
+ spellstealon = 852484,
378
+ spies = 852235,
379
+ spiritlink = 852499,
380
+ spiritofvengeance = 852528,
381
+ spirittroll = 852573,
382
+ spiritwolf = 852126,
383
+ stampede = 852593,
384
+ standdown = 852113,
385
+ starfall = 852183,
386
+ stasistrap = 852114,
387
+ steal = 852574,
388
+ stomp = 852127,
389
+ stoneform = 852206,
390
+ stop = 851972,
391
+ stunned = 851973,
392
+ submerge = 852604,
393
+ summonfactory = 852658,
394
+ summongrizzly = 852594,
395
+ summonphoenix = 852489,
396
+ summonquillbeast = 852595,
397
+ summonwareagle = 852596,
398
+ tankdroppilot = 852079,
399
+ tankloadpilot = 852080,
400
+ tankpilot = 852081,
401
+ taunt = 852520,
402
+ thunderbolt = 852095,
403
+ thunderclap = 852096,
404
+ tornado = 852597,
405
+ townbelloff = 852083,
406
+ townbellon = 852082,
407
+ tranquility = 852184,
408
+ transmute = 852665,
409
+ unavatar = 852087,
410
+ unavengerform = 852532,
411
+ unbearform = 852139,
412
+ unburrow = 852534,
413
+ uncoldarrows = 852245,
414
+ uncorporealform = 852494,
415
+ undeadbuild = 851998,
416
+ undefend = 852056,
417
+ undivineshield = 852091,
418
+ unetherealform = 852497,
419
+ unflamingarrows = 852175,
420
+ unflamingattack = 852541,
421
+ unholyfrenzy = 852209,
422
+ unimmolation = 852178,
423
+ unload = 852047,
424
+ unloadall = 852048,
425
+ unloadallcorpses = 852054,
426
+ unloadallinstant = 852049,
427
+ unpoisonarrows = 852256,
428
+ unravenform = 852156,
429
+ unrobogoblin = 852657,
430
+ unroot = 852166,
431
+ unstableconcoction = 852500,
432
+ unstoneform = 852207,
433
+ unsubmerge = 852605,
434
+ unsummon = 852210,
435
+ unwindwalk = 852130,
436
+ vengeance = 852521,
437
+ vengeanceinstant = 852524,
438
+ vengeanceoff = 852523,
439
+ vengeanceon = 852522,
440
+ volcano = 852669,
441
+ voodoo = 852503,
442
+ ward = 852504,
443
+ waterelemental = 852097,
444
+ wateryminion = 852598,
445
+ web = 852211,
446
+ weboff = 852213,
447
+ webon = 852212,
448
+ whirlwind = 852128,
449
+ windwalk = 852129,
450
+ wispharvest = 852214
451
+ }
452
+ return function(id)
453
+ return orders[id] or 0
454
+ end
455
+ end)()
456
+ end
457
+ _G.orderId = inner.orderId
458
+ macro_define(
459
+ "orderId",
460
+ function(...)
461
+ return tostring(orderId(...)) .. " "
462
+ end
463
+ )
464
+ return ____exports