大约有 1,562 项符合查询结果, 库内数据总量为 31,671 项。 (搜索耗时: 0.0064 秒)
... txt.y = 100; txt.fontSize = 50; txt.on("click", this, onFunc); Laya.stage.addChild(txt); } private function onFunc(e:Event):void { var arr:Array = e.touches; console.log("e.touchId="+e.touchId); console.log("arr[0]"+arr[0]); } } } 输出为: 不明白touches属性数组里面存储的...
来源: Laya_社区 发布时间: 20170519
请问下如何将当前Sprite进行截图? 现在有一个Sprite,addChild了字体,按钮和其他各种子对象,现在想要对这个Sprite进行截图,然后作为一张图片发送到服务端。类似flash的BitmapData的draw方法,该如何实现? 2017-04-14 添加评论 免费...
来源: Laya_社区 发布时间: 20170414
... //添加到舞台 Laya.stage.addChild(img); //加载图片" img.loadImage("/res/atlas/game/bg.png",50,50,130,35); I:\MyDream\Dream\bin-debug\h5\res\atlas\game\bg.png 这个是图片地址 2017-03-07 添加...
来源: Laya_社区 发布时间: 20170307
...a(TiledMapManager.Instance.TiledMap); gsp.updatePos(); mapLayer._childs[0].addChild(gsp); 附件 : --> bug.png 2018-08-10 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 Laya_Aaron 赞同来自: 第三方的官方...
来源: Laya_社区 发布时间: 20180810
...cle2D(settings); sp.emitter.start(); sp.play(); sp.x = 90; sp.y = 55; this.addChild(sp); } 还是会有几种颜色,我希望跟在IDE里预览的时候效果一样 只有一种 我这样设置再传入Particle2D不对吗? settings.colorComponentInter = true; 2016-12-30 添加评论 免费帖 --...
来源: Laya_社区 发布时间: 20161230
....0设置阴影的代码: var directionLight: Laya.DirectionLight = scene.addChild(new Laya.DirectionLight()) as Laya.DirectionLight; directionLight.color = new Laya.Vector3(0.6, 0.6, 0.6); directionLight.transform.worldMatrix.setForward(new Laya.Vector3(1, -1, 0)); directionLight.shadowMode = Laya...
来源: Laya_社区 发布时间: 20201105
有关Sprite3D使用lh资源文件的问题 var plane = this.scene.addChild(Laya.loader.getRes("res/LayaScene_plane/plane.lh")) as Laya.Sprite3D; 这样可以根据一个lh文件 来创建一个Sprite3D类型的对象。 那么请问,如果我写了一个类A,并继承与Laya.Sprite3D 我要怎...
来源: Laya_社区 发布时间: 20180227
...var sprite3D:Laya.Sprite3D = Laya.loader.getRes("res/room.lh");this.scene.addChild(sprite3D);} 2018-09-08 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 130*****543 相关问题 unity导出粒子文件问题 从unity导出的场景透贴...
来源: Laya_社区 发布时间: 20180817
...前仅限2.3.0) //灯光开启阴影 directionLight.shadow = true this.addChild(directionLight)2.可产生阴影的物体穿过平面,会在反向出现阴影,如图 // 穿过产生阴影 3.物体不能同时产生和接受阴影,否则会出现如图所示情况 //同时产生接...
来源: Laya_社区 发布时间: 20191129
...ure(Laya.loader.getRes(this.monkey2),100,50); //添加到舞台 Laya.stage.addChild(img); }求教一下Promise方式来实现这段代码应该写,谢谢 2017-08-25 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复...
来源: Laya_社区 发布时间: 20170825