- Timestamp:
- 2015-01-22T14:28:16+13:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
other-projects/nz-flag-design/trunk/render-3d/weather/rain.js
r29634 r29694 14 14 15 15 // create the particle variables 16 this.particleCount = 3500,16 this.particleCount = 10000, 17 17 this.particles = new THREE.Geometry(), 18 18 this.pMaterial = new THREE.ParticleBasicMaterial({ … … 32 32 // create a particle with random 33 33 // position values, -250 -> 250 34 var pX = (Math.random() * 3000) - 1500,35 pY = Math.random() * window.innerHeight * 3- window.innerHeight,36 pZ = (Math.random() * 3000) - 1500;34 var pX = (Math.random() * 10000) - 5000, 35 pY = Math.random() * window.innerHeight * 6 - window.innerHeight, 36 pZ = (Math.random() * 10000) - 5000; 37 37 this.particle = new THREE.Vector3(pX, pY, pZ); 38 38 … … 72 72 // check if we need to reset 73 73 if(this.particle.y < -10) { 74 this.particle.y = (window.innerHeight* 2)+(Math.random() * 100);74 this.particle.y = (window.innerHeight*6)+(Math.random() * 100); 75 75 this.particle.velocity.y = 0; 76 this.particle.x = (Math.random() * 4000) - 2000;77 this.particle.z = (Math.random() * 4000) - 2000;76 this.particle.x = (Math.random() * 10000) - 5000; 77 this.particle.z = (Math.random() * 10000) - 5000; 78 78 79 79 }
Note:
See TracChangeset
for help on using the changeset viewer.