• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 1,442 项符合查询结果, 库内数据总量为 30,906 项。 (搜索耗时: 0.0059 秒)

921. 求助。资源加载问题,按照官方demo出现问题 [ 67%]

...ivate onLoadComplete(){     const scene = new Laya.Scene3D()     Laya.stage.addChild(scene)          const prefab = Laya.loader.getRes(url)     scene.addChild(prefab) } 2020-03-13 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的...

来源: Laya_社区 发布时间: 20200313

922. worldroot [ 67%]

worldroot let root = new Laya.Sprite(); Laya.stage.addChildAt(root, 0);   Laya.Physics.I.worldRoot = root;   Laya.stage.on(Laya.Event.CLICK, this, () => { Laya.Physics.I.worldRoot.x -= 50; });   设置worldRoot = 一个新的sprite后, 移动world root ,物理世界不会跟着一起移...

来源: Laya_社区 发布时间: 20181126

923. 请问如何获取触屏上两个或者更多位置的坐标 [ 67%]

...   this.preRadian = Math.atan2(                     touches[0].stageY - touches[1].stageY,                     touches[0].stageX - touches[1].stageX);                 Laya.stage.on(Event.MOUSE_MOVE, this, this.onMouseMove);             }         }         p...

来源: Laya_社区 发布时间: 20171201

924. 自己创建的box作为tab,为啥没有点击事件啊? [ 67%]

...t, "MyBootClass", MyPage2UI);     var UI = new MyBootClass();     Laya.stage.addChild(UI); } function MyBoot() {     MyBoot.super(this);     this.MyTab.selectHandler = new Laya.Handler(this, onSelect, null, false);//设置 tab 的选择项发生改变时执行的处理器。     console.l...

来源: Laya_社区 发布时间: 20160722

925. 官方DynamicBatchTest照做为什么动态合不了批? [ 67%]

...了批? class DynamicBatchTest { constructor() { Laya3D.init(0, 0); Laya.stage.scaleMode = Laya.Stage.SCALE_FULL; Laya.stage.screenMode = Laya.Stage.SCREEN_NONE; Laya.Stat.show();   var scene = Laya.stage.addChild(new Laya.Scene3D()); scene.ambientColor = new Laya.Vector3(1, 1, 1);   var camera ...

来源: Laya_社区 发布时间: 20191112

926. 多次加载一个页面出现_$P为null的情况 [ 67%]

...tDeskNo(data.desk.deskNo); StorageHelper.setDeskSeat(data.ownSeatNo); Laya.stage.destroyChildren(); var playSence = new OnlinePlaySence(data); Laya.stage.addChild(playSence); },function(data){ console.log('加入游戏失败'); alert('加入游戏失败'); GameUnitls.showToast(data); }); }else{ aler...

来源: Laya_社区 发布时间: 20171219

927. 回调函数传递sprite3D问题 [ 67%]

...xp, 300/xp); msg1.pivot(msg1.width,msg1.height); msg1.pos(_outPos.x / Laya.stage.clientScaleX,(_outPos.y / Laya.stage.clientScaleY)-20); }我这样写 为什么在freshBubble里拿不到这个?有示例可以参考一下吗?感激不尽 2018-01-05 添加评论 免费帖 --> 分享 微博 QZONE ...

来源: Laya_社区 发布时间: 20180105

928. Laya2.1 加载spine动画会随机出现抖动 [ 67%]

...答一下 //加载spine动画 this.skeleton = new Laya.Skeleton ();  Laya.stage.addChild(this.skeleton);  this.skeleton.pos(parseInt (npcPos[0]), parseInt (npcPos[1]));  this.skeleton.load (this.curNpcInfo.npcPath); 附件 : --> 70003.zip 2019-05-16 添加评论 免费帖 --> 分享 微博 QZONE ...

来源: Laya_社区 发布时间: 20190516

929. laya.display.Stage_API3.0 [ 67%]

...Protected All Inherited Externals Only exported Menu Globals "laya/display/Stage" Stage Class Stage Stage 是舞台类,显示列表的根节点,所有显示对象都在舞台上显示。通过 Laya.stage 单例访问。 Stage提供几种适配模式,不同的适配模式会产生不同的画...

来源: Laya3.0_api 发布时间: 20231115

930. laya.ui.Dialog_API3.0 [ 67%]

...() { Laya.init(640, 800);//设置游戏画布宽高、渲染模式。 Laya.stage.bgColor = "#efefef";//设置画布的背景颜色。 Laya.loader.load("resource/ui/btn_close.png", Handler.create(this, onLoadComplete));//加载资源。 } private function onLoadComplete():void { dialog = new Dialog_I...

来源: Laya3.0_api 发布时间: 20231115