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

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

231. laya.d3.core.trail.TrailFilter [ 68%]

...Classes | Index | Frames No Frames TrailFilterProperties | Methods | Constants Packagelaya.d3.core.trailClasspublic class TrailFilterInheritanceTrailFilter Object TrailFilter 类用于创建拖尾过滤器。 Public Properties PropertyDefined By  alignment : int = 0轨迹准线。TrailFilt...

来源: Laya2.0_api 发布时间: 20190513

232. UI运行时 · LayaAir3.3 · 引擎文档 · LAYABOX [ 68%]

...场景中创建好了UI组件脚本,而后添加的代码如下所示: const { regClass } = Laya; import { RuntimeScriptBase } from "./RuntimeScript.generated"; @regClass() export class RuntimeScript extends RuntimeScriptBase { onAwake(): void { // Button添加鼠标事件,让Image不显示 th...

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

233. 如何使用vscode编译laya项目 [ 68%]

...rkSpaceDir = argv.split("=")[1].replace("/.laya/compile.js", ""); } } [/b] const gulp = require(ideModuleDir + "gulp"); const rollup = require(ideModuleDir + "rollup"); const typescript = require(ideModuleDir + 'rollup-plugin-typescript2');//typescript2 plugin const glsl = require(ideModuleDir + 'ro...

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

234. HTTP通信 · LayaAir3.3 · 引擎文档 · LAYABOX [ 68%]

...数据等。 GET请求的示例代码如下: //创建HttpRequest对象 const xhr = new Laya.HttpRequest(); //发送HTTP的GET请求,数据会附加在URL中,适用于无需发送大量数据的情况。 xhr.send('https://httpbin.org/get', null, 'get', 'text'); 2.1.3 POST请求示例 POST 请...

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

235. [LayaAirIDE3]打包原生安卓 , 运行错误 , 我不清楚是不是我自己的问题. [ 68%]

...: number): string {         if (value === 0) return '0';          const absValue = Math.abs(value);         const sign = value < 0 ? '-' : '';          // 简单的单位转换         if (absValue >= 1e9) {             return sign + (absValue / 1e9).toFixed(2).repl...

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

236. [LayaAir3]3.3.0.beta.3 2d物理RigidBody代码生成问题 [ 68%]

...  private addRigidBody(object: Laya.Sprite): Laya.RigidBody {         const rigidBody = object.addComponent(Laya.RigidBody);         rigidBody.type = "kinematic";         rigidBody.label = object.name; // 添加标签         const shape = new Laya.BoxShape2D();         shape.x ...

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

237. 音频节点 · LayaAir3.3 · 引擎文档 · LAYABOX [ 68%]

...口中。下面给出一个示例代码,实现脚本控制SoundNode: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { //declare owner : Laya.Sprite3D; @property({ type: Laya.SoundNode }) public sound: Laya.SoundNode; constructor() { super(); } /** * ...

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

238. 能不能让LayaFlash支持原生的条件编译 [ 67%]

...项目属性->编译选项(Compiler Options)->编译常量(Compiler Constats),写入 CONFIG::cn,false CONFIG::en,true 如图: 2.在代码中写入 CONFIG::cn{     [Embed(source="ui_cn.swf", mimeType="application/octet-stream")]     private const _Ui_SWF:Class;   } CONFIG::en{    ...

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

239. 屏幕适配-自动竖屏 [ 67%]

...语言、LayaAirIDE让项目开发更高效。class SmartScale_Portrait { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage, Stat = Laya.Stat, Handler = Laya.Handler; // 不支持WebGL时自动切换至Canvas Laya.init(550, 400, WebGL); Laya.stage.alignV = Stage.AL...

来源: Laya2.0_示例 发布时间: 20260106

240. 屏幕适配-自动横屏 [ 67%]

...语言、LayaAirIDE让项目开发更高效。class SmartScale_Landscape { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage, Stat = Laya.Stat, Handler = Laya.Handler; // 不支持WebGL时自动切换至Canvas Laya.init(550, 400, WebGL); Laya.stage.alignV = Stage.A...

来源: Laya2.0_示例 发布时间: 20260106