Corescript improvements, playerlist fixes, and improvements to debug console
This commit is contained in:
parent
615fbc465c
commit
67e8f51ca4
|
|
@ -136,7 +136,7 @@ function AnimateBars(x, y, lastX, height)
|
|||
end
|
||||
tray.bar2.BackgroundColor3 = Color3.new(1, GBchannels, GBchannels)
|
||||
|
||||
wait(0.02)
|
||||
wait()
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -159,12 +159,12 @@ function AnimateHurtOverlay()
|
|||
for i=1,i_total do
|
||||
overlay.Position = UDim2.new( (-2 + (2 * (i/i_total)) + wiggle_total/2), 0, (-2 + (2 * (i/i_total)) + wiggle_total/2), -22 )
|
||||
overlay.Size = UDim2.new( (4.5 - (3.5 * (i/i_total)) + wiggle_total), 0, (4.65 - (3.5 * (i/i_total)) + wiggle_total), 30 )
|
||||
wait(0.01)
|
||||
wait()
|
||||
end
|
||||
|
||||
i_total = 30
|
||||
|
||||
wait(0.03)
|
||||
wait()
|
||||
|
||||
-- Animate Out, slow
|
||||
for i=1,i_total do
|
||||
|
|
@ -174,7 +174,7 @@ function AnimateHurtOverlay()
|
|||
wiggle_total = wiggle_total + wiggle_i
|
||||
overlay.Position = UDim2.new( (0 - (2 * (i/i_total)) + wiggle_total/2), 0, (0 - (2 * (i/i_total)) + wiggle_total/2), -22 )
|
||||
overlay.Size = UDim2.new( (1 + (3.5 * (i/i_total)) + wiggle_total), 0, (1.15 + (3.5 * (i/i_total)) + wiggle_total), 30 )
|
||||
wait(0.01)
|
||||
wait()
|
||||
end
|
||||
|
||||
-- Hide after we're done
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs a new computed state object, which follows the value of another
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs and returns objects which can be used to model derived reactive
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs a new ForKeys state object which maps keys of an array using
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs a new ForPairs object which maps pairs of a table using
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs a new ForValues object which maps values of a table using
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs a new state object which can listen for updates on another state
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
--!nonstrict
|
||||
--!strict
|
||||
|
||||
--[[
|
||||
Constructs and returns objects which can be used to model independent
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
--!strict
|
||||
--!nolint LocalShadow
|
||||
|
||||
--[[
|
||||
Time-based contextual values, to allow for transparently passing values down
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
--!strict
|
||||
local Load = {}
|
||||
|
||||
function Load.Help()
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
return function(IsServer: boolean)
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
return function(IsServer: boolean)
|
||||
local RedEvent = require "../RedEvent"(IsServer)
|
||||
local Event = RedEvent.Remote
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
return function(IsServer: boolean)
|
||||
local Players = game:GetService "Players"
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
return function(IsServer: boolean)
|
||||
local ReplicatedStorage = game:GetService "ReplicatedStorage"
|
||||
local Players = game:GetService "Players"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
local Spawn = require "./Spawn"
|
||||
local typeof = require "../../../Modules/Polyfill/typeof"
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
-- local ReplicatedStorage = game:GetService "ReplicatedStorage"
|
||||
--!strict
|
||||
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local function MakeHeartbeatFunction(Clock: Clock)
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
local CollectionService = game:GetService "CollectionService"
|
||||
|
||||
local Spawn = require "./Spawn"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local Spawn = require "./Spawn"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
return function<T>(Limit: number, Interval: number)
|
||||
assert(Limit > 0, "Limit must be greater than 0")
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
local Promise = require "./Promise"
|
||||
local Spawn = require "./Spawn"
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,6 @@
|
|||
local FreeThread: thread? = nil
|
||||
--!strict
|
||||
|
||||
local FreeThread: thread?
|
||||
|
||||
local function FunctionPasser(fn, ...)
|
||||
local AquiredThread = FreeThread
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
--!strict
|
||||
|
||||
local function Red(_, Script: LuaSourceContainer)
|
||||
local _SERVER
|
||||
|
||||
|
|
|
|||
|
|
@ -1,181 +0,0 @@
|
|||
-- A basic polyfill for the typeof function
|
||||
|
||||
return function(value)
|
||||
local basicType = type(value)
|
||||
|
||||
if
|
||||
basicType == "nil"
|
||||
or basicType == "boolean"
|
||||
or basicType == "number"
|
||||
or basicType == "string"
|
||||
or basicType == "function"
|
||||
or basicType == "thread"
|
||||
or basicType == "table"
|
||||
then
|
||||
return basicType
|
||||
end
|
||||
|
||||
-- Will short-circuit
|
||||
--[[
|
||||
{
|
||||
name of type to check,
|
||||
{ list of required properties },
|
||||
}
|
||||
]]
|
||||
local tests = {
|
||||
{
|
||||
"Instance",
|
||||
{ "ClassName" },
|
||||
},
|
||||
{
|
||||
"EnumItem",
|
||||
{ "EnumType", "Name", "Value" },
|
||||
},
|
||||
{
|
||||
"Enum",
|
||||
{ "GetEnumItems" },
|
||||
},
|
||||
{
|
||||
"Enums",
|
||||
{ "MembershipType" }, -- lmao
|
||||
},
|
||||
{
|
||||
"RBXScriptSignal",
|
||||
{
|
||||
"connect",
|
||||
-- "connected",
|
||||
-- "connectFirst",
|
||||
-- "connectLast",
|
||||
"wait",
|
||||
},
|
||||
},
|
||||
{
|
||||
"RBXScriptConnection",
|
||||
{
|
||||
"connected",
|
||||
"disconnect",
|
||||
},
|
||||
},
|
||||
{
|
||||
"TweenInfo",
|
||||
{
|
||||
"EasingDirection",
|
||||
-- "Time",
|
||||
-- "DelayTime",
|
||||
"RepeatCount",
|
||||
"EasingStyle",
|
||||
-- "Reverses",
|
||||
},
|
||||
},
|
||||
{
|
||||
"CFrame",
|
||||
{
|
||||
"p",
|
||||
"x",
|
||||
"y",
|
||||
"z",
|
||||
"lookVector",
|
||||
},
|
||||
},
|
||||
{
|
||||
"Vector3",
|
||||
{
|
||||
"Lerp",
|
||||
-- "Cross",
|
||||
-- "Dot",
|
||||
"unit",
|
||||
"magnitude",
|
||||
"x",
|
||||
"y",
|
||||
"z",
|
||||
},
|
||||
},
|
||||
{
|
||||
"Vector3int16",
|
||||
{ "z", "x", "y" },
|
||||
},
|
||||
{
|
||||
"Vector2",
|
||||
{ "unit", "magnitude", "x", "y" },
|
||||
},
|
||||
{
|
||||
"Vector2int16",
|
||||
{ "x", "y" },
|
||||
},
|
||||
{
|
||||
"Region3",
|
||||
{ "CFrame", "Size" },
|
||||
},
|
||||
{
|
||||
"Region3int16",
|
||||
{ "Min", "Max" },
|
||||
},
|
||||
{
|
||||
"Ray",
|
||||
{
|
||||
"Origin",
|
||||
"Direction",
|
||||
"Unit",
|
||||
"ClosestPoint",
|
||||
"Distance",
|
||||
},
|
||||
},
|
||||
{
|
||||
"UDim",
|
||||
{ "Scale", "Offset" },
|
||||
},
|
||||
{
|
||||
"Axes",
|
||||
{ "Z", "X", "Y" },
|
||||
},
|
||||
{
|
||||
"UDim2",
|
||||
{ "X", "Y" },
|
||||
},
|
||||
{
|
||||
"BrickColor",
|
||||
{
|
||||
"Number",
|
||||
"Name",
|
||||
"Color",
|
||||
"r",
|
||||
"g",
|
||||
"b",
|
||||
},
|
||||
},
|
||||
{
|
||||
"Color3",
|
||||
{ "r", "g", "b" },
|
||||
},
|
||||
{
|
||||
"Faces",
|
||||
{
|
||||
"Right",
|
||||
"Top",
|
||||
"Back",
|
||||
-- "Left",
|
||||
-- "Bottom",
|
||||
-- "Front",
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
for _, v in ipairs(tests) do
|
||||
local t, test = v[1], v[2]
|
||||
|
||||
local ok, result = pcall(function()
|
||||
for _, prop in ipairs(test) do
|
||||
if value[prop] == nil then
|
||||
return false
|
||||
end
|
||||
-- Cannot throw if the property does not exist,
|
||||
-- as userdatas may allow nil indexing
|
||||
end
|
||||
return true
|
||||
end)
|
||||
|
||||
if ok and result then
|
||||
return t
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1,17 +1,71 @@
|
|||
--!strict
|
||||
|
||||
local Players = game:GetService "Players"
|
||||
local MaxLength = 35
|
||||
|
||||
local New = (require "../Modules/New").New
|
||||
|
||||
return function(parent: Instance)
|
||||
local username = Players.LocalPlayer.Name
|
||||
if username ~= "Heliodex" then -- Don't show the debug console for anyone but me
|
||||
local logEvent: BindableEvent
|
||||
|
||||
local docs: { [string]: { string } } = {
|
||||
help = {
|
||||
"help()",
|
||||
"You've already found this command!",
|
||||
},
|
||||
printTable = {
|
||||
"printTable(t: { [any]: any }, max: number?)",
|
||||
"Prints the contents of a table to the console.",
|
||||
"`max` is the maximum number of entries to print. If not provided, all",
|
||||
"entries are printed.",
|
||||
},
|
||||
exit = {
|
||||
"exit()",
|
||||
"Exits the debug console.",
|
||||
},
|
||||
}
|
||||
|
||||
local utility = {
|
||||
help = function()
|
||||
for _, doc in pairs(docs) do
|
||||
logEvent:Fire(doc[1], Color3.new(1, 1, 0.3))
|
||||
for i = 2, #doc do
|
||||
logEvent:Fire("\t" .. doc[i], Color3.new(1, 1, 1))
|
||||
end
|
||||
end
|
||||
end,
|
||||
printTable = function(t: { [any]: any }, max: number?)
|
||||
assert(type(t) == "table", "Expected table, got " .. type(t))
|
||||
|
||||
local num = max or math.huge
|
||||
local len = 0
|
||||
for k, v in pairs(t) do
|
||||
len += 1
|
||||
if len < num then
|
||||
logEvent:Fire(tostring(k) .. " = " .. tostring(v))
|
||||
end
|
||||
end
|
||||
if len >= num then
|
||||
logEvent:Fire("... and " .. tostring(len - num) .. " more")
|
||||
end
|
||||
end,
|
||||
exit = function()
|
||||
logEvent:Fire("Goodbye!", Color3.new(1, 1, 0.3))
|
||||
wait(0.5)
|
||||
local debug = game.CoreGui:FindFirstChild "Debug console" :: ScreenGui
|
||||
debug:Destroy()
|
||||
end,
|
||||
}
|
||||
|
||||
return function(parent: CoreGui)
|
||||
if not Players.LocalPlayer or Players.LocalPlayer.Name ~= "Heliodex" then -- Don't show the debug console for anyone but me
|
||||
return
|
||||
end
|
||||
|
||||
local logEvent = New "BindableEvent" {
|
||||
Name = "Log",
|
||||
Parent = parent,
|
||||
}
|
||||
logEvent = logEvent
|
||||
or New "BindableEvent" {
|
||||
Name = "Log",
|
||||
Parent = game,
|
||||
}
|
||||
|
||||
local screen = New "ScreenGui" {
|
||||
Name = "Debug console",
|
||||
|
|
@ -21,34 +75,159 @@ return function(parent: Instance)
|
|||
local frame = New "Frame" {
|
||||
Name = "Frame",
|
||||
BackgroundTransparency = 1,
|
||||
Position = UDim2.new(0, 0, 0, 0),
|
||||
Size = UDim2.new(0.5, 0, 1, 0),
|
||||
Parent = screen
|
||||
New "TextBox" {
|
||||
Name = "Input",
|
||||
BackgroundColor3 = Color3.new(0, 0, 0),
|
||||
BackgroundTransparency = 0.5,
|
||||
BorderSizePixel = 0,
|
||||
Position = UDim2.new(0, 0, 1, -30),
|
||||
Size = UDim2.new(1, 0, 0, 30),
|
||||
Font = Enum.Font.SourceSans,
|
||||
FontSize = Enum.FontSize.Size14,
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
TextXAlignment = Enum.TextXAlignment.Left,
|
||||
},
|
||||
Position = UDim2.new(0, 0, 0.2, 0),
|
||||
Size = UDim2.new(0.25, 0, 0.7, 0),
|
||||
Parent = screen,
|
||||
}
|
||||
|
||||
local console = New "TextBox" {
|
||||
local console = New "Frame" {
|
||||
Name = "Console",
|
||||
BackgroundColor3 = Color3.new(0, 0, 0),
|
||||
BackgroundTransparency = 0.5,
|
||||
BorderSizePixel = 0,
|
||||
Position = UDim2.new(0, 0, 0, 0),
|
||||
Size = UDim2.new(1, 0, 1, -30),
|
||||
Parent = frame,
|
||||
}
|
||||
|
||||
local logLines = {}
|
||||
local logLineInstances: { TextLabel } = {}
|
||||
for i = 1, MaxLength do
|
||||
table.insert(logLines, {
|
||||
Text = "",
|
||||
Colour = Color3.new(1, 1, 1),
|
||||
})
|
||||
table.insert(
|
||||
logLineInstances,
|
||||
New "TextLabel" {
|
||||
Name = "LogLine",
|
||||
BackgroundTransparency = 1,
|
||||
Font = Enum.Font.SourceSans,
|
||||
FontSize = Enum.FontSize.Size18,
|
||||
Position = UDim2.new(0, 0, 0, (i - 1) * 18),
|
||||
Size = UDim2.new(1, 0, 0, 18),
|
||||
Text = "",
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
TextXAlignment = Enum.TextXAlignment.Left,
|
||||
Parent = console,
|
||||
}
|
||||
)
|
||||
end
|
||||
|
||||
local function recomputeLogLines()
|
||||
for i, line in ipairs(logLines) do
|
||||
logLineInstances[i].Text = line.Text
|
||||
logLineInstances[i].TextColor3 = line.Colour or Color3.new(1, 1, 1)
|
||||
end
|
||||
end
|
||||
|
||||
logEvent.Event:connect(function(text: string, colour: Color3?)
|
||||
table.insert(logLines, {
|
||||
Text = text,
|
||||
Colour = colour or Color3.new(1, 1, 1),
|
||||
})
|
||||
if #logLines > MaxLength then
|
||||
table.remove(logLines, 1)
|
||||
end
|
||||
|
||||
recomputeLogLines()
|
||||
end)
|
||||
|
||||
local input = New "TextBox" {
|
||||
Name = "Input",
|
||||
BackgroundColor3 = Color3.new(0.2, 0.2, 0.2),
|
||||
BackgroundTransparency = 0.2,
|
||||
BorderSizePixel = 0,
|
||||
Position = UDim2.new(0, 0, 1, -30),
|
||||
Size = UDim2.new(1, 0, 0, 30),
|
||||
Size = UDim2.new(1, -30, 0, 30),
|
||||
Font = Enum.Font.SourceSans,
|
||||
FontSize = Enum.FontSize.Size14,
|
||||
FontSize = Enum.FontSize.Size18,
|
||||
Text = "",
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
TextXAlignment = Enum.TextXAlignment.Left,
|
||||
Parent = frame
|
||||
ClearTextOnFocus = false,
|
||||
Parent = frame,
|
||||
}
|
||||
|
||||
local upButton = New "TextButton" {
|
||||
Name = "UpButton",
|
||||
BackgroundColor3 = Color3.new(0.2, 0.2, 0.2),
|
||||
BackgroundTransparency = 0.2,
|
||||
BorderSizePixel = 0,
|
||||
Position = UDim2.new(1, -30, 1, -30),
|
||||
Size = UDim2.new(0, 30, 0, 30),
|
||||
Font = Enum.Font.SourceSans,
|
||||
FontSize = Enum.FontSize.Size24,
|
||||
Text = "^",
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
Parent = frame,
|
||||
}
|
||||
|
||||
local history = {}
|
||||
local historyPos = 1
|
||||
|
||||
-- on upButton pressed, go back in history
|
||||
upButton.MouseButton1Click:connect(function()
|
||||
if historyPos > #history then
|
||||
return
|
||||
end
|
||||
|
||||
input.Text = history[historyPos]
|
||||
historyPos += 1
|
||||
end)
|
||||
|
||||
input.FocusLost:connect(function(enterPressed)
|
||||
if enterPressed then
|
||||
historyPos = 1
|
||||
local text = input.Text
|
||||
table.insert(history, 1, text)
|
||||
logEvent:Fire("> " .. text)
|
||||
|
||||
-- run the command
|
||||
local fn = loadstring(text)
|
||||
|
||||
if fn then
|
||||
local env = getfenv(fn)
|
||||
for k, v in pairs(utility) do
|
||||
env[k] = v
|
||||
end
|
||||
setfenv(fn, env)
|
||||
|
||||
local success, output = ypcall(fn)
|
||||
if success then
|
||||
logEvent:Fire(
|
||||
"= " .. tostring(output),
|
||||
Color3.new(0.5, 1, 0.5)
|
||||
)
|
||||
else
|
||||
logEvent:Fire(
|
||||
"! " .. tostring(output),
|
||||
Color3.new(1, 0.5, 0.5)
|
||||
)
|
||||
end
|
||||
else
|
||||
logEvent:Fire("Invalid command", Color3.new(1, 0.3, 0.3))
|
||||
end
|
||||
|
||||
input.Text = ""
|
||||
input.BackgroundColor3 = Color3.new(0.2, 0.2, 0.2)
|
||||
end
|
||||
end)
|
||||
|
||||
input.Changed:connect(function(property)
|
||||
if property ~= "Text" or input.Text == "" then
|
||||
return
|
||||
end
|
||||
|
||||
input.BackgroundColor3 = Color3.new(0, 0, 0)
|
||||
end)
|
||||
|
||||
logEvent:Fire("[Reading access...]", Color3.new(0.5, 0.5, 0.5)) -- haxor text
|
||||
logEvent:Fire("[Access granted.]", Color3.new(0.5, 1, 0.5))
|
||||
logEvent:Fire(
|
||||
"Welcome to the Mercury Debug Console!",
|
||||
Color3.new(1, 1, 0.3)
|
||||
)
|
||||
logEvent:Fire("Type `help()` for a list of commands.", Color3.new(1, 1, 1))
|
||||
logEvent:Fire("")
|
||||
end
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
local logEvent
|
||||
|
||||
return function(...: string)
|
||||
if game.Players.LocalPlayer.Name ~= "Heliodex" then
|
||||
return
|
||||
end
|
||||
|
||||
logEvent = logEvent or game:WaitForChild "Log"
|
||||
local message = ""
|
||||
for _, v in ipairs { ... } do
|
||||
message ..= tostring(v) .. " "
|
||||
end
|
||||
print(message)
|
||||
logEvent:Fire(message)
|
||||
end
|
||||
|
|
@ -1,3 +1,4 @@
|
|||
--!strict
|
||||
-- A basic polyfill for the typeof function
|
||||
|
||||
return function(value)
|
||||
|
|
@ -16,32 +17,26 @@ return function(value)
|
|||
end
|
||||
|
||||
-- Will short-circuit
|
||||
--[[
|
||||
{
|
||||
name of type to check,
|
||||
{ list of required properties },
|
||||
}
|
||||
]]
|
||||
local tests = {
|
||||
{
|
||||
"Instance",
|
||||
{ "ClassName" },
|
||||
Type = "Instance",
|
||||
Props = { "ClassName" },
|
||||
},
|
||||
{
|
||||
"EnumItem",
|
||||
{ "EnumType", "Name", "Value" },
|
||||
Type = "EnumItem",
|
||||
Props = { "EnumType", "Name", "Value" },
|
||||
},
|
||||
{
|
||||
"Enum",
|
||||
{ "GetEnumItems" },
|
||||
Type = "Enum",
|
||||
Props = { "GetEnumItems" },
|
||||
},
|
||||
{
|
||||
"Enums",
|
||||
{ "MembershipType" }, -- lmao
|
||||
Type = "Enums",
|
||||
Props = { "MembershipType" }, -- lmao
|
||||
},
|
||||
{
|
||||
"RBXScriptSignal",
|
||||
{
|
||||
Type = "RBXScriptSignal",
|
||||
Props = {
|
||||
"connect",
|
||||
-- "connected",
|
||||
-- "connectFirst",
|
||||
|
|
@ -50,15 +45,15 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"RBXScriptConnection",
|
||||
{
|
||||
Type = "RBXScriptConnection",
|
||||
Props = {
|
||||
"connected",
|
||||
"disconnect",
|
||||
},
|
||||
},
|
||||
{
|
||||
"TweenInfo",
|
||||
{
|
||||
Type = "TweenInfo",
|
||||
Props = {
|
||||
"EasingDirection",
|
||||
-- "Time",
|
||||
-- "DelayTime",
|
||||
|
|
@ -68,8 +63,8 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"CFrame",
|
||||
{
|
||||
Type = "CFrame",
|
||||
Props = {
|
||||
"p",
|
||||
"x",
|
||||
"y",
|
||||
|
|
@ -78,8 +73,8 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"Vector3",
|
||||
{
|
||||
Type = "Vector3",
|
||||
Props = {
|
||||
"Lerp",
|
||||
-- "Cross",
|
||||
-- "Dot",
|
||||
|
|
@ -91,28 +86,28 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"Vector3int16",
|
||||
{ "z", "x", "y" },
|
||||
Type = "Vector3int16",
|
||||
Props = { "z", "x", "y" },
|
||||
},
|
||||
{
|
||||
"Vector2",
|
||||
{ "unit", "magnitude", "x", "y" },
|
||||
Type = "Vector2",
|
||||
Props = { "unit", "magnitude", "x", "y" },
|
||||
},
|
||||
{
|
||||
"Vector2int16",
|
||||
{ "x", "y" },
|
||||
Type = "Vector2int16",
|
||||
Props = { "x", "y" },
|
||||
},
|
||||
{
|
||||
"Region3",
|
||||
{ "CFrame", "Size" },
|
||||
Type = "Region3",
|
||||
Props = { "CFrame", "Size" },
|
||||
},
|
||||
{
|
||||
"Region3int16",
|
||||
{ "Min", "Max" },
|
||||
Type = "Region3int16",
|
||||
Props = { "Min", "Max" },
|
||||
},
|
||||
{
|
||||
"Ray",
|
||||
{
|
||||
Type = "Ray",
|
||||
Props = {
|
||||
"Origin",
|
||||
"Direction",
|
||||
"Unit",
|
||||
|
|
@ -121,20 +116,20 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"UDim",
|
||||
{ "Scale", "Offset" },
|
||||
Type = "UDim",
|
||||
Props = { "Scale", "Offset" },
|
||||
},
|
||||
{
|
||||
"Axes",
|
||||
{ "Z", "X", "Y" },
|
||||
Type = "Axes",
|
||||
Props = { "Z", "X", "Y" },
|
||||
},
|
||||
{
|
||||
"UDim2",
|
||||
{ "X", "Y" },
|
||||
Type = "UDim2",
|
||||
Props = { "X", "Y" },
|
||||
},
|
||||
{
|
||||
"BrickColor",
|
||||
{
|
||||
Type = "BrickColor",
|
||||
Props = {
|
||||
"Number",
|
||||
"Name",
|
||||
"Color",
|
||||
|
|
@ -144,12 +139,12 @@ return function(value)
|
|||
},
|
||||
},
|
||||
{
|
||||
"Color3",
|
||||
{ "r", "g", "b" },
|
||||
Type = "Color3",
|
||||
Props = { "r", "g", "b" },
|
||||
},
|
||||
{
|
||||
"Faces",
|
||||
{
|
||||
Type = "Faces",
|
||||
Props = {
|
||||
"Right",
|
||||
"Top",
|
||||
"Back",
|
||||
|
|
@ -161,7 +156,7 @@ return function(value)
|
|||
}
|
||||
|
||||
for _, v in ipairs(tests) do
|
||||
local t, test = v[1], v[2]
|
||||
local t, test = v.Type, v.Props
|
||||
|
||||
local ok, result = pcall(function()
|
||||
for _, prop in ipairs(test) do
|
||||
|
|
@ -178,5 +173,6 @@ return function(value)
|
|||
return t
|
||||
end
|
||||
end
|
||||
|
||||
return basicType
|
||||
end
|
||||
|
|
|
|||
20
defs.d.lua
20
defs.d.lua
|
|
@ -4024,19 +4024,9 @@ declare class ClusterPacketCache extends Instance
|
|||
end
|
||||
|
||||
declare class CollectionService extends Instance
|
||||
TagAdded: RBXScriptSignal<string>
|
||||
ItemAdded: RBXScriptSignal<string>
|
||||
TagRemoved: RBXScriptSignal<string>
|
||||
ItemRemoved: RBXScriptSignal<string>
|
||||
function AddTag(self, instance: Instance, tag: string): nil
|
||||
function GetAllTags(self): { string }
|
||||
function GetInstanceAddedSignal(self, tag: string): RBXScriptSignal<Instance>
|
||||
function GetInstanceRemovedSignal(self, tag: string): RBXScriptSignal<Instance>
|
||||
ItemAdded: RBXScriptSignal<Instance>
|
||||
ItemRemoved: RBXScriptSignal<Instance>
|
||||
function GetCollection(self, tag: string): { Instance }
|
||||
function GetTagged(self, tag: string): { Instance }
|
||||
function GetTags(self, instance: Instance): { string }
|
||||
function HasTag(self, instance: Instance, tag: string): boolean
|
||||
function RemoveTag(self, instance: Instance, tag: string): nil
|
||||
end
|
||||
|
||||
declare class CommandInstance extends Instance
|
||||
|
|
@ -5037,12 +5027,8 @@ end
|
|||
|
||||
declare class TextBox extends GuiObject
|
||||
ClearTextOnFocus: boolean
|
||||
ContentText: string
|
||||
CursorPosition: number
|
||||
FocusLost: RBXScriptSignal<boolean, InputObject>
|
||||
Focused: RBXScriptSignal<>
|
||||
Font: EnumFont
|
||||
FontFace: Font
|
||||
LineHeight: number
|
||||
ManualFocusRelease: boolean
|
||||
MaxVisibleGraphemes: number
|
||||
|
|
@ -9142,4 +9128,4 @@ declare LoadLibrary: ((libraryName: "RbxFusion") -> Fusion) & ((libraryName: "Rb
|
|||
declare function settings(): GlobalSettings
|
||||
declare function UserSettings(): UserSettings
|
||||
declare function PluginManager(): PluginManager
|
||||
declare function ypcall(f: (() -> any) | (() -> ()), ...: any): (boolean, any)
|
||||
declare function ypcall(f: (() -> any) | (() -> ()) | ((...any) -> (), (...any) -> ()) -> (), ...: any): (boolean, any)
|
||||
|
|
|
|||
|
|
@ -8,20 +8,21 @@ local MarketplaceService = game:GetService "MarketplaceService"
|
|||
local GuiService = game:GetService "GuiService"
|
||||
local ContentProvider = game:GetService "ContentProvider"
|
||||
local HttpService = game:GetService "HttpService"
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
-- wait for important items to appear
|
||||
while not Game do
|
||||
wait(0.1)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
while not MarketplaceService do
|
||||
wait(0.1)
|
||||
RunService.Heartbeat:wait()
|
||||
MarketplaceService = game:GetService "MarketplaceService"
|
||||
end
|
||||
while not game:FindFirstChild "CoreGui" do
|
||||
wait(0.1)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
while not game.CoreGui:FindFirstChild "RobloxGui" do
|
||||
wait(0.1)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
|
||||
-------------------------------- Global Variables ----------------------------------------
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
--!strict
|
||||
-- CoreGui.RobloxGui.CoreScripts/ToolTip
|
||||
print "[Mercury]: Loaded corescript 36868950"
|
||||
|
||||
|
|
@ -5,7 +6,10 @@ local News = require "../Modules/New"
|
|||
local New = News.New
|
||||
local Hydrate = News.Hydrate
|
||||
|
||||
local controlFrame = script.Parent:FindFirstChild "ControlFrame"
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local RobloxGui = script.Parent
|
||||
local controlFrame = RobloxGui:FindFirstChild "ControlFrame"
|
||||
|
||||
if not controlFrame then
|
||||
return
|
||||
|
|
@ -49,7 +53,7 @@ local function setUpListeners(frameToListen)
|
|||
- fadeSpeed
|
||||
frameToListen.TextTransparency = frameToListen.TextTransparency
|
||||
- fadeSpeed
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@ print "[Mercury]: Loaded corescript 37801172"
|
|||
local ScriptContext = game:GetService "ScriptContext"
|
||||
local CoreGui = game:GetService "CoreGui"
|
||||
|
||||
require "../Modules/DebugConsole"(CoreGui)
|
||||
local Debug = require "../Modules/DebugConsole"
|
||||
Debug(CoreGui)
|
||||
|
||||
-- Creates all neccessary scripts for the gui on initial load, everything except build tools
|
||||
-- Please note that these are loaded in a specific order to diminish errors/perceived load time by user
|
||||
|
|
@ -24,7 +25,10 @@ local function waitForChild(instance, name)
|
|||
end
|
||||
|
||||
waitForChild(CoreGui, "RobloxGui")
|
||||
local screenGui = CoreGui:FindFirstChild "RobloxGui"
|
||||
local screenGui = CoreGui:FindFirstChild "RobloxGui" :: ScreenGui & {
|
||||
Backpack: Frame,
|
||||
CurrentLoadout: Frame,
|
||||
}
|
||||
|
||||
local scripts = {
|
||||
[36868950] = "CoreScripts/ToolTip", -- ToolTipper (creates tool tips for gui)
|
||||
|
|
@ -40,25 +44,8 @@ for id, path in pairs(scripts) do
|
|||
ScriptContext:AddCoreScript(id, screenGui, path)
|
||||
end
|
||||
|
||||
if screenGui.AbsoluteSize.Y >= 600 then
|
||||
-- New Player List
|
||||
ScriptContext:AddCoreScript(
|
||||
48488235,
|
||||
screenGui,
|
||||
"CoreScripts/PlayerListScript"
|
||||
)
|
||||
else
|
||||
delay(5, function()
|
||||
if screenGui.AbsoluteSize.Y >= 600 then
|
||||
-- New Player List
|
||||
ScriptContext:AddCoreScript(
|
||||
48488235,
|
||||
screenGui,
|
||||
"CoreScripts/PlayerListScript"
|
||||
)
|
||||
end
|
||||
end)
|
||||
end
|
||||
-- New Player List
|
||||
ScriptContext:AddCoreScript(48488235, screenGui, "CoreScripts/PlayerListScript")
|
||||
|
||||
-- Backpack Builder, creates most of the backpack gui
|
||||
ScriptContext:AddCoreScript(
|
||||
|
|
@ -69,7 +56,7 @@ ScriptContext:AddCoreScript(
|
|||
|
||||
waitForChild(screenGui, "CurrentLoadout")
|
||||
waitForChild(screenGui, "Backpack")
|
||||
local Backpack = screenGui.Backpack
|
||||
local Backpack = screenGui.Backpack :: Frame
|
||||
|
||||
-- Manager handles all big backpack state changes, other scripts subscribe to this and do things accordingly
|
||||
ScriptContext:AddCoreScript(
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
--!strict
|
||||
-- CoreGui.RobloxGui.CoreScripts/MainBotChatScript
|
||||
print "[Mercury]: Loaded corescript 39250920"
|
||||
|
||||
|
|
@ -6,6 +7,7 @@ local New = News.New
|
|||
local Hydrate = News.Hydrate
|
||||
|
||||
local InsertService = game:GetService "InsertService"
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local function waitForProperty(instance, name)
|
||||
while not instance[name] do
|
||||
|
|
@ -173,11 +175,13 @@ local function createMessageDialog()
|
|||
}
|
||||
end
|
||||
|
||||
local function showMessage(msg, size)
|
||||
local function showMessage(msg: string, size: number)
|
||||
Hydrate(messageDialog) {
|
||||
Size = UDim2.new(0, size, 0, 40),
|
||||
Position = UDim2.new(0.5, -size / 2, 0.5, -40),
|
||||
Visible = true,
|
||||
}
|
||||
messageDialog.Text.Text = msg
|
||||
messageDialog.Size = UDim2.new(0, size, 0, 40)
|
||||
messageDialog.Position = UDim2.new(0.5, -size / 2, 0.5, -40)
|
||||
messageDialog.Visible = true
|
||||
wait(2)
|
||||
messageDialog.Visible = false
|
||||
end
|
||||
|
|
@ -243,7 +247,7 @@ local function normalEndDialog()
|
|||
endDialog()
|
||||
end
|
||||
|
||||
local function sanitizeMessage(msg)
|
||||
local function sanitiseMessage(msg)
|
||||
if string.len(msg) == 0 then
|
||||
return "..."
|
||||
end
|
||||
|
|
@ -256,7 +260,7 @@ local function presentDialogChoices(talkingPart, dialogChoices)
|
|||
end
|
||||
|
||||
currentConversationPartner = talkingPart
|
||||
local sortedDialogChoices = {}
|
||||
local sortedDialogChoices: { DialogChoice } = {}
|
||||
for _, obj in pairs(dialogChoices) do
|
||||
if obj:IsA "DialogChoice" then
|
||||
table.insert(sortedDialogChoices, obj)
|
||||
|
|
@ -313,7 +317,6 @@ local function renewKillswitch(dialog)
|
|||
end
|
||||
|
||||
currentAbortDialogScript = Hydrate(timeoutScript:Clone()) {
|
||||
|
||||
archivable = false,
|
||||
Disabled = false,
|
||||
Parent = dialog,
|
||||
|
|
@ -323,11 +326,13 @@ end
|
|||
local function selectChoice(choice)
|
||||
renewKillswitch(currentConversationDialog)
|
||||
|
||||
local localPlayer = game.Players.LocalPlayer
|
||||
|
||||
--First hide the Gui
|
||||
mainFrame.Visible = false
|
||||
if choice == lastChoice then
|
||||
game.Chat:Chat(
|
||||
game.Players.LocalPlayer.Character,
|
||||
localPlayer.Character,
|
||||
"Goodbye!",
|
||||
getChatColor(currentTone())
|
||||
)
|
||||
|
|
@ -337,8 +342,8 @@ local function selectChoice(choice)
|
|||
local dialogChoice = choiceMap[choice]
|
||||
|
||||
game.Chat:Chat(
|
||||
game.Players.LocalPlayer.Character,
|
||||
sanitizeMessage(dialogChoice.UserDialog),
|
||||
localPlayer.Character,
|
||||
sanitiseMessage(dialogChoice.UserDialog),
|
||||
getChatColor(currentTone())
|
||||
)
|
||||
wait(1)
|
||||
|
|
@ -348,7 +353,7 @@ local function selectChoice(choice)
|
|||
)
|
||||
game.Chat:Chat(
|
||||
currentConversationPartner,
|
||||
sanitizeMessage(dialogChoice.ResponseDialog),
|
||||
sanitiseMessage(dialogChoice.ResponseDialog),
|
||||
getChatColor(currentTone())
|
||||
)
|
||||
|
||||
|
|
@ -444,7 +449,7 @@ local function doDialog(dialog)
|
|||
local il = Instance.Lock(dialog, player)
|
||||
print("for instance", il)
|
||||
while not il do
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
il = Instance.Lock(dialog, player)
|
||||
print("for instance", il)
|
||||
end
|
||||
|
|
@ -486,7 +491,7 @@ local function checkForLeaveArea()
|
|||
end
|
||||
end
|
||||
|
||||
local function startDialog(dialog)
|
||||
local function startDialog(dialog: Dialog)
|
||||
if dialog.Parent and dialog.Parent:IsA "BasePart" then
|
||||
if
|
||||
player:DistanceFromCharacter(dialog.Parent.Position)
|
||||
|
|
@ -509,7 +514,7 @@ local function startDialog(dialog)
|
|||
end
|
||||
end
|
||||
|
||||
local function removeDialog(dialog)
|
||||
local function removeDialog(dialog: Dialog)
|
||||
if dialogMap[dialog] then
|
||||
dialogMap[dialog]:Remove()
|
||||
dialogMap[dialog] = nil
|
||||
|
|
@ -520,7 +525,7 @@ local function removeDialog(dialog)
|
|||
end
|
||||
end
|
||||
|
||||
local function addDialog(dialog)
|
||||
local function addDialog(dialog: Dialog)
|
||||
if dialog.Parent then
|
||||
if dialog.Parent:IsA "BasePart" then
|
||||
local chatGui = Hydrate(chatNotificationGui:Clone()) {
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ local Hydrate = News.Hydrate
|
|||
|
||||
local ContentProvider = game:GetService "ContentProvider"
|
||||
local InsertService = game:GetService "InsertService"
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local RbxGui = {}
|
||||
|
||||
|
|
@ -111,7 +112,13 @@ local function CreateButtons(frame, buttons, yPos, ySize)
|
|||
end
|
||||
end
|
||||
|
||||
local function setSliderPos(newAbsPosX, slider, sliderPosition, bar, steps)
|
||||
local function setSliderPos(
|
||||
newAbsPosX: number,
|
||||
slider: ImageButton,
|
||||
sliderPosition: IntValue,
|
||||
bar,
|
||||
steps: number
|
||||
)
|
||||
local newStep = steps - 1 --otherwise we really get one more step than we want
|
||||
local relativePosX = math.min(
|
||||
1,
|
||||
|
|
@ -245,7 +252,7 @@ function RbxGui.CreateStyledMessageDialog(title, message, style, buttons)
|
|||
end
|
||||
|
||||
local scrollMouseCount
|
||||
function RbxGui.CreateDropDownMenu(items, onSelect, forRoblox)
|
||||
function RbxGui.CreateDropDownMenu(items, onSelect, forRoblox: boolean?)
|
||||
local width = UDim.new(0, 100)
|
||||
local height = UDim.new(0, 32)
|
||||
|
||||
|
|
@ -342,7 +349,7 @@ function RbxGui.CreateDropDownMenu(items, onSelect, forRoblox)
|
|||
local scrollDownButton
|
||||
scrollMouseCount = 0
|
||||
|
||||
local setZIndex = function(baseZIndex)
|
||||
local function setZIndex(baseZIndex: number)
|
||||
droppedDownMenu.ZIndex = baseZIndex + 1
|
||||
if scrollUpButton then
|
||||
scrollUpButton.ZIndex = baseZIndex + 3
|
||||
|
|
@ -686,11 +693,12 @@ function RbxGui.GetFontHeight(font, fontSize)
|
|||
end
|
||||
end
|
||||
|
||||
local function layoutGuiObjectsHelper(frame, guiObjects, settingsTable)
|
||||
local function layoutGuiObjectsHelper(frame: Frame, guiObjects, settingsTable)
|
||||
local totalPixels = frame.AbsoluteSize.Y
|
||||
local pixelsRemaining = frame.AbsoluteSize.Y
|
||||
for _, child in ipairs(guiObjects) do
|
||||
if child:IsA "TextLabel" or child:IsA "TextButton" then
|
||||
for _, ch in ipairs(guiObjects) do
|
||||
if ch:IsA "TextLabel" or ch:IsA "TextButton" then
|
||||
local child = ch :: TextLabel & TextButton -- luau moment
|
||||
local isLabel = child:IsA "TextLabel"
|
||||
if isLabel then
|
||||
pixelsRemaining = pixelsRemaining
|
||||
|
|
@ -712,7 +720,10 @@ local function layoutGuiObjectsHelper(frame, guiObjects, settingsTable)
|
|||
pixelsRemaining
|
||||
)
|
||||
|
||||
if child.TextFits and child.TextBounds.Y < pixelsRemaining then
|
||||
if
|
||||
child.TextFits
|
||||
and (child.TextBounds.Y :: number) < pixelsRemaining
|
||||
then
|
||||
child.Visible = true
|
||||
if isLabel then
|
||||
child.Size = UDim2.new(
|
||||
|
|
@ -752,7 +763,8 @@ local function layoutGuiObjectsHelper(frame, guiObjects, settingsTable)
|
|||
pixelsRemaining = -1
|
||||
end
|
||||
else
|
||||
--GuiObject
|
||||
local child = ch :: GuiObject
|
||||
-- GuiObject
|
||||
child.Position = UDim2.new(
|
||||
child.Position.X.Scale,
|
||||
child.Position.X.Offset,
|
||||
|
|
@ -804,7 +816,7 @@ function RbxGui.LayoutGuiObjects(frame, guiObjects, settingsTable)
|
|||
end
|
||||
|
||||
local recalculate = function()
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
layoutGuiObjectsHelper(wrapperFrame, guiObjects, settingsTable)
|
||||
end
|
||||
|
||||
|
|
@ -819,7 +831,7 @@ function RbxGui.LayoutGuiObjects(frame, guiObjects, settingsTable)
|
|||
layoutGuiObjectsHelper(wrapperFrame, guiObjects, settingsTable)
|
||||
end
|
||||
|
||||
function RbxGui.CreateSlider(steps, width, position)
|
||||
function RbxGui.CreateSlider(steps: number, width: number, position)
|
||||
local sliderGui = New "Frame" {
|
||||
Size = UDim2.new(1, 0, 1, 0),
|
||||
BackgroundTransparency = 1,
|
||||
|
|
@ -937,8 +949,8 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
local lowY
|
||||
local highY
|
||||
|
||||
local dragCon
|
||||
local upCon
|
||||
local dragCon: RBXScriptConnection?
|
||||
local upCon: RBXScriptConnection?
|
||||
|
||||
local internalChange = false
|
||||
|
||||
|
|
@ -1060,18 +1072,20 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
Size = UDim2.new(0, 10, 0, 0),
|
||||
ZIndex = 2,
|
||||
BackgroundTransparency = 0.5,
|
||||
Parent = scrollbar,
|
||||
}
|
||||
end
|
||||
|
||||
local scrollNub = Hydrate(nub()) {
|
||||
Position = UDim2.new(0.5, -5, 0.5, 0),
|
||||
Parent = scrollbar,
|
||||
}
|
||||
local newNub = Hydrate(nub()) {
|
||||
Position = UDim2.new(0.5, -5, 0.5, -2),
|
||||
Parent = scrollbar,
|
||||
}
|
||||
local lastNub = Hydrate(nub()) {
|
||||
Position = UDim2.new(0.5, -5, 0.5, 2),
|
||||
Parent = scrollbar,
|
||||
}
|
||||
|
||||
scrollbar.MouseEnter:connect(function()
|
||||
|
|
@ -1148,7 +1162,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
return (oldPos ~= scrollbar.Position)
|
||||
end
|
||||
|
||||
local function drillDownSetHighLow(instance)
|
||||
local function drillDownSetHighLow(instance: GuiObject)
|
||||
if not instance or not instance:IsA "GuiObject" then
|
||||
return
|
||||
end
|
||||
|
|
@ -1176,7 +1190,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
end
|
||||
local children = instance:GetChildren()
|
||||
for i = 1, #children do
|
||||
drillDownSetHighLow(children[i])
|
||||
drillDownSetHighLow(children[i] :: GuiObject)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -1184,7 +1198,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
local firstChildren = scrollingFrame:GetChildren()
|
||||
|
||||
for i = 1, #firstChildren do
|
||||
drillDownSetHighLow(firstChildren[i])
|
||||
drillDownSetHighLow(firstChildren[i]) -- y no type annotation here, luau?
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -1352,24 +1366,27 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
upCon = mouseDrag.MouseButton1Up:connect(function()
|
||||
scrollStamp = tick()
|
||||
mouseDrag.Parent = nil
|
||||
upCon:disconnect()
|
||||
if upCon then
|
||||
-- what's upcon
|
||||
-- nothing much, you?
|
||||
upCon:disconnect()
|
||||
end
|
||||
end)
|
||||
mouseDrag.Parent = getScreenGuiAncestor(scrollbar)
|
||||
doScrollUp()
|
||||
wait(0.2)
|
||||
local t = tick()
|
||||
local w = 0.1
|
||||
while scrollStamp == current do
|
||||
doScrollUp()
|
||||
if not scrollUpButton.Active then
|
||||
break
|
||||
end
|
||||
if tick() - t > 5 then
|
||||
w = 0
|
||||
elseif tick() - t > 5 then
|
||||
wait()
|
||||
elseif tick() - t > 2 then
|
||||
w = 0.06
|
||||
wait(0.06)
|
||||
else
|
||||
wait(0.1)
|
||||
end
|
||||
wait(w)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -1462,7 +1479,13 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
scrollbar.MouseButton1Up:connect(scrollTick)
|
||||
|
||||
-- local function heightCheck(instance)
|
||||
-- if (highY and (instance.AbsolutePosition.Y + instance.AbsoluteSize.Y) > highY) or not highY then
|
||||
-- if
|
||||
-- (
|
||||
-- highY
|
||||
-- and (instance.AbsolutePosition.Y + instance.AbsoluteSize.Y)
|
||||
-- > highY
|
||||
-- ) or not highY
|
||||
-- then
|
||||
-- highY = instance.AbsolutePosition.Y + instance.AbsoluteSize.Y
|
||||
-- end
|
||||
-- setSliderSizeAndPosition()
|
||||
|
|
@ -1489,7 +1512,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
end
|
||||
|
||||
if prop == "Size" or prop == "Position" then
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
highLowRecheck()
|
||||
end
|
||||
end
|
||||
|
|
@ -1500,7 +1523,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
end
|
||||
|
||||
if instance.Visible then
|
||||
wait() -- wait a heartbeat for sizes to reconfig
|
||||
RunService.Heartbeat:wait() -- wait a heartbeat for sizes to reconfig
|
||||
highLowRecheck()
|
||||
end
|
||||
|
||||
|
|
@ -1519,7 +1542,7 @@ function RbxGui.CreateTrueScrollingFrame()
|
|||
descendantsChangeConMap[instance]:disconnect()
|
||||
descendantsChangeConMap[instance] = nil
|
||||
end
|
||||
wait() -- wait a heartbeat for sizes to reconfig
|
||||
RunService.Heartbeat:wait() -- wait a heartbeat for sizes to reconfig
|
||||
highLowRecheck()
|
||||
end)
|
||||
|
||||
|
|
@ -1930,7 +1953,7 @@ function RbxGui.CreateScrollingFrame(orderList, scrollStyle)
|
|||
return
|
||||
end
|
||||
reentrancyGuard = true
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
local success, err
|
||||
if style == "grid" then
|
||||
success, err = pcall(function()
|
||||
|
|
@ -2136,7 +2159,11 @@ function RbxGui.CreateScrollingFrame(orderList, scrollStyle)
|
|||
return frame, scrollUpButton, scrollDownButton, recalculate, scrollbar
|
||||
end
|
||||
|
||||
local function binaryGrow(min, max, fits)
|
||||
local function binaryGrow(
|
||||
min: number,
|
||||
max: number,
|
||||
fits: (number) -> boolean
|
||||
): number
|
||||
if min > max then
|
||||
return min
|
||||
end
|
||||
|
|
@ -2147,17 +2174,21 @@ local function binaryGrow(min, max, fits)
|
|||
if fits(mid) and (biggestLegal == nil or biggestLegal < mid) then
|
||||
biggestLegal = mid
|
||||
|
||||
--Try growing
|
||||
-- Try growing
|
||||
min = mid + 1
|
||||
else
|
||||
--Doesn't fit, shrink
|
||||
-- Doesn't fit, shrink
|
||||
max = mid - 1
|
||||
end
|
||||
end
|
||||
return biggestLegal
|
||||
end
|
||||
|
||||
local function binaryShrink(min, max, fits)
|
||||
local function binaryShrink(
|
||||
min: number,
|
||||
max: number,
|
||||
fits: (number) -> boolean
|
||||
): number
|
||||
if min > max then
|
||||
return min
|
||||
end
|
||||
|
|
@ -2168,27 +2199,28 @@ local function binaryShrink(min, max, fits)
|
|||
if fits(mid) and (smallestLegal == nil or smallestLegal > mid) then
|
||||
smallestLegal = mid
|
||||
|
||||
--It fits, shrink
|
||||
-- It fits, shrink
|
||||
max = mid - 1
|
||||
else
|
||||
--Doesn't fit, grow
|
||||
-- Doesn't fit, grow
|
||||
min = mid + 1
|
||||
end
|
||||
end
|
||||
return smallestLegal
|
||||
end
|
||||
|
||||
local function getGuiOwner(instance)
|
||||
while instance ~= nil do
|
||||
if instance:IsA "ScreenGui" or instance:IsA "BillboardGui" then
|
||||
return instance
|
||||
local function hasGuiOwner(instance: Instance)
|
||||
local obj: Instance? = instance
|
||||
while obj do
|
||||
if obj:IsA "ScreenGui" or obj:IsA "BillboardGui" then
|
||||
return true
|
||||
end
|
||||
instance = instance.Parent
|
||||
obj = obj.Parent
|
||||
end
|
||||
return nil
|
||||
return false
|
||||
end
|
||||
|
||||
function RbxGui.AutoTruncateTextObject(textLabel)
|
||||
function RbxGui.AutoTruncateTextObject(textLabel: TextLabel)
|
||||
local text = textLabel.Text
|
||||
|
||||
local fullLabel = Hydrate(textLabel:Clone()) {
|
||||
|
|
@ -2204,11 +2236,11 @@ function RbxGui.AutoTruncateTextObject(textLabel)
|
|||
}
|
||||
|
||||
local shortText
|
||||
local mouseEnterConnection
|
||||
local mouseLeaveConnection
|
||||
local mouseEnterConnection: RBXScriptConnection?
|
||||
local mouseLeaveConnection: RBXScriptConnection?
|
||||
|
||||
local checkForResize = function()
|
||||
if getGuiOwner(textLabel) == nil then
|
||||
local function checkForResize()
|
||||
if not hasGuiOwner(textLabel) then
|
||||
return
|
||||
end
|
||||
textLabel.Text = text
|
||||
|
|
@ -2228,11 +2260,8 @@ function RbxGui.AutoTruncateTextObject(textLabel)
|
|||
|
||||
--Shrink the text
|
||||
local textSize = binaryGrow(0, len, function(pos)
|
||||
if pos == 0 then
|
||||
textLabel.Text = "~"
|
||||
else
|
||||
textLabel.Text = `{string.sub(text, 1, pos)}~`
|
||||
end
|
||||
textLabel.Text = pos == 0 and "~"
|
||||
or string.sub(text, 1, pos) .. "~"
|
||||
return textLabel.TextFits
|
||||
end)
|
||||
shortText = `{string.sub(text, 1, textSize)}~`
|
||||
|
|
@ -2290,8 +2319,8 @@ function RbxGui.AutoTruncateTextObject(textLabel)
|
|||
end
|
||||
|
||||
local function TransitionTutorialPages(
|
||||
fromPage: Instance?,
|
||||
toPage: Instance?,
|
||||
fromPage: GuiObject?,
|
||||
toPage: GuiObject?,
|
||||
transitionFrame: Frame,
|
||||
currentPageValue: ObjectValue
|
||||
)
|
||||
|
|
@ -2445,8 +2474,8 @@ end
|
|||
local function CreateBasicTutorialPage(
|
||||
name: string,
|
||||
handleResize: (number, number) -> (),
|
||||
skipTutorial,
|
||||
giveDoneButton
|
||||
skipTutorial: () -> (),
|
||||
giveDoneButton: boolean? -- idk
|
||||
)
|
||||
local frame = New "Frame" {
|
||||
Name = "TutorialPage",
|
||||
|
|
@ -2543,7 +2572,7 @@ local function CreateBasicTutorialPage(
|
|||
innerFrame.Size = giveDoneButton and UDim2.new(1, 0, 1, -75)
|
||||
or UDim2.new(1, 0, 1, -22)
|
||||
|
||||
local parentConnection
|
||||
local parentConnection: RBXScriptConnection?
|
||||
|
||||
local function basicHandleResize()
|
||||
if frame.Visible and frame.Parent then
|
||||
|
|
@ -2557,7 +2586,7 @@ local function CreateBasicTutorialPage(
|
|||
|
||||
frame.Changed:connect(function(prop)
|
||||
if prop == "Parent" then
|
||||
if parentConnection ~= nil then
|
||||
if parentConnection then
|
||||
parentConnection:disconnect()
|
||||
parentConnection = nil
|
||||
end
|
||||
|
|
@ -2565,7 +2594,7 @@ local function CreateBasicTutorialPage(
|
|||
parentConnection = frame.Parent.Changed:connect(
|
||||
function(parentProp)
|
||||
if parentProp == "AbsoluteSize" then
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
basicHandleResize()
|
||||
end
|
||||
end
|
||||
|
|
@ -2582,7 +2611,7 @@ local function CreateBasicTutorialPage(
|
|||
return frame, innerFrame
|
||||
end
|
||||
|
||||
RbxGui.CreateTextTutorialPage = function(name, text, skipTutorialFunc)
|
||||
function RbxGui.CreateTextTutorialPage(name, text, skipTutorial)
|
||||
local frame
|
||||
local contentFrame
|
||||
|
||||
|
|
@ -2608,7 +2637,7 @@ RbxGui.CreateTextTutorialPage = function(name, text, skipTutorialFunc)
|
|||
end
|
||||
|
||||
frame, contentFrame =
|
||||
CreateBasicTutorialPage(name, handleResize, skipTutorialFunc)
|
||||
CreateBasicTutorialPage(name, handleResize, skipTutorial)
|
||||
textLabel.Parent = contentFrame
|
||||
|
||||
return frame
|
||||
|
|
@ -2617,9 +2646,9 @@ end
|
|||
RbxGui.CreateImageTutorialPage = function(
|
||||
name,
|
||||
imageAsset,
|
||||
x,
|
||||
y,
|
||||
skipTutorialFunc,
|
||||
x: number,
|
||||
y: number,
|
||||
skipTutorial: () -> (),
|
||||
giveDoneButton
|
||||
)
|
||||
local frame
|
||||
|
|
@ -2663,7 +2692,7 @@ RbxGui.CreateImageTutorialPage = function(
|
|||
frame, contentFrame = CreateBasicTutorialPage(
|
||||
name,
|
||||
handleResize,
|
||||
skipTutorialFunc,
|
||||
skipTutorial,
|
||||
giveDoneButton
|
||||
)
|
||||
imageLabel.Parent = contentFrame
|
||||
|
|
@ -2671,7 +2700,12 @@ RbxGui.CreateImageTutorialPage = function(
|
|||
return frame
|
||||
end
|
||||
|
||||
RbxGui.AddTutorialPage = function(tutorial, tutorialPage)
|
||||
type TutorialPage = GuiObject & {
|
||||
NextButton: TextButton,
|
||||
PrevButton: TextButton,
|
||||
}
|
||||
|
||||
RbxGui.AddTutorialPage = function(tutorial, tutorialPage: TutorialPage)
|
||||
local transitionFrame = tutorial.TransitionFrame
|
||||
local currentPageValue = tutorial.CurrentTutorialPage
|
||||
|
||||
|
|
@ -2683,7 +2717,7 @@ RbxGui.AddTutorialPage = function(tutorial, tutorialPage)
|
|||
local children = tutorial.Pages:GetChildren()
|
||||
if children and #children > 0 then
|
||||
tutorialPage.Name = "TutorialPage" .. (#children + 1)
|
||||
local previousPage = children[#children]
|
||||
local previousPage: TutorialPage = children[#children]
|
||||
if not previousPage:IsA "GuiObject" then
|
||||
error "All elements under Pages must be GuiObjects"
|
||||
end
|
||||
|
|
@ -3066,7 +3100,7 @@ RbxGui.CreateSetPanel = function(
|
|||
end
|
||||
|
||||
local function handleResize()
|
||||
wait() -- neccessary to insure heartbeat happened
|
||||
RunService.Heartbeat:wait() -- neccessary to insure heartbeat happened
|
||||
|
||||
local itemPreview = setGui.SetPanel.ItemPreview
|
||||
|
||||
|
|
@ -3084,8 +3118,15 @@ RbxGui.CreateSetPanel = function(
|
|||
)
|
||||
end
|
||||
|
||||
local function buttonImage()
|
||||
return New "ImageLabel" {
|
||||
Image = "",
|
||||
BackgroundTransparency = 1,
|
||||
}
|
||||
end
|
||||
|
||||
local function makeInsertAssetButton()
|
||||
local insertAssetButtonExample = New "Frame" {
|
||||
return New "Frame" {
|
||||
Name = "InsertAssetButtonExample",
|
||||
Position = UDim2.new(0, 128, 0, 64),
|
||||
Size = UDim2.new(0, 64, 0, 64),
|
||||
|
|
@ -3100,39 +3141,28 @@ RbxGui.CreateSetPanel = function(
|
|||
Name = "AssetName",
|
||||
Value = "",
|
||||
},
|
||||
New "TextButton" {
|
||||
Name = "Button",
|
||||
Text = "",
|
||||
Style = Enum.ButtonStyle.RobloxButton,
|
||||
Position = UDim2.new(0.025, 0, 0.025, 0),
|
||||
Size = UDim2.new(0.95, 0, 0.95, 0),
|
||||
ZIndex = 6,
|
||||
Hydrate(buttonImage()) {
|
||||
Name = "ButtonImage",
|
||||
Position = UDim2.new(0, -7, 0, -7),
|
||||
Size = UDim2.new(1, 14, 1, 14),
|
||||
ZIndex = 7,
|
||||
},
|
||||
},
|
||||
Hydrate(buttonImage()) {
|
||||
Name = "ConfigIcon",
|
||||
Visible = false,
|
||||
Position = UDim2.new(1, -23, 1, -24),
|
||||
Size = UDim2.new(0, 16, 0, 16),
|
||||
ZIndex = 6,
|
||||
},
|
||||
}
|
||||
|
||||
local button = New "TextButton" {
|
||||
Name = "Button",
|
||||
Text = "",
|
||||
Style = Enum.ButtonStyle.RobloxButton,
|
||||
Position = UDim2.new(0.025, 0, 0.025, 0),
|
||||
Size = UDim2.new(0.95, 0, 0.95, 0),
|
||||
ZIndex = 6,
|
||||
Parent = insertAssetButtonExample,
|
||||
}
|
||||
|
||||
local buttonImage = New "ImageLabel" {
|
||||
Name = "ButtonImage",
|
||||
Image = "",
|
||||
Position = UDim2.new(0, -7, 0, -7),
|
||||
Size = UDim2.new(1, 14, 1, 14),
|
||||
BackgroundTransparency = 1,
|
||||
ZIndex = 7,
|
||||
Parent = button,
|
||||
}
|
||||
|
||||
Hydrate(buttonImage:Clone()) {
|
||||
Name = "ConfigIcon",
|
||||
Visible = false,
|
||||
Position = UDim2.new(1, -23, 1, -24),
|
||||
Size = UDim2.new(0, 16, 0, 16),
|
||||
Image = "",
|
||||
ZIndex = 6,
|
||||
Parent = insertAssetButtonExample,
|
||||
}
|
||||
|
||||
return insertAssetButtonExample
|
||||
end
|
||||
|
||||
local function showLargePreview(insertButton)
|
||||
|
|
@ -3161,9 +3191,9 @@ RbxGui.CreateSetPanel = function(
|
|||
end
|
||||
end
|
||||
|
||||
local function createTerrainTypeButton(name, parent)
|
||||
local function createTerrainTypeButton(name: string, parent: Frame)
|
||||
local dropDownTextButton = New "TextButton" {
|
||||
Name = `{name}Button`,
|
||||
Name = name .. "Button",
|
||||
Font = Enum.Font.ArialBold,
|
||||
FontSize = Enum.FontSize.Size14,
|
||||
BorderSizePixel = 0,
|
||||
|
|
@ -3201,7 +3231,7 @@ RbxGui.CreateSetPanel = function(
|
|||
return dropDownTextButton
|
||||
end
|
||||
|
||||
local function createTerrainDropDownMenu(zIndex)
|
||||
local function createTerrainDropDownMenu(zIndex: number)
|
||||
local dropDown = New "Frame" {
|
||||
Name = "TerrainDropDown",
|
||||
BackgroundColor3 = Color3.new(0, 0, 0),
|
||||
|
|
@ -3231,7 +3261,7 @@ RbxGui.CreateSetPanel = function(
|
|||
end)
|
||||
end
|
||||
|
||||
local function createDropDownMenuButton(parent)
|
||||
local function createDropDownMenuButton(parent: Frame)
|
||||
local dropDownButton = New "ImageButton" {
|
||||
Name = "DropDownButton",
|
||||
Image = "http://banland.xyz/asset?id=67581509",
|
||||
|
|
@ -4002,7 +4032,7 @@ RbxGui.CreateLoadingFrame = function(name, size, position)
|
|||
return loadingFrame, updateLoadingGuiPercent, cancelButtonClicked
|
||||
end
|
||||
|
||||
RbxGui.CreatePluginFrame = function(name, size, position, scrollable, parent)
|
||||
function RbxGui.CreatePluginFrame(name: string, size, position, scrollable, parent)
|
||||
local function createMenuButton(
|
||||
size,
|
||||
position,
|
||||
|
|
@ -4043,6 +4073,15 @@ RbxGui.CreatePluginFrame = function(name, size, position, scrollable, parent)
|
|||
return button
|
||||
end
|
||||
|
||||
local function separatingLineC()
|
||||
return New "Frame" {
|
||||
Name = "SeparatingLine",
|
||||
BackgroundColor3 = Colour3(115, 115, 115),
|
||||
BorderSizePixel = 0,
|
||||
Size = UDim2.new(0, 1, 0, 14),
|
||||
}
|
||||
end
|
||||
|
||||
local dragBar = New "ImageButton" {
|
||||
Name = `{name}DragBar`,
|
||||
BackgroundColor3 = Colour3(39, 39, 39),
|
||||
|
|
@ -4061,7 +4100,14 @@ RbxGui.CreatePluginFrame = function(name, size, position, scrollable, parent)
|
|||
TextXAlignment = Enum.TextXAlignment.Left,
|
||||
BackgroundTransparency = 1,
|
||||
},
|
||||
Hydrate(separatingLineC()) {
|
||||
Position = UDim2.new(1, -18, 0.5, -7),
|
||||
},
|
||||
Hydrate(separatingLineC()) {
|
||||
Position = UDim2.new(1, -35, 0.5, -7),
|
||||
},
|
||||
}
|
||||
|
||||
if size then
|
||||
dragBar.Size = UDim2.new(size.X.Scale, size.X.Offset, 0, 20)
|
||||
+ UDim2.new(0, 20, 0, 0)
|
||||
|
|
@ -4181,20 +4227,6 @@ RbxGui.CreatePluginFrame = function(name, size, position, scrollable, parent)
|
|||
Parent = minimizeFrame,
|
||||
}
|
||||
|
||||
local separatingLine = New "Frame" {
|
||||
Name = "SeparatingLine",
|
||||
BackgroundColor3 = Colour3(115, 115, 115),
|
||||
BorderSizePixel = 0,
|
||||
Position = UDim2.new(1, -18, 0.5, -7),
|
||||
Size = UDim2.new(0, 1, 0, 14),
|
||||
Parent = dragBar,
|
||||
}
|
||||
-- otherSeparatingLine
|
||||
Hydrate(separatingLine:Clone()) {
|
||||
Position = UDim2.new(1, -35, 0.5, -7),
|
||||
Parent = dragBar,
|
||||
}
|
||||
|
||||
local widgetContainer = New "Frame" {
|
||||
Name = "WidgetContainer",
|
||||
BackgroundTransparency = 1,
|
||||
|
|
@ -4208,22 +4240,11 @@ RbxGui.CreatePluginFrame = function(name, size, position, scrollable, parent)
|
|||
widgetContainer.Parent = dragBar
|
||||
|
||||
if size then
|
||||
if scrollable then
|
||||
widgetContainer.Size = size
|
||||
else
|
||||
widgetContainer.Size = UDim2.new(
|
||||
0,
|
||||
dragBar.AbsoluteSize.X,
|
||||
size.Y.Scale,
|
||||
size.Y.Offset
|
||||
)
|
||||
end
|
||||
widgetContainer.Size = scrollable and size
|
||||
or UDim2.new(0, dragBar.AbsoluteSize.X, size.Y.Scale, size.Y.Offset)
|
||||
else
|
||||
if scrollable then
|
||||
widgetContainer.Size = UDim2.new(0, 163, 0, 400)
|
||||
else
|
||||
widgetContainer.Size = UDim2.new(0, dragBar.AbsoluteSize.X, 0, 400)
|
||||
end
|
||||
widgetContainer.Size = scrollable and UDim2.new(0, 163, 0, 400)
|
||||
or UDim2.new(0, dragBar.AbsoluteSize.X, 0, 400)
|
||||
end
|
||||
if position then
|
||||
widgetContainer.Position = position + UDim2.new(0, 0, 0, 20)
|
||||
|
|
|
|||
1948
luau/46295863.luau
1948
luau/46295863.luau
File diff suppressed because it is too large
Load Diff
|
|
@ -1,7 +1,10 @@
|
|||
-- CoreGui.RobloxGui.CoreScripts/PlayerListScript
|
||||
print "[Mercury]: Loaded corescript 48488235"
|
||||
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local New = (require "../Modules/New").New
|
||||
local log = require "../Modules/Logger"
|
||||
|
||||
--------------------
|
||||
-- Super Util
|
||||
|
|
@ -623,43 +626,6 @@ local BigButton = New "ImageButton" {
|
|||
Parent = ScreenGui,
|
||||
}
|
||||
|
||||
local debugFrame = New "Frame" {
|
||||
Name = "debugframe",
|
||||
-- Position = UDim2.new(0, 0, 0, 0),
|
||||
-- Size = UDim2.new(0, 150, 0, 800),--0.99000001
|
||||
-- BackgroundTransparency = 1,
|
||||
BackgroundTransparency = 1,
|
||||
Position = UDim2.new(0.25, 0, 0.300000012, 0),
|
||||
Size = UDim2.new(0.5, 0, 0.370000005, 0),
|
||||
MakeBackgroundGuiObj "http://banland.xyz/asset?id=96506233",
|
||||
}
|
||||
local debugOutput = New "TextLabel" {
|
||||
BackgroundTransparency = 0.8,
|
||||
Position = UDim2.new(0, 0, 0.5, 0),
|
||||
Size = UDim2.new(1, 0, 0.5, 0),
|
||||
Parent = debugFrame,
|
||||
Font = "ArialBold",
|
||||
Text = "--",
|
||||
FontSize = "Size14",
|
||||
TextWrapped = true,
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
TextStrokeColor3 = Color3.new(0, 0, 0),
|
||||
TextStrokeTransparency = 0,
|
||||
TextXAlignment = "Right",
|
||||
TextYAlignment = "Center",
|
||||
}
|
||||
|
||||
--[[
|
||||
simple function to toggle the display of debug output
|
||||
--]]
|
||||
local DebugPrintEnabled = true
|
||||
local function debugprint(str)
|
||||
--print(str)
|
||||
if DebugPrintEnabled then
|
||||
debugOutput.Text = str
|
||||
end
|
||||
end
|
||||
|
||||
--[[
|
||||
obligatory wait for child function
|
||||
@Args:
|
||||
|
|
@ -669,8 +635,8 @@ end
|
|||
--]]
|
||||
local function WaitForChild(parent, child)
|
||||
while not parent:FindFirstChild(child) do
|
||||
wait()
|
||||
debugprint(` child {parent.Name} waiting for {child}`)
|
||||
RunService.Heartbeat:wait()
|
||||
log(` child {parent.Name} waiting for {child}`)
|
||||
end
|
||||
return parent[child]
|
||||
end
|
||||
|
|
@ -833,7 +799,7 @@ local function TweenProperty(obj, propName, inita: number, enda: number, length)
|
|||
while tick() - startTime < length do
|
||||
obj[propName] = ((enda - inita) * ((tick() - startTime) / length))
|
||||
+ inita
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
obj[propName] = enda
|
||||
end
|
||||
|
|
@ -860,13 +826,13 @@ local function WaitForClick(frameParent, polledFunction, exitFunction)
|
|||
if connection2 then
|
||||
connection2:disconnect()
|
||||
end
|
||||
-- debugprint "mouse up!"
|
||||
-- log "mouse up!"
|
||||
end)
|
||||
connection2 = BigButton.MouseMoved:connect(function(nx, ny)
|
||||
polledFunction(nx, ny)
|
||||
end)
|
||||
|
||||
-- debugprint "waiting for click!"
|
||||
-- log "waiting for click!"
|
||||
BigButton.Visible = true
|
||||
BigButton.Active = true
|
||||
BigButton.Parent = frameParent
|
||||
|
|
@ -876,7 +842,7 @@ local function WaitForClick(frameParent, polledFunction, exitFunction)
|
|||
BigButton.Visible = false
|
||||
connection:disconnect()
|
||||
connection2:disconnect()
|
||||
debugprint "forced out of wait for click"
|
||||
log "forced out of wait for click"
|
||||
end
|
||||
end)
|
||||
WaitForClickLock = false
|
||||
|
|
@ -971,7 +937,7 @@ local function OnPrivilegeLevelSelect(
|
|||
MemberButton,
|
||||
AdminButton
|
||||
)
|
||||
debugprint "setting privilege level"
|
||||
log "setting privilege level"
|
||||
SetPrivilegeRank(player, nlevel)
|
||||
HighlightMyRank(
|
||||
player,
|
||||
|
|
@ -1018,7 +984,7 @@ local function OnSubmitAbuse()
|
|||
then
|
||||
CalmingAbuseBox.Parent = ReportAbuseShield
|
||||
else
|
||||
debugprint "opening abuse box"
|
||||
log "opening abuse box"
|
||||
NormalAbuseBox.Parent = ReportAbuseShield
|
||||
end
|
||||
else
|
||||
|
|
@ -1050,7 +1016,7 @@ end
|
|||
opens the abuse dialog, initialises text to display selectedplayer
|
||||
--]]
|
||||
local function OpenAbuseDialog()
|
||||
debugprint "adding report dialog"
|
||||
log "adding report dialog"
|
||||
AbusePlayerLabel.Text = SelectedPlayer.Name
|
||||
--AbuseDescriptionBox.Text = ""
|
||||
PopUpPanel:TweenPosition(
|
||||
|
|
@ -1304,7 +1270,7 @@ local function UpdateHeaderNameSize()
|
|||
tHeader.FontSize = FONT_SIZES[fSize]
|
||||
Delay(0.2, function()
|
||||
while tHeader.TextBounds.x == 0 do
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
while tHeader.TextBounds.x - NormalBounds.X.Offset > 1 do
|
||||
fSize -= 1
|
||||
|
|
@ -1687,8 +1653,8 @@ end
|
|||
--]]
|
||||
local function BaseUpdate()
|
||||
while BaseUpdateLock do
|
||||
debugprint "in baseupdate lock"
|
||||
wait()
|
||||
log "in baseupdate lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
BaseUpdateLock = true
|
||||
-- print "baseupdate"
|
||||
|
|
@ -1720,7 +1686,7 @@ local function BaseUpdate()
|
|||
UpdateScrollPosition()
|
||||
|
||||
UpdateScrollBarVisibility()
|
||||
-- debugprint "EndBaseUpdate"
|
||||
-- log "EndBaseUpdate"
|
||||
BaseUpdateLock = false
|
||||
end
|
||||
|
||||
|
|
@ -1732,10 +1698,10 @@ RecreateScoreColumns = function(ptable)
|
|||
end
|
||||
local nscoretxt = panel:FindFirstChild("PlayerScore"):Clone()
|
||||
local thisScore
|
||||
--here lies the resting place of a once great and terrible bug
|
||||
--may its treachery never be forgotten, lest its survivors fall for it again
|
||||
--RIP the leaderstat bug, oct 2012-nov 2012
|
||||
wait()
|
||||
-- here lies the resting place of a once great and terrible bug
|
||||
-- may its treachery never be forgotten, lest its survivors fall for it again
|
||||
-- RIP the leaderstat bug, oct 2012-nov 2012
|
||||
RunService.Heartbeat:wait()
|
||||
if
|
||||
entry.Player:FindFirstChild "leaderstats"
|
||||
and entry.Player.leaderstats:FindFirstChild(scoreval.Name)
|
||||
|
|
@ -1754,7 +1720,7 @@ RecreateScoreColumns = function(ptable)
|
|||
nscoretxt.Name = scoreval.Name
|
||||
nscoretxt.Text = tostring(GetScoreValue(thisScore))
|
||||
if scoreval.Name == ScoreNames[1]["Name"] then
|
||||
debugprint "changing score"
|
||||
log "changing score"
|
||||
entry.Score = GetScoreValue(thisScore)
|
||||
if entry.Player == LocalPlayer then
|
||||
HeaderScore.Text = tostring(GetScoreValue(thisScore))
|
||||
|
|
@ -1778,8 +1744,8 @@ RecreateScoreColumns = function(ptable)
|
|||
end
|
||||
|
||||
while AddingStatLock do
|
||||
debugprint "In Adding Stat Lock2"
|
||||
wait()
|
||||
log "In Adding Stat Lock2"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingStatLock = true
|
||||
local Xoffset = 5 --15 --current offset from Right
|
||||
|
|
@ -1799,7 +1765,7 @@ RecreateScoreColumns = function(ptable)
|
|||
-- make an entry for this object
|
||||
local nentry = MakeScoreEntry(entry, scoreval, panel)
|
||||
if nentry then
|
||||
debugprint(`adding {nentry.Name} to {entry.Player.Name}`)
|
||||
log(`adding {nentry.Name} to {entry.Player.Name}`)
|
||||
nentry.Parent = panel
|
||||
-- add score to team
|
||||
if
|
||||
|
|
@ -2033,8 +1999,8 @@ end
|
|||
local function StatAdded(nchild, playerEntry)
|
||||
-- dont re - add a leaderstat I alreday have
|
||||
while AddingStatLock do
|
||||
debugprint "in stat added function lock"
|
||||
wait()
|
||||
log "in stat added function lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingStatLock = true
|
||||
if
|
||||
|
|
@ -2109,12 +2075,12 @@ end
|
|||
--]]
|
||||
local function StatRemoved(nchild, playerEntry)
|
||||
while AddingStatLock do
|
||||
debugprint "In Adding Stat Lock1"
|
||||
wait()
|
||||
log "In Adding Stat Lock1"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingStatLock = true
|
||||
if playerEntry.Frame:FindFirstChild(nchild.Name) then
|
||||
debugprint "Destroyed frame!"
|
||||
log "Destroyed frame!"
|
||||
playerEntry.Frame[nchild.Name].Parent = nil
|
||||
end
|
||||
if not DoesStatExist(nchild.Name, playerEntry.Player) then
|
||||
|
|
@ -2268,7 +2234,7 @@ local function InitMovingPanel(entry, player)
|
|||
|
||||
local nextIndex = 2
|
||||
local friendStatus = GetFriendStatus(player)
|
||||
debugprint(tostring(friendStatus))
|
||||
log(tostring(friendStatus))
|
||||
local showRankMenu = false
|
||||
-- IsPersonalServer
|
||||
-- and LocalPlayer.PersonalServerRank >= PrivilegeLevel.Admin
|
||||
|
|
@ -2391,7 +2357,7 @@ local function InitMovingPanel(entry, player)
|
|||
0,
|
||||
myFrame.AbsolutePosition.Y
|
||||
)
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
end)
|
||||
end
|
||||
|
|
@ -2434,9 +2400,7 @@ local function StartDrag(entry, startx, starty)
|
|||
startY = AbsoluteToPercent(nx, ny).Y
|
||||
end
|
||||
local nowY = AbsoluteToPercent(nx, ny).Y
|
||||
debugprint(
|
||||
`drag dist {Vector2.new(startx - nx, starty - ny).magnitude}`
|
||||
)
|
||||
log(`drag dist {Vector2.new(startx - nx, starty - ny).magnitude}`)
|
||||
if
|
||||
Vector2.new(startx - nx, starty - ny).magnitude
|
||||
> MOUSE_DRAG_DISTANCE
|
||||
|
|
@ -2462,9 +2426,9 @@ end
|
|||
local function StartMinimizeDrag()
|
||||
Delay(0, function()
|
||||
local startTime = tick()
|
||||
debugprint "Got Click2"
|
||||
log "Got Click2"
|
||||
local function dragExit()
|
||||
-- debugprint "undone click2"
|
||||
-- log "undone click2"
|
||||
if tick() - startTime < 0.25 then --was click
|
||||
ToggleMinimize()
|
||||
else --was drag
|
||||
|
|
@ -2660,8 +2624,8 @@ end
|
|||
--]]
|
||||
local function LeaderstatsRemoved(_, playerEntry)
|
||||
while AddingFrameLock do
|
||||
debugprint(`waiting to insert {playerEntry.Player.Name}`)
|
||||
wait()
|
||||
log(`waiting to insert {playerEntry.Player.Name}`)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
RemoveAllStats(playerEntry)
|
||||
|
|
@ -2685,8 +2649,8 @@ end
|
|||
|
||||
local function RemoveNeutralTeam()
|
||||
while NeutralTeamLock do
|
||||
debugprint "in neutral team lock"
|
||||
wait()
|
||||
log "in neutral team lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
NeutralTeamLock = true
|
||||
NeutralTeam.Frame:Destroy()
|
||||
|
|
@ -2756,8 +2720,8 @@ end
|
|||
--]]
|
||||
local function AddNeutralTeam()
|
||||
while NeutralTeamLock do
|
||||
debugprint "in neutral team 2 lock"
|
||||
wait()
|
||||
log "in neutral team 2 lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
NeutralTeamLock = true
|
||||
|
||||
|
|
@ -2821,7 +2785,7 @@ local function SetPlayerToTeam(entry)
|
|||
end
|
||||
-- if player was set to an invalid team, then set it back to neutral
|
||||
if not setToTeam and #(game.Teams:GetTeams()) > 0 then
|
||||
debugprint(`{entry.Player.Name} could not find team`)
|
||||
log(`{entry.Player.Name} could not find team`)
|
||||
entry.MyTeam = nil
|
||||
if not NeutralTeam then
|
||||
AddNeutralTeam()
|
||||
|
|
@ -2841,25 +2805,25 @@ end
|
|||
--]]
|
||||
local function PlayerChanged(entry, property)
|
||||
while PlayerChangedLock do
|
||||
debugprint "in playerchanged lock"
|
||||
wait()
|
||||
log "in playerchanged lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
PlayerChangedLock = true
|
||||
if property == "Neutral" then
|
||||
-- if player changing to neutral
|
||||
if entry.Player.Neutral and #(game.Teams:GetTeams()) > 0 then
|
||||
debugprint(`{entry.Player.Name} setting to neutral`)
|
||||
log(`{entry.Player.Name} setting to neutral`)
|
||||
FindRemovePlayerFromTeam(entry)
|
||||
entry.MyTeam = nil
|
||||
if not NeutralTeam then
|
||||
debugprint(`{entry.Player.Name} creating neutral team`)
|
||||
log(`{entry.Player.Name} creating neutral team`)
|
||||
AddNeutralTeam()
|
||||
else
|
||||
debugprint(`{entry.Player.Name} adding to neutral team`)
|
||||
log(`{entry.Player.Name} adding to neutral team`)
|
||||
AddPlayerToTeam(NeutralTeam, entry)
|
||||
end
|
||||
elseif #(game.Teams:GetTeams()) > 0 then -- else player switching to a team, or a weird edgecase
|
||||
debugprint(`{entry.Player.Name} has been set non-neutral`)
|
||||
log(`{entry.Player.Name} has been set non-neutral`)
|
||||
SetPlayerToTeam(entry)
|
||||
end
|
||||
BaseUpdate()
|
||||
|
|
@ -2868,7 +2832,7 @@ local function PlayerChanged(entry, property)
|
|||
and not entry.Player.Neutral
|
||||
and entry.Player ~= entry.MyTeam
|
||||
then
|
||||
debugprint(`{entry.Player.Name} setting to new team`)
|
||||
log(`{entry.Player.Name} setting to new team`)
|
||||
SetPlayerToTeam(entry)
|
||||
BaseUpdate()
|
||||
elseif property == "Name" or property == "MembershipType" then
|
||||
|
|
@ -2899,8 +2863,8 @@ end
|
|||
--]]
|
||||
local function InsertPlayerFrame(nplayer)
|
||||
while AddingFrameLock do
|
||||
debugprint(`waiting to insert {nplayer.Name}`)
|
||||
wait()
|
||||
log(`waiting to insert {nplayer.Name}`)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
|
||||
|
|
@ -2999,8 +2963,8 @@ local function InsertPlayerFrame(nplayer)
|
|||
nplayer.ChildAdded:connect(function(nchild)
|
||||
if nchild.Name == "leaderstats" then
|
||||
while AddingFrameLock do
|
||||
debugprint "in adding leaderstats lock"
|
||||
wait()
|
||||
log "in adding leaderstats lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
LeaderstatsAdded(nentry)
|
||||
|
|
@ -3034,8 +2998,8 @@ end
|
|||
--]]
|
||||
local function RemovePlayerFrame(tplayer)
|
||||
while AddingFrameLock do
|
||||
debugprint "in removing player frame lock"
|
||||
wait()
|
||||
log "in removing player frame lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
|
||||
|
|
@ -3072,7 +3036,7 @@ Players.ChildRemoved:connect(RemovePlayerFrame)
|
|||
|
||||
local function OnFriendshipChanged(player, friendStatus)
|
||||
Delay(0.5, function()
|
||||
debugprint(
|
||||
log(
|
||||
`friend status changed for {player.Name} {friendStatus} vs {GetFriendStatus(
|
||||
player
|
||||
)}`
|
||||
|
|
@ -3086,7 +3050,7 @@ local function OnFriendshipChanged(player, friendStatus)
|
|||
elseif nicon ~= "" and entry.Frame.FriendLabel.Image == "" then
|
||||
entry.Frame.TitleFrame.Title.Position = entry.Frame.TitleFrame.Title.Position
|
||||
+ UDim2.new(0, 17, 0, 0)
|
||||
debugprint(`confirmed status {player.Name}`)
|
||||
log(`confirmed status {player.Name}`)
|
||||
end
|
||||
entry.Frame.FriendLabel.Image = nicon
|
||||
return
|
||||
|
|
@ -3137,8 +3101,8 @@ end
|
|||
--]]
|
||||
local function RemoveTeamFrame(nteam)
|
||||
while AddingFrameLock do
|
||||
debugprint "in removing team frame lock"
|
||||
wait()
|
||||
log "in removing team frame lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
-- if IsMinimized.Value then
|
||||
|
|
@ -3152,7 +3116,7 @@ local function RemoveTeamFrame(nteam)
|
|||
end
|
||||
end
|
||||
if #TeamFrames == 0 then
|
||||
debugprint "removeteamframe, remove neutral"
|
||||
log "removeteamframe, remove neutral"
|
||||
if NeutralTeam then
|
||||
RemoveNeutralTeam()
|
||||
end
|
||||
|
|
@ -3198,8 +3162,8 @@ end
|
|||
--]]
|
||||
local function InsertTeamFrame(nteam)
|
||||
while AddingFrameLock do
|
||||
debugprint "in adding team frame lock"
|
||||
wait()
|
||||
log "in adding team frame lock"
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
AddingFrameLock = true
|
||||
--for _,i in pairs(TeamFrames) do
|
||||
|
|
@ -3299,7 +3263,7 @@ game.GuiService:AddKey "\t"
|
|||
local LastTabTime = time()
|
||||
game.GuiService.KeyPressed:connect(function(key)
|
||||
if key == "\t" then
|
||||
debugprint "caught tab key"
|
||||
log "caught tab key"
|
||||
local modalCheck, isModal = pcall(function()
|
||||
return game.GuiService.IsModalDialog
|
||||
end)
|
||||
|
|
@ -3362,8 +3326,8 @@ pcall(function()
|
|||
end)
|
||||
|
||||
while not game:GetService "Teams" do
|
||||
wait()
|
||||
debugprint "Waiting For Teams"
|
||||
RunService.Heartbeat:wait()
|
||||
log "Waiting For Teams"
|
||||
end
|
||||
for _, i in pairs(game.Teams:GetTeams()) do
|
||||
TeamAdded(i)
|
||||
|
|
|
|||
|
|
@ -29,19 +29,15 @@ waitForProperty(game.Players, "LocalPlayer")
|
|||
|
||||
local function SlotNumber()
|
||||
return New "TextLabel" {
|
||||
Name = "SlotNumber",
|
||||
BackgroundTransparency = 1,
|
||||
BorderSizePixel = 0,
|
||||
Font = Enum.Font.ArialBold,
|
||||
FontSize = Enum.FontSize.Size18,
|
||||
Position = UDim2.new(0, 0, 0, 0),
|
||||
Size = UDim2.new(0, 10, 0, 15),
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
TextTransparency = 0,
|
||||
TextXAlignment = Enum.TextXAlignment.Left,
|
||||
TextYAlignment = Enum.TextYAlignment.Bottom,
|
||||
RobloxLocked = true,
|
||||
ZIndex = 5,
|
||||
}
|
||||
end
|
||||
|
||||
|
|
@ -160,7 +156,12 @@ local CurrentLoadout = New "Frame" {
|
|||
TextWrap = true,
|
||||
ZIndex = 5.0,
|
||||
},
|
||||
SlotNumber(),
|
||||
Hydrate(SlotNumber()) {
|
||||
Name = "SlotNumber",
|
||||
TextColor3 = Color3.new(1, 1, 1),
|
||||
Position = UDim2.new(0, 0, 0, 0),
|
||||
ZIndex = 5,
|
||||
},
|
||||
Hydrate(SlotNumber()) {
|
||||
Name = "SlotNumberDownShadow",
|
||||
TextColor3 = Color3.new(0, 0, 0),
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ print "[Mercury]: Loaded corescript 53878057"
|
|||
|
||||
local CoreGui = game:GetService "CoreGui"
|
||||
local GuiService = game:GetService "GuiService"
|
||||
local RunService = game:GetService "RunService"
|
||||
local UserInputService = Game:GetService "UserInputService"
|
||||
|
||||
-- A couple of necessary functions
|
||||
|
|
@ -525,12 +526,6 @@ local function activateGear(num)
|
|||
end
|
||||
end
|
||||
|
||||
local waitForDebounce = function()
|
||||
while debounce do
|
||||
wait()
|
||||
end
|
||||
end
|
||||
|
||||
local function pointInRectangle(point, rectTopLeft, rectSize)
|
||||
if point.x > rectTopLeft.x and point.x < (rectTopLeft.x + rectSize.x) then
|
||||
if
|
||||
|
|
@ -713,7 +708,9 @@ local function addingPlayerChild(
|
|||
addToSlot,
|
||||
inventoryGearButton
|
||||
)
|
||||
waitForDebounce()
|
||||
while debounce do
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
debounce = true
|
||||
|
||||
if child:FindFirstChild "RobloxBuildTool" then
|
||||
|
|
@ -1153,7 +1150,7 @@ pcall(function()
|
|||
Game.StarterGui.CoreGuiChangedSignal:connect(coreGuiChanged)
|
||||
end)
|
||||
|
||||
wait() -- let stuff initialize incase this is first heartbeat...
|
||||
RunService.Heartbeat:wait() -- let stuff initialize incase this is first heartbeat...
|
||||
|
||||
waitForChild(player, "Backpack")
|
||||
waitForProperty(player, "Character")
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
-- Script Context./Libraries/LibraryRegistration/LibraryRegist
|
||||
print "[Mercury]: Loaded corescript 60595695"
|
||||
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
-- Library Registration Script
|
||||
-- This script is used to register RbxLua libraries on game servers, so game scripts have
|
||||
-- access to all of the libraries (otherwise only local scripts do)
|
||||
|
|
@ -12,7 +14,7 @@ for i = 1, 4 do
|
|||
if ScriptContext then
|
||||
break
|
||||
end
|
||||
wait(0.2)
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
|
||||
if ScriptContext then
|
||||
|
|
|
|||
|
|
@ -1,12 +1,8 @@
|
|||
--!strict
|
||||
-- CoreGui.RobloxGui.CoreScripts/ChatScript
|
||||
print "[Mercury]: Loaded corescript 97188756"
|
||||
|
||||
--[[
|
||||
//FileName: ChatScript.LUA
|
||||
//Written by: Sorcus
|
||||
//Description: Code for lua side chat on Mercury. Supports Scrolling.
|
||||
//NOTE: If you find any bugs or inaccuracies PM Sorcus on Roblox or @Canavus on Twitter
|
||||
]]
|
||||
local RunService = game:GetService "RunService"
|
||||
|
||||
local SafeChat = require "../Modules/Safechat.yml" -- THANK YOU DARKLUA
|
||||
local New = (require "../Modules/New").New
|
||||
|
|
@ -21,19 +17,13 @@ local function WaitForChild(parent, childName)
|
|||
return parent[childName]
|
||||
end
|
||||
|
||||
local function IsPhone()
|
||||
local cGui = Game:GetService "CoreGui"
|
||||
local rGui = WaitForChild(cGui, "RobloxGui")
|
||||
return rGui.AbsoluteSize.Y < 600
|
||||
end
|
||||
|
||||
while Game.Players.LocalPlayer == nil do
|
||||
wait(0.03)
|
||||
while not Game.Players.LocalPlayer do
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
|
||||
local Player = Game.Players.LocalPlayer
|
||||
while Player.Character == nil do
|
||||
wait(0.03)
|
||||
while not Player.Character do
|
||||
RunService.Heartbeat:wait()
|
||||
end
|
||||
local Camera = Game.Workspace.CurrentCamera
|
||||
|
||||
|
|
@ -51,7 +41,7 @@ local enum_mt = {
|
|||
end,
|
||||
__index = {
|
||||
GetEnumItems = function(self)
|
||||
local t = {}
|
||||
local t: { any } = {}
|
||||
for i, item in pairs(self) do
|
||||
if type(i) == "number" then
|
||||
t[#t + 1] = item
|
||||
|
|
@ -571,9 +561,9 @@ function Chat:CreateMessage(cPlayer, message)
|
|||
end
|
||||
|
||||
function Chat:ScreenSizeChanged()
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
while self.Frame.AbsoluteSize.Y > 120 do
|
||||
self.Frame.Size -= UDim2.new(0, 0, 0.005, 0)
|
||||
(self.Frame :: Frame).Size -= UDim2.new(0, 0, 0.005, 0)
|
||||
end
|
||||
-- Chat:RecalculateSpacing()
|
||||
end
|
||||
|
|
@ -706,13 +696,6 @@ function Chat:CreateGui()
|
|||
},
|
||||
}
|
||||
|
||||
Spawn(function()
|
||||
wait(0.5)
|
||||
if IsPhone() then
|
||||
self.Frame.Size = UDim2.new(0, 280, 0, 120)
|
||||
end
|
||||
end)
|
||||
|
||||
self.RenderFrame = self.Frame.ChatRenderFrame
|
||||
if self.Frame.AbsoluteSize.Y > 120 then
|
||||
Chat:ScreenSizeChanged()
|
||||
|
|
@ -861,7 +844,7 @@ function Chat:CullThread()
|
|||
end
|
||||
end
|
||||
end
|
||||
wait(5.0)
|
||||
wait(5)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ end)
|
|||
|
||||
if _MAP_LOCATION_EXISTS then
|
||||
-- yield so that file load happens in the heartbeat thread
|
||||
wait()
|
||||
RunService.Heartbeat:wait()
|
||||
|
||||
-- load the game
|
||||
game:Load(_MAP_LOCATION)
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
--!strict
|
||||
print "[Mercury]: Loaded Join corescript"
|
||||
|
||||
local InsertService = game:GetService "InsertService"
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
local ContentProvider = game:GetService "ContentProvider"
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
-- Local function definitions
|
||||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
---------------
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
@ -216,7 +216,7 @@ end
|
|||
|
||||
-- Show the highlighter.
|
||||
function MouseHighlighter:EnablePreview()
|
||||
self.selectionBox.Parent = CoreGui-- This will make it not show up in workspace.
|
||||
self.selectionBox.Parent = CoreGui -- This will make it not show up in workspace.
|
||||
end
|
||||
|
||||
-- Create the mouse movement highlighter.
|
||||
|
|
@ -625,7 +625,7 @@ function onClicked(mouse2)
|
|||
d = math.floor(50 * (originalY - prevY) / mouse2.ViewSizeY)
|
||||
elevate(x, y, z, elevationOptions.r, r2, d, range)
|
||||
end
|
||||
wait(0)
|
||||
wait()
|
||||
end
|
||||
ChangeHistoryService:SetWaypoint "Elevation"
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
@ -80,11 +80,11 @@ function makeCrater(x, y, z, cr, cd)
|
|||
if cellschanged == false then
|
||||
break
|
||||
end
|
||||
wait(0)
|
||||
wait()
|
||||
end
|
||||
|
||||
for ri = 0, cr do
|
||||
wait(0)
|
||||
wait()
|
||||
|
||||
local i = x - ri
|
||||
for k = z - cr, z + cr do
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
---------------
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
while game == nil do
|
||||
wait(1 / 30)
|
||||
wait()
|
||||
end
|
||||
|
||||
local ChangeHistoryService = game:GetService "ChangeHistoryService"
|
||||
|
|
|
|||
Loading…
Reference in New Issue