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

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

31. 3D模型x方向角度不为0,时。挂刚体和碰撞器。在rotate y方向时。模型会乱转,不挂就没问题 [ 89%]

...题   模型x转了-90度   console.log(angle, " lastangel ", this.owner.transform.rotationEuler.y) this.lastAngle = this.owner.transform.rotationEuler.y; this.owner.transform.rotate(new Vector3(0, angle - this.lastAngle, 0), false, false) 打印出来看到y方向角度一直在变。   如果...

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

32. 为什么rotation、scale赋值了不管用? [ 89%]

...3D: this.role3D = Laya.MeshSprite3D.load("3d/ben/Export.lh") this.role3D.transform.scale = new Laya.Vector3(0.5,0.5,0.5); this.role3D.transform.position = new Laya.Vector3(0,20,0); 以上的scale、position设置均不起作用,但是我放到frameloop里就有用,请问这是为什么?要...

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

33. Mesh网格-自定义网格 [ 89%]

...cene()); var camera = scene.addChild(new Laya.Camera(0, 0.1, 100)); camera.transform.translate(new Laya.Vector3(0, 2, 5)); camera.transform.rotate(new Laya.Vector3(-15, 0, 0), true, false); var directionLight = scene.addChild(new Laya.DirectionLight()); directionLight.color = new Laya.Vector3(0.6, 0...

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

34. LayaAir3D 坐标系统与矩阵变换 [ 89%]

...相机 var camera:Camera = scene.addChild(new Camera()) as Camera; camera.transform.position = new Vector3(0, 3, 3); camera.transform.rotate(new Vector3( -45, 0, 0), true, false); camera.addComponent(CameraMoveScript); //生成平面,其实是一个box,只不过高度很小,可看成一个平...

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

35. 如何动态获取image的宽高? [ 88%]

...jd); tf.translate(thisp.x,thisp.y); var otf:Matrix=new Matrix();//photoimg.transform?photoimg.transform:new Matrix(); //trace("jjjj1",photoimg.x,photoimg.y,photoimg.width,photoimg.height,photoimg.rotation); photoimg.transform=otf.concat(tf); image图片 通过矩阵旋转, bug1 如果设置缩放 ...

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

36. UNITY导出的模型旋转不了 [ 87%]

...ate(null, function(sp) { //let obj = sp; let obj = scene.addChild(sp); obj.transform.scale = new Laya.Vector3(4, 4, 4); obj.transform.rotate(new Laya.Vector3(0, 0.9, 0)); obj.addComponent(BoxControlScript); //旋转方向与角度设置 //var vect = new Laya.Vector3(0,1,0); //每10毫秒旋转一次...

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

37. 3d模型位置设置 [ 86%]

...位置 赋给 另一个位置 应该怎么写,怎么才能生效呢? A.transform.translate(B.transform.position,false); A.transform.rotate(B.transform.rotation,false,false) ; 2017-12-27 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的...

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

38. 高级应用-实时阴影 [ 85%]

...cene()); var camera = scene.addChild(new Laya.Camera(0, 0.1, 100)); camera.transform.translate(new Laya.Vector3(0, 0.7, 1.2)); camera.transform.rotate(new Laya.Vector3(-15, 0, 0), true, false); var directionLight = scene.addChild(new Laya.DirectionLight()); directionLight.direction = new Laya.Vector...

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

39. 使用3D精灵 · LayaAir3.0文档 · LAYABOX [ 85%]

...节点的关联关系,使变换操作更灵活,每个精灵都有一个Transform3D。 (图2-9) 我们也可以在编辑器里手动调整精灵的变换 (图2-10) (图2-11) 图2-10用来调整精灵的旋转,图2-11用来调整精灵的缩放 (图2-12) 图2-12可同时用来调...

来源: Laya3.0_文档 发布时间: 20240624

40. 怎么让模型原地依照Y轴旋转到 我指定的角度? 角度 如何 转换成 Y轴旋转 的四元数? [ 85%]

...。使用这个方法就可以直接把第二个问题绕开了。 var t:Transform3D; t.localRotationEuler = new Vector3(0, 45, 0); 不过在这里还是贴一下使用代码: var q:Quaternion = new Quaternion(); Quaternion.createFromYawPitchRoll(45,0,0,q);   2017-09-19 1 0 分享 微博 QZONE 微...

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