isaacscript-common 47.5.0 → 47.5.4

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.
@@ -4724,8 +4724,11 @@ export declare function getAliveNPCs(entityType?: EntityType | -1, variant?: num
4724
4724
  *
4725
4725
  * The set contains strings with the entity type and variant, separated by a period.
4726
4726
  *
4727
- * Note that this set does not include bosses that do not appear in Boss Rooms (e.g. Krampus, Uriel,
4728
- * and Gabriel.).
4727
+ * Note that this set does not include:
4728
+ * - mini-bosses (e.g. Ultra Pride, Krampus)
4729
+ * - bosses that do not appear in Boss Rooms (e.g. Uriel, Gabriel)
4730
+ * - the second phase of multi-phase bosses (e.g. Mega Satan 2), with the exception of The Beast
4731
+ * (Ultra Famine, Ultra Pestilence, Ultra War, and Ultra Death are included)
4729
4732
  *
4730
4733
  * Also see the `getBossSet` and `getCombinedBossSet` functions.
4731
4734
  *
@@ -1,6 +1,6 @@
1
1
  --[[
2
2
 
3
- isaacscript-common 47.5.0
3
+ isaacscript-common 47.5.4
4
4
 
5
5
  This is the "isaacscript-common" library, which was created with the IsaacScript tool.
6
6
 
@@ -43745,14 +43745,11 @@ return ____exports
43745
43745
  ["src.sets.bossSets"] = function(...)
43746
43746
  local ____lualib = require("lualib_bundle")
43747
43747
  local __TS__New = ____lualib.__TS__New
43748
- local __TS__Spread = ____lualib.__TS__Spread
43749
- local __TS__SparseArrayNew = ____lualib.__TS__SparseArrayNew
43750
- local __TS__SparseArrayPush = ____lualib.__TS__SparseArrayPush
43751
- local __TS__SparseArraySpread = ____lualib.__TS__SparseArraySpread
43752
43748
  local Set = ____lualib.Set
43749
+ local __TS__Spread = ____lualib.__TS__Spread
43753
43750
  local ____exports = {}
43754
- local getAllBossesExcludingStoryBossesSet
43755
43751
  local ____isaac_2Dtypescript_2Ddefinitions = require("lua_modules.isaac-typescript-definitions.dist.src.index")
43752
+ local BeastVariant = ____isaac_2Dtypescript_2Ddefinitions.BeastVariant
43756
43753
  local BigHornVariant = ____isaac_2Dtypescript_2Ddefinitions.BigHornVariant
43757
43754
  local ChubVariant = ____isaac_2Dtypescript_2Ddefinitions.ChubVariant
43758
43755
  local DaddyLongLegsVariant = ____isaac_2Dtypescript_2Ddefinitions.DaddyLongLegsVariant
@@ -43785,6 +43782,7 @@ local WidowVariant = ____isaac_2Dtypescript_2Ddefinitions.WidowVariant
43785
43782
  local ____entities = require("src.functions.entities")
43786
43783
  local parseEntityTypeVariantString = ____entities.parseEntityTypeVariantString
43787
43784
  local ____set = require("src.functions.set")
43785
+ local combineSets = ____set.combineSets
43788
43786
  local copySet = ____set.copySet
43789
43787
  local ____utils = require("src.functions.utils")
43790
43788
  local assertDefined = ____utils.assertDefined
@@ -43794,19 +43792,6 @@ local ____ReadonlySet = require("src.types.ReadonlySet")
43794
43792
  local ReadonlySet = ____ReadonlySet.ReadonlySet
43795
43793
  local ____storyBossesSet = require("src.sets.storyBossesSet")
43796
43794
  local STORY_BOSSES_SET = ____storyBossesSet.STORY_BOSSES_SET
43797
- function getAllBossesExcludingStoryBossesSet(self)
43798
- local allBossesExcludingStoryBossesSet = copySet(nil, ____exports.ALL_BOSSES_SET)
43799
- local allBosses = {__TS__Spread(____exports.ALL_BOSSES_SET:values())}
43800
- for ____, entityTypeVariantString in ipairs(allBosses) do
43801
- local tuple = parseEntityTypeVariantString(nil, entityTypeVariantString)
43802
- assertDefined(nil, tuple, "Failed to parse a boss tuple when constructing the story boss set.")
43803
- local entityType, _variant = table.unpack(tuple)
43804
- if STORY_BOSSES_SET:has(entityType) then
43805
- allBossesExcludingStoryBossesSet:delete(entityTypeVariantString)
43806
- end
43807
- end
43808
- return allBossesExcludingStoryBossesSet
43809
- end
43810
43795
  local BASEMENT_BOSSES_SET = __TS__New(
43811
43796
  ReadonlySet,
43812
43797
  {
@@ -43881,27 +43866,13 @@ local DROSS_BOSSES_SET = __TS__New(
43881
43866
  tostring(EntityType.TURDLET) .. ".0"
43882
43867
  }
43883
43868
  )
43884
- local ____ReadonlySet_1 = ReadonlySet
43885
- local ____array_0 = __TS__SparseArrayNew(__TS__Spread(BASEMENT_BOSSES_SET:values()))
43886
- __TS__SparseArrayPush(
43887
- ____array_0,
43888
- __TS__Spread(CELLAR_BOSSES_SET:values())
43889
- )
43890
- __TS__SparseArrayPush(
43891
- ____array_0,
43892
- __TS__Spread(BURNING_BASEMENT_BOSSES_SET:values())
43893
- )
43894
- __TS__SparseArrayPush(
43895
- ____array_0,
43896
- __TS__Spread(DOWNPOUR_BOSSES_SET:values())
43897
- )
43898
- __TS__SparseArrayPush(
43899
- ____array_0,
43900
- __TS__Spread(DROSS_BOSSES_SET:values())
43901
- )
43902
- local ALL_BASEMENT_BOSSES_SET = __TS__New(
43903
- ____ReadonlySet_1,
43904
- {__TS__SparseArraySpread(____array_0)}
43869
+ local ALL_BASEMENT_BOSSES_SET = combineSets(
43870
+ nil,
43871
+ BASEMENT_BOSSES_SET,
43872
+ CELLAR_BOSSES_SET,
43873
+ BURNING_BASEMENT_BOSSES_SET,
43874
+ DOWNPOUR_BOSSES_SET,
43875
+ DROSS_BOSSES_SET
43905
43876
  )
43906
43877
  local BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
43907
43878
  {StageType.ORIGINAL, BASEMENT_BOSSES_SET},
@@ -43992,27 +43963,13 @@ local ASHPIT_BOSSES_SET = __TS__New(
43992
43963
  tostring(EntityType.CLUTCH) .. ".0"
43993
43964
  }
43994
43965
  )
43995
- local ____ReadonlySet_3 = ReadonlySet
43996
- local ____array_2 = __TS__SparseArrayNew(__TS__Spread(CAVES_BOSSES_SET:values()))
43997
- __TS__SparseArrayPush(
43998
- ____array_2,
43999
- __TS__Spread(CATACOMBS_BOSSES_SET:values())
44000
- )
44001
- __TS__SparseArrayPush(
44002
- ____array_2,
44003
- __TS__Spread(FLOODED_CAVES_BOSSES_SET:values())
44004
- )
44005
- __TS__SparseArrayPush(
44006
- ____array_2,
44007
- __TS__Spread(MINES_BOSSES_SET:values())
44008
- )
44009
- __TS__SparseArrayPush(
44010
- ____array_2,
44011
- __TS__Spread(ASHPIT_BOSSES_SET:values())
44012
- )
44013
- local ALL_CAVES_BOSSES_SET = __TS__New(
44014
- ____ReadonlySet_3,
44015
- {__TS__SparseArraySpread(____array_2)}
43966
+ local ALL_CAVES_BOSSES_SET = combineSets(
43967
+ nil,
43968
+ CAVES_BOSSES_SET,
43969
+ CATACOMBS_BOSSES_SET,
43970
+ FLOODED_CAVES_BOSSES_SET,
43971
+ MINES_BOSSES_SET,
43972
+ ASHPIT_BOSSES_SET
44016
43973
  )
44017
43974
  local CAVES_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44018
43975
  {StageType.ORIGINAL, CAVES_BOSSES_SET},
@@ -44087,27 +44044,13 @@ local GEHENNA_BOSSES_SET = __TS__New(
44087
44044
  tostring(EntityType.HORNY_BOYS) .. ".0"
44088
44045
  }
44089
44046
  )
44090
- local ____ReadonlySet_5 = ReadonlySet
44091
- local ____array_4 = __TS__SparseArrayNew(__TS__Spread(DEPTHS_BOSSES_SET:values()))
44092
- __TS__SparseArrayPush(
44093
- ____array_4,
44094
- __TS__Spread(NECROPOLIS_BOSSES_SET:values())
44095
- )
44096
- __TS__SparseArrayPush(
44097
- ____array_4,
44098
- __TS__Spread(DANK_DEPTHS_BOSSES_SET:values())
44099
- )
44100
- __TS__SparseArrayPush(
44101
- ____array_4,
44102
- __TS__Spread(MAUSOLEUM_BOSSES_SET:values())
44103
- )
44104
- __TS__SparseArrayPush(
44105
- ____array_4,
44106
- __TS__Spread(GEHENNA_BOSSES_SET:values())
44107
- )
44108
- local ALL_DEPTHS_BOSSES_SET = __TS__New(
44109
- ____ReadonlySet_5,
44110
- {__TS__SparseArraySpread(____array_4)}
44047
+ local ALL_DEPTHS_BOSSES_SET = combineSets(
44048
+ nil,
44049
+ DEPTHS_BOSSES_SET,
44050
+ NECROPOLIS_BOSSES_SET,
44051
+ DANK_DEPTHS_BOSSES_SET,
44052
+ MAUSOLEUM_BOSSES_SET,
44053
+ GEHENNA_BOSSES_SET
44111
44054
  )
44112
44055
  local DEPTHS_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44113
44056
  {StageType.ORIGINAL, DEPTHS_BOSSES_SET},
@@ -44176,27 +44119,13 @@ local CORPSE_BOSSES_SET = __TS__New(
44176
44119
  tostring(EntityType.MOTHER) .. ".0"
44177
44120
  }
44178
44121
  )
44179
- local ____ReadonlySet_7 = ReadonlySet
44180
- local ____array_6 = __TS__SparseArrayNew(__TS__Spread(WOMB_BOSSES_SET:values()))
44181
- __TS__SparseArrayPush(
44182
- ____array_6,
44183
- __TS__Spread(UTERO_BOSSES_SET:values())
44184
- )
44185
- __TS__SparseArrayPush(
44186
- ____array_6,
44187
- __TS__Spread(SCARRED_WOMB_BOSSES_SET:values())
44188
- )
44189
- __TS__SparseArrayPush(
44190
- ____array_6,
44191
- __TS__Spread(MAUSOLEUM_BOSSES_SET:values())
44192
- )
44193
- __TS__SparseArrayPush(
44194
- ____array_6,
44195
- __TS__Spread(GEHENNA_BOSSES_SET:values())
44196
- )
44197
- local ALL_WOMB_BOSSES_SET = __TS__New(
44198
- ____ReadonlySet_7,
44199
- {__TS__SparseArraySpread(____array_6)}
44122
+ local ALL_WOMB_BOSSES_SET = combineSets(
44123
+ nil,
44124
+ WOMB_BOSSES_SET,
44125
+ UTERO_BOSSES_SET,
44126
+ SCARRED_WOMB_BOSSES_SET,
44127
+ MAUSOLEUM_BOSSES_SET,
44128
+ GEHENNA_BOSSES_SET
44200
44129
  )
44201
44130
  local WOMB_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, WOMB_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, UTERO_BOSSES_SET}, {StageType.AFTERBIRTH, SCARRED_WOMB_BOSSES_SET}, {StageType.REPENTANCE, CORPSE_BOSSES_SET}})
44202
44131
  local BLUE_WOMB_BOSSES_SET = __TS__New(
@@ -44212,36 +44141,41 @@ local CATHEDRAL_BOSSES_SET = __TS__New(
44212
44141
  ReadonlySet,
44213
44142
  {(tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.ISAAC)}
44214
44143
  )
44215
- local ____ReadonlySet_9 = ReadonlySet
44216
- local ____array_8 = __TS__SparseArrayNew(__TS__Spread(SHEOL_BOSSES_SET:values()))
44217
- __TS__SparseArrayPush(
44218
- ____array_8,
44219
- __TS__Spread(CATHEDRAL_BOSSES_SET:values())
44220
- )
44221
- local ALL_STAGE_10_BOSSES_SET = __TS__New(
44222
- ____ReadonlySet_9,
44223
- {__TS__SparseArraySpread(____array_8)}
44224
- )
44144
+ local ALL_STAGE_10_BOSSES_SET = combineSets(nil, SHEOL_BOSSES_SET, CATHEDRAL_BOSSES_SET)
44225
44145
  local STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, SHEOL_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CATHEDRAL_BOSSES_SET}})
