UNPKG

isaac-typescript-definitions

Version:

TypeScript definitions for The Binding of Isaac: Repentance.

142 lines 3.79 kB
/** * Matches the `RoomDescriptor.FLAG_*` members of the `RoomDescriptor` class. In IsaacScript, we * reimplement this as an object instead, since it is cleaner. * * This is represented as an object instead of an enum due to limitations with TypeScript enums. (We * want this type to be a child of the `BitFlag` type.) * * @enum * @notExported * @rename RoomDescriptorFlag */ declare const RoomDescriptorFlagInternal: { /** * Room is clear, don't spawn enemies when visiting. * * 1 << 0 (1) */ readonly CLEAR: number; /** * All pressure plates have been triggered in this room. This won't be set if there are no trigger * pressure plates in the first place. * * 1 << 1 (2) */ readonly PRESSURE_PLATES_TRIGGERED: number; /** * A Sacrifice Room has paid out. * * 1 << 2 (4) */ readonly SACRIFICE_DONE: number; /** * A Challenge Room has finished. * * 1 << 3 (8) */ readonly CHALLENGE_DONE: number; /** * Load Greed/Krampus instead of the room specified by the type & variant. * * 1 << 4 (16) */ readonly SURPRISE_MINIBOSS: number; /** * Pits in this room contain water. * * 1 << 5 (32) */ readonly HAS_WATER: number; /** * Play alternate boss music in this room. * * 1 << 6 (64) */ readonly ALT_BOSS_MUSIC: number; /** * Don't pay out with a reward when clearing this room. Used for traps that lock the player in the * room when triggered. * * 1 << 7 (128) */ readonly NO_REWARD: number; /** * Was flooded by an item (i.e. Flush). * * 1 << 8 (256) */ readonly FLOODED: number; /** * Complete darkness. * * 1 << 9 (512) */ readonly PITCH_BLACK: number; /** * Room spawned by Red Key. * * 1 << 10 (1024) */ readonly RED_ROOM: number; /** * Treasure room transformed by Devil's Crown. * * 1 << 11 (2048) */ readonly DEVIL_TREASURE: number; /** * Use an alternate backdrop. (This is used by some floors such as Dross and Ashpit.) * * 1 << 12 (4096) */ readonly USE_ALTERNATE_BACKDROP: number; /** * The room is covered in cursed mist; the player is temporarily reduced to base items and stats. * * 1 << 13 (8192) */ readonly CURSED_MIST: number; /** * Mama Mega has activated in this room. * * 1 << 14 (16384) */ readonly MAMA_MEGA: number; /** * Don't generate walls (for Beast arena). * * 1 << 15 (32768) */ readonly NO_WALLS: number; /** * Rotgut's heart was killed, immediately play Rotgut's death animation when reentering this room. * * 1 << 16 (65536) */ readonly ROTGUT_CLEARED: number; /** * A portal spawned by Lil Portal now links to this room; don't create more portals that link to * it. * * 1 << 17 (131072) */ readonly PORTAL_LINKED: number; /** * If walking into this room through a door, redirect to a Blue Womb room instead. (This is used * by Blue Key.) * * 1 << 18 (262144) */ readonly BLUE_REDIRECT: number; }; type RoomDescriptorFlagValue = BitFlag & { readonly __roomDescriptorFlagBrand: symbol; }; type RoomDescriptorFlagType = { readonly [K in keyof typeof RoomDescriptorFlagInternal]: RoomDescriptorFlagValue; }; export declare const RoomDescriptorFlag: RoomDescriptorFlagType; export type RoomDescriptorFlag = RoomDescriptorFlagType[keyof RoomDescriptorFlagType]; export declare const RoomDescriptorFlagZero: BitFlags<RoomDescriptorFlagValue>; export {}; //# sourceMappingURL=RoomDescriptorFlag.d.ts.map