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

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

141. Laya.loader.create 加载进度问题 [ 79%]

...AssetsLoading)); } 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

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

Laya.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

143. js socket 连接不上 [ 79%]

...r(app); 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> &l...

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

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

...mponent(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...

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

145. Error: 代码包大小为 5533 kb,上限为 4096 kb,请删除文件后重试? [ 79%]

...一个测试代码,压根就没有功能。 class Main { constructor() { console.log(Laya.Browser.width, Laya.Browser.height); this.current = { x: 0, y: Laya.Browser.height }; // Laya.stage.bgColor = "#3F51B5"; this.sp = new Laya.Sprite(); Laya.stage.addChild(this.sp); } render() { console.log("re...

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

146. Byte二进制读写(TypeScript-LayaAir基础篇(TS)-数据与通信) [ 79%]

...始读入byte中。省略其中的浮点数20.0和整数16 byte.pos = 0;// console.log(byte.readUTFString())//从byte中读出字符串。 ``` - 读取数据 **getByte**():number在字节流中读一个字节。 **getInt16**():number在当前字节偏移量位置处读取 Int16 值。 **getInt32**()...

来源: Laya2.0_文档 发布时间: 20210715

147. 3D场景跳转到2D场景问题 [ 79%]

...ner.name==="end"){ // this.owner.parent.removeSelf(); //删除自身场景 console.log(this.owner.parent) console.log(this.owner.parent.parent); //创建胜利的UI界面 let victoryScene=new VictoryScene(); Laya.stage.addChild(victoryScene);   this.isDelete=true;  // console.log(Scene3DControl.Ga...

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

148. 淘宝创意互动分包指南(TypeScript-小游戏适配文档-淘宝创意互动) [ 79%]

... { my.redirectTo({ url: "/subpackage1/page2/index", success: function () { console.log("success") }, fail: function (err) { console.log("2222", err) } }) } ``` 注意:在加载资源的时候,分包文件夹名称前也需要加“ / ” #### 2.2 资源分包 资源分包适合页面数量较多...

来源: Laya2.0_文档 发布时间: 20210715

149. 切换后台时,引擎如何判断是否停止定时器? [ 78%]

...rameLoop);     }      private onFrameLoop():void{         console.log("delta:",Laya.timer.delta);     }      private onFocus(): void {         console.log("onFocus:");     }      private onBlur(): void {         console.log("onBlur:");     } }...

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

150. 物体的x,y输出不一致的问题 [ 78%]

...息不一致: var player :Player = Laya.stage.getChildAt(i) as Player; console.log(player.x); 附:在Player中输出x的信息 一直为0 但是在Monster类中输出Player的x的数据一直是497,0,494,0,491,0,488,0.......这样的 2018-08-28 添加评论 免费帖 --> 分享 微...

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