大约有 308 项符合查询结果, 库内数据总量为 30,935 项。 (搜索耗时: 0.0050 秒)
Error: Layer value can be null. 一开始正常后来把 Laya.stage.addChild(Gamesce.gameFig); 改为Laya.stage.addChildAt(Gamesce.gameFig,1); 报这个错误,再改为Laya.stage.addChild(Gamesce.gameFig); 游戏一直报Error: Layer value can be null.,游戏崩了。。。。。 有大神知...
来源: Laya_社区 发布时间: 20181102
...tmpVector = new Laya.Vector3(0, 0, 0); this.scene = Laya.stage.addChild(new Laya.Scene3D()); //初始化照相机 let camera = this.scene.addChild(new Laya.Camera(0, 0.1, 100)); camera.transform.translate(new Laya.Vector3(0, 6, 9.5)); camer...
来源: Laya_社区 发布时间: 20191009
...aleMode = "showall"; //添加Sprite var sp = new Laya.Sprite(); Laya.stage.addChild(sp); //将sp移动到横坐标400,纵坐标300的位置 sp.pos(400,300); //绘制两条在sp的原点交叉的直线 sp.graphics.drawLine(-50,0,50,0,'#00ff00',1); sp.graphics.drawLine(0,-50,0,50,'#00ff00',1); //绘...
来源: Laya_社区 发布时间: 20180524
...信 whzooo - 王掌柜 赞同来自: maskimg=new Sprite(); //addChild(maskimg); photoimg=new Sprite(); Laya.stage.addChild(photoimg); photoimg.mask=maskimg; photoimg.loadImage(imgn,0,0,500,500); Laya.timer.once(1000, this, function():void{ maskimg.lo...
来源: Laya_社区 发布时间: 20160923
..."rock"); var gids = layer.getDrawSprite(5,5); var coinS = new coin(); gids.addChild(coinS); gids.x = 200; gids.y = 100; layer.addChild(gids) 还是说 我的思路本来就是错的?那如果地图上有些物体是随机出现的 怎么搞 瓦片地图的对象层最大的作用是什么 如...
来源: Laya_社区 发布时间: 20171008
...wSomething() { sp = new Sprite(); Laya.stage.addChild(sp); // 绘制这些坐标.会出现如下图的错误 sp.graphics.drawPoly(0, 0, [285,285,-1,285,-1,-1,285,-1,285,213.24324324324323,240,240,240,260,260,260,285,259.12280701754383], "#ffff...
来源: Laya_社区 发布时间: 20171117
... this.down2) Laya.stage.on(Laya.Event.MOUSE_UP, this, this.up2) Laya.stage.addChild(this.ps); } down2() { this.a = Laya.stage.mouseX; this.b = Laya.stage.mouseY; console.log("鼠标点击的点" + this.a, this.b) Laya.stage.on(Laya.Event.MOUSE_MOVE, this, this.move2) } move2() { this.path.push(Laya....
来源: Laya_社区 发布时间: 20170721
...le is not defined. /LayaAirTest/src/LayaAirTest.as (22):warning:Laya.stage.addChild This variable is not defined. 代码如下: package { import laya.display.Text; public class LayaAirTest { public function LayaAirTest() { Laya....
来源: Laya_社区 发布时间: 20170429
...ar sprite = new Laya.Sprite(); sprite.loadImage('comp/bg.png'); Laya.stage.addChild(sprite); } 上面这段代码如果把Laya.stage.size这行的注释去掉,运行时不能正常显示图片。请问下对stage是否有大小限制,如何放开这个限制。 这里用的scaleMode是Laya.Stage...
来源: Laya_社区 发布时间: 20170803
...anelRotationTest(Laya.Sprite); testSpriteRotation.pos(300,260); Laya.stage.addChild(testSpriteRotation); var testPanelRotation:PanelRotationTest = new PanelRotationTest(Laya.Panel); testPanelRotation.pos(1000,260); Laya.stage.addChild(testPanelRotation); Laya.Tween.to(testPanelRotation,{rotation:720...
来源: Laya_社区 发布时间: 20170814