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

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

131. laya的canvas缩放原理? [ 80%]

...     虽然说laya可以通过一些方法获取缩放的参数,例如 console.log(Laya.stage._canvasTransform); console.log(Laya.stage.clientScaleX); console.log(Laya.stage.clientScaleY);   但是,我的div,在laya还没初始化完成的时候,就已经有了吧。这时候,应该无...

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

132. 使用getUserInfo获取的用户信息 [ 80%]

...getUserInfo({ withCredentials:false, lang: 'zh_CN', success: (res) => { console.log(res); // BigData.ins.user = res.data[0]; }, fail: () => { console.log("userInfo"+JSON.stringify("fail")); }, complete: () => { // console.log("userInfo"+JSON.stringify(selfData)); } Res打印出来时空的 ...

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

133. async bug 导出小游戏 [ 80%]

...rmal; share.imageUrl = ShareImgUrl; let a = await share.shareAppMessage(); console.log(a) }   转换后代码   onShareClick() { // return __awaiter(this, void 0, void 0, function* () { // let share = SDKCenter.getShare(); // share.title = ShareNormal; // share.imageUrl = ShareImgUrl; // let a = y...

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

134. 请问laya中js如何继承自己写的类 [ 80%]

...unction t1(b) { this.b = b; } //父类方法a t1.prototype.a = function(){ console.log(this.b.x+""+this.b.y); } return t1; }());   ========================= /* * t2继承父类t1 */ var t2 = (function () { function t2() { t2.super(); } t2.prototype.a = function(){ console.log('2222'); } return t2; ...

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

135. 闪屏,报错信息如下 [ 80%]

...rom previous GL command 02-05 16:53:07.013 24700-24700/? I/chromium: [INFO:CONSOLE(0)] "[.Offscreen-For-WebGL-0x7c8dec00]GL ERROR :0x0505 : glTexImage2D: <- error from previous GL command", source: http://xx.xxx.xxxx.pk/xn/x/.............html (0) 02-05 16:53:07.825 24700-24824/? E/chromium: [ERRO...

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

136. destroy节点后,报错 [ 80%]

...@param node 节点 */ base_remove(node){ if(node.numChildren<=0)return; console.log('移除',node.name); let obj; for(let i=node.numChildren-1;i>=0;i--){ obj= node.getChildAt(i); obj.destroy(); } }   或者 /* 从舞台移除模型对象 @param node 节点 */ base_remove(node){ if(node.numChi...

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

137. layaair获取xml信息出错 [ 80%]

...  代码: var configData:XmlDom = Loader.getRes(config_PATH) as XmlDom; console.log(configData); console.log(configData.attributes); console.log(configData.childNodes);   xml如下: <root>     <config>          <PATH>../h5/</PAHT>     </config> </r...

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

138. Laya.timer.once计时不准确的问题 [ 80%]

...// 程序入口 class GameMain{ constructor() { Laya.init(600,400, WebGL); console.log("Before In One, Time = " + Date.now()); Laya.timer.once(1,this,this.One) console.log("After In One, Time = " + Date.now()); } One():void{ console.log("In One, Time = " + Date.now()); } } new GameMain();   控制...

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

139. HttpRequest 回调方法都没执行 LayaAir 1.7.17 beta JS版本 [ 80%]

...OR,this,this.onError); //数据传输失败后返回 //post数据的写法 console.log(JSON.stringify(request)); this.http.send(url,JSON.stringify(request), 'post', 'text',["content-type","application/json"]); } function onProgress(e) { console.log("run onProgress"); } function onComplete(e) { conso...

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

140. 微信小游戏提审后,提示说代码侵权 [ 79%]

...r traceName = "xxxx";//添加的干扰代码 var funString = '_xxxx_fun(){ console.log("';//添加的方法体 var root_Url = "D:/code/project/src";//项目diam路径 fileDisplay(path.resolve(root_Url)); /** * 文件遍历方法 * @param filePath 需要遍历的文件路径 */ function fileDisplay(f...

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