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

Help: Replacement for Deprecated "LocalLibrary"?

Asked by 5 years ago

Is there a replacement for Local Library? It seems that its deprecation might have broken this script.

local Utils = assert(LoadLibrary("RbxUtility")) local DataStore = game:GetService("DataStoreService"):GetDataStore("GlobalPlayerList")

local Creator = "superbluefire1" --Change this to your username

game.Players.PlayerAdded:connect(function(Player) local PL = DataStore:GetAsync("PlayerListV1.0")

if PL == nil then --If this is the first time running then local TempList = "Player List: "..Player.Name..", " DataStore:SetAsync("PlayerListV1.0",TempList) else local LoadedList = DataStore:GetAsync("PlayerListV1.0") DataStore:SetAsync("PlayerListV1.0",LoadedList..Player.Name..", ")
end

if Player.Name == Creator then game.Players[Creator].PlayerGui.PlayerList.ScrollingFrame.Visible = true game.Players[Creator].PlayerGui.PlayerList.ScrollingFrame.Text.Text = DataStore:GetAsync("PlayerListV1.0")
game.Players[Creator].PlayerGui.PlayerList.ScrollingFrame.Clear.MouseButton1Click:connect(function() DataStore:SetAsync("PlayerListV1.0","Player List: ")
end) end

Answer this question