Friction from the ground makes dash way less effective when not mid-air

How should I go about making friction not affect the player while their dashing?

Here’s what I mean:

(Edit) I don’t think it’s necessary but I should probably add the code lol

local UIS = game:GetService("UserInputService")

if not game.Players.LocalPlayer.Character then
game.Players.LocalPlayer.CharacterAdded:Wait()
end

local Character = game.Players.LocalPlayer.Character

local DashSpeed = 50

UIS.InputBegan:Connect(function(key)
	if key.KeyCode == Enum.KeyCode.LeftShift then
		-- Character.Humanoid.WalkSpeed = 0
		Character.HumanoidRootPart.AssemblyLinearVelocity = Character.Humanoid.MoveDirection * 100
	end
end)

I don’t think turning off friction on the floor until the player’s done is a good idea, because there are going to be some larger levels with a lot more platforms.
Could I maybe lift the player slightly off the ground, and then lock their y axis movement? Because I don’t know how I would do that

Any help is appreciated! <3

1 Like

Add a constant set velocity instead of straight up setting it.

2 Likes

Yeah you should add a vectorvelocity and bind it to character’s primary part, for lets say 0.5 seconds and then remove it. Do it in client-side tho since network owner of the character is the player

2 Likes

Assemblylinearvelocity is not how you do a dash unless you want friction.
Assemblylinearvelocity is the entire part’s velocity, walkspeed, friction and customphysprops and all!

Do what the above says and create a temp velocity instance or so and parent it to your rootpart.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.