How to make an offscreen actor spawn several types of actors at an increasingly faster rate?
Pro
Member Posts: 16
I have 6 separate types actors that serve as enemies. They all have varying drag, velocity, and size.
My goal is to create a spawner that will randomly spawn several types of these enemy actors at an increasing rate (slowly).
The game is a classic "Falling Balls" remake but with some new twists to make it fresh and different.
One small problem I had before (when testing 1 actor only) is when it would spawn a copy of "enemy" which I gave the Collision and velocity rules, but when it spawns the actor it is just the picture of it and it falls without having any of the features of the edited actor.
If there was a fix to this, and a working answer to my question, I would be very appreciative and thankful of whoever helps me out.
Thanks.
Comments
I am doing this in my games Zachary vs Aliens, SuperPaker and Gage's Dino Hunt. They are all in the arcade if you want to see how the end result works.
Basically, I have an off screen actor that works off a TimeToSpawn REAL variable. When the game.Time > TimeToSpawn then it execute the block of code.
1st, it resets the timeToSpawn to game.Time + spawninterval
(SpawnInterval can be slowly decremented in your case.)
Then, generate a random number between 1 and number of possible "enemy" types.
Do a rule that tests for random = 1, then spawn
etc.
I set a variable called level and another called monstersSpawned
When monsters spawned = 10+(5*level) then level = level +1
the spawninterval is 3 (seconds) - (.1 * level)
But you can do yours anyway you want.
@ookami007
I'm really not the most familiar with GameSalad (I only starting working with it 2 days ago) so it's a tad harder for me to understand.
I'm only familiar with behaviors, attributes, rules, etc. right now, so is there any way you could dumb it down a little bit?
It's a pain, but it would be really helpful.
I'm really struggling with this.