isaacscript-common 1.0.474 → 1.0.475
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -178,7 +178,7 @@ function spawnAllEntities(self, jsonRoom, seed, verbose)
|
|
|
178
178
|
if entityType >= 1000 then
|
|
179
179
|
if verbose then
|
|
180
180
|
log(
|
|
181
|
-
((((((("Spawning
|
|
181
|
+
((((((("Spawning grid entity " .. tostring(entityType)) .. ".") .. tostring(variant)) .. " at: (") .. tostring(x)) .. ", ") .. tostring(y)) .. ")"
|
|
182
182
|
)
|
|
183
183
|
end
|
|
184
184
|
spawnGridEntity(nil, entityType, variant, x, y)
|
|
@@ -186,7 +186,7 @@ function spawnAllEntities(self, jsonRoom, seed, verbose)
|
|
|
186
186
|
seed = nextSeed(nil, seed)
|
|
187
187
|
if verbose then
|
|
188
188
|
log(
|
|
189
|
-
((((((((("Spawning
|
|
189
|
+
((((((((("Spawning normal entity " .. tostring(entityType)) .. ".") .. tostring(variant)) .. ".") .. tostring(subType)) .. " at: (") .. tostring(x)) .. ", ") .. tostring(y)) .. ")"
|
|
190
190
|
)
|
|
191
191
|
end
|
|
192
192
|
local entity = spawnNormalEntity(nil, entityType, variant, subType, x, y, seed)
|
|
@@ -76,10 +76,10 @@ function ____exports.setPlayerHealth(self, player, playerHealth)
|
|
|
76
76
|
player:AddEternalHearts(playerHealth.eternalHearts)
|
|
77
77
|
local soulHeartsRemaining = playerHealth.soulHearts
|
|
78
78
|
do
|
|
79
|
-
local i =
|
|
80
|
-
while i
|
|
81
|
-
local heartType = playerHealth.soulHeartTypes[i]
|
|
82
|
-
local isHalf = (playerHealth.soulHearts + (playerHealth.boneHearts * 2)) < (i * 2)
|
|
79
|
+
local i = 0
|
|
80
|
+
while i < #playerHealth.soulHeartTypes do
|
|
81
|
+
local heartType = playerHealth.soulHeartTypes[i + 1]
|
|
82
|
+
local isHalf = (playerHealth.soulHearts + (playerHealth.boneHearts * 2)) < ((i + 1) * 2)
|
|
83
83
|
local addAmount = 2
|
|
84
84
|
if (isHalf or (heartType == HeartSubType.HEART_BONE)) or (soulHeartsRemaining < 2) then
|
|
85
85
|
addAmount = 1
|