local ____lualib = require("lualib_bundle")
local __TS__Class = ____lualib.__TS__Class
local __TS__ClassExtends = ____lualib.__TS__ClassExtends
local ____exports = {}
local ____isaac_2Dtypescript_2Ddefinitions = require("isaac-typescript-definitions")
local DamageFlag = ____isaac_2Dtypescript_2Ddefinitions.DamageFlag
local RoomType = ____isaac_2Dtypescript_2Ddefinitions.RoomType
local ____cachedClasses = require("core.cachedClasses")
local game = ____cachedClasses.game
local ____ModCallbackCustom = require("enums.ModCallbackCustom")
local ModCallbackCustom = ____ModCallbackCustom.ModCallbackCustom
local ____flag = require("functions.flag")
local hasFlag = ____flag.hasFlag
local ____shouldFire = require("shouldFire")
local shouldFirePlayer = ____shouldFire.shouldFirePlayer
local ____CustomCallback = require("classes.private.CustomCallback")
local CustomCallback = ____CustomCallback.CustomCallback
local v = {level = {numSacrifices = 0}}
____exports.PostSacrifice = __TS__Class()
local PostSacrifice = ____exports.PostSacrifice
PostSacrifice.name = "PostSacrifice"
__TS__ClassExtends(PostSacrifice, CustomCallback)
function PostSacrifice.prototype.____constructor(self)
    CustomCallback.prototype.____constructor(self)
    self.v = v
    self.shouldFire = shouldFirePlayer
    self.entityTakeDmgPlayer = function(____, player, _amount, damageFlags, _source, _countdownFrames)
        local room = game:GetRoom()
        local roomType = room:GetType()
        local isSpikeDamage = hasFlag(nil, damageFlags, DamageFlag.SPIKES)
        if roomType == RoomType.SACRIFICE and isSpikeDamage then
            local ____v_level_0, ____numSacrifices_1 = v.level, "numSacrifices"
            ____v_level_0[____numSacrifices_1] = ____v_level_0[____numSacrifices_1] + 1
            self:fire(player, v.level.numSacrifices)
        end
        return nil
    end
    self.customCallbacksUsed = {{ModCallbackCustom.ENTITY_TAKE_DMG_PLAYER, self.entityTakeDmgPlayer}}
end
return ____exports
