[]小游戏导入手机后Sprite.Mask没有正常显示
在电脑上,微信开发工具里好好的,导入手机里就不行了- -
Laya.loader.load(url, Handler.create(this, function () {
var t = Laya.loader.getRes(url)
var sp = new Sprite()
sp.graphics.drawTexture(t, 0, 0, 80, 80)
that.addChild(sp)
var cMask = new Sprite()
cMask.graphics.drawCircle(40, 40, 37, "#ff0000")
sp.mask = cMask
//sp.addChild(cMask)
//sp.removeChild(cMask)
sp.pos(7,14)
console.log(cMask.x, cMask.y)
}, null, "image"))
一个圆形的遮罩显示微信头像..
Laya.loader.load(url, Handler.create(this, function () {
var t = Laya.loader.getRes(url)
var sp = new Sprite()
sp.graphics.drawTexture(t, 0, 0, 80, 80)
that.addChild(sp)
var cMask = new Sprite()
cMask.graphics.drawCircle(40, 40, 37, "#ff0000")
sp.mask = cMask
//sp.addChild(cMask)
//sp.removeChild(cMask)
sp.pos(7,14)
console.log(cMask.x, cMask.y)
}, null, "image"))
一个圆形的遮罩显示微信头像..
没有找到相关结果
已邀请:
要回复问题请先登录
2 个回复
Aar0n
赞同来自:
流光鸣_
赞同来自: