Fling gets canceled by player's movement

whenever the player moves away from the direction of getting flung, then the character does not get flinged that far

so far i tried to zero out the character’s move velocity
but that appears not to be working

rootpart.AssemblyLinearVelocity *= Vector3.new(0, 1, 0)

i also tried to separate the vertical fling velocity from the horizontal

local direction = (rootpart.Position - self.model["Deagle"]["Barrel"].ShootPoint.WorldPosition).Unit
local horizontal = ((direction * Vector3.new(1, 0, 1)).Unit) * 500
local vertical = Vector3.new(0, 1000, 0) 

local velocity = horizontal + vertical
flingCharacter:FireClient(player, velocity)

i was been using this

flingCharacter:FireClient(player, (rootpart.Position - self.model["Deagle"]["Barrel"].ShootPoint.WorldPosition).Unit * flingForce)

the fling works consistently except when player moves towards the aggressor

2 Likes

oh wait im an idiot, i forgot to turn off collisions from the bullet trail

mark your post as solved please

not yet, i have another question to solve
players get fling so much more when jumping comparatively than just walking

Are you using a vector force or :ApplyImpulse()?

apply impulse

Blockquote

  • List item

how much farther do they fly?

||30 csdfsdfharrrrrr||

like a half further than normally

edit:
spawn location is the start

the part behind me is the furthest
and me in the middle is regular
image

Get the players state, and if its Enum.HumanoidStateType.FallingDown then multiply the Vector that they are flung with by 2.

ok moving towards the shooter, its like 1/2 less and moving away is 1/2 more
jumping would cause it to go 2x more

Roblox’s physics engine is applying friction when you are on the ground. When you jump, you have no such friction. When moving towards the bullet, the player has motion that the impulse has to cancel out. When moving away, the impulse is added onto their preexisting motion.

1 Like

Before you fling the player, try setting their velocity to 0, and their state to a normal state.

already tried, i think the guy above your comment is correct

type or paste code here