You can write your topic however you want, but you need to answer these questions:
What do you want to achieve? Keep it simple and clear!
Be able to change parents without any errors or fails
What is the issue? Include screenshots / videos if possible!
I get an error that say it does not exist or just “Tank Is not a valid member of Workspace Workspace”
here is a pic
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
Changing the line, many location checkings
script.Parent.Triggered:Connect(function()
local Tanko = script.Parent.Parent.Parent.Tank
local table = script.Parent.Parent.Parent.Tank:GetChildren()
for i, v in pairs(table) do
if v:IsA("Part") or v:IsA("UnionOperation") then
local AbortDeselectText = script.Parent.Parent.Parent.Display.SurfaceGui["Abort/Deselect"].Text
if AbortDeselectText == "Deselect" or AbortDeselectText == "" then
v.Anchored = false
script.Parent.Parent.Stats.Status.Value = "Detached"
script.Parent.Parent.Parent.Display.SurfaceGui.Progress.Text = 0
script.Parent.Enabled = false
script.Parent.ActionText = "Couple"
Tanko.Parent = game.Workspace -- here its supposted to be changed
script.Parent.Parent.Parent.Tube.Touched:Connect(function(Toucher)
if Toucher:IsA("Part") or Toucher:IsA("UnionOperation") then
print("touched")
if Toucher.Parent.Name == "Tank" then
print("IsTank")
script.Parent.Enabled = true
script.Parent.Triggered:Connect(function()
game.Workspace.Tank.Parent = script.Parent.Parent.Parent -- here is supposted to be changed back
script.Parent.Enabled = false
local TankPos = script.Parent.Parent.Parent.TankPlace.Position
script.Parent.Parent.Parent.Tank.TankItself.Position = TankPos
print("Moved")
local table2 = script.Parent.Parent.Parent.Tank:GetChildren()
for i, v in pairs(table2) do
end
end)
end
end
end)
end
end
end
end)
Could the Tank be stored in replicated storage and moved in and out of there, or cloned from there and destroyed when you’re done with it?
Seems strange to have the script in the Tank when you are moving it in and out of the workspace.