GetMarkedReachedSignal is not a valid member of AnimationTrack?

So I’m trying to make two functions happen upon a marker being reached in an animation, however it says:
“GetMarkedReachedSignal is not a valid member of AnimationTrack” I’m really confused.

Heres my code:

script.Parent.OnServerEvent:Connect(function(plr)
	print("Started")
	local on = true
	local char = plr.Character
	local fist = game.Lighting.DivergentFists:Clone()
	local leftfist = game.Lighting.DivergentFists2:Clone()
	local anim =  script.Parent.Parent.DiverGentAnim
	local weld = Instance.new("ManualWeld")
	local leftweld = Instance.new("ManualWeld")


	local function RightHandEmit()
	fist.Parent = char.RightHand
	fist.CFrame = char.RightHand.CFrame

	weld.Parent = char.RightHand
	weld.Part0 = char.RightHand
	weld.Part1 = fist
	weld.C0 = CFrame.new(0,-1,0)
	
	local function FlameEmit()
		while on == true do
			fist.Attachment.BlackFlames:Emit(10)
			fist.Attachment.Flames:Emit(10)
			wait(.1)
		end
	end
	
	local function SparksEmit()
		while on == true do
			fist.Attachment.Aura:Emit(10)
			fist.Attachment.Main:Emit(10)
			wait(.1)
		end
	end
	
	spawn(SparksEmit)
		spawn(FlameEmit)
	end
	
	local function LeftHandEmit()
		leftfist.Parent = char.LeftHand
		leftfist.CFrame = char.LeftHand.CFrame

		leftweld.Parent = char.LeftHand
		leftweld.Part0 = char.LeftHand
		leftweld.Part1 = leftfist
		leftweld.C0 = CFrame.new(0,-1,0)

		local function LeftFlameEmit()
			while on == true do
				leftfist.Attachment.BlackFlames:Emit(10)
				leftfist.Attachment.Flames:Emit(10)
				wait(.1)
			end
		end

		local function LeftSparksEmit()
			while on == true do
				leftfist.Attachment.Aura:Emit(10)
				leftfist.Attachment.Main:Emit(10)
				wait(.1)
			end
		end
		spawn(LeftFlameEmit)
		spawn(LeftSparksEmit)
	end
	
	local load = char.Humanoid.Animator:LoadAnimation(anim)
	
	load:Play()
	
	load:GetMarkerReachedSignal("ReachedStart"):Connect(function()
		print("Reached")
		spawn(LeftHandEmit)
		spawn(RightHandEmit)
	end)

	
end)

Any help is appreciated, thanks! (This is all on the server by the way)

1 Like