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

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

1. laya.d3.math.RandX_API3.0 [ 100%]

...rarchy RandX Index Constructors constructor Properties defaultRand Methods random randomint Constructors constructor new RandX(seed: any[]): RandX Defined in laya/d3/math/RandX.ts:18 创建一个 Rand 实例。 Parameters seed: any[] 随机种子。 Returns RandX Properties Static defaultRand defaul...

来源: Laya3.0_api 发布时间: 20231115

2. laya.d3.math.RandX [ 89%]

...MethodDefined By  RandX(seed:Array) 创建一个 Rand 实例。 RandX  random():Number 返回[0,1)之间的随机数。 RandX  randomint():Array 通过2x32位的数组,返回64位的随机数。 RandXProperty DetaildefaultRandpropertypublic static var defaultRand:RandX基于时间种子的...

来源: laya_api 发布时间: 20170929

3. laya.d3.math.RandX [ 89%]

...MethodDefined By  RandX(seed:Array) 创建一个 Rand 实例。 RandX  random():Number 返回[0,1)之间的随机数。 RandX  randomint():Array 通过2x32位的数组,返回64位的随机数。 RandXProperty DetaildefaultRandpropertypublic static var defaultRand:RandX基于时间种子的...

来源: Laya2.0_api 发布时间: 20190513

4. 3D灯光与阴影 · LayaAir3.4 · 引擎文档 · LAYABOX [ 80%]

...ntLight.addComponent(Laya.PointLightCom); pointLightCom.range = 2.0 + Math.random() * 8.0; pointLightCom.color.setValue(Math.random(), Math.random(), Math.random(), 1); pointLightCom.intensity = 6.0 + Math.random() * 8; moverLights[i] = pointLight; offsets[i] = new Vector3((Math.random() - 0.5) * 10...

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

5. 3D性能优化 · LayaAir3.4 · 引擎文档 · LAYABOX [ 66%]

...lt; this._colorNums; i++) { let offset = i * 4; colorBuffer[offset] = Math.random(); colorBuffer[offset + 1] = Math.random(); colorBuffer[offset + 2] = Math.random(); colorBuffer[offset + 3] = 1; } //设置uniformbuffer this.batchMat.setBuffer("colormap", colorBuffer); } //随机生成_spriteNums数...

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

6. 5以内的随机数怎么生成 [ 66%]

...邀请: 与内容相关的链接 提交 1 个回复 Sky 赞同来自: Math.random()*5 这问题百度就出来了,比帖子快 2018-07-18 0 1 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 程序未响应 相关问题 laya2的Scene默认...

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

7. 怎么生成唯一的随机数啊 [ 65%]

...相关的链接 提交 1 个回复 cuixueying 赞同来自: 直接用Math.random生成随机数即可! 2017-03-20 0 3 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 h690759643 相关问题 laya2的Scene默认是文件模式,不会生成...

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

8. 和原生Dom交互 · LayaAir3.4 · 引擎文档 · LAYABOX [ 50%]

... window.onclick = function() { // Fill the buffer with white noise; //just random values between -1.0 and 1.0 for (var channel = 0; channel < channels; channel++) { // This gives us the actual ArrayBuffer that contains the data var nowBuffering = myArrayBuffer.getChannelData(channel); for (var i ...

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

9. 2D性能优化 · LayaAir3.4 · 引擎文档 · LAYABOX [ 48%]

...(var i=0;i<10000;i++) { this.text=new Laya.Text(); this.text.text=(Math.random()*100).toFixed(0); this.text.color="#CCCCCC"; this.text.x=Math.random()*550; this.text.y=Math.random()*400; textBox.addChild(this.text); } Laya.stage.addChild(textBox); } } 下面是笔者电脑上的运行时截图,...

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

10. 3D物理系统 · LayaAir3.4 · 引擎文档 · LAYABOX [ 36%]

...private addCone(): void { //生成随机值半径和高 let raidius = Math.random() * 0.2 + 0.2; let height = Math.random() * 0.5 + 0.8; //创建圆锥形3D模型节点对象 let cone = new Laya.Sprite3D; let coneMesh = cone.addComponent(Laya.MeshFilter); let coneRender = cone.addComponent(Laya.Mesh...

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