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

大约有 1,144 项符合查询结果, 库内数据总量为 30,724 项。 (搜索耗时: 0.0046 秒)

801. LayaBox HelloWorld实战 [ 60%]

...oWorld extends Laya.Scene { constructor() { super(); HelloWorld.instance = this; } onBtnShowClick(){ var dialog = new Laya.Dialog(); dialog.width=300; dialog.height=600; //var bg = new Laya.Image('comp/img_bg.png'); //dialog.addChild(bg); var button = new Laya.Button('comp/button.png'); button.label...

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

802. matter中有没有类似于unity中的OnCollision碰撞检测函数呀,用js怎么写 [ 60%]

...来自: 么有。这个我给你个demo,你自己看看。 1.初始化 this.Matter.Events.on(this._engine, 'collisionActive', this.onCollision);   2.碰撞检测 private onCollision(event): void { console.log("碰撞了..");  var home = _gamePage._mainPage._playPage;  for(var i = 0; i < even...

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

803. srpite 绑定startDrag事件没有出发 [ 60%]

...发 srpite 绑定startDrag事件没有出发 football.on(Event.MOUSE_DOWN, this, onStartDrag(e)); football 是一个sprite function onStartDrag(e){ alert("拖动事件") } 2017-02-15 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 ...

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

804. 2.2.0beta2中,ui使用相对布局时初始化会报错 [ 59%]

...,设置了相对坐标 然后在初始化ui时报错 debug发现是因为this._widget没有值,   和以前的版本对比,是因为this._widget和super()的位置对调了,导致在createChildren()时_widget还没有进行初始化   2.2.0beta2   以前的版本   附件 : --> LayoutTes...

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

805. 鼠标点击无效 [ 59%]

...宽高就可以了 roleAni.size(width,height); roleAni.on(Laya.Event.CLICK,this,function): 13995580072 • 2017-11-21 17:24 非常感谢,就是没有宽和高引起的

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

806. App Updates for HTML5 Apps 这意味着iOS端就废了? [ 59%]

... Store, we have always specified that apps must be self-contained bundles. This means that the core features and functionality of the app must be contained within the binary of the software, rather than made possible by referring users outside of the approved app, including through the use of HTML5....

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

807. 如何监听键盘组合键 [ 59%]

...接 提交 2 个回复 Laya_XS 赞同来自: Laya.stage.on(Event.KEY_DOWN, this, _onKeyDown); 然后你根据Keyboard对应的keycode来判断是什么键即可 2018-04-06 0 0 分享 微博 QZONE 微信 akunone 赞同来自: laya.events.KeyBoardManager.hasKeyDown(laya.events.Keyboard.CONTROL) 2019-0...

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

808. skeleton 里的label 事件怎么设置的啊 [ 59%]

... 个回复 cuixueying 赞同来自: 直接让你的skeleton.on(Event.LABLE,this,onLabel)去注册监听即可!  2017-03-31 0 0 分享 微博 QZONE 微信 uncle1980 赞同来自: 我是想问这个label 怎么设置在哪一帧触发 不是怎么监听。 2017-04-01 0 0 分享 微博 QZONE 微信 ...

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

809. 微信小游戏内TextInput不能实现只输数字的功能 [ 59%]

...实现了,虽然笨了点,但还能用 let input = new Laya.TextInput(); this.addChild(input); input.width = 100; input.height = 50; input.on(Laya.Event.BLUR, this, e=>{ let str = input.text.split(''); for (let i = 0; i < str.length; i++) { let isNotNumber = true; for (let j = 0; j < 10; j+...

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

810. 鼠标右键监听无效 [ 59%]

...览器运行的,没有调用test方法 Laya.stage.on(Event.RIGHT_CLICK,this,test) 2019-10-23 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 李友涛 赞同来自: 你好,问题解决了吗 2019-12-17 0 0 分...

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