isaacscript-common 1.2.292 → 2.0.2

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 (482) hide show
  1. package/README.md +2 -2
  2. package/dist/cachedClasses.d.ts +1 -1
  3. package/dist/cachedClasses.lua +0 -1
  4. package/dist/callbacks/customRevive.lua +13 -8
  5. package/dist/callbacks/itemPickup.lua +3 -1
  6. package/dist/callbacks/postBombInitLate.lua +3 -1
  7. package/dist/callbacks/postBoneSwing.lua +5 -2
  8. package/dist/callbacks/postCollectibleInitFirst.lua +4 -1
  9. package/dist/callbacks/postCursedTeleport.lua +16 -8
  10. package/dist/callbacks/postCustomDoorEnter.d.ts +1 -1
  11. package/dist/callbacks/postCustomDoorEnter.lua +16 -10
  12. package/dist/callbacks/postEffectInitLate.lua +3 -1
  13. package/dist/callbacks/postEffectStateChanged.lua +3 -1
  14. package/dist/callbacks/postEsauJr.lua +5 -2
  15. package/dist/callbacks/postFamiliarInitLate.lua +3 -1
  16. package/dist/callbacks/postFamiliarStateChanged.lua +3 -1
  17. package/dist/callbacks/postFlip.lua +9 -5
  18. package/dist/callbacks/postGreedModeWave.d.ts +1 -0
  19. package/dist/callbacks/postGreedModeWave.lua +32 -0
  20. package/dist/callbacks/postGreedWave.d.ts +1 -0
  21. package/dist/callbacks/postGreedWave.lua +31 -0
  22. package/dist/callbacks/postGridEntity.lua +4 -2
  23. package/dist/callbacks/postGridEntityCollision.lua +5 -2
  24. package/dist/callbacks/postHolyMantleRemoved.lua +3 -1
  25. package/dist/callbacks/postItemDischarged.lua +10 -5
  26. package/dist/callbacks/postKnifeInitLate.lua +3 -1
  27. package/dist/callbacks/postLaserInitLate.lua +3 -1
  28. package/dist/callbacks/postNPCInitLate.lua +3 -1
  29. package/dist/callbacks/postNPCStateChanged.lua +3 -1
  30. package/dist/callbacks/postNewRoomEarly.lua +7 -5
  31. package/dist/callbacks/postPickupCollect.lua +3 -1
  32. package/dist/callbacks/postPickupInitLate.lua +3 -1
  33. package/dist/callbacks/postPickupStateChanged.lua +3 -1
  34. package/dist/callbacks/postPlayerChangeHealth.lua +2 -2
  35. package/dist/callbacks/postPlayerFatalDamage.lua +4 -1
  36. package/dist/callbacks/postPlayerInitLate.lua +3 -1
  37. package/dist/callbacks/postPlayerReordered.lua +7 -6
  38. package/dist/callbacks/postProjectileInitLate.lua +3 -1
  39. package/dist/callbacks/postRoomClearChanged.lua +4 -3
  40. package/dist/callbacks/postSacrifice.lua +8 -4
  41. package/dist/callbacks/postSlotInitUpdate.lua +4 -2
  42. package/dist/callbacks/postSlotRender.lua +3 -1
  43. package/dist/callbacks/postTearInitLate.lua +3 -1
  44. package/dist/callbacks/postTearInitVeryLate.lua +3 -1
  45. package/dist/callbacks/postTransformation.lua +7 -12
  46. package/dist/callbacks/postTrinketBreak.lua +8 -3
  47. package/dist/callbacks/preBerserkDeath.lua +3 -2
  48. package/dist/callbacks/preNewLevel.lua +5 -3
  49. package/dist/callbacks/reorderedCallbacks.lua +7 -5
  50. package/dist/callbacks/subscriptions/postBombInitLate.d.ts +5 -2
  51. package/dist/callbacks/subscriptions/postBombInitLate.lua +3 -3
  52. package/dist/callbacks/subscriptions/postBoneSwing.d.ts +3 -1
  53. package/dist/callbacks/subscriptions/postBoneSwing.lua +3 -3
  54. package/dist/callbacks/subscriptions/postCollectibleInitFirst.d.ts +5 -2
  55. package/dist/callbacks/subscriptions/postCollectibleInitFirst.lua +3 -3
  56. package/dist/callbacks/subscriptions/postCursedTeleport.d.ts +3 -1
  57. package/dist/callbacks/subscriptions/postCursedTeleport.lua +3 -3
  58. package/dist/callbacks/subscriptions/postCustomDoorEnter.d.ts +5 -2
  59. package/dist/callbacks/subscriptions/postCustomDoorEnter.lua +3 -3
  60. package/dist/callbacks/subscriptions/postCustomRevive.d.ts +4 -1
  61. package/dist/callbacks/subscriptions/postCustomRevive.lua +3 -3
  62. package/dist/callbacks/subscriptions/postEffectInitLate.d.ts +5 -2
  63. package/dist/callbacks/subscriptions/postEffectInitLate.lua +3 -3
  64. package/dist/callbacks/subscriptions/postEffectStateChanged.d.ts +5 -2
  65. package/dist/callbacks/subscriptions/postEffectStateChanged.lua +3 -3
  66. package/dist/callbacks/subscriptions/postEsauJr.d.ts +3 -1
  67. package/dist/callbacks/subscriptions/postEsauJr.lua +3 -3
  68. package/dist/callbacks/subscriptions/postFamiliarInitLate.d.ts +5 -2
  69. package/dist/callbacks/subscriptions/postFamiliarInitLate.lua +3 -3
  70. package/dist/callbacks/subscriptions/postFamiliarStateChanged.d.ts +5 -2
  71. package/dist/callbacks/subscriptions/postFamiliarStateChanged.lua +3 -3
  72. package/dist/callbacks/subscriptions/postFirstEsauJr.d.ts +3 -1
  73. package/dist/callbacks/subscriptions/postFirstEsauJr.lua +3 -3
  74. package/dist/callbacks/subscriptions/postFirstFlip.d.ts +3 -1
  75. package/dist/callbacks/subscriptions/postFirstFlip.lua +3 -3
  76. package/dist/callbacks/subscriptions/postFlip.d.ts +3 -1
  77. package/dist/callbacks/subscriptions/postFlip.lua +3 -3
  78. package/dist/callbacks/subscriptions/postGameStartedReordered.d.ts +3 -1
  79. package/dist/callbacks/subscriptions/postGameStartedReordered.lua +3 -3
  80. package/dist/callbacks/subscriptions/postGreedModeWave.d.ts +4 -0
  81. package/dist/callbacks/subscriptions/postGreedModeWave.lua +16 -0
  82. package/dist/callbacks/subscriptions/postGreedWave.d.ts +2 -0
  83. package/dist/callbacks/subscriptions/postGreedWave.lua +16 -0
  84. package/dist/callbacks/subscriptions/postGridEntityBroken.d.ts +5 -2
  85. package/dist/callbacks/subscriptions/postGridEntityBroken.lua +3 -3
  86. package/dist/callbacks/subscriptions/postGridEntityCollision.d.ts +5 -2
  87. package/dist/callbacks/subscriptions/postGridEntityCollision.lua +3 -3
  88. package/dist/callbacks/subscriptions/postGridEntityInit.d.ts +5 -2
  89. package/dist/callbacks/subscriptions/postGridEntityInit.lua +3 -3
  90. package/dist/callbacks/subscriptions/postGridEntityRemove.d.ts +5 -2
  91. package/dist/callbacks/subscriptions/postGridEntityRemove.lua +3 -3
  92. package/dist/callbacks/subscriptions/postGridEntityStateChanged.d.ts +5 -2
  93. package/dist/callbacks/subscriptions/postGridEntityStateChanged.lua +3 -3
  94. package/dist/callbacks/subscriptions/postGridEntityUpdate.d.ts +5 -2
  95. package/dist/callbacks/subscriptions/postGridEntityUpdate.lua +3 -3
  96. package/dist/callbacks/subscriptions/postHolyMantleRemoved.d.ts +6 -2
  97. package/dist/callbacks/subscriptions/postHolyMantleRemoved.lua +16 -4
  98. package/dist/callbacks/subscriptions/postItemDischarged.d.ts +5 -2
  99. package/dist/callbacks/subscriptions/postItemDischarged.lua +3 -3
  100. package/dist/callbacks/subscriptions/postItemPickup.d.ts +6 -2
  101. package/dist/callbacks/subscriptions/postItemPickup.lua +3 -3
  102. package/dist/callbacks/subscriptions/postKnifeInitLate.d.ts +5 -2
  103. package/dist/callbacks/subscriptions/postKnifeInitLate.lua +3 -3
  104. package/dist/callbacks/subscriptions/postLaserInitLate.d.ts +5 -2
  105. package/dist/callbacks/subscriptions/postLaserInitLate.lua +3 -3
  106. package/dist/callbacks/subscriptions/postNPCInitLate.d.ts +5 -2
  107. package/dist/callbacks/subscriptions/postNPCInitLate.lua +3 -3
  108. package/dist/callbacks/subscriptions/postNPCStateChanged.d.ts +6 -2
  109. package/dist/callbacks/subscriptions/postNPCStateChanged.lua +3 -3
  110. package/dist/callbacks/subscriptions/postNewLevelReordered.d.ts +1 -1
  111. package/dist/callbacks/subscriptions/postNewLevelReordered.lua +3 -3
  112. package/dist/callbacks/subscriptions/postNewRoomEarly.d.ts +1 -1
  113. package/dist/callbacks/subscriptions/postNewRoomEarly.lua +3 -3
  114. package/dist/callbacks/subscriptions/postNewRoomReordered.d.ts +1 -1
  115. package/dist/callbacks/subscriptions/postNewRoomReordered.lua +3 -3
  116. package/dist/callbacks/subscriptions/postPEffectUpdateReordered.d.ts +6 -2
  117. package/dist/callbacks/subscriptions/postPEffectUpdateReordered.lua +8 -4
  118. package/dist/callbacks/subscriptions/postPickupCollect.d.ts +5 -2
  119. package/dist/callbacks/subscriptions/postPickupCollect.lua +3 -3
  120. package/dist/callbacks/subscriptions/postPickupInitLate.d.ts +5 -2
  121. package/dist/callbacks/subscriptions/postPickupInitLate.lua +3 -3
  122. package/dist/callbacks/subscriptions/postPickupStateChanged.d.ts +5 -2
  123. package/dist/callbacks/subscriptions/postPickupStateChanged.lua +3 -3
  124. package/dist/callbacks/subscriptions/postPlayerChangeHealth.d.ts +5 -2
  125. package/dist/callbacks/subscriptions/postPlayerChangeHealth.lua +3 -3
  126. package/dist/callbacks/subscriptions/postPlayerChangeType.d.ts +4 -2
  127. package/dist/callbacks/subscriptions/postPlayerChangeType.lua +3 -3
  128. package/dist/callbacks/subscriptions/postPlayerFatalDamage.d.ts +5 -2
  129. package/dist/callbacks/subscriptions/postPlayerFatalDamage.lua +3 -3
  130. package/dist/callbacks/subscriptions/postPlayerInitLate.d.ts +5 -2
  131. package/dist/callbacks/subscriptions/postPlayerInitLate.lua +3 -3
  132. package/dist/callbacks/subscriptions/postPlayerInitReordered.d.ts +5 -2
  133. package/dist/callbacks/subscriptions/postPlayerInitReordered.lua +3 -3
  134. package/dist/callbacks/subscriptions/postPlayerRenderReordered.d.ts +5 -2
  135. package/dist/callbacks/subscriptions/postPlayerRenderReordered.lua +3 -3
  136. package/dist/callbacks/subscriptions/postPlayerUpdateReordered.d.ts +5 -2
  137. package/dist/callbacks/subscriptions/postPlayerUpdateReordered.lua +3 -3
  138. package/dist/callbacks/subscriptions/postProjectileInitLate.d.ts +5 -2
  139. package/dist/callbacks/subscriptions/postProjectileInitLate.lua +3 -3
  140. package/dist/callbacks/subscriptions/postPurchase.d.ts +6 -2
  141. package/dist/callbacks/subscriptions/postPurchase.lua +3 -3
  142. package/dist/callbacks/subscriptions/postRoomClearChanged.d.ts +3 -1
  143. package/dist/callbacks/subscriptions/postRoomClearChanged.lua +3 -3
  144. package/dist/callbacks/subscriptions/postSacrifice.d.ts +3 -1
  145. package/dist/callbacks/subscriptions/postSacrifice.lua +3 -3
  146. package/dist/callbacks/subscriptions/postSlotAnimationChanged.d.ts +5 -2
  147. package/dist/callbacks/subscriptions/postSlotAnimationChanged.lua +3 -3
  148. package/dist/callbacks/subscriptions/postSlotDestroyed.d.ts +5 -2
  149. package/dist/callbacks/subscriptions/postSlotDestroyed.lua +3 -3
  150. package/dist/callbacks/subscriptions/postSlotInit.d.ts +5 -2
  151. package/dist/callbacks/subscriptions/postSlotInit.lua +3 -3
  152. package/dist/callbacks/subscriptions/postSlotRender.d.ts +5 -2
  153. package/dist/callbacks/subscriptions/postSlotRender.lua +3 -3
  154. package/dist/callbacks/subscriptions/postSlotUpdate.d.ts +5 -2
  155. package/dist/callbacks/subscriptions/postSlotUpdate.lua +3 -3
  156. package/dist/callbacks/subscriptions/postTearInitLate.d.ts +5 -2
  157. package/dist/callbacks/subscriptions/postTearInitLate.lua +3 -3
  158. package/dist/callbacks/subscriptions/postTearInitVeryLate.d.ts +5 -2
  159. package/dist/callbacks/subscriptions/postTearInitVeryLate.lua +3 -3
  160. package/dist/callbacks/subscriptions/postTransformation.d.ts +5 -2
  161. package/dist/callbacks/subscriptions/postTransformation.lua +3 -3
  162. package/dist/callbacks/subscriptions/postTrinketBreak.d.ts +5 -2
  163. package/dist/callbacks/subscriptions/postTrinketBreak.lua +3 -3
  164. package/dist/callbacks/subscriptions/preBerserkDeath.d.ts +5 -2
  165. package/dist/callbacks/subscriptions/preBerserkDeath.lua +3 -3
  166. package/dist/callbacks/subscriptions/preCustomRevive.d.ts +3 -1
  167. package/dist/callbacks/subscriptions/preCustomRevive.lua +3 -3
  168. package/dist/callbacks/subscriptions/preItemPickup.d.ts +6 -2
  169. package/dist/callbacks/subscriptions/preItemPickup.lua +3 -3
  170. package/dist/callbacks/subscriptions/preNewLevel.d.ts +3 -1
  171. package/dist/callbacks/subscriptions/preNewLevel.lua +3 -3
  172. package/dist/classes/ModUpgraded.d.ts +5 -5
  173. package/dist/constants.d.ts +9 -43
  174. package/dist/constants.lua +16 -13
  175. package/dist/constantsMax.d.ts +16 -0
  176. package/dist/constantsMax.lua +27 -0
  177. package/dist/enums/CardType.lua +1 -1
  178. package/dist/enums/CollectiblePedestalType.lua +1 -1
  179. package/dist/enums/HealthType.d.ts +3 -3
  180. package/dist/enums/HealthType.lua +1 -2
  181. package/dist/enums/ModCallbacksCustom.d.ts +56 -48
  182. package/dist/enums/ModCallbacksCustom.lua +47 -46
  183. package/dist/enums/PillEffectClass.lua +1 -1
  184. package/dist/enums/PillEffectType.lua +1 -1
  185. package/dist/enums/PocketItemType.lua +1 -2
  186. package/dist/enums/SerializationType.lua +1 -2
  187. package/dist/enums/private/CopyableIsaacAPIClassType.d.ts +1 -1
  188. package/dist/enums/private/CopyableIsaacAPIClassType.lua +2 -3
  189. package/dist/enums/private/SaveDataKeys.d.ts +4 -4
  190. package/dist/enums/private/SaveDataKeys.lua +5 -6
  191. package/dist/enums/private/SerializationBrand.d.ts +3 -4
  192. package/dist/enums/private/SerializationBrand.lua +2 -15
  193. package/dist/features/characterHealthConversion.d.ts +2 -2
  194. package/dist/features/characterHealthConversion.lua +8 -4
  195. package/dist/features/characterStats.d.ts +4 -4
  196. package/dist/features/characterStats.lua +3 -1
  197. package/dist/features/debugDisplay.lua +12 -11
  198. package/dist/features/deployJSONRoom.d.ts +3 -3
  199. package/dist/features/deployJSONRoom.lua +35 -21
  200. package/dist/features/disableInputs.d.ts +1 -1
  201. package/dist/features/disableInputs.lua +6 -3
  202. package/dist/features/disableSound.lua +3 -1
  203. package/dist/features/extraConsoleCommands/commands.d.ts +5 -3
  204. package/dist/features/extraConsoleCommands/commands.lua +96 -56
  205. package/dist/features/extraConsoleCommands/commandsDisplay.lua +0 -1
  206. package/dist/features/extraConsoleCommands/commandsSubroutines.d.ts +1 -1
  207. package/dist/features/extraConsoleCommands/commandsSubroutines.lua +13 -10
  208. package/dist/features/extraConsoleCommands/init.lua +17 -9
  209. package/dist/features/extraConsoleCommands/v.lua +0 -1
  210. package/dist/features/fadeInRemover.lua +3 -2
  211. package/dist/features/fastReset.lua +7 -5
  212. package/dist/features/forgottenSwitch.lua +6 -3
  213. package/dist/features/getCollectibleItemPoolType.d.ts +1 -1
  214. package/dist/features/getCollectibleItemPoolType.lua +6 -2
  215. package/dist/features/isPonyActive.lua +5 -2
  216. package/dist/features/playerInventory.d.ts +1 -1
  217. package/dist/features/playerInventory.lua +7 -3
  218. package/dist/features/preventCollectibleRotate.d.ts +1 -1
  219. package/dist/features/preventCollectibleRotate.lua +9 -4
  220. package/dist/features/runInNFrames.lua +4 -2
  221. package/dist/features/saveDataManager/constants.lua +0 -1
  222. package/dist/features/saveDataManager/exports.d.ts +9 -8
  223. package/dist/features/saveDataManager/main.lua +11 -9
  224. package/dist/features/saveDataManager/maps.d.ts +5 -0
  225. package/dist/features/saveDataManager/merge.d.ts +1 -1
  226. package/dist/features/saveDataManager/merge.lua +2 -1
  227. package/dist/features/saveDataManager/serializationBrand.d.ts +1 -0
  228. package/dist/features/saveDataManager/serializationBrand.lua +17 -0
  229. package/dist/features/sirenHelpers.d.ts +1 -1
  230. package/dist/features/sirenHelpers.lua +5 -2
  231. package/dist/features/taintedLazarusPlayers.lua +6 -3
  232. package/dist/featuresInitialized.lua +0 -1
  233. package/dist/functions/array.d.ts +18 -2
  234. package/dist/functions/array.lua +29 -3
  235. package/dist/functions/bitwise.lua +0 -1
  236. package/dist/functions/boss.d.ts +1 -1
  237. package/dist/functions/boss.lua +12 -9
  238. package/dist/functions/cacheFlag.d.ts +2 -2
  239. package/dist/functions/cacheFlag.lua +0 -1
  240. package/dist/functions/cards.d.ts +9 -17
  241. package/dist/functions/cards.lua +22 -23
  242. package/dist/functions/challenges.d.ts +1 -1
  243. package/dist/functions/challenges.lua +0 -1
  244. package/dist/functions/character.d.ts +6 -4
  245. package/dist/functions/character.lua +16 -7
  246. package/dist/functions/charge.d.ts +1 -1
  247. package/dist/functions/charge.lua +14 -9
  248. package/dist/functions/chargeBar.lua +0 -1
  249. package/dist/functions/collectibleCacheFlag.d.ts +4 -4
  250. package/dist/functions/collectibleCacheFlag.lua +8 -5
  251. package/dist/functions/collectibleSet.d.ts +1 -1
  252. package/dist/functions/collectibleSet.lua +4 -5
  253. package/dist/functions/collectibleTag.d.ts +1 -2
  254. package/dist/functions/collectibleTag.lua +12 -10
  255. package/dist/functions/collectibles.d.ts +21 -28
  256. package/dist/functions/collectibles.lua +29 -26
  257. package/dist/functions/color.lua +9 -1
  258. package/dist/functions/debug.d.ts +12 -0
  259. package/dist/functions/debug.lua +3 -1
  260. package/dist/functions/deepCopy.d.ts +1 -1
  261. package/dist/functions/deepCopy.lua +4 -2
  262. package/dist/functions/direction.d.ts +4 -0
  263. package/dist/functions/direction.lua +17 -0
  264. package/dist/functions/doors.d.ts +12 -16
  265. package/dist/functions/doors.lua +34 -26
  266. package/dist/functions/easing.lua +0 -1
  267. package/dist/functions/entity.d.ts +4 -5
  268. package/dist/functions/entity.lua +4 -12
  269. package/dist/functions/entitySpecific.d.ts +35 -33
  270. package/dist/functions/entitySpecific.lua +20 -19
  271. package/dist/functions/enums.d.ts +70 -0
  272. package/dist/functions/enums.lua +71 -0
  273. package/dist/functions/familiars.d.ts +2 -2
  274. package/dist/functions/familiars.lua +0 -1
  275. package/dist/functions/flag.d.ts +42 -10
  276. package/dist/functions/flag.lua +31 -13
  277. package/dist/functions/flying.d.ts +2 -2
  278. package/dist/functions/flying.lua +20 -14
  279. package/dist/functions/globals.lua +5 -2
  280. package/dist/functions/gridEntity.d.ts +18 -16
  281. package/dist/functions/gridEntity.lua +39 -26
  282. package/dist/functions/input.d.ts +14 -3
  283. package/dist/functions/input.lua +39 -78
  284. package/dist/functions/jsonHelpers.d.ts +9 -7
  285. package/dist/functions/jsonHelpers.lua +0 -1
  286. package/dist/functions/kColor.lua +14 -3
  287. package/dist/functions/language.lua +9 -8
  288. package/dist/functions/log.d.ts +21 -15
  289. package/dist/functions/log.lua +61 -36
  290. package/dist/functions/math.d.ts +19 -8
  291. package/dist/functions/math.lua +33 -22
  292. package/dist/functions/mergeTests.lua +0 -1
  293. package/dist/functions/npc.d.ts +1 -1
  294. package/dist/functions/npc.lua +32 -16
  295. package/dist/functions/pickups.d.ts +10 -26
  296. package/dist/functions/pickups.lua +31 -29
  297. package/dist/functions/pills.d.ts +14 -13
  298. package/dist/functions/pills.lua +9 -3
  299. package/dist/functions/player.d.ts +11 -11
  300. package/dist/functions/player.lua +79 -66
  301. package/dist/functions/playerHealth.lua +19 -16
  302. package/dist/functions/playerIndex.d.ts +3 -3
  303. package/dist/functions/playerIndex.lua +9 -6
  304. package/dist/functions/pocketItems.d.ts +1 -1
  305. package/dist/functions/pocketItems.lua +21 -12
  306. package/dist/functions/positionVelocity.lua +4 -1
  307. package/dist/functions/random.d.ts +2 -3
  308. package/dist/functions/random.lua +0 -1
  309. package/dist/functions/revive.lua +18 -13
  310. package/dist/functions/roomData.d.ts +2 -2
  311. package/dist/functions/roomData.lua +11 -13
  312. package/dist/functions/roomGrid.d.ts +2 -2
  313. package/dist/functions/roomGrid.lua +0 -1
  314. package/dist/functions/roomShape.d.ts +2 -2
  315. package/dist/functions/rooms.d.ts +19 -14
  316. package/dist/functions/rooms.lua +42 -22
  317. package/dist/functions/run.d.ts +1 -1
  318. package/dist/functions/run.lua +3 -2
  319. package/dist/functions/seeds.d.ts +7 -0
  320. package/dist/functions/seeds.lua +7 -1
  321. package/dist/functions/sound.lua +4 -3
  322. package/dist/functions/spawnCollectible.d.ts +5 -5
  323. package/dist/functions/spawnCollectible.lua +7 -4
  324. package/dist/functions/sprite.d.ts +1 -1
  325. package/dist/functions/sprite.lua +3 -4
  326. package/dist/functions/stage.d.ts +4 -4
  327. package/dist/functions/stage.lua +3 -2
  328. package/dist/functions/string.d.ts +8 -1
  329. package/dist/functions/string.lua +10 -2
  330. package/dist/functions/tears.d.ts +4 -4
  331. package/dist/functions/tears.lua +0 -1
  332. package/dist/functions/transformations.d.ts +5 -3
  333. package/dist/functions/transformations.lua +31 -20
  334. package/dist/functions/trinketCacheFlag.d.ts +1 -1
  335. package/dist/functions/trinketCacheFlag.lua +8 -6
  336. package/dist/functions/trinketGive.d.ts +14 -3
  337. package/dist/functions/trinketGive.lua +46 -28
  338. package/dist/functions/trinketSet.d.ts +1 -1
  339. package/dist/functions/trinketSet.lua +4 -5
  340. package/dist/functions/trinkets.d.ts +8 -17
  341. package/dist/functions/trinkets.lua +17 -34
  342. package/dist/functions/ui.lua +7 -5
  343. package/dist/functions/utils.d.ts +1 -61
  344. package/dist/functions/utils.lua +3 -50
  345. package/dist/functions/vector.d.ts +1 -2
  346. package/dist/functions/vector.lua +8 -6
  347. package/dist/index.d.ts +4 -6
  348. package/dist/index.lua +17 -34
  349. package/dist/initCustomCallbacks.lua +3 -1
  350. package/dist/initFeatures.lua +0 -1
  351. package/dist/lualib_bundle.lua +14 -1
  352. package/dist/maps/cardMap.d.ts +1 -1
  353. package/dist/maps/characterMap.d.ts +1 -1
  354. package/dist/maps/collectibleDescriptionMap.d.ts +1 -1
  355. package/dist/maps/collectibleNameMap.d.ts +1 -1
  356. package/dist/maps/defaultPlayerStatMap.d.ts +1 -1
  357. package/dist/maps/defaultPlayerStatMap.lua +8 -6
  358. package/dist/maps/gridEntityTypeToBrokenStateMap.d.ts +1 -1
  359. package/dist/maps/gridEntityTypeToBrokenStateMap.lua +19 -12
  360. package/dist/maps/gridEntityXMLMap.d.ts +1 -1
  361. package/dist/maps/gridEntityXMLMap.lua +44 -34
  362. package/dist/maps/pillEffectMap.d.ts +1 -1
  363. package/dist/maps/roomShapeToTopLeftWallGridIndexMap.d.ts +1 -1
  364. package/dist/maps/roomShapeToTopLeftWallGridIndexMap.lua +7 -5
  365. package/dist/maps/roomTypeMap.d.ts +1 -1
  366. package/dist/maps/roomTypeMap.lua +37 -35
  367. package/dist/maps/trinketDescriptionMap.d.ts +1 -1
  368. package/dist/maps/trinketNameMap.d.ts +1 -1
  369. package/dist/objects/LRoomShapeToRectangles.d.ts +1 -1
  370. package/dist/objects/LRoomShapeToRectangles.lua +6 -5
  371. package/dist/objects/callbackRegisterFunctions.d.ts +2 -2
  372. package/dist/objects/callbackRegisterFunctions.lua +3 -1
  373. package/dist/objects/cardDescriptions.d.ts +1 -1
  374. package/dist/objects/cardDescriptions.lua +89 -90
  375. package/dist/objects/cardNames.d.ts +1 -1
  376. package/dist/objects/cardNames.lua +89 -90
  377. package/dist/objects/cardTypes.d.ts +3 -4
  378. package/dist/objects/cardTypes.lua +102 -104
  379. package/dist/objects/challengeNames.d.ts +1 -1
  380. package/dist/objects/challengeNames.lua +48 -48
  381. package/dist/objects/characterNames.d.ts +1 -1
  382. package/dist/objects/characterNames.lua +44 -44
  383. package/dist/objects/coinSubTypeToValue.d.ts +1 -1
  384. package/dist/objects/coinSubTypeToValue.lua +10 -8
  385. package/dist/objects/colors.lua +0 -1
  386. package/dist/objects/directionNames.d.ts +1 -1
  387. package/dist/objects/directionNames.lua +2 -1
  388. package/dist/objects/directionToDegrees.d.ts +1 -1
  389. package/dist/objects/directionToDegrees.lua +2 -1
  390. package/dist/objects/directionToVector.d.ts +1 -1
  391. package/dist/objects/directionToVector.lua +2 -1
  392. package/dist/objects/doorSlotFlagToDoorSlot.d.ts +5 -0
  393. package/dist/objects/doorSlotFlagToDoorSlot.lua +16 -0
  394. package/dist/objects/doorSlotToDirection.d.ts +1 -1
  395. package/dist/objects/doorSlotToDirection.lua +11 -10
  396. package/dist/objects/isaacAPIClassTypeToBrand.lua +1 -2
  397. package/dist/objects/isaacAPIClassTypeToCopyFunction.lua +1 -2
  398. package/dist/objects/pillEffectClasses.d.ts +3 -4
  399. package/dist/objects/pillEffectClasses.lua +55 -57
  400. package/dist/objects/pillEffectNames.d.ts +1 -1
  401. package/dist/objects/pillEffectNames.lua +52 -53
  402. package/dist/objects/pillEffectTypes.d.ts +3 -4
  403. package/dist/objects/pillEffectTypes.lua +54 -56
  404. package/dist/objects/roomShapeBounds.d.ts +1 -1
  405. package/dist/objects/roomShapeBounds.lua +14 -16
  406. package/dist/objects/roomShapeLayoutSizes.d.ts +1 -1
  407. package/dist/objects/roomShapeLayoutSizes.lua +14 -14
  408. package/dist/objects/roomShapeToBottomRightPosition.d.ts +1 -1
  409. package/dist/objects/roomShapeToBottomRightPosition.lua +14 -16
  410. package/dist/objects/roomShapeToDoorSlots.d.ts +1 -1
  411. package/dist/objects/roomShapeToDoorSlots.lua +35 -33
  412. package/dist/objects/roomShapeToDoorSlotsToGridIndexDelta.d.ts +2 -2
  413. package/dist/objects/roomShapeToDoorSlotsToGridIndexDelta.lua +68 -66
  414. package/dist/objects/roomShapeToGridWidth.d.ts +1 -1
  415. package/dist/objects/roomShapeToGridWidth.lua +14 -14
  416. package/dist/objects/roomShapeToTopLeftPosition.d.ts +1 -1
  417. package/dist/objects/roomShapeToTopLeftPosition.lua +14 -14
  418. package/dist/objects/roomShapeVolumes.d.ts +1 -1
  419. package/dist/objects/roomShapeVolumes.lua +14 -14
  420. package/dist/objects/roomTypeNames.d.ts +1 -1
  421. package/dist/objects/roomTypeNames.lua +32 -32
  422. package/dist/objects/serializedIsaacAPIClassTypeToIdentityFunction.lua +1 -2
  423. package/dist/objects/stageTypeToLetter.d.ts +1 -1
  424. package/dist/objects/stageTypeToLetter.lua +8 -7
  425. package/dist/objects/transformationNames.d.ts +1 -1
  426. package/dist/objects/transformationNames.lua +16 -17
  427. package/dist/patchErrorFunctions.lua +1 -2
  428. package/dist/sets/LRoomShapesSet.d.ts +1 -1
  429. package/dist/sets/LRoomShapesSet.lua +3 -1
  430. package/dist/sets/bossSets.lua +241 -211
  431. package/dist/sets/charactersThatStartWithAnActiveItemSet.d.ts +1 -1
  432. package/dist/sets/charactersThatStartWithAnActiveItemSet.lua +13 -11
  433. package/dist/sets/charactersWithBlackHeartFromEternalHeartSet.d.ts +1 -1
  434. package/dist/sets/charactersWithBlackHeartFromEternalHeartSet.lua +3 -1
  435. package/dist/sets/charactersWithFreeDevilDealsSet.d.ts +1 -1
  436. package/dist/sets/charactersWithFreeDevilDealsSet.lua +3 -1
  437. package/dist/sets/charactersWithNoRedHeartsSet.d.ts +1 -1
  438. package/dist/sets/charactersWithNoRedHeartsSet.lua +10 -8
  439. package/dist/sets/charactersWithNoSoulHeartsSet.d.ts +1 -1
  440. package/dist/sets/charactersWithNoSoulHeartsSet.lua +7 -5
  441. package/dist/sets/chestPickupVariantsSet.d.ts +1 -1
  442. package/dist/sets/chestPickupVariantsSet.lua +14 -12
  443. package/dist/sets/familiarsThatShootPlayerTearsSet.d.ts +1 -1
  444. package/dist/sets/familiarsThatShootPlayerTearsSet.lua +2 -0
  445. package/dist/sets/lostStyleCharactersSet.d.ts +1 -1
  446. package/dist/sets/lostStyleCharactersSet.lua +7 -5
  447. package/dist/sets/redHeartSubTypesSet.d.ts +1 -1
  448. package/dist/sets/redHeartSubTypesSet.lua +3 -1
  449. package/dist/sets/sinEntityTypesSet.d.ts +1 -1
  450. package/dist/sets/sinEntityTypesSet.lua +9 -7
  451. package/dist/sets/singleUseActiveCollectibleTypesSet.d.ts +1 -1
  452. package/dist/sets/singleUseActiveCollectibleTypesSet.lua +10 -8
  453. package/dist/sets/storyBossesSet.d.ts +1 -1
  454. package/dist/sets/storyBossesSet.lua +15 -13
  455. package/dist/types/AddCallbackParameterCustom.d.ts +123 -0
  456. package/dist/types/AddCallbackParameterCustom.lua +4 -0
  457. package/dist/types/AddCallbackParametersCustom.d.ts +120 -277
  458. package/dist/types/AnyEntity.lua +0 -1
  459. package/dist/types/CollectibleIndex.lua +0 -1
  460. package/dist/types/EntityTypeNonNPC.lua +0 -1
  461. package/dist/types/JSONDoor.lua +0 -1
  462. package/dist/types/JSONEntity.lua +0 -1
  463. package/dist/types/JSONRoom.lua +0 -1
  464. package/dist/types/JSONRooms.lua +0 -1
  465. package/dist/types/JSONSpawn.lua +0 -1
  466. package/dist/types/PickingUpItem.d.ts +1 -1
  467. package/dist/types/PickingUpItem.lua +5 -3
  468. package/dist/types/PlayerHealth.d.ts +1 -1
  469. package/dist/types/PlayerHealth.lua +0 -1
  470. package/dist/types/PlayerIndex.lua +0 -1
  471. package/dist/types/PocketItemDescription.d.ts +1 -1
  472. package/dist/types/PocketItemDescription.lua +0 -1
  473. package/dist/types/Primitive.lua +0 -1
  474. package/dist/types/TrinketSituation.d.ts +1 -1
  475. package/dist/types/TrinketSituation.lua +0 -1
  476. package/dist/types/private/IsaacAPIClass.lua +0 -1
  477. package/dist/types/private/SaveData.lua +0 -1
  478. package/dist/types/private/SerializedIsaacAPIClass.lua +0 -1
  479. package/dist/types/private/TSTLClass.lua +0 -1
  480. package/dist/types/private/TSTLClassMetatable.lua +0 -1
  481. package/dist/upgradeMod.d.ts +1 -1
  482. package/package.json +9 -8
