Hi! I am a new scripter, and I am stuck with this script. I have tried for like 30 min to fix it by myself, but I don’t know how to fix it. You can check the error picture.
--Variables
local EventModule = require(game.ServerStorage.EventModule)
local RemoteEvents = game.ReplicatedStorage.RemoteEvents
--Functions
RemoteEvents.AddSlushieEvent.OnServerEvent:Connect(function(player, ValueFolder)
local leaderstats = player:WaitForChild("leaderstats")
leaderstats.Slushies.Value = leaderstats.Slushies.Value * ValueFolder.AmountGive.Value *{EventModule.EventBoost + 1}
end)
The EventModule (I dont know if I did this right)
local EventBoost = {
["EventBoost"] = 1;
}
return EventBoost
Tool Script
--Variables
local Debounce = false
local SlushieTool = script.Parent
--Functions
SlushieTool.Activated:Connect(function()
if Debounce == false then
Debounce = true
game.ReplicatedStorage.RemoteEvents.AddSlushieEvent:FireServer(script.Parent.Values.AmountGive)
wait(0.3)
Debounce = false
end
end)
Error
Hope you can help me out.