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

Kohl's Admin Commands V5 - Setting A Player to a Table On Touch? [closed]

Asked by 10 years ago

This question already has an answer here:

How To Make An Admin Giver For Kohl's Admin V5?

I'm currently trying to create an onTouch script that adds a player to the TempAdmins table for Kohl's Admin Commands V5

Tables:

set['Owners'] = {"Your Name Here"} -- Are able to set Admins who can ban/etc... using :pa name
set['Admins'] = {} -- Sets Admins who can use ban/kick/admin or shutdown
set['TempAdmins'] = {} -- Sets Admins who can't use ban/kick/admin or shutdown
set['BanList'] = {'Test_User123=1235674'} -- Add people to ban here. Format to use UserId is "Name=UserId" EX: "John32=192845", this bans any player named John32 or has an id of 192845 (This way they can't bypass the ban by changing their username) use $group=GROUPID to ban groups.
set['MuteList'] = {} -- Add the names of people to mute (makes it so they cant talk)

I put this code at the end of the script, hoping that it would set the player to temp admin.

`function onTouched(hit)
    if addeb == false then
        addeb = true
        script.Parent.Parent.Name = "Your an Admin, Try :cmds"
     table.insert(set['TempAdmins'],player.Name)
    wait(3)
    script.Parent.Parent.Name = "Touch For Admin!"
end

script.Parent.Touched:connect(onTouched)
end`

Some help would be appreciated.

0
Swap Line 10 and 11. The end should be before the event. Line 5: it's "hit.Parent.Name" not "player.Name" fahmisack123 385 — 10y

Marked as Duplicate by Tempestatem, Sublimus, and TheeDeathCaster

This question has been asked before, and already has an answer. If those answers do not fully address your question, then please ask a new question here.

Why was this question closed?