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

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

2041. laya.d3.core.particleshuriken.module.GradientColor_API3.0 [ 63%]

...eateByRandomTwoConstant createByRandomTwoGradient Constructors constructor new GradientColor(): GradientColor Defined in laya/d3/core/particleShuriKen/module/GradientColor.ts:113 创建一个 GradientColor,不允许new,请使用静态创建函数。 实例。 Returns GradientColor Accessors consta...

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

2042. 给图片节点添加新创建的图片,会报这个错:node._setParent is not a function [ 63%]

...) * this.intMaxLove); let imgSrc = "comp/heart"+iNum+".png"; let imgLove = new Image(imgSrc); console.log("imgLove ==="+imgLove); console.log("imgSrc === "+ imgSrc); //imgLove.pos(iRows*this._x + 120 , iColumns*this._y + 320); this.imageBg.addChild(imgLove); } }TypeError: node._setParent is not a fu...

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

2043. 关于WebGL矢量图的遮罩问题 [ 63%]

...1024); } //等待可调试 Laya.timer.once(1000, null, ()=>{ let mask = new Laya.Sprite() let sprite = new Laya.Sprite() sprite.mask = mask Laya.stage.addChild(sprite) //正方形 sprite.graphics.drawPoly(0, 0, [100, 100, 100, 200, 200, 200, 200, 100], "#ffffff") //一挑粗直线 遮挡正方形...

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

2044. 分包项目, 加载js时报错 [ 63%]

... function loading100()         {             var txt:Text = new Text();             //设置文本内容             txt.text = "Hello Layabox2";             //设置文本颜色为白色,默认颜色为黑色             txt.color = '#ffffff';  ...

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

2045. 分享:为List组件下Item(Box)下的Button(或其他组件)进行监听! [ 63%]

...is.list.array = arr; //给list添加渲染函数 this.list.renderHandler = new Handler(this, onListRender); } //通过渲染函数为Btn添加Click function onListRender(item, index) { var btn=item.getChildByName('btn'); btn.on(Event.CLICK,this,onClickBtn,[index]); } Laya.class(TestUI, "TestUI", Tes...

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

2046. 渲染优化原则(TypeScript-2D进阶篇(TS)-性能优化) [ 63%]

...nstructor() { Laya.init(550,400,Laya.WebGL); Laya.Stat.show(); var textBox=new Laya.Sprite(); for(var i=0;i (图1) 当我们对文字所在的容器设置为cacheAs之后,如下面的例子所示,性能获得较大的提升,FPS达到到了60帧。 ```typescript //...省略其他代码 var ...

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

2047. laya2.0 设置mask的显示对象再微信小游戏ios设备上执行移除显示对象后界面卡住了。 [ 63%]

...某些设备上在移除显示对象的时候界面会卡主,laya直接new出来的spite的显示对象不会有这个问题,这个问题只出现再laya2.0。laya1.0也正常的。 这个问题很奇怪fgui里设置mask也是设置 displayObject.mask。我找了挺久没找到哪里的问题...

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

2048. config.jsh中无法使用confirm [ 62%]

...ic static void showError(){ Log.e("showerror","show"); new AlertDialog.Builder(MainActivity.my_activity).setTitle("error" ).setMessage("加载游戏失败,可能由于您的网络不稳定,请退出重进" ).setPositiveButton("确定" , new Dialo...

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

2049. laya animation播放图片集合,切换时会闪烁一下 [ 62%]

...eAnimation(images: Array<string>): Laya.Animation { this.animation = new Laya.Animation(); this.ui.addChild(this.animation); this.animation.loadImages(images); this.animation.interval = 70; this.animation.play(0); return  this.animation } 我不知道你是怎么做的。这样是没问题...

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

2050. 重复使用Laya.Sprite3D.load加载同一个lh类型的资源,发现第二次加载到的资源是无效的 [ 62%]

...源释放问题 分享:LayaAir下如何获取图集下的小图资源? new Laya.Sprite();绘制图形以后,怎么删除释放资源? 问题状态 最新活动: 2020-06-11 11:09 浏览: 2894 关注: 2 人 189*****909 • 2020-06-12 15:58 请问Laya.Loader这个能读取lh文件么?我们...

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