Fix error in event listener.
This commit is contained in:
parent
4f0f5dc8ad
commit
86d4338e34
|
@ -3,7 +3,7 @@ local sprt = require "abase-sprite"
|
|||
-- recolors all layers in the current sprite
|
||||
local function RecolorLayers()
|
||||
for i, layer in ipairs(app.sprite.layers) do
|
||||
sprt.setColor(layer)
|
||||
sprt.SetColor(layer)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -74,14 +74,19 @@ end
|
|||
|
||||
local function safeSetColor(layer, color)
|
||||
pixelValue = layer.color.rgbaPixel
|
||||
|
||||
--[[ print("safeSetColor: " .. pixelValue)
|
||||
print(BASE_COLOR.rgbaPixel)
|
||||
print(IGNORE_COLOR.rgbaPixel)
|
||||
print(IGNORE_SUBCOLOR.rgbaPixel)
|
||||
print(MERGE_COLOR.rgbaPixel)
|
||||
print(MERGE_SUBCOLOR.rgbaPixel) ]]
|
||||
if (pixelValue ~= BASE_COLOR.rgbaPixel and
|
||||
pixelValue ~= IGNORE_COLOR.rgbaPixel and
|
||||
pixelValue ~= IGNORE_SUBCOLOR.rgbaPixel and
|
||||
pixelValue ~= MERGE_COLOR.rgbaPixel and
|
||||
pixelValue ~= MERGE_SUBCOLOR.rgbaPixel) then
|
||||
print("DEBUG: not setting color")
|
||||
return
|
||||
--[[ print("DEBUG: not setting color")
|
||||
]] return
|
||||
end
|
||||
layer.color = color
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user