大约有 1,764 项符合查询结果, 库内数据总量为 31,624 项。 (搜索耗时: 0.0057 秒)
Laya_社区(623) Laya3.0_api(482) Laya2.0_文档(180) Laya_示例(146) Laya2.0_示例(116) Laya3.0_文档(86) Laya2.0_api(67) laya_api(64)
...play.Stage; import laya.webgl.WebGL; public class Sprite_DrawShapes { private var sp:Sprite; public function Sprite_DrawShapes() { Laya.init(500, 300, WebGL); ...
来源: Laya2.0_文档 发布时间: 20210714
...import laya.display.Text; /** @author Charley */ public class HelloLayabox { public function HelloLayabox() { //创建舞台,默认背景色是黑色的 Laya.init(600, 300); var txt:Text = new Text(); //设置文本内容 txt....
来源: Laya2.0_文档 发布时间: 20210715
...添加如下的示例代码,实现脚本控制HScrollBar: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.HScrollBar }) public hscroll: Laya.HScrollBar; //组件被激活后执行,此时所有节点和组件均已创建完毕...
来源: Laya3.0_文档 发布时间: 20251010
...lobals "laya/d3/component/AnimatorControllerLayer" AnimatorControllerLayer Class AnimatorControllerLayer AnimatorControllerLayer 类用于创建动画控制器层。 Hierarchy AnimatorControllerLayer Implements IReferenceCounter IClone Index Constructors constructor Properties blendingMode defaultWe...
来源: Laya3.0_api 发布时间: 20231102
...ew.TestView; import laya.net.WorkerLoader; import laya.webgl.WebGL; public class LayaUISample { public function LayaUISample() { //初始化引擎 Laya.init(600, 400,WebGL); //设置Laya提供的worker.js的路径 WorkerLoader.workerPath = "libs/worker.js"; //开启worker线程 WorkerLoader.enable =...
来源: Laya2.0_文档 发布时间: 20210715
...添加如下的示例代码,实现脚本控制VScrollBar: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.VScrollBar }) public vscroll: Laya.VScrollBar; //组件被激活后执行,此时所有节点和组件均已创建完毕...
来源: Laya3.0_文档 发布时间: 20251010
...mport Handler = Laya.Handler; import Loader = Laya.Loader; // 程序入口 class GameMain{ private begin: Begin; constructor() { Laya.init(600,400, WebGL); Laya.stage.bgColor = "#000000"; Laya.loader.load("comp/button.png", Handler.create(this, this.onLoaded)); } private onLoaded(): void { this.begi...
来源: Laya_社区 发布时间: 20180829
为什么hitTestPoint始终是false? class TestUI extends Laya.Sprite { private s:Laya.Sprite = new Laya.Sprite(); constructor() { super(); var img:Laya.Image = new Laya.Image("comp/bg.png"); this.s.addChild(img); this.addChild(this.s); Laya.stage.on(Laya.Event.CLICK, this, this.hitPoint); } priv...
来源: Laya_社区 发布时间: 20170319
htmlDiv中img图片大小问题 // 程序入口 class GameMain{ constructor() { Laya.init(600,400); let htmlDiv = new Laya.HTMLDivElement(); let imgUrl = 'images/kb-emoji-U+E056.png'; // origin width/height: 64/64px; //let imgStr = `<img src="${imgUrl}" width="30" height="30"></img>`; l...
来源: Laya_社区 发布时间: 20170511
...ader; import Texture = Laya.Texture; import Handler = Laya.Handler; export class Loader_SingleType { constructor() { Laya.init(550, 400); // 加载一张png类型资源 Laya.loader.load("../../res/apes/monkey0.png", Handler.create(this, this.onAssetLoaded1)); // 加载多张png类型资源 Laya.load...
来源: Laya_示例 发布时间: 20251218