isaacscript-common 87.4.0 → 87.5.1

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 (596) hide show
  1. package/README.md +1 -1
  2. package/dist/callbackClasses.d.ts +6 -6
  3. package/dist/callbackClasses.d.ts.map +1 -1
  4. package/dist/callbackClasses.js +14 -14
  5. package/dist/callbackClasses.lua +159 -300
  6. package/dist/callbacks.js +18 -9
  7. package/dist/classes/DefaultMap.d.ts +5 -1
  8. package/dist/classes/DefaultMap.d.ts.map +1 -1
  9. package/dist/classes/ModFeature.js +3 -3
  10. package/dist/classes/ModUpgraded.d.ts.map +1 -1
  11. package/dist/classes/ModUpgraded.js +2 -4
  12. package/dist/classes/callbacks/InputActionFilter.d.ts +2 -2
  13. package/dist/classes/callbacks/InputActionFilter.d.ts.map +1 -1
  14. package/dist/classes/callbacks/InputActionPlayer.d.ts +2 -2
  15. package/dist/classes/callbacks/InputActionPlayer.d.ts.map +1 -1
  16. package/dist/classes/callbacks/PostCollectibleEmpty.d.ts +2 -2
  17. package/dist/classes/callbacks/PostCollectibleEmpty.d.ts.map +1 -1
  18. package/dist/classes/callbacks/PostCollectibleEmpty.js +1 -3
  19. package/dist/classes/callbacks/PostCustomRevive.d.ts +2 -4
  20. package/dist/classes/callbacks/PostCustomRevive.d.ts.map +1 -1
  21. package/dist/classes/callbacks/PostDiceRoomActivated.d.ts +2 -3
  22. package/dist/classes/callbacks/PostDiceRoomActivated.d.ts.map +1 -1
  23. package/dist/classes/callbacks/PostGridEntityCollision.d.ts +2 -4
  24. package/dist/classes/callbacks/PostGridEntityCollision.d.ts.map +1 -1
  25. package/dist/classes/callbacks/PostGridEntityCustomCollision.d.ts +2 -4
  26. package/dist/classes/callbacks/PostGridEntityCustomCollision.d.ts.map +1 -1
  27. package/dist/classes/callbacks/PostGridEntityCustomRemove.d.ts +2 -3
  28. package/dist/classes/callbacks/PostGridEntityCustomRemove.d.ts.map +1 -1
  29. package/dist/classes/callbacks/PostGridEntityRemove.d.ts +2 -2
  30. package/dist/classes/callbacks/PostGridEntityRemove.d.ts.map +1 -1
  31. package/dist/classes/callbacks/PostItemDischarge.d.ts +2 -2
  32. package/dist/classes/callbacks/PostItemDischarge.d.ts.map +1 -1
  33. package/dist/classes/callbacks/PostItemDischarge.js +3 -6
  34. package/dist/classes/callbacks/PostKeyboardChanged.d.ts +2 -1
  35. package/dist/classes/callbacks/PostKeyboardChanged.d.ts.map +1 -1
  36. package/dist/classes/callbacks/PostNewRoomEarly.js +1 -1
  37. package/dist/classes/callbacks/PostPickupSelectionFilter.d.ts +2 -2
  38. package/dist/classes/callbacks/PostPickupSelectionFilter.d.ts.map +1 -1
  39. package/dist/classes/callbacks/PostPlayerChangeType.js +1 -1
  40. package/dist/classes/callbacks/PostPurchase.d.ts +2 -4
  41. package/dist/classes/callbacks/PostPurchase.d.ts.map +1 -1
  42. package/dist/classes/callbacks/PostRoomClearChanged.d.ts.map +1 -1
  43. package/dist/classes/callbacks/PostTransformation.d.ts +2 -2
  44. package/dist/classes/callbacks/PostTransformation.d.ts.map +1 -1
  45. package/dist/classes/callbacks/PostTransformation.js +1 -3
  46. package/dist/classes/callbacks/PostTrinketBreak.d.ts.map +1 -1
  47. package/dist/classes/callbacks/PostTrinketBreak.js +1 -3
  48. package/dist/classes/callbacks/PreEntitySpawnFilter.d.ts +2 -2
  49. package/dist/classes/callbacks/PreEntitySpawnFilter.d.ts.map +1 -1
  50. package/dist/classes/callbacks/PreNewLevel.d.ts.map +1 -1
  51. package/dist/classes/callbacks/PreRoomEntitySpawnFilter.d.ts +2 -2
  52. package/dist/classes/callbacks/PreRoomEntitySpawnFilter.d.ts.map +1 -1
  53. package/dist/classes/features/callbackLogic/CustomGridEntities.d.ts +1 -1
  54. package/dist/classes/features/callbackLogic/CustomGridEntities.d.ts.map +1 -1
  55. package/dist/classes/features/callbackLogic/CustomRevive.d.ts.map +1 -1
  56. package/dist/classes/features/callbackLogic/EsauJrDetection.d.ts.map +1 -1
  57. package/dist/classes/features/callbackLogic/GameReorderedCallbacks.d.ts.map +1 -1
  58. package/dist/classes/features/callbackLogic/GameReorderedCallbacks.js +4 -6
  59. package/dist/classes/features/callbackLogic/ItemPickupDetection.d.ts.map +1 -1
  60. package/dist/classes/features/callbackLogic/ItemPickupDetection.js +6 -2
  61. package/dist/classes/features/callbackLogic/ItemPickupDetection.lua +6 -1
  62. package/dist/classes/features/callbackLogic/PlayerReorderedCallbacks.d.ts +0 -1
  63. package/dist/classes/features/callbackLogic/PlayerReorderedCallbacks.d.ts.map +1 -1
  64. package/dist/classes/features/callbackLogic/PlayerReorderedCallbacks.js +4 -4
  65. package/dist/classes/features/other/CustomPickups.d.ts.map +1 -1
  66. package/dist/classes/features/other/CustomPickups.js +1 -0
  67. package/dist/classes/features/other/CustomStages.js +19 -9
  68. package/dist/classes/features/other/CustomTrapdoors.d.ts.map +1 -1
  69. package/dist/classes/features/other/CustomTrapdoors.js +23 -17
  70. package/dist/classes/features/other/CustomTrapdoors.lua +14 -7
  71. package/dist/classes/features/other/DebugDisplay.d.ts +0 -18
  72. package/dist/classes/features/other/DebugDisplay.d.ts.map +1 -1
  73. package/dist/classes/features/other/DeployJSONRoom.d.ts +0 -2
  74. package/dist/classes/features/other/DeployJSONRoom.d.ts.map +1 -1
  75. package/dist/classes/features/other/DeployJSONRoom.js +2 -0
  76. package/dist/classes/features/other/EdenStartingStatsHealth.d.ts +1 -1
  77. package/dist/classes/features/other/EdenStartingStatsHealth.d.ts.map +1 -1
  78. package/dist/classes/features/other/ExtraConsoleCommands.d.ts +14 -10
  79. package/dist/classes/features/other/ExtraConsoleCommands.d.ts.map +1 -1
  80. package/dist/classes/features/other/ExtraConsoleCommands.js +31 -17
  81. package/dist/classes/features/other/ExtraConsoleCommands.lua +2 -1
  82. package/dist/classes/features/other/FlyingDetection.d.ts +0 -1
  83. package/dist/classes/features/other/FlyingDetection.d.ts.map +1 -1
  84. package/dist/classes/features/other/ForgottenSwitch.d.ts +0 -1
  85. package/dist/classes/features/other/ForgottenSwitch.d.ts.map +1 -1
  86. package/dist/classes/features/other/ModdedElementDetection.js +4 -4
  87. package/dist/classes/features/other/ModdedElementSets.d.ts +2 -2
  88. package/dist/classes/features/other/ModdedElementSets.d.ts.map +1 -1
  89. package/dist/classes/features/other/ModdedElementSets.js +1 -1
  90. package/dist/classes/features/other/PickupIndexCreation.d.ts +0 -1
  91. package/dist/classes/features/other/PickupIndexCreation.d.ts.map +1 -1
  92. package/dist/classes/features/other/PickupIndexCreation.js +2 -3
  93. package/dist/classes/features/other/PickupIndexCreation.lua +10 -10
  94. package/dist/classes/features/other/PonyDetection.d.ts +0 -1
  95. package/dist/classes/features/other/PonyDetection.d.ts.map +1 -1
  96. package/dist/classes/features/other/PreventChildEntities.d.ts +0 -1
  97. package/dist/classes/features/other/PreventChildEntities.d.ts.map +1 -1
  98. package/dist/classes/features/other/RoomClearFrame.d.ts +0 -1
  99. package/dist/classes/features/other/RoomClearFrame.d.ts.map +1 -1
  100. package/dist/classes/features/other/RoomHistory.d.ts +0 -1
  101. package/dist/classes/features/other/RoomHistory.d.ts.map +1 -1
  102. package/dist/classes/features/other/RunInNFrames.js +2 -2
  103. package/dist/classes/features/other/SaveDataManager.js +1 -1
  104. package/dist/classes/features/other/SpawnRockAltRewards.d.ts +0 -4
  105. package/dist/classes/features/other/SpawnRockAltRewards.d.ts.map +1 -1
  106. package/dist/classes/features/other/TaintedLazarusPlayers.d.ts +0 -1
  107. package/dist/classes/features/other/TaintedLazarusPlayers.d.ts.map +1 -1
  108. package/dist/classes/features/other/customStages/backdrop.js +2 -3
  109. package/dist/classes/features/other/customStages/constants.d.ts.map +1 -1
  110. package/dist/classes/features/other/customStages/gridEntities.d.ts +0 -1
  111. package/dist/classes/features/other/customStages/gridEntities.d.ts.map +1 -1
  112. package/dist/classes/features/other/customStages/gridEntities.js +5 -6
  113. package/dist/classes/features/other/customStages/shadows.js +1 -2
  114. package/dist/classes/features/other/customStages/streakText.js +3 -4
  115. package/dist/classes/features/other/customStages/utils.d.ts +0 -2
  116. package/dist/classes/features/other/customStages/utils.d.ts.map +1 -1
  117. package/dist/classes/features/other/customStages/utils.js +2 -3
  118. package/dist/classes/features/other/customStages/v.d.ts.map +1 -1
  119. package/dist/classes/features/other/customStages/versusScreen.js +2 -3
  120. package/dist/classes/features/other/debugDisplay/DebugDisplayBomb.d.ts +0 -1
  121. package/dist/classes/features/other/debugDisplay/DebugDisplayBomb.d.ts.map +1 -1
  122. package/dist/classes/features/other/debugDisplay/DebugDisplayDoor.d.ts +0 -1
  123. package/dist/classes/features/other/debugDisplay/DebugDisplayDoor.d.ts.map +1 -1
  124. package/dist/classes/features/other/debugDisplay/DebugDisplayEffect.d.ts +0 -1
  125. package/dist/classes/features/other/debugDisplay/DebugDisplayEffect.d.ts.map +1 -1
  126. package/dist/classes/features/other/debugDisplay/DebugDisplayFamiliar.d.ts +0 -1
  127. package/dist/classes/features/other/debugDisplay/DebugDisplayFamiliar.d.ts.map +1 -1
  128. package/dist/classes/features/other/debugDisplay/DebugDisplayKnife.d.ts +0 -1
  129. package/dist/classes/features/other/debugDisplay/DebugDisplayKnife.d.ts.map +1 -1
  130. package/dist/classes/features/other/debugDisplay/DebugDisplayLaser.d.ts +0 -1
  131. package/dist/classes/features/other/debugDisplay/DebugDisplayLaser.d.ts.map +1 -1
  132. package/dist/classes/features/other/debugDisplay/DebugDisplayNPC.d.ts +0 -1
  133. package/dist/classes/features/other/debugDisplay/DebugDisplayNPC.d.ts.map +1 -1
  134. package/dist/classes/features/other/debugDisplay/DebugDisplayPickup.d.ts +0 -1
  135. package/dist/classes/features/other/debugDisplay/DebugDisplayPickup.d.ts.map +1 -1
  136. package/dist/classes/features/other/debugDisplay/DebugDisplayPit.d.ts +0 -1
  137. package/dist/classes/features/other/debugDisplay/DebugDisplayPit.d.ts.map +1 -1
  138. package/dist/classes/features/other/debugDisplay/DebugDisplayPlayer.d.ts +0 -1
  139. package/dist/classes/features/other/debugDisplay/DebugDisplayPlayer.d.ts.map +1 -1
  140. package/dist/classes/features/other/debugDisplay/DebugDisplayPoop.d.ts +0 -1
  141. package/dist/classes/features/other/debugDisplay/DebugDisplayPoop.d.ts.map +1 -1
  142. package/dist/classes/features/other/debugDisplay/DebugDisplayPressurePlate.d.ts +0 -1
  143. package/dist/classes/features/other/debugDisplay/DebugDisplayPressurePlate.d.ts.map +1 -1
  144. package/dist/classes/features/other/debugDisplay/DebugDisplayProjectile.d.ts +0 -1
  145. package/dist/classes/features/other/debugDisplay/DebugDisplayProjectile.d.ts.map +1 -1
  146. package/dist/classes/features/other/debugDisplay/DebugDisplayRock.d.ts +0 -1
  147. package/dist/classes/features/other/debugDisplay/DebugDisplayRock.d.ts.map +1 -1
  148. package/dist/classes/features/other/debugDisplay/DebugDisplaySlot.d.ts +0 -1
  149. package/dist/classes/features/other/debugDisplay/DebugDisplaySlot.d.ts.map +1 -1
  150. package/dist/classes/features/other/debugDisplay/DebugDisplaySpikes.d.ts +0 -1
  151. package/dist/classes/features/other/debugDisplay/DebugDisplaySpikes.d.ts.map +1 -1
  152. package/dist/classes/features/other/debugDisplay/DebugDisplayTNT.d.ts +0 -1
  153. package/dist/classes/features/other/debugDisplay/DebugDisplayTNT.d.ts.map +1 -1
  154. package/dist/classes/features/other/debugDisplay/DebugDisplayTear.d.ts +0 -1
  155. package/dist/classes/features/other/debugDisplay/DebugDisplayTear.d.ts.map +1 -1
  156. package/dist/classes/features/other/debugDisplay/utils.d.ts +0 -2
  157. package/dist/classes/features/other/debugDisplay/utils.d.ts.map +1 -1
  158. package/dist/classes/features/other/debugDisplay/utils.js +2 -3
  159. package/dist/classes/features/other/extraConsoleCommands/commands.js +147 -150
  160. package/dist/classes/features/other/extraConsoleCommands/subroutines.js +8 -9
  161. package/dist/classes/features/other/saveDataManager/constants.d.ts.map +1 -1
  162. package/dist/classes/features/other/saveDataManager/glowingHourGlass.d.ts +0 -1
  163. package/dist/classes/features/other/saveDataManager/glowingHourGlass.d.ts.map +1 -1
  164. package/dist/classes/features/other/saveDataManager/glowingHourGlass.js +2 -3
  165. package/dist/classes/features/other/saveDataManager/loadFromDisk.d.ts +0 -2
  166. package/dist/classes/features/other/saveDataManager/loadFromDisk.d.ts.map +1 -1
  167. package/dist/classes/features/other/saveDataManager/loadFromDisk.js +5 -2
  168. package/dist/classes/features/other/saveDataManager/loadFromDisk.lua +3 -0
  169. package/dist/classes/features/other/saveDataManager/restoreDefaults.d.ts +0 -1
  170. package/dist/classes/features/other/saveDataManager/restoreDefaults.d.ts.map +1 -1
  171. package/dist/classes/features/other/saveDataManager/restoreDefaults.js +3 -4
  172. package/dist/classes/features/other/saveDataManager/saveToDisk.d.ts +0 -2
  173. package/dist/classes/features/other/saveDataManager/saveToDisk.d.ts.map +1 -1
  174. package/dist/classes/features/other/saveDataManager/saveToDisk.js +1 -2
  175. package/dist/classes/private/CustomCallback.d.ts.map +1 -1
  176. package/dist/core/cachedClasses.d.ts +0 -5
  177. package/dist/core/cachedClasses.d.ts.map +1 -1
  178. package/dist/core/constants.js +1 -1
  179. package/dist/core/constantsVanilla.js +4 -4
  180. package/dist/core/upgradeMod.d.ts +0 -2
  181. package/dist/core/upgradeMod.d.ts.map +1 -1
  182. package/dist/core/upgradeMod.js +1 -2
  183. package/dist/decorators.js +2 -2
  184. package/dist/enums/ModCallbackCustom.d.ts +5 -4
  185. package/dist/enums/ModCallbackCustom.d.ts.map +1 -1
  186. package/dist/enums/ModCallbackCustom.js +5 -4
  187. package/dist/enums/private/GridEntityTypeCustom.d.ts.map +1 -1
  188. package/dist/features.js +1 -2
  189. package/dist/functions/ambush.js +1 -2
  190. package/dist/functions/array.d.ts +5 -8
  191. package/dist/functions/array.d.ts.map +1 -1
  192. package/dist/functions/array.js +55 -55
  193. package/dist/functions/array.lua +2 -2
  194. package/dist/functions/arrayLua.d.ts +1 -1
  195. package/dist/functions/arrayLua.d.ts.map +1 -1
  196. package/dist/functions/arrayLua.js +7 -8
  197. package/dist/functions/benchmark.d.ts +0 -1
  198. package/dist/functions/benchmark.d.ts.map +1 -1
  199. package/dist/functions/benchmark.js +1 -2
  200. package/dist/functions/bitSet128.d.ts +0 -1
  201. package/dist/functions/bitSet128.d.ts.map +1 -1
  202. package/dist/functions/bitSet128.js +5 -6
  203. package/dist/functions/bitwise.d.ts +0 -4
  204. package/dist/functions/bitwise.d.ts.map +1 -1
  205. package/dist/functions/bitwise.js +7 -8
  206. package/dist/functions/bitwise.lua +3 -3
  207. package/dist/functions/bombs.d.ts +0 -1
  208. package/dist/functions/bombs.d.ts.map +1 -1
  209. package/dist/functions/bombs.js +1 -2
  210. package/dist/functions/bosses.d.ts.map +1 -1
  211. package/dist/functions/bosses.js +17 -17
  212. package/dist/functions/cards.js +16 -17
  213. package/dist/functions/challenges.js +9 -10
  214. package/dist/functions/characters.js +17 -18
  215. package/dist/functions/charge.d.ts.map +1 -1
  216. package/dist/functions/charge.js +10 -11
  217. package/dist/functions/charge.lua +1 -1
  218. package/dist/functions/chargeBar.d.ts +0 -2
  219. package/dist/functions/chargeBar.d.ts.map +1 -1
  220. package/dist/functions/chargeBar.js +2 -3
  221. package/dist/functions/collectibleTag.js +2 -3
  222. package/dist/functions/collectibles.js +37 -38
  223. package/dist/functions/color.d.ts +0 -1
  224. package/dist/functions/color.d.ts.map +1 -1
  225. package/dist/functions/color.js +7 -8
  226. package/dist/functions/console.js +2 -3
  227. package/dist/functions/curses.js +2 -3
  228. package/dist/functions/debugFunctions.d.ts +0 -1
  229. package/dist/functions/debugFunctions.d.ts.map +1 -1
  230. package/dist/functions/debugFunctions.js +5 -6
  231. package/dist/functions/decorators.d.ts +4 -4
  232. package/dist/functions/decorators.d.ts.map +1 -1
  233. package/dist/functions/decorators.js +4 -5
  234. package/dist/functions/deepCopy.d.ts +0 -1
  235. package/dist/functions/deepCopy.d.ts.map +1 -1
  236. package/dist/functions/deepCopy.js +1 -4
  237. package/dist/functions/deepCopy.lua +0 -2
  238. package/dist/functions/deepCopyTests.js +5 -6
  239. package/dist/functions/dimensions.js +2 -3
  240. package/dist/functions/direction.js +6 -7
  241. package/dist/functions/doors.d.ts.map +1 -1
  242. package/dist/functions/doors.js +53 -49
  243. package/dist/functions/easing.js +30 -31
  244. package/dist/functions/effects.d.ts +0 -2
  245. package/dist/functions/effects.d.ts.map +1 -1
  246. package/dist/functions/effects.js +2 -2
  247. package/dist/functions/emptyRoom.js +2 -3
  248. package/dist/functions/entities.d.ts +3 -4
  249. package/dist/functions/entities.d.ts.map +1 -1
  250. package/dist/functions/entities.js +32 -33
  251. package/dist/functions/entities.lua +4 -11
  252. package/dist/functions/entitiesSpecific.js +40 -41
  253. package/dist/functions/entityTypes.d.ts +0 -1
  254. package/dist/functions/entityTypes.d.ts.map +1 -1
  255. package/dist/functions/entityTypes.js +1 -2
  256. package/dist/functions/enums.d.ts +1 -6
  257. package/dist/functions/enums.d.ts.map +1 -1
  258. package/dist/functions/enums.js +12 -13
  259. package/dist/functions/external.js +2 -3
  260. package/dist/functions/familiars.js +6 -7
  261. package/dist/functions/flag.d.ts +1 -1
  262. package/dist/functions/flag.d.ts.map +1 -1
  263. package/dist/functions/flag.js +7 -8
  264. package/dist/functions/frames.d.ts +0 -1
  265. package/dist/functions/frames.d.ts.map +1 -1
  266. package/dist/functions/frames.js +18 -19
  267. package/dist/functions/globals.d.ts +0 -1
  268. package/dist/functions/globals.d.ts.map +1 -1
  269. package/dist/functions/globals.js +23 -15
  270. package/dist/functions/gridEntities.d.ts.map +1 -1
  271. package/dist/functions/gridEntities.js +51 -39
  272. package/dist/functions/gridEntities.lua +9 -5
  273. package/dist/functions/gridEntitiesSpecific.js +38 -39
  274. package/dist/functions/gridIndex.js +1 -2
  275. package/dist/functions/hash.js +1 -2
  276. package/dist/functions/hex.d.ts +0 -2
  277. package/dist/functions/hex.d.ts.map +1 -1
  278. package/dist/functions/hex.js +2 -3
  279. package/dist/functions/input.js +21 -21
  280. package/dist/functions/isaacAPIClass.d.ts +0 -20
  281. package/dist/functions/isaacAPIClass.d.ts.map +1 -1
  282. package/dist/functions/isaacAPIClass.js +23 -24
  283. package/dist/functions/itemPool.js +7 -8
  284. package/dist/functions/jsonHelpers.d.ts +4 -5
  285. package/dist/functions/jsonHelpers.d.ts.map +1 -1
  286. package/dist/functions/jsonHelpers.js +23 -14
  287. package/dist/functions/jsonHelpers.lua +4 -4
  288. package/dist/functions/jsonRoom.js +5 -6
  289. package/dist/functions/kColor.d.ts +0 -1
  290. package/dist/functions/kColor.d.ts.map +1 -1
  291. package/dist/functions/kColor.js +7 -8
  292. package/dist/functions/language.js +1 -2
  293. package/dist/functions/level.js +4 -5
  294. package/dist/functions/levelGrid.d.ts.map +1 -1
  295. package/dist/functions/levelGrid.js +27 -32
  296. package/dist/functions/log.js +4 -5
  297. package/dist/functions/logEntities.d.ts.map +1 -1
  298. package/dist/functions/logEntities.js +11 -9
  299. package/dist/functions/logMisc.d.ts +1 -2
  300. package/dist/functions/logMisc.d.ts.map +1 -1
  301. package/dist/functions/logMisc.js +35 -48
  302. package/dist/functions/logMisc.lua +3 -3
  303. package/dist/functions/map.d.ts +0 -2
  304. package/dist/functions/map.d.ts.map +1 -1
  305. package/dist/functions/map.js +12 -13
  306. package/dist/functions/math.js +13 -14
  307. package/dist/functions/merge.d.ts +0 -1
  308. package/dist/functions/merge.d.ts.map +1 -1
  309. package/dist/functions/merge.js +2 -3
  310. package/dist/functions/mergeTests.js +1 -2
  311. package/dist/functions/minimap.d.ts.map +1 -1
  312. package/dist/functions/minimap.js +12 -17
  313. package/dist/functions/modFeatures.js +1 -2
  314. package/dist/functions/newArray.d.ts +0 -1
  315. package/dist/functions/newArray.d.ts.map +1 -1
  316. package/dist/functions/newArray.js +2 -3
  317. package/dist/functions/nextStage.d.ts.map +1 -1
  318. package/dist/functions/nextStage.js +6 -3
  319. package/dist/functions/npcDataStructures.d.ts +0 -2
  320. package/dist/functions/npcDataStructures.d.ts.map +1 -1
  321. package/dist/functions/npcDataStructures.js +14 -15
  322. package/dist/functions/npcs.d.ts.map +1 -1
  323. package/dist/functions/npcs.js +9 -7
  324. package/dist/functions/pickupVariants.d.ts +0 -1
  325. package/dist/functions/pickupVariants.d.ts.map +1 -1
  326. package/dist/functions/pickupVariants.js +11 -12
  327. package/dist/functions/pickups.js +14 -15
  328. package/dist/functions/pickupsSpecific.js +40 -41
  329. package/dist/functions/pills.js +18 -19
  330. package/dist/functions/playerCenter.d.ts +0 -1
  331. package/dist/functions/playerCenter.d.ts.map +1 -1
  332. package/dist/functions/playerCenter.js +1 -2
  333. package/dist/functions/playerCollectibles.d.ts.map +1 -1
  334. package/dist/functions/playerCollectibles.js +19 -22
  335. package/dist/functions/playerCollectibles.lua +9 -9
  336. package/dist/functions/playerDataStructures.d.ts +0 -1
  337. package/dist/functions/playerDataStructures.d.ts.map +1 -1
  338. package/dist/functions/playerDataStructures.js +14 -15
  339. package/dist/functions/playerEffects.js +5 -6
  340. package/dist/functions/playerHealth.d.ts +0 -2
  341. package/dist/functions/playerHealth.d.ts.map +1 -1
  342. package/dist/functions/playerHealth.js +20 -21
  343. package/dist/functions/playerHealth.lua +26 -26
  344. package/dist/functions/playerIndex.d.ts +0 -3
  345. package/dist/functions/playerIndex.d.ts.map +1 -1
  346. package/dist/functions/playerIndex.js +9 -10
  347. package/dist/functions/playerTrinkets.js +10 -11
  348. package/dist/functions/players.d.ts +2 -0
  349. package/dist/functions/players.d.ts.map +1 -1
  350. package/dist/functions/players.js +39 -38
  351. package/dist/functions/players.lua +2 -0
  352. package/dist/functions/pocketItems.js +8 -9
  353. package/dist/functions/positionVelocity.d.ts +0 -4
  354. package/dist/functions/positionVelocity.d.ts.map +1 -1
  355. package/dist/functions/positionVelocity.js +11 -20
  356. package/dist/functions/positionVelocity.lua +4 -4
  357. package/dist/functions/pressurePlate.js +1 -2
  358. package/dist/functions/projectiles.js +2 -3
  359. package/dist/functions/random.d.ts +0 -3
  360. package/dist/functions/random.d.ts.map +1 -1
  361. package/dist/functions/random.js +3 -4
  362. package/dist/functions/readOnly.d.ts +0 -4
  363. package/dist/functions/readOnly.d.ts.map +1 -1
  364. package/dist/functions/readOnly.js +3 -4
  365. package/dist/functions/render.d.ts +0 -3
  366. package/dist/functions/render.d.ts.map +1 -1
  367. package/dist/functions/render.js +3 -4
  368. package/dist/functions/revive.d.ts +0 -3
  369. package/dist/functions/revive.d.ts.map +1 -1
  370. package/dist/functions/revive.js +5 -6
  371. package/dist/functions/rng.d.ts +0 -1
  372. package/dist/functions/rng.d.ts.map +1 -1
  373. package/dist/functions/rng.js +15 -15
  374. package/dist/functions/rockAlt.d.ts +0 -1
  375. package/dist/functions/rockAlt.d.ts.map +1 -1
  376. package/dist/functions/rockAlt.js +2 -3
  377. package/dist/functions/roomData.d.ts.map +1 -1
  378. package/dist/functions/roomData.js +15 -18
  379. package/dist/functions/roomGrid.js +6 -7
  380. package/dist/functions/roomShape.js +14 -15
  381. package/dist/functions/roomShapeWalls.js +2 -3
  382. package/dist/functions/roomTransition.js +2 -3
  383. package/dist/functions/rooms.d.ts.map +1 -1
  384. package/dist/functions/rooms.js +77 -64
  385. package/dist/functions/rooms.lua +2 -2
  386. package/dist/functions/run.js +8 -9
  387. package/dist/functions/seeds.d.ts +0 -1
  388. package/dist/functions/seeds.d.ts.map +1 -1
  389. package/dist/functions/seeds.js +2 -3
  390. package/dist/functions/serialization.js +5 -6
  391. package/dist/functions/set.d.ts +0 -2
  392. package/dist/functions/set.d.ts.map +1 -1
  393. package/dist/functions/set.js +22 -23
  394. package/dist/functions/slots.js +2 -3
  395. package/dist/functions/sort.d.ts.map +1 -1
  396. package/dist/functions/sort.js +6 -7
  397. package/dist/functions/sound.d.ts.map +1 -1
  398. package/dist/functions/sound.js +4 -9
  399. package/dist/functions/spawnCollectible.d.ts.map +1 -1
  400. package/dist/functions/spawnCollectible.js +4 -7
  401. package/dist/functions/sprites.d.ts +0 -3
  402. package/dist/functions/sprites.d.ts.map +1 -1
  403. package/dist/functions/sprites.js +6 -7
  404. package/dist/functions/stage.d.ts.map +1 -1
  405. package/dist/functions/stage.js +44 -53
  406. package/dist/functions/stage.lua +5 -5
  407. package/dist/functions/stats.js +4 -5
  408. package/dist/functions/storyBosses.js +2 -3
  409. package/dist/functions/string.d.ts +0 -1
  410. package/dist/functions/string.d.ts.map +1 -1
  411. package/dist/functions/string.js +12 -13
  412. package/dist/functions/table.d.ts +0 -1
  413. package/dist/functions/table.d.ts.map +1 -1
  414. package/dist/functions/table.js +8 -9
  415. package/dist/functions/tears.js +6 -7
  416. package/dist/functions/transformations.js +5 -6
  417. package/dist/functions/trinketGive.js +5 -6
  418. package/dist/functions/trinkets.d.ts.map +1 -1
  419. package/dist/functions/trinkets.js +14 -17
  420. package/dist/functions/tstlClass.d.ts +2 -3
  421. package/dist/functions/tstlClass.d.ts.map +1 -1
  422. package/dist/functions/tstlClass.js +9 -10
  423. package/dist/functions/tstlClass.lua +2 -2
  424. package/dist/functions/types.d.ts +15 -17
  425. package/dist/functions/types.d.ts.map +1 -1
  426. package/dist/functions/types.js +38 -39
  427. package/dist/functions/types.lua +14 -14
  428. package/dist/functions/ui.d.ts +0 -3
  429. package/dist/functions/ui.d.ts.map +1 -1
  430. package/dist/functions/ui.js +13 -14
  431. package/dist/functions/utils.d.ts +0 -1
  432. package/dist/functions/utils.d.ts.map +1 -1
  433. package/dist/functions/utils.js +11 -12
  434. package/dist/functions/vector.d.ts +0 -1
  435. package/dist/functions/vector.d.ts.map +1 -1
  436. package/dist/functions/vector.js +11 -12
  437. package/dist/functions/versusScreen.js +4 -5
  438. package/dist/functions/weighted.d.ts +0 -3
  439. package/dist/functions/weighted.d.ts.map +1 -1
  440. package/dist/functions/weighted.js +2 -3
  441. package/dist/index.d.ts +58 -58
  442. package/dist/index.d.ts.map +1 -1
  443. package/dist/index.js +4 -58
  444. package/dist/index.lua +443 -11
  445. package/dist/index.rollup.d.ts +86 -69
  446. package/dist/indexLua.d.ts +58 -58
  447. package/dist/indexLua.d.ts.map +1 -1
  448. package/dist/indexLua.js +4 -58
  449. package/dist/indexLua.lua +443 -11
  450. package/dist/interfaces/ChargeBarSprites.d.ts +0 -2
  451. package/dist/interfaces/ChargeBarSprites.d.ts.map +1 -1
  452. package/dist/interfaces/Corner.d.ts +0 -2
  453. package/dist/interfaces/Corner.d.ts.map +1 -1
  454. package/dist/interfaces/SaveData.d.ts +0 -1
  455. package/dist/interfaces/SaveData.d.ts.map +1 -1
  456. package/dist/interfaces/TSTLClassMetatable.d.ts +0 -4
  457. package/dist/interfaces/TSTLClassMetatable.d.ts.map +1 -1
  458. package/dist/interfaces/private/AddCallbackParametersCustom.d.ts +5 -3
  459. package/dist/interfaces/private/AddCallbackParametersCustom.d.ts.map +1 -1
  460. package/dist/interfaces/private/ModUpgradedInterface.d.ts +0 -1
  461. package/dist/interfaces/private/ModUpgradedInterface.d.ts.map +1 -1
  462. package/dist/isaacscript-common.lua +1561 -1186
  463. package/dist/lib/jsonLua.js +2 -2
  464. package/dist/lualib_bundle.lua +107 -38
  465. package/dist/objects/LRoomShapeToRectangles.js +1 -1
  466. package/dist/objects/colors.d.ts +0 -1
  467. package/dist/objects/colors.d.ts.map +1 -1
  468. package/dist/objects/directionToVector.d.ts +0 -1
  469. package/dist/objects/directionToVector.d.ts.map +1 -1
  470. package/dist/objects/doorSlotFlagToDoorSlot.d.ts +9 -2
  471. package/dist/objects/doorSlotFlagToDoorSlot.d.ts.map +1 -1
  472. package/dist/objects/doorSlotToDoorSlotFlag.d.ts +0 -1
  473. package/dist/objects/doorSlotToDoorSlotFlag.d.ts.map +1 -1
  474. package/dist/objects/itemPoolTypeToCollectibleTypesSet.js +17 -7
  475. package/dist/objects/kColors.d.ts +0 -1
  476. package/dist/objects/kColors.d.ts.map +1 -1
  477. package/dist/objects/roomShapeToBottomRightPosition.d.ts +0 -1
  478. package/dist/objects/roomShapeToBottomRightPosition.d.ts.map +1 -1
  479. package/dist/objects/roomShapeToDoorSlotsToGridIndexDelta.js +1 -1
  480. package/dist/objects/roomShapeToTopLeftPosition.d.ts +0 -1
  481. package/dist/objects/roomShapeToTopLeftPosition.d.ts.map +1 -1
  482. package/dist/objects/versusScreenBackgroundColors.d.ts +0 -1
  483. package/dist/objects/versusScreenBackgroundColors.d.ts.map +1 -1
  484. package/dist/objects/versusScreenDirtSpotColors.d.ts +0 -1
  485. package/dist/objects/versusScreenDirtSpotColors.d.ts.map +1 -1
  486. package/dist/patchErrorFunctions.js +1 -2
  487. package/dist/serialization.js +1 -2
  488. package/dist/shaderCrashFix.d.ts +0 -1
  489. package/dist/shaderCrashFix.d.ts.map +1 -1
  490. package/dist/shaderCrashFix.js +1 -2
  491. package/dist/shouldFire.d.ts.map +1 -1
  492. package/dist/shouldFire.js +30 -30
  493. package/dist/tsdoc-metadata.json +1 -1
  494. package/dist/types/AddSubtract.d.ts +10 -2
  495. package/dist/types/AddSubtract.d.ts.map +1 -1
  496. package/dist/types/AnyEntity.d.ts +0 -11
  497. package/dist/types/AnyEntity.d.ts.map +1 -1
  498. package/dist/types/AnyGridEntity.d.ts +0 -8
  499. package/dist/types/AnyGridEntity.d.ts.map +1 -1
  500. package/dist/types/PickingUpItem.js +5 -6
  501. package/dist/types/PickupIndex.d.ts +0 -1
  502. package/dist/types/PickupIndex.d.ts.map +1 -1
  503. package/dist/types/PlayerIndex.d.ts +0 -1
  504. package/dist/types/PlayerIndex.d.ts.map +1 -1
  505. package/dist/types/ReadonlyMap.d.ts.map +1 -1
  506. package/dist/types/ReadonlySet.d.ts.map +1 -1
  507. package/dist/types/TSTLClass.d.ts +0 -1
  508. package/dist/types/TSTLClass.d.ts.map +1 -1
  509. package/dist/types/TupleWithLengthBetween.js +2 -2
  510. package/dist/types/TupleWithMaxLength.js +2 -2
  511. package/dist/types/WeightedArray.d.ts +0 -1
  512. package/dist/types/WeightedArray.d.ts.map +1 -1
  513. package/package.json +9 -2
  514. package/src/callbackClasses.ts +6 -6
  515. package/src/classes/DefaultMap.ts +5 -2
  516. package/src/classes/ModFeature.ts +3 -3
  517. package/src/classes/ModUpgraded.ts +2 -4
  518. package/src/classes/callbacks/PostCollectibleEmpty.ts +1 -3
  519. package/src/classes/callbacks/PostItemDischarge.ts +3 -6
  520. package/src/classes/callbacks/PostNPCStateChanged.ts +1 -1
  521. package/src/classes/callbacks/PostNewRoomEarly.ts +1 -1
  522. package/src/classes/callbacks/PostPlayerChangeType.ts +1 -1
  523. package/src/classes/callbacks/PostTransformation.ts +1 -3
  524. package/src/classes/callbacks/PostTrinketBreak.ts +1 -3
  525. package/src/classes/features/callbackLogic/CustomGridEntities.ts +1 -1
  526. package/src/classes/features/callbackLogic/GameReorderedCallbacks.ts +4 -6
  527. package/src/classes/features/callbackLogic/ItemPickupDetection.ts +6 -2
  528. package/src/classes/features/callbackLogic/PlayerReorderedCallbacks.ts +4 -4
  529. package/src/classes/features/other/CustomPickups.ts +1 -0
  530. package/src/classes/features/other/CustomStages.ts +2 -2
  531. package/src/classes/features/other/CustomTrapdoors.ts +23 -18
  532. package/src/classes/features/other/DeployJSONRoom.ts +2 -0
  533. package/src/classes/features/other/EdenStartingStatsHealth.ts +3 -1
  534. package/src/classes/features/other/ExtraConsoleCommands.ts +14 -10
  535. package/src/classes/features/other/ModdedElementDetection.ts +4 -4
  536. package/src/classes/features/other/ModdedElementSets.ts +3 -3
  537. package/src/classes/features/other/PickupIndexCreation.ts +2 -3
  538. package/src/classes/features/other/RunInNFrames.ts +2 -2
  539. package/src/classes/features/other/SaveDataManager.ts +1 -1
  540. package/src/classes/features/other/customStages/backdrop.ts +1 -1
  541. package/src/classes/features/other/extraConsoleCommands/commands.ts +7 -7
  542. package/src/classes/features/other/saveDataManager/loadFromDisk.ts +5 -0
  543. package/src/core/constants.ts +1 -1
  544. package/src/core/constantsVanilla.ts +4 -4
  545. package/src/enums/ModCallbackCustom.ts +5 -4
  546. package/src/functions/array.ts +33 -29
  547. package/src/functions/arrayLua.ts +1 -1
  548. package/src/functions/bosses.ts +2 -1
  549. package/src/functions/charge.ts +1 -2
  550. package/src/functions/decorators.ts +6 -9
  551. package/src/functions/deepCopy.ts +0 -4
  552. package/src/functions/deepCopyTests.ts +4 -4
  553. package/src/functions/doors.ts +5 -0
  554. package/src/functions/entities.ts +7 -14
  555. package/src/functions/enums.ts +4 -4
  556. package/src/functions/flag.ts +1 -1
  557. package/src/functions/globals.ts +2 -3
  558. package/src/functions/gridEntities.ts +19 -1
  559. package/src/functions/jsonHelpers.ts +7 -5
  560. package/src/functions/levelGrid.ts +3 -6
  561. package/src/functions/logEntities.ts +3 -0
  562. package/src/functions/logMisc.ts +9 -20
  563. package/src/functions/map.ts +4 -4
  564. package/src/functions/merge.ts +1 -1
  565. package/src/functions/minimap.ts +2 -6
  566. package/src/functions/newArray.ts +1 -1
  567. package/src/functions/nextStage.ts +4 -0
  568. package/src/functions/npcDataStructures.ts +5 -5
  569. package/src/functions/npcs.ts +3 -0
  570. package/src/functions/playerCollectibles.ts +1 -3
  571. package/src/functions/playerDataStructures.ts +5 -5
  572. package/src/functions/players.ts +2 -0
  573. package/src/functions/positionVelocity.ts +4 -12
  574. package/src/functions/rng.ts +4 -3
  575. package/src/functions/roomData.ts +1 -3
  576. package/src/functions/rooms.ts +16 -1
  577. package/src/functions/set.ts +8 -8
  578. package/src/functions/sort.ts +2 -2
  579. package/src/functions/sound.ts +2 -7
  580. package/src/functions/spawnCollectible.ts +1 -3
  581. package/src/functions/stage.ts +4 -14
  582. package/src/functions/trinkets.ts +1 -3
  583. package/src/functions/tstlClass.ts +2 -2
  584. package/src/functions/types.ts +16 -16
  585. package/src/index.ts +58 -58
  586. package/src/interfaces/SaveData.ts +2 -1
  587. package/src/interfaces/private/AddCallbackParametersCustom.ts +8 -3
  588. package/src/lib/jsonLua.js +2 -2
  589. package/src/objects/LRoomShapeToRectangles.ts +1 -1
  590. package/src/objects/roomShapeToDoorSlotsToGridIndexDelta.ts +1 -1
  591. package/src/shouldFire.ts +2 -1
  592. package/src/types/AddSubtract.ts +10 -2
  593. package/src/types/HasFunction.ts +1 -1
  594. package/src/types/Immutable.ts +1 -1
  595. package/src/types/TupleWithLengthBetween.ts +2 -2
  596. package/src/types/TupleWithMaxLength.ts +2 -2
@@ -34,13 +34,13 @@ function ____exports.convertDecimalToBinary(self, num, minLength)
34
34
  local bits = {}
35
35
  local bitsString = __TS__NumberToString(num, 2)
36
36
  for ____, bitString in __TS__Iterator(bitsString) do
37
- local bit = parseIntSafe(nil, bitString)
37
+ local ____bit = parseIntSafe(nil, bitString)
38
38
  assertDefined(
39
39
  nil,
40
- bit,
40
+ ____bit,
41
41
  "Failed to convert the following number to binary: " .. tostring(num)
42
42
  )
43
- bits[#bits + 1] = bit
43
+ bits[#bits + 1] = ____bit
44
44
  end
45
45
  if minLength ~= nil then
46
46
  while #bits < minLength do
@@ -1,4 +1,3 @@
1
- /// <reference types="isaac-typescript-definitions" />
2
1
  /** Helper function to find out how large a bomb explosion is based on the damage inflicted. */
3
2
  export declare function getBombRadiusFromDamage(damage: float): float;
4
3
  //# sourceMappingURL=bombs.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"bombs.d.ts","sourceRoot":"","sources":["../../src/functions/bombs.ts"],"names":[],"mappings":";AAAA,+FAA+F;AAC/F,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,KAAK,GAAG,KAAK,CAU5D"}
1
+ {"version":3,"file":"bombs.d.ts","sourceRoot":"","sources":["../../src/functions/bombs.ts"],"names":[],"mappings":"AAAA,+FAA+F;AAC/F,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,KAAK,GAAG,KAAK,CAU5D"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getBombRadiusFromDamage = void 0;
3
+ exports.getBombRadiusFromDamage = getBombRadiusFromDamage;
4
4
  /** Helper function to find out how large a bomb explosion is based on the damage inflicted. */
5
5
  function getBombRadiusFromDamage(damage) {
6
6
  if (damage > 175) {
@@ -11,4 +11,3 @@ function getBombRadiusFromDamage(damage) {
11
11
  }
12
12
  return 90;
13
13
  }
14
- exports.getBombRadiusFromDamage = getBombRadiusFromDamage;
@@ -1 +1 @@
1
- {"version":3,"file":"bosses.d.ts","sourceRoot":"","sources":["../../src/functions/bosses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACxE,OAAO,EACL,MAAM,EACN,UAAU,EAGX,MAAM,8BAA8B,CAAC;AAiCtC;;;;;;;;;;;;;GAaG;AACH,wBAAgB,cAAc,CAC5B,UAAU,GAAE,UAAU,GAAG,CAAC,CAAM,EAChC,OAAO,SAAK,EACZ,OAAO,SAAK,EACZ,cAAc,UAAQ,GACrB,SAAS,SAAS,EAAE,CAGtB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,YAAY,IAAI,SAAS,MAAM,EAAE,CAEhD;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,IAAI,SAAS,MAAM,EAAE,CAExD;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,IAAI,MAAM,GAAG,SAAS,CA0B9C;AAED,wBAAgB,8BAA8B,CAC5C,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,GACX,MAAM,GAAG,SAAS,CAGpB;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,UAAU,GAChB,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAEjC;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,GACf,SAAS,MAAM,EAAE,GAAG,SAAS,CAE/B;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAIlD;AAED,+FAA+F;AAC/F,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,GAAG,WAAW,CAAC,OAAO,CAAC,CAEpE;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,SAAS,CACvB,UAAU,CAAC,EAAE,UAAU,EACvB,OAAO,CAAC,EAAE,GAAG,EACb,OAAO,CAAC,EAAE,GAAG,EACb,cAAc,UAAQ,GACrB,SAAS,SAAS,EAAE,CAGtB;AAED,wBAAgB,8BAA8B,CAC5C,MAAM,EAAE,MAAM,GACb,SAAS,CAAC,UAAU,EAAE,GAAG,CAAC,CAE5B;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAExD;AAED,6FAA6F;AAC7F,wBAAgB,KAAK,CAAC,GAAG,EAAE,SAAS,GAAG,OAAO,CAE7C;AAmCD;;;;;;;;;GASG;AACH,wBAAgB,SAAS,CACvB,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,EACZ,OAAO,EAAE,GAAG,EACZ,mBAAmB,EAAE,MAAM,GAAG,GAAG,EACjC,QAAQ,GAAE,MAAmB,EAC7B,OAAO,GAAE,MAAM,GAAG,SAAqB,EACvC,SAAS,GAAE,IAAI,GAAG,GAAG,GAAG,SAAqB,EAC7C,WAAW,CAAC,EAAE,GAAG,GAChB,SAAS,CAiCX;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,EACZ,OAAO,EAAE,GAAG,EACZ,mBAAmB,EAAE,MAAM,GAAG,GAAG,EACjC,SAAS,EAAE,IAAI,GAAG,GAAG,EACrB,QAAQ,GAAE,MAAmB,EAC7B,OAAO,GAAE,MAAM,GAAG,SAAqB,EACvC,WAAW,CAAC,EAAE,GAAG,GAChB,SAAS,CAYX"}
1
+ {"version":3,"file":"bosses.d.ts","sourceRoot":"","sources":["../../src/functions/bosses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAC;AACxE,OAAO,EACL,MAAM,EACN,UAAU,EAGX,MAAM,8BAA8B,CAAC;AAiCtC;;;;;;;;;;;;;GAaG;AACH,wBAAgB,cAAc,CAC5B,UAAU,GAAE,UAAU,GAAG,CAAC,CAAM,EAChC,OAAO,SAAK,EACZ,OAAO,SAAK,EACZ,cAAc,UAAQ,GACrB,SAAS,SAAS,EAAE,CAGtB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,YAAY,IAAI,SAAS,MAAM,EAAE,CAEhD;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,IAAI,SAAS,MAAM,EAAE,CAExD;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,IAAI,MAAM,GAAG,SAAS,CA0B9C;AAED,wBAAgB,8BAA8B,CAC5C,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,GACX,MAAM,GAAG,SAAS,CAGpB;AAED;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,UAAU,GAChB,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAEjC;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,OAAO,GACf,SAAS,MAAM,EAAE,GAAG,SAAS,CAE/B;AAED;;;GAGG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAIlD;AAED,+FAA+F;AAC/F,wBAAgB,eAAe,CAAC,MAAM,EAAE,MAAM,GAAG,WAAW,CAAC,OAAO,CAAC,CAEpE;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,SAAS,CACvB,UAAU,CAAC,EAAE,UAAU,EACvB,OAAO,CAAC,EAAE,GAAG,EACb,OAAO,CAAC,EAAE,GAAG,EACb,cAAc,UAAQ,GACrB,SAAS,SAAS,EAAE,CAGtB;AAED,wBAAgB,8BAA8B,CAC5C,MAAM,EAAE,MAAM,GACb,SAAS,CAAC,UAAU,EAAE,GAAG,CAAC,CAE5B;AAED;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAExD;AAED,6FAA6F;AAC7F,wBAAgB,KAAK,CAAC,GAAG,EAAE,SAAS,GAAG,OAAO,CAE7C;AAoCD;;;;;;;;;GASG;AACH,wBAAgB,SAAS,CACvB,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,EACZ,OAAO,EAAE,GAAG,EACZ,mBAAmB,EAAE,MAAM,GAAG,GAAG,EACjC,QAAQ,GAAE,MAAmB,EAC7B,OAAO,GAAE,MAAM,GAAG,SAAqB,EACvC,SAAS,GAAE,IAAI,GAAG,GAAG,GAAG,SAAqB,EAC7C,WAAW,CAAC,EAAE,GAAG,GAChB,SAAS,CAiCX;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,GAAG,EACZ,OAAO,EAAE,GAAG,EACZ,mBAAmB,EAAE,MAAM,GAAG,GAAG,EACjC,SAAS,EAAE,IAAI,GAAG,GAAG,EACrB,QAAQ,GAAE,MAAmB,EAC7B,OAAO,GAAE,MAAM,GAAG,SAAqB,EACvC,WAAW,CAAC,EAAE,GAAG,GAChB,SAAS,CAYX"}
@@ -1,6 +1,20 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.spawnBossWithSeed = exports.spawnBoss = exports.isSin = exports.isRepentanceBoss = exports.getEntityTypeVariantFromBossID = exports.getBosses = exports.getBossStageIDs = exports.getBossName = exports.getBossIDsForStageID = exports.getBossIDsForStage = exports.getBossIDFromEntityTypeVariant = exports.getBossID = exports.getAllNonStoryBosses = exports.getAllBosses = exports.getAliveBosses = void 0;
3
+ exports.getAliveBosses = getAliveBosses;
4
+ exports.getAllBosses = getAllBosses;
5
+ exports.getAllNonStoryBosses = getAllNonStoryBosses;
6
+ exports.getBossID = getBossID;
7
+ exports.getBossIDFromEntityTypeVariant = getBossIDFromEntityTypeVariant;
8
+ exports.getBossIDsForStage = getBossIDsForStage;
9
+ exports.getBossIDsForStageID = getBossIDsForStageID;
10
+ exports.getBossName = getBossName;
11
+ exports.getBossStageIDs = getBossStageIDs;
12
+ exports.getBosses = getBosses;
13
+ exports.getEntityTypeVariantFromBossID = getEntityTypeVariantFromBossID;
14
+ exports.isRepentanceBoss = isRepentanceBoss;
15
+ exports.isSin = isSin;
16
+ exports.spawnBoss = spawnBoss;
17
+ exports.spawnBossWithSeed = spawnBossWithSeed;
4
18
  const isaac_typescript_definitions_1 = require("isaac-typescript-definitions");
5
19
  const cachedClasses_1 = require("../core/cachedClasses");
6
20
  const constants_1 = require("../core/constants");
@@ -43,7 +57,6 @@ function getAliveBosses(entityType = -1, variant = -1, subType = -1, ignoreFrien
43
57
  const aliveNPCs = (0, npcs_1.getAliveNPCs)(entityType, variant, subType, ignoreFriendly);
44
58
  return aliveNPCs.filter((aliveNPC) => aliveNPC.IsBoss());
45
59
  }
46
- exports.getAliveBosses = getAliveBosses;
47
60
  /**
48
61
  * Helper function to get an array with every boss in the game. This is derived from the `BossID`
49
62
  * enum.
@@ -64,7 +77,6 @@ exports.getAliveBosses = getAliveBosses;
64
77
  function getAllBosses() {
65
78
  return bossSets_1.ALL_BOSSES;
66
79
  }
67
- exports.getAllBosses = getAllBosses;
68
80
  /**
69
81
  * Helper function to get an array with every boss in the game. This is derived from the `BossID`
70
82
  * enum. This is the same thing as the `getAllBosses` helper function, but with story bosses
@@ -73,7 +85,6 @@ exports.getAllBosses = getAllBosses;
73
85
  function getAllNonStoryBosses() {
74
86
  return bossSets_1.NON_STORY_BOSSES;
75
87
  }
76
- exports.getAllNonStoryBosses = getAllNonStoryBosses;
77
88
  /**
78
89
  * Helper function to get the boss ID corresponding to the current room. Returns undefined if the
79
90
  * current room is not a Boss Room.
@@ -89,7 +100,7 @@ function getBossID() {
89
100
  return isaac_typescript_definitions_1.BossID.BEAST;
90
101
  }
91
102
  const room = cachedClasses_1.game.GetRoom();
92
- // eslint-disable-next-line deprecation/deprecation
103
+ // eslint-disable-next-line @typescript-eslint/no-deprecated
93
104
  const bossID = room.GetBossID();
94
105
  if (bossID === 0) {
95
106
  return undefined;
@@ -101,12 +112,10 @@ function getBossID() {
101
112
  }
102
113
  return bossID;
103
114
  }
104
- exports.getBossID = getBossID;
105
115
  function getBossIDFromEntityTypeVariant(entityType, variant) {
106
116
  const entityTypeVariant = `${entityType}.${variant}`;
107
117
  return entityTypeVariantToBossIDMap_1.ENTITY_TYPE_VARIANT_TO_BOSS_ID_MAP.get(entityTypeVariant);
108
118
  }
109
- exports.getBossIDFromEntityTypeVariant = getBossIDFromEntityTypeVariant;
110
119
  /**
111
120
  * Helper function to get the set of vanilla bosses for a particular stage across all of the stage
112
121
  * types. For example, specifying `LevelStage.BASEMENT_2` will return a set with all of the bosses
@@ -117,7 +126,6 @@ exports.getBossIDFromEntityTypeVariant = getBossIDFromEntityTypeVariant;
117
126
  function getBossIDsForStage(stage) {
118
127
  return bossSets_1.STAGE_TO_COMBINED_BOSS_SET_MAP.get(stage);
119
128
  }
120
- exports.getBossIDsForStage = getBossIDsForStage;
121
129
  /**
122
130
  * Helper function to get the set of vanilla bosses that can randomly appear on a particular stage
123
131
  * ID.
@@ -127,7 +135,6 @@ exports.getBossIDsForStage = getBossIDsForStage;
127
135
  function getBossIDsForStageID(stageID) {
128
136
  return bossSets_1.STAGE_ID_TO_BOSS_IDS.get(stageID);
129
137
  }
130
- exports.getBossIDsForStageID = getBossIDsForStageID;
131
138
  /**
132
139
  * Helper function to get the proper English name for a boss. For example, the name for
133
140
  * `BossID.WRETCHED` (36) is "The Wretched".
@@ -137,12 +144,10 @@ function getBossName(bossID) {
137
144
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
138
145
  return bossNames_1.BOSS_NAMES[bossID] ?? bossNames_1.DEFAULT_BOSS_NAME;
139
146
  }
140
- exports.getBossName = getBossName;
141
147
  /** Helper function to get the set of stage IDs that a particular boss naturally appears in. */
142
148
  function getBossStageIDs(bossID) {
143
149
  return bossSets_1.BOSS_ID_TO_STAGE_IDS[bossID];
144
150
  }
145
- exports.getBossStageIDs = getBossStageIDs;
146
151
  /**
147
152
  * Helper function to get all of the bosses in the room.
148
153
  *
@@ -158,11 +163,9 @@ function getBosses(entityType, variant, subType, ignoreFriendly = false) {
158
163
  const npcs = (0, entitiesSpecific_1.getNPCs)(entityType, variant, subType, ignoreFriendly);
159
164
  return npcs.filter((npc) => npc.IsBoss());
160
165
  }
161
- exports.getBosses = getBosses;
162
166
  function getEntityTypeVariantFromBossID(bossID) {
163
167
  return bossIDToEntityTypeVariant_1.BOSS_ID_TO_ENTITY_TYPE_VARIANT[bossID];
164
168
  }
165
- exports.getEntityTypeVariantFromBossID = getEntityTypeVariantFromBossID;
166
169
  /**
167
170
  * Helper function to check if a boss is only found on a Repentance floor such as Dross, Mines, and
168
171
  * so on.
@@ -173,12 +176,10 @@ exports.getEntityTypeVariantFromBossID = getEntityTypeVariantFromBossID;
173
176
  function isRepentanceBoss(bossID) {
174
177
  return repentanceBossIDsSet_1.REPENTANCE_ONLY_BOSS_IDS_SET.has(bossID);
175
178
  }
176
- exports.isRepentanceBoss = isRepentanceBoss;
177
179
  /** Helper function to check if the provided NPC is a Sin miniboss, such as Sloth or Lust. */
178
180
  function isSin(npc) {
179
181
  return sinEntityTypesSet_1.SIN_ENTITY_TYPES_SET.has(npc.Type);
180
182
  }
181
- exports.isSin = isSin;
182
183
  function getNumBossSegments(entityType, variant, numSegments) {
183
184
  if (numSegments !== undefined) {
184
185
  return numSegments;
@@ -191,6 +192,7 @@ function getNumBossSegments(entityType, variant, numSegments) {
191
192
  }
192
193
  // 69
193
194
  case isaac_typescript_definitions_1.EntityType.LOKI: {
195
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-enum-comparison
194
196
  return variant === isaac_typescript_definitions_1.LokiVariant.LOKII ? 2 : 1;
195
197
  }
196
198
  // 237
@@ -225,7 +227,6 @@ function spawnBoss(entityType, variant, subType, positionOrGridIndex, velocity =
225
227
  }
226
228
  return npc;
227
229
  }
228
- exports.spawnBoss = spawnBoss;
229
230
  /**
230
231
  * Helper function to spawn a boss with a specific seed.
231
232
  *
@@ -235,4 +236,3 @@ function spawnBossWithSeed(entityType, variant, subType, positionOrGridIndex, se
235
236
  const seed = (0, rng_1.isRNG)(seedOrRNG) ? seedOrRNG.Next() : seedOrRNG;
236
237
  return spawnBoss(entityType, variant, subType, positionOrGridIndex, velocity, spawner, seed, numSegments);
237
238
  }
238
- exports.spawnBossWithSeed = spawnBossWithSeed;
@@ -1,6 +1,21 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.useCardTemp = exports.isVanillaCardType = exports.isValidCardType = exports.isTarotCard = exports.isSuitCard = exports.isSpecialCard = exports.isRune = exports.isReverseTarotCard = exports.isPocketItemObject = exports.isModdedCardType = exports.isCardType = exports.isCard = exports.hasCard = exports.getItemConfigCardType = exports.getCardName = exports.getCardDescription = void 0;
3
+ exports.getCardDescription = getCardDescription;
4
+ exports.getCardName = getCardName;
5
+ exports.getItemConfigCardType = getItemConfigCardType;
6
+ exports.hasCard = hasCard;
7
+ exports.isCard = isCard;
8
+ exports.isCardType = isCardType;
9
+ exports.isModdedCardType = isModdedCardType;
10
+ exports.isPocketItemObject = isPocketItemObject;
11
+ exports.isReverseTarotCard = isReverseTarotCard;
12
+ exports.isRune = isRune;
13
+ exports.isSpecialCard = isSpecialCard;
14
+ exports.isSuitCard = isSuitCard;
15
+ exports.isTarotCard = isTarotCard;
16
+ exports.isValidCardType = isValidCardType;
17
+ exports.isVanillaCardType = isVanillaCardType;
18
+ exports.useCardTemp = useCardTemp;
4
19
  const isaac_typescript_definitions_1 = require("isaac-typescript-definitions");
5
20
  const cachedEnumValues_1 = require("../cachedEnumValues");
6
21
  const cachedClasses_1 = require("../core/cachedClasses");
@@ -33,7 +48,6 @@ function getCardDescription(cardType) {
33
48
  }
34
49
  return cardDescriptions_1.DEFAULT_CARD_DESCRIPTION;
35
50
  }
36
- exports.getCardDescription = getCardDescription;
37
51
  /**
38
52
  * Helper function to get the name of a card. Returns "Unknown" if the provided card type is not
39
53
  * valid.
@@ -57,7 +71,6 @@ function getCardName(cardType) {
57
71
  }
58
72
  return cardNames_1.DEFAULT_CARD_NAME;
59
73
  }
60
- exports.getCardName = getCardName;
61
74
  /**
62
75
  * Helper function to get the item config card type of a particular card, rune, or object. For
63
76
  * example, the item config card type of `CardType.FOOL` is equal to `ItemConfigCardType.TAROT`.
@@ -71,7 +84,6 @@ function getItemConfigCardType(cardType) {
71
84
  }
72
85
  return itemConfigCard.CardType;
73
86
  }
74
- exports.getItemConfigCardType = getItemConfigCardType;
75
87
  /**
76
88
  * Helper function to check if a player is holding a specific card in one of their pocket item
77
89
  * slots.
@@ -86,7 +98,6 @@ function hasCard(player, ...cardTypes) {
86
98
  return cardTypesSet.has(cardType);
87
99
  });
88
100
  }
89
- exports.hasCard = hasCard;
90
101
  /**
91
102
  * Returns true for card types that have the following item config card type:
92
103
  *
@@ -102,57 +113,46 @@ function isCard(cardType) {
102
113
  }
103
114
  return itemConfigCardTypesForCards_1.ITEM_CONFIG_CARD_TYPES_FOR_CARDS.has(itemConfigCardType);
104
115
  }
105
- exports.isCard = isCard;
106
116
  /** Returns whether the given card type matches the specified item config card type. */
107
117
  function isCardType(cardType, itemConfigCardType) {
108
118
  return itemConfigCardType === getItemConfigCardType(cardType);
109
119
  }
110
- exports.isCardType = isCardType;
111
120
  /** Returns true for any card type added by a mod. */
112
121
  function isModdedCardType(cardType) {
113
122
  return !isVanillaCardType(cardType);
114
123
  }
115
- exports.isModdedCardType = isModdedCardType;
116
124
  /** Returns true for card types that have `ItemConfigCardType.SPECIAL_OBJECT`. */
117
125
  function isPocketItemObject(cardType) {
118
126
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.SPECIAL_OBJECT);
119
127
  }
120
- exports.isPocketItemObject = isPocketItemObject;
121
128
  /** Returns true for card types that have `ItemConfigCardType.TAROT_REVERSE`. */
122
129
  function isReverseTarotCard(cardType) {
123
130
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.TAROT_REVERSE);
124
131
  }
125
- exports.isReverseTarotCard = isReverseTarotCard;
126
132
  /** Returns true for card types that have `ItemConfigCardType.RUNE`. */
127
133
  function isRune(cardType) {
128
134
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.RUNE);
129
135
  }
130
- exports.isRune = isRune;
131
136
  /** Returns true for card types that have `ItemConfigCardType.SPECIAL`. */
132
137
  function isSpecialCard(cardType) {
133
138
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.SPECIAL);
134
139
  }
135
- exports.isSpecialCard = isSpecialCard;
136
140
  /** Returns true for card types that have `ItemConfigCardType.SUIT`. */
137
141
  function isSuitCard(cardType) {
138
142
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.SUIT);
139
143
  }
140
- exports.isSuitCard = isSuitCard;
141
144
  /** Returns true for card types that have `ItemConfigCardType.TAROT`. */
142
145
  function isTarotCard(cardType) {
143
146
  return isCardType(cardType, isaac_typescript_definitions_1.ItemConfigCardType.TAROT);
144
147
  }
145
- exports.isTarotCard = isTarotCard;
146
148
  function isValidCardType(cardType) {
147
149
  const potentialCardType = (0, types_1.asCardType)(cardType);
148
150
  const itemConfigCard = cachedClasses_1.itemConfig.GetCard(potentialCardType);
149
151
  return itemConfigCard !== undefined;
150
152
  }
151
- exports.isValidCardType = isValidCardType;
152
153
  function isVanillaCardType(cardType) {
153
154
  return cardType <= constantsFirstLast_1.LAST_VANILLA_CARD_TYPE;
154
155
  }
155
- exports.isVanillaCardType = isVanillaCardType;
156
156
  /**
157
157
  * Helper function to use a card without showing an animation and without the announcer voice
158
158
  * playing.
@@ -161,4 +161,3 @@ function useCardTemp(player, cardType) {
161
161
  const useFlags = (0, flag_1.addFlag)(isaac_typescript_definitions_1.UseFlag.NO_ANIMATION, isaac_typescript_definitions_1.UseFlag.NO_ANNOUNCER_VOICE);
162
162
  player.UseCard(cardType, useFlags);
163
163
  }
164
- exports.useCardTemp = useCardTemp;
@@ -1,6 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.setChallenge = exports.onChallenge = exports.onAnyChallenge = exports.getChallengeTrinketType = exports.getChallengeName = exports.getChallengeCollectibleTypes = exports.getChallengeCharacter = exports.getChallengeBoss = exports.clearChallenge = void 0;
3
+ exports.clearChallenge = clearChallenge;
4
+ exports.getChallengeBoss = getChallengeBoss;
5
+ exports.getChallengeCharacter = getChallengeCharacter;
6
+ exports.getChallengeCollectibleTypes = getChallengeCollectibleTypes;
7
+ exports.getChallengeName = getChallengeName;
8
+ exports.getChallengeTrinketType = getChallengeTrinketType;
9
+ exports.onAnyChallenge = onAnyChallenge;
10
+ exports.onChallenge = onChallenge;
11
+ exports.setChallenge = setChallenge;
4
12
  const isaac_typescript_definitions_1 = require("isaac-typescript-definitions");
5
13
  const challengeBosses_1 = require("../objects/challengeBosses");
6
14
  const challengeCharacters_1 = require("../objects/challengeCharacters");
@@ -23,7 +31,6 @@ function clearChallenge() {
23
31
  Isaac.ExecuteCommand(command);
24
32
  }
25
33
  }
26
- exports.clearChallenge = clearChallenge;
27
34
  /**
28
35
  * Get the final boss of a challenge. This will only work for vanilla challenges.
29
36
  *
@@ -38,7 +45,6 @@ function getChallengeBoss(challenge) {
38
45
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
39
46
  return challengeBossID ?? challengeBosses_1.DEFAULT_CHALLENGE_BOSS_ID;
40
47
  }
41
- exports.getChallengeBoss = getChallengeBoss;
42
48
  /**
43
49
  * Get the starting character of a challenge. This will only work for vanilla challenges.
44
50
  *
@@ -50,7 +56,6 @@ function getChallengeCharacter(challenge) {
50
56
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
51
57
  return challengeCharacter ?? challengeCharacters_1.DEFAULT_CHALLENGE_CHARACTER;
52
58
  }
53
- exports.getChallengeCharacter = getChallengeCharacter;
54
59
  /**
55
60
  * Get the extra starting collectibles for a challenge. This will only work for vanilla challenges.
56
61
  *
@@ -59,7 +64,6 @@ exports.getChallengeCharacter = getChallengeCharacter;
59
64
  function getChallengeCollectibleTypes(challenge) {
60
65
  return challengeCollectibleTypes_1.CHALLENGE_COLLECTIBLE_TYPES[challenge];
61
66
  }
62
- exports.getChallengeCollectibleTypes = getChallengeCollectibleTypes;
63
67
  /**
64
68
  * Get the proper name for a `Challenge` enum. This will only work for vanilla challenges.
65
69
  *
@@ -71,7 +75,6 @@ function getChallengeName(challenge) {
71
75
  // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
72
76
  return challengeName ?? challengeNames_1.DEFAULT_CHALLENGE_NAME;
73
77
  }
74
- exports.getChallengeName = getChallengeName;
75
78
  /**
76
79
  * Get the extra starting trinket for a challenge. This will only work for vanilla challenges.
77
80
  *
@@ -82,13 +85,11 @@ exports.getChallengeName = getChallengeName;
82
85
  function getChallengeTrinketType(challenge) {
83
86
  return challengeTrinketType_1.CHALLENGE_TRINKET_TYPE[challenge];
84
87
  }
85
- exports.getChallengeTrinketType = getChallengeTrinketType;
86
88
  /** Helper function to see if the player is playing any challenge. */
87
89
  function onAnyChallenge() {
88
90
  const challenge = Isaac.GetChallenge();
89
91
  return challenge !== isaac_typescript_definitions_1.Challenge.NULL;
90
92
  }
91
- exports.onAnyChallenge = onAnyChallenge;
92
93
  /**
93
94
  * Helper function to check to see if the player is playing a particular challenge.
94
95
  *
@@ -99,7 +100,6 @@ function onChallenge(...challenges) {
99
100
  const challenge = Isaac.GetChallenge();
100
101
  return challenges.includes(challenge);
101
102
  }
102
- exports.onChallenge = onChallenge;
103
103
  /**
104
104
  * Helper function to restart the run on a particular challenge.
105
105
  *
@@ -114,4 +114,3 @@ function setChallenge(challenge) {
114
114
  Isaac.ExecuteCommand(command);
115
115
  }
116
116
  }
117
- exports.setChallenge = setChallenge;
@@ -1,6 +1,22 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isVanillaCharacter = exports.isModdedCharacter = exports.isMainCharacter = exports.isFlyingCharacter = exports.getMainCharacter = exports.getCharacterStartingTrinketType = exports.getCharacterStartingCollectibleTypes = exports.getCharacterSpritePNGFilePath = exports.getCharacterName = exports.getCharacterMaxHeartContainers = exports.getCharacterDeathAnimationName = exports.getCharacterDamageMultiplier = exports.doesCharacterStartWithActiveItem = exports.doesCharacterGetBlackHeartFromEternalHeart = exports.canCharacterTakeFreeDevilDeals = exports.canCharacterHaveSoulHearts = exports.canCharacterHaveRedHearts = void 0;
3
+ exports.canCharacterHaveRedHearts = canCharacterHaveRedHearts;
4
+ exports.canCharacterHaveSoulHearts = canCharacterHaveSoulHearts;
5
+ exports.canCharacterTakeFreeDevilDeals = canCharacterTakeFreeDevilDeals;
6
+ exports.doesCharacterGetBlackHeartFromEternalHeart = doesCharacterGetBlackHeartFromEternalHeart;
7
+ exports.doesCharacterStartWithActiveItem = doesCharacterStartWithActiveItem;
8
+ exports.getCharacterDamageMultiplier = getCharacterDamageMultiplier;
9
+ exports.getCharacterDeathAnimationName = getCharacterDeathAnimationName;
10
+ exports.getCharacterMaxHeartContainers = getCharacterMaxHeartContainers;
11
+ exports.getCharacterName = getCharacterName;
12
+ exports.getCharacterSpritePNGFilePath = getCharacterSpritePNGFilePath;
13
+ exports.getCharacterStartingCollectibleTypes = getCharacterStartingCollectibleTypes;
14
+ exports.getCharacterStartingTrinketType = getCharacterStartingTrinketType;
15
+ exports.getMainCharacter = getMainCharacter;
16
+ exports.isFlyingCharacter = isFlyingCharacter;
17
+ exports.isMainCharacter = isMainCharacter;
18
+ exports.isModdedCharacter = isModdedCharacter;
19
+ exports.isVanillaCharacter = isVanillaCharacter;
4
20
  const isaac_typescript_definitions_1 = require("isaac-typescript-definitions");
5
21
  const constants_1 = require("../core/constants");
6
22
  const constantsFirstLast_1 = require("../core/constantsFirstLast");
@@ -28,7 +44,6 @@ const PNG_PATH_PREFIX = "characters/costumes";
28
44
  function canCharacterHaveRedHearts(character) {
29
45
  return !charactersWithNoRedHeartsSet_1.CHARACTERS_WITH_NO_RED_HEARTS_SET.has(character);
30
46
  }
31
- exports.canCharacterHaveRedHearts = canCharacterHaveRedHearts;
32
47
  /**
33
48
  * Helper function to determine if the given character can have soul hearts. Returns true for
34
49
  * characters like Isaac, Magdalene, or Cain. Returns false for characters like Bethany. Returns
@@ -37,7 +52,6 @@ exports.canCharacterHaveRedHearts = canCharacterHaveRedHearts;
37
52
  function canCharacterHaveSoulHearts(character) {
38
53
  return !charactersWithNoSoulHeartsSet_1.CHARACTERS_WITH_NO_SOUL_HEARTS_SET.has(character);
39
54
  }
40
- exports.canCharacterHaveSoulHearts = canCharacterHaveSoulHearts;
41
55
  /**
42
56
  * Helper function for determining whether the given character can take free Devil Deals. (e.g. The
43
57
  * Lost, Tainted Lost, etc.)
@@ -45,7 +59,6 @@ exports.canCharacterHaveSoulHearts = canCharacterHaveSoulHearts;
45
59
  function canCharacterTakeFreeDevilDeals(character) {
46
60
  return charactersWithFreeDevilDealsSet_1.CHARACTERS_WITH_FREE_DEVIL_DEALS_SET.has(character);
47
61
  }
48
- exports.canCharacterTakeFreeDevilDeals = canCharacterTakeFreeDevilDeals;
49
62
  /**
50
63
  * Normally, characters get a red heart container upon reaching a new floor with an eternal heart,
51
64
  * but some characters grant a black heart instead. Returns true for Dark Judas and Tainted Judas.
@@ -54,7 +67,6 @@ exports.canCharacterTakeFreeDevilDeals = canCharacterTakeFreeDevilDeals;
54
67
  function doesCharacterGetBlackHeartFromEternalHeart(character) {
55
68
  return charactersWithBlackHeartFromEternalHeartSet_1.CHARACTERS_WITH_BLACK_HEART_FROM_ETERNAL_HEART_SET.has(character);
56
69
  }
57
- exports.doesCharacterGetBlackHeartFromEternalHeart = doesCharacterGetBlackHeartFromEternalHeart;
58
70
  /**
59
71
  * Helper function to determine if the specified character starts with an active item.
60
72
  *
@@ -64,7 +76,6 @@ exports.doesCharacterGetBlackHeartFromEternalHeart = doesCharacterGetBlackHeartF
64
76
  function doesCharacterStartWithActiveItem(character) {
65
77
  return charactersThatStartWithAnActiveItemSet_1.CHARACTERS_THAT_START_WITH_AN_ACTIVE_ITEM_SET.has(character);
66
78
  }
67
- exports.doesCharacterStartWithActiveItem = doesCharacterStartWithActiveItem;
68
79
  /**
69
80
  * Helper function to get the numerical damage multiplier for a character.
70
81
  *
@@ -80,7 +91,6 @@ function getCharacterDamageMultiplier(character, hasWhoreOfBabylon = false) {
80
91
  }
81
92
  return characterDamageMultipliers_1.CHARACTER_DAMAGE_MULTIPLIERS[character];
82
93
  }
83
- exports.getCharacterDamageMultiplier = getCharacterDamageMultiplier;
84
94
  /**
85
95
  * - Most characters have a 56 frame death animation (i.e. the "Death" animation).
86
96
  * - The Lost and Tainted Lost have a 38 frame death animation (i.e. the "LostDeath" animation).
@@ -95,7 +105,6 @@ function getCharacterDeathAnimationName(character) {
95
105
  }
96
106
  return "Death";
97
107
  }
98
- exports.getCharacterDeathAnimationName = getCharacterDeathAnimationName;
99
108
  /**
100
109
  * Returns the maximum heart containers that the provided character can have. Normally, this is 12,
101
110
  * but with Keeper it is 3, and with Tainted Keeper it is 2. This does not account for Birthright or
@@ -120,7 +129,6 @@ function getCharacterMaxHeartContainers(character) {
120
129
  }
121
130
  return 12;
122
131
  }
123
- exports.getCharacterMaxHeartContainers = getCharacterMaxHeartContainers;
124
132
  /** Helper function to get the name of a character. Returns "Unknown" for modded characters. */
125
133
  function getCharacterName(character) {
126
134
  if (isModdedCharacter(character)) {
@@ -128,7 +136,6 @@ function getCharacterName(character) {
128
136
  }
129
137
  return characterNames_1.CHARACTER_NAMES[character];
130
138
  }
131
- exports.getCharacterName = getCharacterName;
132
139
  /**
133
140
  * Helper function to get the path to the sprite for a particular character.
134
141
  *
@@ -139,7 +146,6 @@ function getCharacterSpritePNGFilePath(character) {
139
146
  const fileName = characterSpritePNGFileNames_1.CHARACTER_SPRITE_PNG_FILE_NAMES[character];
140
147
  return `${PNG_PATH_PREFIX}/${fileName}`;
141
148
  }
142
- exports.getCharacterSpritePNGFilePath = getCharacterSpritePNGFilePath;
143
149
  /**
144
150
  * Helper function to get the collectibles that are granted to a particular character at the
145
151
  * beginning of a run.
@@ -149,7 +155,6 @@ exports.getCharacterSpritePNGFilePath = getCharacterSpritePNGFilePath;
149
155
  function getCharacterStartingCollectibleTypes(character) {
150
156
  return characterStartingCollectibleTypes_1.CHARACTER_STARTING_COLLECTIBLE_TYPES[character];
151
157
  }
152
- exports.getCharacterStartingCollectibleTypes = getCharacterStartingCollectibleTypes;
153
158
  /**
154
159
  * Helper function to get the trinket that is granted to a particular character at the beginning of
155
160
  * a run. Returns undefined if the character does not start with a trinket.
@@ -159,7 +164,6 @@ exports.getCharacterStartingCollectibleTypes = getCharacterStartingCollectibleTy
159
164
  function getCharacterStartingTrinketType(character) {
160
165
  return characterStartingTrinketTypes_1.CHARACTER_STARTING_TRINKET_TYPE[character];
161
166
  }
162
- exports.getCharacterStartingTrinketType = getCharacterStartingTrinketType;
163
167
  /**
164
168
  * Helper function to get the "main" version of the character. In other words, this is the character
165
169
  * that selectable from the main menu (and has achievements related to completing the various bosses
@@ -209,11 +213,9 @@ function getMainCharacter(character) {
209
213
  }
210
214
  }
211
215
  }
212
- exports.getMainCharacter = getMainCharacter;
213
216
  function isFlyingCharacter(character) {
214
217
  return FLYING_CHARACTERS_SET.has(character);
215
218
  }
216
- exports.isFlyingCharacter = isFlyingCharacter;
217
219
  /**
218
220
  * Helper function to check if the provided character is one of the characters that are selectable
219
221
  * from the main menu (and have achievements related to completing the various bosses and so on).
@@ -221,12 +223,9 @@ exports.isFlyingCharacter = isFlyingCharacter;
221
223
  function isMainCharacter(character) {
222
224
  return MAIN_CHARACTERS_SET.has(character);
223
225
  }
224
- exports.isMainCharacter = isMainCharacter;
225
226
  function isModdedCharacter(character) {
226
227
  return !isVanillaCharacter(character);
227
228
  }
228
- exports.isModdedCharacter = isModdedCharacter;
229
229
  function isVanillaCharacter(character) {
230
230
  return character <= constantsFirstLast_1.LAST_VANILLA_CHARACTER;
231
231
  }
232
- exports.isVanillaCharacter = isVanillaCharacter;
@@ -1 +1 @@
1
- {"version":3,"file":"charge.d.ts","sourceRoot":"","sources":["../../src/functions/charge.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,eAAe,EAIhB,MAAM,8BAA8B,CAAC;AAUtC;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,SAAS,CACvB,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,EAC/B,UAAU,SAAI,EACd,eAAe,UAAO,GACrB,GAAG,CA+BL;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,YAAY,EACpB,mBAAmB,UAAO,EAC1B,eAAe,UAAO,GACrB,IAAI,CAaN;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,EAC/B,mBAAmB,UAAO,EAC1B,eAAe,UAAO,GACrB,IAAI,CA4BN;AAqBD;;;;;;;;;;;;GAYG;AACH,wBAAgB,mBAAmB,CAAC,mBAAmB,UAAO,GAAG,IAAI,CAIpE;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,GAAG,CAQL;AAED;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,GAAG,CAKL;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,eAAe,GAC/B,SAAS,UAAU,EAAE,CAOvB;AAED;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,OAAO,CAMT;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,IAAI,CAYN"}
1
+ {"version":3,"file":"charge.d.ts","sourceRoot":"","sources":["../../src/functions/charge.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,eAAe,EAIhB,MAAM,8BAA8B,CAAC;AAUtC;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,SAAS,CACvB,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,EAC/B,UAAU,SAAI,EACd,eAAe,UAAO,GACrB,GAAG,CA8BL;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,YAAY,EACpB,mBAAmB,UAAO,EAC1B,eAAe,UAAO,GACrB,IAAI,CAaN;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,EAC/B,mBAAmB,UAAO,EAC1B,eAAe,UAAO,GACrB,IAAI,CA4BN;AAqBD;;;;;;;;;;;;GAYG;AACH,wBAAgB,mBAAmB,CAAC,mBAAmB,UAAO,GAAG,IAAI,CAIpE;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,GAAG,CAQL;AAED;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,GAAG,CAKL;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CACtC,MAAM,EAAE,YAAY,EACpB,eAAe,EAAE,eAAe,GAC/B,SAAS,UAAU,EAAE,CAOvB;AAED;;;;;;GAMG;AACH,wBAAgB,yBAAyB,CACvC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,OAAO,CAMT;AAED;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,YAAY,EACpB,UAAU,aAAqB,GAC9B,IAAI,CAYN"}
@@ -1,6 +1,14 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.playChargeSoundEffect = exports.isActiveSlotDoubleCharged = exports.getUsableActiveItemSlots = exports.getTotalCharge = exports.getChargesAwayFromMax = exports.addRoomClearCharges = exports.addRoomClearChargeToSlot = exports.addRoomClearCharge = exports.addCharge = void 0;
3
+ exports.addCharge = addCharge;
4
+ exports.addRoomClearCharge = addRoomClearCharge;
5
+ exports.addRoomClearChargeToSlot = addRoomClearChargeToSlot;
6
+ exports.addRoomClearCharges = addRoomClearCharges;
7
+ exports.getChargesAwayFromMax = getChargesAwayFromMax;
8
+ exports.getTotalCharge = getTotalCharge;
9
+ exports.getUsableActiveItemSlots = getUsableActiveItemSlots;
10
+ exports.isActiveSlotDoubleCharged = isActiveSlotDoubleCharged;
11
+ exports.playChargeSoundEffect = playChargeSoundEffect;
4
12
  const isaac_typescript_definitions_1 = require("isaac-typescript-definitions");
5
13
  const cachedClasses_1 = require("../core/cachedClasses");
6
14
  const collectibles_1 = require("./collectibles");
@@ -32,7 +40,7 @@ function addCharge(player, activeSlot = isaac_typescript_definitions_1.ActiveSlo
32
40
  // add too many charges, it will grant orange "battery" charges, even if the player does not have
33
41
  // The Battery.)
34
42
  const chargesAwayFromMax = getChargesAwayFromMax(player, activeSlot);
35
- const chargesToAdd = numCharges > chargesAwayFromMax ? chargesAwayFromMax : numCharges;
43
+ const chargesToAdd = Math.min(numCharges, chargesAwayFromMax);
36
44
  // The AAA Battery trinket might grant an additional charge.
37
45
  const modifiedChargesToAdd = getChargesToAddWithAAAModifier(player, activeSlot, chargesToAdd);
38
46
  const totalCharge = getTotalCharge(player, activeSlot);
@@ -47,7 +55,6 @@ function addCharge(player, activeSlot = isaac_typescript_definitions_1.ActiveSlo
47
55
  }
48
56
  return modifiedChargesToAdd;
49
57
  }
50
- exports.addCharge = addCharge;
51
58
  /**
52
59
  * Helper function to add a charge to a player's active item(s), emulating what happens when a room
53
60
  * is cleared.
@@ -73,7 +80,6 @@ function addRoomClearCharge(player, bigRoomDoubleCharge = true, playSoundEffect
73
80
  addRoomClearChargeToSlot(player, activeSlot, bigRoomDoubleCharge, playSoundEffect);
74
81
  }
75
82
  }
76
- exports.addRoomClearCharge = addRoomClearCharge;
77
83
  /**
78
84
  * Helper function to add a charge to one of a player's active items, emulating what happens when a
79
85
  * room is cleared.
@@ -116,7 +122,6 @@ function addRoomClearChargeToSlot(player, activeSlot = isaac_typescript_definiti
116
122
  }
117
123
  addCharge(player, activeSlot, numCharges, playSoundEffect);
118
124
  }
119
- exports.addRoomClearChargeToSlot = addRoomClearChargeToSlot;
120
125
  /**
121
126
  * The AAA Battery should grant an extra charge when the active item is one away from being fully
122
127
  * charged.
@@ -148,7 +153,6 @@ function addRoomClearCharges(bigRoomDoubleCharge = true) {
148
153
  addRoomClearCharge(player, bigRoomDoubleCharge);
149
154
  }
150
155
  }
151
- exports.addRoomClearCharges = addRoomClearCharges;
152
156
  /**
153
157
  * Helper function to get the amount of charges away from the maximum charge that a particular
154
158
  * player is.
@@ -168,7 +172,6 @@ function getChargesAwayFromMax(player, activeSlot = isaac_typescript_definitions
168
172
  const effectiveMaxCharges = hasBattery ? maxCharges * 2 : maxCharges;
169
173
  return effectiveMaxCharges - totalCharge;
170
174
  }
171
- exports.getChargesAwayFromMax = getChargesAwayFromMax;
172
175
  /**
173
176
  * Helper function to get the combined normal charge and the battery charge for the player's active
174
177
  * item. This is useful because you have to add these two values together when setting the active
@@ -182,7 +185,6 @@ function getTotalCharge(player, activeSlot = isaac_typescript_definitions_1.Acti
182
185
  const batteryCharge = player.GetBatteryCharge(activeSlot);
183
186
  return activeCharge + batteryCharge;
184
187
  }
185
- exports.getTotalCharge = getTotalCharge;
186
188
  /**
187
189
  * Helper function to find the active slots that the player has the corresponding collectible type
188
190
  * in and have enough charge to be used. Returns an empty array if the player does not have the
@@ -196,7 +198,6 @@ function getUsableActiveItemSlots(player, collectibleType) {
196
198
  return totalCharge >= maxCharges;
197
199
  });
198
200
  }
199
- exports.getUsableActiveItemSlots = getUsableActiveItemSlots;
200
201
  /**
201
202
  * Helper function to check if a player's active item is "double charged", meaning that it has both
202
203
  * a full normal charge and a full charge from The Battery.
@@ -210,7 +211,6 @@ function isActiveSlotDoubleCharged(player, activeSlot = isaac_typescript_definit
210
211
  const maxCharges = (0, collectibles_1.getCollectibleMaxCharges)(collectibleType);
211
212
  return batteryCharge >= maxCharges;
212
213
  }
213
- exports.isActiveSlotDoubleCharged = isActiveSlotDoubleCharged;
214
214
  /**
215
215
  * Helper function to play the appropriate sound effect for a player after getting one or more
216
216
  * charges on their active item. (There is a different sound depending on whether the item is fully
@@ -231,7 +231,6 @@ function playChargeSoundEffect(player, activeSlot = isaac_typescript_definitions
231
231
  : isaac_typescript_definitions_1.SoundEffect.BEEP;
232
232
  cachedClasses_1.sfxManager.Play(chargeSoundEffect);
233
233
  }
234
- exports.playChargeSoundEffect = playChargeSoundEffect;
235
234
  function shouldPlayFullRechargeSound(player, activeSlot) {
236
235
  const activeItem = player.GetActiveItem(activeSlot);
237
236
  const activeCharge = player.GetActiveCharge(activeSlot);
@@ -49,7 +49,7 @@ function ____exports.addCharge(self, player, activeSlot, numCharges, playSoundEf
49
49
  end
50
50
  local hud = game:GetHUD()
51
51
  local chargesAwayFromMax = ____exports.getChargesAwayFromMax(nil, player, activeSlot)
52
- local chargesToAdd = numCharges > chargesAwayFromMax and chargesAwayFromMax or numCharges
52
+ local chargesToAdd = math.min(numCharges, chargesAwayFromMax)
53
53
  local modifiedChargesToAdd = getChargesToAddWithAAAModifier(nil, player, activeSlot, chargesToAdd)
54
54
  local totalCharge = ____exports.getTotalCharge(nil, player, activeSlot)
55
55
  local newCharge = totalCharge + modifiedChargesToAdd
@@ -1,5 +1,3 @@
1
- /// <reference types="isaac-typescript-definitions" />
2
- /// <reference types="isaac-typescript-definitions" />
3
1
  import type { ChargeBarSprites } from "../interfaces/ChargeBarSprites";
4
2
  /**
5
3
  * Constructor for a `ChargeBarSprites` object. For more information, see the `renderChargeBar`
@@ -1 +1 @@
1
- {"version":3,"file":"chargeBar.d.ts","sourceRoot":"","sources":["../../src/functions/chargeBar.ts"],"names":[],"mappings":";;AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAIvE;;;;;;GAMG;AACH,wBAAgB,mBAAmB,CAAC,UAAU,EAAE,GAAG,GAAG,gBAAgB,CAwBrE;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,gBAAgB,EACzB,QAAQ,EAAE,MAAM,EAChB,aAAa,EAAE,GAAG,EAClB,cAAc,EAAE,GAAG,GAClB,IAAI,CAgBN"}
1
+ {"version":3,"file":"chargeBar.d.ts","sourceRoot":"","sources":["../../src/functions/chargeBar.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAIvE;;;;;;GAMG;AACH,wBAAgB,mBAAmB,CAAC,UAAU,EAAE,GAAG,GAAG,gBAAgB,CAwBrE;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,gBAAgB,EACzB,QAAQ,EAAE,MAAM,EAChB,aAAa,EAAE,GAAG,EAClB,cAAc,EAAE,GAAG,GAClB,IAAI,CAgBN"}