44226
44146
  local DARK_ROOM_BOSSES_SET = __TS__New(
44227
44147
  ReadonlySet,
44228
- {(tostring(EntityType.THE_LAMB) .. ".") .. tostring(LambVariant.LAMB)}
44148
+ {
44149
+ (tostring(EntityType.THE_LAMB) .. ".") .. tostring(LambVariant.LAMB),
44150
+ tostring(EntityType.MEGA_SATAN) .. ".0"
44151
+ }
44229
44152
  )
44230
44153
  local CHEST_BOSSES_SET = __TS__New(
44231
44154
  ReadonlySet,
44232
- {(tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.BLUE_BABY)}
44155
+ {
44156
+ (tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.BLUE_BABY),
44157
+ tostring(EntityType.MEGA_SATAN) .. ".0"
44158
+ }
44233
44159
  )
44234
- local ____ReadonlySet_11 = ReadonlySet
44235
- local ____array_10 = __TS__SparseArrayNew(__TS__Spread(DARK_ROOM_BOSSES_SET:values()))
44236
- __TS__SparseArrayPush(
44237
- ____array_10,
44238
- __TS__Spread(CHEST_BOSSES_SET:values())
44160
+ local ALL_STAGE_11_BOSSES_SET = combineSets(nil, DARK_ROOM_BOSSES_SET, CHEST_BOSSES_SET)
44161
+ local STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, DARK_ROOM_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CHEST_BOSSES_SET}})
44162
+ local THE_VOID_BOSSES_SET = __TS__New(
44163
+ ReadonlySet,
44164
+ {tostring(EntityType.DELIRIUM) .. ".0"}
44239
44165
  )
