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

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

651. Laya.Pool用法 [ 67%]

... 2017-08-07 09:44:25      */     export class ProtoPool {         private static _dic: Laya.Dictionary;         public static PROTO_HEAD: string = "proto_Head";         public static PROTO_BINARY_REQUEST: string = "proto_BinaryRequest";         public static PROTO_PARAMS: string...

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

652. Sprite-根据数据绘制路径 [ 67%]

...eMode = "showall"; Laya.stage.bgColor = "#232628"; this.drawPentagram(); } private drawPentagram(): void { var canvas: Sprite = new Sprite(); Laya.stage.addChild(canvas); var path: Array = []; path.push(0, -130); path.push(33, -33); path.push(137, -30); path.push(55, 32); path.push(85, 130); path.pu...

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

653. CPU优化方式(TypeScript-2D进阶篇(TS)-性能优化) [ 66%]

...导致图形重绘: ```typescript var rotation=0, scale=1, position=0; private function setRotation(value):void { this.rotation=value; update(); } private function setScale(value):void { this.scale = value; update(); } private function setPosition(value):void { this.position = value; update(); } p...

来源: Laya2.0_文档 发布时间: 20210714

654. 文本-自动换行 [ 66%]

... Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.createText(); } private createText(): void { var txt: Text = new Text(); txt.text = "Layabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!"; txt.width = 300; txt.fontSize = ...

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

655. Sprite-根据数据绘制路径 [ 66%]

...eMode = "showall"; Laya.stage.bgColor = "#232628"; this.drawPentagram(); } private drawPentagram(): void { var canvas: Sprite = new Sprite(); Laya.stage.addChild(canvas); var path: Array = []; path.push(0, -130); path.push(33, -33); path.push(137, -30); path.push(55, 32); path.push(85, 130); path.pu...

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

656. [LayaAir3]Laya3.0 中设置舞台背景透明无效 [ 66%]

...";                 this.Show();             }           private iframe: any = Laya.Browser.document.createElement("iframe");     private _view: HTMLDivElement = document.createElement("div");           public Show(): void {         Laya.Browser.document.body.appendChild...

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

657. 循环添加一组按钮事件无法正常使用 [ 66%]

...行,单独给文本添加啦同一组事件,可以正常执行     private function addEgg():void         {             trace("addEgg");             for(var i:int = 0; i<eggLoc.length; i++)             {                 //trace(eggLoc[i][1]+"  "...

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

658. 怎么实现同一个工程内分包? [ 66%]

... { if (stage) init(); else addEventListener(Event.ADDED_TO_STAGE, init); } private function init(e:Event = null):void { removeEventListener(Event.ADDED_TO_STAGE, init); this.stage.scaleMode = StageScaleMode.NO_SCALE; this.stage.align = StageAlign.TOP_LEFT; IFlash.setSize(1000, 600); //2D项目中设...

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

659. [LayaAir3]Laya旧版本的TiledMap如何隐藏某一层级的格子贴图 [ 66%]

...demo代码如下,运行scene场景,点击屏幕就会响应代码: private onMouseClick(event:Laya.Event):void{ //获取点击位置的地图坐标 const uiPosX = Math.abs(this.tMap.viewPortX) + event.stageX / this.tMap.scale; const uiPosY = Math.abs(this.tMap.viewPortY) + event.stageY / this....

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

660. 文本-自动换行 [ 66%]

... Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.createText(); } private createText(): void { var txt: Text = new Text(); txt.text = "Layabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!"; txt.width = 300; txt.fontSize = ...

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