Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / attach all sprite together

Author
Message
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 30th Jan 2015 12:34 Edited at: 30th Jan 2015 12:39
Hi.

I created a Puzzle game and I want after finish game,move all sprite to custom Position (like Paintings) but I don't know how can attach all sprite together and change all Position at same time.

Please Guide me.

Thanks.
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Jan 2015 12:59
2 options:

1. Loop through all of the sprites and move them all the same distance in turn.

2. Make one of the sprites a static physics sprite and the rest dynamic physics sprites. Connect them all with weld joints. Moving the Kinetic sprite will then move them all.

Here's an example of option 2:



Quidquid latine dictum sit, altum sonatur
Behdadsoft
15
Years of Service
User Offline
Joined: 7th Apr 2009
Location: Tehran-Iran
Posted: 30th Jan 2015 15:53
Thanks BatVink, option 2 is better idea.

Login to post a reply

Server time is: 2024-11-25 17:47:52
Your offset time is: 2024-11-25 17:47:52