Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Expected ')' (to close '(' at line 73) "got local"?

Asked by 4 years ago
local AKMod = game.CoreGui.ScreenGui.main.AK
AKMod.MouseButton1Down:connect (onAKModActivated()
    local player = game:GetService("Players").LocalPlayer
    local gun = player.Backpack:FindFirstChild("AK-47")
    local sM = require(gun:FindFirstChild("GunStates"))
    sM["Damage"] = 999
    sM["MaxAmmo"] = 9999991
    sM["StoredAmmo"] = 9999991
    sM["FireRate"] = 0.000001
    sM["AmmoPerClip"] = 9999991
    sM["Range"] = 5000
    sM["ReloadTime"] = 0.05
    sM["Bullets"] = 10
    sM["AutoFire"] = true
end)

I just dont have a clue. how to fix it

0
Where exactly is the error because it says line 73 but there's only 15 lines Barty200 85 — 4y
0
Line 3 slipperycat753 2 — 4y
0
I think Connect should be with a capital Barty200 85 — 4y
0
Did you set up the module correctly? SnowieDev 171 — 4y
View all comments (2 more)
0
why is there a "CoreGui"... 0msh 333 — 4y
0
CoreGui is for plugins and stuff PrismaticFruits 842 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago

I don't know what you are trying to do but it should be :Connect(function() unless you already made a function called onAKModActivated()

AKMod.MouseButton1Down:connect(function()
    -- Your code here
end)
Ad

Answer this question