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

Trello Ban Script not banning new players?

Asked by 8 years ago
Edited 8 years ago

Hello! To begin with, the script works at first. When I join a server and do ban plrName the player get's put on the Trello, His name and his userID are printed in the console.

But let's say another player joins, I'm not able to ban him untill I rejoin myself. I do not believe the trello api I'm using is needed, But if it is just ask.

01------[[[[[[[[[[[[[[[[---->
02api = require(game.ServerScriptService.TrelloAPI)   -- Require Module
03BoardID =  api:GetBoardID("NewTest")                           -- Use module to get BoardID From Trello
04ListID =  api:GetListID("Ban List",BoardID)                    -- Use module to get List from BoardID
05 
06speakers = {"Robertandy11"} --ADmins
07banned = {} -- People I don't like
08 
09function checkSpeakers(name)  --Test if "speaker" is admin or not
10    for i,v in pairs(speakers) do
11                if (string.upper(name) == string.upper(v)) then return true end
12        end
13        return false
14end
15 
View all 45 lines...

Edit : All this script is supposed to do is create a Card on the banlist on trello, which it does But not for the players that join after the Admin/Moderator. The script that takes care of game-wide banning people and syncing bans is alerady done.

1 answer

Log in to vote
1
Answered by 8 years ago

Fixed by removing the chatted event from on player added event. This caused the command only to be ran once.

I added a new event to the workspace and I made a local script fire that even to the server when someone used a command. Can be built upon and optimized.

Also fixed the implemented ban and the player rejoin ban. They simply wasn't implemented.

Another bug I fixed was inserting the player into a banned array.

Good day Sir!

Ad

Answer this question