Skip to content

Item Pool

getDefaultCollectibleTypesInItemPool(itemPoolType): ReadonlySet<CollectibleType>

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:50

Helper function to get the collectibles that are in a particular item pool at the beginning of a vanilla run.

ItemPoolType

ReadonlySet<CollectibleType>


getDefaultItemPoolsForCollectibleType(collectibleType): readonly ItemPoolType[]

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:63

Helper function to get the item pools that a particular collectible starts in at the beginning of a vanilla run.

This function will automatically account for Greed Mode. In other words, it will not return the “normal” item pools when playing in Greed Mode.

CollectibleType

readonly ItemPoolType[]


getItemPoolName(itemPoolType): string

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:86

Helper function to get the name for an item pool type as it appears in the “itempools.xml” file.

ItemPoolType

string


getRandomItemPool(seedOrRNG): ItemPoolType

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:102

Helper function to get a random item pool. This is not as simple as getting a random value from the ItemPoolType enum, since ItemPoolType.SHELL_GAME (7) is not a real item pool and the Greed Mode item pools should be excluded if not playing in Greed Mode.

If you want to get an unseeded item pool, you must explicitly pass undefined to the seedOrRNG parameter.

RNG | Seed | undefined

The Seed or RNG object to use. If an RNG object is provided, the RNG.Next method will be called. If undefined is provided, it will default to a random seed.

ItemPoolType


isCollectibleTypeInDefaultItemPool(collectibleType, itemPoolType): boolean

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:116

Helper function to check if a particular collectibles is in a particular item pool at the beginning of a vanilla run.

CollectibleType

ItemPoolType

boolean


removeCollectibleFromPools(…collectibleTypes): void

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:130

Helper function to remove one or more collectibles from all item pools.

This function is variadic, meaning you can pass as many collectible types as you want to remove.

…readonly CollectibleType[]

void


removeTrinketFromPools(…trinketTypes): void

Defined in: packages/isaacscript-common/src/functions/itemPool.ts:145

Helper function to remove one or more trinkets from all item pools.

This function is variadic, meaning you can pass as many trinket types as you want to remove.

…readonly TrinketType[]

void