大约有 15 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0021 秒)
...lor = "#232628"; // 加载一张png类型资源 Laya.loader.load("res/apes/monkey0.png", Handler.create(this, this.onAssetLoaded1)); // 加载多张png类型资源 Laya.loader.load( ["res/apes/monkey0.png", "res/apes/monkey1.png", "res/apes/monkey2.png"], Handler.create(this, this.onAssetLoaded2)); ...
来源: Laya2.0_示例 发布时间: 20251130
... = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; // 按序列加载 monkey2.png - monkey1.png - monkey0.png // 不开启缓存 // 关闭并发加载 Laya.loader.maxLoader = 1; Laya.loader.load("res/apes/monkey2.png", Handler.create(this, this.onAssetLoaded), null, null, 0, false); Laya.loader...
来源: Laya2.0_示例 发布时间: 20251130
...OWALL; Laya.stage.bgColor = "#232628"; this.showApe(); } showApe() { const monkey1Path = "./res/apes/monkey1.png", monkey2Path = "./res/apes/monkey2.png"; // 方法1:使用loadImage let ape = new Laya.Sprite(); Laya.stage.addChild(ape); ape.loadImage(monkey1Path); // 方法2:使用drawTexture La...
来源: Laya2.0_示例 发布时间: 20251130
...、TypeScript三种开发语言、LayaAirIDE让项目开发更高效。let monkey1Str = "res/apes/monkey1.png", monkey2Str = "res/apes/monkey2.png", monkey1Res, monkey2Res; class Sprite_SwitchTexture { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持...
来源: Laya2.0_示例 发布时间: 20251130
...2628"; this.createApes(); } createApes() { const Sprite = Laya.Sprite; let monkey2Path = "res/apes/monkey2.png"; this.ape1 = new Sprite(); this.ape2 = new Sprite(); this.ape1.loadImage(monkey2Path); this.ape2.loadImage(monkey2Path); this.ape1.pivot(55, 72); this.ape2.pivot(55, 72); this.ape1.pos(Lay...
来源: Laya2.0_示例 发布时间: 20251130
...2628"; this.createApes(); } createApes() { const Sprite = Laya.Sprite; let monkey2Path = "res/apes/monkey2.png"; let gap = 150; this.ape1 = new Sprite(); Laya.stage.addChild(this.ape1); this.ape1.loadImage(monkey2Path); // 设置轴心点为中心 this.ape1.pivot(55, 72); this.ape1.pos(Laya.stage.wi...
来源: Laya2.0_示例 发布时间: 20251130
...= null; this.aimSp = null; this.drawImage = null; this.drawSp = null; this.monkeyTexture = null; // 不支持WebGL时自动切换至Canvas Config.preserveDrawingBuffer =true; Laya.init(Browser.clientWidth, Browser.clientHeight); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN...
来源: Laya2.0_示例 发布时间: 20251130
...发语言、LayaAirIDE让项目开发更高效。let apePath = "res/apes/monkey2.png", apeTexture; class Filters_Color { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.width, Browser.height, WebGL); La...
来源: Laya2.0_示例 发布时间: 20251130
...Laya.Sprite(); Laya.stage.addChild(this.ape); this.ape.loadImage("res/apes/monkey2.png"); this.ape.pivot(55, 72); // this.ape.pos( Laya.stage.width / 2, Laya.stage.height / 2); this.ape.x = Laya.stage.width / 2; this.ape.y = Laya.stage.height / 2; this.scaleDelta = 0; Laya.timer.frameLoop(1, this, t...
来源: Laya2.0_示例 发布时间: 20251130
...发语言、LayaAirIDE让项目开发更高效。let apePath = "res/apes/monkey2.png"; class Filters_Blur { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.width, Browser.height, WebGL); Laya.stage.alig...
来源: Laya2.0_示例 发布时间: 20251130