How can I do this?
So I have an actor that is on top of the scene and it's Y position is random.
Is it possible to have another actor on the bottom that uses the top actor's Y position to determine it's own Y position?
Think if it like flappy bird. The pipes are always going up and down but the gap is always same length between the two. It's like the bottom pipes uses the top pipe's Y position to determine it's own Y position.
Comments
Use the top actor to spawn the bottom actor. That way it will always be a certain distance under the top actor, based on the setting of the Spawn behavior.
@pHghost
Thanks
@pHghost
How would I spawn it? Using the spawn actor rule of course
I can't seem to get it to work
@Armelline
@ShortAxe5 -- what isn't working exactly, can you describe more?
Here is an example, check it out, and analyze what it does differently, so you understand why your isn't doing what you want it to.
The zip file isn't working for me for some reason, Ah well.
Anyone?
Are you on a mac?
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
@ShortAxe5,
The cleanest way would possibly be to:
1 and 2 are a must, 3 and 4 increase the difficulty / fun factors.
Good luck!
My Blog / App Store / Google Play
@The_Gamesalad_Guru
I'm on a pc
@mhedges
Thanks a lot! But is there anyway I could use the top actor to control the lower actor's y position instead of having something spawn them both?
Bump
Unlock the bottom actor and:
Constrain Behavior: self.Position.Y To:scene.Background.topActor.Position.Y-100
You can change the -100 to suit the gap you are looking for.
Ok thanks again guys!