# When I unpossess vehicle. Vehicle not slows down

**URL:** <https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992>\
**Category:** World Creation\
**Tags:** vehicle, unreal-engine, Physics, Blueprint, question\
**Created:** [March 14, 2015, 11:33pm UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992 "2015-03-14T23:33:49Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![TawreCZE](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TawreCZE](https://forums.unrealengine.com/u/TawreCZE)\
**Post date:** [March 14, 2015, 11:33pm UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/1 "2015-03-14T23:33:49Z")

</div>

I don’t know what I am doing wrong, but when I unpossess vehicle in Vehicle template than it will driving straight. It stops really slow, wheels are spinnig even if it hits wall.

Probably misreading some inputs for vehicle movement, because when I release throttle and I have it possessed. It will stop in much shorter distance. Even when I try reset input’s in “Unpossessed” event like that:

![34214-bp_vehicle_unpossessed.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/2/6/626303f557f6a05c8d7caa87c8b55f8dac333982.png)

For example: You can try unpossess vehicle when you gain some speed and turn. Vehicle still go ahead and turn.

Is that some my problem in workflow or it’s bug?

---

<div class="post-metadata">

**Author:** ![Jacky](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/jacky/32/918690_2.png) [@Jacky](https://forums.unrealengine.com/u/Jacky)\
**Post date:** [March 14, 2015, 11:45pm UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/2 "2015-03-14T23:45:36Z")

</div>

Check out this thread: [GTA Style Vehicle Interaction - Project File Included - Community & Industry Discussion - Unreal Engine Forums](https://forums.unrealengine.com/showthread.php?44214-GTA-Style-Vehicle-Interaction-Project-File-Included)

It has the answer to your question and it also has a multiplayer-ready sample.

---

<div class="post-metadata">

**Author:** ![TawreCZE](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TawreCZE](https://forums.unrealengine.com/u/TawreCZE)\
**Post date:** [March 15, 2015, 11:30am UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/3 "2015-03-15T11:30:10Z")

</div>

Thanks, idea behind that is not bad. In that project with gas on the floor, it doesn’t work either. But is there a solution, in making a boolean variable that can affect inputs and after that using the solution with delay, before unpossessing, solve that.

One more time, thanks Jacky for aiming me to the right direction to solve that issue.

---

<div class="post-metadata">

**Author:** ![Skylonxe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Skylonxe](https://forums.unrealengine.com/u/Skylonxe)\
**Post date:** [February 10, 2016, 11:18pm UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/4 "2016-02-10T23:18:03Z")

</div>

I have proper solution, but it is C++ only:

You need to create custom vehicle component and override function UpdateDrag(), also you need to call another custom function (FullClearInput) before leaving vehicle with no controller.

```
.h

void FullClearInput();

virtual void UpdateDrag(float DeltaTime) override;

.cpp

void CustomVehicleComponent::FullClearInput()
{
	ClearInput();
	ServerUpdateState(0.f, 0.f, 0.f, 0.f, GetCurrentGear());
}

void CustomVehicleComponent::UpdateDrag(float DeltaTime)
{
	APawn* MyOwner = UpdatedComponent ? Cast<APawn>(UpdatedComponent->GetOwner()) : nullptr;
	if (MyOwner && MyOwner->GetController())
	{
		Super::UpdateDrag(DeltaTime);
	}
}

```

Epic, this should be available out-of-box.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_3d6017aa](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_3d6017aa](https://forums.unrealengine.com/u/anonymous_user_3d6017aa)\
**Post date:** [November 9, 2016, 2:25pm UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/5 "2016-11-09T14:25:09Z")

</div>

Really helped unlike all other solutions. Thank you!

---

<div class="post-metadata">

**Author:** ![ZimaXXX](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ZimaXXX](https://forums.unrealengine.com/u/ZimaXXX)\
**Post date:** [September 25, 2019, 10:28am UTC](https://forums.unrealengine.com/t/when-i-unpossess-vehicle-vehicle-not-slows-down/310992/6 "2019-09-25T10:28:08Z")

</div>

Fantastic solution! It’s also useful to make the fourth parameter, which is handbrake, to set it to 1.0f so vehicle stops quickly). It’s almost 2020 and issue still perists…
