Hi,
I have a bunch of factory created objects . When I try to delete, a few are not getting deleted even though I can see that the object is getting the message to be deleted.
Util.lua
--block is object at position x and y on table called slots
if block.type == block_type.PLAIN then
print("REMOVED PLAIN at x "..x.." y "..y)
msg.post(block.id, M.REMOVE)
slots[block.x][block.y] = nil
end
block.script
function on_message(self, message_id, message, sender)
if message_id == REMOVE then
print("DELETE col "..self.x.." row "..self.y)
go.delete()
end
end
Any and all help deeply appreciated. Thanks.