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

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

401. 3D粒子编辑模块 · LayaAir3文档 · LAYABOX [ 46%]

...tring): void { if (this._isInited) { return; } this._filePath = file_path; console.log("Particle3D"); //从拿到的粒子系统克隆一个 var res = Laya.loader.getRes(file_path); var particle = res.clone(); this._particle = particle; //获取这个粒子特效的所有粒子系统,用于后面...

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

402. 场景管理 · LayaAir3.3 · 引擎文档 · LAYABOX [ 46%]

...lass() export class MsgRT extends MsgRTBase { onOpened(param: any): void { console.log(param.text); } } 这样,点击Scene场景中的Button,就会打印日志“点击成功!”,效果如动图2-3所示: (动图2-3) 2.3 关闭场景 1,关闭指定的场景 /** * 根据地址,关...

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

403. Spine渲染器 · LayaAir3.3 · 引擎文档 · LAYABOX [ 42%]

...currentSkin; this.spine.play("idle", false); //切换后重新播放一次 console.log(`当前皮肤切换至:${currentSkin}`); }); } } 2.6 动画名称 animationName 在前文的示例代码中,我们通过play方法来直接播放动画。为了在IDE面板中更方便易用,我们提供的...

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

404. 2D寻路 · LayaAir3.3 · 引擎文档 · LAYABOX [ 42%]

...t: Laya.Event): void { let pos = new Laya.Vector2(evt.stageX, evt.stageY); console.log("click", pos); this._temp.graphics.clear(); this._allAgent.forEach((agent) => { agent.destination = pos; let paths = agent.getCurrentPath(); if (paths.length >= 2) { let points: any = [] paths.forEach((point...

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

405. 关于UI与3D场景的问题 [ 41%]

...同来自: button.on(Laya.Event.CLICK, this, function(event:Laya.Event){ console.log("点击到了UI"); event.stopPropagation(); }); 完整代码 2018-05-30 0 17 分享 微博 QZONE 微信 Laya_Aaron 赞同来自: 你这个问题描述的很明确,很好,这个按钮正常来讲,会挡住下...

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

406. laya.ui.Button_API3.0 [ 41%]

...andler.create(this,loadComplete));//加载资源 function loadComplete() { console.log("资源加载完成!"); var button = new laya.ui.Button("resource/ui/button.png","label");//创建一个 Button 类的实例对象 button ,传入它的皮肤skin和标签label。 button.x =100;//设置 button ...

来源: Laya3.0_api 发布时间: 20231115

407. laya.ui.CheckBox_API3.0 [ 41%]

...andler.create(this,loadComplete));//加载资源 function loadComplete() { console.log("资源加载完成!"); var checkBox:laya.ui.CheckBox= new laya.ui.CheckBox("resource/ui/check.png", "这个是一个CheckBox组件。");//创建一个 CheckBox 类的类的实例对象 checkBox ,传入它的皮...

来源: Laya3.0_api 发布时间: 20231115

408. laya.display.Sprite_API3.0 [ 33%]

...//给 shape 对象添加点击事件侦听。 } function onClickSprite() { console.log("点击 sprite 对象。"); sprite.rotation += 5;//旋转 sprite 对象。 } function onClickShape() { console.log("点击 shape 对象。"); shape.rotation += 5;//旋转 shape 对象。 } example import Sprite = ...

来源: Laya3.0_api 发布时间: 20231115

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

...in); } protected AroundByMobileInput(): void { if (this.TouchCount == 1) { console.log(this.targetAngles); this.targetAngles.y -= this.GetAxisX * this.mouseSettings.pointerSensitivity; this.targetAngles.x += this.GetAxisY * this.mouseSettings.pointerSensitivity; //Range. this.targetAngles.y = this.C...

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

410. laya.ui.ColorPicker_API3.0 [ 31%]

...andler.create(this,loadComplete));//加载资源 function loadComplete() { console.log("资源加载完成!"); var colorPicket = new laya.ui.ColorPicker();//创建一个 ColorPicker 类的实例对象 colorPicket 。 colorPicket.skin = "resource/ui/color.png";//设置 colorPicket 的皮肤。 colo...

来源: Laya3.0_api 发布时间: 20231115