playMaker

Author Topic: Grabbing a ledge?  (Read 3728 times)

Red

  • Hero Member
  • *****
  • Posts: 563
Grabbing a ledge?
« on: August 17, 2012, 03:34:52 PM »
So, a side project i'm working on is a 2d side-scrolling platform and i've got in the plans ledges that i want the player character to be able to grab and either climb up onto or jump off from...

i can gather the animation and triggers required but since i'm using the 2d platforming script that comes with the platforming tutorial, i'm having a bit of difficulty telling it when to stop falling (to simulate the grabbing-of-the-ledge) and difficulty with the jumping off... the climbing up seems simple enough, make an animation once frozen to that spot and move/warp the character to the appropriate point after the "climb up" animation has finished playing.

anyone able to offer a bit of help on this one?

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Grabbing a ledge?
« Reply #1 on: August 20, 2012, 03:06:01 AM »
Hi,

 what kind of player controller are you using? If I was to do it in the M2H jumper game, I would add a collider in front of the player torso that when triggering with a platform simply void the player velocity and lock user input to only allow for climbing up or down.

Have you tried that?

bye,

 Jean

Red

  • Hero Member
  • *****
  • Posts: 563
Re: Grabbing a ledge?
« Reply #2 on: August 21, 2012, 05:47:36 PM »
the controller is the one used in the Lerpz 2d side-scrolling tutorial that Unity has on their tutorial page... would you recommend using the other one you mentioned instead? (i'm not so far into this project that this would be an un-desired amount of steps backwards.)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Grabbing a ledge?
« Reply #3 on: August 29, 2012, 02:46:08 AM »
Hi,

 I think it's more a question of adding features to that controller, because grabbing ledge is not something built in any default character controller that I know of.


bye,

 Jean