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

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

361. 路径显示会添加DrawCall,每增加一条路径都会添加,有什么办法降DrawCall [ 55%]

... arr2:Array = ; private var pop:TestDialogUI; public function TestView() { super(); _path.pivot(0,0); _path.pos(a.x,a.y); this.addChild(_path); _path.rotation = Math.atan2(b.y - a.y, b.x - a.x) / Math.PI * 180; _path2.rotation = Math.atan2(b.y - a.y+300, b.x - a.x) / Math.PI * 180; _path2.pos(a.x,a....

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

362. LayaAir能做RPG吗?不要问我能不能,因为我已经在做 - 杀意来袭 [ 54%]

... = "data";         constructor(decorate?:Decorate) {             super();             this.mDecorate = decorate || new Decorate(this);             this.pomelo = new Pomelo();             this.configuration();         }         /** 配置*/         private conf...

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

363. 在父sprite中添加子sprite ,移动父Sprite 子sprite为什么不动? [ 54%]

... = target.angel.level; // 构造 function IsLand() { // 初始化 IsLand.__super.call(this); // 名字 this.name = "gemini"; this.init(); } // 注册类 IsLand Laya.class(IsLand,"IsLand",laya.display.Sprite); // 原型 var _proto = IsLand.prototype; // 初始化 _proto.init = function(){ // 球体 t...

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

364. 为什么全局属性赋值后,在另外个函数中调用会自动变成undefined [ 54%]

...      public function MainPageController(){             super();             Laya.stage.scaleMode = Stage.SCALE_FULL;             Laya.stage.screenMode = Stage.SCREEN_NONE;              Scene3D.load("res/model/LayaScene_Car/Conventional/car.ls",...

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

365. 引擎 TiledMap 居然不支持图块翻转 [ 54%]

...Sprite extends Laya.Sprite {         constructor() {             super(...arguments);             this.relativeX = 0;             this.relativeY = 0;             this.isAloneObject = false;             this.isHaveAnimation = false;             this.drawImageNu...

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

366. 使用3D UI · LayaAir3.4 · 引擎文档 · LAYABOX [ 54%]

...tends Laya.Script { // 设置单例 static instance: Main; constructor() { super(); Main.instance = this; } @property({type:Laya.Sprite3D}) private target: Laya.Sprite3D; @property({type:Laya.UI3D}) private ui3d: Laya.UI3D; public animator: Laya.Animator; onEnable() { // 广告牌模式 this.ui3d.bi...

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

367. 微信小游戏渲染开放域卡顿处理 [ 54%]

...前修改有效,兼容ui         constructor() {             super();             this.once(Laya.Event.DISPLAY, this, this.onCreate);             this.once(Laya.Event.UNDISPLAY, this, this.onDestroy);         }         /**          * 加入场景          */...

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

368. 分享水波一个shader [ 54%]

...donly Time:number = Shader3D.propertyNameToID("u_Time");  constructor() { super();  var vs:string = ` attribute vec4 a_Position; attribute vec2 a_Textcoord; attribute vec3 a_Normal; uniform mat4 u_WorldMat; uniform mat4 u_MvpMatrix;   varying vec2 v_textcoord; varying vec3 v_normal; varying vec4 ...

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

369. 使用了destroy()之后,还需要手动移除侦听事件和引用吗? [ 54%]

...mage。我需要手动将img属性置null吗? 比如:public destroy(){ super.destroy(); this.img = null; } 这个有必要吗? 最后,有没有关于优化的比较系统的文档,https://ldc.layabox.com/doc/?nav=zh-js-3-2-1和https://ldc.layabox.com/doc/?nav=zh-js-3-2-1这两个文档空...

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

370. 插件开发说明 · LayaAir3.4 · 引擎文档 · LAYABOX [ 53%]

... class DemoPreviewPlugin extends IEditorEnv.AssetPreview { constructor() { super(); this.sprite.graphics.drawCircle(100, 100, 50, "#ffff00"); this.sprite.size(100, 100); } async setAsset(asset: IEditorEnv.IAssetInfo): Promise<any> { this.renderTarget = this.sprite; } } 显示效果如下: ...

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