Comments.

This commit is contained in:
NathanSweet 2013-11-04 22:11:01 +01:00
parent fc16a47c1a
commit 35810a5961
2 changed files with 9 additions and 9 deletions

View File

@ -182,7 +182,7 @@ function spine.Skeleton.new (skeletonData, group)
local a = skeletonA * slot.a
if a and (image.lastA ~= a or not image.lastA) then
image.lastA = a
image.alpha = image.lastA
image.alpha = image.lastA -- 0-1 range, unlike RGB.
end
self.group:insert(image)

View File

@ -111,10 +111,10 @@ function SkeletonJson.new (attachmentLoader)
local color = slotMap["color"]
if color then
slotData:setColor(
tonumber(color:sub(1, 2), 16)/255,
tonumber(color:sub(3, 4), 16)/255,
tonumber(color:sub(5, 6), 16)/255,
tonumber(color:sub(7, 8), 16)/255
tonumber(color:sub(1, 2), 16) / 255,
tonumber(color:sub(3, 4), 16) / 255,
tonumber(color:sub(5, 6), 16) / 255,
tonumber(color:sub(7, 8), 16) / 255
)
end
@ -264,10 +264,10 @@ function SkeletonJson.new (attachmentLoader)
local color = valueMap["color"]
timeline:setFrame(
keyframeIndex, time,
tonumber(color:sub(1, 2), 16)/255,
tonumber(color:sub(3, 4), 16)/255,
tonumber(color:sub(5, 6), 16)/255,
tonumber(color:sub(7, 8), 16)/255
tonumber(color:sub(1, 2), 16) / 255,
tonumber(color:sub(3, 4), 16) / 255,
tonumber(color:sub(5, 6), 16) / 255,
tonumber(color:sub(7, 8), 16) / 255
)
readCurve(timeline, keyframeIndex, valueMap)
keyframeIndex = keyframeIndex + 1