Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- This is a secret Module script that LuckyMaxer made for the Night at the Museum Tablet.
- It changes the glow color.
- ]]--
- AdminTable = {
- {
- Key = "NATMTablet",
- FullReturnKey = "NightAtTheMuseumTablet",
- Users = {
- {UserId = -1},
- {UserId = 322834},
- {UserId = 13203163},
- {UserId = 3089945},
- {UserId = 264635},
- },
- Return = {
- ColorGui = (function(DefaultColor)
- local function Split(String, Divider)
- local Results = {}
- local Number = 1
- for i = 1, string.len(String) do
- if string.sub(String, i, i + (string.len(Divider) - 1)) == Divider then
- if string.sub(String, Number, (i - 1)) ~= "" then
- table.insert(Results, string.sub(String, Number, (i - 1)))
- end
- Number = (i + string.len(Divider))
- end
- end
- if string.sub(String, Number) ~= "" then
- table.insert(Results, string.sub(String, Number))
- end
- return Results
- end
- local Color3PickerGui = Instance.new("ScreenGui")
- Color3PickerGui.Name = "Color3PickerGui"
- local Frame = Instance.new("Frame")
- Frame.BackgroundColor3 = Color3.new(255, 255, 255)
- Frame.Position = UDim2.new(0, 10, 0, 500)
- Frame.Size = UDim2.new(0, 200, 0, 50)
- Frame.ZIndex = 1
- Frame.Parent = Color3PickerGui
- local Border = Instance.new("Frame")
- Border.Name = "Border"
- Border.BackgroundTransparency = 1
- Border.Position = UDim2.new(0.025, 0, 0.075, 0)
- Border.Size = UDim2.new(0.95, 0, 0.85, 0)
- Border.ZIndex = 2
- Border.Parent = Frame
- local ColorBox = Instance.new("Frame")
- ColorBox.Name = "ColorBox"
- ColorBox.Position = UDim2.new(0.75, 0, 0, 0)
- ColorBox.Size = UDim2.new(0.25, 0, 1, 0)
- ColorBox.BackgroundColor3 = ((DefaultColor and DefaultColor) or Color3.new(255, 255, 255))
- ColorBox.ZIndex = 3
- ColorBox.Parent = Border
- local Color3Input = Instance.new("TextBox")
- Color3Input.Name = "Color3Input"
- Color3Input.BackgroundTransparency = 1
- Color3Input.ClearTextOnFocus = true
- Color3Input.Position = UDim2.new(0, 0, 0, 0)
- Color3Input.Size = UDim2.new(0.75, 0, 0.75, 0)
- Color3Input.Font = Enum.Font.SourceSans
- Color3Input.TextColor3 = Color3.new(0, 0, 0)
- Color3Input.TextScaled = true
- Color3Input.TextWrapped = true
- Color3Input.TextXAlignment = Enum.TextXAlignment.Center
- Color3Input.TextYAlignment = Enum.TextYAlignment.Center
- Color3Input.ZIndex = 3
- Color3Input.Parent = Border
- local ColorSubmit = Instance.new("TextButton")
- ColorSubmit.Name = "Submit"
- ColorSubmit.BackgroundTransparency = 1
- ColorSubmit.Position = UDim2.new(0.125, 0, 0.75, 0)
- ColorSubmit.Size = UDim2.new(0.5, 0, 0.25, 0)
- ColorSubmit.Font = Enum.Font.SourceSans
- ColorSubmit.FontSize = Enum.FontSize.Size14
- ColorSubmit.Text = "[ Set Color ]"
- ColorSubmit.TextColor3 = Color3.new(255, 0, 0)
- ColorSubmit.TextScaled = false
- ColorSubmit.TextWrapped = false
- ColorSubmit.TextXAlignment = Enum.TextXAlignment.Center
- ColorSubmit.TextYAlignment = Enum.TextYAlignment.Center
- ColorSubmit.ZIndex = 3
- ColorSubmit.Parent = Border
- local BaseColor = tostring(ColorBox.BackgroundColor3)
- Color3Input.Text = BaseColor
- ColorSubmit.MouseButton1Down:connect(function()
- local Color = Color3Input.Text
- Color = string.gsub(Color, " ", "")
- Color = Split(Color, ",")
- local R = tonumber(Color[1])
- local G = tonumber(Color[2])
- local B = tonumber(Color[3])
- if R and G and B then
- ColorBox.BackgroundColor3 = Color3.new(R, G, B)
- else
- Color3Input.Text = BaseColor
- end
- end)
- ColorBox.Changed:connect(function(Property)
- if Property == "BackgroundColor3" then
- Color3Input.Text = tostring(ColorBox.BackgroundColor3)
- end
- end)
- return Color3PickerGui
- end),
- },
- },
- }
- FullReturnKey = "RETURNKEY"
- function GetTable(Table)
- for i, v in pairs(AdminTable) do
- return ((((Table.Key and Table.Player and CheckPlayer(v, Table.Player)) or (Table.ReturnKey and Table.ReturnKey == FullReturnKey)) and v.Return) or ((Table.FullReturnKey and v.FullReturnKey and Table.FullReturnKey == v.FullReturnKey) and v) or nil)
- end
- return nil
- end
- function CheckPlayer(Table, Player)
- if not Table or not Player or not Player.Parent then
- return
- end
- local TableType = type(Table)
- Table = (((TableType == "string" and GetTable(Table, FullReturnKey)) or (TableType == "table" and Table)) or nil)
- if not Table or not Table.Users then
- return
- end
- for i, v in pairs(Table.Users) do
- if ((v.UserId and tonumber(v.UserId) == tonumber(Player.userId)) or (v.UserName and tostring(v.UserName) == tostring(Player.Name))) then
- return true
- end
- end
- return false
- end
- return {GetTable = GetTable, CheckPlayer = CheckPlayer}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement