StarterCharacter Can't Jump After Swinging

Hello everyone I’ve encountered a pretty weird issue, after I swing my weapon my character cant really jump, they still can but its like they are weighted down by something. Moreover it only occurs when I use a StarterCharacter, if I just use the default character it works just fine. Anyone know why this is happening.

My Script doesn’t really do anything to the characters jumping so I don’t know why this could be happening, below is the snippet of code for the sword swings.

elseif Input == Enum.UserInputType.MouseButton1 then
			if SwingDebounce == false and WeaponSheathed == false and char.VariableFolder.Rolling.Value == false and char.VariableFolder.Stunned.Value == false and SheatheDebounce == false and char.VariableFolder.Parrying.Value == false then
				SwingDebounce = true

				local RunningAttack = false
				local CurrentPushForce = RunningAttackPushForce
				if char.VariableFolder.Sprinting.Value == true then
					char.MovementSystem.SprintScript.StopSprint:FireClient(plr)
					script.RunningAttack:FireClient(plr,RunningAttackDuration,RunningAttackPushForce,RunningAttackSlowdownAmount,RunningAttackLingerTime)

					RunningAttack = true
				end

				char.VariableFolder.Swinging.Value = true
				char.VariableFolder.CanSprint.Value = false
				Weapon.Trail.Enabled = false	

				if CurrentAnimTrack ~= nil then
					CurrentAnimTrack:Stop()
				end
				for i,v in pairs(char.Humanoid:GetPlayingAnimationTracks()) do
					if v.Name == "ParriedAnimation" or v.Name == "ParryAnim" or v.Name == "AttemptParryAnim" or v.Name == "BlockAnim" or v.Name == "Hit1" or v.Name == "Hit2" or v.Name == "Hit3" then
						v:Stop()
					end
				end
				char.VariableFolder.Blocking.Value = false
				BlockDebounce = false

				local FinalSwing = false

				local ResetCombo = ContinueCombo(char,ResetComboTime)
				if ResetCombo == true then
					SwingNum = 1
				end

				SwingNum, FinalSwing = SetCombo(SwingNum,FinalSwing,RunningAttack)
				CurrentAnimTrack:AdjustSpeed(SwingSpeed)

				CurrentAnimTrack.KeyframeReached:Connect(function(Keyframe)	
					if Keyframe == "StartTrail" and StartTrailDebounce == false then
						StartTrailDebounce = true
						if Weapon ~= nil then
							Weapon.Trail.Enabled = true
						end

						local SwingSound = game.ReplicatedStorage.Effects.Sounds.Combat.SwingSounds.HeavySwingSound:Clone()
						SwingSound.Parent = Weapon
						if SwingNum == 2 then
							SwingSound.PlaybackSpeed = 0.8
						elseif SwingNum == 3 then
							SwingSound.PlaybackSpeed = 0.85
						elseif SwingNum == 4 then
							SwingSound.PlaybackSpeed = 0.8
						elseif SwingNum == 1 then
							SwingSound.PlaybackSpeed = 0.75
						end
						SwingSound:Play()

						Debris:AddItem(SwingSound,5)

						task.wait()
						StartTrailDebounce = false
					end

					if Keyframe == "HitStart" and HitStartDebounce == false then
						HitStartDebounce = true

						local Params = OverlapParams.new()
						Params.FilterType = Enum.RaycastFilterType.Exclude
						Params.FilterDescendantsInstances = {char}

						local HitList = workspace:GetPartBoundsInBox(char.HumanoidRootPart.CFrame * CFrame.new(Vector3.new(0,0,-Range / 2)),Vector3.new(Range + 4,8,Range),Params)
						local AlreadyHitList = {}
						for i, Part in ipairs(HitList) do
							if Part.Parent:FindFirstChild("Humanoid") and Part.Parent:FindFirstChild("VariableFolder") and Part.Name ~= "Weapon" then
								if not table.find(AlreadyHitList, Part.Parent) then
									table.insert(AlreadyHitList,Part.Parent)	
									coroutine.resume(coroutine.create(function()
										local Hitstun = CombatFunctions.OnSuccessfulHit(Part,FinalSwing,CurrentAnimTrack,Damage,PostureDamage,SwingSpeed,HitIFrames,char)
										if Hitstun == true then
											CombatFunctions.HitStun(Part.Parent, 0.5)										
										end
									end))
								end
							end
						end

						task.wait()
						HitStartDebounce = false
					end

					if Keyframe == "EndSwing" and EndSwingDebounce == false then
						OnSwingEnd(FinalSwing,false)
					end

					if Keyframe == "StopTrail" and StopTrailDebounce == false then
						StopTrailDebounce = true
						if Weapon ~= nil then
							Weapon.Trail.Enabled = false
						end

						task.wait()
						StopTrailDebounce = false
					end
				end)
			end

Any help would be greatly appreciated!

2 Likes

maybe something is welding to the character when you make the vfx

also check jumppower in character and massless on the weapon

1 Like

There are no welds occurring, and I’ve already checked the jumppower regardless of what it is the character is still bugged, and the weapon is indeed massless.

1 Like

Is it some collision glitch? You might have done that by accident.

What do you mean by collision glitch, if you mean some parts not being cancollide = false then I already made sure that everything is cancollide = false except for the head and torso of course.

1 Like

Okay, you made my brain hurt, is this the only script that is causing this? Try disabling that script to see if you cannot jump.

You should try checking on the “Massless” property on your weapon model.
image_2025-03-12_025316043

But they could jump before, I don’t think the tool is weighing it down. I don’t really know honestly

1 Like

You should give it a try, and tell me if it changed anything. I think it’d be best to have your model as massless regardless anyways.

The model is indeed massless, it really is super weird, this is the only thing that causes this behavior. there is nothing else bound to mousebutton1 other than this script, so I really have no idea what is causing it.

So, does the issue persist if you remove the sword after swinging?

Yes the issue persists even if I remove the sword and the script after I swing.

Here are two of my guesses:

  1. There is something wrong with animation

  2. You forgot to delete all parts when making vfx effects, and one is right above your head preventing you from jumping

  1. I don’t think it has anything to do with the animations, its just a regular animation with a few animation events that’s it, it doesn’t loop or anything weird like that.

  2. My scripts don’t add any vfx effects at all , I just don’t have them, unless you count the trail, but that just uses the default roblox trail system.

At this point, i’m confused, try playing it outside of roblox studio, there is a high chance it could be roblox studio issue, anyways, if that’s not the case, I think you should check your scripts again, I suppose movement is limited when swinging and so is jumping (If that’s true check the script that should return your JumpPower back)

The problem did indeed persist in game, but it did seem to be caused by the part of the script that limits jumping, I tried removing that part of the script temporarily and it didn’t bug out, Thanks!

1 Like

Quick update for anyone experiencing a similar issue, my script was changing the players JumpPower, while the StarterCharacter I was using was using JumpHeight instead. that’s why the issue only occurred when using a StarterCharacter, the weird glitchy jump you see is because it is settings its JumpPower to 7.2, which is very small compared to the default 40. All you need to do to fix this issue is either uncheck the setting in the humanoid “UseJumpPower” or change your scripts to use JumpHeight.

Hope that cleared some things up.