I want to place some objects randomly, but make sure they dont overlap. I am using families because I also want to set some instance variables at the same time. Say the family of sprites is called "ships"
I can do something like this:
on start of layout
for each ships -> ships -> set X to ...
-> set myinstanceVar to ...[/code:2px6zc52]
Now I want to do something like "if ships is overlapping ships then start again for this ship" WITHIN the for each ships, but cant figure out how to do this.
I thought of using some nested functions, but you dont seem to be able to pass objects to functions (unless you pass the UID as an integer), which makes it harder.
I saw some function examples with "remember picked object" set somewhere, but could not find this feature. Anyone got a hand example?