Can I get some advice how to start coding this?

So I’ve been coding for about a year-ish now and I’m pretty confident with basics of coding. I’ve made a topdown 3D survival/RTS style/management game for a university assignment, which I seemed to handle rather well. Either way I really wanted to work on a personal project to become better at C# and programming in general, so I want to recreate this tether like mechanic from a old Playstation 1 game called Wild 9.

Here is the mechanic in action:

(If the time stamp didn’t work skip to 00:25)

I’d love to hear how other people would tackle this mechanic, as I’ve come up with a few ways but they seem super ‘long way’ and not really the optimal route to code it.

Thanks for your time, hope to hear back soon as I can’t wait to get started!

What is it that you want to do? pick up an object and smash it?

Pretty much yeah, I want to have the mechanic where you shoot a tether beam towards the mouse, and if it makes contact with an enemy you grab it and are able to manipulate it. Most small parts of this mechanic are easy to do, its just how to approach it. It wouldn’t be hard to do damage based on how hard it hits the floor but its the tether itself I don’t know where to begin.

You could use the same principles as for a grappling hook. Check out this blog.

Oh yeah I actually found this blog not so long ago and completely forgot about it. I’ll see what I can do with that. I’m still open to other ideas anyone else has :).

Well, for the tether only, it looks like it is just an lightning animation. You just need to play the lightning animation between the player and the draged object.
Then there’s the question of dragging the object, shooting the tether, etc etc

Yeah I’m not worried about the looks of the tether, just the code behind shooting it and manipulating enemies on a XY axis.

I’m assuming there will be a range limit on how far your going to shoot the tether.
You have to raycast (a ray) beguining at the player position, in the mouse direction. Make sure the raycast returns all objects hit by it and not just the first. And I believe there are 2D raycasts, but not sure though

Yeah a limit would be useful. If i go with a ray as the way to find what I hit it would be instant rather than a short delay. In the video the tether actually slowly reaches its distance after a second or two.

To be honest it’s kinda slow and clunky when its like that, lol, so maybe using a ray is the best bet.

Edit: If anyone finds more useful things related to my question let me know asap. The more the better.

Bump, I’m hoping to get this done in a few days :).

Bump. Curious to see if anyone else has ideas as to how they would go about making this.

I’d abuse the physics system and use a FixedJoint.

If you aren’t using physics the solution is still pretty simple, make the object follow a circular arc around the player. Everything else is just art work.

I’m going for physics. I’m using a character joint right now but it’s super glitchy lol. Is there a big difference between character and fixed joint?