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

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

1. 加载.lh文件 运行后黑屏 无法显示 [ 100%]

... import GameConfig from "./GameConfig";  class Main {     //private scene:Laya.Scene3D;     private text:Laya.Text;     private _upVector3:Laya.Vector3 = new Laya.Vector3(0, 1, 0);     constructor() {         this._upVector3 = new Laya.Vector3(0, 1, 0);         Laya3...

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

2. 针对2.0.0 beta5 setLoadingPage 做增强 [ 98%]

...法 */ export default class LoadPage { constructor(url = null) { this._loadScene = null if (url) this.preload(url) } /** * 预加载loading页面 * @param {String} url loading页面url */ async preload(url = 'loadingpage.scene') { if (this._loadScene && url === this._loadScene.url) return le...

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

3. (实现手指控制模型的缩放旋转)触控可以识别 但是导入的模型没有根据触控反应 [ 98%]

...  //预加载所有资源         var resource = [{url: "Box/LayaScene_JJF/Conventional/JJF.lh"}];         Laya.loader.create(resource, Laya.Handler.create(this, this.onComplete)); } onComplete(){ //创建场景         var scene = Laya.stage.addChild(new Laya.Scene3D()); ...

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

4. 3D场景销毁后,仍有引用存在,内存中场景及引用其的对象无法销毁 [ 97%]

...,内存中场景及引用其的对象无法销毁         this.scene = Laya.stage.addChild(new Laya.Scene3D()) as Laya.Scene3D;          this.camera = new Laya.Camera();         this.camera.transform.translate(new Laya.Vector3(0, 2, 5));         this.cam...

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

5. 微信小游戏运行导出项目的时候报错:Scene: the .lh file root type must be Scene [ 96%]

微信小游戏运行导出项目的时候报错:Scene: the .lh file root type must be Scene 引擎使用的是1.7.17beta版本,下面是报错堆栈,附件是工程项目以及导出的小游戏项目。 Scene: the .lh file root type must be Scene,please use other function to  load  this fil...

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

6. 微信小游戏中加载unity导出的场景报错the .lh file root type must be Scene [ 95%]

...小游戏中加载unity导出的场景报错the .lh file root type must be Scene 报错:the .lh file root type must be Scene。 看了下代码,是读取的.ls文件并不是按照数组方式读取的,而是安装字符串读取进来的,所以导致判断type失败:       /**    ...

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

7. rigidBody.applyForce 物体不会移动 [ 95%]

...动也不动的 ​ export default class GameUI { //宣告場景 private scene: Laya.Scene3D; private camera: Laya.Camera; private directionlight: Laya.DirectionLight; private character: Laya.Sprite3D; private monster_character: Laya.Sprite3D; private translateW: Laya.Vector3 = new Laya.Vector3(0, 0...

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

8. 2.0版本可用的CameraMoveScript.ts [ 94%]

...er = 0.00006;     protected camera: Laya.BaseCamera;     protected scene: Laya.Scene3D;      constructor() {         super();      }      /**      * @private      */     protected _updateRotation(): void {         if (Math.abs(this.yawPitchRoll.y) &...

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

9. Camera.viewportToRay中origin与direction相等问题 [ 94%]

...anager.instance.mainCamera.viewportPointToRay(this._rayPt, this._ray); let scene = this.owner.scene as Laya.Scene3D; scene.physicsSimulation.rayCast(this._ray, this._raycastHit); console.log(this._raycastHit.succeeded); if(this._raycastHit.succeeded) console.log(this._raycastHit.collider.owner.name)...

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

10. viewportPointToRay产生的射线始终有偏差,是为什么? [ 93%]

... 0 0 分享 微博 QZONE 微信 watsonsong 赞同来自: 我添加了一个SceneScript来绘制Ray的射线,发现确实位置不正确: import Camera = Laya.Camera; import PhasorSpriter3D = Laya.PhasorSpriter3D; import Ray = Laya.Ray; import RenderState = Laya.RenderState; import Script = Laya....

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