@@ -1,5 +1,10 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
2
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
3
+ local CollectibleType = ____isaac_2Dtypescript_2Ddefinitions.CollectibleType
4
+ local EntityType = ____isaac_2Dtypescript_2Ddefinitions.EntityType
5
+ local NullItemID = ____isaac_2Dtypescript_2Ddefinitions.NullItemID
6
+ local PlayerType = ____isaac_2Dtypescript_2Ddefinitions.PlayerType
7
+ local TrinketType = ____isaac_2Dtypescript_2Ddefinitions.TrinketType
3
8
  local ____cachedClasses = require("cachedClasses")
4
9
  local game = ____cachedClasses.game
5
10
  local ____constants = require("constants")
@@ -13,12 +18,12 @@ local getPlayerNumHitsRemaining = ____player.getPlayerNumHitsRemaining
13
18
  local hasLostCurse = ____player.hasLostCurse
14
19
  local isKeeper = ____player.isKeeper
15
20
  local ____sprite = require("functions.sprite")
16
- local getFinalFrameOfAnimation = ____sprite.getFinalFrameOfAnimation
21
+ local getLastFrameOfAnimation = ____sprite.getLastFrameOfAnimation
17
22
  local ____trinketGive = require("functions.trinketGive")
18
23
  local giveTrinketsBack = ____trinketGive.giveTrinketsBack
