大约有 310 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0054 秒)
...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
...t(fontName); } createText(font) { let txt = new Laya.Text(); Laya.stage.addChild(txt); txt.width = 250; txt.wordWrap = true; txt.text = "Do one thing at a time, and do well."; txt.font = font; // 文本的字体名称,以字符串形式表示 txt.leading = 5; // 垂直行间距 txt.pos(Laya.sta...
来源: Laya_社区 发布时间: 20190221
...se.linearOut,Laya.Handler.create(this,this.removeball,[ball])); Laya.stage.addChild( ball ); } } public removeball( ball:Laya.Sprite ){ Laya.stage.removeChild(ball); // console.log("rmove ball") } public getObj():Laya.Sprite { for( let i:number = 0 ; i < this.balls.length;i++ ){ if( !this.balls[i...
来源: Laya_社区 发布时间: 20180226
...Laya3D01/Laya3D01.ls",Laya.Handler.create(null,function(scene){ Laya.stage.addChild(scene); //创建摄像机(横纵比,近距裁剪,远距裁剪) var camera= new Laya.Camera( 0, 0.1, 1000); //加载到场景 scene.addChild(camera); //移动摄像机位置 camera.transform.position=new Laya.Vect...
来源: Laya_社区 发布时间: 20180919
...CC"; this.text.x=Math.random()*550; this.text.y=Math.random()*400; textBox.addChild(this.text); } Laya.stage.addChild(textBox); } } 下面是笔者电脑上的运行时截图,FPS稳定于52上下。 (图2-1) 当我们对文字所在的容器设置为cacheAs之后,如下面的例子所示,...
来源: Laya3.0_文档 发布时间: 20251010
...loadScene("test/TestScene.scene"); //添加3D场景 var scene = Laya.stage.addChild(new Laya.Scene3D()); //添加照相机 var camera = (scene.addChild(new Laya.Camera(0, 0.1, 100))); camera.transform.translate(new Laya.Vector3(0, 3, 3)); camera.transform.rotate(new Laya.Vector3(-30, 0, 0), true, fa...
来源: Laya_社区 发布时间: 20201021
...var s:sprite = new sprite(); s.skin = "图片路径"; laya.stage.addChild(s); } 2018-04-16 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 cyk123 相关问题 【屏幕适配】在LayaAir上面是竖屏,为什么到微信开...
来源: Laya_社区 发布时间: 20180416
...对齐参照物 let reference: Laya.Sprite = new Laya.Sprite(); Laya.stage.addChild(reference); reference.pos(0, 0); reference.size(Laya.stage.width, Laya.stage.height); reference.graphics.drawRect(0, 0, reference.width, reference.height, "#CCCCCC"); let tipElmt = Laya.Browser.createElement("img"); ...
来源: Laya_社区 发布时间: 20180802
... return; console.log("打开开放域",Laya.Browser.onMiniGame) Laya.stage.addChild(this._openZone); this._openZone.x = vx; this._openZone.y = vy; if(Laya.Browser.onMiniGame){ Laya.Browser.window.sharedCanvas.width = Laya.stage.designWidth; Laya.Browser.window.sharedCanvas.height = Laya.stage.design...
来源: Laya_社区 发布时间: 20200618
...{ sp = new Particle2D(settings); sp.emitter.start(); sp.play(); Laya.stage.addChild(sp); sp.x = Laya.stage.width / 2; sp.y = Laya.stage.height / 2; } })(); ---------------------------------------------------------------------------------------- ----------------------------------------------------...
来源: Laya_社区 发布时间: 20200229