I want a player to physically interact with a 3 part hose object (2 connectors socketed to a cylinder with bone), and be able to “plug-in” (simple snap-to-location movement) 1 connector to a machine and 1 to a wall. They need to be able to unplug the hose connectors if they mess up, and both connectors should be able to become “floating anchors” for the hose to dangle from.
1.) Player uses simplified physics gun (from demo content) blueprint to move an actor that simulates physics (for now it is a cube).
2.) When any object (with PickUp tag for safety) overlaps with an invisible trigger volume (blueprint), the object is released from player control, and the object snaps to the trigger’s relative location (uses blueprint interface).
3.) The object is now expected to float in place until the actor clicks on it again, or the game ends. The object needs to stay in place, even if the player was to jump on top of it.
I have completed the first two steps, but step 3 eludes me.
The object will snap to the location correctly for a second, but will then fly off in some direction (with proper physics still). I assume this is because there is still some forces being applied to the actor after the “snap-to” movement. Is there a way I can toggle an actor’s “simulate physics” characteristic? A work-around would suffice, as long as it covers the above criteria. One way that almost works would be to destroy the actor and spawn a replacement at the location, but this would still need me to tamper with its physics since there will be a hose pulling on it later (or the user be able to detach and move it).
Is there a way I can move an actor that is simulating physics to a location, stop it from moving, and toggle its “simulate physics” characteristic?
Note: I know that a “Set Simulate Physics” node has been added in the latest version, but it seems to not work yet according to the topic: Can't toggle Simulate Physics property on Destructible Mesh - World Creation - Epic Developer Community Forums . I would try it right now, but the Barracuda filter at work prevents the Unreal Engine from phoning home for updates :(. My company’s IT has looked into the issue, but any network conflicts it may be causing aren’t registering on their end; so, I have to take the computer home to update.