Blood Puddles not appearing

  1. I want to make the Blood drops actually work on walls and ground and not only in other players.

  2. Whenever the Blood trails fall down and actually hit a wall or ground, it does not detect it and does not spawn the blood puddle on the spot. Demonstration: https://gyazo.com/c714be1c65099b26a9e1230f168ae525

  3. I have tried using CFrame.lookVector and also Velocity.Unit including just making the direction Vector3.new(0,-1,0), only the vector3.new one works on the ground but not on the walls. Although, all of the methods works on the player but not on the walls, ground and including terrain.

This is from the script of the tool, which activates the module and sends all the required information to it so it can create the bezier curve, it also includes the Raycast, which is just a ray cast to the ground and once it detects anything, it sends the Position for it.

spawn(function()
						for i = 1,5 do 
					RayParams.FilterDescendantsInstances = {v.Parent:GetChildren(),v.Parent}
					local HitRay = workspace:Raycast(v.Parent:WaitForChild("Torso").Position,Vector3.new(0,-10,0),RayParams)
					if HitRay  then
						local TrailClone = game:GetService("ReplicatedStorage"):WaitForChild("Combat").Particles.BloodTrail:Clone()
						BezierModule.NormalGenerate(game:GetService("ReplicatedStorage"):WaitForChild("Combat").BloodBezier,v.Parent:WaitForChild("HumanoidRootPart"),TrailClone,v.Parent:WaitForChild("HumanoidRootPart").CFrame:Lerp(CFrame.new(HitRay.Position),0.5),HitRay.Position, game:GetService("ReplicatedStorage"):WaitForChild("Combat").Particles.BloodPool:Clone())
							end
						end

This is the Part of the Module which receives all of the information and uses it to create the curve and also the puddle.
It has the Raycast which appears from the bloodtrail that is being bezier curved, and it uses that as a way to detect whether it touched anything or not, which if it does then the puddle itself will appear and do the rest which has no problems. Only with the Raycast not hitting the walls, ground and only working on the player.

local Hit = workspace:Raycast(Part.Position,Part.CFrame.lookVector * 1.1,params)
		if Hit then
			print(Hit.Instance)
			HasHit = true
			Part:Destroy()
			Pool.Parent = workspace
			Pool.CFrame = (CFrame.new(Hit.Position, Hit.Position + Hit.Normal) * CFrame.Angles(math.rad(90), math.random(-360,360), 0)) * CFrame.new(0, 0/2,0)
			local Anim = game:GetService("TweenService"):Create(Pool,TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,0,false,0),Rise)
			Anim:Play()
			Anim.Completed:Connect(function()
				task.wait(5)
				local Anim2 = game:GetService("TweenService"):Create(Pool,TweenInfo.new(1,Enum.EasingStyle.Sine,Enum.EasingDirection.InOut,0,false,0),Fall)
				Anim2:Play()
				Anim2.Completed:Connect(function()
				game:GetService("Debris"):AddItem(Pool,5)
				end)
			end)
		end
1 Like