Hi everyone,
I'm hoping someone can help me. I'm trying to program in a Yoshi Tongue that will extend from the player character, and be able to grab an enemy that will then be brought back to the player to be carried. The player can then toss the enemy.
I can get it to sort of work, but for the most part it only works once and is prone to bugs if the player is moving while the tongue is extended. Also it only works in one direction, but I imagine reversing it is a matter of mirroring all the formulas.
Another problem is that the formula I use for tossing the enemy (apply impulse at image point) doesn't take momentum into account and I'm not sure if there is a better tool to use.
The platformer "Levelhead" has pretty much the exact system I'd like to use where boxes can be picked up with an extending arm and then thrown:
youtube.com/watch
File: drive.google.com/file/d/1w4wxHTXKtNMiCdJssHCIc1lnB7Xd3pmy/view
Is anyone able to help me? Thank you for any and all responses.
Edit: Demo Controls. Left/Right to move left and right, up to jump, space to extend grabber/toss enemy