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

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

251. 缓动-时间线 [ 72%]

...); timeLine.on(Event.LABEL, this, this.onLabel); } function onComplete() { console.log("timeLine complete!!!!"); } function onLabel(label) { console.log("LabelName:" + label); } function keyDown(e) { switch(e.keyCode) { case Keyboard.LEFT: timeLine.play("turnLeft"); break; case Keyboard.RIGHT: timeL...

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

252. as3字符串截取int的问题 [ 72%]

...g.gamrRoomEnterPower; },function(value){ DConfig.gamrRoomEnterPower=value; console.log(DConfig.gamrRoomEnterPower.length); console.log(DConfig.gamrRoomEnterPower); for (var i=0;i < DConfig.gamrRoomEnterPower.length;i++){ DConfig.gamrRoomEnterPower=int(DConfig.gamrRoomEnterPower[i]); } });[/i] 201...

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

253. [LayaAir3]Pool对象池获取继承对象时会返回基类对象 [ 72%]

... Laya.Script { onStart() { let item1 = Laya.Pool.createByClass(TestClass); console.log('item1:', item1.type); Laya.Pool.recoverByClass(item1); let item2 = Laya.Pool.createByClass(TestClass2); console.log('item2:', item2.type); console.log(item1 == item2); } } export class TestClass { type = 0; } exp...

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

254. 版本号:2.0.2 beta, 在sound文件夹下音乐播放不了,放入到res文件夹下可播放 [ 72%]

...tring:string = "./sounds/hit.wav";  private onPlayMusic(e: Event): void { console.log("播放音乐"); SoundManager.playMusic(this.musicString, 1, new Handler(this, this.onComplete)); }  private onPlaySound(e: Event): void { console.log("播放音效"); SoundManager.playSound(this.soundString, 1, ...

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

255. websocket服务端显示连接成功,客户端未进行回调 [ 72%]

...p udp //创建server服务 var server = net.createServer(function (conn) { console.log('new connection is connecting') conn.write('\n hello buddy') }); server.listen(8081, function () { console.log('server is listening') // server.emit('connection'); }); 2019-04-23 添加评论 免费帖 --> 分享 ...

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

256. 不带格式后缀的图片无法成功加载 [ 72%]

...aya.Handler.create(this, () => { let picTemp = Laya.Loader.getRes(url); console.log(picTemp.width) // undefined let nodee = new Laya.Sprite() nodee.texture = picTemp nodee.width = 500 nodee.height = 250 nodee.x = 100 nodee.y = 350 Laya.stage.addChild(nodee) }));上面这个图片无法正常显...

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

257. Button 添加事件不执行? [ 72%]

... clickHandler); rightBtn.clickHandler = Handler.create(this, function () { console.log('click handler'); }); function clickHandler () { console.log('on click') } Stage.addChild(rightBtn);  请问一下,为什么事件不执行啊? 2018-03-09 添加评论 免费帖 --> 分享 微博 QZONE 微信...

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

258. HTMLCanvas Laya.stage.addChild(HTMLCanvas); 挂载到舞台报错 [ 72%]

...);      div.size(600,400);      Laya.stage.addChild(div);      console.log(div);  var myChart = echarts.init(div.getCanvas());  // 指定图表的配置项和数据 var option = { title: { text: 'ECharts 入门示例' }, tooltip: {}, legend: { data:['销量'] }, xAxis: { data: ["衬衫...

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

259. vivo小游戏分包指南(TypeScript-小游戏适配文档-vivo小游戏) [ 72%]

...adTaskA = qg.loadSubpackage({ name: 'sub1Name', success: function (data) { console.info('加载分包 sub1Name 成功') }, fail: function (err) { console.info('加载分包 sub1Name 失败', err) }, complete: function(){ // 不管分包加载成功还是失败都会执行此回调 } } ) ``` 加载...

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

260. 布局后的对象的x y坐标如何获取? [ 72%]

...了centerX 和centerY后,就无法获取到这个Box的坐标了呀? console.log(this.test1.x ) //结果是 0  但console.log 这个对象,可以看到_x _y 的坐标   请问如何获取到这个被布局后的x y坐标呀? 附件 : --> 2019-07-01 添加评论 免费帖 --> 分享 ...

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