44240
- local ALL_STAGE_11_BOSSES_SET = __TS__New(
44241
- ____ReadonlySet_11,
44242
- {__TS__SparseArraySpread(____array_10)}
44166
+ local THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, THE_VOID_BOSSES_SET}})
44167
+ local HOME_BOSSES_SET = __TS__New(
44168
+ ReadonlySet,
44169
+ {
44170
+ tostring(EntityType.DOGMA) .. ".0",
44171
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.BEAST),
44172
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_FAMINE),
44173
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_PESTILENCE),
44174
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_WAR),
44175
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_DEATH)
44176
+ }
44243
44177
  )
44244
- local STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, DARK_ROOM_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CHEST_BOSSES_SET}})
44178
+ local HOME_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, HOME_BOSSES_SET}})
44245
44179
  ____exports.STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44246
44180
  {1, BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP},
44247
44181
  {2, BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP},
@@ -44253,7 +44187,9 @@ ____exports.STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44253
44187
  {8, WOMB_STAGE_TYPE_TO_BOSS_SET_MAP},
44254
44188
  {9, BLUE_WOMB_STAGE_TYPE_TO_BOSS_SET_MAP},
44255
44189
  {10, STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP},
44256
- {11, STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP}
44190
+ {11, STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP},
44191
+ {12, THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP},
44192
+ {13, HOME_STAGE_TYPE_TO_BOSS_SET_MAP}
44257
44193
  })
44258
44194
  ____exports.STAGE_TO_COMBINED_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44259
44195
  {1, ALL_BASEMENT_BOSSES_SET},
@@ -44266,39 +44202,35 @@ ____exports.STAGE_TO_COMBINED_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
44266
44202
  {8, ALL_WOMB_BOSSES_SET},
44267
44203
  {9, BLUE_WOMB_BOSSES_SET},
44268
44204
  {10, ALL_STAGE_10_BOSSES_SET},
44269
- {11, ALL_STAGE_11_BOSSES_SET}
44205
+ {11, ALL_STAGE_11_BOSSES_SET},
44206
+ {12, THE_VOID_BOSSES_SET},
44207
+ {13, HOME_BOSSES_SET}
44270
44208
  })
