I need help with getting HumanoidRootPart's position

Hi, I was trying to make a basic Drop Item script, Like dark souls.

Problem I am having is that when the NPC dies it clones the model but, the models position is where I don’t want it to be in.

I am trying to make it so that when NPC dies it gets HumanoidRootParts Location and clones it where ever HumanoidRootPart is.

script:

local rs = game:GetService("ReplicatedStorage")
local Humanoid = script.Parent.Humanoid
local HumanRoot = script.Parent.HumanoidRootPart

function ded()
	local Venom = rs.Drops.Venomshank:Clone()
	Venom.Parent = game.Workspace
end
Humanoid.Died:connect(ded) 

video:
https://gyazo.com/e007419de13e762b52810ecf1887907f

well thats because your not setting the position of the “Venom” instance

try this @SillyFwemboy

local rs = game:GetService("ReplicatedStorage")
local Humanoid = script.Parent.Humanoid
local HumanRoot = script.Parent.HumanoidRootPart

function ded()
	local Venom = rs.Drops.Venomshank:Clone()
    if Venom:IsA("Model") then
      Venom.PrimaryPart.Position = HumanRoot.Position
    else
      Venom.Position = HumanRoot.Position
    end
	Venom.Parent = game.Workspace
end
Humanoid.Died:connect(ded) 
1 Like