Bug when cloning MfdGui back to CoreMfdGui

I will put this in scripting support until there is no solution.

I have an Instance (CustomService btw) called CoreMfdGui, that when the server adds it to the player, the Client waits for it to exist and then the ScreenGui inside of it changes its parent to PlayerGui.
Problem is, when I clone it back to it’s previous parent, everything isn’t cloned, I have added delays, nothing. Screenshot below, for your information, no, there aren’t any errors

Code

--	// FileName: PlayerInit.lua
--	// Written By: NSG (Forked from CoreScripts and utilized for Identity 2)
--	// Description: Waits for server to clone CoreMfdPackages, CoreMfdGui and CoreMfdClientScripts to Player and puts them in the correct folders
local PlayersService = game:GetService("Players")
local CoreMfdGui = PlayersService.LocalPlayer:WaitForChild("CoreMfdGui", 15)
wait(5)
CoreMfdGui.MfdGui.Parent = PlayersService.LocalPlayer.PlayerGui
local newMfdGui = PlayersService.LocalPlayer.PlayerGui:WaitForChild("MfdGui", 15):Clone()

newMfdGui.Parent = CoreMfdGui

Hierarchy:
image

1 Like

First off, why would you do it this way instead of just cloning it into the PlayerGui? Parenting it out then cloning it back seems to be a recipe for disaster anyway.

That said, are the items being cloned Archivable? I’m pretty sure PlayerGui isn’t, so perhaps that is the issue. Another reason to not clone tampered objects back into your storage.

Side note: the hierarchy photo is when the game isn’t running, client can only see MfdReplicatedStorage

1 Like

Doing it the other way does not show any positive results either, and it comes back half of the time with the correct objects

1 Like

And I also just made an amazing discovery, PlayerGui detects this Gui now for some reason, so I can clone it straight to there instead of the other stuff

1 Like