44271
- local ____ReadonlySet_13 = ReadonlySet
44272
- local ____array_12 = __TS__SparseArrayNew(__TS__Spread(ALL_BASEMENT_BOSSES_SET:values()))
44273
- __TS__SparseArrayPush(
44274
- ____array_12,
44275
- __TS__Spread(ALL_CAVES_BOSSES_SET:values())
44276
- )
44277
- __TS__SparseArrayPush(
44278
- ____array_12,
44279
- __TS__Spread(ALL_DEPTHS_BOSSES_SET:values())
44280
- )
44281
- __TS__SparseArrayPush(
44282
- ____array_12,
44283
- __TS__Spread(ALL_WOMB_BOSSES_SET:values())
44284
- )
44285
- __TS__SparseArrayPush(
44286
- ____array_12,
44287
- __TS__Spread(BLUE_WOMB_BOSSES_SET:values())
44288
- )
44289
- __TS__SparseArrayPush(
44290
- ____array_12,
44291
- __TS__Spread(ALL_STAGE_10_BOSSES_SET:values())
44292
- )
44293
- __TS__SparseArrayPush(
44294
- ____array_12,
44295
- __TS__Spread(ALL_STAGE_11_BOSSES_SET:values())
44296
- )
44297
- ____exports.ALL_BOSSES_SET = __TS__New(
44298
- ____ReadonlySet_13,
44299
- {__TS__SparseArraySpread(____array_12)}
44209
+ ____exports.ALL_BOSSES_SET = combineSets(
44210
+ nil,
44211
+ ALL_BASEMENT_BOSSES_SET,
44212
+ ALL_CAVES_BOSSES_SET,
44213
+ ALL_DEPTHS_BOSSES_SET,
44214
+ ALL_WOMB_BOSSES_SET,
44215
+ BLUE_WOMB_BOSSES_SET,
44216
+ ALL_STAGE_10_BOSSES_SET,
44217
+ ALL_STAGE_11_BOSSES_SET,
44218
+ THE_VOID_BOSSES_SET,
44219
+ HOME_BOSSES_SET
44300
44220
  )
44301
- ____exports.ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET = getAllBossesExcludingStoryBossesSet(nil)
44221
+ ____exports.ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET = (function()
44222
+ local allBossesExcludingStoryBossesSet = copySet(nil, ____exports.ALL_BOSSES_SET)
44223
+ local allBosses = {__TS__Spread(____exports.ALL_BOSSES_SET:values())}
44224
+ for ____, entityTypeVariantString in ipairs(allBosses) do
44225
+ local tuple = parseEntityTypeVariantString(nil, entityTypeVariantString)
44226
+ assertDefined(nil, tuple, "Failed to parse a boss tuple when constructing the story boss set.")
44227
+ local entityType, _variant = table.unpack(tuple)
44228
+ if STORY_BOSSES_SET:has(entityType) then
44229
+ allBossesExcludingStoryBossesSet:delete(entityTypeVariantString)
44230
+ end
44231
+ end
44232
+ return allBossesExcludingStoryBossesSet
44233
+ end)(nil)
44302
44234
  return ____exports
44303
44235
  end,
44304
44236
  ["src.sets.sinEntityTypesSet"] = function(...)
@@ -20,8 +20,11 @@ export declare function getAliveBosses(entityType?: EntityType | -1, variant?: n
20
20
  *
21
21
  * The set contains strings with the entity type and variant, separated by a period.
22
22
  *
23
- * Note that this set does not include bosses that do not appear in Boss Rooms (e.g. Krampus, Uriel,
24
- * and Gabriel.).
23
+ * Note that this set does not include:
24
+ * - mini-bosses (e.g. Ultra Pride, Krampus)
25
+ * - bosses that do not appear in Boss Rooms (e.g. Uriel, Gabriel)
26
+ * - the second phase of multi-phase bosses (e.g. Mega Satan 2), with the exception of The Beast
27
+ * (Ultra Famine, Ultra Pestilence, Ultra War, and Ultra Death are included)
25
28
  *
26
29
  * Also see the `getBossSet` and `getCombinedBossSet` functions.
27
30
  *
@@ -1 +1 @@
1
- {"version":3,"file":"bosses.d.ts","sourceRoot":"","sources":["../../../src/functions/bosses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAe,MAAM,8BAA8B,CAAC;AA0BvE;;;;;;;;;;;;;GAaG;AACH,wBAAgB,cAAc,CAC5B,UAAU,GAAE,UAAU,GAAG,CAAC,CAAM,EAChC,OAAO,SAAK,EACZ,OAAO,SAAK,EACZ,cAAc,UAAQ,GACrB,SAAS,EAAE,CAGb;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,eAAe,CAC7B,kBAAkB,UAAO,GACxB,WAAW,CAAC,MAAM,CAAC,CAIrB;AAED;;;;;;;GAOG;AACH,wBAAgB,UAAU,CACxB,KAAK,EAAE,GAAG,EACV,SAAS,EAAE,SAAS,GACnB,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAYjC;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,EAAE,CAGb;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,GAAG,GACT,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAOjC;AAED,6FAA6F;AAC7F,wBAAgB,KAAK,CAAC,GAAG,EAAE,SAAS,GAAG,OAAO,CAE7C;AAED;;;;;;;;;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;AAmCD;;;;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,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAe,MAAM,8BAA8B,CAAC;AA0BvE;;;;;;;;;;;;;GAaG;AACH,wBAAgB,cAAc,CAC5B,UAAU,GAAE,UAAU,GAAG,CAAC,CAAM,EAChC,OAAO,SAAK,EACZ,OAAO,SAAK,EACZ,cAAc,UAAQ,GACrB,SAAS,EAAE,CAGb;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,eAAe,CAC7B,kBAAkB,UAAO,GACxB,WAAW,CAAC,MAAM,CAAC,CAIrB;AAED;;;;;;;GAOG;AACH,wBAAgB,UAAU,CACxB,KAAK,EAAE,GAAG,EACV,SAAS,EAAE,SAAS,GACnB,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAYjC;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,EAAE,CAGb;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,GAAG,GACT,WAAW,CAAC,MAAM,CAAC,GAAG,SAAS,CAOjC;AAED,6FAA6F;AAC7F,wBAAgB,KAAK,CAAC,GAAG,EAAE,SAAS,GAAG,OAAO,CAE7C;AAED;;;;;;;;;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;AAmCD;;;;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"}
@@ -108,8 +108,11 @@ end
108
108
  --
109
109
  -- The set contains strings with the entity type and variant, separated by a period.
110
110
  --
111
- -- Note that this set does not include bosses that do not appear in Boss Rooms (e.g. Krampus, Uriel,
112
- -- and Gabriel.).
111
+ -- Note that this set does not include:
112
+ -- - mini-bosses (e.g. Ultra Pride, Krampus)
113
+ -- - bosses that do not appear in Boss Rooms (e.g. Uriel, Gabriel)
114
+ -- - the second phase of multi-phase bosses (e.g. Mega Satan 2), with the exception of The Beast
115
+ -- (Ultra Famine, Ultra Pestilence, Ultra War, and Ultra Death are included)
113
116
  --
114
117
  -- Also see the `getBossSet` and `getCombinedBossSet` functions.
115
118
  --
@@ -1 +1 @@
1
- {"version":3,"file":"bossSets.d.ts","sourceRoot":"","sources":["../../../src/sets/bossSets.ts"],"names":[],"mappings":";AAobA,eAAO,MAAM,mCAAmC,yDAe9C,CAAC;AAEH,eAAO,MAAM,8BAA8B,uCAezC,CAAC;AAEH,eAAO,MAAM,cAAc,qBAQzB,CAAC;AAEH,eAAO,MAAM,qCAAqC,qBACX,CAAC"}
1
+ {"version":3,"file":"bossSets.d.ts","sourceRoot":"","sources":["../../../src/sets/bossSets.ts"],"names":[],"mappings":";AA8cA,eAAO,MAAM,mCAAmC,yDAiB9C,CAAC;AAEH,eAAO,MAAM,8BAA8B,uCAiBzC,CAAC;AAEH,eAAO,MAAM,cAAc,EAAE,WAAW,CAAC,MAAM,CAU9C,CAAC;AAEF,eAAO,MAAM,qCAAqC,EAAE,WAAW,CAAC,MAAM,CAoBhE,CAAC"}
@@ -1,13 +1,10 @@
1
1
  local ____lualib = require("lualib_bundle")
2
2
  local __TS__New = ____lualib.__TS__New
3
- local __TS__Spread = ____lualib.__TS__Spread
4
- local __TS__SparseArrayNew = ____lualib.__TS__SparseArrayNew
5
- local __TS__SparseArrayPush = ____lualib.__TS__SparseArrayPush
6
- local __TS__SparseArraySpread = ____lualib.__TS__SparseArraySpread
7
3
  local Set = ____lualib.Set
4
+ local __TS__Spread = ____lualib.__TS__Spread
8
5
  local ____exports = {}
9
- local getAllBossesExcludingStoryBossesSet
10
6
  local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
7
+ local BeastVariant = ____isaac_2Dtypescript_2Ddefinitions.BeastVariant
11
8
  local BigHornVariant = ____isaac_2Dtypescript_2Ddefinitions.BigHornVariant
12
9
  local ChubVariant = ____isaac_2Dtypescript_2Ddefinitions.ChubVariant
13
10
  local DaddyLongLegsVariant = ____isaac_2Dtypescript_2Ddefinitions.DaddyLongLegsVariant
@@ -40,6 +37,7 @@ local WidowVariant = ____isaac_2Dtypescript_2Ddefinitions.WidowVariant
40
37
  local ____entities = require("src.functions.entities")
41
38
  local parseEntityTypeVariantString = ____entities.parseEntityTypeVariantString
42
39
  local ____set = require("src.functions.set")
40
+ local combineSets = ____set.combineSets
43
41
  local copySet = ____set.copySet
44
42
  local ____utils = require("src.functions.utils")
45
43
  local assertDefined = ____utils.assertDefined
@@ -49,19 +47,6 @@ local ____ReadonlySet = require("src.types.ReadonlySet")
49
47
  local ReadonlySet = ____ReadonlySet.ReadonlySet
50
48
  local ____storyBossesSet = require("src.sets.storyBossesSet")
51
49
  local STORY_BOSSES_SET = ____storyBossesSet.STORY_BOSSES_SET
52
- function getAllBossesExcludingStoryBossesSet(self)
53
- local allBossesExcludingStoryBossesSet = copySet(nil, ____exports.ALL_BOSSES_SET)
54
- local allBosses = {__TS__Spread(____exports.ALL_BOSSES_SET:values())}
55
- for ____, entityTypeVariantString in ipairs(allBosses) do
56
- local tuple = parseEntityTypeVariantString(nil, entityTypeVariantString)
57
- assertDefined(nil, tuple, "Failed to parse a boss tuple when constructing the story boss set.")
58
- local entityType, _variant = table.unpack(tuple)
59
- if STORY_BOSSES_SET:has(entityType) then
60
- allBossesExcludingStoryBossesSet:delete(entityTypeVariantString)
61
- end
62
- end
63
- return allBossesExcludingStoryBossesSet
64
- end
65
50
  --- Contains just the bosses in Basement (not e.g. Burning Basement).
66
51
  local BASEMENT_BOSSES_SET = __TS__New(
67
52
  ReadonlySet,
@@ -141,28 +126,14 @@ local DROSS_BOSSES_SET = __TS__New(
141
126
  tostring(EntityType.TURDLET) .. ".0"
142
127
  }
143
128
  )
144
- local ____ReadonlySet_1 = ReadonlySet
145
- local ____array_0 = __TS__SparseArrayNew(__TS__Spread(BASEMENT_BOSSES_SET:values()))
146
- __TS__SparseArrayPush(
147
- ____array_0,
148
- __TS__Spread(CELLAR_BOSSES_SET:values())
149
- )
150
- __TS__SparseArrayPush(
151
- ____array_0,
152
- __TS__Spread(BURNING_BASEMENT_BOSSES_SET:values())
153
- )
154
- __TS__SparseArrayPush(
155
- ____array_0,
156
- __TS__Spread(DOWNPOUR_BOSSES_SET:values())
157
- )
158
- __TS__SparseArrayPush(
159
- ____array_0,
160
- __TS__Spread(DROSS_BOSSES_SET:values())
161
- )
162
129
  --- The set of unique bosses for Basement, Cellar, and so on.
163
- local ALL_BASEMENT_BOSSES_SET = __TS__New(
164
- ____ReadonlySet_1,
165
- {__TS__SparseArraySpread(____array_0)}
130
+ local ALL_BASEMENT_BOSSES_SET = combineSets(
131
+ nil,
132
+ BASEMENT_BOSSES_SET,
133
+ CELLAR_BOSSES_SET,
134
+ BURNING_BASEMENT_BOSSES_SET,
135
+ DOWNPOUR_BOSSES_SET,
136
+ DROSS_BOSSES_SET
166
137
  )
167
138
  local BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
168
139
  {StageType.ORIGINAL, BASEMENT_BOSSES_SET},
@@ -258,28 +229,14 @@ local ASHPIT_BOSSES_SET = __TS__New(
258
229
  tostring(EntityType.CLUTCH) .. ".0"
259
230
  }
260
231
  )
261
- local ____ReadonlySet_3 = ReadonlySet
262
- local ____array_2 = __TS__SparseArrayNew(__TS__Spread(CAVES_BOSSES_SET:values()))
263
- __TS__SparseArrayPush(
264
- ____array_2,
265
- __TS__Spread(CATACOMBS_BOSSES_SET:values())
266
- )
267
- __TS__SparseArrayPush(
268
- ____array_2,
269
- __TS__Spread(FLOODED_CAVES_BOSSES_SET:values())
270
- )
271
- __TS__SparseArrayPush(
272
- ____array_2,
273
- __TS__Spread(MINES_BOSSES_SET:values())
274
- )
275
- __TS__SparseArrayPush(
276
- ____array_2,
277
- __TS__Spread(ASHPIT_BOSSES_SET:values())
278
- )
279
232
  --- The set of unique bosses for Caves, Catacombs, and so on.
280
- local ALL_CAVES_BOSSES_SET = __TS__New(
281
- ____ReadonlySet_3,
282
- {__TS__SparseArraySpread(____array_2)}
233
+ local ALL_CAVES_BOSSES_SET = combineSets(
234
+ nil,
235
+ CAVES_BOSSES_SET,
236
+ CATACOMBS_BOSSES_SET,
237
+ FLOODED_CAVES_BOSSES_SET,
238
+ MINES_BOSSES_SET,
239
+ ASHPIT_BOSSES_SET
283
240
  )
284
241
  local CAVES_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
285
242
  {StageType.ORIGINAL, CAVES_BOSSES_SET},
@@ -359,28 +316,14 @@ local GEHENNA_BOSSES_SET = __TS__New(
359
316
  tostring(EntityType.HORNY_BOYS) .. ".0"
360
317
  }
361
318
  )
362
- local ____ReadonlySet_5 = ReadonlySet
363
- local ____array_4 = __TS__SparseArrayNew(__TS__Spread(DEPTHS_BOSSES_SET:values()))
364
- __TS__SparseArrayPush(
365
- ____array_4,
366
- __TS__Spread(NECROPOLIS_BOSSES_SET:values())
367
- )
368
- __TS__SparseArrayPush(
369
- ____array_4,
370
- __TS__Spread(DANK_DEPTHS_BOSSES_SET:values())
371
- )
372
- __TS__SparseArrayPush(
373
- ____array_4,
374
- __TS__Spread(MAUSOLEUM_BOSSES_SET:values())
375
- )
376
- __TS__SparseArrayPush(
377
- ____array_4,
378
- __TS__Spread(GEHENNA_BOSSES_SET:values())
379
- )
380
319
  --- The set of unique bosses for Depths, Necropolis, and so on.
381
- local ALL_DEPTHS_BOSSES_SET = __TS__New(
382
- ____ReadonlySet_5,
383
- {__TS__SparseArraySpread(____array_4)}
320
+ local ALL_DEPTHS_BOSSES_SET = combineSets(
321
+ nil,
322
+ DEPTHS_BOSSES_SET,
323
+ NECROPOLIS_BOSSES_SET,
324
+ DANK_DEPTHS_BOSSES_SET,
325
+ MAUSOLEUM_BOSSES_SET,
326
+ GEHENNA_BOSSES_SET
384
327
  )
385
328
  local DEPTHS_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
386
329
  {StageType.ORIGINAL, DEPTHS_BOSSES_SET},
@@ -453,28 +396,14 @@ local CORPSE_BOSSES_SET = __TS__New(
453
396
  tostring(EntityType.MOTHER) .. ".0"
454
397
  }
455
398
  )
456
- local ____ReadonlySet_7 = ReadonlySet
457
- local ____array_6 = __TS__SparseArrayNew(__TS__Spread(WOMB_BOSSES_SET:values()))
458
- __TS__SparseArrayPush(
459
- ____array_6,
460
- __TS__Spread(UTERO_BOSSES_SET:values())
461
- )
462
- __TS__SparseArrayPush(
463
- ____array_6,
464
- __TS__Spread(SCARRED_WOMB_BOSSES_SET:values())
465
- )
466
- __TS__SparseArrayPush(
467
- ____array_6,
468
- __TS__Spread(MAUSOLEUM_BOSSES_SET:values())
469
- )
470
- __TS__SparseArrayPush(
471
- ____array_6,
472
- __TS__Spread(GEHENNA_BOSSES_SET:values())
473
- )
474
399
  --- The set of unique bosses for Depths, Necropolis, and so on.
475
- local ALL_WOMB_BOSSES_SET = __TS__New(
476
- ____ReadonlySet_7,
477
- {__TS__SparseArraySpread(____array_6)}
400
+ local ALL_WOMB_BOSSES_SET = combineSets(
401
+ nil,
402
+ WOMB_BOSSES_SET,
403
+ UTERO_BOSSES_SET,
404
+ SCARRED_WOMB_BOSSES_SET,
405
+ MAUSOLEUM_BOSSES_SET,
406
+ GEHENNA_BOSSES_SET
478
407
  )
479
408
  local WOMB_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, WOMB_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, UTERO_BOSSES_SET}, {StageType.AFTERBIRTH, SCARRED_WOMB_BOSSES_SET}, {StageType.REPENTANCE, CORPSE_BOSSES_SET}})
480
409
  local BLUE_WOMB_BOSSES_SET = __TS__New(
@@ -490,36 +419,41 @@ local CATHEDRAL_BOSSES_SET = __TS__New(
490
419
  ReadonlySet,
491
420
  {(tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.ISAAC)}
492
421
  )
493
- local ____ReadonlySet_9 = ReadonlySet
494
- local ____array_8 = __TS__SparseArrayNew(__TS__Spread(SHEOL_BOSSES_SET:values()))
495
- __TS__SparseArrayPush(
496
- ____array_8,
497
- __TS__Spread(CATHEDRAL_BOSSES_SET:values())
498
- )
499
- local ALL_STAGE_10_BOSSES_SET = __TS__New(
500
- ____ReadonlySet_9,
501
- {__TS__SparseArraySpread(____array_8)}
502
- )
422
+ local ALL_STAGE_10_BOSSES_SET = combineSets(nil, SHEOL_BOSSES_SET, CATHEDRAL_BOSSES_SET)
503
423
  local STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, SHEOL_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CATHEDRAL_BOSSES_SET}})
504
424
  local DARK_ROOM_BOSSES_SET = __TS__New(
505
425
  ReadonlySet,
506
- {(tostring(EntityType.THE_LAMB) .. ".") .. tostring(LambVariant.LAMB)}
426
+ {
427
+ (tostring(EntityType.THE_LAMB) .. ".") .. tostring(LambVariant.LAMB),
428
+ tostring(EntityType.MEGA_SATAN) .. ".0"
429
+ }
507
430
  )
508
431
  local CHEST_BOSSES_SET = __TS__New(
509
432
  ReadonlySet,
510
- {(tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.BLUE_BABY)}
433
+ {
434
+ (tostring(EntityType.ISAAC) .. ".") .. tostring(IsaacVariant.BLUE_BABY),
435
+ tostring(EntityType.MEGA_SATAN) .. ".0"
436
+ }
511
437
  )
512
- local ____ReadonlySet_11 = ReadonlySet
513
- local ____array_10 = __TS__SparseArrayNew(__TS__Spread(DARK_ROOM_BOSSES_SET:values()))
514
- __TS__SparseArrayPush(
515
- ____array_10,
516
- __TS__Spread(CHEST_BOSSES_SET:values())
438
+ local ALL_STAGE_11_BOSSES_SET = combineSets(nil, DARK_ROOM_BOSSES_SET, CHEST_BOSSES_SET)
439
+ local STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, DARK_ROOM_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CHEST_BOSSES_SET}})
440
+ local THE_VOID_BOSSES_SET = __TS__New(
441
+ ReadonlySet,
442
+ {tostring(EntityType.DELIRIUM) .. ".0"}
517
443
  )
518
- local ALL_STAGE_11_BOSSES_SET = __TS__New(
519
- ____ReadonlySet_11,
520
- {__TS__SparseArraySpread(____array_10)}
444
+ local THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, THE_VOID_BOSSES_SET}})
445
+ local HOME_BOSSES_SET = __TS__New(
446
+ ReadonlySet,
447
+ {
448
+ tostring(EntityType.DOGMA) .. ".0",
449
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.BEAST),
450
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_FAMINE),
451
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_PESTILENCE),
452
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_WAR),
453
+ (tostring(EntityType.BEAST) .. ".") .. tostring(BeastVariant.ULTRA_DEATH)
454
+ }
521
455
  )
522
- local STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, DARK_ROOM_BOSSES_SET}, {StageType.WRATH_OF_THE_LAMB, CHEST_BOSSES_SET}})
456
+ local HOME_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {{StageType.ORIGINAL, HOME_BOSSES_SET}})
523
457
  ____exports.STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
524
458
  {1, BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP},
525
459
  {2, BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP},
@@ -531,7 +465,9 @@ ____exports.STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
531
465
  {8, WOMB_STAGE_TYPE_TO_BOSS_SET_MAP},
532
466
  {9, BLUE_WOMB_STAGE_TYPE_TO_BOSS_SET_MAP},
533
467
  {10, STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP},
534
- {11, STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP}
468
+ {11, STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP},
469
+ {12, THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP},
470
+ {13, HOME_STAGE_TYPE_TO_BOSS_SET_MAP}
535
471
  })
536
472
  ____exports.STAGE_TO_COMBINED_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
537
473
  {1, ALL_BASEMENT_BOSSES_SET},
@@ -544,37 +480,33 @@ ____exports.STAGE_TO_COMBINED_BOSS_SET_MAP = __TS__New(ReadonlyMap, {
544
480
  {8, ALL_WOMB_BOSSES_SET},
545
481
  {9, BLUE_WOMB_BOSSES_SET},
546
482
  {10, ALL_STAGE_10_BOSSES_SET},
547
- {11, ALL_STAGE_11_BOSSES_SET}
483
+ {11, ALL_STAGE_11_BOSSES_SET},
484
+ {12, THE_VOID_BOSSES_SET},
485
+ {13, HOME_BOSSES_SET}
548
486
  })
549
- local ____ReadonlySet_13 = ReadonlySet
550
- local ____array_12 = __TS__SparseArrayNew(__TS__Spread(ALL_BASEMENT_BOSSES_SET:values()))
551
- __TS__SparseArrayPush(
552
- ____array_12,
553
- __TS__Spread(ALL_CAVES_BOSSES_SET:values())
554
- )
555
- __TS__SparseArrayPush(
556
- ____array_12,
557
- __TS__Spread(ALL_DEPTHS_BOSSES_SET:values())
558
- )
559
- __TS__SparseArrayPush(
560
- ____array_12,
561
- __TS__Spread(ALL_WOMB_BOSSES_SET:values())
562
- )
563
- __TS__SparseArrayPush(
564
- ____array_12,
565
- __TS__Spread(BLUE_WOMB_BOSSES_SET:values())
566
- )
567
- __TS__SparseArrayPush(
568
- ____array_12,
569
- __TS__Spread(ALL_STAGE_10_BOSSES_SET:values())
570
- )
571
- __TS__SparseArrayPush(
572
- ____array_12,
573
- __TS__Spread(ALL_STAGE_11_BOSSES_SET:values())
574
- )
575
- ____exports.ALL_BOSSES_SET = __TS__New(
576
- ____ReadonlySet_13,
577
- {__TS__SparseArraySpread(____array_12)}
578
- )
579
- ____exports.ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET = getAllBossesExcludingStoryBossesSet(nil)
487
+ ____exports.ALL_BOSSES_SET = combineSets(
488
+ nil,
489
+ ALL_BASEMENT_BOSSES_SET,
490
+ ALL_CAVES_BOSSES_SET,
491
+ ALL_DEPTHS_BOSSES_SET,
492
+ ALL_WOMB_BOSSES_SET,
493
+ BLUE_WOMB_BOSSES_SET,
494
+ ALL_STAGE_10_BOSSES_SET,
495
+ ALL_STAGE_11_BOSSES_SET,
496
+ THE_VOID_BOSSES_SET,
497
+ HOME_BOSSES_SET
498
+ )
499
+ ____exports.ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET = (function()
500
+ local allBossesExcludingStoryBossesSet = copySet(nil, ____exports.ALL_BOSSES_SET)
501
+ local allBosses = {__TS__Spread(____exports.ALL_BOSSES_SET:values())}
502
+ for ____, entityTypeVariantString in ipairs(allBosses) do
503
+ local tuple = parseEntityTypeVariantString(nil, entityTypeVariantString)
504
+ assertDefined(nil, tuple, "Failed to parse a boss tuple when constructing the story boss set.")
505
+ local entityType, _variant = table.unpack(tuple)
506
+ if STORY_BOSSES_SET:has(entityType) then
507
+ allBossesExcludingStoryBossesSet:delete(entityTypeVariantString)
508
+ end
509
+ end
510
+ return allBossesExcludingStoryBossesSet
511
+ end)(nil)
580
512
  return ____exports
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "isaacscript-common",
3
- "version": "47.5.0",
3
+ "version": "47.5.4",
4
4
  "description": "Helper functions and features for IsaacScript mods.",
