Download

Object with Physics connected to Spline - Object not Pointing Forward Along Spline when moving- Help

Hello all.

I’m really hoping that someone can help me… This is the last resort to ask this question. I’ve tried many a try with this and have failed.

OBJECTIVE:
Having a craft to travel along a pre-determined path (spline) but the user is to control the speed of the craft as it travels, then slow down naturally when the key is not pressed.
Hence the need for the craft to be linked to the spline and have the Add Force node applied for the physics and in need for the craft to point in the correct direction when travelling along the spline.

Results So Far:
I’ve got the craft travelling along the spline with Physics to speed up on key press and slow down on release travelling along the spline.

**Failed to achieve: ** Having the craft point in the forward direction when travelling along the spline.

**First up, **
I have a CapsuleComponent (playerBP - Self) and this is connected to the spline via the blueprint (this is loosly based on a tutorial I found online but used just the Add Movement Input node)

I have added an Add Force node so that when I press the Key ( I assigned M for Forward - N for Backward) The speed increases forward, when I release, the speed naturally reduced, the object slows down by it’s self.
This is great and what I wanted to achieve (I will swap out the cone for my own mesh at a later date.)

However the object (cone) doesn’t point forward to the direction it is following along the spline

Here’s before I turn on Physics on the Capsule Component - the cone points in the correct forward direction when going along the curve.

Capsule Component - Cone Pointing in the Correct Direction
[ATTACH=JSON]{“alt”:“ConeBeforePhysics”,“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_212685_1612201471797_37”,“title”:“ConeBeforePhysics.jpg”}[/ATTACH]
https://forums.unrealengine.com/core/image/gif;base64

BluePrint - No Physics involved

[ATTACH=JSON]{“alt”:“Before Physics”,“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_212683_1612201313043_667”,“title”:“Before.jpg”}[/ATTACH]
https://forums.unrealengine.com/core/image/gif;base64

Physics Applied:

Now when I change the Blueprint to use the Add Force Node and Turn On Physics for the Capsule Component.

The Capsule Component - Cone no longer points in the direction that it is travelling… I’ve tried all sorts of combinations within the Blueprint.

Capsule Component - Cone following Spline but not pointing in the forward direction when travelling along spline
[ATTACH=JSON]{“alt”:“ConeAfterPhy”,“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_212687_1612202357778_844”,“title”:“ConeAfterPhysics.jpg”}[/ATTACH]
https://forums.unrealengine.com/core/image/gif;base64

The re-jigged Blueprint.

[ATTACH=JSON]{“alt”:“BP with Phy”,“data-align”:“none”,“data-size”:“full”,“data-tempid”:“temp_212688_1612202444856_583”,“title”:“WithPhysics_AddForce.jpg”}[/ATTACH]
https://forums.unrealengine.com/core/image/gif;base64

If there is anyone that can help point me in the right direction or even show a working Blueprint (as I’m no expert with Blueprints) that’ll be really great and very much appreciated.

Plus I cannot use the Vehicle Blueprint system if anyone suggests it… Too complicated for what I need.
This is mini project of mine; is just for a Hover Raft to travel along a pre-determined path but the user is to control the speed of the craft as it travels, then slow down naturally when the key is not pressed.

Thanks all and look forward to some possible soultions.
Richard