mirror of https://github.com/axmolengine/axmol.git
Merge pull request #12475 from samuele3hu/v3_7_test
[ci skip]Fix the some test cases error about Lua
This commit is contained in:
commit
b08325dd5b
|
@ -1035,8 +1035,8 @@ end
|
|||
function CameraArcBallDemo:updateCameraTransform()
|
||||
-- body
|
||||
local trans = cc.mat4.createTranslation(cc.vec3(0.0, 10.0, self._distanceZ), cc.mat4.createIdentity())
|
||||
local rot = cc.mat4.createRotation(self._rotationQuat, cc.mat4.createIdentity())
|
||||
local center = cc.mat4.createTranslation(self._center, cc.mat4.createIdentity())
|
||||
local rot = cc.mat4.new(cc.mat4.createRotation(self._rotationQuat, cc.mat4.createIdentity()))
|
||||
local center = cc.mat4.new(cc.mat4.createTranslation(self._center, cc.mat4.createIdentity()))
|
||||
local result = cc.mat4.new(center:multiply(rot)):multiply(trans)
|
||||
|
||||
self._camera:setNodeToParentTransform(result)
|
||||
|
|
|
@ -1243,7 +1243,7 @@ function LabelCharMapTest.create()
|
|||
label2:setPosition( cc.p(10,160) )
|
||||
label2:setOpacity( 32 )
|
||||
|
||||
local label3 = cc.Label:createWithCharMap("fonts/tuffy_bold_italic-charmap.png", 48, 64, 32)--32 means Space key
|
||||
local label3 = cc.Label:createWithCharMap("fonts/tuffy_bold_italic-charmap.plist")--32 means Space key
|
||||
label3:setString("123 Test")
|
||||
layer:addChild(label3, 0, kTagSprite3)
|
||||
label3:setPosition(cc.p(10,220))
|
||||
|
@ -1388,13 +1388,13 @@ function LabelCharMapColorTest.create()
|
|||
Helper.titleLabel:setString("New Label + CharMap")
|
||||
Helper.subtitleLabel:setString("Opacity + Color should work at the same time")
|
||||
|
||||
local label1 = cc.Label:createWithCharMap( "fonts/tuffy_bold_italic-charmap.png", 48, 64, 32)--32 means Space key
|
||||
local label1 = cc.Label:createWithCharMap("fonts/tuffy_bold_italic-charmap.plist")--32 means Space key
|
||||
layer:addChild(label1, 0, kTagSprite1)
|
||||
label1:setAnchorPoint(cc.p(0.0, 0.0))
|
||||
label1:setPosition( cc.p(10,100) )
|
||||
label1:setOpacity( 200 )
|
||||
|
||||
local label2 = cc.Label:createWithCharMap("fonts/tuffy_bold_italic-charmap.png", 48, 64, 32)--32 means Space key
|
||||
local label2 = cc.Label:createWithCharMap("fonts/tuffy_bold_italic-charmap.plist")--32 means Space key
|
||||
layer:addChild(label2, 0, kTagSprite2)
|
||||
label2:setAnchorPoint(cc.p(0.0, 0.0))
|
||||
label2:setPosition( cc.p(10, 200) )
|
||||
|
|
|
@ -61,9 +61,8 @@ local function baseInit(self)
|
|||
local children = ps:getChildren()
|
||||
for i= 1, #children do
|
||||
local child = children[i]
|
||||
if nil ~= child then
|
||||
--UNDO
|
||||
count = count + #(child:getParticlePool():getActiveParticleList())
|
||||
if nil ~= child and nil ~= child.getAliveParticleCount then
|
||||
count = count + child:getAliveParticleCount()
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue