Curses
Functions
getCurseIDByName
▸ getCurseIDByName(name
): LevelCurse
Helper function to get the actual bit flag for modded curses.
Will throw a run-time error if the provided curse does not exist.
Use this over the Isaac.GetCurseIdByName
method because that will return an integer instead of
a bit flag.
Parameters
Name | Type |
---|---|
name | string |
Returns
LevelCurse
Defined in
packages/isaacscript-common/src/functions/curses.ts:13
hasCurse
▸ hasCurse(...curses
): boolean
Helper function to check if the current floor has a particular curse.
This function is variadic, meaning that you can specify as many curses as you want. The function will return true if the level has one or more of the curses.
Under the hood, this function uses the Level.GetCurses
method.
Parameters
Name | Type |
---|---|
...curses | readonly LevelCurseValue [] |
Returns
boolean