-1

http://madcomm.deviantart.com/art/System-generator-wip-611957633

This is what I am currently working on, and currently, I'm looking for a way (if any) to basically draw automatic, randomised asteroid belts.

The main idea I have, currently, would be to simply draw a circle with a pattern/stroke of asteroid sprites, but I have no idea how this could be achieved.

Ideally, the width and length of a circle of pattern would be randomised, then the sprites drawn.

Help would be greatly appreciated.

Current code to be found within the deviantart page.

Mostly looking for a way to paste objects over a circle I guess - such a function could be randomised, the circle behind "asteroid belt" wouldn't be particularly necessary. So either ability to draw a circle stroke of patterned sprites, or spawning sprites in a circular manner.

  • You should post the code here. You'll get more and better replies if people don't have to hunt for it on another site. – Neal Davis Jun 01 '16 at 16:52
  • Could you please include a picture of what you are trying to accomplish? If your link breaks, this question will be incomplete. So please create a quick sketch of the desired effect. – null Jun 01 '16 at 16:53
  • Literally on the link posted. The code. – Silver Seraphim Jun 01 '16 at 17:05
  • Literally, if that link breaks, there's no code in your question. – null Jun 01 '16 at 17:31
  • Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Questions without a clear problem statement are not useful to other readers. – Brian Jun 02 '16 at 16:18
  • Link cannot break. It's on a gallery. :U – Silver Seraphim Jun 05 '16 at 22:39

1 Answers1

0

I would have a planet object. Add your Sprite objects to it as children at a chosen distance away from the center of the planet. After each sprite object is added, and before the next one is added, rotate the planet a random amount, then add the next one. You would do this with a for loop. You could also add them at a range of distances so they aren't all the same distance from the planet.

Neal Davis
  • 2,010
  • 2
  • 12
  • 25