Announcement

Collapse
No announcement yet.

Cable Component Plugin for UE4

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #46
    I have seen this thread and also the third party dynamic cable plugin for $20 in the other thread.

    I am wondering what the difference is to the cable in the free sample content of UE4. See sample content -> Physics -> Showroom 1.2. The rope there is a FBX with physics asset and has all collision, also dynamic, has true physics and so on. I am just trying to get a full picture because I need a physics rope sooner or later, and the sample content rope is already full physics enabled from what I saw.
    Last edited by PolyPlant; 03-12-2015, 03:57 PM.

    Comment


      #47
      I assume you mean this
      https://docs.unrealengine.com/latest...1_2/index.html

      Just reading that page, it appears that this is meant to make a skeletal mesh interact with the world for effects like Ragdoll.
      Taken at face value, it means the bendable joints are predefined ahead of time.
      I am not sure how good a rope that would make, but the idea looks like it has potential.
      The rope could only bend at the points that are predefined for it in the editor, so you would have to make a lot of joints.
      Not sure how it would look in game, but the demo looks promising, because you see how it makes a smooth bend.

      Another potential issue is if one needs the rope to change length or not.
      If you have a rope of a set size that's good, but if you need the length to change in game (such as for my grapple cable), then you have a problem, because the mesh is predefined in the editor. Sure, maybe you could stretch it out, but the predefined joints would then also stretch out, making the bending look worse and worse the longer it got. There are also material scaling issues when doing that because the material gets all stretched looking, so you have to add dynamic scaling.

      Other potential snags are:

      -performance. not necessarily an issue, but with so many bends, performance would need to be evaluated. I went to great lengths in my own cable to keep the number of bends down to a minimum.

      -rubber band effect. earlier drafts of our cable had the rubber band effect because the cable so was bendable, too bendable. therefore every time you moved the cable wiggled around like limp spaghetti. so a possible concern for a skeletal mesh rope is that with so many bend points as it would have to have to make it work, it would also perhaps wiggle around like a rubber band or spaghetti. only play test could very that, of course, and even then, the behavior might be acceptable, so depends on what one wants.

      All that said, I think a skeletal mesh with a set length that doesn't need to change, with enough joints in it, ought to work, in my opinion.
      Sounds like it could be a worthy avenue of research.
      Last edited by warhead328; 03-18-2015, 10:54 AM.

      Comment


        #48
        I agree with you.

        I have not done Verlet Integration myself yet, but I think the Verlet integration is better suited to solved a larger number of particles that connect to a rope, because it is faster than using PhysX joints for each 'particle'. In principle you could use the soft limits of the PhysX joint to get stretching, but not sure.
        In a Verlet rope, depending on the number of particles you can also see sharp bends in the Verlet rope. (not enough particles). The more particles, the less sharp bends.
        As I understood, the Verlet particles are also connected by joints, but reduced joints in the degree of freedom in order for the Verlet integration to be applicable.

        Interesting stuff. At one point I will read through the link in the first post where the stuff is explained.
        Last edited by PolyPlant; 03-18-2015, 04:24 PM.

        Comment


          #49
          Welp, we as Chaos have finished core dev on our cable. It works with moving objects now. I don't want to high jack this thread, but I did promise some more details about our cable implementation, so for anyone interested, check out the comments section on this vid. It's enough to get anyone started down that road who wants to develop similar tech on their own. No plans at this time for releasing the cable independently from the Chaos mod. https://www.youtube.com/watch?v=RPKNex5i8HY

          Comment


            #50
            I made a helper blueprint recently called MultipleCableActor to address the issue that CableActors/CableComponents are a ***** to set up and use, even if you're okay with the limited feature set (which is fine for just pretty ropes around your environments). Releasing it for free on here.

            Things it does

            -let you specify any number of cable sections with their own end points that you can drag around, so a single cable can be strung up from many points along the ceiling/whatever
            -automatically keep the UVs consistent across all your ropes regardless of length (tiling still adjustable)
            -let you specify different amounts of "slack" on the rope for each section, or specify a Uniform Slack to use for every section





            You can download it from my blog
            Impromptu Games|dev blog|twitter|itch.io store|Patreon
            Impromptu Procedural Ladders|Impromptu Procedural Handrails|Impromptu Procedural Stairs
            |Impromptu Fire Propagation|InFlux Example Game|Impromptu Vector Field Painter

            Comment


              #51
              That's a great contribution. I haven't used these before but I'm wondering if the cable can be affected by wind. For example if you used these for power lines, could they sway in the wind by placing a wind direction actor in the scene or would it be more complex than that?

              Comment


                #52
                @JoeWintergreen - awesome work, that looks like it will make the CableComponent much more friendly to use.
                Storyteller - An immersive VR audiobook player

                Dungeon Survival - WIP First person dungeon crawler with a focus on survival and environmental gameplay ala roguelikes

                Comment


                  #53
                  Is this only for 4.10 and up? I am on 4.9.2 and get an error when opening the BP:

                  Cable Sections member variable have invalid type.

                  Comment


                    #54
                    Not sure. Created on 4.10, haven't tried anywhere else. Try revoking/resaving everything.
                    Impromptu Games|dev blog|twitter|itch.io store|Patreon
                    Impromptu Procedural Ladders|Impromptu Procedural Handrails|Impromptu Procedural Stairs
                    |Impromptu Fire Propagation|InFlux Example Game|Impromptu Vector Field Painter

                    Comment


                      #55
                      Looks like whatever struct gets broke down below the Add Cable Component node in the ConstructionScript is the issue. There is a Break node for <unknown struct>

                      Also looks like there are 2 in the Get Longest Section function. Large image to show you:

                      Comment


                        #56
                        Do you have a struct named CableSection in the same folder as the actor?
                        Impromptu Games|dev blog|twitter|itch.io store|Patreon
                        Impromptu Procedural Ladders|Impromptu Procedural Handrails|Impromptu Procedural Stairs
                        |Impromptu Fire Propagation|InFlux Example Game|Impromptu Vector Field Painter

                        Comment


                          #57
                          Yes. Its called ImpromptuCableSection

                          It includes EndLocation and Slack vars.

                          Comment


                            #58
                            That's correct. Unreal sometimes chokes on custom structs for weird reasons. Save the struct (even though you haven't done anything with it) and correct those graphs so that they look like this:


                            Impromptu Games|dev blog|twitter|itch.io store|Patreon
                            Impromptu Procedural Ladders|Impromptu Procedural Handrails|Impromptu Procedural Stairs
                            |Impromptu Fire Propagation|InFlux Example Game|Impromptu Vector Field Painter

                            Comment


                              #59
                              Originally posted by wilberolive View Post
                              That's a great contribution. I haven't used these before but I'm wondering if the cable can be affected by wind. For example if you used these for power lines, could they sway in the wind by placing a wind direction actor in the scene or would it be more complex than that?
                              Currently no - I'd really like that functionality too, the best case scenario being a perfect emulation of the ropes in the Source engine (HL2). Someone would need to implement it in code on CableComponent - currently not my scene.
                              Impromptu Games|dev blog|twitter|itch.io store|Patreon
                              Impromptu Procedural Ladders|Impromptu Procedural Handrails|Impromptu Procedural Stairs
                              |Impromptu Fire Propagation|InFlux Example Game|Impromptu Vector Field Painter

                              Comment


                                #60
                                Everything works perfectly now. Thanks for the help and for the BP!

                                Comment

                                Working...
                                X