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

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

221. 加载-销毁Texture使用的图片资源 [ 80%]

...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.init(); } init() { const Sprite = Laya.Sprite, Animation = Laya.Animation, Text = Laya.Text, Event = Laya.Event; // 创建背景 this.spBg = Sprite.fromImage(PathBg); Laya.stage.addChild(this.spBg); // 创建动画 this....

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

222. Laya.loader.create 进度回调函数执行两次 [ 80%]

... Laya.loader.create(["Main/SMain.ls","Role/Role.lh"],Laya.Handler.create(this,this.on3DComplete),Laya.Handler.create(this,this.onProgress,null,false)); Manager.prototype.onProgress = function(value) { console.log("value=="+Math.floor(value*100)+"%"); }   输出结果: 0.19186599730944645 0.525199...

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

223. Dialog关闭时如何向open他的页面传值? [ 80%]

...是哪个按钮,抛出具体的事件并监听。 myClose.on(Event.CLICK,this,onClicks); myYes.on(Event.CLICK,this,onClicks); myNo.on(Event.CLICK,this,onClicks) } private function onClicks(e:Event):void { // TODO Auto Generated method stub if(e.target.name=="close") { open页面.event(CLOSE, [para...

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

224. 为什么没有on的方法? [ 80%]

...:Animator = hero.getComponent(Animator) as Animator; ani.on(Event.COMPLETE,this,onAniComplete,[ani]); 官方例子里这样写.但编辑器和运行都报错显示没on的方法 2018-11-23 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链...

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

225. this.bitmap.activeResource is not a function TypeError: this.bitmap.activeResource is not a function [ 80%]

this.bitmap.activeResource is not a function TypeError: this.bitmap.activeResource is not a function if (bitmap&&bitmap._addReference){ bitmap._addReference(); } 这个代码过滤已经加了,但是会报下面这个错 this.bitmap.activeResource is not a function TypeError: this.bitmap....

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

226. 播放视频只有声音没有图像 [ 80%]

...ginGame extends Laya.Scene { constructor() { super(); LoginGame.instance = this; Laya.MouseManager.multiTouchEnabled = false; this.loadScene("LoginGame.scene"); } onEnable() { SoundManager.playMusic("audio/梅林茂 - 静かな古都.mp3", 0); this.login_game_button.on(Laya.Event.CLICK, this,this.on...

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

227. UI-Clip [ 80%]

...Laya.loader.load([buttonSkin, clipSkin, bgSkin], laya.utils.Handler.create(this, onSkinLoaded)); })(); function onSkinLoaded() { showBg(); createTimerAnimation(); showTotalSeconds(); createController(); } function showBg() { var bg = new Image(bgSkin); bg.size(224, 302); bg.pos(Laya.stage.width - bg...

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

228. 2.0.1beta ctx.getImageData is not a function [ 80%]

...TypeError: ctx.getImageData is not a function. (In 'ctx.getImageData(0, 0, this._mbW, this._mbH)', 'ctx.getImageData' is undefined) url:undefined line:67259 column:43 id:1300147 TypeError: ctx.getImageData is not a function. (In 'ctx.getImageData(0, 0, this._mbW, this._mbH)', 'ctx.getImageData' is u...

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

229. playByFrame动画监听问题,真不会了。就一个小问题。监听不到动画结束。。。 [ 80%]

...?应该怎么用求教啊。。。。。 Laya.stage.on(Laya.Event.CLICK, this, function () {                 for (var i = 0; i < _outHitAllInfo.length; i++) {                     var name=_outHitAllInfo<em>.sprite3D.name;                     if(name=='anifish')...

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

230. 关于button的click监听 [ 80%]

...AAAA"; btn.pos(200,200); Laya.stage.addChild(btn); btn.on(Laya.Event.CLICK,this,()=>{console.log("click button");});   请问 这样监听不到button的点击事件吗?如果我创建一个ui.view  a  a.on 也监听不到吗 2017-11-28 添加评论 免费帖 --> 分享 微博 QZONE 微信 ...

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