Remote Events for Module Script

Hi,
I’m currently trying to make a level and EXP indicator for a game with GUIs. ProfileService doesn’t work on local scripts, and using a regular Script under the GUIs doesn’t work either, returning “Module code did not return exactly 1 value.” Correct me if I am wrong, but I think I need to use a RemoteEvent to communicate this correctly, but I am really not sure where to being, and most tutorials don’t seem to help with this exact situation.
Here is the code that I used for the GUI script.

local DataManager = require(game.ReplicatedStorage.DataManager)
local txt = script.Parent
local exptxt = script.Parent.Parent.Parent.EXPbar
local function onPlayerAdded(player)
	if player then
		local data = DataManager:Get(player)
		if data then
			local leveltext = tostring(data.level)
			local experience = tostring(data.exp)
			local maxexp = (((data.level)*100)+100)
			txt.Text = leveltext
			exptxt.Text = experience.." EXP / "..maxexp .." EXP"
		else
			txt.Text = "No level data found."
			exptxt.Text = "Please contact our socials."
		end
	end
end
game.Players.PlayerAdded(onPlayerAdded)

Any guidance on how to use RemoteEvents or another solution would be greatly appreciated. Thank you!

ProfileService would not run on local scripts due to DataStoreService being limited to [server] scripts.

This message usually comes with a module that does not return itself correctly. Ensure you uphold the format for module scripts.

I’d recommend you to make a framework for storing data with the Server/Client Model in mind. Limit Player access to Server Data as well use remote events only where you must need them. This prevents duped data & exploiters gaining control.

I’ve personally made a Framework that you could use. Shall you wish to use it, I could guide you.