大约有 520 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0052 秒)
...rl:[ "fish_6.png" ],type:Loader.IMAGE}); Laya.loader.load(assets,Handler.create(this,onLoaded)); } private function onLoaded():void{ var img:Image = new Image("fish_6.png"); img.on(Event.CLICK,this,onClick); img.mouseThrough = true; Laya.stage.addChild(img); } 代码就这么简...
来源: Laya_社区 发布时间: 20180314
...图片资源来自“引擎API使用示例” Laya.loader.load(skins, Laya.Handler.create(this, this.placeHSlider)); } private placeHSlider(): void { let hs: Laya.Slider = new Laya.HSlider(); hs.skin = "hslider.png"; hs.width = 300; hs.pos(50, 500); hs.min = 0; hs.max = 100; hs.value = 50; hs.tick =...
来源: Laya3.0_文档 发布时间: 20251010
...e; import laya.net.Loader; import laya.resource.Texture; import laya.utils.Handler; import laya.utils.Stat; import laya.webgl.WebGL; public class Demo { private var num:Number=0;//加载图片的个数 private var sp:Sprite;//显示图片的显示对象容器 private var texture:Texture;//预加载...
来源: Laya_社区 发布时间: 20161107
...会随着改变 代码: Laya.loader.load("res/Particles/Tail.part", Laya.Handler.create(this, this.OnPariticleAssetsLoaded), null, Laya.Loader.JSON); OnPariticleAssetsLoaded(setting:Laya.ParticleSetting) { let sp = new Laya.Particle2D(setting); sp.pos(200, 200); sp.emitter.start(); sp.play(); Laya...
来源: Laya_社区 发布时间: 20180505
...值? private jsonParse() { Laya.loader.load("res/atlas/resTest0.json", Handler.create(this, this.onLoaded), null, Loader.JSON); } private onLoaded() { var json : JSON = Laya.Loader.getRes("res/atlas/resTest0.json"); var jsTx = JSON.stringify(json); } 已经通过上面代码获取整个json内容...
来源: Laya_社区 发布时间: 20171016
...,执行onLoaded回调方法 Laya.loader.load("res/atlas/comp.atlas",Laya.Handler.create(this,this.onLoaded)); } private onLoaded():void{ //创建一个UI实例 this.comp = new ui.ComponentDemoUI(); //添加到舞台上显示 Laya.stage.addChild(this.comp); //点击Tab选择按钮的处理 this.com...
来源: Laya2.0_文档 发布时间: 20210715
...能console出,那个list中的数据也存在,但没渲染出。 Laya.Handler.create 回调 load方法的progress回调进的次数太少了。是我哪里设置有问题么 Tween的to方法完成缓动后的回调怎么写,Tween.to(beginbox,{x:-Laya.Browser.width},1000,null,aaa,0,false);aaa...
来源: Laya_社区 发布时间: 20170321
...果 Laya.loader.load("https://piggy.q1.com/res//atlas/images.atlas", Laya.Handler.create(this, this.onLoaded2), null, Laya.Loader.ATLAS); // Laya.loader.load("map/tile_map.png"); 2018-05-28 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关...
来源: Laya_社区 发布时间: 20180528
...{ url: "view/MyView.json", type: Loader.JSON }, ] Laya.loader.load(assets, Handler.create(this, this.onLoaded)); } private onLoaded():void { this.createView(Laya.loader.getRes("view/MyView.json")); } } 因为加载是异步的,很有可能在加载过程中,用户或者其他行为逻辑已经...
来源: Laya_社区 发布时间: 20180113
... jacksing888 • 2018-01-22 23:37 Laya.loader.load( 'res/atlas/comp.json', Handler.create(this, function(){ container = new Laya.Sprite(); var x = 0,y =80; Laya.stage.addChild(container); for(var i=0;i<1200;i++){ var role = new Laya.Sprite(); x = x+0.1; y = y+0.1 role.x = x; role.y = y; role.load...
来源: Laya_社区 发布时间: 20180122