- Home /
Question by
ghostyx101 · Jul 03, 2017 at 12:39 PM ·
vrloopsphereloopingspherecollider
How do i make it rain spheres continuously in a loop in Cardboard SDK?
For an architect I'm trying to make an raining simulation with balls, but it has to loop after a short period, say 2 minutes? I tried this code but its only for 1 prefab
using System.Collections; using System.Collections.Generic; using UnityEngine;
public class rainBalls : MonoBehaviour {
public float fallSpeed = 8.0f;
public float spinSpeed = 250.0f;
void Update()
{
transform.Translate(Vector3.down * fallSpeed * Time.deltaTime, Space.World);
transform.Rotate(Vector3.forward, spinSpeed * Time.fixedDeltaTime);
}
}
how do I make it rain spheres from the top of the scene ant random positions?
Comment
Your answer
Follow this Question
Related Questions
Infinite Loop in void checkcard (memory game) 1 Answer
C# List looping Vector3's 2 Answers
Unity Movie Texture - Skipping First or Last Few Frames 0 Answers
Loop Coroutine For A Demo Mode 1 Answer
Sound not looping properly on device? 2 Answers