Instantiate only once in Update and be able to use the clone variable in a switch statement(in Update).
Hi, I am trying to create object pooling in my script, For that I only want to Instantiate an object once and use it in a switch statement(All of this is in a separate void function. Then I put this function in Update(). Since I'm putting the void function in Update, the instantiate is creating too many clones. How can I solve this problem?
Any Help is appreciated!
Can you post some code? Also, that is not what object pooling is, as you are not using a pool of objects, but that's irrelevant for now.
Answer by Arsh7 · Nov 13, 2015 at 12:18 AM
I solved the problem, but thanks for replying!
How did u solve this problem? Please share to help others like me !
Your answer
Follow this Question
Related Questions
Instantiate prefab 0 Answers
Instantiate isnt working for spawner class 1 Answer
How can I make an object clone in the time that I indicate it to appear? 0 Answers
Edit bool on another script and object. 1 Answer
Wont instantiate game object 1 Answer