isaacscript-common 6.20.0 → 6.21.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 (106) hide show
  1. package/dist/constants.d.ts +5 -0
  2. package/dist/constants.d.ts.map +1 -1
  3. package/dist/constants.lua +4 -0
  4. package/dist/constantsFirstLast.d.ts +2 -2
  5. package/dist/constantsFirstLast.lua +2 -2
  6. package/dist/enums/RockAltType.d.ts +12 -1
  7. package/dist/enums/RockAltType.d.ts.map +1 -1
  8. package/dist/enums/RockAltType.lua +4 -2
  9. package/dist/features/customStage/backdrop.d.ts.map +1 -1
  10. package/dist/features/customStage/backdrop.lua +3 -2
  11. package/dist/features/customStage/customStageConstants.d.ts +11 -0
  12. package/dist/features/customStage/customStageConstants.d.ts.map +1 -1
  13. package/dist/features/customStage/customStageConstants.lua +10 -0
  14. package/dist/features/customStage/customStageGridEntities.d.ts +1 -0
  15. package/dist/features/customStage/customStageGridEntities.d.ts.map +1 -1
  16. package/dist/features/customStage/customStageGridEntities.lua +58 -23
  17. package/dist/features/customStage/exports.d.ts +6 -2
  18. package/dist/features/customStage/exports.d.ts.map +1 -1
  19. package/dist/features/customStage/exports.lua +51 -45
  20. package/dist/features/customStage/init.d.ts.map +1 -1
  21. package/dist/features/customStage/init.lua +7 -12
  22. package/dist/features/customStage/shadows.d.ts.map +1 -1
  23. package/dist/features/customStage/shadows.lua +2 -1
  24. package/dist/features/customStage/streakText.d.ts +0 -7
  25. package/dist/features/customStage/streakText.d.ts.map +1 -1
  26. package/dist/features/customStage/streakText.lua +51 -84
  27. package/dist/features/customStage/v.d.ts +13 -0
  28. package/dist/features/customStage/v.d.ts.map +1 -1
  29. package/dist/features/customStage/v.lua +6 -1
  30. package/dist/features/customTrapdoor/blackSprite.d.ts.map +1 -1
  31. package/dist/features/customTrapdoor/blackSprite.lua +1 -0
  32. package/dist/features/customTrapdoor/exports.d.ts +7 -6
  33. package/dist/features/customTrapdoor/exports.d.ts.map +1 -1
  34. package/dist/features/customTrapdoor/exports.lua +6 -5
  35. package/dist/features/customTrapdoor/init.d.ts.map +1 -1
  36. package/dist/features/customTrapdoor/init.lua +11 -6
  37. package/dist/features/customTrapdoor/touched.lua +0 -1
  38. package/dist/features/customTrapdoor/v.d.ts +1 -1
  39. package/dist/features/extraConsoleCommands/commandsSubroutines.d.ts.map +1 -1
  40. package/dist/features/extraConsoleCommands/commandsSubroutines.lua +3 -3
  41. package/dist/features/saveDataManager/exports.d.ts +3 -0
  42. package/dist/features/saveDataManager/exports.d.ts.map +1 -1
  43. package/dist/features/saveDataManager/exports.lua +3 -0
  44. package/dist/functions/collectibleSet.d.ts +1 -1
  45. package/dist/functions/collectibleSet.lua +1 -1
  46. package/dist/functions/doors.d.ts +10 -0
  47. package/dist/functions/doors.d.ts.map +1 -1
  48. package/dist/functions/doors.lua +6 -0
  49. package/dist/functions/levelGrid.d.ts +5 -2
  50. package/dist/functions/levelGrid.d.ts.map +1 -1
  51. package/dist/functions/levelGrid.lua +29 -6
  52. package/dist/functions/log.d.ts +1 -15
  53. package/dist/functions/log.d.ts.map +1 -1
  54. package/dist/functions/log.lua +3 -218
  55. package/dist/functions/logEntities.d.ts +16 -0
  56. package/dist/functions/logEntities.d.ts.map +1 -0
  57. package/dist/functions/logEntities.lua +220 -0
  58. package/dist/functions/rockAlt.d.ts +6 -5
  59. package/dist/functions/rockAlt.d.ts.map +1 -1
  60. package/dist/functions/rockAlt.lua +147 -18
  61. package/dist/functions/roomData.d.ts +2 -2
  62. package/dist/functions/roomData.d.ts.map +1 -1
  63. package/dist/functions/roomData.lua +2 -2
  64. package/dist/functions/roomTransition.d.ts +26 -0
  65. package/dist/functions/roomTransition.d.ts.map +1 -0
  66. package/dist/functions/roomTransition.lua +75 -0
  67. package/dist/functions/rooms.d.ts +39 -35
  68. package/dist/functions/rooms.d.ts.map +1 -1
  69. package/dist/functions/rooms.lua +97 -99
  70. package/dist/index.d.ts +1 -0
  71. package/dist/index.d.ts.map +1 -1
  72. package/dist/index.lua +8 -0
  73. package/dist/interfaces/private/CustomTrapdoorDescription.d.ts +1 -1
  74. package/dist/interfaces/private/CustomTrapdoorDescription.d.ts.map +1 -1
  75. package/dist/objects/backdropTypeToRockAltType.lua +3 -3
  76. package/package.json +2 -2
  77. package/src/constants.ts +8 -0
  78. package/src/constantsFirstLast.ts +2 -2
  79. package/src/enums/RockAltType.ts +14 -1
  80. package/src/features/customStage/backdrop.ts +2 -1
  81. package/src/features/customStage/customStageConstants.ts +16 -0
  82. package/src/features/customStage/customStageGridEntities.ts +47 -0
  83. package/src/features/customStage/exports.ts +56 -40
  84. package/src/features/customStage/init.ts +7 -18
  85. package/src/features/customStage/shadows.ts +2 -1
  86. package/src/features/customStage/streakText.ts +58 -95
  87. package/src/features/customStage/v.ts +17 -0
  88. package/src/features/customTrapdoor/blackSprite.ts +1 -0
  89. package/src/features/customTrapdoor/exports.ts +9 -6
  90. package/src/features/customTrapdoor/init.ts +16 -5
  91. package/src/features/customTrapdoor/touched.ts +0 -2
  92. package/src/features/customTrapdoor/v.ts +1 -1
  93. package/src/features/extraConsoleCommands/commandsSubroutines.ts +4 -1
  94. package/src/features/saveDataManager/exports.ts +3 -0
  95. package/src/functions/collectibleSet.ts +1 -1
  96. package/src/functions/doors.ts +10 -0
  97. package/src/functions/levelGrid.ts +54 -10
  98. package/src/functions/log.ts +1 -279
  99. package/src/functions/logEntities.ts +276 -0
  100. package/src/functions/rockAlt.ts +147 -19
  101. package/src/functions/roomData.ts +3 -3
  102. package/src/functions/roomTransition.ts +78 -0
  103. package/src/functions/rooms.ts +107 -107
  104. package/src/index.ts +1 -0
  105. package/src/interfaces/private/CustomTrapdoorDescription.ts +3 -1
  106. package/src/objects/backdropTypeToRockAltType.ts +3 -3
@@ -3,7 +3,7 @@ local Map = ____lualib.Map
3
3
  local __TS__ObjectAssign = ____lualib.__TS__ObjectAssign
4
4
  local __TS__New = ____lualib.__TS__New
5
5
  local ____exports = {}
6
- local initRoomTypeMaps, getRoomTypeMap, postRender, postCurseEval, postGameStarted, getShaderParams, postGridEntityBrokenRockAlt, postGridEntityBrokenInit, postNewRoomReordered
6
+ local initRoomTypeMaps, getRoomTypeMap, postRender, postCurseEval, getShaderParams, postGridEntityBrokenRockAlt, postGridEntityInit, postNewRoomReordered
7
7
  local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
8
8
  local GridEntityType = ____isaac_2Dtypescript_2Ddefinitions.GridEntityType
9
9
  local LevelCurse = ____isaac_2Dtypescript_2Ddefinitions.LevelCurse
@@ -20,6 +20,7 @@ local saveDataManager = ____exports.saveDataManager
20
20
  local ____backdrop = require("features.customStage.backdrop")
21
21
  local setBackdrop = ____backdrop.setBackdrop
22
22
  local ____customStageGridEntities = require("features.customStage.customStageGridEntities")
23
+ local convertVanillaTrapdoors = ____customStageGridEntities.convertVanillaTrapdoors
23
24
  local removeUrnRewards = ____customStageGridEntities.removeUrnRewards
24
25
  local setCustomDecorationGraphics = ____customStageGridEntities.setCustomDecorationGraphics
25
26
  local setCustomDoorGraphics = ____customStageGridEntities.setCustomDoorGraphics
@@ -30,8 +31,6 @@ local ____shadows = require("features.customStage.shadows")
30
31
  local setShadows = ____shadows.setShadows
31
32
  local ____streakText = require("features.customStage.streakText")
32
33
  local streakTextGetShaderParams = ____streakText.streakTextGetShaderParams
33
- local streakTextInit = ____streakText.streakTextInit
34
- local streakTextPostGameStarted = ____streakText.streakTextPostGameStarted
35
34
  local streakTextPostRender = ____streakText.streakTextPostRender
36
35
  local ____v = require("features.customStage.v")
37
36
  local v = ____v.default
@@ -89,14 +88,11 @@ function postCurseEval(self, curses)
89
88
  if customStage == nil then
90
89
  return nil
91
90
  end
92
- if hasFlag(nil, curses, LevelCurse.MAZE) then
93
- return removeFlag(nil, curses, LevelCurse.MAZE)
91
+ if hasFlag(nil, curses, LevelCurse.LABYRINTH) then
92
+ return removeFlag(nil, curses, LevelCurse.LABYRINTH)
94
93
  end
95
94
  return nil
96
95
  end
97
- function postGameStarted(self)
98
- streakTextPostGameStarted(nil)
99
- end
100
96
  function getShaderParams(self, shaderName)
101
97
  local customStage = v.run.currentCustomStage
102
98
  if customStage == nil then
@@ -112,7 +108,7 @@ function postGridEntityBrokenRockAlt(self, gridEntity)
112
108
  end
113
109
  removeUrnRewards(nil, customStage, gridEntity)
114
110
  end
115
- function postGridEntityBrokenInit(self, gridEntity)
111
+ function postGridEntityInit(self, gridEntity)
116
112
  local customStage = v.run.currentCustomStage
117
113
  if customStage == nil then
118
114
  return
@@ -121,6 +117,7 @@ function postGridEntityBrokenInit(self, gridEntity)
121
117
  setCustomRockGraphics(nil, customStage, gridEntity)
122
118
  setCustomPitGraphics(nil, customStage, gridEntity)
123
119
  setCustomDoorGraphics(nil, customStage, gridEntity)
120
+ convertVanillaTrapdoors(nil, customStage, gridEntity)
124
121
  end
125
122
  function postNewRoomReordered(self)
126
123
  local customStage = v.run.currentCustomStage
@@ -137,14 +134,12 @@ function ____exports.customStageInit(self, mod)
137
134
  return
138
135
  end
139
136
  saveDataManager(nil, "customStage", v)
140
- streakTextInit(nil)
141
137
  versusScreenInit(nil)
142
138
  mod:AddCallback(ModCallback.POST_RENDER, postRender)
143
139
  mod:AddCallback(ModCallback.POST_CURSE_EVAL, postCurseEval)
144
- mod:AddCallback(ModCallback.POST_GAME_STARTED, postGameStarted)
145
140
  mod:AddCallback(ModCallback.GET_SHADER_PARAMS, getShaderParams)
146
141
  mod:AddCallbackCustom(ModCallbackCustom.POST_GRID_ENTITY_BROKEN, postGridEntityBrokenRockAlt, GridEntityType.ROCK_ALT)
147
- mod:AddCallbackCustom(ModCallbackCustom.POST_GRID_ENTITY_INIT, postGridEntityBrokenInit)
142
+ mod:AddCallbackCustom(ModCallbackCustom.POST_GRID_ENTITY_INIT, postGridEntityInit)
148
143
  mod:AddCallbackCustom(ModCallbackCustom.POST_NEW_ROOM_REORDERED, postNewRoomReordered)