19
24
  local temporarilyRemoveTrinket = ____trinketGive.temporarilyRemoveTrinket
20
25
  function ____exports.willReviveFromHeartbreak(self, player)
21
- if not player:HasCollectible(CollectibleType.COLLECTIBLE_HEARTBREAK) then
26
+ if not player:HasCollectible(CollectibleType.HEARTBREAK) then
22
27
  return false
23
28
  end
24
29
  local maxHeartContainers = getPlayerMaxHeartContainers(nil, player)
@@ -28,33 +33,33 @@ function ____exports.willReviveFromHeartbreak(self, player)
28
33
  return maxHeartContainers > numBrokenHeartsAfterRevival
29
34
  end
30
35
  function ____exports.willReviveFromSpiritShackles(self, player)
31
- if not player:HasCollectible(CollectibleType.COLLECTIBLE_SPIRIT_SHACKLES) then
36
+ if not player:HasCollectible(CollectibleType.SPIRIT_SHACKLES) then
32
37
  return false
33
38
  end
34
39
  local effects = player:GetEffects()
35
- local spiritShacklesEnabled = not effects:HasNullEffect(NullItemID.ID_SPIRIT_SHACKLES_DISABLED)
36
- local playerInSoulForm = effects:HasNullEffect(NullItemID.ID_SPIRIT_SHACKLES_SOUL)
40
+ local spiritShacklesEnabled = not effects:HasNullEffect(NullItemID.SPIRIT_SHACKLES_DISABLED)
41
+ local playerInSoulForm = effects:HasNullEffect(NullItemID.SPIRIT_SHACKLES_SOUL)
37
42
  return spiritShacklesEnabled and not playerInSoulForm
