Improve settings script using New function
This commit is contained in:
parent
4680b21930
commit
1f450a0b1f
|
|
@ -1713,7 +1713,7 @@ binaryShrink = function(min, max, fits)
|
||||||
end
|
end
|
||||||
local getGuiOwner
|
local getGuiOwner
|
||||||
getGuiOwner = function(instance)
|
getGuiOwner = function(instance)
|
||||||
while instance ~= nil do
|
while (instance ~= nil) do
|
||||||
if instance:IsA("ScreenGui") or instance:IsA("BillboardGui") then
|
if instance:IsA("ScreenGui") or instance:IsA("BillboardGui") then
|
||||||
return instance
|
return instance
|
||||||
end
|
end
|
||||||
|
|
@ -2002,7 +2002,7 @@ CreateBasicTutorialPage = function(name, handleResize, skipTutorial, giveDoneBut
|
||||||
end
|
end
|
||||||
frame.Changed:connect(function(prop)
|
frame.Changed:connect(function(prop)
|
||||||
if prop == "Parent" then
|
if prop == "Parent" then
|
||||||
if parentConnection ~= nil then
|
if (parentConnection ~= nil) then
|
||||||
parentConnection:disconnect()
|
parentConnection:disconnect()
|
||||||
parentConnection = nil
|
parentConnection = nil
|
||||||
end
|
end
|
||||||
|
|
@ -2675,7 +2675,7 @@ t.CreateSetPanel = function(userIdsForSets, objectSelected, dialogClosed, size,
|
||||||
end
|
end
|
||||||
local selectSet
|
local selectSet
|
||||||
selectSet = function(button, setName, setId, _)
|
selectSet = function(button, setName, setId, _)
|
||||||
if button and Data.Category[Data.CurrentCategory] ~= nil then
|
if button and (Data.Category[Data.CurrentCategory] ~= nil) then
|
||||||
if button ~= Data.Category[Data.CurrentCategory].Button then
|
if button ~= Data.Category[Data.CurrentCategory].Button then
|
||||||
Data.Category[Data.CurrentCategory].Button = button
|
Data.Category[Data.CurrentCategory].Button = button
|
||||||
if SetCache[setId] == nil then
|
if SetCache[setId] == nil then
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1836,7 +1836,7 @@ binaryShrink = (min, max, fits) ->
|
||||||
|
|
||||||
|
|
||||||
getGuiOwner = (instance) ->
|
getGuiOwner = (instance) ->
|
||||||
while instance ~= nil
|
while instance?
|
||||||
if instance\IsA"ScreenGui" or instance\IsA "BillboardGui"
|
if instance\IsA"ScreenGui" or instance\IsA "BillboardGui"
|
||||||
return instance
|
return instance
|
||||||
|
|
||||||
|
|
@ -2152,7 +2152,7 @@ CreateBasicTutorialPage = (name, handleResize, skipTutorial, giveDoneButton) ->
|
||||||
|
|
||||||
frame.Changed\connect (prop) ->
|
frame.Changed\connect (prop) ->
|
||||||
if prop == "Parent"
|
if prop == "Parent"
|
||||||
if parentConnection ~= nil
|
if parentConnection?
|
||||||
parentConnection\disconnect!
|
parentConnection\disconnect!
|
||||||
parentConnection = nil
|
parentConnection = nil
|
||||||
|
|
||||||
|
|
@ -2837,7 +2837,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
|
|
||||||
|
|
||||||
selectSet = (button, setName, setId, _) ->
|
selectSet = (button, setName, setId, _) ->
|
||||||
if button and Data.Category[Data.CurrentCategory] ~= nil
|
if button and Data.Category[Data.CurrentCategory]?
|
||||||
if button ~= Data.Category[Data.CurrentCategory].Button
|
if button ~= Data.Category[Data.CurrentCategory].Button
|
||||||
Data.Category[Data.CurrentCategory].Button = button
|
Data.Category[Data.CurrentCategory].Button = button
|
||||||
|
|
||||||
|
|
|
||||||
1216
yue/46295863.yue
1216
yue/46295863.yue
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue