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

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

191. 获取位置信息 · LayaAir3.4 · 引擎文档 · LAYABOX [ 66%]

...; @regClass() export class NewScript extends Laya.Script { constructor() { super(); } onMouseClick(evt: Laya.Event): void { // 尝试获取当前位置 Laya.Geolocation.getCurrentPosition( Laya.Handler.create(this, this.onSuccess), Laya.Handler.create(this, this.onError) ); console.log("click"); } /...

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

192. Tab组件如何通过js控制选中 [ 66%]

...没有问题,但是无法更改 class Tab extends TabUI{ constructor() { super() this.zOrder = 1 console.log(this._tab._selectedIndex) //返回1,正常 this._tab._selectedIndex = 0 } } xdkaka • 2017-12-14 17:40 发布肯定是已经发布了的。。。。看了下tabUI的函数也是正常的...

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

193. 在Unity中设置动画事件(JavaScript-3D基础(JS)-LayaAir3D之Animator动画) [ 66%]

...pt export default class SceneScript extends Laya.Script3D { constructor(){ super(); //用于表现的方法 this.showMsgFunc = null; } //对应unity添加的AnimationEvent的动画事件函数,名字是可以对应上的 ShowMsg() { console.log("ShowMsg"); this.showMsgFunc && this.showMsgFunc(); }...

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

194. list中的item类中的button注册事件不响应 是怎么回事呢 ?可以帮帮我解答下吗 [ 66%]

...rivate skin_lock:Laya.Image; private skin_inUse:Laya.Image; constructor(){ super(); this.size(Item.WID, Item.HEI); this.initBuild(); this.skin_btn_use.on(Laya.Event.CLICK,this,this.onSkinBtnUseClick) } private onSkinBtnUseClick(){ console.log("使用"); }   //btn 有宽高 2018-08-28 添加评论 ...

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

195. shader 问题[关闭] [ 66%]

...ord = texcoord;}`class ShaderValue extends Laya.Value2D { constructor () { super(0, 0) var _vlen = 8 * Laya.CONST3D2D.BYTES_PE this.position = [2, Laya.WebGLContext.FLOAT, false, _vlen, 0] this.texcoord = [2, Laya.WebGLContext.FLOAT, false, _vlen, 2 * Laya.CONST3D2D.BYTES_PE] this.color = [4, Laya.W...

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

196. ios苹果手机,同时播放声音出现巨大杂音 [ 66%]

...ameMain extends Laya.Scene {     constructor() {          super();          //设置单例的引用方式,方便其他类引用         GameMain.instance = this;         //加载场景文件         this.loadScene("main_scene.scene");     } ...

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

197. 生成的粒子特效怎么设置colorComponentInter无效? [ 66%]

...rComponentInter无效? function UILetterBox(letter, width) { UILetterBox.super(this); letter = letter; this.loadImage('res/jiezou/wenzi2.png'); Laya.loader.load("res/parts/qipao.part", Handler.create(this, onAssetsLoaded), null, Loader.JSON); } function onAssetsLoaded(settings) { settings.colorCom...

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

198. 内嵌模式创建scene,运行时报找不到json文件 [ 66%]

...compId":3}],"loadList":["comp/label.png"],"loadList3D":[]}; constructor(){ super()} createChildren():void { super.createChildren(); this.createView(HelloUI.uiView); } } REG("ui.HelloUI",HelloUI); } 附件 : --> TestDemo.zip 2019-06-25 2 条评论 免费帖 --> 分享 微博 QZONE 微信 没有找到...

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

199. 取色器组件 · LayaAir3.4 · 引擎文档 · LAYABOX [ 66%]

...ipt { private skin: string = "atlas/comp/colorPicker.png"; constructor() { super(); } // 组件被激活后执行,此时所有节点和组件均已创建完毕,此方法只执行一次 onAwake(): void { Laya.loader.load(this.skin).then( ()=>{ this.onColorPickerSkinLoaded(); } ); } private onC...

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

200. 缓动-缓动函数演示 [ 66%]

...; return input } } class ListItemRender extends Laya.Box { constructor() { super(); const Label = Laya.Label; this.size(100, 20); this.label = new Label(); this.label.fontSize = 12; this.label.color = "#FFFFFF"; this.addChild(this.label); } setLabel(value) { this.label.text = value; } } new Tween_Ea...

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