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

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

391. 关于Laya.loader.load和getRes的问题 [ 54%]

...  加载结束回调。根据url类型不同分为2种情况:1. url为String类型,也就是单个资源地址,如果加载成功,则回调参数值为加载完成的资源,否则为null;2. url为数组类型,指定了一组要加载的资源,如果全部加载成功,则回调参...

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

392. Laya中的宏编译要怎么用啊 [ 53%]

... function multiLineMacroCompilationTest():void { var flag:Boolean; var msg:String; var result:int = 0; /*[IF-FLASH-BEGIN]*/ if (!flag) { msg = "AS3"; flag = true; } /*[IF-FLASH-END]*/ if (flag) { result = 100; } /*[IF-SCRIPT-BEGIN] else { msg = "JS"; } [IF-SCRIPT-END]*/ trace(msg + ", let's go! Resu...

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

393. 在微信小游戏中,主域中显示开发域的list为什么显示不全? [ 53%]

...;             //this.addChild(this.text); } public setImg(src: string): void { this.img.skin = src;             } }  /* class Main {     constructor() {         wx.onMessage(data => {             console.log(data);             if (data....

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

394. 有关Laya3D碰撞检测疑问 [ 53%]

...件 Laya.stage.on(Laya.Event.MOUSE_UP, this, function (): void { var str: String = ""; for (var i: number = 0; i < this._outHitAllInfo.length; i++) { str += this._outHitAllInfo.sprite3D.name + " "; } if (this._outHitAllInfo.length == 0) { str = "点击选取的几何体"; } this.label.text = str;...

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

395. 微信关系链:LayaAir引擎针对开发数据域使用图集支持介绍 [ 52%]

...lic class MsgMgr { /**共享画布类型**/ public static var SHAREDRESIZE:String = "sharedresize"; private static var _i:MsgMgr = null; public function MsgMgr() { super(); } public static function get instance():MsgMgr { return _i ||= new MsgMgr(); } /**初始化消息监听**/ public function init...

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

396. 缓动 · LayaAir3.4 · 引擎文档 · LAYABOX [ 52%]

...* @param value 属性目标值。 * @return Tween对象。 */ to(propName: string, value: any): this; 除了to()方法,还有from()和go()两种方法可以用于设置缓动的属性: /** * @zh 缓动对象的属性从指定值到当前值。 * @param propName 属性名称。 * 属性类型可...

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

397. 2D方向光 · LayaAir3.4 · 引擎文档 · LAYABOX [ 52%]

...ath.floor(totalMinutes / 60); const minutes = totalMinutes % 60; const timeString = `${this.padNumber(hours)}:${this.padNumber(minutes)}`; // 更新文本显示 this.displayText.text = `时间: ${timeString}`; // 计算当前时间的光照强度 const timeProgress = this.dayTime / this.dayDuration;...

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

398. 和原生Dom交互 · LayaAir3.4 · 引擎文档 · LAYABOX [ 52%]

...显示这个img。我们新建个项目。代码如下所示: var data: string = "data:image/svg+xml," + '<svg xmlns="http://www.w3.org/2000/svg" width="200" height="200">' + '<foreignObject width="100%" height="100%">' + '<div xmlns="http://www.w3.org/1999/xhtml" style="font-size:4...

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

399. layaAir TS项目如何引用protoBuf库? [ 51%]

... package awesomepackage;   message AwesomeMessage {       required string awesomeField = 1;  }     放在laya/proto下面,proto这个文件夹没有请自己创建。   2、在bin下的index.html里的这个位置,看粗体部分,protobuf.js在项目里已经存在了,不需要再...

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

400. Cannot read property 'load' of null [ 51%]

...(); } return this.s_instance; } private init() { } private skins: Array<string>; private mapImg:Laya.Image; private constructor() { } public GetMap():Laya.Image { if(this.mapImg==null) { this.mapImg=new Laya.Image(); } return this.mapImg; } public LoadMapResource() { this.skins=[ "res/img/map/...

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