isaacscript-common 11.2.4 → 12.0.0

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 (67) hide show
  1. package/dist/index.d.ts +8 -3
  2. package/dist/isaacscript-common.lua +138 -62
  3. package/dist/package.lua +1 -1
  4. package/dist/src/features/customStage/backdrop.lua +2 -2
  5. package/dist/src/features/customStage/{customStageConstants.d.ts → constants.d.ts} +1 -1
  6. package/dist/src/features/customStage/constants.d.ts.map +1 -0
  7. package/dist/src/features/customStage/{customStageConstants.lua → constants.lua} +0 -0
  8. package/dist/src/features/customStage/init.lua +2 -2
  9. package/dist/src/features/customStage/shadows.lua +2 -2
  10. package/dist/src/features/customStage/streakText.d.ts.map +1 -1
  11. package/dist/src/features/customStage/streakText.lua +3 -3
  12. package/dist/src/features/customStage/v.d.ts +1 -1
  13. package/dist/src/features/customStage/v.d.ts.map +1 -1
  14. package/dist/src/features/customStage/v.lua +2 -2
  15. package/dist/src/features/customStage/versusScreen.lua +3 -3
  16. package/dist/src/features/customTrapdoor/{customTrapdoorConstants.d.ts → constants.d.ts} +1 -1
  17. package/dist/src/features/customTrapdoor/constants.d.ts.map +1 -0
  18. package/dist/src/features/customTrapdoor/{customTrapdoorConstants.lua → constants.lua} +0 -0
  19. package/dist/src/features/customTrapdoor/exports.lua +2 -2
  20. package/dist/src/features/customTrapdoor/init.lua +4 -4
  21. package/dist/src/features/customTrapdoor/openClose.lua +4 -4
  22. package/dist/src/features/customTrapdoor/spawn.lua +2 -2
  23. package/dist/src/features/customTrapdoor/touched.lua +6 -6
  24. package/dist/src/features/saveDataManager/constants.d.ts +10 -0
  25. package/dist/src/features/saveDataManager/constants.d.ts.map +1 -0
  26. package/dist/src/features/saveDataManager/constants.lua +10 -0
  27. package/dist/src/features/saveDataManager/exports.d.ts +8 -3
  28. package/dist/src/features/saveDataManager/exports.d.ts.map +1 -1
  29. package/dist/src/features/saveDataManager/exports.lua +10 -5
  30. package/dist/src/features/saveDataManager/load.d.ts.map +1 -1
  31. package/dist/src/features/saveDataManager/load.lua +9 -9
  32. package/dist/src/features/saveDataManager/main.d.ts.map +1 -1
  33. package/dist/src/features/saveDataManager/main.lua +67 -4
  34. package/dist/src/features/saveDataManager/maps.d.ts +5 -0
  35. package/dist/src/features/saveDataManager/maps.d.ts.map +1 -1
  36. package/dist/src/features/saveDataManager/maps.lua +3 -0
  37. package/dist/src/features/saveDataManager/merge.lua +2 -2
  38. package/dist/src/features/saveDataManager/save.lua +3 -3
  39. package/dist/src/functions/deepCopy.lua +2 -2
  40. package/package.json +1 -1
  41. package/src/features/customStage/backdrop.ts +1 -1
  42. package/src/features/customStage/{customStageConstants.ts → constants.ts} +0 -0
  43. package/src/features/customStage/init.ts +1 -1
  44. package/src/features/customStage/shadows.ts +1 -1
  45. package/src/features/customStage/streakText.ts +1 -4
  46. package/src/features/customStage/v.ts +1 -1
  47. package/src/features/customStage/versusScreen.ts +1 -1
  48. package/src/features/customTrapdoor/{customTrapdoorConstants.ts → constants.ts} +0 -0
  49. package/src/features/customTrapdoor/exports.ts +1 -1
  50. package/src/features/customTrapdoor/init.ts +1 -1
  51. package/src/features/customTrapdoor/openClose.ts +1 -1
  52. package/src/features/customTrapdoor/spawn.ts +1 -1
  53. package/src/features/customTrapdoor/touched.ts +1 -1
  54. package/src/features/saveDataManager/constants.ts +15 -0
  55. package/src/features/saveDataManager/exports.ts +9 -4
  56. package/src/features/saveDataManager/load.ts +13 -9
  57. package/src/features/saveDataManager/main.ts +78 -4
  58. package/src/features/saveDataManager/maps.ts +6 -0
  59. package/src/features/saveDataManager/merge.ts +1 -1
  60. package/src/features/saveDataManager/save.ts +1 -1
  61. package/src/functions/deepCopy.ts +1 -1
  62. package/dist/src/features/customStage/customStageConstants.d.ts.map +0 -1
  63. package/dist/src/features/customTrapdoor/customTrapdoorConstants.d.ts.map +0 -1
  64. package/dist/src/features/saveDataManager/saveDataManagerConstants.d.ts +0 -4
  65. package/dist/src/features/saveDataManager/saveDataManagerConstants.d.ts.map +0 -1
  66. package/dist/src/features/saveDataManager/saveDataManagerConstants.lua +0 -5
  67. package/src/features/saveDataManager/saveDataManagerConstants.ts +0 -4
package/dist/index.d.ts CHANGED
@@ -10414,9 +10414,14 @@ export declare enum SaveDataKey {
10414
10414
  * data manager cannot do this on its own because it cannot know when your mod features are finished
10415
10415
  * initializing.)
10416
10416
  *
10417
- * Finally, some features may have variables that need to be automatically reset per run/level, but
10418
- * not saved to disk on game exit. (For example, if they contain functions or other non-serializable
10419
- * data.) For these cases, set the second argument to `() => false`.
10417
+ * Some features may have variables that need to be automatically reset per run/level, but not saved
10418
+ * to disk on game exit. (For example, if they contain functions or other non-serializable data.)
10419
+ * For these cases, set the second argument to `() => false`.
10420
+ *
10421
+ * Note that when the player uses Glowing Hour Glass, the save data manager will automatically
10422
+ * restore any variables on a "run" or "level" object with a backup that was created when the room
10423
+ * was entered. Thus, you should not have to explicitly program support for Glowing Hour Glass into
10424
+ * your mod features that use the save data manager.
10420
10425
  *
10421
10426
  * @param key The name of the file or feature that is submitting data to be managed by the save data
10422
10427
  * manager. The save data manager will throw an error if the key is already registered.
