大约有 169 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0057 秒)
...new 出的带有 PhysicsCollider 的正方体模型报错 this.box = scene.addChild(new Laya.MeshSprite3D(new Laya.BoxMesh(1, 1, 1))) as Laya.MeshSprite3D; this.box.addComponent(Laya.PhysicsCollider); this.box.destroy();引擎版本 LayaAirIDE2.0_beta.5 报错: Uncaught TypeError: Cannot read prop...
来源: Laya_社区 发布时间: 20190118
...j.Curr_Game_ImagePath + "hall/room_bg.png"); this.roombg.pos(50,150); this.addChild(this.roombg); var button = new Sprite(); button.loadImage($mj.Curr_Game_ImagePath + "hall/room_jiesan.png"); button.pos(300, 0); this.roombg.addChild(button); button.on(Event.MOUSE_DOWN, this, function (e) { list.add...
来源: Laya_社区 发布时间: 20170920
...3D =Laya.Sprite3D.load("LayaMonkey/LayaMonkey.lh") as Laya.Sprite3D; scene.addChild(layaMonkey); layaMonkey.transform.localScale = new Laya.Vector3(0.001,0.001,0.001); layaMonkey.transform.localPosition = new Laya.Vector3(0,1,0); layaMonkey.transform.rotate(new Laya.Vector3(0,-Math.PI/2,0)); //移...
来源: Laya_社区 发布时间: 20180112
...Label = res.create(); //添加预制体Label字体到box节点下 this.box.addChild( label ); } ); } } 运行效果如图3-6所示 (图3-6) 3.2 3D预制体 3D预制体的使用过程同2D预制体一样,在这里我们就不介绍如何制作预制体了,通过下面的示例来看看3D预...
来源: Laya3.0_文档 发布时间: 20241014
...SceneMonkey.ls",Handler.create(this,function(res:Scene3D):void{ Laya.stage.addChild(res); //用于挂点的精灵 var box: MeshSprite3D = new MeshSprite3D(PrimitiveMesh.createBox(1,1,1)); var material: BlinnPhongMaterial = new BlinnPhongMaterial(); Texture2D.load("res/layabox.png", Handler.create(th...
来源: Laya2.0_文档 发布时间: 20210714
...Label = res.create(); //添加预制体Label字体到box节点下 this.box.addChild( label ); } ); } } 运行效果如图3-6所示 (图3-6) 3.2 3D预制体 3D预制体的使用过程同2D预制体一样,在这里我们就不介绍如何制作预制体了,通过下面的示例来看看3D预...
来源: Laya3.0_文档 发布时间: 20251105
...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
...ing = new myRing(600, 300, 18, "#087729", 40, "#a87729"); Laya.stage.addChild(ring.sprite); } laya_test(); 代码如上,点击绘制的圆环,无触发事件 使用的库为LayaAirJS_1.5.5_beta,库内无修改 laya air引擎使用过程中,经常发现各种不触发事件的...
来源: Laya_社区 发布时间: 20161221
...e)); } onComplete(){ //创建场景 var scene = Laya.stage.addChild(new Laya.Scene3D()); //创建相机 var camera = new Laya.Camera(0, 0.1, 100); scene.addChild(camera); //设置相机的名称 camera.na...
来源: Laya_社区 发布时间: 20190605
...(0, 0, this.width, this.height); this.mask.optimizeScrollRect = true; this.addChild(this.mask); } this.initContent = function () { this.content = new Box(); this.content.width = this.width; this.content.autoSize = true; this.content.y = this.scrollMode == DOWN_TO_TOP ? this.height : 1; this.mask.add...
来源: Laya_社区 发布时间: 20161118