UE4 Make Rope Swing - Cable Component and Physics in Unreal Engine 4 Chain Tutorial How To

แชร์
ฝัง
  • เผยแพร่เมื่อ 19 มิ.ย. 2024
  • In this free step by step Unreal Engine 4 tutorial video (UE4 how to) you will learn how to make a rope swing mechanism using physics constraints and the cable component.
    Rope tutorial using Bones: • UE4 Rope using Bones a...
    All my UE4 tutorials: • UE4 Make Rope Swing - ...
    Join me for Live Streams: / lusiogenic
    I Share stuff here: / lusiogenic
    00:00 Overview
    00:49 Create Base and Board
    01:37 Create and Configure Physics Constraints
    06:54 Create Cable Compoenents
    12:41 Tweak Rotation Limitations
    #ue4 #unrealengine #gamedev
    Thumbnail graphics license:
    Icons made by surang www.flaticon.com/authors/surang from www.flaticon.com

ความคิดเห็น • 67

  • @Lusiogenic
    @Lusiogenic  4 ปีที่แล้ว +4

    If you're looking for Rope implemented using Bones, here's the tutorial: th-cam.com/video/hEMcr98cDJE/w-d-xo.html

    • @jayjaygolden5123
      @jayjaygolden5123 2 ปีที่แล้ว +1

      im trying to make a cable using the cable component, with a plug on each end, so i can use this in a modular manner to place dangling cables where applicable.
      Now a problem im running into is that instead of 'coming out' of the cylindrical shape that is my plug, and then sagging down more as it gets further from the plug, it just takes the pivot of my object as a pivot, and thus clips with the plug in an ugly way. Any ideas?

  • @reerjgiorge
    @reerjgiorge 6 ปีที่แล้ว +5

    Thanks man for another interesting tutorial.

  • @LostArkLover
    @LostArkLover 3 ปีที่แล้ว +1

    Just came to this channel by accident, didn't regret it!!!

  • @_clicktac_
    @_clicktac_ 4 ปีที่แล้ว

    really good tutorials, please, keep going... thank you very much

  • @wither932
    @wither932 3 ปีที่แล้ว +1

    Used this tutorial to make a wrecking ball. Really easy and works great. Keep up the great Tutorials man.

    • @Nekan11
      @Nekan11 2 ปีที่แล้ว +1

      that's what im here for as well:D Glad to know it works for that then, thanks!

  • @Hogscraper
    @Hogscraper 3 ปีที่แล้ว

    Thank you for the great tutorial!

  • @Video-by6lp
    @Video-by6lp 5 ปีที่แล้ว +1

    The Best tutorial !)

  • @madmanoliver
    @madmanoliver 3 ปีที่แล้ว

    Dude your actually amazing

  • @Nekan11
    @Nekan11 2 ปีที่แล้ว

    Thanks for the tutorial big dawg

  • @raziel4564
    @raziel4564 6 ปีที่แล้ว +1

    Thanks for + 1 tutorial

  • @_-_-_-_-_Michael_-_-_-_-_
    @_-_-_-_-_Michael_-_-_-_-_ 4 ปีที่แล้ว

    Thank you so much!

  • @karvakferenc
    @karvakferenc 5 ปีที่แล้ว +1

    Verry good tutorial

  • @GokdenizCetin
    @GokdenizCetin 2 ปีที่แล้ว

    Thank you!

  • @YawLighthouse
    @YawLighthouse 4 ปีที่แล้ว +3

    Hello, so I've been having trouble with spawning in physics constraints to build out a tow cable type of thing at runtime where physics objects will be connected to other physics objects. Would it be possible to make a tutorial on spawning a physics constraint and connecting two components from separate actors at runtime? This would open up a bunch of possibilities :)

  • @CristhianASB
    @CristhianASB 3 ปีที่แล้ว

    Gracias!

  • @unrealengineruseng9583
    @unrealengineruseng9583 4 ปีที่แล้ว

    Cool !)

  • @Latvian3Dman
    @Latvian3Dman 5 ปีที่แล้ว

    Thank You for this !

  • @MrPangahas
    @MrPangahas 6 ปีที่แล้ว +1

    Another great video.Any chance we would see tutorials of Physics Asset tool being used for organic type simulations, things like muscles, skin, hair strands, body fat etc. stuff that can be used say for setting up some creatures/monsters.

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      Thanks!
      I would have to do some research for that, I haven't used the Physics Asset tool all that much. It's sounds very interesting, I'll put it on the list. :)

    • @NathanHarris83
      @NathanHarris83 6 ปีที่แล้ว

      If I remember correctly, PhaT isn't used so much with the most recent versions of PhysX? I'd have to do some digging to find links on the topic, sorry about that.
      The topic of musculature simulation is outside of the scope of PhysX, generally these are custom rolled systems that are (usually) tightly integrated with DCC tools and plugins. If by body fat, you mean things jiggling around, that ends up being mostly morph targets doing the heavy lifting. Hair rendering is outside of the scope of PhysX as well, and there are already existing solutions. Hair is a complex beast...
      I suggest doing some research on these topics. You could (and should) easily spend hours to days educating yourself reading articles, white papers, watching talks, etc.

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      The PhaT (or as it's called now, the PhaE) is just an editor that helps to set up physics constraints on skeletal meshes.
      Actually, I think you can make a simple belly flop with 3 bones (or even one) that are weight painted to the skin and have them act like springs using physics constraints in the PhaE. Making a tail or a pony tail is definitely achievable with bones and physics constraints.
      For the muscles, there are two considerations: the force that they apply to the world and their visual representation. For the force, you could use a physics constraint to act as a contracting spring and for the visual part you could also use one or multiple (weight painted) bones and limit them using physics constraints. Of course, you would have to use different physics constraints for each task.
      I plan on expanding my knowledge on this subject, but, as you said, it takes a lot of time.

  • @Grimsikk
    @Grimsikk 4 ปีที่แล้ว

    I haven't tried this tutorial yet, but could this setup work for a grappling hook for a character to swing from? For example, the player fires a GrappleHook object/projectile with the cable end attached to it, and then once the hook has attached somewhere, the player could swing from it?

  • @moviesinclusive
    @moviesinclusive 5 ปีที่แล้ว

    Hey, great tutorial! One quick question, how do you enter the demo mode where you can grab objects to test out physics (or is this custom made)?

    • @Lusiogenic
      @Lusiogenic  5 ปีที่แล้ว

      Hit Alt+S to simulate.

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว

      I'm sorry, I just realized what you meant.
      It's custom made. Here's the tutorial for it: th-cam.com/video/irk5NAuFPMc/w-d-xo.html

  • @virginiel.6159
    @virginiel.6159 5 ปีที่แล้ว

    Hey, great video!
    I have a question, is it possible to do that with a mesh skeletal? (I make an old sign that wears a fabric)

    • @Lusiogenic
      @Lusiogenic  5 ปีที่แล้ว

      Not sure what you mean by that, please elaborate.
      Maybe you're looking for something like this: th-cam.com/video/hEMcr98cDJE/w-d-xo.html

  • @TommyGunsXL
    @TommyGunsXL 3 ปีที่แล้ว

    12:15 Maybe a dump question, but isn't the rope not moving beause it's parented to the board? If the board was parented to the rope it should work 🤔 ( if that's possible). Anyway, I'm new to Unreal and your tutorials are very well done and helped me alot, so thank you for all your work. You are great!

  • @arknet4973
    @arknet4973 2 ปีที่แล้ว

    Thank for tutorial. Trying to make fishing rode. Need help with additing weight on the fisinh rod , in the end. Any ideas?

  • @johnnyjosefsen7644
    @johnnyjosefsen7644 2 ปีที่แล้ว

    Hi, I used this on two player characters, it works well when one character is hanging from the other character, but not the other way around. What i mean is, if the board is dangling from the base it works perfectly well, but if you suddenly switch them around during gameplay, enabling physics on the base and disabling them on the board, it stops working. I would have assumed that they would just change places, but instead the base just kinda falls and gets stuck.

  • @allods2ue4
    @allods2ue4 ปีที่แล้ว

    Спасибо, добрый человек, с костями так не сделаешь, их несёт в космос, а тут вроде всё как надо. Теперь смогу сделать цеп.

  • @ScottBarrettihq
    @ScottBarrettihq 11 หลายเดือนก่อน

    this has been a fantastic tutorial and just what I needed BUT, when I grab the 'swing' object, the base object moves around instead! and the swing remains stationary until I release the grip, at which point the swing swings based on the base's new position

  • @vaibhavsrivastav6992
    @vaibhavsrivastav6992 2 ปีที่แล้ว

    Hi
    Can we use a rod of a specified material instead of rope? like can we choose which metal/material a rod can be ?

  • @Genichi__
    @Genichi__ 4 ปีที่แล้ว

    Can you attach it to the player so it work like a grappeling hook ?

  • @hanson251985
    @hanson251985 2 ปีที่แล้ว

    Can you do some swing pole character tutorial like in Prince of persia or Uncharted 4? Cheers

  • @kyn-nex6705
    @kyn-nex6705 3 ปีที่แล้ว

    ASMR voice
    Thx for the video

  • @MilanKarakas
    @MilanKarakas ปีที่แล้ว

    How did you make widget and that grab thing? I am working in UE5 and unable to pull anything.

  • @mrcoughman
    @mrcoughman 5 ปีที่แล้ว

    Silly question, but how are you able to interact with just one component of the swing bp when simulating?

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว

      Maybe you're looking for this th-cam.com/video/irk5NAuFPMc/w-d-xo.html
      or this th-cam.com/video/XVND_jo-kNo/w-d-xo.html

  • @charlesoxbow9609
    @charlesoxbow9609 6 ปีที่แล้ว +1

    Hi, thanks for the great tutorial. I have a question about the linear constraints. If we set a constraint of 150 units along each dimension in world space, wouldn't this constrain the board to a cube, not a sphere?

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      That's a good question! Let me check that and I'll get back to you.
      It certainly didn't look like it was moving within a cube when I was testing it.

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      Ok, I've checked, it's definitely moving within a sphere (and it's also mentioned in the docs, see below). But your question is still valid.
      From what I can deduce empirically, the axis themselves rotate when the objects are moving in relation to each other, so that (for example) the X axis always passes through the center of the two objects.
      Unfortunately, the physics constraint is very poorly documented. The only thing I could find about this is the tooltip of the Limit in the Liniar Limits, that states: "[...]Distance applies on all axes enabled (one axis means line, two axis implies circle, three axis implies sphere)". It's probably why we can't have different limits on each axis.
      I will have to make a in-depth video dedicated to explaining the physics constraint, but I need to study it further before I can do that.

    • @charlesoxbow9609
      @charlesoxbow9609 6 ปีที่แล้ว +1

      Ahah, I was wondering if that was what was going on. Because I agree it definitely is constrained to a sphere, and not a cube. I suppose we could peek inside the PhysicsConstraint source to see which axes it's using, but I believe you must be right. Thanks again!

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      I will probably have to look into the source code to fully understand the physics constraint, but it takes such a long time, and it takes away from my time making tutorials.

  • @Grimsikk
    @Grimsikk 4 ปีที่แล้ว

    How do I use this with a player character? I can't figure out how to get it to let the player swing without having physics enabled because when its enabled then the player ends up upside down and spinning frantically.
    I really could use some help and guidance please.

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว

      You can only have the character swing without activating physics on it, if you attach it to the plank of the swing. And you would probably have to lower the center of mass of the plank, so the player stays upwright.
      The fact that the player spins when activating physics it's probably because it collides with other objects. You have to test and see which one. You may have to deactivate some controls from the player, not sure which, though.
      When I make a character that uses physics, I start with a simple Pawn class and build from there. So there's no additional functionnality that could mess up the movement.

  • @madmodder
    @madmodder 3 ปีที่แล้ว

    Is there a way to set the limit size at run time? Like a winch pulling an object? Ive tried using the set linear X,Y, and Z nodes simultaneously but it doesnt appear to give me results

    • @madmodder
      @madmodder 3 ปีที่แล้ว

      Found out if i just hit my constrained object with my player it will update, then I can crank my pulley to raise and lower my constrained object just fine. Curious.

    • @madmodder
      @madmodder 3 ปีที่แล้ว

      If anyone is trying to do something similar to this, how i fixed it was by waking the constrained object once, like with a do once node, whenever I first do anything to change the length of the constraint and that seems to persist throughout the rest of the game play instance. Youd think having "start awake" checked would take care of this but it doesnt seem to.

  • @colinericburriss
    @colinericburriss 6 ปีที่แล้ว +1

    Could these swings be used to create a rope bridge?

    • @Lusiogenic
      @Lusiogenic  6 ปีที่แล้ว

      Yes, they could. I'm planning to make a tutorial on how to implement a rope bridge.

    • @Lusiogenic
      @Lusiogenic  3 ปีที่แล้ว

      Something like this?
      th-cam.com/video/PYJP09BENiQ/w-d-xo.html

    • @colinericburriss
      @colinericburriss 3 ปีที่แล้ว

      You are a super genius, @@Lusiogenic. Sorry i can't pay for your work.

  • @lucian6172
    @lucian6172 ปีที่แล้ว

    In Blender there is an option to apply rotation and scale so that the transforms get reset back to 0 and 1. Why UE4 doesn't have that option ? (7:18)

  • @MGInspiration
    @MGInspiration 3 ปีที่แล้ว

    Sorry, how to contact with the object when we press play mode to test it , i'm a newbie really dont know how to make it

  • @IRONFRIDGE
    @IRONFRIDGE 2 ปีที่แล้ว

    Hi, is this working replicated?

  • @cadafalch8652
    @cadafalch8652 ปีที่แล้ว

    Is it possible that it is moved by the wind, instead of the player?

    • @ScottBarrettihq
      @ScottBarrettihq 11 หลายเดือนก่อน

      also interested in this

  • @CGFED
    @CGFED 4 ปีที่แล้ว

    You physical cyborg

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว +1

      That's a cool nickname. Thanks!

  • @Latvian3Dman
    @Latvian3Dman 4 ปีที่แล้ว

    Hello. Again, thanks for tutorial. I was hoping to solve what I want myself, but i am getting mad here :D So, I would like to ask for a consult, please? I think I have tried all options and values, but I still have an issue. I will explain. Short video here:
    twitter.com/Thunder_Owl/status/1252575953391431683
    It looks good, but only because i am "cheating", not doing any linear movement of ship, i am doing just rotations. When I do forward/backward or any "strafing", physical connection stretches like mad. I think I have tried everything (XYZ linear are set locked), but I hope I missed something simple? Also, if I try same "panedant" in empty level and move by mouse in simulation mode - there is no such stretching on linear movement. What can be a problem? With ship, scene with all 3 elements is parented to ship's body.
    Many thanks in advance for possible help! :)
    EDIT: well i kinda fixed it... Turns out, "base" component has to be ship's body. But, that does not make any sense to me, how constraint differs, is it ship's body, or another added cube or whatever mesh? Weird...

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว +1

      Hi there. It's hard to see what's wrong without seeing your physics constraint setup, but I'm glad it's working now.
      There's a whole discussion to be made about components, sub-components and the position of the physics constraint relative to the constrained components.
      Try testing with 2 cubes, move the physics constraint position (before starting the simulation) relative to the cubes and free some rotation and translation axes and see what's hapenning. The position of the physics constraint is very important!
      I'm planning to make small lessons on the physics constraints. Hope I can get to that soon.

  • @joshuasanderson7359
    @joshuasanderson7359 5 ปีที่แล้ว

    Is this video busted for anyone else? The visuals are corrupted but the audio is ok?

    • @Lusiogenic
      @Lusiogenic  4 ปีที่แล้ว

      There aren't any problems on my end. I've even checked it in an incognito tab.
      Can you try again and see if it works correctly now?