@@ -1,6 +1,6 @@
1
1
  --[[
2
2
 
3
- isaacscript-common 11.2.4
3
+ isaacscript-common 12.0.0
4
4
 
5
5
  This is the "isaacscript-common" library, which was created with the IsaacScript tool.
6
6
 
@@ -26923,11 +26923,16 @@ ____exports.SerializationType.DESERIALIZE = 2
26923
26923
  ____exports.SerializationType[____exports.SerializationType.DESERIALIZE] = "DESERIALIZE"
26924
26924
  return ____exports
26925
26925
  end,
26926
- ["src.features.saveDataManager.saveDataManagerConstants"] = function(...)
26926
+ ["src.features.saveDataManager.constants"] = function(...)
26927
26927
  local ____exports = {}
26928
+ local ____SaveDataKey = require("src.enums.SaveDataKey")
26929
+ local SaveDataKey = ____SaveDataKey.SaveDataKey
26928
26930
  --- Set this to true to enable more verbosity in the save data manger.
26929
26931
  ____exports.SAVE_DATA_MANAGER_DEBUG = false
26930
26932
  ____exports.SAVE_DATA_MANAGER_FEATURE_NAME = "save data manager"
26933
+ --- When the Glowing Hour Glass is used, certain save data keys will automatically be restored to a
26934
+ -- backup.
26935
+ ____exports.SAVE_DATA_MANAGER_GLOWING_HOUR_GLASS_BACKUP_KEYS = {SaveDataKey.RUN, SaveDataKey.LEVEL}
26931
26936
  return ____exports
26932
26937
  end,
26933
26938
  ["src.features.saveDataManager.serializationBrands"] = function(...)
@@ -30051,8 +30056,8 @@ local ____SerializationBrand = require("src.enums.private.SerializationBrand")
30051
30056
  local SerializationBrand = ____SerializationBrand.SerializationBrand
30052
30057
  local ____SerializationType = require("src.enums.SerializationType")
30053
30058
  local SerializationType = ____SerializationType.SerializationType
30054
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
30055
- local SAVE_DATA_MANAGER_DEBUG = ____saveDataManagerConstants.SAVE_DATA_MANAGER_DEBUG
30059
+ local ____constants = require("src.features.saveDataManager.constants")
30060
+ local SAVE_DATA_MANAGER_DEBUG = ____constants.SAVE_DATA_MANAGER_DEBUG
30056
30061
  local ____serializationBrands = require("src.features.saveDataManager.serializationBrands")
30057
30062
  local isSerializationBrand = ____serializationBrands.isSerializationBrand
30058
30063
  local ____array = require("src.functions.array")
@@ -31355,8 +31360,8 @@ local ____types = require("src.functions.types")
31355
31360
  local isTable = ____types.isTable
31356
31361
  local ____utils = require("src.functions.utils")
31357
31362
  local getTraversalDescription = ____utils.getTraversalDescription
31358
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
31359
- local SAVE_DATA_MANAGER_DEBUG = ____saveDataManagerConstants.SAVE_DATA_MANAGER_DEBUG
31363
+ local ____constants = require("src.features.saveDataManager.constants")
31364
+ local SAVE_DATA_MANAGER_DEBUG = ____constants.SAVE_DATA_MANAGER_DEBUG
31360
31365
  local ____serializationBrands = require("src.features.saveDataManager.serializationBrands")
31361
31366
  local isSerializationBrand = ____serializationBrands.isSerializationBrand
31362
31367
  --- `merge` takes the values from a new table and recursively merges them into an old object (while
@@ -31496,11 +31501,11 @@ local iterateTableInOrder = ____table.iterateTableInOrder
31496
31501
  local ____types = require("src.functions.types")
31497
31502
  local isString = ____types.isString
31498
31503
  local isTable = ____types.isTable
31504
+ local ____constants = require("src.features.saveDataManager.constants")
31505
+ local SAVE_DATA_MANAGER_DEBUG = ____constants.SAVE_DATA_MANAGER_DEBUG
31506
+ local SAVE_DATA_MANAGER_FEATURE_NAME = ____constants.SAVE_DATA_MANAGER_FEATURE_NAME
31499
31507
  local ____merge = require("src.features.saveDataManager.merge")
31500
31508
  local merge = ____merge.merge
31501
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
31502
- local SAVE_DATA_MANAGER_DEBUG = ____saveDataManagerConstants.SAVE_DATA_MANAGER_DEBUG
31503
- local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MANAGER_FEATURE_NAME
31504
31509
  function readSaveDatFile(self, mod)
31505
31510
  local renderFrameCount = Isaac.GetFrameCount()
31506
31511
  local ok, jsonStringOrErrMsg = pcall(tryLoadModData, mod)
@@ -31536,21 +31541,21 @@ function ____exports.loadFromDisk(self, mod, oldSaveData)
31536
31541
  iterateTableInOrder(
31537
31542
  nil,
31538
31543
  newSaveData,
31539
- function(____, key, value)
31540
- if not isString(nil, key) then
31544
+ function(____, subscriberName, saveData)
31545
+ if not isString(nil, subscriberName) then
31541
31546
  return
31542
31547
  end
31543
- if not isTable(nil, value) then
31548
+ if not isTable(nil, saveData) then
31544
31549
  return
31545
31550
  end
31546
- local oldSaveDataForSubscriber = oldSaveData[key]
31551
+ local oldSaveDataForSubscriber = oldSaveData[subscriberName]
31547
31552
  if oldSaveDataForSubscriber == nil then
31548
31553
  return
31549
31554
  end
31550
31555
  if SAVE_DATA_MANAGER_DEBUG then
31551
- log(nil, "Merging in stored data for feature: " .. key)
31556
+ log(nil, "Merging in stored data for feature: " .. subscriberName)
31552
31557
  end
31553
- merge(nil, oldSaveDataForSubscriber, value, key)
31558
+ merge(nil, oldSaveDataForSubscriber, saveData, subscriberName)
31554
31559
  end,
31555
31560
  SAVE_DATA_MANAGER_DEBUG
31556
31561
  )
@@ -31566,6 +31571,9 @@ local ____exports = {}
31566
31571
  ____exports.saveDataMap = {}
31567
31572
  ____exports.saveDataDefaultsMap = {}
31568
31573
  ____exports.saveDataConditionalFuncMap = {}
31574
+ --- We backup some save data keys on every new room for the purposes of restoring it when Glowing
31575
+ -- Hour Glass is used.
31576
+ ____exports.saveDataGlowingHourGlassMap = {}
31569
31577
  return ____exports
31570
31578
  end,
31571
31579
  ["src.features.saveDataManager.save"] = function(...)
@@ -31583,9 +31591,9 @@ local ____log = require("src.functions.log")
31583
31591
  local log = ____log.log
31584
31592
  local ____table = require("src.functions.table")
31585
31593
  local iterateTableInOrder = ____table.iterateTableInOrder
31586
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
31587
- local SAVE_DATA_MANAGER_DEBUG = ____saveDataManagerConstants.SAVE_DATA_MANAGER_DEBUG
31588
- local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MANAGER_FEATURE_NAME
31594
+ local ____constants = require("src.features.saveDataManager.constants")
31595
+ local SAVE_DATA_MANAGER_DEBUG = ____constants.SAVE_DATA_MANAGER_DEBUG
31596
+ local SAVE_DATA_MANAGER_FEATURE_NAME = ____constants.SAVE_DATA_MANAGER_FEATURE_NAME
31589
31597
  function getAllSaveDataToWriteToDisk(self, saveDataMap, saveDataConditionalFuncMap)
31590
31598
  local allSaveData = {}
31591
31599
  iterateTableInOrder(
@@ -31623,7 +31631,7 @@ local ____lualib = require("lualib_bundle")
31623
31631
  local Set = ____lualib.Set
31624
31632
  local __TS__New = ____lualib.__TS__New
31625
31633
  local ____exports = {}
31626
- local postUseItemGlowingHourGlass, postPlayerInit, preGameExit, postNewLevel, postNewRoomEarly, restoreDefaultsAll, restoreDefaults, clearAndCopyAllElements, RESETTABLE_SAVE_DATA_KEYS, mod, loadedDataOnThisRun
31634
+ local postUseItemGlowingHourGlass, postPlayerInit, preGameExit, postNewLevel, postNewRoomEarly, makeGlowingHourGlassBackup, restoreGlowingHourGlassBackup, restoreDefaultsAll, restoreDefaults, clearAndCopyAllElements, RESETTABLE_SAVE_DATA_KEYS, mod, loadedDataOnThisRun, restoreGlowingHourGlassDataOnNextRoom
31627
31635
  local ____isaac_2Dtypescript_2Ddefinitions = require("lua_modules.isaac-typescript-definitions.dist.src.index")
31628
31636
  local CollectibleType = ____isaac_2Dtypescript_2Ddefinitions.CollectibleType
31629
31637
  local ModCallback = ____isaac_2Dtypescript_2Ddefinitions.ModCallback
@@ -31644,18 +31652,23 @@ local onFirstFloor = ____stage.onFirstFloor
31644
31652
  local ____table = require("src.functions.table")
31645
31653
  local clearTable = ____table.clearTable
31646
31654
  local iterateTableInOrder = ____table.iterateTableInOrder
31655
+ local ____constants = require("src.features.saveDataManager.constants")
31656
+ local SAVE_DATA_MANAGER_DEBUG = ____constants.SAVE_DATA_MANAGER_DEBUG
31657
+ local SAVE_DATA_MANAGER_FEATURE_NAME = ____constants.SAVE_DATA_MANAGER_FEATURE_NAME
31658
+ local SAVE_DATA_MANAGER_GLOWING_HOUR_GLASS_BACKUP_KEYS = ____constants.SAVE_DATA_MANAGER_GLOWING_HOUR_GLASS_BACKUP_KEYS
31647
31659
  local ____load = require("src.features.saveDataManager.load")
31648
31660
  local loadFromDisk = ____load.loadFromDisk
31649
31661
  local ____maps = require("src.features.saveDataManager.maps")
31650
31662
  local saveDataConditionalFuncMap = ____maps.saveDataConditionalFuncMap
31651
31663
  local saveDataDefaultsMap = ____maps.saveDataDefaultsMap
31664
+ local saveDataGlowingHourGlassMap = ____maps.saveDataGlowingHourGlassMap
31652
31665
  local saveDataMap = ____maps.saveDataMap
31666
+ local ____merge = require("src.features.saveDataManager.merge")
31667
+ local merge = ____merge.merge
31653
31668
  local ____save = require("src.features.saveDataManager.save")
31654
31669
  local saveToDisk = ____save.saveToDisk
31655
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
31656
- local SAVE_DATA_MANAGER_DEBUG = ____saveDataManagerConstants.SAVE_DATA_MANAGER_DEBUG
31657
- local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MANAGER_FEATURE_NAME
31658
31670
  function postUseItemGlowingHourGlass(self)
31671
+ restoreGlowingHourGlassDataOnNextRoom = true
31659
31672
  return nil
31660
31673
  end
31661
31674
  function postPlayerInit(self)
@@ -31692,6 +31705,63 @@ function postNewLevel(self)
31692
31705
  end
31693
31706
  function postNewRoomEarly(self)
31694
31707
  restoreDefaults(nil, SaveDataKey.ROOM)
31708
+ if restoreGlowingHourGlassDataOnNextRoom then
31709
+ restoreGlowingHourGlassDataOnNextRoom = false
31710
+ restoreGlowingHourGlassBackup(nil)
31711
+ else
31712
+ makeGlowingHourGlassBackup(nil)
31713
+ end
31714
+ end
31715
+ function makeGlowingHourGlassBackup(self)
31716
+ iterateTableInOrder(
31717
+ nil,
31718
+ saveDataMap,
31719
+ function(____, subscriberName, saveData)
31720
+ for ____, saveDataKey in ipairs(SAVE_DATA_MANAGER_GLOWING_HOUR_GLASS_BACKUP_KEYS) do
31721
+ do
31722
+ local childTable = saveData[saveDataKey]
31723
+ if childTable == nil then
31724
+ goto __continue18
31725
+ end
31726
+ local saveDataGlowingHourGlass = saveDataGlowingHourGlassMap[subscriberName]
31727
+ if saveDataGlowingHourGlass == nil then
31728
+ saveDataGlowingHourGlass = {}
31729
+ end
31730
+ local copiedChildTable = deepCopy(nil, childTable)
31731
+ saveDataGlowingHourGlass[saveDataKey] = copiedChildTable
31732
+ end
31733
+ ::__continue18::
31734
+ end
31735
+ end,
31736
+ SAVE_DATA_MANAGER_DEBUG
31737
+ )
31738
+ end
31739
+ function restoreGlowingHourGlassBackup(self)
31740
+ iterateTableInOrder(
31741
+ nil,
31742
+ saveDataMap,
31743
+ function(____, subscriberName, saveData)
31744
+ for ____, saveDataKey in ipairs(SAVE_DATA_MANAGER_GLOWING_HOUR_GLASS_BACKUP_KEYS) do
31745
+ do
31746
+ local childTable = saveData[saveDataKey]
31747
+ if childTable == nil then
31748
+ goto __continue24
31749
+ end
31750
+ local saveDataGlowingHourGlass = saveDataGlowingHourGlassMap[subscriberName]
31751
+ if saveDataGlowingHourGlass == nil then
31752
+ goto __continue24
31753
+ end
31754
+ local childTableBackup = saveDataGlowingHourGlass[saveDataKey]
31755
+ if childTableBackup == nil then
31756
+ goto __continue24
31757
+ end
31758
+ merge(nil, childTable, childTableBackup, subscriberName .. "__glowingHourGlass")
31759
+ end
31760
+ ::__continue24::
31761
+ end
31762
+ end,
31763
+ SAVE_DATA_MANAGER_DEBUG
31764
+ )
31695
31765
  end
31696
31766
  function restoreDefaultsAll(self)
31697
31767
  restoreDefaults(nil, SaveDataKey.RUN)
@@ -31738,6 +31808,7 @@ end
31738
31808
  RESETTABLE_SAVE_DATA_KEYS = __TS__New(Set, {SaveDataKey.RUN, SaveDataKey.LEVEL, SaveDataKey.ROOM})
31739
31809
  mod = nil
31740
31810
  loadedDataOnThisRun = false
31811
+ restoreGlowingHourGlassDataOnNextRoom = false
31741
31812
  function ____exports.saveDataManagerInit(self, incomingMod)
31742
31813
  mod = incomingMod
31743
31814
  mod:AddCallback(ModCallback.POST_USE_ITEM, postUseItemGlowingHourGlass, CollectibleType.GLOWING_HOUR_GLASS)
@@ -31773,6 +31844,8 @@ local ____deepCopy = require("src.functions.deepCopy")
31773
31844
  local deepCopy = ____deepCopy.deepCopy
31774
31845
  local ____types = require("src.functions.types")
31775
31846
  local isString = ____types.isString
31847
+ local ____constants = require("src.features.saveDataManager.constants")
31848
+ local SAVE_DATA_MANAGER_FEATURE_NAME = ____constants.SAVE_DATA_MANAGER_FEATURE_NAME
31776
31849
  local ____main = require("src.features.saveDataManager.main")
31777
31850
  local forceSaveDataManagerLoad = ____main.forceSaveDataManagerLoad
31778
31851
  local forceSaveDataManagerSave = ____main.forceSaveDataManagerSave
@@ -31781,8 +31854,6 @@ local ____maps = require("src.features.saveDataManager.maps")
31781
31854
  local saveDataConditionalFuncMap = ____maps.saveDataConditionalFuncMap
31782
31855
  local saveDataDefaultsMap = ____maps.saveDataDefaultsMap
31783
31856
  local saveDataMap = ____maps.saveDataMap
31784
- local ____saveDataManagerConstants = require("src.features.saveDataManager.saveDataManagerConstants")
31785
- local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MANAGER_FEATURE_NAME
31786
31857
  --- This is the entry point to the save data manager, a system which provides two major features:
31787
31858
  --
31788
31859
  -- 1. automatic resetting of variables on a new run, on a new level, or on a new room (as desired)
@@ -31854,9 +31925,14 @@ local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MA
31854
31925
  -- data manager cannot do this on its own because it cannot know when your mod features are finished
31855
31926
  -- initializing.)
31856
31927
  --
31857
- -- Finally, some features may have variables that need to be automatically reset per run/level, but
31858
- -- not saved to disk on game exit. (For example, if they contain functions or other non-serializable
31859
- -- data.) For these cases, set the second argument to `() => false`.
31928
+ -- Some features may have variables that need to be automatically reset per run/level, but not saved
31929
+ -- to disk on game exit. (For example, if they contain functions or other non-serializable data.)
31930
+ -- For these cases, set the second argument to `() => false`.
31931
+ --
31932
+ -- Note that when the player uses Glowing Hour Glass, the save data manager will automatically
31933
+ -- restore any variables on a "run" or "level" object with a backup that was created when the room
31934
+ -- was entered. Thus, you should not have to explicitly program support for Glowing Hour Glass into
31935
+ -- your mod features that use the save data manager.
31860
31936
  --
31861
31937
  -- @param key The name of the file or feature that is submitting data to be managed by the save data
31862
31938
  -- manager. The save data manager will throw an error if the key is already registered.
@@ -39625,7 +39701,7 @@ return ____exports
39625
39701
  local ____exports = {}
39626
39702
  return ____exports
39627
39703
  end,
39628
- ["src.features.customStage.customStageConstants"] = function(...)
39704
+ ["src.features.customStage.constants"] = function(...)
39629
39705
  local ____exports = {}
39630
39706
  ____exports.CUSTOM_STAGE_FEATURE_NAME = "customStage"
39631
39707
  ____exports.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = "gfx/isaacscript-custom-stage"
@@ -39671,8 +39747,8 @@ local trimPrefix = ____string.trimPrefix
39671
39747
  local ____utils = require("src.functions.utils")
39672
39748
  local erange = ____utils.erange
39673
39749
  local irange = ____utils.irange
39674
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
39675
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
39750
+ local ____constants = require("src.features.customStage.constants")
39751
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
39676
39752
  function getBackdropPNGPath(self, customStage, backdropKind, rng)
39677
39753
  local backdrop = customStage.backdropPNGPaths == nil and DEFAULT_BACKDROP or customStage.backdropPNGPaths
39678
39754
  local pathArray = backdrop[backdropKind]
@@ -40164,7 +40240,7 @@ return ____exports
40164
40240
  local ____exports = {}
40165
40241
  return ____exports
40166
40242
  end,
40167
- ["src.features.customTrapdoor.customTrapdoorConstants"] = function(...)
40243
+ ["src.features.customTrapdoor.constants"] = function(...)
40168
40244
  local ____lualib = require("lualib_bundle")
40169
40245
  local Set = ____lualib.Set
40170
40246
  local __TS__New = ____lualib.__TS__New
@@ -40247,10 +40323,10 @@ local ____positionVelocity = require("src.functions.positionVelocity")
40247
40323
  local anyPlayerCloserThan = ____positionVelocity.anyPlayerCloserThan
40248
40324
  local ____roomClearFrame = require("src.features.roomClearFrame")
40249
40325
  local getRoomClearGameFrame = ____roomClearFrame.getRoomClearGameFrame
40250
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
40251
- local TRAPDOOR_BOSS_REACTION_FRAMES = ____customTrapdoorConstants.TRAPDOOR_BOSS_REACTION_FRAMES
40252
- local TRAPDOOR_OPEN_DISTANCE = ____customTrapdoorConstants.TRAPDOOR_OPEN_DISTANCE
40253
- local TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS = ____customTrapdoorConstants.TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS
40326
+ local ____constants = require("src.features.customTrapdoor.constants")
40327
+ local TRAPDOOR_BOSS_REACTION_FRAMES = ____constants.TRAPDOOR_BOSS_REACTION_FRAMES
40328
+ local TRAPDOOR_OPEN_DISTANCE = ____constants.TRAPDOOR_OPEN_DISTANCE
40329
+ local TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS = ____constants.TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS
40254
40330
  function shouldTrapdoorOpen(self, gridEntity, firstSpawn)
40255
40331
  local room = game:GetRoom()
40256
40332
  local roomClear = room:IsClear()
@@ -40350,8 +40426,8 @@ local ____vector = require("src.functions.vector")
40350
40426
  local isVector = ____vector.isVector
40351
40427
  local ____customGridEntity = require("src.features.customGridEntity")
40352
40428
  local spawnCustomGridEntity = ____customGridEntity.spawnCustomGridEntity
40353
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
40354
- local GridEntityTypeCustom = ____customTrapdoorConstants.GridEntityTypeCustom
40429
+ local ____constants = require("src.features.customTrapdoor.constants")
40430
+ local GridEntityTypeCustom = ____constants.GridEntityTypeCustom
40355
40431
  local ____openClose = require("src.features.customTrapdoor.openClose")
40356
40432
  local shouldTrapdoorSpawnOpen = ____openClose.shouldTrapdoorSpawnOpen
40357
40433
  local ____v = require("src.features.customTrapdoor.v")
@@ -40394,8 +40470,8 @@ local errorIfFeaturesNotInitialized = ____featuresInitialized.errorIfFeaturesNot
40394
40470
  local ____nextStage = require("src.functions.nextStage")
40395
40471
  local getNextStage = ____nextStage.getNextStage
40396
40472
  local getNextStageType = ____nextStage.getNextStageType
40397
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
40398
- local CUSTOM_TRAPDOOR_FEATURE_NAME = ____customTrapdoorConstants.CUSTOM_TRAPDOOR_FEATURE_NAME
40473
+ local ____constants = require("src.features.customTrapdoor.constants")
40474
+ local CUSTOM_TRAPDOOR_FEATURE_NAME = ____constants.CUSTOM_TRAPDOOR_FEATURE_NAME
40399
40475
  local ____spawn = require("src.features.customTrapdoor.spawn")
40400
40476
  local spawnCustomTrapdoorToDestination = ____spawn.spawnCustomTrapdoorToDestination
40401
40477
  --- Helper function to spawn a trapdoor grid entity that will take a player to a custom stage. If you
@@ -40570,8 +40646,8 @@ local ____lualib = require("lualib_bundle")
40570
40646
  local Map = ____lualib.Map
40571
40647
  local __TS__New = ____lualib.__TS__New
40572
40648
  local ____exports = {}
40573
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
40574
- local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
40649
+ local ____constants = require("src.features.customStage.constants")
40650
+ local UIStreakAnimation = ____constants.UIStreakAnimation
40575
40651
  local v = {
40576
40652
  run = {
40577
40653
  currentCustomStage = nil,
@@ -41087,8 +41163,8 @@ local ____entitiesSpecific = require("src.functions.entitiesSpecific")
41087
41163
  local spawnEffectWithSeed = ____entitiesSpecific.spawnEffectWithSeed
41088
41164
  local ____string = require("src.functions.string")
41089
41165
  local removeCharactersBefore = ____string.removeCharactersBefore
41090
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
41091
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
41166
+ local ____constants = require("src.features.customStage.constants")
41167
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
41092
41168
  local ____v = require("src.features.customStage.v")
41093
41169
  local v = ____v.default
41094
41170
  --- Normally, we would make a custom entity to represent a shadow effect, but we don't want to
@@ -41288,9 +41364,9 @@ local getEnumValues = ____enums.getEnumValues
41288
41364
  local ____ui = require("src.functions.ui")
41289
41365
  local getScreenBottomCenterPos = ____ui.getScreenBottomCenterPos
41290
41366
  local getScreenTopCenterPos = ____ui.getScreenTopCenterPos
41291
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
41292
- local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
41293
- local UI_STREAK_ANIMATION_END_FRAMES = ____customStageConstants.UI_STREAK_ANIMATION_END_FRAMES
41367
+ local ____constants = require("src.features.customStage.constants")
41368
+ local UIStreakAnimation = ____constants.UIStreakAnimation
41369
+ local UI_STREAK_ANIMATION_END_FRAMES = ____constants.UI_STREAK_ANIMATION_END_FRAMES
41294
41370
  local ____v = require("src.features.customStage.v")
41295
41371
  local v = ____v.default
41296
41372
  function checkEndTopStreakText(self)
@@ -43522,9 +43598,9 @@ local pause = ____pause.pause
43522
43598
  local unpause = ____pause.unpause
43523
43599
  local ____runInNFrames = require("src.features.runInNFrames")
43524
43600
  local runNextGameFrame = ____runInNFrames.runNextGameFrame
43525
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
43526
- local CUSTOM_STAGE_FEATURE_NAME = ____customStageConstants.CUSTOM_STAGE_FEATURE_NAME
43527
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
43601
+ local ____constants = require("src.features.customStage.constants")
43602
+ local CUSTOM_STAGE_FEATURE_NAME = ____constants.CUSTOM_STAGE_FEATURE_NAME
43603
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
43528
43604
  local ____exports = require("src.features.customStage.exports")
43529
43605
  local CUSTOM_FLOOR_STAGE = ____exports.CUSTOM_FLOOR_STAGE
43530
43606
  local CUSTOM_FLOOR_STAGE_TYPE = ____exports.CUSTOM_FLOOR_STAGE_TYPE
@@ -43764,8 +43840,8 @@ local ____exports = require("src.features.saveDataManager.exports")
43764
43840
  local saveDataManager = ____exports.saveDataManager
43765
43841
  local ____backdrop = require("src.features.customStage.backdrop")
43766
43842
  local setCustomStageBackdrop = ____backdrop.setCustomStageBackdrop
43767
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
43768
- local CUSTOM_STAGE_FEATURE_NAME = ____customStageConstants.CUSTOM_STAGE_FEATURE_NAME
43843
+ local ____constants = require("src.features.customStage.constants")
43844
+ local CUSTOM_STAGE_FEATURE_NAME = ____constants.CUSTOM_STAGE_FEATURE_NAME
43769
43845
  local ____customStageGridEntities = require("src.features.customStage.customStageGridEntities")
43770
43846
  local convertVanillaTrapdoors = ____customStageGridEntities.convertVanillaTrapdoors
43771
43847
  local removeUrnRewards = ____customStageGridEntities.removeUrnRewards
@@ -44318,12 +44394,12 @@ local isPlayerUsingPony = ____ponyDetection.isPlayerUsingPony
44318
44394
  local ____runInNFrames = require("src.features.runInNFrames")
44319
44395
  local runInNGameFrames = ____runInNFrames.runInNGameFrames
44320
44396
  local runNextRenderFrame = ____runInNFrames.runNextRenderFrame
44321
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
44322
- local ANIMATIONS_THAT_PREVENT_STAGE_TRAVEL = ____customTrapdoorConstants.ANIMATIONS_THAT_PREVENT_STAGE_TRAVEL
44323
- local CUSTOM_TRAPDOOR_FEATURE_NAME = ____customTrapdoorConstants.CUSTOM_TRAPDOOR_FEATURE_NAME
44324
- local OTHER_PLAYER_TRAPDOOR_JUMP_DELAY_GAME_FRAMES = ____customTrapdoorConstants.OTHER_PLAYER_TRAPDOOR_JUMP_DELAY_GAME_FRAMES
44325
- local OTHER_PLAYER_TRAPDOOR_JUMP_DURATION_GAME_FRAMES = ____customTrapdoorConstants.OTHER_PLAYER_TRAPDOOR_JUMP_DURATION_GAME_FRAMES
44326
- local TRAPDOOR_TOUCH_DISTANCE = ____customTrapdoorConstants.TRAPDOOR_TOUCH_DISTANCE
44397
+ local ____constants = require("src.features.customTrapdoor.constants")
44398
+ local ANIMATIONS_THAT_PREVENT_STAGE_TRAVEL = ____constants.ANIMATIONS_THAT_PREVENT_STAGE_TRAVEL
44399
+ local CUSTOM_TRAPDOOR_FEATURE_NAME = ____constants.CUSTOM_TRAPDOOR_FEATURE_NAME
44400
+ local OTHER_PLAYER_TRAPDOOR_JUMP_DELAY_GAME_FRAMES = ____constants.OTHER_PLAYER_TRAPDOOR_JUMP_DELAY_GAME_FRAMES
44401
+ local OTHER_PLAYER_TRAPDOOR_JUMP_DURATION_GAME_FRAMES = ____constants.OTHER_PLAYER_TRAPDOOR_JUMP_DURATION_GAME_FRAMES
44402
+ local TRAPDOOR_TOUCH_DISTANCE = ____constants.TRAPDOOR_TOUCH_DISTANCE
44327
44403
  local ____v = require("src.features.customTrapdoor.v")
44328
44404
  local v = ____v.default
44329
44405
  function canPlayerInteractWithTrapdoor(self, player)
@@ -44491,10 +44567,10 @@ local ____exports = require("src.features.saveDataManager.exports")
44491
44567
  local saveDataManager = ____exports.saveDataManager
44492
44568
  local ____blackSprite = require("src.features.customTrapdoor.blackSprite")
44493
44569
  local drawBlackSprite = ____blackSprite.drawBlackSprite
44494
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
44495
- local CUSTOM_TRAPDOOR_FEATURE_NAME = ____customTrapdoorConstants.CUSTOM_TRAPDOOR_FEATURE_NAME
44496
- local GridEntityTypeCustom = ____customTrapdoorConstants.GridEntityTypeCustom
44497
- local PIXELATION_TO_BLACK_FRAMES = ____customTrapdoorConstants.PIXELATION_TO_BLACK_FRAMES
44570
+ local ____constants = require("src.features.customTrapdoor.constants")
44571
+ local CUSTOM_TRAPDOOR_FEATURE_NAME = ____constants.CUSTOM_TRAPDOOR_FEATURE_NAME
44572
+ local GridEntityTypeCustom = ____constants.GridEntityTypeCustom
44573
+ local PIXELATION_TO_BLACK_FRAMES = ____constants.PIXELATION_TO_BLACK_FRAMES
44498
44574
  local ____openClose = require("src.features.customTrapdoor.openClose")
44499
44575
  local checkCustomTrapdoorOpenClose = ____openClose.checkCustomTrapdoorOpenClose
44500
44576
  local ____touched = require("src.features.customTrapdoor.touched")
@@ -46959,7 +47035,7 @@ return ____exports
46959
47035
  ["package"] = function(...)
46960
47036
  return {
46961
47037
  name = "isaacscript-common",
46962
- version = "11.2.4",
47038
+ version = "12.0.0",
46963
47039
  description = "Helper functions and features for IsaacScript mods.",
46964
47040
  keywords = {"isaac", "rebirth", "afterbirth", "repentance"},
46965
47041
  homepage = "https://isaacscript.github.io/",
package/dist/package.lua CHANGED
@@ -1,6 +1,6 @@
1
1
  return {
2
2
  name = "isaacscript-common",
3
- version = "11.2.4",
3
+ version = "12.0.0",
4
4
  description = "Helper functions and features for IsaacScript mods.",
5
5
  keywords = {"isaac", "rebirth", "afterbirth", "repentance"},
6
6
  homepage = "https://isaacscript.github.io/",
@@ -27,8 +27,8 @@ local trimPrefix = ____string.trimPrefix
27
27
  local ____utils = require("src.functions.utils")
28
28
  local erange = ____utils.erange
29
29
  local irange = ____utils.irange
30
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
31
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
30
+ local ____constants = require("src.features.customStage.constants")
31
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
32
32
  function getBackdropPNGPath(self, customStage, backdropKind, rng)
33
33
  local backdrop = customStage.backdropPNGPaths == nil and DEFAULT_BACKDROP or customStage.backdropPNGPaths
34
34
  local pathArray = backdrop[backdropKind]
@@ -11,4 +11,4 @@ export declare enum UIStreakAnimation {
11
11
  export declare const UI_STREAK_ANIMATION_END_FRAMES: {
12
12
  readonly [key in UIStreakAnimation]: int;
13
13
  };
14
- //# sourceMappingURL=customStageConstants.d.ts.map
14
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/features/customStage/constants.ts"],"names":[],"mappings":";AAAA,eAAO,MAAM,yBAAyB,gBAAgB,CAAC;AAEvD,eAAO,MAAM,iCAAiC,iCAAiC,CAAC;AAEhF,uCAAuC;AACvC,oBAAY,iBAAiB;IAC3B,IAAI,IAAA;IACJ,IAAI,IAAA;IACJ,SAAS,IAAA;CACV;AAED,uCAAuC;AACvC,eAAO,MAAM,8BAA8B,EAAE;IAC3C,QAAQ,EAAE,GAAG,IAAI,iBAAiB,GAAG,GAAG;CAKhC,CAAC"}
@@ -19,8 +19,8 @@ local ____exports = require("src.features.saveDataManager.exports")
19
19
  local saveDataManager = ____exports.saveDataManager
20
20
  local ____backdrop = require("src.features.customStage.backdrop")
21
21
  local setCustomStageBackdrop = ____backdrop.setCustomStageBackdrop
22
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
23
- local CUSTOM_STAGE_FEATURE_NAME = ____customStageConstants.CUSTOM_STAGE_FEATURE_NAME
22
+ local ____constants = require("src.features.customStage.constants")
23
+ local CUSTOM_STAGE_FEATURE_NAME = ____constants.CUSTOM_STAGE_FEATURE_NAME
24
24
  local ____customStageGridEntities = require("src.features.customStage.customStageGridEntities")
25
25
  local convertVanillaTrapdoors = ____customStageGridEntities.convertVanillaTrapdoors
26
26
  local removeUrnRewards = ____customStageGridEntities.removeUrnRewards
@@ -10,8 +10,8 @@ local ____entitiesSpecific = require("src.functions.entitiesSpecific")
10
10
  local spawnEffectWithSeed = ____entitiesSpecific.spawnEffectWithSeed
11
11
  local ____string = require("src.functions.string")
12
12
  local removeCharactersBefore = ____string.removeCharactersBefore
13
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
14
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
13
+ local ____constants = require("src.features.customStage.constants")
14
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
15
15
  local ____v = require("src.features.customStage.v")
16
16
  local v = ____v.default
17
17
  --- Normally, we would make a custom entity to represent a shadow effect, but we don't want to
@@ -1 +1 @@
1
- {"version":3,"file":"streakText.d.ts","sourceRoot":"","sources":["../../../../src/features/customStage/streakText.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAuEnE,wBAAgB,oBAAoB,IAAI,IAAI,CAS3C;AA0FD,wBAAgB,yBAAyB,CACvC,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,MAAM,GACjB,IAAI,CAYN;AA0ED,wBAAgB,kBAAkB,IAAI,IAAI,CAWzC"}
1
+ {"version":3,"file":"streakText.d.ts","sourceRoot":"","sources":["../../../../src/features/customStage/streakText.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AAoEnE,wBAAgB,oBAAoB,IAAI,IAAI,CAS3C;AA0FD,wBAAgB,yBAAyB,CACvC,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,MAAM,GACjB,IAAI,CAYN;AA0ED,wBAAgB,kBAAkB,IAAI,IAAI,CAWzC"}
@@ -16,9 +16,9 @@ local getEnumValues = ____enums.getEnumValues
16
16
  local ____ui = require("src.functions.ui")
17
17
  local getScreenBottomCenterPos = ____ui.getScreenBottomCenterPos
18
18
  local getScreenTopCenterPos = ____ui.getScreenTopCenterPos
19
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
20
- local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
21
- local UI_STREAK_ANIMATION_END_FRAMES = ____customStageConstants.UI_STREAK_ANIMATION_END_FRAMES
19
+ local ____constants = require("src.features.customStage.constants")
20
+ local UIStreakAnimation = ____constants.UIStreakAnimation
21
+ local UI_STREAK_ANIMATION_END_FRAMES = ____constants.UI_STREAK_ANIMATION_END_FRAMES
22
22
  local ____v = require("src.features.customStage.v")
23
23
  local v = ____v.default
24
24
  function checkEndTopStreakText(self)
@@ -1,6 +1,6 @@
1
1
  import { ControllerIndex } from "isaac-typescript-definitions";
2
2
  import { CustomStage } from "../../interfaces/private/CustomStage";
3
- import { UIStreakAnimation } from "./customStageConstants";
3
+ import { UIStreakAnimation } from "./constants";
4
4
  declare const v: {
5
5
  run: {
6
6
  currentCustomStage: CustomStage | null;
@@ -1 +1 @@
1
- {"version":3,"file":"v.d.ts","sourceRoot":"","sources":["../../../../src/features/customStage/v.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,QAAA,MAAM,CAAC;;;QAIH,iDAAiD;;;QAKjD,oFAAoF;;;;;;;;;;;;;;;;;CAqBvF,CAAC;AACF,eAAe,CAAC,CAAC;AAEjB,oCAAoC;AACpC,eAAO,MAAM,eAAe,0BAAiC,CAAC;AAE9D,+BAA+B;AAC/B,eAAO,MAAM,yBAAyB,mCAAuC,CAAC"}
1
+ {"version":3,"file":"v.d.ts","sourceRoot":"","sources":["../../../../src/features/customStage/v.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAEhD,QAAA,MAAM,CAAC;;;QAIH,iDAAiD;;;QAKjD,oFAAoF;;;;;;;;;;;;;;;;;CAqBvF,CAAC;AACF,eAAe,CAAC,CAAC;AAEjB,oCAAoC;AACpC,eAAO,MAAM,eAAe,0BAAiC,CAAC;AAE9D,+BAA+B;AAC/B,eAAO,MAAM,yBAAyB,mCAAuC,CAAC"}
@@ -2,8 +2,8 @@ local ____lualib = require("lualib_bundle")
2
2
  local Map = ____lualib.Map
3
3
  local __TS__New = ____lualib.__TS__New
4
4
  local ____exports = {}
5
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
6
- local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
5
+ local ____constants = require("src.features.customStage.constants")
6
+ local UIStreakAnimation = ____constants.UIStreakAnimation
7
7
  local v = {
8
8
  run = {
9
9
  currentCustomStage = nil,
@@ -42,9 +42,9 @@ local pause = ____pause.pause
42
42
  local unpause = ____pause.unpause
43
43
  local ____runInNFrames = require("src.features.runInNFrames")
44
44
  local runNextGameFrame = ____runInNFrames.runNextGameFrame
45
- local ____customStageConstants = require("src.features.customStage.customStageConstants")
46
- local CUSTOM_STAGE_FEATURE_NAME = ____customStageConstants.CUSTOM_STAGE_FEATURE_NAME
47
- local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____customStageConstants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
45
+ local ____constants = require("src.features.customStage.constants")
46
+ local CUSTOM_STAGE_FEATURE_NAME = ____constants.CUSTOM_STAGE_FEATURE_NAME
47
+ local ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH = ____constants.ISAACSCRIPT_CUSTOM_STAGE_GFX_PATH
48
48
  local ____exports = require("src.features.customStage.exports")
49
49
  local CUSTOM_FLOOR_STAGE = ____exports.CUSTOM_FLOOR_STAGE
50
50
  local CUSTOM_FLOOR_STAGE_TYPE = ____exports.CUSTOM_FLOOR_STAGE_TYPE
@@ -16,4 +16,4 @@ export declare const ANIMATIONS_THAT_PREVENT_STAGE_TRAVEL: ReadonlySet<string>;
16
16
  export declare const PIXELATION_TO_BLACK_FRAMES = 52;
17
17
  export declare const OTHER_PLAYER_TRAPDOOR_JUMP_DELAY_GAME_FRAMES = 6;
18
18
  export declare const OTHER_PLAYER_TRAPDOOR_JUMP_DURATION_GAME_FRAMES = 5;
19
- //# sourceMappingURL=customTrapdoorConstants.d.ts.map
19
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/features/customTrapdoor/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9D,eAAO,MAAM,4BAA4B,mBAAmB,CAAC;AAE7D,eAAO,MAAM,oBAAoB;IAC/B;;;OAGG;;CAEK,CAAC;AAEX,2FAA2F;AAC3F,eAAO,MAAM,sBAAsB,KAAK,CAAC;AAEzC,eAAO,MAAM,iCAAiC,QAA+B,CAAC;AAC9E,eAAO,MAAM,6BAA6B,KAAK,CAAC;AAEhD,eAAO,MAAM,uBAAuB,OAAO,CAAC;AAE5C,eAAO,MAAM,oCAAoC,EAAE,WAAW,CAAC,MAAM,CAClC,CAAC;AAEpC,eAAO,MAAM,0BAA0B,KAAK,CAAC;AAE7C,eAAO,MAAM,4CAA4C,IAAI,CAAC;AAC9D,eAAO,MAAM,+CAA+C,IAAI,CAAC"}
@@ -4,8 +4,8 @@ local errorIfFeaturesNotInitialized = ____featuresInitialized.errorIfFeaturesNot
4
4
  local ____nextStage = require("src.functions.nextStage")
5
5
  local getNextStage = ____nextStage.getNextStage
6
6
  local getNextStageType = ____nextStage.getNextStageType
7
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
8
- local CUSTOM_TRAPDOOR_FEATURE_NAME = ____customTrapdoorConstants.CUSTOM_TRAPDOOR_FEATURE_NAME
7
+ local ____constants = require("src.features.customTrapdoor.constants")
8
+ local CUSTOM_TRAPDOOR_FEATURE_NAME = ____constants.CUSTOM_TRAPDOOR_FEATURE_NAME
9
9
  local ____spawn = require("src.features.customTrapdoor.spawn")
10
10
  local spawnCustomTrapdoorToDestination = ____spawn.spawnCustomTrapdoorToDestination
11
11
  --- Helper function to spawn a trapdoor grid entity that will take a player to a custom stage. If you
@@ -41,10 +41,10 @@ local ____exports = require("src.features.saveDataManager.exports")
41
41
  local saveDataManager = ____exports.saveDataManager
42
42
  local ____blackSprite = require("src.features.customTrapdoor.blackSprite")
43
43
  local drawBlackSprite = ____blackSprite.drawBlackSprite
44
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
45
- local CUSTOM_TRAPDOOR_FEATURE_NAME = ____customTrapdoorConstants.CUSTOM_TRAPDOOR_FEATURE_NAME
46
- local GridEntityTypeCustom = ____customTrapdoorConstants.GridEntityTypeCustom
47
- local PIXELATION_TO_BLACK_FRAMES = ____customTrapdoorConstants.PIXELATION_TO_BLACK_FRAMES
44
+ local ____constants = require("src.features.customTrapdoor.constants")
45
+ local CUSTOM_TRAPDOOR_FEATURE_NAME = ____constants.CUSTOM_TRAPDOOR_FEATURE_NAME
46
+ local GridEntityTypeCustom = ____constants.GridEntityTypeCustom
47
+ local PIXELATION_TO_BLACK_FRAMES = ____constants.PIXELATION_TO_BLACK_FRAMES
48
48
  local ____openClose = require("src.features.customTrapdoor.openClose")
49
49
  local checkCustomTrapdoorOpenClose = ____openClose.checkCustomTrapdoorOpenClose
50
50
  local ____touched = require("src.features.customTrapdoor.touched")
@@ -10,10 +10,10 @@ local ____positionVelocity = require("src.functions.positionVelocity")
10
10
  local anyPlayerCloserThan = ____positionVelocity.anyPlayerCloserThan
11
11
  local ____roomClearFrame = require("src.features.roomClearFrame")
12
12
  local getRoomClearGameFrame = ____roomClearFrame.getRoomClearGameFrame
13
- local ____customTrapdoorConstants = require("src.features.customTrapdoor.customTrapdoorConstants")
14
- local TRAPDOOR_BOSS_REACTION_FRAMES = ____customTrapdoorConstants.TRAPDOOR_BOSS_REACTION_FRAMES
15
- local TRAPDOOR_OPEN_DISTANCE = ____customTrapdoorConstants.TRAPDOOR_OPEN_DISTANCE
16
- local TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS = ____customTrapdoorConstants.TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS
13
+ local ____constants = require("src.features.customTrapdoor.constants")
14
+ local TRAPDOOR_BOSS_REACTION_FRAMES = ____constants.TRAPDOOR_BOSS_REACTION_FRAMES
15
+ local TRAPDOOR_OPEN_DISTANCE = ____constants.TRAPDOOR_OPEN_DISTANCE
16
+ local TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS = ____constants.TRAPDOOR_OPEN_DISTANCE_AFTER_BOSS
17
17
  function shouldTrapdoorOpen(self, gridEntity, firstSpawn)
18
18
  local room = game:GetRoom()
19
19
  local roomClear = room:IsClear()