• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 293 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0050 秒)

221. laya.display.Text_API3.0 [ 65%]

...模式。 Laya.stage.bgColor = "#efefef";//设置画布的背景颜色。 this.onInit(); } private onInit(): void { var text: laya.display.Text = new laya.display.Text();//创建一个 Text 类的实例对象 text 。 text.text = "这个是一个 Text 文本示例。"; text.color = "#008fff";//设...

来源: Laya3.0_api 发布时间: 20231115

222. 性能测试-虫子(慎入) [ 64%]

....stage.height + padding * 2); Laya.loader.load(texturePath, Handler.create(this, onTextureLoaded)); })(); function onTextureLoaded() { maggotTexture = Laya.loader.getRes(texturePath); initMaggots(); Laya.timer.frameLoop(1, this, animate); } function initMaggots() { var maggotContainer; for (var i = ...

来源: Laya_示例 发布时间: 20251130

223. 滤镜-颜色滤镜 [ 64%]

...a.stage.bgColor = "#232628"; Laya.loader.load(apePath, Laya.Handler.create(this, this.setup)); } setup() { this.normalizeApe(); this.makeRedApe(); this.grayingApe(); } normalizeApe() { let originalApe = this.createApe(); originalApe.x = (Laya.stage.width - apeTexture.width * 3) / 2; originalApe.y = ...

来源: Laya2.0_示例 发布时间: 20251130

224. TiledMap地图 · LayaAir3.3 · 引擎文档 · LAYABOX [ 64%]

...aya.Script { private tMap:Laya.TiledMap; onEnable() { //创建地图对象 this.tMap = new Laya.TiledMap(); //创建Rectangle实例,视口区域 var viewRect:Laya.Rectangle = new Laya.Rectangle(0, 0, Laya.stage.designWidth, Laya.stage.designHeight); //创建TiledMap地图 this.tMap.createMap("reso...

来源: Laya3.0_文档 发布时间: 20251010

225. 发布微信小游戏,sprite的graphics.drawPoly安卓平台会引起花屏 [ 64%]

...等于0  var w: number = 642; var h: number = 12; var g: Laya.Graphics = this._mask.graphics; g.clear();   if (w == 0 || h == 0) return; var points: any[] = []; points.push(0, h); points.push(0, 0); points.push(this._index, 0); points.push(this._index, h); // points.push(0, h); g.drawPoly(0, 0, po...

来源: Laya_社区 发布时间: 20221117

226. 性能测试-虫子(慎入) [ 64%]

....stage.height + padding * 2); Laya.loader.load(texturePath, Handler.create(this, this.onTextureLoaded)); } onTextureLoaded() { maggotTexture = Laya.loader.getRes(texturePath); this.initMaggots(); Laya.timer.frameLoop(1, this, this.animate); } initMaggots() { let maggotContainer; for (let i = 0; i wb...

来源: Laya2.0_示例 发布时间: 20251130

227. 请问特效播放的速率可以自定义吗? [ 64%]

... 2018-04-11 16:27 Laya.loader.load("shadeY.part",Handler.create(this,onParticleLoaded),null,Loader.JSON); private function onParticleLoaded(settings:ParticleSetting):void { settings.minStartSize = 200; settings.minEndSize = 200; settings.maxStartSize = 200; settings.maxEndSize = 200; par =...

来源: Laya_社区 发布时间: 20180409

228. 多行输入文本组件 · LayaAir3.3 · 引擎文档 · LAYABOX [ 64%]

...组件均已创建完毕,此方法只执行一次 */ onAwake(): void { this.txtarea.pos(Laya.stage.width >> 1, Laya.stage.height >> 1); //位置 this.txtarea.size(500, 200); //大小 this.txtarea.pivot(this.txtarea.width/2, this.txtarea.height/2); //轴心点 this.txtarea.text = "大...

来源: Laya3.0_文档 发布时间: 20251010

229. 滤镜-颜色滤镜 [ 64%]

...; Laya.stage.bgColor = "#232628"; Laya.loader.load(ApePath, Handler.create(this, setup)); })(); function setup() { normalizeApe(); makeRedApe(); grayingApe(); } function normalizeApe() { var originalApe = createApe(); apeTexture = Laya.loader.getRes(ApePath); originalApe.x = (Laya.stage.width - apeT...

来源: Laya_示例 发布时间: 20251130

230. laya.ui.TextArea_API3.0 [ 64%]

...背景颜色。 Laya.loader.load(["resource/ui/input.png"], Handler.create(this, onLoadComplete));//加载资源。 } private function onLoadComplete():void { var textArea:TextArea = new TextArea("这个一个TextArea实例。");//创建一个 TextArea 类的实例对象 textArea 。 textArea.skin =...

来源: Laya3.0_api 发布时间: 20231115