大约有 520 项符合查询结果, 库内数据总量为 31,625 项。 (搜索耗时: 0.0049 秒)
Laya_社区(399) Laya2.0_文档(39) Laya3.0_api(32) Laya_示例(19) Laya3.0_文档(15) Laya2.0_示例(9) laya_api(5) Laya2.0_api(2)
...ya.loader.load(["./comp/progress.png", "./comp/progress$bar.png"], Handler.create(this, onLoadComplete)); } console.log(1); Laya.class(Loadings,"Loadings",_super); function onLoadComplete() { progressBar = new ProgressBar("./comp/progress.png"); progressBar.width = 400; progressBar.x = (Laya.stage.w...
来源: Laya_社区 发布时间: 20171230
...,执行onLoad回调方法 Laya.loader.load("res/atlas/ui.atlas", Handler.create(this, onLoaded)); ``` 第二步:创建Animation实例,加载动画文件 ```java //创建一个Animation实例 var tl:Animation = new Animation(); //加载动画文件 tl.loadAnimation("TimeLine.ani"); ``` 第三...
来源: Laya2.0_文档 发布时间: 20210715
...0-10 17:25 官方大大你好,我先说明一下流程: 通过 Laya.loader.create(url, complete); 加载 3D 特效文件 并且缓存 源对象 , 当前或下次 直接从源对象 克隆一个 3D特效 出来 进行 添加到场景里 当怪物全部死亡时 会进行特效文件的回收 先遍...
来源: Laya_社区 发布时间: 20221010
....stage.bgColor = "#232628"; Stat.show(); Laya.loader.load(apePath, Handler.create(this, this.createApe)); } createApe() { const Sprite = Laya.Sprite, Event = Laya.Event; this.ape = new Sprite(); this.ape.loadImage(apePath); let texture = Laya.loader.getRes(apePath); this.ape.pivot(texture.width / 2,...
来源: Laya2.0_示例 发布时间: 20251219
...nction beginLoad():void { Laya.loader.load("res/images/rank.json", Handler.create(this, onLoaded)); } private function onLoaded():void { trace("加载成功"); var c:Image = new Image("rank/country.png"); Laya.stage.addChild(c); } 以上是子域项目中加载图集和取资源的代码。代码...
来源: Laya_社区 发布时间: 20180830
关于as版的Animation.createFrames()不能工作? 请看我的代码,不知道为什么createFrames()生成的缓冲图集就是不能工作: package { import laya.display.Animation; import laya.display.Sprite; import laya.display.Stage; import laya.utils.Handler; import laya.net.Loader; im...
来源: Laya_社区 发布时间: 20161026
...Model/LayaMonkey/Assets/LayaMonkey/LayaMonkey-LayaMonkey.lm", Laya.Handler.create(this, function(mesh) { var layaMonkey = scene.addChild(new Laya.MeshSprite3D(mesh)); layaMonkey.transform.localScale = new Laya.Vector3(0.3, 0.3, 0.3); layaMonkey.transform.rotation = new Laya.Quaternion(0.7071068, 0, ...
来源: Laya2.0_文档 发布时间: 20210714
...Texture Laya.loader.load("../../res/apes/monkey2.png", Handler.create(this, function() { var t = Laya.loader.getRes("../../res/apes/monkey2.png"); var ape = new Sprite(); ape.graphics.drawTexture(t, 0, 0); ...
来源: Laya_社区 发布时间: 20171201
...nnel = null Laya.loader.load("res/dreams.mp3",Laya.Handler.create(this,function(){ dreamsSound = Laya.SoundManager.playMusic("res/dreams.mp3") })) let mainSound:Laya.SoundChannel = null; this.btn_sound.on(Laya....
来源: Laya_社区 发布时间: 20190716
官网的LayaRender无法开启角度指示器 var render = LayaRender.create( { engine: engine, container: gameWorld, width: stageWidth, height: stageHeight, options: { wireframes: true, showAngleIndicator: true //无法开启 } }); 哎,为什么你们习惯要开发者上传Demo给你们发...
来源: Laya_社区 发布时间: 20180120