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

大约有 1,362 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0053 秒)

181. 游戏铺满固定大小容器,火狐和谷歌正常,edge会有滚动条? [ 80%]

...wser.clientHeight){                         console.log("横屏",this.lastClientWidth);                         if(Laya.stage.scaleMode != Laya.Stage.SCALE_SHOWALL){                             Laya.stage.scaleMode = Laya.Stage...

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

182. layacmd mac 系统安装不上,急 [ 80%]

...m ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /var/root/.npm/_logs/2018-05-08T04_07_13_726Z-debug.log   环境: mac 10.13.4 (17E202)   尝试了  sudo npm install layacmd -g sudo -s...

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

183. 开放数据域组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 80%]

....setUserCloudStorage({ KVDataList: KVDataList, success: () => { console.log("数据保存成功") }, fail: () => { console.log("数据保存失败") }, complete: () => { console.log("执行调用结束回调") } }); } } 然后是getFriendCloudStorage方法,来到开放数据域的index.js...

来源: Laya3.0_文档 发布时间: 20251010

184. 继承Scene没有onEnable [ 80%]

...super();     }     public onAwake():void{         console.log(1111);     } }   2.继承Sprite 执行后会有onAwake         let t = new tt();         Laya.Scene.root.addChild(t);     } } //激活启动类 new Main();  class tt extends Laya.Sprite{     ...

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

185. js调用android的java代码失败。NoSuchMethodException [ 80%]

...= PlatformClass.createClass("demo.JSBridge")//创建脚步代理 } console.log("test step ~~~~~~~~~~~~~~~~~~~~~~1") if(os == "Conch-ios"){ }else if (os == "Conch-android") { console.log("test step ~~~~~~~~~~~~~~~~~~~~~~2") if(bridge){ console.log("test step ~~~~~~~~~~~~~~~~~~~~~~3") bridge.call("tes...

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

186. ProtocolBuffer通信 · LayaAir3.3 · 引擎文档 · LAYABOX [ 80%]

...ass() export class ProtobufDemo extends Laya.Script { onEnable() { console.log("Game start"); } } 2.2 Protobuf示例脚本 引入了protobuf模块就可以直接在项目中使用了,这里我们写了一个简单的示例DEMO,完整代码如下: // src/ProtobufDemo.ts // 引入生成的 proto...

来源: Laya3.0_文档 发布时间: 20251010

187. Laya.loader.create 加载进度问题 [ 80%]

...ading)); } ModelManager.prototype.onCreateComplete = function () { console.log("onCreateComplete"); var pipe = Laya.loader.getRes("res/Pipe/Pipe/a.lh"); console.log("pipe", pipe); } ModelManager.prototype.onAssetsLoading = function (progress) { console.log("progress = ",progress); } 打印出来的...

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

188. js socket 连接不上 [ 80%]

...var io = require('socket.io').listen(server); server.listen(8888); console.log("服务器启动"); io.on('connection', function (ws) { console.log('客户端连接成功!'); ws.on('foo', function(data){ console.log(data); }); }); 自己写的html页面 <!DOCTYPE html> <html> <head&g...

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

189. Laya.Byte使用getUint16读取错误 [ 79%]

...Byte使用getUint16读取错误 var bytes1 = new Laya.Byte([0,8]); console.log('++',bytes1.getUint8(),bytes1.getUint8()); var bytes2 = new Laya.Byte([0,8]); console.log('++',bytes2.getUint16()); var bytes3 = new Laya.Byte([0,8,0,0]); console.log('++',bytes3.getUint32());   采用上面测试代码...

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

190. RopeJoint代码动态创建 无法设置otherbody [ 79%]

...Laya.RopeJoint);         this.rope.otherBody=lala;         console.log(lala);         let collider:Laya.CircleCollider=this.owner.getComponent(Laya.CircleCollider);         this.rope.otherAnchor=["540","1060"];         this.rope.maxLength=286;         console.log(this.owner);...

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