38
43
  end
39
44
  function ____exports.isDamageToPlayerFatal(self, player, damageAmount, damageSource, lastDamageGameFrame)
40
45
  local gameFrameCount = game:GetFrameCount()
41
46
  local character = player:GetPlayerType()
42
47
  local effects = player:GetEffects()
43
- local isBerserk = effects:HasCollectibleEffect(CollectibleType.COLLECTIBLE_BERSERK)
44
- if character == PlayerType.PLAYER_JACOB_B and damageSource.Type == EntityType.ENTITY_DARK_ESAU then
48
+ local isBerserk = effects:HasCollectibleEffect(CollectibleType.BERSERK)
49
+ if character == PlayerType.JACOB_B and damageSource.Type == EntityType.DARK_ESAU then
45
50
  return false
46
51
  end
47
52
  if isBerserk then
48
53
  return false
49
54
  end
50
55
  local berserkChargeAfterHit = player.SamsonBerserkCharge + TAINTED_SAMSON_BERSERK_CHARGE_FROM_TAKING_DAMAGE
51
- if character == PlayerType.PLAYER_SAMSON_B and berserkChargeAfterHit >= MAX_TAINTED_SAMSON_BERSERK_CHARGE then
56
+ if character == PlayerType.SAMSON_B and berserkChargeAfterHit >= MAX_TAINTED_SAMSON_BERSERK_CHARGE then
52
57
  return false
