(fix/texture): Desaturate state lost on SetTexture
Fixes #93 Also normalize SetDesaturated calls to use booleans instead of numeric flags. (cherry picked from commit 47dce3a9d5ba23c170f002b323a11ed2a5c5e206)
This commit is contained in:
@@ -1140,7 +1140,7 @@ end
|
||||
local function setTexture(self, ...)
|
||||
local apply = self._SetTexture(self, ...)
|
||||
if self.isDesaturated ~= nil then
|
||||
self:_SetDesaturated(self.isDesaturated)
|
||||
self:_SetDesaturated(self.isDesaturated == 1)
|
||||
end
|
||||
return apply
|
||||
end
|
||||
|
||||
@@ -199,7 +199,7 @@ end
|
||||
local function setTexture(self, ...)
|
||||
local apply = self._SetTexture(self, ...)
|
||||
if self.isDesaturated ~= nil then
|
||||
self:_SetDesaturated(self.isDesaturated)
|
||||
self:_SetDesaturated(self.isDesaturated == 1)
|
||||
end
|
||||
return apply
|
||||
end
|
||||
|
||||
@@ -11,6 +11,7 @@ local default = {
|
||||
height = 200,
|
||||
color = {1, 1, 1, 1},
|
||||
blendMode = "BLEND",
|
||||
textureWrapMode = "CLAMPTOBLACKADDITIVE",
|
||||
rotation = 0,
|
||||
mirror = false,
|
||||
rotate = false,
|
||||
|
||||
Reference in New Issue
Block a user