大约有 520 项符合查询结果, 库内数据总量为 31,625 项。 (搜索耗时: 0.0052 秒)
Laya_社区(399) Laya2.0_文档(39) Laya3.0_api(32) Laya_示例(19) Laya3.0_文档(15) Laya2.0_示例(9) laya_api(5) Laya2.0_api(2)
..."res/atlas/comp.atlas", type:Loader.ATLAS}); Laya.loader.load(res, Handler.create(null, this.__onLoaded)); } private __onLoaded(): void { Laya.stage.addChild(new Test()); } } new Entry(); Test.ts import Sprite = Laya.Sprite; class Test extends Sprite{ constructor(){ super(); this._initView(); } p...
来源: Laya_社区 发布时间: 20180308
...布功能生成 Laya.ResourceVersion.enable("version.json", Laya.Handler.create(this, this.onVersionLoaded), Laya.ResourceVersion.FILENAME_VERSION); ....... ``` 在GameUI中使用我们的自定义材质。 ```typescript //添加自定义模型 var box = scene.addChild(new Laya.MeshSprite3D(Primitiv...
来源: Laya2.0_文档 发布时间: 20210715
.../atlas/test.atlas", "test/1.png", "test/2.png", "test/3.png"],Laya.Handler.create(this,this.onComplete)); } }.bind(this)); }else { Laya.loader.load("res/atlas/test.atlas",Laya.Handler.create(this,this.onComplete)); } } onComplete(): void { //初始化rank排行榜 var rank = new BigRank(); /...
来源: Laya_社区 发布时间: 20190307
... Laya.Stat.show(); Laya.Scene3D.load('/1/res/SampleScene.ls', Laya.Handler.create(null, function(scene1){ let scene = Laya.stage.addChild(scene1); Laya.Sprite3D.load("/1/res/SampleScene.lh", Laya.Handler.create(null, function(sp) { //let obj = sp; let obj = scene.addChild(sp); obj.transform.scale = ...
来源: Laya_社区 发布时间: 20200611
...效的路径,创建一个粒子特效,从对象池里拿一个 static Create(path: string): Particle3D { var ret:Particle3D = Pool.getInstance().getItemByClass("Particle3D@" + path, Particle3D); ret.Init(path); return ret; } //粒子特效初始化 private Init(file_path:string): void { if (this...
来源: Laya3.0_文档 发布时间: 20251010
...效的路径,创建一个粒子特效,从对象池里拿一个 static Create(path: string): Particle3D { var ret:Particle3D = Pool.getInstance().getItemByClass("Particle3D@" + path, Particle3D); ret.Init(path); return ret; } //粒子特效初始化 private Init(file_path:string): void { if (this...
来源: Laya3.0_文档 发布时间: 20250104
... if (tword.y != tStartWord.y) { this.createOneLine(tStartWord, tEndWord, hasLine, g, recList); tStartWord = tword; tEndWord = tword; } else { ...
来源: Laya_社区 发布时间: 20200724
... BellyChen 赞同来自: 通过脚本文件参数传进去,然后调用create方法创建 2019-09-24 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 150*****573 相关问题 两个对象new了一个相同的对象,调用第一个的...
来源: Laya_社区 发布时间: 20190918
...plane = this.newScene.addChild(new Laya.MeshSprite3D(Laya.PrimitiveMesh.createPlane(10, 10, 10, 10))) as Laya.MeshSprite3D; var planeMat = new Laya.BlinnPhongMaterial(); Laya.Texture2D.load("res/grass.png", Laya.Handler.create(this, function (tex: Laya...
来源: Laya_社区 发布时间: 20201120
...ya.Sprite(); this.sp.loadImage("Attack_0_0002.png", Laya.Handler.create(this, (data)=>{ this.sp.graphics.drawTexture(this.sp.texture); var bounds = this.sp.getGraphicBounds(true); })); 这样绘制后,最后拿到的宽高就是图片实际的寛高
来源: Laya_社区 发布时间: 20181117