- Home /
How can i auto Position my Game Object?
The Question i asked isn't very descriptive so i'll add on here.
Alright guys i'm trying to do this just like a card game.
Let's say i click my card and clicked summon.
But then i also want to Summon another Card in my Area Zone.
Since i summoned a card in Zone 1 i want it to go into Zone 2 automatically.
and then if i got a card in Zone 2 I want it to go in Zone 3 automatically.
And ofcourse if my Zones are full then it won't allow the summon.
I'm Thinking of it like this. If i summon a Card in Zone 1 then that spot would be occupied. And if that spot is occupied then it'll summon in Zone 2. If Zone 2 is Occupied and so on.
I was wondering if this had to be done with For Loops and While loops.
Like.
var Zones : GameObject [];
and then make a For or While Loop that'll count up to the Zones. And if they're occupied then of course it'll skip to the next number.
If that is the way you have to do it. Then Can some body please give me a hand? I'd really appreciate it cause this 1 is pretty tough for me.
Your answer
Follow this Question
Related Questions
How to tell if two blocks are right next to each other?(2D) 1 Answer
The name 'Joystick' does not denote a valid type ('not found') 2 Answers
How to tell if 2 blocks are next to each other in a 2d game? 1 Answer
how can i fix a object in a particular place of another mesh or object by click on it 2 Answers
How to access variables from an object based on location? C# (Pic inside) 1 Answer