7 Replies Latest reply on Aug 19, 2015 12:26 PM by Kinetogenic

    Rotating object around self while rotating around other object ?

    Omarb92

      How can these movements be done at the same time ? (ARROWS ARE JUST TO EXPLAIN WHAT THE MOVEMENT IS , THE ONLY OBJECTS ON SCREEN ARE THE STARS ) The blue arrows represent the movement of all stars around the center of the circle , and the red arrows represent the movement of each star around its own center ?

       

      star.PNG

        • 1. Re: Rotating object around self while rotating around other object ?
          Dave LaRonde Level 6

          Make the star.  Make a null layer; its Anchor point position defaults to the exact center of the comp.  Place the star as far away from the null as you'd like it and parent it to the null.  Animate the rotation of the null.  Animate the rotation of the star.  Done.

          • 2. Re: Rotating object around self while rotating around other object ?
            Omarb92 Level 1

            Dave ! Always helping me out Thanks a million

            • 3. Re: Rotating object around self while rotating around other object ?
              Omarb92 Level 1

              Hey there ! Well I tried that , but it only seems to make the large circle rotation work , so had to change the anchor point for the star in order to make it rotate around itself . is there anyway i can place its anchor point exactly at it's center so it can be rotating exactly around its center ?

              • 4. Re: Rotating object around self while rotating around other object ?
                Dave LaRonde Level 6

                Nope! You gotta tweak the anchor point until it's right.  The good news -- once it's right, you can duplicate it for the other stars.

                • 5. Re: Rotating object around self while rotating around other object ?
                  Rick Gerard Adobe Community Professional & MVP

                  First you need each star on a separate layer. I'd use a shape layer. Try this:

                  1. Create a new comp
                  2. Select the Polystar tool
                  3. Click anywhere in the comp window, hold down the shift key and drag out a star
                  4. Select the Shape layer tool and then press the U key twice to reveal everything that is not at the default position and value
                  5. Set the final size of your star by adjusting the inner and outer radius (keep 5 points for now, you can change that later)
                  6. Select the Transform Polystar 1> position property, right click and reset to center the star on the layer's anchor point
                  7. I would probably rotate using the layer's normal rotation property, but you could use the Transform Polystar 1 rotation property if you like
                  8. Animate your rotation
                  9. Add a null to the center of the comp
                  10. Move the first star shape layer straight up (adjust Y only) so that it is exactly where you want the circle's boundary to be
                  11. Duplicate the star shape layer select the duplicate and press the U key to reveal the animated rotation value and delete the keyframes
                  12. Select the rotation property of the duplicate and press the Alt/Option key to add an expression to the duplicate
                  13. Use the expression pickwhip and drag from the duplicate's rotation property to the original's rotation property to tie them together with the expression
                  14. With the duplicate selected duplicate the layer as many times as you want stars in your circle. If you want 4 stars you already have 2 so press Ctrl/Cmnd + D twice. If you want 10 then use the shortcut 8 more times.
                  15. You should now have all of the copies of the star in the same position above the null
                  16. Divide 360 by the number of stars you have (360 / 10 = 36) and memorize the number
                  17. Parent the top star to the null and rotate the null by the appropriate value (36º)
                  18. Parent the second star to the null and add the value to the rotation value by selecting rotation, moving the cursor to the right and typing + 36
                  19. Repeat until you have distributed all of the stars around the null in a circle
                  20. Animate the rotation property of the Null
                  21. If you want to change the speed or direction of all the stars select the original (maybe name it master so it is easy to find) and change the rotation animation. All others will follow because of the expression.
                  22. You're done. EZ PZ

                  Screen Shot 2015-08-18 at 5.50.27 PM.png

                  • 6. Re: Rotating object around self while rotating around other object ?
                    Omarb92 Level 1

                    Rick ! Thanks alot for taking the time with this detailed answer !

                    • 7. Re: Rotating object around self while rotating around other object ?
                      Kinetogenic Level 1

                      If you are in cc 12.1 or up, you don't necessarily have to tweak the anchor point until its right - you can also use the hotkey cmd+opt+home (mac) or ctrl+alt+home (windows) to set the anchor point to the center of the layer. If your star is geometrically perfect, I believe it will be the center.

                       

                      Also, depending on how you want the stars to relate to each other, it may be possible to do this all within one shape layer using a repeater if you want all of the stars spinning at the same rate.  I've included a screen shot below - pay special note to the use of a group, this allows you to transform the star off the origin before repeating it so that the star forms a circle.  Also I've added an expression here that uses the number of copies on the repeater to space them out automatically.

                      repeater.jpg

                      stars.jpg

                       

                      If you want the stars to move at different rates, or all have the same rotation in relation to the screen I think you may have to use Rick's method above which is also a great suggestion!