How to spawn actors with no overlaping?

dreamZdreamZ Member Posts: 103
edited November -1 in Working with GS (Mac)
Thanks all the dudes here for replying my question so quick : )

My question is how to spawn actors on my scene without overlapping them?
click the image below to see what i mean..

http://i4.photobucket.com/albums/y119/terryow/ScreenShot2011-09-08at123838AM.png

as you can see some of the boxes are overlapping each other...

Comments

  • monsterpunchmonsterpunch Member Posts: 37
    Make the actor of the red box Collide with actor of type RedBox or whatever it is. The newest red box that spawns will be immediately pushed out of the other one. I hope that helps.

    Or, a more complex option.

    Make a rule, that if Colliding with Redbox, spawn actor (X, Y, location + 20) or whatever you want.
  • dreamZdreamZ Member Posts: 103
    What if i want all the spawn actors stay wherever they are.. without pushing out at the same time not overlapping by newest actors?
  • RazSalad89RazSalad89 Member Posts: 1
    I really hope someone can help me out. I have an enemy actor who walks a defined path and i have another player actor fixed at a location along the path. The player actor can be clicked to summon a fireball actor. The fireball actor then does damage to the enemy actor provided it collides or overlaps that actor. The problem is that when you click the player actor at any time it will do damage to the enemy actor, it doesn't account for the distance between the actual fireball and the enemy actor. Can someone help me out with this. please.

    Thank you
  • ValanValan Member, BASIC Posts: 410
    Add a rule to destroy a square when it overlaps with another square.

    To stop seeing squares spawning and deleting add an alpha fade that starts a fraction of a second after spawning.
Sign In or Register to comment.