local item = self.scrollView:getChildByTag(i)
local prop = self.universeProxy:getSomeByKindAndId(v.kind,v.id)
local back = UITools.getChild(item,"back")
local front = UITools.getChild(item,"front")
UICommon.loadExternalTexture(UITools.getChild(item,"front","Image_4"),prop.icon)
UITools.getChild(item,"front","Text_1"):setString(prop.name..v.count)
local dtime = 0
if i ~= self.seletedid then
dtime = 0.5
end
local act0 = cc.DelayTime:create(dtime)
local act1 = cc.OrbitCamera:create(0.25, 1, 0, 0, -90, 0, 0)
local act2 = cc.CallFunc:create(function ( ... )
local item = self.universeProxy:getSomeByKindAndId(info.items[1].kind,info.items[1].id)
self.stu:getChild("bbg"):setVisible(true)
self.stu:getChild("bbg","btext"):setString(item.name.." +"..info.items[1].count)
back:setVisible(false)
self.canClose = true
if i == self.seletedid then
UICommon.repeatScale(front)
end
end)
local seq1 = cc.Sequence:create(act0, cc.OrbitCamera:create(0.5, 1, 0, 0, 180, 0, 0))
local seq2 = cc.Sequence:create(act0, act1, act2)
front:runAction(seq1)
back:runAction(seq2)
网友评论