大约有 633 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0049 秒)
...mage加载图片资源的时候,如何判断加载失败? 伪代码: this.avatar.graphics.loadImage(url, 0, 0, 0, 0, __complete);这个时候,如果我的url为空或者为一个不存在的图片地址,我如何判断它加载失败呢? 我尝试使用了这样的代码来获取失败...
来源: Laya_社区 发布时间: 20170928
...null Laya.loader.load("res/dreams.mp3",Laya.Handler.create(this,function(){ dreamsSound = Laya.SoundManager.playMusic("res/dreams.mp3") })) let mainSound:Laya.SoundChannel = null; this.btn_sound.on(Laya.Event.C...
来源: Laya_社区 发布时间: 20190716
...wx报错 代码如下 private var wxLaya:* = wx; 编译后提示如下 wx This variable is not defined 2018-06-08 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 Laya_Aaron 赞同来自: zmhway as使用微信js的a...
来源: Laya_社区 发布时间: 20180608
...if (camera.useOcclusionCulling){ FrustumCulling.renderObjectCulling(camera,this,context,this._renders); }else { FrustumCulling.renderObjectCulling(null,this,context,this._renders); } 而被调用的函数中又直接用到了camera中的变量,传入null的就会报错
来源: Laya_社区 发布时间: 20190322
...artUI { constructor() { super(); this.btnStart.on(Laya.Event.CLICK, this, this.startGame); } startGame(): void { //Laya.Scene.open("GameView.scene"); if (!Main.gameView) { Main.gameVie...
来源: Laya_社区 发布时间: 20190510
...ntView设置为activity_main,laya的gameView添加到RelativeLayout来。this.setContentView(R.layout.activity_main); this.gameContainer = findViewById(R.id.game_container); this.banner_container = findViewById(R.id.banner_container); View gameView = mPlugin.game_plugin_get_view(); this.gameContai...
来源: Laya_社区 发布时间: 20191204
...llback(success:Boolean):void { if(success) { loadingRes(); } } "TypeError: this.loadingRes is not a function\n at RequestConfig.__proto.requestCallback [as _callback] 2017-01-18 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 ...
来源: Laya_社区 发布时间: 20170118
...premultiplyAlpha=false); var width=source.width; var height=source.height; this._width=width; this._height=height; this._setWarpMode(/*laya.webgl.WebGLContext.TEXTURE_WRAP_S*/0x2802,this._wrapModeU); this._setWarpMode(/*laya.webgl.WebGLContext.TEXTURE_WRAP_T*/0x2803,this._wrapModeV); this._setFilter...
来源: Laya_社区 发布时间: 20190809
...WebGLContext2D.fileRect()方法,具体行见截图 RenderContext类:this._drawRect=function(x,y,args){ var ctx=this.ctx; if (args[4] !=null){ ctx.fillStyle=args[4]; ct...
来源: Laya_社区 发布时间: 20161210
...背景色 Laya.stage.bgColor = "#ffffff" Laya.Stat.show() //资源路径 this.Res = "test.png"; this.img = new Laya.Image(); this.img.pos(200, 200) //获取图片资源,绘制到画布 this.img.skin = this.Res //添加到舞台 Laya.stage.addChild(this.img); } private cacheCanvas: Laya.HTMLCanvas ...
来源: Laya_社区 发布时间: 20171211