大约有 1,204 项符合查询结果, 库内数据总量为 30,786 项。 (搜索耗时: 0.0054 秒)
Laya_社区(690) Laya_示例(137) Laya2.0_文档(123) Laya2.0_示例(116) Laya3.0_文档(59) Laya3.0_api(39) laya_api(29) Laya2.0_api(11)
...; // 侦听加载失败 Laya.loader.on(Event.ERROR, this, this.onError); } private onAssetLoaded(texture: Texture): void { // 使用texture console.log("加载结束"); } // 加载进度侦听器 private onLoading(progress: number): void { console.log("加载进度: " + progress); } private onError(...
来源: Laya2.0_示例 发布时间: 20241124
...t laya.utils.Handler; import laya.webgl.WebGL; public class HelloLayabox { private const AniConfPath:String = "../../../../res/role.atlas"; private var roleAni:Animation; public function HelloLayabox() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, W...
来源: Laya2.0_文档 发布时间: 20210715
...a.utils.Handler; import laya.webgl.WebGL; public class DialogCenterClose { private const DIALOG_WIDTH:int = 220; private const DIALOG_HEIGHT:int = 275; private const CLOSE_BTN_WIDTH:int = 43; private const CLOSE_BTN_PADDING:int = 5; private var assets:Array; public function DialogCenterClose() { // ...
来源: Laya_社区 发布时间: 20170706
....Handler; import ui.TestViewUI; public class TestView extends TestViewUI { private var PATH_LEN:Number = 120.0; private var speed:Number = 15; private var _path:Sprite = new Sprite(); private var arr:Array = []; public function TestView() { super(); _path.pivot(0,0); _path.pos(a.x,a.y); this.addChil...
来源: Laya_社区 发布时间: 20171113
... Laya.loader.load(skins, Handler.create(this, this.onSkinLoadComplete)); } private onSkinLoadComplete(): void { this.placeHScroller(); this.placeVScroller(); } private placeHScroller(): void { var hs: HScrollBar = new HScrollBar(); hs.skin = "../../res/ui/hscroll.png"; hs.width = 300; hs.pos(50, 170...
来源: Laya_示例 发布时间: 20241124
...x = 450; sensorCollider.y = 300; for (let i = 0, len = this.count; i = []; private touching: Array = []; constructor(maincls: typeof Main) { this.Main = maincls; Laya.Config.isAntialias = true; Laya.init(1200, 700, WebGL); Stat.show(); Physics.enable(); PhysicsDebugDraw.enable(); Laya.stage.alignV =...
来源: Laya2.0_示例 发布时间: 20241124
...laya.utils.Handler; import ui.test.ListPageUI; public class LayaUISample { private var listP:ListPageUI;//UI面板 private var arr:Array;//list数据数组 public function LayaUISample() { //初始化引擎 Laya.init(600, 800); Laya.stage.bgColor = "#ffcccc"; //加载界面需要的资源文件 Laya...
来源: Laya_社区 发布时间: 20170313
...age.scaleMode = "showall"; Laya.stage.bgColor = "#232628"; this.setup(); } private setup(): void { this.createParagraph(); // 代码创建 this.showExternalHTML(); // 使用外部定义的html } private createParagraph(): void { var p: HTMLDivElement = new HTMLDivElement(); Laya.stage.addChild(p); p...
来源: Laya_示例 发布时间: 20241124
...而移动,你需要手动去改变新添加精灵的位置,像这样 private function createMap():void { tiledMap = new TiledMap(); tiledMap.createMap("tiledMap/orthogonal-test-movelayer.json", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), Handler.create(this,onLoadedMap));...
来源: Laya_社区 发布时间: 20170525
...r = Laya.Handler; import WebGL = Laya.WebGL; export class UI_ColorPicker { private skin: string = "../../res/ui/colorPicker.png"; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage....
来源: Laya_示例 发布时间: 20241124