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

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

31. setSubPixels画布擦除不掉 [ 61%]

setSubPixels画布擦除不掉 this.btn.label = Math.random().toString(); // console.log(Math.random()); let tex:Laya.Texture = Laya.Loader.getRes(this.bUrl); let x:number = this._testStatus == true ? 0:50;//Math.random()>0.5 ? 50 : 0; this._testStatus = !this._testStatus; // let canvasInfo = th...

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

32. 在List渲染的时候,在滚动一个list的时候,如何实现另一个list也跟着滚动,并且两个list同时滚动一模一样。 [ 61%]

...abRender(item:component.UIButton, index: number): void { item.name = index.toString(); item.onClick(this,this.OnCliickItem); } /** 点击item单个道具的时候*/ private OnCliickItem(item: component.UIButton) { let index = parseInt( item.name ); }

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

33. 用npm的protobuf导出的ts代码。然后用import { } from "" 运行到这里没反应,不继续执行,也不报错。 [ 60%]

...code(buffer); console.log("test"); console.log(`buffer = ${Array.prototype.toString.call(buffer)}`); }  然后用import {testProto} from "MyModule" 导入import {testProto} from "MyModule"; // 程序入口 class GameMain{ constructor() { Laya.init(600,400, 0x000000); console.log("start"); testProto...

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

34. 二次开发 · LayaAir3.3 · 引擎文档 · LAYABOX [ 60%]

... } ExportJavaFunction.CallBackToJS(JSBridge.class,"testAsyncCallback", obj.toString()); } }); } 1.3 iOS/OC层 发布后,使用XCode打开项目,在类JSBridge中添加下列函数: +(NSString*)testString:(NSString*)value { NSLog(@"OC: %@",value); return @"LayaBox"; } +(NSNumber*)testNumber:(NSNu...

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

35. laya接入fairyGUI的时候资源加载方式? [ 58%]

...ta); } for (var i = 0; i < loadData.length; i++) { if (Object.prototype.toString.call(loadData[i]) === "[object Object]") { loadData[i].priority = this.priority; } } Laya.loader.load(loadData, Laya.Handler.create(this, this.onComplete, [resKey, otherLoadData, complete, progress, loadData]), progr...

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

36. 3D中摄像机绕物体旋转该如何实现? [ 52%]

...itivity; // m_debugTip.text = ( currentTouchDistance - lastTouchDistance ).ToString() + " + " + targetDistance.ToString(); //把距离限制住在min和max之间 //备份上一次触摸点的位置,用于对比 this.oldPosition1 = tempPosition1; this.oldPosition2 = tempPosition2; this.m_IsSingleFi...

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

37. 官方案例里摄像机绕物体旋转脚本的问题 [ 52%]

...itivity; // m_debugTip.text = ( currentTouchDistance - lastTouchDistance ).ToString() + " + " + targetDistance.ToString(); //把距离限制住在min和max之间 //备份上一次触摸点的位置,用于对比 this.oldPosition1 = tempPosition1; this.oldPosition2 = tempPosition2; this.m_IsSingleFi...

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

38. LAYABOX游戏实时语音之APP版本 [ 49%]

...mStoragePath = Environment.getExternalStorageDirectory().getAbsolutePath().toString(); } } private String getAudioPath(){ String audioPath = mStoragePath + "/"; audioPath += UUID.randomUUID().toString() + ".wav"; return audioPath; } public boolean onTouch(final String type){ switch(type){ case "d": ...

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

39. 本地双击html如何打开laya项目? [ 44%]

...TAG, "文件大小:" + buffer. length); Log. i(TAG, "内容:" + buffer.toString()); buffer = new byte [fis.available()]; fis.read(buffer); os.write(buffer); os.flush(); os.close(); fis.close(); socket.close(); } else { os.println( "HTTP/1.0 404 FileNotFonud!" ); os.close(); } } catch (IOExceptio...

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

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

...mp;& text >= 0 && text <= 9999) { this.owner.text = text.toString() } else { this.owner.text = "1000"; } //开发者要根据这个key来获取数据 let KVData = { key: "playerData", value: this.owner.text } KVDataList.push(KVData); //@ts-ignore wx.setUserCloudStorage({ KVDataList...

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