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

Why am I getting syntax errors in this require script?

Asked by 5 years ago
Edited 5 years ago

I'm trying to make a script that when a remote is fired it loads a script. Ex:

SERVER

remote.OnServerEvent:Connect(function(player, parameterone, parametertwo)
    local thing = require(parameterone)
    thing.[parametertwo]
end)

CLIENT EXAMPLE

remote:FireServer("1312630273", "giveAdmin'coolguyjeremy1213'")

Can someone offer syntax help because I've tried a lot of things to get it to load but it keeps telling me it had "Invalid argument(s)". Thanks :D

0
Just change "giveAdmin'coolguyjeremy1213'" to two seperate parameters ("giveAdmin", "coolguyjeremy1213") and then add a paramterthree to the ServerEvent function Warfaresh0t 414 — 5y

Answer this question