Hi, I’m making an auto name info system, for a modular admin panel. i have an info module which holds the panel version and title (name), and i have it setup so that instead of directly location n asset it will find the asset by the in the info module
my issue is that when i load the panel (with the server script) it copys the dictionary (info module) and puts it inside the info module inside the local script, but on the client it stays empty
this is what is what is copied from server
this is what the client sees
Similarly I also had a issue with getting the info from a modulescript for a modular admin I was also making and tried the same exact thing you did.
The way i fixed this was using remotefunctions. This way you can return info from a serverscript to a clientscript. Very useful.
--//CLIENT\\--
local RemoteFunction = game.ReplicatedStorage.AdminFunction -- Just where the remotefunction is stored.
local TateruCommands = RemoteFunction:InvokeServer("GetCommands")
--//SERVER\\--
-- The server script obv hold a lot more important things than returning commands.
local TateruCommands = require(script.Parent.Parent) -- Everything is stored in the same folder.
local function GetCommands(Player,Value,Value2)
if Value == "GetCommands" then
return TateruCommands.GetCommands()
end
end
game.ReplicatedStorage.AdminFunction.OnServerInvoke = GetCommands
--//MODULESCRIPT\\--
local Commands = {
["tp"] = {1,"Player","Player"} -- Example command list, works a lot different from yours.
}
local module = {}
module.GetCommands = function(Value)
return Commands
end
The result is a reliable way to return information without creating any other scripts or copying and pasting info from the module script.
ok so i had tried using a RemoteEvent before but i was wondering why it wasnt firing inside the local script…it was because inside the server script i had fired the event before i had parented it to the playerGui