local c={[Enum.HumanoidStateType.Running]=true;[Enum.HumanoidStateType.RunningNoPhysics]=true,[Enum.HumanoidStateType.Climbing]=true,[Enum.HumanoidStateType.Ragdoll]=true;[Enum.HumanoidStateType.FallingDown]=true,[Enum.HumanoidStateType.Flying]=true;[Enum.HumanoidStateType.GettingUp]=true;[Enum.HumanoidStateType.Dead]=true;[Enum.HumanoidStateType.None]=true;[Enum.HumanoidStateType.Physics]=true;[Enum.HumanoidStateType.Swimming]=true,[Enum.HumanoidStateType.Seated]=true,[Enum.HumanoidStateType.PlatformStanding]=true}local r repeat wait()until script.Parent.Parent:FindFirstChild("\072\117\109\097\110\111\105\100")r=script.Parent.Parent local p=r:WaitForChild("\072\117\109\097\110\111\105\100")local n=r:WaitForChild("\072\117\109\097\110\111\105\100\082\111\111\116\080\097\114\116")local x=require(script.Parent.Values)while true do local r=getHumanoidState(p)if c[r]and not x.DontUpdateYet then x.LastStandingPos=n.Position end task.wait()end

local States = {
	[Enum.HumanoidStateType.Running] = true;
	[Enum.HumanoidStateType.RunningNoPhysics] = true;
	[Enum.HumanoidStateType.Climbing] = true;
	[Enum.HumanoidStateType.Ragdoll] = true;
	[Enum.HumanoidStateType.FallingDown] = true;
	[Enum.HumanoidStateType.Flying] = true;
	[Enum.HumanoidStateType.GettingUp] = true;
	[Enum.HumanoidStateType.Dead] = true;
	[Enum.HumanoidStateType.None] = true;
	[Enum.HumanoidStateType.Physics] = true;
	[Enum.HumanoidStateType.Swimming] = true;
	[Enum.HumanoidStateType.Seated] = true;
	[Enum.HumanoidStateType.PlatformStanding] = true;
}

local Character

repeat wait() until script.Parent.Parent:FindFirstChild("Humanoid")

Character = script.Parent.Parent

local Humanoid = Character:WaitForChild("Humanoid")
local HRP = Character:WaitForChild("HumanoidRootPart")
local Values = require(script.Parent.Values)

while true do
	local state = getHumanoidState(Humanoid)
	--print(state)
	if States[state] and not Values.DontUpdateYet then
		Values.LastStandingPos = HRP.Position
		--print(Values.LastStandingYPos)
	end
	task.wait()
end
