is it possible for me to create a variable in a module script, that the variable is then used in all the other scripts after i use that function in a different script?
module script code:
local module = {}
function module.scientificdisp(amount)
local val = math.floor(amount/(10^math.floor(math.log10(amount)))*100)/100 .."e"..math.floor(math.log10(amount))
print(val)
return val
end
return module
other script code:
local module = require(game.ServerScriptService.ModuleScript)
while task.wait(0.2) do
if game.ReplicatedStorage.Nothing.Value > 9 then
module.scientificdisp(game.ReplicatedStorage.Nothing.Value)
print(val)
script.Parent.Text = val
else
script.Parent.Text = game.ReplicatedStorage.Nothing.Value
end
end