Questions about a spawning a grid full of actors (Or not necessarily a grid...)
I have no idea where to start on this game idea I have.
The grid of squares would be spots I want an actor(s) to spawn. Would I need to start with the full grid of actors laid out like this? Or would it better to use tables to spawn them in certain places? How would I do this? How would I give GameSalad a list of coordinates to spawn them on? Would I need the X and Y positions on a table for each spot? Or spawn them inside or on top of an actor that is already in that position?
Basically I want a grid laid out. But nothing would move along the grid. The grid just represents places where actors become "active". Once active they have a certain amount of time to meet a condition. If met nothing would happen and the actor would either be destroyed or given a different image to display or a different kind of actor would be able to spawn on it's position. If not met the big #1 blocks off the smaller #1's around it's place on the grid. The actors becoming active or spawning on the grid would be in random positions.
I also do not want more than one actor spawned/active on the same spot. But more than one can spawn at the same time. I would like to control how many spawn at the same time. The smaller number 1's could overlap, but not the big 1's.
Any help would be awesome!
Comments
Does the below template help?
I will send you a link as were not allowed to post here.
No need for tables if you're just evenly spacing actors on a grid. I started making a demo to post last week but didn't finish it. I'm sure someone else has a demo or can explain the process but basically you would use a loop that changes the X position and then checks to see when the X position is at the edge of the scene and changes the Y position and resets the X position to the start of the "row."
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User
Another free one that will help is below.
http://www.deepblueapps.com/collisions-with-tables-template/
Thanks for the vid! But I'm not too sure if that is exactly what I am looking for. I won't have an actor moving on top of them an activating them as he moves by them. I really just need to spawn an actor and if it's condition is not checked it spawns another actor on all 8 of the other actors around it. And it is on the side it would be missing 3 of the side actors or in a corner it would only have 3. Maybe your template is helpful in a way I don't quite understand?
Hey, @tatiang! Thanks for the reply. That sound pretty complicated. I'm not sure how to go about that. :P
Try my 2nd post above it uses the same method as Tat was on about.
@DeepBlueApps I actually have the second one you posted. And maybe it would be easier to use the table method but I would have to have some way to affect the tiles around an actor. Im pretty stumped on this.
example: Actor is spawned, time runs out to meet the condition, all 8 surrounding actors are turned off? Well I guess that wouldn't really work because I would need more than just an on and off state...