5
5
  "keywords": [
6
6
  "isaac",
@@ -25,6 +25,6 @@
25
25
  "main": "dist/src/index",
26
26
  "types": "dist/index.rollup.d.ts",
27
27
  "dependencies": {
28
- "isaac-typescript-definitions": "^17.0.4"
28
+ "isaac-typescript-definitions": "^17.0.5"
29
29
  }
30
30
  }
@@ -54,8 +54,11 @@ export function getAliveBosses(
54
54
  *
55
55
  * The set contains strings with the entity type and variant, separated by a period.
56
56
  *
57
- * Note that this set does not include bosses that do not appear in Boss Rooms (e.g. Krampus, Uriel,
58
- * and Gabriel.).
57
+ * Note that this set does not include:
58
+ * - mini-bosses (e.g. Ultra Pride, Krampus)
59
+ * - bosses that do not appear in Boss Rooms (e.g. Uriel, Gabriel)
60
+ * - the second phase of multi-phase bosses (e.g. Mega Satan 2), with the exception of The Beast
61
+ * (Ultra Famine, Ultra Pestilence, Ultra War, and Ultra Death are included)
59
62
  *
60
63
  * Also see the `getBossSet` and `getCombinedBossSet` functions.
61
64
  *
@@ -1,4 +1,5 @@
1
1
  import {
2
+ BeastVariant,
2
3
  BigHornVariant,
3
4
  ChubVariant,
4
5
  DaddyLongLegsVariant,
@@ -30,7 +31,7 @@ import {
30
31
  WidowVariant,
31
32
  } from "isaac-typescript-definitions";
32
33
  import { parseEntityTypeVariantString } from "../functions/entities";
33
- import { copySet } from "../functions/set";
34
+ import { combineSets, copySet } from "../functions/set";
34
35
  import { assertDefined } from "../functions/utils";
35
36
  import { ReadonlyMap } from "../types/ReadonlyMap";
36
37
  import { ReadonlySet } from "../types/ReadonlySet";
@@ -112,13 +113,13 @@ const DROSS_BOSSES_SET = new ReadonlySet<string>([
112
113
  ]);
113
114
 
114
115
  /** The set of unique bosses for Basement, Cellar, and so on. */
115
- const ALL_BASEMENT_BOSSES_SET = new ReadonlySet<string>([
116
- ...BASEMENT_BOSSES_SET.values(),
117
- ...CELLAR_BOSSES_SET.values(),
118
- ...BURNING_BASEMENT_BOSSES_SET.values(),
119
- ...DOWNPOUR_BOSSES_SET.values(),
120
- ...DROSS_BOSSES_SET.values(),
121
- ]);
116
+ const ALL_BASEMENT_BOSSES_SET: ReadonlySet<string> = combineSets(
117
+ BASEMENT_BOSSES_SET,
118
+ CELLAR_BOSSES_SET,
119
+ BURNING_BASEMENT_BOSSES_SET,
120
+ DOWNPOUR_BOSSES_SET,
121
+ DROSS_BOSSES_SET,
122
+ );
122
123
 
123
124
  const BASEMENT_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
124
125
  StageType,
@@ -209,13 +210,13 @@ const ASHPIT_BOSSES_SET = new ReadonlySet<string>([
209
210
  ]);
210
211
 
211
212
  /** The set of unique bosses for Caves, Catacombs, and so on. */
212
- const ALL_CAVES_BOSSES_SET = new ReadonlySet<string>([
213
- ...CAVES_BOSSES_SET.values(),
214
- ...CATACOMBS_BOSSES_SET.values(),
215
- ...FLOODED_CAVES_BOSSES_SET.values(),
216
- ...MINES_BOSSES_SET.values(),
217
- ...ASHPIT_BOSSES_SET.values(),
218
- ]);
213
+ const ALL_CAVES_BOSSES_SET: ReadonlySet<string> = combineSets(
214
+ CAVES_BOSSES_SET,
215
+ CATACOMBS_BOSSES_SET,
216
+ FLOODED_CAVES_BOSSES_SET,
217
+ MINES_BOSSES_SET,
218
+ ASHPIT_BOSSES_SET,
219
+ );
219
220
 
220
221
  const CAVES_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
221
222
  StageType,
@@ -290,13 +291,13 @@ const GEHENNA_BOSSES_SET = new ReadonlySet<string>([
290
291
  ]);
291
292
 
292
293
  /** The set of unique bosses for Depths, Necropolis, and so on. */
293
- const ALL_DEPTHS_BOSSES_SET = new ReadonlySet<string>([
294
- ...DEPTHS_BOSSES_SET.values(),
295
- ...NECROPOLIS_BOSSES_SET.values(),
296
- ...DANK_DEPTHS_BOSSES_SET.values(),
297
- ...MAUSOLEUM_BOSSES_SET.values(),
298
- ...GEHENNA_BOSSES_SET.values(),
299
- ]);
294
+ const ALL_DEPTHS_BOSSES_SET: ReadonlySet<string> = combineSets(
295
+ DEPTHS_BOSSES_SET,
296
+ NECROPOLIS_BOSSES_SET,
297
+ DANK_DEPTHS_BOSSES_SET,
298
+ MAUSOLEUM_BOSSES_SET,
299
+ GEHENNA_BOSSES_SET,
300
+ );
300
301
 
301
302
  const DEPTHS_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
302
303
  StageType,
@@ -366,13 +367,13 @@ const CORPSE_BOSSES_SET = new ReadonlySet<string>([
366
367
  ]);
367
368
 
368
369
  /** The set of unique bosses for Depths, Necropolis, and so on. */
369
- const ALL_WOMB_BOSSES_SET = new ReadonlySet<string>([
370
- ...WOMB_BOSSES_SET.values(),
371
- ...UTERO_BOSSES_SET.values(),
372
- ...SCARRED_WOMB_BOSSES_SET.values(),
373
- ...MAUSOLEUM_BOSSES_SET.values(),
374
- ...GEHENNA_BOSSES_SET.values(),
375
- ]);
370
+ const ALL_WOMB_BOSSES_SET: ReadonlySet<string> = combineSets(
371
+ WOMB_BOSSES_SET,
372
+ UTERO_BOSSES_SET,
373
+ SCARRED_WOMB_BOSSES_SET,
374
+ MAUSOLEUM_BOSSES_SET,
375
+ GEHENNA_BOSSES_SET,
376
+ );
376
377
 
377
378
  const WOMB_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
378
379
  StageType,
@@ -400,10 +401,10 @@ const CATHEDRAL_BOSSES_SET = new ReadonlySet<string>([
400
401
  `${EntityType.ISAAC}.${IsaacVariant.ISAAC}`, // 102.0
401
402
  ]);
402
403
 
403
- const ALL_STAGE_10_BOSSES_SET = new ReadonlySet<string>([
404
- ...SHEOL_BOSSES_SET.values(),
405
- ...CATHEDRAL_BOSSES_SET.values(),
406
- ]);
404
+ const ALL_STAGE_10_BOSSES_SET: ReadonlySet<string> = combineSets(
405
+ SHEOL_BOSSES_SET,
406
+ CATHEDRAL_BOSSES_SET,
407
+ );
407
408
 
408
409
  const STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
409
410
  StageType,
@@ -415,16 +416,18 @@ const STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
415
416
 
416
417
  const DARK_ROOM_BOSSES_SET = new ReadonlySet<string>([
417
418
  `${EntityType.THE_LAMB}.${LambVariant.LAMB}`, // 273.0
419
+ `${EntityType.MEGA_SATAN}.0`, // 274.0
418
420
  ]);
419
421
 
420
422
  const CHEST_BOSSES_SET = new ReadonlySet<string>([
421
423
  `${EntityType.ISAAC}.${IsaacVariant.BLUE_BABY}`, // 102.1
424
+ `${EntityType.MEGA_SATAN}.0`, // 274.0
422
425
  ]);
423
426
 
424
- const ALL_STAGE_11_BOSSES_SET = new ReadonlySet<string>([
425
- ...DARK_ROOM_BOSSES_SET.values(),
426
- ...CHEST_BOSSES_SET.values(),
427
- ]);
427
+ const ALL_STAGE_11_BOSSES_SET: ReadonlySet<string> = combineSets(
428
+ DARK_ROOM_BOSSES_SET,
429
+ CHEST_BOSSES_SET,
430
+ );
428
431
 
429
432
  const STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
430
433
  StageType,
@@ -434,6 +437,29 @@ const STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
434
437
  [StageType.WRATH_OF_THE_LAMB, CHEST_BOSSES_SET],
435
438
  ]);
