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

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

451. 发布微信小游戏,sprite的graphics.drawPoly安卓平台会引起花屏 [ 85%]

...等于0  var w: number = 642; var h: number = 12; var g: Laya.Graphics = this._mask.graphics; g.clear();   if (w == 0 || h == 0) return; var points: any[] = []; points.push(0, h); points.push(0, 0); points.push(this._index, 0); points.push(this._index, h); // points.push(0, h); g.drawPoly(0, 0, po...

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

452. 鼠标交互-Hold [ 85%]

...bgColor = "#232628"; Stat.show(); Laya.loader.load(apePath, Handler.create(this, this.createApe)); } createApe() { const Sprite = Laya.Sprite, Event = Laya.Event; this.ape = new Sprite(); this.ape.loadImage(apePath); let texture = Laya.loader.getRes(apePath); this.ape.pivot(texture.width / 2, textur...

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

453. unity导出的3D动画模型,导入 laya环境报错: node._setParent is not a function [ 85%]

...play(); chrome 调试:  addChild(node) {             if (!node || this.destroyed || node === this)                 return node;             if (node._zOrder)                 this._setBit(Const.HAS_ZORDER, true);             if (node._parent === this) {       ...

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

454. 点击区域问题 [ 85%]

... new laya.maths.Rectangle(-50,-100,100,100); sp.on(laya.events.Event.CLICK,this,this.spHandler); function spHandler() {     sp.graphics.clear();     var rc:number = Math.floor(Math.random()*0xffffff);     sp.graphics.drawRect(-50,-100,100,100,"#"+rc); } 这样多包几层,点击区域...

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

455. 使用官方文档中qrcode生成二维码的代码,打包APP后无效 [ 85%]

...te initCode() { var div: any = Laya.Browser.document.createElement("div"); this.qrcode = new Laya.Browser.window.QRCode(div, { width: 100, height: 100 }); var url: string = this.URL; this.qrcode.makeCode(url); Laya.stage.once("click", this, this.clickHandler); this.qrcodeSp = new Laya.Sprite(); Laya...

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

456. 3D中的Animator如何从指定的某一帧开始播放动画 [ 85%]

...Clip(totalAnimationClip,"runShoot",startFrame); animator.on(Event.STOPPED, this, this.removeClip); animator.on(Event.COMPLETE, this, this.removeClip); animator.play("runShoot"); 2018-07-26 0 1 分享 微博 QZONE 微信 Laya_Aaron 赞同来自: 这个要在unity 里面进行切片,从那一帧开...

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

457. 寻路导航示例中添加Laya.PathFind组件报异常 [ 85%]

...下: //获取可行走区域模型 var meshSprite3D: Laya.MeshSprite3D = this.scene.getChildByName('Scenes').getChildByName('HeightMap') as Laya.MeshSprite3D; //使可行走区域模型隐藏 meshSprite3D.active = false; var heightMap: Laya.Texture2D = Laya.Loader.getRes("../../res/threeDimen/scen...

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

458. List滚动条问题 [ 85%]

...下: (function (_super){ function MarketItem() { MarketItem.__super.call(this); this.size(312, 462); // {id:1,name:"10金豆-测试",price:0.01,title:"10金豆-测试",desc:"测试",balance:10,gift:0,imgPath:"res\\common\\BalanceSellDlg\\xiaodou.png",hot:1,orderCount:9} // 背景 var bg_image = ne...

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

459. 使用百度地图显示当前位置(ActionScript-LayaAir基础篇(AS3)-硬件设备相关) [ 85%]

...tion.enableHighAccuracy = true; Geolocation.watchPosition(Handler.create(this, updatePosition), Handler.create(this, onError));   // 绑定convertToBaiduCoord作用域 __JS__("this.convertToBaiduCoord = this.convertToBaiduCoord.bind(this)"); } ``` ​ 由于本例不需要使用LayaAir的...

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

460. 加载-错误处理和进度 [ 85%]

...fighter.png", "res/legend/map.jpg"]; Laya.loader.load(urls, Handler.create(this, this.onAssetLoaded), Handler.create(this, this.onLoading, null, false), Loader.TEXT); // 侦听加载失败 Laya.loader.on(Event.ERROR, this, this.onError); } onAssetLoaded(texture) { // 使用texture console.log("加...

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