大约有 277 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0094 秒)
Laya_社区(197) Laya2.0_文档(34) Laya3.0_api(16) Laya3.0_文档(11) Laya2.0_api(6) Laya_示例(6) laya_api(4) Laya2.0_示例(3)
...UI drawUI(); // 创建显示角度的文本 createDegreesText(); Gyroscope.instance.on(Event.CHANGE, this, onOrientationChange); } function createCompass() { compassImg = new Sprite(); Laya.stage.addChild(compassImg); compassImg.loadImage(compassImgPath); compassImg.pivot(compassImg.width / 2, compa...
来源: Laya_示例 发布时间: 20260929
...I(); // // 创建显示角度的文本 this.createDegreesText(); Gyroscope.instance.on(Event.CHANGE, this, this.onOrientationChange); } // 方位指示器指向当前所朝方位 createCompass() { const Sprite = Laya.Sprite; compassImg = new Sprite(); Laya.stage.addChild(compassImg); compassImg.load...
来源: Laya2.0_示例 发布时间: 20260929
...n(){ //获取鼠标点击位置的屏幕坐标 this.point.x = MouseManager.instance.mouseX; this.point.y = MouseManager.instance.mouseY; //由点击的屏幕坐标产生射线 this.camera.viewportPointToRay(this.point, this.ray); //创建CannonHitResult对象来存储射线检测结果 var out = new...
来源: Laya2.0_文档 发布时间: 20210715
... WebGL); // 初始化蛇 initSnake(); // 监视加速器状态 Accelerator.instance.on(Laya.Event.CHANGE, this, monitorAccelerator); // 游戏循环 Laya.timer.frameLoop(1, this, animate); // 食物生产 Laya.timer.loop(3000, this, produceFood); // 游戏开始时有一个食物 produceFood(); })()...
来源: Laya_示例 发布时间: 20260929
...ebGL.enable();} 但在webgl.js 中Layanative2D.__init__()里面 LayaGL.instance.addGlobalValueDefine还是会报错, 此时的Laya.instance._nativeObj显示是webgl,但是_nativeObj.addGlobalValueDefine不存在 if (Render.isConchApp){ /*__JS__ */CommandEncoder=window.GLCommandEncoder; /*__J...
来源: Laya_社区 发布时间: 20200218
...务器上的H5,播放具有中文名的音乐时报错 Native下LayaGL.instance无法获取 HTML文本同一行中的中文和英文没有水平对齐 请问LayaNative2.0能否做到每个子游戏分别打包zip,在Native中解包并跳转? native下字体模糊 打包native报错 Native 在i...
来源: Laya_社区 发布时间: 20181105
...O登录:" + data); callBack(res); }, fail: function (res) { LogicManager.instance.toLoginSucc(); console.log("登陆失败:" + JSON.stringify(res)); } }); 登陆失败:{"code":7605,"msg":"没有 数据","data":null} 请问是什么原因啊 2019-08-23 添加评论 免费帖 --> 分享 微博 ...
来源: Laya_社区 发布时间: 20190823
...开这个源码呢? 请问LayaFlash是否考虑开源? Native下LayaGL.instance无法获取 有没有开源的游戏项目框架 Runtime照着视频做运行不了,求解 native下字体模糊 请问LayaNative2.0能否做到每个子游戏分别打包zip,在Native中解包并跳转? laya2....
来源: Laya_社区 发布时间: 20181218
重力感应在手机没有回调问题 Accelerator.instance.on(Event.CHANGE, this, this.monitorAccelerator); monitorAccelerator(acceleration, accelerationIncludingGravity, rotationRate, interval) 在PC端调试回调中accelerationIncludingGravity为空,手机扫码调试。次函数不会被...
来源: Laya_社区 发布时间: 20190928
...8"; // 初始化蛇 this.initSnake(); // 监视加速器状态 Accelerator.instance.on(Event.CHANGE, this, this.monitorAccelerator); // 游戏循环 Laya.timer.frameLoop(1, this, this.animate); // 食物生产 Laya.timer.loop(3000, this, this.produceFood); // 游戏开始时有一个食物 this.prod...
来源: Laya2.0_示例 发布时间: 20260929