Hi there I was making a script the code is below and on the 1st line the code gives the error specified in the title can someone help me to fix this, it wasn’t happening a few mins ago
local module = require(game.ServerStorage.SettingsForProfile)
game.Players.PlayerAdded:Connect(function(player)
wait(1)
if module.CashOnOff == "On" then
elseif module.CashOnOff == "Off" then
game.ReplicatedStorage.RemoteForOnOffCash:FireAllClients()
print("Fired")
end
end)
local module = {}
module.theme = "Black" -- Its either black or white
module.CashOnOff = "On" --Its either On or Off keep capitalization correct
module.LeaderStatsPathForCash = game.Players.LocalPlayer.leaderstats.Cash -- Default for example change it
return module
local module = require(game.ServerStorage.SettingsForProfile)
game.Players.PlayerAdded:Connect(function(player)
wait(1)
if module.CashOnOff == "On" then
elseif module.CashOnOff == "Off" then
game.ReplicatedStorage.RemoteForOnOffCash:FireAllClients()
print("Fired")
end
end)
If this is fixed please post how you fixed it and then mark that as the Solution at the bottom of the post so that if anyone searches the devforum for answers your post can help them.