Search Unity

Horizontal moving platform moves with player/camera?

Discussion in 'Editor & General Support' started by HarpDernier, Oct 24, 2014.

  1. HarpDernier

    HarpDernier

    Joined:
    May 30, 2013
    Posts:
    6
    So in a 2d platformer we have our vertical and horizontal moving platforms. The vertical ones work just fine but for some reason the horizontal ones will either move faster if the character is moving(by air or ground) the same direction as the platform, or the platform will stop completely if the character is moving in the opposite direction that the platform is moving. Therefore if you're jumping for the platform as it's coming to you it will stop it's movement until you stop moving again thereby often making you miss the jump. Alternatively if you jump for a platform that's moving away from you it will speed up out of your way and you'll miss the platform like that too. Any ideas? I can post script if need be. Should also be noted that my scene uses paralaxing though it isn't applied to the platform, and that this behavior was happening both before and after applying another script to parent the character the said platform while it's being stood upon.
     
  2. HarpDernier

    HarpDernier

    Joined:
    May 30, 2013
    Posts:
    6
    Haha never mind literally figured out within a minute after posting this that I had accidentally parented to the platform to a background object that was being affected by the paralaxing script.
     
  3. lovekutes

    lovekutes

    Joined:
    Oct 24, 2014
    Posts:
    1
    Therefore if you're jumping for the platform as it's coming to you it will stop it's movement until you stop moving again thereby often making you miss the jump. I think it
    ebog, z6, frip