Rotate Around Object At Different Positions

App SurgeApp Surge Member Posts: 651
edited January 2012 in Working with GS (Mac)
Hey there,
So I am having buildings orbit around a planet, and am following Tshirtbooth's orbiting tutorial. However, when I put in multiple buildings, they all orbit at exactly the same place, so it looks like there is only one. If I want them to be spread out, how would I do this?

If I did not explain this well I'll post a video.

Thanks,
Henry Abrams

Comments

  • JohnPapiomitisJohnPapiomitis Member Posts: 6,256
    im kinda out of it since its new years and all ;) but you would add a offset into your constrain for the orbit. Something along the lines of tacking on +90 or something on the end.
  • App SurgeApp Surge Member Posts: 651
    Thanks, but to which constraint? The self.position.y, the self.position.x, or the rotation?
  • App SurgeApp Surge Member Posts: 651
    Bump
  • App SurgeApp Surge Member Posts: 651
    Can anyone help me with this? I'll put up a video on a little bit.
  • App SurgeApp Surge Member Posts: 651
    Dang it, out of time to edit my old post :(
    Well here is a video of how I have my behaviors set up and the whole glitch.

  • App SurgeApp Surge Member Posts: 651
    Any ideas?
  • App SurgeApp Surge Member Posts: 651
    Thanks! Email sent :)
  • CloudsClouds Member Posts: 1,599
    @Redsky

    In the expressions for Constrain X and Constrain Y - place a value after the '%360' and before the closing bracket for the %360.

    So . . . . if you change . . . . %360) . . . . to %360+90) the objects rotation will be offset by 90°.

  • gotyoursgotyours Member Posts: 246
    can you make it rotate while the actor is moving?
  • vikingviking Member, PRO Posts: 322
    I tried this for my game and it works beautifully, so thanks for the heads-up :) However, I ran into one problem when I started speeding up the rotation every 10 seconds for both the main actor and the orbiting ones. Suddenly the actors orbiting the main actor jumped about 30 degrees. They still orbit the main actor at the correct speed, but their placement is now wrong. Not sure how to fix this... Only thing I can think of is that the self.position X and Y are now different from when the rotations started and that messes up the location...? Any ideas?
Sign In or Register to comment.