Crash Saving with items in alcoves
Posted: Mon Jun 02, 2014 12:51 am
The code below works great...but causes an exception that crashes Grimrock if you try to save the game with anything in any of the alcoves. Thoughts? Has anyone had this issue before?
Code: Select all
function CheckAlcovesFull()
alcoveList = {"shieldAlcove1", "shieldAlcove2", "shieldAlcove3", "shieldAlcove4", "shieldAlcove5", "shieldAlcove6"}
for index = 1, #alcoveList do
foundAlcove = findEntity(alcoveList[index])
for alcoveItem in foundAlcove:containedItems() do
if alcoveItem.name == "shining_shield" then
shieldCounter:increment()
end
end
end
if shieldCounter:getValue() == 6 then
shieldsExitDoor:open()
else
shieldCounter:reset()
end
end