Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Torus
- var torus = BABYLON.Mesh.CreateTorus("torus", 4, 2, 30, scene, false);
- // Animations
- var alpha = 0;
- scene.registerBeforeRender(function () {
- torus.rotation.x += 0.001;
- torus.rotation.z += 0.02;
- torus.position = new BABYLON.Vector3(Math.cos(alpha) * 30, 10, Math.sin(alpha) * 30);
- alpha += 0.001;
Advertisement
Add Comment
Please, Sign In to add comment