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

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

2051. 发布项目“是否压缩混淆js(耗时)”的bug [ 62%]

...道什么意思,很正常的语法都报错: [ERR]|CompressJS Fail: E:/new_work/client_deploy/bin/code.js {"message":"Unexpected token name «of», expected punc «;»","filename":"0","line":107395,"col":26,"pos":3691880} 2018-04-13 0 0 分享 微博 QZONE 微信 131*****785 赞同来自: 我直...

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

2052. IOS的safari浏览器打开h5项目demo,游戏场景偏移(附件有完整demo) [ 62%]

....screenMode = Stage.SCREEN_HORIZONTAL; //实例一个背景 var bg:Image = new Image(); bg.skin = "res/ui/bg.jpg"; Laya.stage.addChild(bg); //实例一个文本 var txt:Text = new Text(); txt.text = "适配模式("+Laya.stage.scaleMode+") "; txt.bold = true; txt.pos(10, 350); txt.fontSize = 60; txt....

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

2053. 使用HtmlDivElement取不到实际大小 [ 62%]

...TML(); // 使用外部定义的html } function createParagraph() { var p = new HTMLDivElement(); Laya.stage.addChild(p); p.style.font = "Impact"; p.style.fontSize = 30; var html = "<div>"; html += "<span color='#e3d26a'>使用</span>"; html += "<span style='color:#FFFFFF;font-we...

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

2054. 使用webgl之后toDataUrl返回黑色的图像 [ 62%]

...ya.stage.bgColor = "#ffcccc"; Laya.stage.on(Event.CLICK,this,onClick); sp= new Sprite(); sp.name='base'; sp.loadImage("logo.png"); Laya.stage.addChild(sp); } private function onClick():void { var htmlsss:String=(Laya.stage.getChildAt(0) as Sprite).drawToCanvas(100,100,0,0).getCanvas().toDataURL(); v...

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

2055. 多点触控的使用(JavaScript-3D基础(JS)-LayaAir3D之鼠标交互) [ 62%]

...osition.y; //根据移动的距离进行旋转 this.owner.transform.rotate(new Laya.Vector3(1 * deltaY /2, 1 * deltaX / 2, 0), true, false); } } else if (2 === touchCount){ this._text.text = "触控点为2"; this.isTwoTouch = true; //获取两个触碰点 var touch = this._scene.input.getTouch(0); v...

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

2056. 多点触控的使用(TypeScript-3D基础(TS)-LayaAir3D之鼠标交互) [ 62%]

...osition.y; //根据移动的距离进行旋转 this.owner.transform.rotate(new Laya.Vector3(1 * deltaY /2, 1 * deltaX / 2, 0), true, false); } } else if (2 === touchCount){ this._text.text = "触控点为2"; this.isTwoTouch = true; //获取两个触碰点 var touch = this._scene.input.getTouch(0); v...

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

2057. Spine适配版(JavaScript-LayaAir基础篇(JS)-动画基础) [ 62%]

...artFun(); } private startFun(): void { //创建动画模板 this.templet = new SpineTempletBinary(); this.templet.loadAni(this.aniPath); this.templet.on(Event.COMPLETE, this, this.parseComplete); this.templet.on(Event.ERROR, this, this.onError) } private parseComplete(): void { this.skeleton = this....

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

2058. 时间轴动画(JavaScript-LayaAir基础篇(JS)-动画基础) [ 62%]

...,加载动画文件 ```javascript //创建一个Animation实例 var tl = new Laya.Animation(); //加载动画文件 tl.loadAnimation("TimeLine.ani"); ``` 第三步:添加动画到舞台,播放动画 ```javascript //添加到舞台 Laya.stage.addChild(tl); //播放Animation动画 tl.play(); ```...

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

2059. 使用命名空间遇到的问题 [ 62%]

...用的地方,import * as global2 from "......global2/index";   let p = new global2.Point; 2019-03-07 0 0 分享 微博 QZONE 微信 Mr.余 赞同来自: 感觉还是有问题啊。 命名空间不好用,你多个文件同一个命名空间,你import的时候就会有问题。 ts里官方可...

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

2060. 关于graphics.drawPath手机端和PC端不一致的问题 [ 62%]

...aya.stage.scaleMode = "showall"; Laya.stage.bgColor = "#ffffff"; this.sp = new Sprite(); Laya.stage.addChild(this.sp); this.sp.graphics.drawPath(100, 100, [["moveTo", 100, 0], ["arcTo", 200, 0, 200, 100, 100], ["arcTo", 200, 200, 100, 200, 100], ["arcTo", 0, 200, 0, 100, 100], ["arcTo", 0, 0, 100, 0...

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