Position Sprites in Circlular Pattern

Get help using Construct 2

Post » Tue Mar 19, 2013 7:19 pm

Im trying to figure out how to position sprites in a circular matter. So everytime I click it creates a sprite, and sets it to the correct position to continue the circle pattern. I just can't figure out how to find the position where the sprite needs to go to continue the circle and allow the circle to keep expanding to bigger sizes? I'm pretty bad at math, but I guess you could call it a algorithm? I'm not sure. Any help anyone can give me is appreciated. I made this pro text representation to hopefully explain better. Thanks!


1st Click to 5th click:
(ignore the periods, just there for placement. the X's represent sprites)

X

XX

XXX

..X
XXX

..X
XXX
..X

Etc...Skillasaurus2013-03-19 19:21:18
B
6
S
1
Posts: 31
Reputation: 1,237

Post » Tue Mar 19, 2013 8:52 pm

Create all the sprites beforehand and make them invisible. Then make one visible every click:

On mouse clicked
sprite is invisible
pick sprite closest to (320,240)
make sprite visible
B
79
S
24
G
54
Posts: 4,746
Reputation: 40,755


Return to How do I....?

Who is online

Users browsing this forum: fredriksthlm, MPPlantOfficial, Yahoo [Bot] and 16 guests