436
439
 
440
+ const THE_VOID_BOSSES_SET = new ReadonlySet<string>([
441
+ `${EntityType.DELIRIUM}.0`, // 412.0
442
+ ]);
443
+
444
+ const THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
445
+ StageType,
446
+ ReadonlySet<string>
447
+ >([[StageType.ORIGINAL, THE_VOID_BOSSES_SET]]);
448
+
449
+ const HOME_BOSSES_SET = new ReadonlySet<string>([
450
+ `${EntityType.DOGMA}.0`, // 950.0
451
+ `${EntityType.BEAST}.${BeastVariant.BEAST}`, // 951.0
452
+ `${EntityType.BEAST}.${BeastVariant.ULTRA_FAMINE}`, // 951.10
453
+ `${EntityType.BEAST}.${BeastVariant.ULTRA_PESTILENCE}`, // 951.20
454
+ `${EntityType.BEAST}.${BeastVariant.ULTRA_WAR}`, // 951.30
455
+ `${EntityType.BEAST}.${BeastVariant.ULTRA_DEATH}`, // 951.40
456
+ ]);
457
+
458
+ const HOME_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
459
+ StageType,
460
+ ReadonlySet<string>
461
+ >([[StageType.ORIGINAL, HOME_BOSSES_SET]]);
462
+
437
463
  export const STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
438
464
  int,
439
465
  ReadonlyMap<int, ReadonlySet<string>>
@@ -449,6 +475,8 @@ export const STAGE_TO_STAGE_TYPE_TO_BOSS_SET_MAP = new ReadonlyMap<
449
475
  [9, BLUE_WOMB_STAGE_TYPE_TO_BOSS_SET_MAP],
450
476
  [10, STAGE_10_STAGE_TYPE_TO_BOSS_SET_MAP],
451
477
  [11, STAGE_11_STAGE_TYPE_TO_BOSS_SET_MAP],
478
+ [12, THE_VOID_STAGE_TYPE_TO_BOSS_SET_MAP],
479
+ [13, HOME_STAGE_TYPE_TO_BOSS_SET_MAP],
452
480
  ]);
453
481
 
454
482
  export const STAGE_TO_COMBINED_BOSS_SET_MAP = new ReadonlyMap<
@@ -466,40 +494,40 @@ export const STAGE_TO_COMBINED_BOSS_SET_MAP = new ReadonlyMap<
466
494
  [9, BLUE_WOMB_BOSSES_SET],
467
495
  [10, ALL_STAGE_10_BOSSES_SET],
468
496
  [11, ALL_STAGE_11_BOSSES_SET],
469
- ]);
470
-
471
- export const ALL_BOSSES_SET = new ReadonlySet<string>([
472
- ...ALL_BASEMENT_BOSSES_SET.values(),
473
- ...ALL_CAVES_BOSSES_SET.values(),
474
- ...ALL_DEPTHS_BOSSES_SET.values(),
475
- ...ALL_WOMB_BOSSES_SET.values(),
476
- ...BLUE_WOMB_BOSSES_SET.values(),
477
- ...ALL_STAGE_10_BOSSES_SET.values(),
478
- ...ALL_STAGE_11_BOSSES_SET.values(),
479
- ]);
480
-
481
- export const ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET =
482
- getAllBossesExcludingStoryBossesSet();
483
-
484
- /**
485
- * Since story bosses are stored by entity type, we copy the existing bosses and filter them (to
486
- * avoid having to hard-code story boss variants).
487
- */
488
- function getAllBossesExcludingStoryBossesSet(): ReadonlySet<string> {
489
- const allBossesExcludingStoryBossesSet = copySet(ALL_BOSSES_SET);
490
- const allBosses = [...ALL_BOSSES_SET.values()];
491
- for (const entityTypeVariantString of allBosses) {
492
- const tuple = parseEntityTypeVariantString(entityTypeVariantString);
493
- assertDefined(
494
- tuple,
495
- "Failed to parse a boss tuple when constructing the story boss set.",
496
- );
497
-
498
- const [entityType, _variant] = tuple;
499
- if (STORY_BOSSES_SET.has(entityType)) {
500
- allBossesExcludingStoryBossesSet.delete(entityTypeVariantString);
497
+ [12, THE_VOID_BOSSES_SET],
498
+ [13, HOME_BOSSES_SET],
499
+ ]);
500
+
501
+ export const ALL_BOSSES_SET: ReadonlySet<string> = combineSets(
502
+ ALL_BASEMENT_BOSSES_SET,
503
+ ALL_CAVES_BOSSES_SET,
504
+ ALL_DEPTHS_BOSSES_SET,
505
+ ALL_WOMB_BOSSES_SET,
506
+ BLUE_WOMB_BOSSES_SET,
507
+ ALL_STAGE_10_BOSSES_SET,
508
+ ALL_STAGE_11_BOSSES_SET,
509
+ THE_VOID_BOSSES_SET,
510
+ HOME_BOSSES_SET,
511
+ );
512
+
513
+ export const ALL_BOSSES_EXCLUDING_STORY_BOSSES_SET: ReadonlySet<string> =
514
+ (() => {
515
+ // Since story bosses are stored by entity type, we copy the existing bosses and filter them (to
516
+ // avoid having to hard-code story boss variants).
517
+ const allBossesExcludingStoryBossesSet = copySet(ALL_BOSSES_SET);
518
+ const allBosses = [...ALL_BOSSES_SET.values()];
519
+ for (const entityTypeVariantString of allBosses) {
520
+ const tuple = parseEntityTypeVariantString(entityTypeVariantString);
521
+ assertDefined(
522
+ tuple,
523
+ "Failed to parse a boss tuple when constructing the story boss set.",
524
+ );
525
+
526
+ const [entityType, _variant] = tuple;
527
+ if (STORY_BOSSES_SET.has(entityType)) {
528
+ allBossesExcludingStoryBossesSet.delete(entityTypeVariantString);
529
+ }
501
530
  }
502
- }
503
531
 
504
- return allBossesExcludingStoryBossesSet;
505
- }
532
+ return allBossesExcludingStoryBossesSet;
533
+ })();