Skip to content

Revive

isDamageToPlayerFatal(player, amount, source, lastDamageGameFrame): boolean

Defined in: packages/isaacscript-common/src/functions/revive.ts:25

Uses the player’s current health and other miscellaneous things to determine if incoming damage will be fatal.

EntityPlayer

int

EntityRef

int | undefined

boolean


willMysteriousPaperRevive(player): boolean

Defined in: packages/isaacscript-common/src/functions/revive.ts:123

Assuming that we are on the frame of fatal damage, this function returns whether Mysterious Paper would rotate to Missing Poster on the frame that the “Game Over” screen would appear (which would subsequently save the player from fatal damage).

Mysterious Paper rotates between the 4 items on every frame, in order. The formula for whether Mysterious Paper be Missing Power is: gameFrameCount % 4 === 3

EntityPlayer

boolean


willPlayerRevive(player): boolean

Defined in: packages/isaacscript-common/src/functions/revive.ts:148

The EntityPlayer.WillPlayerRevive method does not properly account for Mysterious Paper, so use this helper function instead for more robust revival detection.

EntityPlayer

boolean


willReviveFromHeartbreak(player): boolean

Defined in: packages/isaacscript-common/src/functions/revive.ts:168

Helper function to determine if the player will be revived by the Heartbreak collectible if they take fatal damage. This is contingent on the character that they are playing as and the amount of broken hearts that they already have.

EntityPlayer

boolean


willReviveFromSpiritShackles(player): boolean

Defined in: packages/isaacscript-common/src/functions/revive.ts:186

Helper function to determine if the Spirit Shackles item is in an enabled state. (It can be either enabled or disabled.)

EntityPlayer

boolean