Skip to content

Commit 3de629a

Browse files
committed
sub allocators inherit parent's settigns except size
1 parent 6c83b16 commit 3de629a

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

tools/allocator.lua

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,12 @@ end
101101

102102
function A:allocateArea(w,h)
103103
if self.objectMask then
104-
local sub_settings = self.settings
104+
local sub_settings = {}
105+
for k,v in pairs(self.settings) do
106+
sub_settings[k] = v
107+
end
105108
sub_settings.size = {w, h}
109+
106110
local sub = A:new(self.level, sub_settings)
107111
if self.settings.immediate then
108112
self:placeArea(sub)

0 commit comments

Comments
 (0)