Feedback on Web Swinging thingy

Hello! So I started getting into spider man and the epicest thing there is a web swinging. Trust me you would wanted to fly through your city doing some cool tricks in air and feel all this wind flying in your face. And so do I.
So Im trying to make my own spider man movement system and current progress is a web swing. It’s heavily inspired by this game.
So here it is!
https://www.roblox.com/games/9564312173/Test-Place-Web-Test

Video:

8 Likes

Did you use a beam or a rope? and would there a be example for this? not like a full system but an example on what you should do

1 Like

That looks insanely good and well done! The only thing I’d change is the music stopping abruptly qhen you lose speed. Maybe add a something like a delay so it only stops if you haven’t moved much in a few seconds.

Other than that, amazing job.

2 Likes

Both. Rope for swing system and beam for visuals.
I can try but I dont promise.

1 Like

Thanks! I will try to make that when I will get to project again.

1 Like

It would be wonderful if you gave a quick tutorial on how to do it since i’ve been struggling for a while now
especially with the swinging and the raycasting for nearest part

1 Like

coincidentally, I was just making one of these for my Marvel game right now! What do you use to move the player? I would use BodyVelocity but thats deprecated, so an answer would be appreciated

1 Like

Im using BodyForce even tho it’s deprecated.

To get nearest part I advice you to use workspace:GetPartBoundsInBox() or how it called. After what calculate the nearest part.

For swinging, create a rope and attach it to player’s HumanoidRootPart and to the point

Point calculation

To get point, you wanna get the nearest part and get it’s top Part.Position+Vector3.new(0,Part.Size.Y/2,0). Fire a raycast from player to the part and use it’s normal to get side of part and it’s edge. And then you can create attachment and set it’s WorldPosition to point’s Position.

Also for rope make Restitution = 0. Set player’s HumanoidState to Physics so there won’t be any physics for them calculated.
Insert BodyForce into HumanoidRootPart. Make a loop where you will update force to Vector3.new(char.Humanoid.MoveDirection.X*500,-500/10,500/5) (you can change 500 to whatever you want).
And to not make player just look at random sides. Create BodyGyro and insert it into HumanoidRootPart (play with it P and D). Make sure to make it’s MaxTorque = Vector3.new(math.huge,math.huge,math.huge)). And in the loop together with BodyForce make it’s cframe: CFrame.new(HumanoidRootPart.Position,HumanoidRootPart.Position+HumanoidRootPart.AssemllyLinearVelocity). It will make him look at the direction he’s moving.

That’s it! However my BodyForce's force is a little bit other since I too it’s force from yt not gonna lie.
Everything else is just effects.

6 Likes

Thank you! for taking the time to reply and explain but why do you attach the rope to humanoidrootpart and not the right/left hand?

1 Like

Would this need any remote events due to the fact of the swinging obviously using UserInputService.

1 Like

I’m not good with Web-Swinging physics on Roblox. Probably only for me, I’d like you to elaborate more if that’s alright with you.

3 Likes

Because I believe when attaching to humanoid root part it allows your character to move more freely

1 Like

Im doing the whole web swinging system on client side (effects can be seen by other players)
Since there no any point at keeping all these physics on server if exploiter still can change them.
So answer is no, unless you want web swinging effect be seen others.

If you want that player could move their direction with camera, then its better to humanoid root part.
But if you want more realistic then you must detect a hand and attach rope to it.

I dont understand them quite well thats why I decided to check it on yt. But if you want make it so you could control your swing direction then for BodyForce force do Vector3.new(Camera.CFrame.LookVector.X*500,-500/10,Camera.CFrame.LookVector.Z*500). If it didnt helped you then it’s better to check code from yt.