c# - Spawn after throw in unity -


i want object respawn after 1 second when throw object air.i tried below code cant figure out solution.if please me solving problem!

public transform[] spawnpoints; public gameobject ball; public gameobject lastball;  void update(){     {         int spawnindex = random.range (0, spawnpoints.length);         lastball = instantiate (ball, spawnpoints [spawnindex].position, spawnpoints [spawnindex].rotation) gameobject;     } } 


Comments

Popular posts from this blog

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -