Platforms

guizanchettguizanchett Member Posts: 24
edited November -1 in Working with GS (Mac)
Hi, got a problem with the elevator platforms on my game.
When my character hits it on the sides, or jumps on it, it changes de course I determined. How do I do to keep the course and the speed when he jumps on it?

Comments

  • applaudmobileapplaudmobile Member Posts: 208
    does the platform have physics > movable on ? Should be off so it's not affected by collisions etc

    also if the platform goes up an down or side to side and repeats then its probably better to use interpolate than move to
  • ARC_GamesARC_Games Member Posts: 78
    depends on how you are dealing with the motion of the elevator platform, but as I understand it, the best way to do this is to use the Interpolate behavior for interpolating the elevator's position. That way, you can make the actor non-movable (i.e. Un-check the box for Movable in the attributes on the left), and it won't collide with any other actors or be interfered with by the motion of any other characters. savvy?
  • guizanchettguizanchett Member Posts: 24
    Yes, but it goes up and down. If i turn movable to off, it doesn't
  • guizanchettguizanchett Member Posts: 24
    So how do I do with interpolate? Never used it.
  • applaudmobileapplaudmobile Member Posts: 208
    yes it won't move with it off because you're using move to. use an "interpolate" behaviour like this

    rule > if self.position.y= 100 interpolate self.position.y to 200 3 seconds
    rule > if self.position.y= 200 interpolate self.position.y to 100 3 seconds

    the positions and time are examples you can play about to get it right and change the ease in-ease out settings as you wish

    hope this helps
  • guizanchettguizanchett Member Posts: 24
    will try it, thx a lot :D
Sign In or Register to comment.