How to fix stand wont go infront

how to fix this : https://gyazo.com/0e4df41f8597b016e90ca3c7d1873047

like when summon first time them stand is work and when i desummon i do move the stand stay behind me how to fix that?

Please me more clear in your question

1 Like

i creating a jojo game and when i summon first time the move is fine and after i desummon and summon the stand again my stand wont go infront of me anymore anyway to fix that?

Your code is broken. What are the errors if any?

nope they are no error i think this is just a bug

You’ll have to show the code then

show what code the summon code or ?

this is my summon script

local summonevent = game:GetService(“ReplicatedStorage”):WaitForChild(“Stand”):WaitForChild(“TW”).Summon
local TweenService = game:GetService(“TweenService”)
local Debris = game:GetService(“Debris”)

summonevent.OnServerEvent:Connect(function(Player)
local Character = Player.Character
if not Character:FindFirstChild(“Stand”) then
local Standclone = game:GetService(“ServerStorage”):WaitForChild(“StandModel”).TheWorld:Clone()
Standclone.Name = “Stand”
Standclone.Parent = Character
Standclone.HumanoidRootPart.CFrame = Character.HumanoidRootPart.CFrame
local standpos = Instance.new(“Attachment”)
standpos.Parent = Character.HumanoidRootPart
standpos.Name = “StandPosition”
local alignp = Instance.new(“AlignPosition”)
alignp.Parent = Standclone
alignp.Attachment0 = Standclone.HumanoidRootPart.RootRigAttachment
alignp.Attachment1 = standpos
alignp.MaxForce = 6000
alignp.Responsiveness = 100
local aligno = Instance.new(“AlignOrientation”)
aligno.Parent = Standclone
aligno.Attachment0 = Standclone.HumanoidRootPart.RootRigAttachment
aligno.Attachment1 = standpos
aligno.MaxTorque = 6000
aligno.Responsiveness = 100
Standclone.AnimationController:LoadAnimation(Standclone.Idle):Play()

	local summon = script.Summon:Clone()
	summon.Parent = Character
	summon:Play()
	
	local summoneffect = script.SummonEffects:Clone()
	summoneffect.Parent = Character
	summoneffect:Play()

	for i ,v in pairs(Character:GetChildren()) do
		if v:IsA("BasePart") then
			local aura2 = script.Aura1:Clone()
			local aura1 = script.Aura2:Clone()
			aura2.Parent = v
			aura1.Parent = v
		end
	end
	
	local finddesummon = Character:FindFirstChild("Desummon")
	local finddeeffect = Character:FindFirstChild("DesummonEffects")
	
	if finddesummon then
		finddesummon:Destroy()
		finddeeffect:Destroy()
	end


	standpos.Position = Vector3.new(-2.3,-0.2,1) 
	for i , partsinstand in pairs(Standclone:GetDescendants())do
		if partsinstand:IsA("BasePart") or partsinstand:IsA("Debris") then 
			if partsinstand.Transparency < 1 then

				local originaltransparency = partsinstand.Transparency
				partsinstand.Transparency = 1
				TweenService:Create(partsinstand,TweenInfo.new(.25),{Transparency = originaltransparency }):Play()
				if partsinstand:IsA("BasePart") then
					local originalmaterial = partsinstand.Material

					partsinstand.Material = Enum.Material.Glass
					delay(.2,function()
						partsinstand.Material = originalmaterial
					end)				
				end
			end


		end




	end



elseif Character:FindFirstChild("Stand") then 
	local stand = Character:FindFirstChild("Stand")
	Character.HumanoidRootPart.StandPosition.Position = Vector3.new(0,0,0)


	local desummon = script.Desummon:Clone()
	desummon.Parent = Character
	desummon:Play()
	
	local desummoneffect = script.DesummonEffects:Clone()
	desummoneffect.Parent = Character
	desummoneffect:Play()

	for i ,v in pairs(Character:GetDescendants()) do
		if v:IsA("ParticleEmitter") then
			v:Destroy()
		end
	end
	
	local summonsound = Character:FindFirstChild("Summon")
	local summoneffect = Character:FindFirstChild("SummonEffects")
	
	if summonsound then
		summonsound:Destroy()
		summoneffect:Destroy()
	end
	

	for i , partsinstand in pairs(stand:GetDescendants())do
		if partsinstand:IsA("BasePart") or partsinstand:IsA("Debris") then 
			TweenService:Create(partsinstand,TweenInfo.new(.25),{Transparency = 1  }):Play()
			if partsinstand:IsA("BasePart") then
				partsinstand.Material = Enum.Material.Glass

			end




		end




	end

	Debris:AddItem(stand,.25) 

end

end)

and this is M1

local Deb = game:GetService(“Debris”)
local rep = game:GetService(“ReplicatedStorage”)

–//{ANIM}//–
local combo1 = script.Anim
local combo2 =script.Anim2
local combo3 = script.Anim3

local hit = script.HitAnim

rep.Stand.TW.M1.OnServerEvent:Connect(function(Player)
local Character = Player.Character
local hitbox = script.Hitbox:Clone()
hitbox.Parent = workspace
hitbox.CFrame = Character.PrimaryPart.CFrame * CFrame.new(0,0,(hitbox.Size.Z/2)*-1)
Deb:AddItem(hitbox,.35)
local ignorelist = {}
hitbox.Touched:Connect(function(hitpart)
if not hitpart:IsDescendantOf(Character) then
if hitpart.Parent:FindFirstChild(“Humanoid”) then
local enemy = hitpart.Parent
if (table.find(ignorelist,enemy) == nil) then
table.insert(ignorelist,enemy)
enemy.Humanoid:TakeDamage(8.25)

				enemy.Humanoid:LoadAnimation(HitAnimation):Play()
			end
		end
	end
end)

end)

rep.Stand.TW.M1.OnServerEvent:Connect(function(Player,count)
local Character = Player.Character
local Stand = Character:FindFirstChild(“Stand”)
if Stand then
local AnimControl = Stand:WaitForChild(“AnimationController”)
if Player.Backpack.Value.UsingMove.Value == false then
local Sound = script.LMB1:Clone()
Sound.Parent = Stand
Sound:Play()
local Sounds = script.Swing:Clone()
Sounds.Parent = Stand
Sounds:Play()
Player.Backpack.Value.UsingMove.Value = true
AnimControl:LoadAnimation(combo1):Play()
Character.HumanoidRootPart.StandPosition.Position = Vector3.new(0,0,-3)
wait(.65)
Player.Backpack.Value.UsingMove.Value = false
Character.HumanoidRootPart.StandPosition.Position = Vector3.new(-2.3,-0.2,1)
wait(2)
Sound:Destroy()
Sounds:Destroy()

	end
end

end)

I know the summon and M1 script is long

pls try to read it and find a way to fix it i really need to fix this bug

This is probably a CFrame issue.

what line in my script? can u tell me?

I assume you followed a tutorial on how to make this. Please read more about CFrames and how CFrames work. To answer your question, all the lines with .Position.

so what should i change all my position to CFrame?

You should play with it around and check what position suits you the best.

how i change the stand infront of my stand

how to Use CFrame i cant do it

Character.HumanoidRootPart.StandPosition.Position = Vector3.new(0,0,-3)
how to change this line to CFrame?

I used CFrame and the stand also bugging