149
144
  end
150
145
  return ____exports
@@ -1 +1 @@
1
- {"version":3,"file":"shadows.d.ts","sourceRoot":"","sources":["../../../src/features/customStage/shadows.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAoC3D,wBAAgB,UAAU,CAAC,WAAW,EAAE,WAAW,GAAG,IAAI,CAqCzD"}
1
+ {"version":3,"file":"shadows.d.ts","sourceRoot":"","sources":["../../../src/features/customStage/shadows.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAqC3D,wBAAgB,UAAU,CAAC,WAAW,EAAE,WAAW,GAAG,IAAI,CAqCzD"}
@@ -19,6 +19,7 @@ local v = ____v.default
19
19
  -- We arbitrarily choose a ladder for this purpose because it will not automatically despawn after
20
20
  -- time passes, like most other effects.
21
21
  local SHADOW_EFFECT_VARIANT = EffectVariant.LADDER
22
+ local SHADOW_EFFECT_SUBTYPE = 102
22
23
  --- The animation comes from StageAPI.
23
24
  local ROOM_SHAPE_TO_SHADOW_ANIMATION = {
24
25
  [RoomShape.SHAPE_1x1] = "1x1",
@@ -50,7 +51,7 @@ function ____exports.setShadows(self, customStage)
50
51
  local shadowEffect = spawnEffectWithSeed(
51
52
  nil,
52
53
  SHADOW_EFFECT_VARIANT,
53
- 0,
54
+ SHADOW_EFFECT_SUBTYPE,
54
55
  centerPos,
55
56
  1
56
57
  )
@@ -1,12 +1,5 @@
1
1
  import { CustomStage } from "../../interfaces/CustomStage";
2
- /**
3
- * We must load the sprites in an init function to prevent issues with mods that replace the vanilla
4
- * files. (For some reason, loading the sprites will cause the overwrite to no longer apply on the
5
- * second and subsequent runs.)
6
- */
7
- export declare function streakTextInit(): void;
8
2
  export declare function streakTextPostRender(): void;
9
- export declare function streakTextPostGameStarted(): void;
10
3
  export declare function streakTextGetShaderParams(customStage: CustomStage, shaderName: string): void;
11
4
  export declare function topStreakTextStart(): void;
12
5
  //# sourceMappingURL=streakText.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"streakText.d.ts","sourceRoot":"","sources":["../../../src/features/customStage/streakText.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AA0F3D;;;;GAIG;AACH,wBAAgB,cAAc,IAAI,IAAI,CAMrC;AAGD,wBAAgB,oBAAoB,IAAI,IAAI,CAS3C;AAmFD,wBAAgB,yBAAyB,IAAI,IAAI,CAGhD;AAGD,wBAAgB,yBAAyB,CACvC,WAAW,EAAE,WAAW,EACxB,UAAU,EAAE,MAAM,GACjB,IAAI,CAYN;AAgFD,wBAAgB,kBAAkB,IAAI,IAAI,CAUzC"}
1
+ {"version":3,"file":"streakText.d.ts","sourceRoot":"","sources":["../../../src/features/customStage/streakText.ts"],"names":[],"mappings":"AAQA,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAuE3D,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,7 +1,7 @@
1
1
  local ____lualib = require("lualib_bundle")
2
2
  local __TS__Spread = ____lualib.__TS__Spread
3
3
  local ____exports = {}
4
- local checkEndTopStreakText, trackMapInputPressed, checkStartBottomStreakText, checkEndBottomStreakText, renderSprite, playTextOut, UIStreakAnimation, TEXT_STAY_FRAME, TEXT_OUT_FRAME, STREAK_TEXT_BOTTOM_Y_OFFSET, NUM_RENDER_FRAMES_MAP_HELD_BEFORE_STREAK_TEXT, TEXT_IN_ADJUSTMENTS, TEXT_OUT_ADJUSTMENTS, TEXT_IN_SCALES, TEXT_OUT_SCALES, topStreakSprite, bottomStreakSprite
4
+ local checkEndTopStreakText, trackMapInputPressed, checkStartBottomStreakText, checkEndBottomStreakText, renderStreakText, TEXT_STAY_FRAME, TEXT_OUT_FRAME, STREAK_TEXT_BOTTOM_Y_OFFSET, NUM_RENDER_FRAMES_MAP_HELD_BEFORE_STREAK_TEXT, TEXT_IN_ADJUSTMENTS, TEXT_OUT_ADJUSTMENTS, TEXT_IN_SCALES, TEXT_OUT_SCALES
5
5
  local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
6
6
  local ButtonAction = ____isaac_2Dtypescript_2Ddefinitions.ButtonAction
7
7
  local ControllerIndex = ____isaac_2Dtypescript_2Ddefinitions.ControllerIndex
@@ -16,16 +16,20 @@ local getEnumValues = ____enums.getEnumValues
16
16
  local ____ui = require("functions.ui")
17
17
  local getScreenBottomCenterPos = ____ui.getScreenBottomCenterPos
18
18
  local getScreenTopCenterPos = ____ui.getScreenTopCenterPos
19
+ local ____customStageConstants = require("features.customStage.customStageConstants")
20
+ local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
21
+ local UI_STREAK_ANIMATION_END_FRAMES = ____customStageConstants.UI_STREAK_ANIMATION_END_FRAMES
19
22
  local ____v = require("features.customStage.v")
20
23
  local v = ____v.default
21
24
  function checkEndTopStreakText(self)
22
- if v.run.topStreakTextStartedRenderFrame == nil or not topStreakSprite:IsPlaying(UIStreakAnimation.TEXT_STAY) then
25
+ if v.run.topStreakTextStartedRenderFrame == nil or v.run.topStreakText.animation ~= UIStreakAnimation.TEXT_STAY then
23
26
  return
24
27
  end
25
28
  local renderFrameCount = Isaac.GetFrameCount()
26
29
  local elapsedFrames = renderFrameCount - v.run.topStreakTextStartedRenderFrame
27
30
  if elapsedFrames >= 115 then
28
- playTextOut(nil, topStreakSprite)
31
+ v.run.topStreakText.animation = UIStreakAnimation.TEXT
32
+ v.run.topStreakText.frame = TEXT_OUT_FRAME - 2
29
33
  end
30
34
  end
31
35
  function trackMapInputPressed(self)
@@ -43,7 +47,7 @@ function trackMapInputPressed(self)
43
47
  end
44
48
  end
45
49
  function checkStartBottomStreakText(self)
46
- if bottomStreakSprite:IsPlaying() then
50
+ if v.run.bottomStreakText.animation ~= UIStreakAnimation.NONE then
47
51
  return
48
52
  end
49
53
  local pushedMapFrames = {__TS__Spread(v.run.controllerIndexPushingMapRenderFrame:values())}
@@ -54,81 +58,69 @@ function checkStartBottomStreakText(self)
54
58
  local gameFrameCount = game:GetFrameCount()
55
59
  local elapsedFrames = gameFrameCount - earliestFrame
56
60
  if elapsedFrames >= NUM_RENDER_FRAMES_MAP_HELD_BEFORE_STREAK_TEXT then
57
- bottomStreakSprite:Play(UIStreakAnimation.TEXT, true)
61
+ v.run.bottomStreakText.animation = UIStreakAnimation.TEXT
62
+ v.run.bottomStreakText.frame = 0
58
63
  end
59
64
  end
60
65
  function checkEndBottomStreakText(self)
61
- if not bottomStreakSprite:IsPlaying(UIStreakAnimation.TEXT_STAY) then
66
+ if v.run.bottomStreakText.animation ~= UIStreakAnimation.TEXT_STAY then
62
67
  return
63
68
  end
64
69
  local pushedMapFrames = {__TS__Spread(v.run.controllerIndexPushingMapRenderFrame:values())}
65
70
  if #pushedMapFrames == 0 then
66
- playTextOut(nil, bottomStreakSprite)
71
+ v.run.bottomStreakText.animation = UIStreakAnimation.TEXT
72
+ v.run.bottomStreakText.frame = TEXT_OUT_FRAME - 2
67
73
  end
68
74
  end
69
- function renderSprite(self, customStage, sprite, position)
70
- sprite:Update()
71
- if not sprite:IsPlaying() then
75
+ function renderStreakText(self, customStage, streakText, position)
76
+ if streakText.animation == UIStreakAnimation.NONE then
72
77
  return
73
78
  end
74
- local animation = sprite:GetAnimation()
75
- local frame = sprite:GetFrame()
76
- if animation == UIStreakAnimation.TEXT and frame == TEXT_STAY_FRAME then
77
- sprite:Play(UIStreakAnimation.TEXT_STAY, true)
79
+ if streakText.animation ~= UIStreakAnimation.TEXT_STAY then
80
+ local ____streakText_0 = streakText
81
+ local pauseFrame = ____streakText_0.pauseFrame
82
+ streakText.pauseFrame = not streakText.pauseFrame
83
+ if not pauseFrame then
84
+ streakText.frame = streakText.frame + 1
85
+ end
86
+ end
87
+ local endFrame = UI_STREAK_ANIMATION_END_FRAMES[streakText.animation]
88
+ if streakText.frame > endFrame then
89
+ streakText.animation = UIStreakAnimation.NONE
90
+ streakText.frame = 0
91
+ return
92
+ end
93
+ if streakText.animation == UIStreakAnimation.TEXT and streakText.frame == TEXT_STAY_FRAME then
94
+ streakText.animation = UIStreakAnimation.TEXT_STAY
95
+ streakText.frame = 0
78
96
  end
79
97
  local isPaused = game:IsPaused()
80
98
  if isPaused then
81
99
  return
82
100
  end
83
101
  local font = fonts.upheaval
84
- local ____customStage_0 = customStage
85
- local name = ____customStage_0.name
86
- local length = font:GetStringWidthUTF8(name)
102
+ local ____customStage_1 = customStage
103
+ local name = ____customStage_1.name
104
+ local numberSuffix = v.run.firstFloor and "I" or "II"
105
+ local nameWithNumberSuffix = (name .. " ") .. numberSuffix
106
+ local length = font:GetStringWidthUTF8(nameWithNumberSuffix)
87
107
  local centeredX = position.X - length / 2
88
108
  local adjustment = 0
89
109
  local scale = VectorOne
90
- repeat
91
- local ____switch27 = animation
92
- local ____cond27 = ____switch27 == UIStreakAnimation.TEXT
93
- if ____cond27 then
94
- do
95
- if frame < TEXT_STAY_FRAME then
96
- adjustment = TEXT_IN_ADJUSTMENTS[frame + 1] or 0
97
- scale = TEXT_IN_SCALES[frame + 1] or VectorOne
98
- else
99
- local adjustedFrame = frame - TEXT_OUT_FRAME
100
- adjustment = TEXT_OUT_ADJUSTMENTS[adjustedFrame + 1] or 0
101
- scale = TEXT_OUT_SCALES[adjustedFrame + 1] or VectorOne
102
- end
103
- break
104
- end
105
- end
106
- ____cond27 = ____cond27 or ____switch27 == UIStreakAnimation.TEXT_IN
107
- if ____cond27 then
108
- do
109
- adjustment = TEXT_IN_ADJUSTMENTS[frame + 1] or 0
110
- scale = TEXT_IN_SCALES[frame + 1] or VectorOne
111
- break
112
- end
113
- end
114
- ____cond27 = ____cond27 or ____switch27 == UIStreakAnimation.TEXT_OUT
115
- if ____cond27 then
116
- do
117
- adjustment = TEXT_OUT_ADJUSTMENTS[frame + 1] or 0
118
- scale = TEXT_OUT_SCALES[frame + 1] or VectorOne
119
- break
120
- end
121
- end
122
- do
123
- do
124
- break
125
- end
110
+ if streakText.animation == UIStreakAnimation.TEXT then
111
+ if streakText.frame < TEXT_STAY_FRAME then
112
+ adjustment = TEXT_IN_ADJUSTMENTS[streakText.frame + 1] or 0
113
+ scale = TEXT_IN_SCALES[streakText.frame + 1] or VectorOne
114
+ else
115
+ local adjustedFrame = streakText.frame - TEXT_OUT_FRAME
116
+ adjustment = TEXT_OUT_ADJUSTMENTS[adjustedFrame + 1] or 0
117
+ scale = TEXT_OUT_SCALES[adjustedFrame + 1] or VectorOne
126
118
  end
127
- until true
119
+ end
128
120
  local adjustedX = centeredX + adjustment
129
121
  local adjustedY = position.Y + STREAK_TEXT_BOTTOM_Y_OFFSET
130
122
  font:DrawStringScaled(
131
- name,
123
+ nameWithNumberSuffix,
132
124
  adjustedX,
133
125
  adjustedY,
134
126
  scale.X,
@@ -136,15 +128,6 @@ function renderSprite(self, customStage, sprite, position)
136
128
  KColorDefault
137
129
  )
138
130
  end
139
- function playTextOut(self, sprite)
140
- sprite:Play(UIStreakAnimation.TEXT, true)
141
- sprite:SetFrame(TEXT_OUT_FRAME - 2)
142
- end
143
- UIStreakAnimation = UIStreakAnimation or ({})
144
- UIStreakAnimation.TEXT = "Text"
145
- UIStreakAnimation.TEXT_IN = "TextIn"
146
- UIStreakAnimation.TEXT_OUT = "TextOut"
147
- UIStreakAnimation.TEXT_STAY = "TextStay"
148
131
  --- This must match the name of the shader in "shaders.xml".
149
132
  local EMPTY_SHADER_NAME = "IsaacScript-RenderAboveHUD"
150
133
  TEXT_STAY_FRAME = 8
@@ -155,8 +138,6 @@ local STREAK_SPRITE_TOP_OFFSET = Vector(0, 48.25)
155
138
  local STREAK_SPRITE_BOTTOM_OFFSET = Vector(0, -48.25)
156
139
  STREAK_TEXT_BOTTOM_Y_OFFSET = -9
157
140
  NUM_RENDER_FRAMES_MAP_HELD_BEFORE_STREAK_TEXT = 11
158
- --- Corresponds to the vanilla value; determined through trial and error.
159
- local TEXT_PLAYBACK_SPEED = 0.5
160
141
  TEXT_IN_ADJUSTMENTS = {
161
142
  -800,
162
143
  -639,
@@ -201,43 +182,29 @@ TEXT_OUT_SCALES = {
201
182
  Vector(2.59, 0.38),
202
183
  Vector(3, 0.2)
203
184
  }
204
- topStreakSprite = Sprite()
205
- bottomStreakSprite = Sprite()
206
- --- We must load the sprites in an init function to prevent issues with mods that replace the vanilla
207
- -- files. (For some reason, loading the sprites will cause the overwrite to no longer apply on the
208
- -- second and subsequent runs.)
209
- function ____exports.streakTextInit(self)
210
- topStreakSprite:Load("resources/gfx/ui/ui_streak.anm2", false)
211
- topStreakSprite.PlaybackSpeed = TEXT_PLAYBACK_SPEED
212
- bottomStreakSprite:Load("resources/gfx/ui/ui_streak.anm2", false)
213
- bottomStreakSprite.PlaybackSpeed = TEXT_PLAYBACK_SPEED
214
- end
215
185
  function ____exports.streakTextPostRender(self)
216
186
  checkEndTopStreakText(nil)
217
187
  trackMapInputPressed(nil)
218
188
  checkStartBottomStreakText(nil)
219
189
  checkEndBottomStreakText(nil)
220
190
  end
221
- function ____exports.streakTextPostGameStarted(self)
222
- topStreakSprite:Stop()
223
- bottomStreakSprite:Stop()
224
- end
225
191
  function ____exports.streakTextGetShaderParams(self, customStage, shaderName)
226
192
  if shaderName ~= EMPTY_SHADER_NAME then
227
193
  return
228
194
  end
229
195
  local topCenterPos = getScreenTopCenterPos(nil)
230
196
  local topStreakPosition = topCenterPos + STREAK_SPRITE_TOP_OFFSET
231
- renderSprite(nil, customStage, topStreakSprite, topStreakPosition)
197
+ renderStreakText(nil, customStage, v.run.topStreakText, topStreakPosition)
232
198
  local bottomCenterPos = getScreenBottomCenterPos(nil)
233
199
  local bottomStreakPosition = bottomCenterPos + STREAK_SPRITE_BOTTOM_OFFSET
234
- renderSprite(nil, customStage, bottomStreakSprite, bottomStreakPosition)
200
+ renderStreakText(nil, customStage, v.run.bottomStreakText, bottomStreakPosition)
235
201
  end
236
202
  function ____exports.topStreakTextStart(self)
237
203
  local level = game:GetLevel()
238
204
  local renderFrameCount = Isaac.GetFrameCount()
239
205
  level:ShowName(false)
206
+ v.run.topStreakText.animation = UIStreakAnimation.TEXT
207
+ v.run.topStreakText.frame = 0
240
208
  v.run.topStreakTextStartedRenderFrame = renderFrameCount
241
- topStreakSprite:Play(UIStreakAnimation.TEXT, true)
242
209
  end
243
210
  return ____exports
@@ -1,12 +1,25 @@
1
1
  import { ControllerIndex } from "isaac-typescript-definitions";
2
2
  import { CustomStage } from "../../interfaces/CustomStage";
3
+ import { UIStreakAnimation } from "./customStageConstants";
3
4
  declare const v: {
4
5
  run: {
5
6
  currentCustomStage: CustomStage | null;
7
+ /** Whether we are on e.g. Caves 1 or Caves 2. */
8
+ firstFloor: boolean;
6
9
  showingBossVersusScreen: boolean;
7
10
  /** Values are the render frame that the controller first pressed the map button. */
8
11
  controllerIndexPushingMapRenderFrame: Map<ControllerIndex, number>;
9
12
  topStreakTextStartedRenderFrame: number | null;
13
+ topStreakText: {
14
+ animation: UIStreakAnimation;
15
+ frame: number;
16
+ pauseFrame: boolean;
17
+ };
18
+ bottomStreakText: {
19
+ animation: UIStreakAnimation;
20
+ frame: number;
21
+ pauseFrame: boolean;
22
+ };
10
23
  };
11
24
  room: {
12
25
  showingShadows: boolean;
@@ -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,8BAA8B,CAAC;AAE3D,QAAA,MAAM,CAAC;;;;QAKH,oFAAoF;;;;;;;CASvF,CAAC;AACF,eAAe,CAAC,CAAC;AAEjB,oCAAoC;AACpC,eAAO,MAAM,eAAe,0BAAiC,CAAC;AAE9D,+BAA+B;AAC/B,eAAO,MAAM,yBAAyB,mCAAuC,CAAC;AAE9E,4BAA4B;AAC5B,eAAO,MAAM,kBAAkB,6DAG5B,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,8BAA8B,CAAC;AAC3D,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;AAE9E,4BAA4B;AAC5B,eAAO,MAAM,kBAAkB,6DAG5B,CAAC"}
@@ -2,12 +2,17 @@ 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("features.customStage.customStageConstants")
6
+ local UIStreakAnimation = ____customStageConstants.UIStreakAnimation
5
7
  local v = {
6
8
  run = {
7
9
  currentCustomStage = nil,
10
+ firstFloor = true,
8
11
  showingBossVersusScreen = false,
9
12
  controllerIndexPushingMapRenderFrame = __TS__New(Map),
10
- topStreakTextStartedRenderFrame = nil
13
+ topStreakTextStartedRenderFrame = nil,
14
+ topStreakText = {animation = UIStreakAnimation.NONE, frame = 0, pauseFrame = false},
15
+ bottomStreakText = {animation = UIStreakAnimation.NONE, frame = 0, pauseFrame = false}
11
16
  },
12
17
  room = {showingShadows = false}
13
18
  }
@@ -1 +1 @@
1
- {"version":3,"file":"blackSprite.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/blackSprite.ts"],"names":[],"mappings":"AAUA,wBAAgB,eAAe,IAAI,IAAI,CAWtC"}
1
+ {"version":3,"file":"blackSprite.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/blackSprite.ts"],"names":[],"mappings":"AAUA,wBAAgB,eAAe,IAAI,IAAI,CAYtC"}
@@ -13,6 +13,7 @@ function ____exports.drawBlackSprite(self)
13
13
  if not blackSprite:IsLoaded() then
14
14
  blackSprite:Load("gfx/ui/boss/versusscreen.anm2", true)
15
15
  blackSprite:SetFrame("Scene", 0)
16
+ blackSprite.Scale = Vector(100, 100)
16
17
  end
17
18
  blackSprite:RenderLayer(0, VectorZero)
18
19
  end
@@ -6,7 +6,6 @@ import { LevelStage, StageType } from "isaac-typescript-definitions";
6
6
  * - custom destination (or custom logic for after the player enters)
7
7
  * - custom graphics
8
8
  * - custom logic for opening/closing
9
- * - TODO: player jumping animation?
10
9
  *
11
10
  * You can use this function to take the player to your custom stage.
12
11
  *
@@ -15,15 +14,17 @@ import { LevelStage, StageType } from "isaac-typescript-definitions";
15
14
  *
16
15
  * @param gridIndexOrPosition The location in the room to spawn the trapdoor.
17
16
  * @param destination Optional. Used to specify where the player will go after jumping into the
18
- * trapdoor. Can either be a tuple containing the stage and stage type, or a
19
- * string containing the name of a custom stage. If not specified at all, then
20
- * the "normal" destination corresponding to the current stage and room will be
21
- * used (e.g. the next floor).
17
+ * trapdoor. Can either be a tuple or undefined. For example, a destination of
18
+ * `[LevelStage.CAVES_1, StageType.ORIGINAL]` corresponds to Caves 1, and a
19
+ * destination of `["Slaughterhouse", 1]` corresponds to a custom stage of
20
+ * Slaughterhouse 1. If the destination is set to undefined, then the "normal"
21
+ * destination corresponding to the current stage and room will be used (e.g. the
22
+ * next floor).
22
23
  * @param anm2Path Optional. The path to the anm2 file to use. By default, the vanilla trapdoor anm2
23
24
  * of "gfx/grid/door_11_trapdoor.anm2" will be used. The specified anm2 file must
24
25
  * have animations called "Opened", "Closed", and "Open Animation".
25
26
  * @param spawnOpen Optional. Whether or not to spawn the trapdoor in an open state. By default,
26
27
  * behavior will be used that emulates a vanilla trapdoor.
27
28
  */
28
- export declare function spawnCustomTrapdoor(gridIndexOrPosition: int | Vector, destination?: [stage: LevelStage, stageType: StageType] | string, anm2Path?: string, spawnOpen?: boolean): GridEntity;
29
+ export declare function spawnCustomTrapdoor(gridIndexOrPosition: int | Vector, destination?: [stage: LevelStage, stageType: StageType] | [customStageName: string, floorNum: int], anm2Path?: string, spawnOpen?: boolean): GridEntity;
29
30
  //# sourceMappingURL=exports.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/exports.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,UAAU,EACV,SAAS,EACV,MAAM,8BAA8B,CAAC;AAgBtC;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,wBAAgB,mBAAmB,CACjC,mBAAmB,EAAE,GAAG,GAAG,MAAM,EACjC,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,CAAC,GAAG,MAAM,EAChE,QAAQ,SAAmC,EAC3C,SAAS,CAAC,EAAE,OAAO,GAClB,UAAU,CAwCZ"}
1
+ {"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/exports.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,UAAU,EACV,SAAS,EACV,MAAM,8BAA8B,CAAC;AAgBtC;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,mBAAmB,CACjC,mBAAmB,EAAE,GAAG,GAAG,MAAM,EACjC,WAAW,CAAC,EACR,CAAC,KAAK,EAAE,UAAU,EAAE,SAAS,EAAE,SAAS,CAAC,GACzC,CAAC,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,CAAC,EAC5C,QAAQ,SAAmC,EAC3C,SAAS,CAAC,EAAE,OAAO,GAClB,UAAU,CAwCZ"}
@@ -37,7 +37,6 @@ end
37
37
  -- - custom destination (or custom logic for after the player enters)
38
38
  -- - custom graphics
39
39
  -- - custom logic for opening/closing
40
- -- - TODO: player jumping animation?
41
40
  --
42
41
  -- You can use this function to take the player to your custom stage.
43
42
  --
@@ -46,10 +45,12 @@ end
46
45
  --
47
46
  -- @param gridIndexOrPosition The location in the room to spawn the trapdoor.
48
47
  -- @param destination Optional. Used to specify where the player will go after jumping into the
49
- -- trapdoor. Can either be a tuple containing the stage and stage type, or a
50
- -- string containing the name of a custom stage. If not specified at all, then
51
- -- the "normal" destination corresponding to the current stage and room will be
52
- -- used (e.g. the next floor).
48
+ -- trapdoor. Can either be a tuple or undefined. For example, a destination of
49
+ -- `[LevelStage.CAVES_1, StageType.ORIGINAL]` corresponds to Caves 1, and a
50
+ -- destination of `["Slaughterhouse", 1]` corresponds to a custom stage of
51
+ -- Slaughterhouse 1. If the destination is set to undefined, then the "normal"
52
+ -- destination corresponding to the current stage and room will be used (e.g. the
53
+ -- next floor).
53
54
  -- @param anm2Path Optional. The path to the anm2 file to use. By default, the vanilla trapdoor anm2
54
55
  -- of "gfx/grid/door_11_trapdoor.anm2" will be used. The specified anm2 file must
55
56
  -- have animations called "Opened", "Closed", and "Open Animation".
@@ -1 +1 @@
1
- {"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/init.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAyBxD,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,WAAW,GAAG,IAAI,CAUzD"}
1
+ {"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../../../src/features/customTrapdoor/init.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAyBxD,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,WAAW,GAAG,IAAI,CAUzD"}
@@ -5,6 +5,8 @@ local ____exports = {}
5
5
  local postRender, checkAllPlayersJumpComplete, checkPixelationToBlackComplete, checkPausingOnBlackComplete, checkAllPlayersLayingDownComplete, goToCustomDestination, anyPlayerPlayingExtraAnimation, postPEffectUpdate, checkJumpComplete, postGridEntityCustomUpdateTrapdoor
6
6
  local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
7
7
  local Direction = ____isaac_2Dtypescript_2Ddefinitions.Direction
8
+ local EntityCollisionClass = ____isaac_2Dtypescript_2Ddefinitions.EntityCollisionClass
9
+ local EntityGridCollisionClass = ____isaac_2Dtypescript_2Ddefinitions.EntityGridCollisionClass
8
10
  local ModCallback = ____isaac_2Dtypescript_2Ddefinitions.ModCallback
9
11
  local RoomTransitionAnim = ____isaac_2Dtypescript_2Ddefinitions.RoomTransitionAnim
10
12
  local ____cachedClasses = require("cachedClasses")
@@ -20,8 +22,8 @@ local getAllPlayers = ____playerIndex.getAllPlayers
20
22
  local ____roomData = require("functions.roomData")
21
23
  local getRoomGridIndex = ____roomData.getRoomGridIndex
22
24
  local getRoomListIndex = ____roomData.getRoomListIndex
23
- local ____rooms = require("functions.rooms")
24
- local teleport = ____rooms.teleport
25
+ local ____roomTransition = require("functions.roomTransition")
26
+ local teleport = ____roomTransition.teleport
25
27
  local ____stage = require("functions.stage")
26
28
  local setStage = ____stage.setStage
27
29
  local ____types = require("functions.types")
@@ -112,6 +114,8 @@ function checkPausingOnBlackComplete(self)
112
114
  v.run.state = StageTravelState.PLAYERS_LAYING_DOWN
113
115
  for ____, player in ipairs(getAllPlayers(nil)) do
114
116
  player:AnimateAppear()
117
+ player.EntityCollisionClass = EntityCollisionClass.ALL
118
+ player.GridCollisionClass = EntityGridCollisionClass.GROUND
115
119
  end
116
120
  end
117
121
  )
@@ -136,11 +140,12 @@ function goToCustomDestination(self)
136
140
  if v.run.destination == nil then
137
141
  return
138
142
  end
139
- if isString(nil, v.run.destination) then
140
- setCustomStage(nil, "Slaughterhouse")
143
+ local arg1, arg2 = table.unpack(v.run.destination)
144
+ if isString(nil, arg1) then
145
+ local firstFloor = arg2 == 1
146
+ setCustomStage(nil, "Slaughterhouse", firstFloor)
141
147
  else
142
- local stage, stageType = table.unpack(v.run.destination)
143
- setStage(nil, stage, stageType)
148
+ setStage(nil, arg1, arg2)
144
149
  end
145
150
  end
146
151
  function anyPlayerPlayingExtraAnimation(self)
@@ -73,7 +73,6 @@ function setPlayerAttributes(self, trapdoorPlayer, position)
73
73
  player.Velocity = VectorZero
74
74
  player.EntityCollisionClass = EntityCollisionClass.NONE
75
75
  player.GridCollisionClass = EntityGridCollisionClass.NONE
76
- player.SubType = -1
77
76
  end
78
77
  end
79
78
  function dropTaintedForgotten(self, player)
@@ -7,7 +7,7 @@ declare const v: {
7
7
  state: StageTravelState;
8
8
  /** The render frame that this state was reached. */
9
9
  stateRenderFrame: number | null;
10
- destination: string | [stage: LevelStage, stageType: StageType] | null;
10
+ destination: [stage: LevelStage, stageType: StageType] | [customStageName: string, floorNum: number] | null;
11
11
  };
12
12
  level: {
13
13
  /** Indexed by room list index and grid index. */
@@ -1 +1 @@
1
- {"version":3,"file":"commandsSubroutines.d.ts","sourceRoot":"","sources":["../../../src/features/extraConsoleCommands/commandsSubroutines.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EAIT,QAAQ,EACT,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAgBpD,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,UAAU,GAAG,IAAI,CAcrE;AAED,wBAAgB,UAAU,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAqBlD;AAED,wBAAgB,YAAY,CAC1B,MAAM,EAAE,MAAM,EACd,wBAAwB,EAAE,OAAO,GAChC,IAAI,CAYN;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,EAAE,OAAO,GAAG,IAAI,CAY5E;AAED,wBAAgB,UAAU,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,GAAG,IAAI,CAgBrE;AAED,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAUjE;AAED,wBAAgB,cAAc,CAAC,QAAQ,EAAE,QAAQ,GAAG,IAAI,CAevD"}
1
+ {"version":3,"file":"commandsSubroutines.d.ts","sourceRoot":"","sources":["../../../src/features/extraConsoleCommands/commandsSubroutines.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EAIT,QAAQ,EACT,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAmBpD,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,UAAU,GAAG,IAAI,CAcrE;AAED,wBAAgB,UAAU,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAqBlD;AAED,wBAAgB,YAAY,CAC1B,MAAM,EAAE,MAAM,EACd,wBAAwB,EAAE,OAAO,GAChC,IAAI,CAYN;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,EAAE,YAAY,EAAE,OAAO,GAAG,IAAI,CAY5E;AAED,wBAAgB,UAAU,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,GAAG,IAAI,CAgBrE;AAED,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAUjE;AAED,wBAAgB,cAAc,CAAC,QAAQ,EAAE,QAAQ,GAAG,IAAI,CAevD"}
@@ -13,9 +13,9 @@ local ____gridEntities = require("functions.gridEntities")
13
13
  local spawnGridEntityWithVariant = ____gridEntities.spawnGridEntityWithVariant
14
14
  local ____levelGrid = require("functions.levelGrid")
15
15
  local getRoomGridIndexesForType = ____levelGrid.getRoomGridIndexesForType
16
- local ____log = require("functions.log")
17
- local logAllEntities = ____log.logAllEntities
18
- local logAllGridEntities = ____log.logAllGridEntities
16
+ local ____logEntities = require("functions.logEntities")
17
+ local logAllEntities = ____logEntities.logAllEntities
18
+ local logAllGridEntities = ____logEntities.logAllGridEntities
19
19
  local ____playerHealth = require("functions.playerHealth")
20
20
  local addPlayerHealthType = ____playerHealth.addPlayerHealthType
21
21
  local ____roomData = require("functions.roomData")
@@ -59,6 +59,9 @@ import { SaveData } from "../../interfaces/SaveData";
59
59
  * can possibly run).
60
60
  * - Save data is recorded to disk in the `PRE_GAME_EXIT` callback.
61
61
  *
62
+ * You can put lots of data types on your variable objects, but not everything is supported. For the
63
+ * specific things that are supported, see the documentation for the `deepCopy` helper function.
64
+ *
62
65
  * Note that before using the save data manager, you must call the `upgradeMod` function. (Upgrade
63
66
  * your mod before registering any of your own callbacks so that the save data manager will run
64
67
  * before any of your code does.)
@@ -1 +1 @@
1
- {"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/features/saveDataManager/exports.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AAarD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoFG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,MAAM,EACX,CAAC,EAAE,QAAQ,EACX,eAAe,CAAC,EAAE,MAAM,OAAO,GAC9B,IAAI,CAkCN;AAED;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,IAAI,IAAI,CAG1C;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,IAAI,CAG1C;AAQD;;;;;;GAMG;AACH,wBAAgB,wBAAwB,IAAI,IAAI,CAK/C;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,oBAAoB,CAClC,GAAG,EAAE,MAAM,EACX,cAAc,EAAE,MAAM,GACrB,IAAI,CAiBN"}
1
+ {"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/features/saveDataManager/exports.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAE,MAAM,2BAA2B,CAAC;AAarD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuFG;AACH,wBAAgB,eAAe,CAC7B,GAAG,EAAE,MAAM,EACX,CAAC,EAAE,QAAQ,EACX,eAAe,CAAC,EAAE,MAAM,OAAO,GAC9B,IAAI,CAkCN;AAED;;;;;;;GAOG;AACH,wBAAgB,mBAAmB,IAAI,IAAI,CAG1C;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,IAAI,IAAI,CAG1C;AAQD;;;;;;GAMG;AACH,wBAAgB,wBAAwB,IAAI,IAAI,CAK/C;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,oBAAoB,CAClC,GAAG,EAAE,MAAM,EACX,cAAc,EAAE,MAAM,GACrB,IAAI,CAiBN"}
@@ -79,6 +79,9 @@ local SAVE_DATA_MANAGER_FEATURE_NAME = ____saveDataManagerConstants.SAVE_DATA_MA
79
79
  -- can possibly run).
80
80
  -- - Save data is recorded to disk in the `PRE_GAME_EXIT` callback.
81
81
  --
82
+ -- You can put lots of data types on your variable objects, but not everything is supported. For the
83
+ -- specific things that are supported, see the documentation for the `deepCopy` helper function.
84
+ --
82
85
  -- Note that before using the save data manager, you must call the `upgradeMod` function. (Upgrade
83
86
  -- your mod before registering any of your own callbacks so that the save data manager will run
84
87
  -- before any of your code does.)
@@ -4,7 +4,7 @@ import { CollectibleType } from "isaac-typescript-definitions";
4
4
  * collectibles.
5
5
  *
6
6
  * Use this if you need to iterate over the collectibles in order. If you need to do O(1) lookups,
7
- * then use the `getCollectibleArray` helper function instead.
7
+ * then use the `getCollectibleSet` helper function instead.
8
8
  */
9
9
  export declare function getCollectibleArray(): readonly CollectibleType[];
10
10
  /**
@@ -54,7 +54,7 @@ end
54
54
  -- collectibles.
55
55
  --
56
56
  -- Use this if you need to iterate over the collectibles in order. If you need to do O(1) lookups,
57
- -- then use the `getCollectibleArray` helper function instead.
57
+ -- then use the `getCollectibleSet` helper function instead.
58
58
  function ____exports.getCollectibleArray(self)
59
59
  initCollectibleArraysAndSets(nil)
60
60
  return ALL_COLLECTIBLES_ARRAY