|
I hv 10 cards prefabs and i want to intantiate all of them in scene under a group.. Deck is the parent(i want it to be), and card shud be children...so when i move my deck card will be moved ...so the problem is when i use intantiate every card is coming on each other and all mixed up they r now children but all mixed up... or other way all card are on scene on the right position while game but they do not hv parent (deck)... is there any way that i can put them in deck while gameplay using scrip... (part of scripting)
(comments are locked)
|
|
The question is a little unclear, but I notice you're assigning 'height' to 'localPosition', but then using 'position' when you create the object. If all the cards are being instantiated at exactly the same position, that might be the reason. yes if i m making the clone child of deck so its instatiating in the same position ... is there any way to select all cards i hv taged with "Card" while gameplay using scrip after instatiating them...if there it will also work for me ...
Apr 05 '11 at 10:01 AM
Craxter
You can use GameObject.FindGameObjectsWithTag() to find all active game objects in a scene with the specified tag.
Apr 05 '11 at 11:48 AM
Jesse Anders
(comments are locked)
|