53
58
  end
54
59
  if ____exports.willReviveFromSpiritShackles(nil, player) then
55
60
  return false
56
61
  end
57
- if character == PlayerType.PLAYER_JACOB2_B then
62
+ if character == PlayerType.JACOB_2_B then
58
63
  return true
59
64
  end
60
65
  if hasLostCurse(nil, player) then
@@ -67,7 +72,7 @@ function ____exports.isDamageToPlayerFatal(self, player, damageAmount, damageSou
67
72
  if ____exports.willReviveFromHeartbreak(nil, player) then
68
73
  return false
69
74
  end
70
- if player:HasCollectible(CollectibleType.COLLECTIBLE_BROKEN_GLASS_CANNON) and gameFrameCount == lastDamageGameFrame then
75
+ if player:HasCollectible(CollectibleType.BROKEN_GLASS_CANNON) and gameFrameCount == lastDamageGameFrame then
71
76
  return false
72
77
  end
73
78
  local hearts = player:GetHearts()
@@ -84,12 +89,12 @@ function ____exports.willMysteriousPaperRevive(self, player)
84
89
  local sprite = player:GetSprite()
85
90
  local character = player:GetPlayerType()
86
91
  local animation = getCharacterDeathAnimationName(nil, character)
87
- local deathAnimationFrames = getFinalFrameOfAnimation(nil, sprite, animation)
92
+ local deathAnimationFrames = getLastFrameOfAnimation(nil, sprite, animation)
88
93
  local frameOfDeath = gameFrameCount + deathAnimationFrames + 1
89
94
  return frameOfDeath % 4 == 3
90
95
  end
91
96
  function ____exports.willPlayerRevive(self, player)
92
- local trinketSituation = temporarilyRemoveTrinket(nil, player, TrinketType.TRINKET_MYSTERIOUS_PAPER)
97
+ local trinketSituation = temporarilyRemoveTrinket(nil, player, TrinketType.MYSTERIOUS_PAPER)
93
98
  local willRevive = player:WillPlayerRevive() or trinketSituation ~= nil and ____exports.willMysteriousPaperRevive(nil, player)
94
99
  giveTrinketsBack(nil, player, trinketSituation)
95
100
  return willRevive
@@ -1,4 +1,4 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { DoorSlot, RoomShape, RoomType, StageID } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Alias for the `Level.GetCurrentRoomDesc` method. Use this to make it more clear what type of
4
4
  * `RoomDescriptor` object that you are retrieving.
@@ -26,7 +26,7 @@ export declare function getRoomDescriptor(roomGridIndex?: int): RoomDescriptor;
26
26
  *
27
27
  * - If the current room is inside of the grid, this function will return the `SafeGridIndex` from
28
28
  * the room descriptor. (The safe grid index is defined as the top-left 1x1 section that the room
29
- * overlaps with, or the top-right 1x1 section of a `RoomType.ROOMSHAPE_LTL` room.)
29
+ * overlaps with, or the top-right 1x1 section of a `RoomType.SHAPE_LTL` room.)
30
30
  * - If the current room is outside of the grid, it will return the index from the
31
31
  * `Level.GetCurrentRoomIndex` method (since `SafeGridIndex` is bugged for these cases).
32
32
  *
@@ -2,12 +2,16 @@ local ____lualib = require("lualib_bundle")
2
2
  local Set = ____lualib.Set
3
3
  local __TS__New = ____lualib.__TS__New
4
4
  local ____exports = {}
5
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
6
+ local DoorSlotFlag = ____isaac_2Dtypescript_2Ddefinitions.DoorSlotFlag
5
7
  local ____cachedClasses = require("cachedClasses")
6
8
  local game = ____cachedClasses.game
9
+ local ____doors = require("functions.doors")
10
+ local doorSlotFlagToDoorSlot = ____doors.doorSlotFlagToDoorSlot
11
+ local ____enums = require("functions.enums")
12
+ local getEnumValues = ____enums.getEnumValues
7
13
  local ____flag = require("functions.flag")
8
14
  local hasFlag = ____flag.hasFlag
9
- local ____utils = require("functions.utils")
10
- local getEnumValues = ____utils.getEnumValues
11
15
  function ____exports.getCurrentRoomDescriptorReadOnly(self)
12
16
  local level = game:GetLevel()
13
17
  return level:GetCurrentRoomDesc()
@@ -38,18 +42,12 @@ function ____exports.getRoomAllowedDoors(self, roomGridIndex)
38
42
  if roomData == nil then
39
43
  return allowedDoors
40
44
  end
41
- local doorSlots = getEnumValues(nil, DoorSlot)
42
- for ____, doorSlot in ipairs(doorSlots) do
43
- do
44
- if doorSlot == DoorSlot.NO_DOOR_SLOT or doorSlot == DoorSlot.NUM_DOOR_SLOTS then
45
- goto __continue5
46
- end
47
- local doorSlotFlag = 1 << doorSlot
48
- if hasFlag(nil, roomData.Doors, doorSlotFlag) then
49
- allowedDoors:add(doorSlot)
50
- end
45
+ local doorSlotFlags = getEnumValues(nil, DoorSlotFlag)
46
+ for ____, doorSlotFlag in ipairs(doorSlotFlags) do
47
+ if hasFlag(nil, roomData.Doors, doorSlotFlag) then
48
+ local doorSlot = doorSlotFlagToDoorSlot(nil, doorSlotFlag)
49
+ allowedDoors:add(doorSlot)
51
50
  end
52
- ::__continue5::
53
51
  end
54
52
  return allowedDoors
55
53
  end
@@ -1,4 +1,4 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { RoomShape } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Helper function to convert grid coordinates to a world position `Vector`.
4
4
  *
@@ -19,7 +19,7 @@ export declare function gridIndexToGridPosition(gridIndex: int, roomShape: RoomS
19
19
  */
20
20
  export declare function gridPositionToWorldPosition(gridPosition: Vector): Vector;
21
21
  /**
22
- * Test if a grid position is actually in the given `RoomShape`
22
+ * Test if a grid position is actually in the given `RoomShape`.
23
23
  *
24
24
  * In this context, the grid position of the top-left wall is "Vector(-1, -1)".
25
25
  */
@@ -1,4 +1,3 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
3
2
  local isValidGridPositionNormal, isValidGridPositionLRoom
4
3
  local ____LRoomShapeToRectangles = require("objects.LRoomShapeToRectangles")
@@ -1,7 +1,7 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { DoorSlot, RoomShape } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Helper function to get the grid index delta that a door out of the given room shape would lead
4
- * to. For example, if you went through the bottom door in a room of `RoomShape.ROOMSHAPE_1x2`, you
4
+ * to. For example, if you went through the bottom door in a room of `RoomShape.SHAPE_1x2`, you
5
5
  * would end up in a room with a grid index that is +26 units from the `SafeGridIndex` of where you
6
6
  * started.
7
7
  */
@@ -1,9 +1,8 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { BossID, Dimension, Direction, DoorSlot, ItemPoolType, MinibossID, RoomTransitionAnim, RoomType } from "isaac-typescript-definitions";
2
2
  /**
3
- * Helper function for quickly switching to a new room without playing a particular animation.
4
- * Use this helper function over invoking the `Game.ChangeRoom` method directly to ensure that you
5
- * do not forget to set the `LeaveDoor` property and to prevent crashing on invalid room grid
6
- * indexes.
3
+ * Helper function for quickly switching to a new room without playing a particular animation. Use
4
+ * this helper function over invoking the `Game.ChangeRoom` method directly to ensure that you do
5
+ * not forget to set the `LeaveDoor` property and to prevent crashing on invalid room grid indexes.
7
6
  */
8
7
  export declare function changeRoom(roomGridIndex: int): void;
9
8
  export declare function getAllRoomGridIndexes(): int[];
@@ -30,6 +29,12 @@ export declare function getRoomGridIndexesForType(...roomTypes: RoomType[]): int
30
29
  * `ItemPoolType.ItemPoolType.POOL_ANGEL` if you are in an Angel Room.
31
30
  */
32
31
  export declare function getRoomItemPoolType(): ItemPoolType;
32
+ /**
33
+ * Helper function to get the proper name of a room type.
34
+ *
35
+ * For example, `RoomType.TREASURE` will return "Treasure Room".
36
+ */
37
+ export declare function getRoomTypeName(roomType: RoomType): string;
33
38
  /**
34
39
  * Helper function to get the room descriptor for every room on the level. Uses the `Level.GetRooms`
35
40
  * method to accomplish this. Rooms without data are assumed to be non-existent and are not added to
@@ -49,8 +54,8 @@ export declare function getRooms(includeExtraDimensionalRooms?: boolean): RoomDe
49
54
  */
50
55
  export declare function getRoomsOfDimension(dimension: Dimension): RoomDescriptor[];
51
56
  /**
52
- * Helper function to determine if the current room shape is equal to `RoomShape.ROOMSHAPE_1x2` or
53
- * `RoomShape.ROOMSHAPE_2x1`.
57
+ * Helper function to determine if the current room shape is equal to `RoomShape.1x2` or
58
+ * `RoomShape.2x1`.
54
59
  */
55
60
  export declare function in2x1Room(): boolean;
56
61
  export declare function inAngelShop(): boolean;
@@ -62,8 +67,8 @@ export declare function inBeastRoom(): boolean;
62
67
  export declare function inBossRoomOf(bossID: BossID): boolean;
63
68
  /**
64
69
  * Helper function for determining whether the current room is a crawlspace. Use this function over
65
- * comparing to `RoomType.ROOM_DUNGEON` or `GridRooms.ROOM_DUNGEON_IDX` since there is a special
66
- * case of the player being in a boss fight that take place in a dungeon.
70
+ * comparing to `RoomType.DUNGEON` or `GridRoom.DUNGEON_IDX` since there is a special case of the
71
+ * player being in a boss fight that take place in a dungeon.
67
72
  */
68
73
  export declare function inCrawlspace(): boolean;
69
74
  /**
@@ -85,7 +90,7 @@ export declare function inLRoom(): boolean;
85
90
  export declare function inMegaSatanRoom(): boolean;
86
91
  /**
87
92
  * Helper function to check if the current room is a miniboss room for a particular miniboss. This
88
- * will only work for minibosses that have dedicated boss rooms in the "00.special rooms.stb" file.
93
+ * will only work for mini-bosses that have dedicated boss rooms in the "00.special rooms.stb" file.
89
94
  */
90
95
  export declare function inMinibossRoomOf(minibossID: MinibossID): boolean;
91
96
  /**
@@ -97,8 +102,8 @@ export declare function inMinibossRoomOf(minibossID: MinibossID): boolean;
97
102
  */
98
103
  export declare function inSecretShop(): boolean;
99
104
  /**
100
- * Helper function to determine whether or not the current room is the starting room of a floor.
101
- * It only returns true for the starting room of the primary dimension (meaning that being in the
105
+ * Helper function to determine whether or not the current room is the starting room of a floor. It
106
+ * only returns true for the starting room of the primary dimension (meaning that being in the
102
107
  * starting room of the mirror world does not count).
103
108
  */
104
109
  export declare function inStartingRoom(): boolean;
@@ -122,8 +127,8 @@ export declare function isDoorSlotValidAtGridIndexForRedRoom(doorSlot: DoorSlot,
122
127
  */
123
128
  export declare function isRedKeyRoom(roomGridIndex?: int): boolean;
124
129
  /**
125
- * Helper function to determine if the provided room is part of the floor layout. For
126
- * example, Devil Rooms and the Mega Satan room are not considered to be inside the map.
130
+ * Helper function to determine if the provided room is part of the floor layout. For example, Devil
131
+ * Rooms and the Mega Satan room are not considered to be inside the map.
127
132
  *
128
133
  * @param roomGridIndex Optional. Default is the current room index.
129
134
  */
@@ -8,12 +8,28 @@ local __TS__Spread = ____lualib.__TS__Spread
8
8
  local __TS__StringIncludes = ____lualib.__TS__StringIncludes
9
9
  local __TS__ArrayEvery = ____lualib.__TS__ArrayEvery
10
10
  local ____exports = {}
11
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
12
+ local AngelRoomSubType = ____isaac_2Dtypescript_2Ddefinitions.AngelRoomSubType
13
+ local Dimension = ____isaac_2Dtypescript_2Ddefinitions.Dimension
14
+ local Direction = ____isaac_2Dtypescript_2Ddefinitions.Direction
15
+ local DungeonSubType = ____isaac_2Dtypescript_2Ddefinitions.DungeonSubType
16
+ local GridRoom = ____isaac_2Dtypescript_2Ddefinitions.GridRoom
17
+ local HomeRoomSubType = ____isaac_2Dtypescript_2Ddefinitions.HomeRoomSubType
18
+ local RoomDescriptorFlag = ____isaac_2Dtypescript_2Ddefinitions.RoomDescriptorFlag
19
+ local RoomShape = ____isaac_2Dtypescript_2Ddefinitions.RoomShape
20
+ local RoomTransitionAnim = ____isaac_2Dtypescript_2Ddefinitions.RoomTransitionAnim
21
+ local RoomType = ____isaac_2Dtypescript_2Ddefinitions.RoomType
22
+ local SoundEffect = ____isaac_2Dtypescript_2Ddefinitions.SoundEffect
23
+ local StageID = ____isaac_2Dtypescript_2Ddefinitions.StageID
11
24
  local ____cachedClasses = require("cachedClasses")
12
25
  local game = ____cachedClasses.game
13
26
  local sfxManager = ____cachedClasses.sfxManager
14
27
  local ____constants = require("constants")
15
28
  local MAX_ROOM_INDEX = ____constants.MAX_ROOM_INDEX
16
29
  local NUM_DIMENSIONS = ____constants.NUM_DIMENSIONS
30
+ local ____roomTypeNames = require("objects.roomTypeNames")
31
+ local DEFAULT_ROOM_TYPE_NAME = ____roomTypeNames.DEFAULT_ROOM_TYPE_NAME
32
+ local ROOM_TYPE_NAMES = ____roomTypeNames.ROOM_TYPE_NAMES
17
33
  local ____doors = require("functions.doors")
18
34
  local closeAllDoors = ____doors.closeAllDoors
19
35
  local getDoors = ____doors.getDoors
@@ -24,7 +40,7 @@ local getEntities = ____entity.getEntities
24
40
  local ____flag = require("functions.flag")
25
41
  local hasFlag = ____flag.hasFlag
26
42
  local ____math = require("functions.math")
27
- local range = ____math.range
43
+ local erange = ____math.erange
28
44
  local ____positionVelocity = require("functions.positionVelocity")
29
45
  local getEntityPositions = ____positionVelocity.getEntityPositions
30
46
  local getEntityVelocities = ____positionVelocity.getEntityVelocities
@@ -77,7 +93,7 @@ end
77
93
  function ____exports.inDeathCertificateArea(self)
78
94
  local roomStageID = getRoomStageID(nil)
79
95
  local roomSubType = getRoomSubType(nil)
80
- return roomStageID == 35 and (roomSubType == 33 or roomSubType == 34)
96
+ return roomStageID == StageID.HOME and (roomSubType == HomeRoomSubType.DEATH_CERTIFICATE_ENTRANCE or roomSubType == HomeRoomSubType.DEATH_CERTIFICATE_ITEMS)
81
97
  end
82
98
  function ____exports.roomExists(self, roomGridIndex)
83
99
  local roomData = getRoomData(nil, roomGridIndex)
@@ -102,12 +118,12 @@ end
102
118
  function ____exports.getCurrentDimension(self)
103
119
  local level = game:GetLevel()
104
120
  if ____exports.inDeathCertificateArea(nil) then
105
- return 2
121
+ return Dimension.DEATH_CERTIFICATE
106
122
  end
107
123
  local startingRoomGridIndex = level:GetStartingRoomIndex()
108
- local startingRoomDescription = level:GetRoomByIdx(startingRoomGridIndex, -1)
124
+ local startingRoomDescription = level:GetRoomByIdx(startingRoomGridIndex, Dimension.CURRENT)
109
125
  local startingRoomHash = GetPtrHash(startingRoomDescription)
110
- for ____, dimension in ipairs(range(nil, NUM_DIMENSIONS - 1)) do
126
+ for ____, dimension in ipairs(erange(nil, NUM_DIMENSIONS)) do
111
127
  local dimensionRoomDescription = level:GetRoomByIdx(startingRoomGridIndex, dimension)
112
128
  local dimensionRoomHash = GetPtrHash(dimensionRoomDescription)
113
129
  if dimensionRoomHash == startingRoomHash then
@@ -135,6 +151,10 @@ function ____exports.getRoomItemPoolType(self)
135
151
  local roomSeed = room:GetSpawnSeed()
136
152
  return itemPool:GetPoolForRoom(roomType, roomSeed)
137
153
  end
154
+ function ____exports.getRoomTypeName(self, roomType)
155
+ local roomTypeName = ROOM_TYPE_NAMES[roomType]
156
+ return roomTypeName == nil and DEFAULT_ROOM_TYPE_NAME or roomTypeName
157
+ end
138
158
  function ____exports.getRoomsOfDimension(self, dimension)
139
159
  local level = game:GetLevel()
140
160
  local roomsMap = __TS__New(Map)
@@ -153,36 +173,36 @@ end
153
173
  function ____exports.in2x1Room(self)
154
174
  local room = game:GetRoom()
155
175
  local roomShape = room:GetRoomShape()
156
- return roomShape == RoomShape.ROOMSHAPE_1x2 or roomShape == RoomShape.ROOMSHAPE_2x1
176
+ return roomShape == RoomShape.SHAPE_1x2 or roomShape == RoomShape.SHAPE_2x1
157
177
  end
158
178
  function ____exports.inAngelShop(self)
159
179
  local room = game:GetRoom()
160
180
  local roomType = room:GetType()
161
181
  local roomSubType = getRoomSubType(nil)
162
- return roomType == RoomType.ROOM_ANGEL and roomSubType == 1
182
+ return roomType == RoomType.ANGEL and roomSubType == AngelRoomSubType.SHOP
163
183
  end
164
184
  function ____exports.inBeastRoom(self)
165
185
  local room = game:GetRoom()
166
186
  local roomType = room:GetType()
167
187
  local roomSubType = getRoomSubType(nil)
168
- return roomType == RoomType.ROOM_DUNGEON and roomSubType == 4
188
+ return roomType == RoomType.DUNGEON and roomSubType == DungeonSubType.BEAST_ROOM
169
189
  end
170
190
  function ____exports.inBossRoomOf(self, bossID)
171
191
  local room = game:GetRoom()
172
192
  local roomType = room:GetType()
173
193
  local roomStageID = getRoomStageID(nil)
174
194
  local roomSubType = getRoomSubType(nil)
175
- return roomType == RoomType.ROOM_BOSS and roomStageID == 0 and roomSubType == bossID
195
+ return roomType == RoomType.BOSS and roomStageID == StageID.SPECIAL_ROOMS and roomSubType == bossID
176
196
  end
177
197
  function ____exports.inCrawlspace(self)
178
198
  local room = game:GetRoom()
179
199
  local roomType = room:GetType()
180
200
  local roomSubType = getRoomSubType(nil)
181
- return roomType == RoomType.ROOM_DUNGEON and roomSubType == 0
201
+ return roomType == RoomType.DUNGEON and roomSubType == DungeonSubType.NORMAL
182
202
  end
183
203
  function ____exports.inDevilsCrownTreasureRoom(self)
184
204
  local roomDescriptor = getCurrentRoomDescriptorReadOnly(nil)
185
- return hasFlag(nil, roomDescriptor.Flags, 2048)
205
+ return hasFlag(nil, roomDescriptor.Flags, RoomDescriptorFlag.DEVIL_TREASURE)
186
206
  end
187
207
  function ____exports.inDimension(self, dimension)
188
208
  return dimension == ____exports.getCurrentDimension(nil)
@@ -191,37 +211,37 @@ function ____exports.inDoubleTrouble(self)
191
211
  local room = game:GetRoom()
192
212
  local roomType = room:GetType()
193
213
  local roomName = getRoomName(nil)
194
- return roomType == RoomType.ROOM_BOSS and __TS__StringIncludes(roomName, "Double Trouble")
214
+ return roomType == RoomType.BOSS and __TS__StringIncludes(roomName, "Double Trouble")
195
215
  end
196
216
  function ____exports.inGenesisRoom(self)
197
217
  local roomGridIndex = getRoomGridIndex(nil)
198
- return roomGridIndex == GridRooms.ROOM_GENESIS_IDX
218
+ return roomGridIndex == GridRoom.GENESIS
199
219
  end
200
220
  function ____exports.inLRoom(self)
201
221
  local room = game:GetRoom()
202
222
  local roomShape = room:GetRoomShape()
203
- return roomShape == RoomShape.ROOMSHAPE_LTL or roomShape == RoomShape.ROOMSHAPE_LTR or roomShape == RoomShape.ROOMSHAPE_LBL or roomShape == RoomShape.ROOMSHAPE_LBR
223
+ return roomShape == RoomShape.LTL or roomShape == RoomShape.LTR or roomShape == RoomShape.LBL or roomShape == RoomShape.LBR
204
224
  end
205
225
  function ____exports.inMegaSatanRoom(self)
206
226
  local roomGridIndex = getRoomGridIndex(nil)
207
- return roomGridIndex == GridRooms.ROOM_MEGA_SATAN_IDX
227
+ return roomGridIndex == GridRoom.MEGA_SATAN
208
228
  end
209
229
  function ____exports.inMinibossRoomOf(self, minibossID)
210
230
  local room = game:GetRoom()
211
231
  local roomType = room:GetType()
212
232
  local roomStageID = getRoomStageID(nil)
213
233
  local roomSubType = getRoomSubType(nil)
214
- return roomType == RoomType.ROOM_MINIBOSS and roomStageID == 0 and roomSubType == minibossID
234
+ return roomType == RoomType.MINI_BOSS and roomStageID == StageID.SPECIAL_ROOMS and roomSubType == minibossID
215
235
  end
216
236
  function ____exports.inSecretShop(self)
217
237
  local roomGridIndex = getRoomGridIndex(nil)
218
- return roomGridIndex == GridRooms.ROOM_SECRET_SHOP_IDX
238
+ return roomGridIndex == GridRoom.SECRET_SHOP
219
239
  end
220
240
  function ____exports.inStartingRoom(self)
221
241
  local level = game:GetLevel()
222
242
  local startingRoomGridIndex = level:GetStartingRoomIndex()
223
243
  local roomGridIndex = getRoomGridIndex(nil)
224
- return roomGridIndex == startingRoomGridIndex and ____exports.inDimension(nil, 0)
244
+ return roomGridIndex == startingRoomGridIndex and ____exports.inDimension(nil, Dimension.MAIN)
225
245
  end
226
246
  function ____exports.isAllRoomsClear(self, onlyCheckRoomTypes)
227
247
  local ____temp_0
@@ -263,7 +283,7 @@ function ____exports.isDoorSlotValidAtGridIndexForRedRoom(self, doorSlot, roomGr
263
283
  end
264
284
  function ____exports.isRedKeyRoom(self, roomGridIndex)
265
285
  local roomDescriptor = getRoomDescriptor(nil, roomGridIndex)
266
- return hasFlag(nil, roomDescriptor.Flags, 1024)
286
+ return hasFlag(nil, roomDescriptor.Flags, RoomDescriptorFlag.RED_ROOM)
267
287
  end
268
288
  function ____exports.isRoomInsideMap(self, roomGridIndex)
269
289
  if roomGridIndex == nil then
@@ -290,14 +310,14 @@ function ____exports.setRoomCleared(self)
290
310
  for ____, door in ipairs(getDoors(nil)) do
291
311
  do
292
312
  if isHiddenSecretRoomDoor(nil, door) then
293
- goto __continue55
313
+ goto __continue56
294
314
  end
295
315
  openDoorFast(nil, door)
296
316
  door.ExtraVisible = false
297
317
  end
298
- ::__continue55::
318
+ ::__continue56::
299
319
  end
300
- sfxManager:Stop(SoundEffect.SOUND_DOOR_HEAVY_OPEN)
320
+ sfxManager:Stop(SoundEffect.DOOR_HEAVY_OPEN)
301
321
  game:ShakeScreen(0)
302
322
  end
303
323
  function ____exports.setRoomUncleared(self)
@@ -1,4 +1,4 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { PlayerType } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Whether or not the player is playing on a set seed (i.e. that they entered in a specific seed by
4
4
  * pressing tab on the character selection screen). When the player resets the game on a set seed,
@@ -1,5 +1,6 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
2
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
3
+ local Challenge = ____isaac_2Dtypescript_2Ddefinitions.Challenge
3
4
  local ____cachedClasses = require("cachedClasses")
4
5
  local game = ____cachedClasses.game
5
6
  local ____log = require("functions.log")
@@ -8,7 +9,7 @@ function ____exports.onSetSeed(self)
8
9
  local seeds = game:GetSeeds()
9
10
  local customRun = seeds:IsCustomRun()
10
11
  local challenge = Isaac.GetChallenge()
11
- return challenge == Challenge.CHALLENGE_NULL and customRun
12
+ return challenge == Challenge.NULL and customRun
12
13
  end
13
14
  function ____exports.restart(self, character)
14
15
  if character == nil then
@@ -1,2 +1,9 @@
1
+ /// <reference types="isaac-typescript-definitions" />
1
2
  /** Alias for the `Seeds.GetStartSeedString` method. */
2
3
  export declare function getStartSeedString(): string;
4
+ /**
5
+ * Helper function to get the next seed value.
6
+ *
7
+ * This function is useful when you are working with seed values directly over RNG objects.
8
+ */
9
+ export declare function nextSeed(seed: Seed): Seed;
@@ -1,9 +1,15 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
3
2
  local ____cachedClasses = require("cachedClasses")
4
3
  local game = ____cachedClasses.game
4
+ local ____rng = require("functions.rng")
5
+ local newRNG = ____rng.newRNG
5
6
  function ____exports.getStartSeedString(self)
6
7
  local seeds = game:GetSeeds()
7
8
  return seeds:GetStartSeedString()
8
9
  end
10
+ function ____exports.nextSeed(self, seed)
11
+ local rng = newRNG(nil, seed)
12
+ rng:Next()
13
+ return rng:GetSeed()
14
+ end
9
15
  return ____exports
@@ -1,9 +1,10 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
2
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
3
+ local SoundEffect = ____isaac_2Dtypescript_2Ddefinitions.SoundEffect
3
4
  local ____cachedClasses = require("cachedClasses")
4
5
  local sfxManager = ____cachedClasses.sfxManager
5
- local ____utils = require("functions.utils")
6
- local getEnumValues = ____utils.getEnumValues
6
+ local ____enums = require("functions.enums")
7
+ local getEnumValues = ____enums.getEnumValues
7
8
  function ____exports.stopAllSoundEffects(self)
8
9
  for ____, soundEffect in ipairs(getEnumValues(nil, SoundEffect)) do
9
10
  sfxManager:Stop(soundEffect)
@@ -1,4 +1,4 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { CollectibleType } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Helper function to spawn a collectible. Use this instead of the `Game.Spawn` method because it
4
4
  * handles the cases of Tainted Keeper collectibles costing coins and preventing quest items from
@@ -17,11 +17,11 @@
17
17
  export declare function spawnCollectible(collectibleType: CollectibleType | int, position: Vector, seedOrRNG?: Seed | RNG, options?: boolean, forceFreeItem?: boolean): EntityPickup;
18
18
  /**
19
19
  * Helper function to spawn an empty collectible. Doing this is tricky since spawning a collectible
20
- * with `CollectibleType.COLLECTIBLE_NULL` will result in spawning a collectible with a random type
21
- * from the current room's item pool.
20
+ * with `CollectibleType.NULL` will result in spawning a collectible with a random type from the
21
+ * current room's item pool.
22
22
  *
23
- * Instead, this function arbitrarily spawns a collectible with
24
- * `CollectibleType.COLLECTIBLE_SAD_ONION`, and then converts it to an empty pedestal afterward.
23
+ * Instead, this function arbitrarily spawns a collectible with `CollectibleType.SAD_ONION`, and
24
+ * then converts it to an empty pedestal afterward.
25
25
  *
26
26
  * @param position The position to spawn the empty collectible at.
27
27
  * @param seedOrRNG The `Seed` or `RNG` object to use. If an `RNG` object is provided, the
@@ -1,5 +1,8 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
2
+ local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
3
+ local CollectibleType = ____isaac_2Dtypescript_2Ddefinitions.CollectibleType
4
+ local PickupVariant = ____isaac_2Dtypescript_2Ddefinitions.PickupVariant
5
+ local PlayerType = ____isaac_2Dtypescript_2Ddefinitions.PlayerType
3
6
  local ____preventCollectibleRotate = require("features.preventCollectibleRotate")
4
7
  local preventCollectibleRotate = ____preventCollectibleRotate.preventCollectibleRotate
5
8
  local ____featuresInitialized = require("featuresInitialized")
@@ -28,7 +31,7 @@ function ____exports.spawnCollectible(self, collectibleType, position, seedOrRNG
28
31
  local seed = isRNG(nil, seedOrRNG) and seedOrRNG:Next() or seedOrRNG
29
32
  local collectible = spawnPickupWithSeed(
30
33
  nil,
31
- 100,
34
+ PickupVariant.COLLECTIBLE,
32
35
  collectibleType,
33
36
  position,
34
37
  seed
@@ -36,7 +39,7 @@ function ____exports.spawnCollectible(self, collectibleType, position, seedOrRNG
36
39
  if options then
37
40
  collectible.OptionsPickupIndex = 1
38
41
  end
39
- if anyPlayerIs(nil, PlayerType.PLAYER_KEEPER_B) and not isQuestCollectible(nil, collectibleType) and not forceFreeItem then
42
+ if anyPlayerIs(nil, PlayerType.KEEPER_B) and not isQuestCollectible(nil, collectibleType) and not forceFreeItem then
40
43
  collectible.ShopItemId = -1
41
44
  collectible.Price = 15
42
45
  end
@@ -51,7 +54,7 @@ function ____exports.spawnEmptyCollectible(self, position, seedOrRNG)
51
54
  end
52
55
  local collectible = ____exports.spawnCollectible(
53
56
  nil,
54
- CollectibleType.COLLECTIBLE_SAD_ONION,
57
+ CollectibleType.SAD_ONION,
55
58
  position,
56
59
  seedOrRNG,
57
60
  false,
@@ -23,7 +23,7 @@ export declare function clearSprite(sprite: Sprite, ...layerIDs: int[]): void;
23
23
  * to use this function on animations that are not slowed down by Stop Watch or Broken Watch, such
24
24
  * as player animations.
25
25
  */
26
- export declare function getFinalFrameOfAnimation(sprite: Sprite, animation?: string): int;
26
+ export declare function getLastFrameOfAnimation(sprite: Sprite, animation?: string): int;
27
27
  /**
28
28
  * Helper function to check if two sprite layers have the same sprite sheet by using the
29
29
  * `Sprite.GetTexel` method.
@@ -1,4 +1,3 @@
1
- --[[ Generated with https://github.com/TypeScriptToLua/TypeScriptToLua ]]
2
1
  local ____exports = {}
3
2
  local ____constants = require("constants")
4
3
  local EMPTY_PNG_PATH = ____constants.EMPTY_PNG_PATH
@@ -6,7 +5,7 @@ local VectorZero = ____constants.VectorZero
6
5
  local ____kColor = require("functions.kColor")
7
6
  local kColorEquals = ____kColor.kColorEquals
8
7
  local ____math = require("functions.math")
9
- local range = ____math.range
8
+ local erange = ____math.erange
10
9
  function ____exports.texelEquals(self, sprite1, sprite2, position, layerID)
11
10
  local kColor1 = sprite1:GetTexel(position, VectorZero, 1, layerID)
12
11
  local kColor2 = sprite2:GetTexel(position, VectorZero, 1, layerID)
@@ -16,14 +15,14 @@ function ____exports.clearSprite(self, sprite, ...)
16
15
  local layerIDs = {...}
17
16
  if #layerIDs == 0 then
18
17
  local numLayers = sprite:GetLayerCount()
19
- layerIDs = range(nil, numLayers - 1)
18
+ layerIDs = erange(nil, numLayers)
20
19
  end
21
20
  for ____, layerID in ipairs(layerIDs) do
22
21
  sprite:ReplaceSpritesheet(layerID, EMPTY_PNG_PATH)
23
22
  end
24
23
  sprite:LoadGraphics()
25
24
  end
26
- function ____exports.getFinalFrameOfAnimation(self, sprite, animation)
25
+ function ____exports.getLastFrameOfAnimation(self, sprite, animation)
27
26
  local currentAnimation = sprite:GetAnimation()
28
27
  local currentFrame = sprite:GetFrame()
29
28
  if animation ~= nil and animation ~= currentAnimation then
@@ -1,4 +1,4 @@
1
- /// <reference types="isaac-typescript-definitions" />
1
+ import { LevelStage, StageType } from "isaac-typescript-definitions";
2
2
  /**
3
3
  * Helper function to account for Repentance floors being offset by 1. For example, Downpour 2 is
4
4
  * the third level of the run, but the game considers it to have a stage of 2. This function will
@@ -28,8 +28,8 @@ export declare function onRepentanceStage(): boolean;
28
28
  export declare function onSheol(): boolean;
29
29
  /**
30
30
  * Helper function to convert a numerical `StageType` into the letter suffix supplied to the "stage"
31
- * console command. For example, `StageType.STAGETYPE_REPENTANCE` is the stage type for Downpour,
32
- * and the console command to go to Downpour is "stage 1c", so this function converts
33
- * `StageType.STAGETYPE_REPENTANCE` to "c".
31
+ * console command. For example, `StageType.REPENTANCE` is the stage type for Downpour, and the
32
+ * console command to go to Downpour is "stage 1c", so this function converts `StageType.REPENTANCE`
33
+ * to "c".
34
34
  */
35
35
  export declare function stageTypeToLetter(stageType: StageType): string;