x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How to implement rope mechanic that respect meshes in level

Hello,

I'm working on a game where player can shoot rope to connect two things in level (firing once connects one end of rope and firing second time connects second end of rope). That can be AI to exploding barrels (rope tension will make barrel fly towards AI and explode on contact) or AI to a rotating drill (AI gets pulled into the drill and gets smashed) and other fun mechanics revolving around rope. But I want the rope to respect meshes in level. For example if player shoot rope on a static wall and starts walking it has to wrap around objects in middle. Rope's length can be infinite so player can walk around as much as he want and rope will not restrict him.

Unreal's rope just goes through any mesh that is in between. I started trying to do this through and the result is as shown.

https://youtu.be/dPCknbjpDZA

Also problem with using spline is they don't respect gravity. How can I create rope that I want? What is the direction that I should be looking at?

Product Version: UE 4.14
Tags:
more ▼

asked Jan 28 '17 at 08:46 PM in Using UE4

avatar image

plato.manchi
75 11 11 21

avatar image Moutrave Nov 21 '18 at 08:34 PM

Hello,

Are you using a cable component? If so there is no way to make it interact physically with the environement.

I made a chain using a simple rig imported from 3ds max, set the first bone to Kinematic so I can animate it, and the rest of them to Simulated so they have physics. You need to check Simulate physic in the properties of the skeletal mesh, and you need to have a physic asset if I'm not mistaken for it to collide with the world.

I would be interested to know though how you managed to make your rope follow by grabbing another item, that is precisely what I've been failing to do all day!

Thanks

avatar image plato.manchi Nov 22 '18 at 08:30 AM

Hi,

We pivoted to making the rope straight and used cable component. To pull, if the object rope is connected to has physics enabled then we apply force based on the mass of the object in the direction of cable at the point of contact.

avatar image Moutrave Nov 22 '18 at 02:47 PM

Nice, I used constraint in the BP to link a cable component to some bucket, my issue was with pulling the bucket up by tightening the constraint but it didn't work like that, had to cheat :)

Good luck and thanks!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

EDIT: FYI post for future visitors - didn't realise age of question.

The cable component does have an "Enable Collision" option, but it's not perfect.

As you're moving the rope manually, it will likely get stuck and tangled on objects, rather than being stopped by them.

It was enough of a solution in my case to continuously check the distance between each point on the cable component, and if the distance was extreme, the rope was likely caught on something and being stretched, it would then detach and ragdoll - an action similar to being "snagged".

more ▼

answered Nov 22 '18 at 09:38 AM

avatar image

Unfathomable
421 2 5 7

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question