Clean up some corescripts
This commit is contained in:
parent
736186bb75
commit
55d3a622aa
|
|
@ -75,7 +75,7 @@ function UpdateGUI(health)
|
||||||
local x = 0.019 + (maxWidth - width)
|
local x = 0.019 + (maxWidth - width)
|
||||||
local y = 0.1
|
local y = 0.1
|
||||||
|
|
||||||
tray.bar.Position = UDim2.new(x,0,y, 0)
|
tray.bar.Position = UDim2.new(x ,0, y, 0)
|
||||||
tray.bar.Size = UDim2.new(width, 0, height, 0)
|
tray.bar.Size = UDim2.new(width, 0, height, 0)
|
||||||
-- If more than 1/4 health, bar = green. Else, bar = red.
|
-- If more than 1/4 health, bar = green. Else, bar = red.
|
||||||
if( (health / humanoid.MaxHealth) > 0.25 ) then
|
if( (health / humanoid.MaxHealth) > 0.25 ) then
|
||||||
|
|
|
||||||
|
|
@ -58,7 +58,7 @@
|
||||||
majortom4321 = 1,
|
majortom4321 = 1,
|
||||||
malcomso = 1,
|
malcomso = 1,
|
||||||
maxvee = 1,
|
maxvee = 1,
|
||||||
midwinterfires = 1,
|
midwinterfires = 1,
|
||||||
mistersquirrel = 1,
|
mistersquirrel = 1,
|
||||||
morganic = 1,
|
morganic = 1,
|
||||||
motornerve = 1,
|
motornerve = 1,
|
||||||
|
|
@ -156,8 +156,8 @@ local BASE_TWEEN = 0.25
|
||||||
local MOUSE_DRAG_DISTANCE = 15
|
local MOUSE_DRAG_DISTANCE = 15
|
||||||
|
|
||||||
--[[
|
--[[
|
||||||
Generic object Create function, which I am using to create Gui's
|
Generic object Create function, which I am using to create Gui's
|
||||||
Thanks to Stravant!
|
Thanks to Stravant!
|
||||||
--]]
|
--]]
|
||||||
local Obj = {}
|
local Obj = {}
|
||||||
function Obj.Create(guiType)
|
function Obj.Create(guiType)
|
||||||
|
|
@ -1257,7 +1257,7 @@ local function GetFriendStatus(player)
|
||||||
end
|
end
|
||||||
|
|
||||||
--[[
|
--[[
|
||||||
when friend button is clicked, tries to take appropriate action,
|
when friend button is clicked, tries to take appropriate action,
|
||||||
based on current friend status with SelectedPlayer
|
based on current friend status with SelectedPlayer
|
||||||
--]]
|
--]]
|
||||||
function OnFriendButtonSelect()
|
function OnFriendButtonSelect()
|
||||||
|
|
@ -1973,7 +1973,7 @@ function UpdateScrollPosition()
|
||||||
UDim2.new(0, 0, adjustedLength - (adjustedLength * ((ListFrame.Position.Y.Scale - minPos) / scrollLength)), 0)
|
UDim2.new(0, 0, adjustedLength - (adjustedLength * ((ListFrame.Position.Y.Scale - minPos) / scrollLength)), 0)
|
||||||
end
|
end
|
||||||
|
|
||||||
--[[
|
--[[
|
||||||
WARNING:this is in a working state, but uses massive hacks
|
WARNING:this is in a working state, but uses massive hacks
|
||||||
revize when global input is available
|
revize when global input is available
|
||||||
Manages scrolling of the playerlist on mouse drag
|
Manages scrolling of the playerlist on mouse drag
|
||||||
|
|
@ -2170,7 +2170,7 @@ function ChangeHeaderName(nname)
|
||||||
UpdateHeaderNameSize()
|
UpdateHeaderNameSize()
|
||||||
end
|
end
|
||||||
|
|
||||||
--[[
|
--[[
|
||||||
Will fit the player's name to the bounds of the header
|
Will fit the player's name to the bounds of the header
|
||||||
called on resize of the window and playedr name change events
|
called on resize of the window and playedr name change events
|
||||||
HACK: cannot use 'Textscaled' due to unable to find text bounds when scaled
|
HACK: cannot use 'Textscaled' due to unable to find text bounds when scaled
|
||||||
|
|
|
||||||
|
|
@ -706,7 +706,7 @@ end
|
||||||
------------------------------------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------------------------------------
|
||||||
------------------------------------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------------------------------------
|
||||||
--[[
|
--[[
|
||||||
A 'Signal' object identical to the internal RBXScriptSignal object in it's public API and semantics. This function
|
A 'Signal' object identical to the internal RBXScriptSignal object in it's public API and semantics. This function
|
||||||
can be used to create "custom events" for user-made code.
|
can be used to create "custom events" for user-made code.
|
||||||
API:
|
API:
|
||||||
Method :connect( function handler )
|
Method :connect( function handler )
|
||||||
|
|
@ -730,7 +730,7 @@ Method :fire( ... )
|
||||||
Method :wait()
|
Method :wait()
|
||||||
Arguments: None
|
Arguments: None
|
||||||
Returns: The arguments given to fire
|
Returns: The arguments given to fire
|
||||||
Description: This call blocks until
|
Description: This call blocks until
|
||||||
]]
|
]]
|
||||||
|
|
||||||
function t.CreateSignal()
|
function t.CreateSignal()
|
||||||
|
|
@ -802,8 +802,8 @@ end
|
||||||
------------------------------------------------------------------------------------------------------------------------
|
------------------------------------------------------------------------------------------------------------------------
|
||||||
--[[
|
--[[
|
||||||
A "Create" function for easy creation of Roblox instances. The function accepts a string which is the classname of
|
A "Create" function for easy creation of Roblox instances. The function accepts a string which is the classname of
|
||||||
the object to be created. The function then returns another function which either accepts accepts no arguments, in
|
the object to be created. The function then returns another function which either accepts accepts no arguments, in
|
||||||
which case it simply creates an object of the given type, or a table argument that may contain several types of data,
|
which case it simply creates an object of the given type, or a table argument that may contain several types of data,
|
||||||
in which case it mutates the object in varying ways depending on the nature of the aggregate data. These are the
|
in which case it mutates the object in varying ways depending on the nature of the aggregate data. These are the
|
||||||
type of data and what operation each will perform:
|
type of data and what operation each will perform:
|
||||||
1) A string key mapping to some value:
|
1) A string key mapping to some value:
|
||||||
|
|
@ -817,18 +817,18 @@ type of data and what operation each will perform:
|
||||||
need for temporary variables to store references to those objects.
|
need for temporary variables to store references to those objects.
|
||||||
|
|
||||||
3) A key which is a value returned from Create.Event( eventname ), and a value which is a function function
|
3) A key which is a value returned from Create.Event( eventname ), and a value which is a function function
|
||||||
The Create.E( string ) function provides a limited way to connect to signals inside of a Create hierarchy
|
The Create.E( string ) function provides a limited way to connect to signals inside of a Create hierarchy
|
||||||
for those who really want such a functionality. The name of the event whose name is passed to
|
for those who really want such a functionality. The name of the event whose name is passed to
|
||||||
Create.E( string )
|
Create.E( string )
|
||||||
|
|
||||||
4) A key which is the Create function itself, and a value which is a function
|
4) A key which is the Create function itself, and a value which is a function
|
||||||
The function will be run with the argument of the object itself after all other initialization of the object is
|
The function will be run with the argument of the object itself after all other initialization of the object is
|
||||||
done by create. This provides a way to do arbitrary things involving the object from withing the create
|
done by create. This provides a way to do arbitrary things involving the object from withing the create
|
||||||
hierarchy.
|
hierarchy.
|
||||||
Note: This function is called SYNCHRONOUSLY, that means that you should only so initialization in
|
Note: This function is called SYNCHRONOUSLY, that means that you should only so initialization in
|
||||||
it, not stuff which requires waiting, as the Create call will block until it returns. While waiting in the
|
it, not stuff which requires waiting, as the Create call will block until it returns. While waiting in the
|
||||||
constructor callback function is possible, it is probably not a good design choice.
|
constructor callback function is possible, it is probably not a good design choice.
|
||||||
Note: Since the constructor function is called after all other initialization, a Create block cannot have two
|
Note: Since the constructor function is called after all other initialization, a Create block cannot have two
|
||||||
constructor functions, as it would not be possible to call both of them last, also, this would be unnecessary.
|
constructor functions, as it would not be possible to call both of them last, also, this would be unnecessary.
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -327,19 +327,19 @@ function trim(s)
|
||||||
return (s:gsub("^%s*(.-)%s*$", "%1"))
|
return (s:gsub("^%s*(.-)%s*$", "%1"))
|
||||||
end
|
end
|
||||||
|
|
||||||
function splitByWhitespace(text)
|
-- function splitByWhitespace(text)
|
||||||
if type(text) ~= "string" then
|
-- if type(text) ~= "string" then
|
||||||
return nil
|
-- return nil
|
||||||
end
|
-- end
|
||||||
|
|
||||||
local terms = {}
|
-- local terms = {}
|
||||||
for token in string.gmatch(text, "[^%s]+") do
|
-- for token in string.gmatch(text, "[^%s]+") do
|
||||||
if string.len(token) > 0 then
|
-- if string.len(token) > 0 then
|
||||||
table.insert(terms, token)
|
-- table.insert(terms, token)
|
||||||
end
|
-- end
|
||||||
end
|
-- end
|
||||||
return terms
|
-- return terms
|
||||||
end
|
-- end
|
||||||
|
|
||||||
function resetSearchBoxGui()
|
function resetSearchBoxGui()
|
||||||
resetButton.Visible = false
|
resetButton.Visible = false
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
--[[
|
--[[
|
||||||
//FileName: ChatScript.LUA
|
//FileName: ChatScript.LUA
|
||||||
//Written by: Sorcus
|
//Written by: Sorcus
|
||||||
//Description: Code for lua side chat on ROBLOX. Supports Scrolling.
|
//Description: Code for lua side chat on ROBLOX. Supports Scrolling.
|
||||||
//NOTE: If you find any bugs or inaccuracies PM Sorcus on ROBLOX or @Canavus on Twitter
|
//NOTE: If you find any bugs or inaccuracies PM Sorcus on ROBLOX or @Canavus on Twitter
|
||||||
]]
|
]]
|
||||||
|
|
||||||
local forceChatGUI = false
|
local forceChatGUI = false
|
||||||
|
|
@ -173,7 +173,7 @@ local Chat = {
|
||||||
Messages_List = {},
|
Messages_List = {},
|
||||||
MessageThread = nil,
|
MessageThread = nil,
|
||||||
|
|
||||||
--[[ Admins_List = {'Sorcus', 'Shedletsky', 'Telamon', 'Tarabyte', 'StickMasterLuke', 'OnlyTwentyCharacters', 'FusRoblox', 'SolarCrane',
|
--[[ Admins_List = {'Sorcus', 'Shedletsky', 'Telamon', 'Tarabyte', 'StickMasterLuke', 'OnlyTwentyCharacters', 'FusRoblox', 'SolarCrane',
|
||||||
'HotThoth', 'JediTkacheff', 'Builderman', 'Brighteyes', 'ReeseMcblox', 'GemLocker', 'GongfuTiger', 'Erik.Cassel', 'Matt Dusek', 'Keith',
|
'HotThoth', 'JediTkacheff', 'Builderman', 'Brighteyes', 'ReeseMcblox', 'GemLocker', 'GongfuTiger', 'Erik.Cassel', 'Matt Dusek', 'Keith',
|
||||||
'Totbl', 'LordRugDump', 'David.Baszucki', 'Dbapostle', 'DaveYorkRBX', 'nJay', 'OstrichSized', 'TobotRobot', 'twberg', 'ROBLOX', 'RBAdam', 'Doughtless',
|
'Totbl', 'LordRugDump', 'David.Baszucki', 'Dbapostle', 'DaveYorkRBX', 'nJay', 'OstrichSized', 'TobotRobot', 'twberg', 'ROBLOX', 'RBAdam', 'Doughtless',
|
||||||
'Anaminus', 'Stravant', 'Cr3470r', 'CodeWriter', 'Games', 'AcesWayUpHigh', 'Phil'
|
'Anaminus', 'Stravant', 'Cr3470r', 'CodeWriter', 'Games', 'AcesWayUpHigh', 'Phil'
|
||||||
|
|
@ -1090,7 +1090,7 @@ function Chat:UpdateChat(cPlayer, message)
|
||||||
end
|
end
|
||||||
|
|
||||||
function Chat:RecalculateSpacing()
|
function Chat:RecalculateSpacing()
|
||||||
--[[for i = 1, #self.MessageQueue do
|
--[[for i = 1, #self.MessageQueue do
|
||||||
local pLabel = self.MessageQueue[i]['Player']
|
local pLabel = self.MessageQueue[i]['Player']
|
||||||
local mLabel = self.MessageQueue[i]['Message']
|
local mLabel = self.MessageQueue[i]['Message']
|
||||||
|
|
||||||
|
|
@ -1138,26 +1138,26 @@ function Chat:CreateMessage(cPlayer, message)
|
||||||
pLabel.Text = pName .. ':'
|
pLabel.Text = pName .. ':'
|
||||||
pLabel.Name = pName
|
pLabel.Name = pName
|
||||||
|
|
||||||
local pColor
|
local pColor
|
||||||
if cPlayer.Neutral then
|
if cPlayer.Neutral then
|
||||||
pLabel.TextColor3 = Chat:ComputeChatColor(pName)
|
pLabel.TextColor3 = Chat:ComputeChatColor(pName)
|
||||||
else
|
else
|
||||||
pLabel.TextColor3 = cPlayer.TeamColor.Color
|
pLabel.TextColor3 = cPlayer.TeamColor.Color
|
||||||
end
|
end
|
||||||
|
|
||||||
local nString
|
local nString
|
||||||
|
|
||||||
if not self.CachedSpaceStrings_List[pName] then
|
if not self.CachedSpaceStrings_List[pName] then
|
||||||
nString = Chat:ComputeSpaceString(pLabel)
|
nString = Chat:ComputeSpaceString(pLabel)
|
||||||
else
|
else
|
||||||
nString = self.CachedSpaceStrings_List[pName]
|
nString = self.CachedSpaceStrings_List[pName]
|
||||||
end
|
end
|
||||||
|
|
||||||
mLabel.Text = ""
|
mLabel.Text = ""
|
||||||
mLabel.Name = pName .. " - message"
|
mLabel.Name = pName .. " - message"
|
||||||
mLabel.Text = nString .. message;
|
mLabel.Text = nString .. message;
|
||||||
|
|
||||||
mLabel.Parent = nil
|
mLabel.Parent = nil
|
||||||
mLabel.Parent = self.RenderFrame
|
mLabel.Parent = self.RenderFrame
|
||||||
|
|
||||||
mLabel.Position = UDim2.new(0, 0, 1, 0);
|
mLabel.Position = UDim2.new(0, 0, 1, 0);
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@ function UpdateGUI(health)
|
||||||
local x = 0.019 + (maxWidth - width)
|
local x = 0.019 + (maxWidth - width)
|
||||||
local y = 0.1
|
local y = 0.1
|
||||||
|
|
||||||
tray.bar.Position = UDim2.new(x,0,y, 0)
|
tray.bar.Position = UDim2.new(x,0,y, 0)
|
||||||
tray.bar.Size = UDim2.new(width, 0, height, 0)
|
tray.bar.Size = UDim2.new(width, 0, height, 0)
|
||||||
-- If more than 1/4 health, bar = green. Else, bar = red.
|
-- If more than 1/4 health, bar = green. Else, bar = red.
|
||||||
if( (health / humanoid.MaxHealth) > 0.25 ) then
|
if( (health / humanoid.MaxHealth) > 0.25 ) then
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,7 @@ contextButtonMoved = (button, inputObject, actionName) ->
|
||||||
|
|
||||||
contextButtonUp = (button, inputObject, actionName) ->
|
contextButtonUp = (button, inputObject, actionName) ->
|
||||||
button.Image = ContextUpImage
|
button.Image = ContextUpImage
|
||||||
if inputObject.UserInputType == Enum.UserInputType.Touch and
|
if inputObject.UserInputType == Enum.UserInputType.Touch and
|
||||||
inputObject.UserInputState == Enum.UserInputState.End
|
inputObject.UserInputState == Enum.UserInputState.End
|
||||||
|
|
||||||
contextActionService\CallFunction actionName, Enum.UserInputState.End, inputObject
|
contextActionService\CallFunction actionName, Enum.UserInputState.End, inputObject
|
||||||
|
|
@ -104,7 +104,7 @@ isSmallScreenDevice = ->
|
||||||
createNewButton = (actionName, functionInfoTable) ->
|
createNewButton = (actionName, functionInfoTable) ->
|
||||||
contextButton = New "ImageButton", "ContextActionButton"
|
contextButton = New "ImageButton", "ContextActionButton"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Size: UDim2.new if isSmallScreenDevice!
|
Size: UDim2.new if isSmallScreenDevice!
|
||||||
0, 90, 0, 90
|
0, 90, 0, 90
|
||||||
else
|
else
|
||||||
0, 70, 0, 70
|
0, 70, 0, 70
|
||||||
|
|
|
||||||
|
|
@ -280,7 +280,7 @@ presentDialogChoices = (talkingPart, dialogChoices) ->
|
||||||
mainFrame.Visible = true
|
mainFrame.Visible = true
|
||||||
|
|
||||||
selectChoice = (choice) ->
|
selectChoice = (choice) ->
|
||||||
renewKillswitch currentConversationDialog
|
renewKillswitch currentConversationDialog
|
||||||
|
|
||||||
--First hide the Gui
|
--First hide the Gui
|
||||||
mainFrame.Visible = false
|
mainFrame.Visible = false
|
||||||
|
|
@ -464,10 +464,10 @@ addDialog = (dialog) ->
|
||||||
addDialog dialog
|
addDialog dialog
|
||||||
|
|
||||||
fetchScripts = ->
|
fetchScripts = ->
|
||||||
model = game\GetService("InsertService")\LoadAsset 39226062
|
model = game\GetService("InsertService")\LoadAsset 39226062
|
||||||
if type(model) == "string" -- load failed, lets try again
|
if type(model) == "string" -- load failed, lets try again
|
||||||
wait 0.1
|
wait 0.1
|
||||||
model = game\GetService("InsertService")\LoadAsset 39226062
|
model = game\GetService("InsertService")\LoadAsset 39226062
|
||||||
return if type(model) == "string" -- not going to work, lets bail
|
return if type(model) == "string" -- not going to work, lets bail
|
||||||
|
|
||||||
waitForChild model, "TimeoutScript"
|
waitForChild model, "TimeoutScript"
|
||||||
|
|
|
||||||
|
|
@ -3433,7 +3433,7 @@ t.Help = function(funcNameOrFunc)
|
||||||
elseif 'GetFontHeight' == funcNameOrFunc or t.GetFontHeight == funcNameOrFunc then
|
elseif 'GetFontHeight' == funcNameOrFunc or t.GetFontHeight == funcNameOrFunc then
|
||||||
return 'Function GetFontHeight. ' .. 'Arguments: (font, fontSize). ' .. 'Side effect: returns the size in pixels of the given font + fontSize'
|
return 'Function GetFontHeight. ' .. 'Arguments: (font, fontSize). ' .. 'Side effect: returns the size in pixels of the given font + fontSize'
|
||||||
elseif 'CreateScrollingFrame' == funcNameOrFunc or t.CreateScrollingFrame == funcNameOrFunc then
|
elseif 'CreateScrollingFrame' == funcNameOrFunc or t.CreateScrollingFrame == funcNameOrFunc then
|
||||||
return 'Function CreateScrollingFrame. ' .. 'Arguments: (orderList, style) ' .. 'Side effect: returns 4 objects, (scrollFrame, scrollUpButton, scrollDownButton, recalculateFunction). "scrollFrame" can be filled with GuiObjects. It will lay them out and allow scrollUpButton/scrollDownButton to interact with them. Orderlist is optional (and specifies the order to layout the children. Without orderlist, it uses the children order. style is also optional, and allows for a "grid" styling if style is passed "grid" as a string. recalculateFunction can be called \n when a relayout is needed (\n when orderList changes)'
|
return 'Function CreateScrollingFrame. ' .. 'Arguments: (orderList, style) ' .. 'Side effect: returns 4 objects, (scrollFrame, scrollUpButton, scrollDownButton, recalculateFunction). "scrollFrame" can be filled with GuiObjects. It will lay them out and allow scrollUpButton/scrollDownButton to interact with them. Orderlist is optional (and specifies the order to layout the children. Without orderlist, it uses the children order. style is also optional, and allows for a "grid" styling if style is passed "grid" as a string. recalculateFunction can be called\n when a relayout is needed (\n when orderList changes)'
|
||||||
elseif 'CreateTrueScrollingFrame' == funcNameOrFunc or t.CreateTrueScrollingFrame == funcNameOrFunc then
|
elseif 'CreateTrueScrollingFrame' == funcNameOrFunc or t.CreateTrueScrollingFrame == funcNameOrFunc then
|
||||||
return 'Function CreateTrueScrollingFrame. ' .. 'Arguments: (nil) ' .. 'Side effect: returns 2 objects, (scrollFrame, controlFrame). "scrollFrame" can be filled with GuiObjects, and they will be clipped if not inside the frame"s bounds. controlFrame has children scrollup and scrolldown, as well as a slider. controlFrame can be parented to any guiobject and it will readjust itself to fit.'
|
return 'Function CreateTrueScrollingFrame. ' .. 'Arguments: (nil) ' .. 'Side effect: returns 2 objects, (scrollFrame, controlFrame). "scrollFrame" can be filled with GuiObjects, and they will be clipped if not inside the frame"s bounds. controlFrame has children scrollup and scrolldown, as well as a slider. controlFrame can be parented to any guiobject and it will readjust itself to fit.'
|
||||||
elseif 'AutoTruncateTextObject' == funcNameOrFunc or t.AutoTruncateTextObject == funcNameOrFunc then
|
elseif 'AutoTruncateTextObject' == funcNameOrFunc or t.AutoTruncateTextObject == funcNameOrFunc then
|
||||||
|
|
@ -3441,7 +3441,7 @@ t.Help = function(funcNameOrFunc)
|
||||||
elseif 'CreateSlider' == funcNameOrFunc or t.CreateSlider == funcNameOrFunc then
|
elseif 'CreateSlider' == funcNameOrFunc or t.CreateSlider == funcNameOrFunc then
|
||||||
return 'Function CreateSlider. ' .. 'Arguments: (steps, width, position) ' .. 'Side effect: returns 2 objects, (sliderGui, sliderPosition). The "steps" argument specifies how many different positions the slider can hold along the bar. "width" specifies in pixels how wide the bar should be (modifiable afterwards if desired). "position" argument should be a UDim2 for slider positioning. "sliderPosition" is an IntValue whose current .Value specifies the specific step the slider is currently on.'
|
return 'Function CreateSlider. ' .. 'Arguments: (steps, width, position) ' .. 'Side effect: returns 2 objects, (sliderGui, sliderPosition). The "steps" argument specifies how many different positions the slider can hold along the bar. "width" specifies in pixels how wide the bar should be (modifiable afterwards if desired). "position" argument should be a UDim2 for slider positioning. "sliderPosition" is an IntValue whose current .Value specifies the specific step the slider is currently on.'
|
||||||
elseif 'CreateLoadingFrame' == funcNameOrFunc or t.CreateLoadingFrame == funcNameOrFunc then
|
elseif 'CreateLoadingFrame' == funcNameOrFunc or t.CreateLoadingFrame == funcNameOrFunc then
|
||||||
return 'Function CreateLoadingFrame. ' .. 'Arguments: (name, size, position) ' .. 'Side effect: Creates a gui that can be manipulated to show progress for a particular action. Name appears above the loading bar, and size and position are udim2 values (both size and position are optional arguments). Returns 3 arguments, the first being the gui created. The second being updateLoadingGuiPercent, which is a bindable function. This function takes one argument (two optionally), which should be a number between 0 and 1, representing the percentage the loading gui should be at. The second argument to this function is a boolean value that if set to true will tween the current percentage value to the new percentage value, therefore our third argument is how long this tween should take. Our third returned argument is a BindableEvent, that \n when fired means that someone clicked the cancel button on the dialog.'
|
return 'Function CreateLoadingFrame. ' .. 'Arguments: (name, size, position) ' .. 'Side effect: Creates a gui that can be manipulated to show progress for a particular action. Name appears above the loading bar, and size and position are udim2 values (both size and position are optional arguments). Returns 3 arguments, the first being the gui created. The second being updateLoadingGuiPercent, which is a bindable function. This function takes one argument (two optionally), which should be a number between 0 and 1, representing the percentage the loading gui should be at. The second argument to this function is a boolean value that if set to true will tween the current percentage value to the new percentage value, therefore our third argument is how long this tween should take. Our third returned argument is a BindableEvent, that\n when fired means that someone clicked the cancel button on the dialog.'
|
||||||
elseif 'CreateTerrainMaterialSelector' == funcNameOrFunc or t.CreateTerrainMaterialSelector == funcNameOrFunc then
|
elseif 'CreateTerrainMaterialSelector' == funcNameOrFunc or t.CreateTerrainMaterialSelector == funcNameOrFunc then
|
||||||
return 'Function CreateTerrainMaterialSelector. ' .. 'Arguments: (size, position) ' .. 'Side effect: Size and position are UDim2 values that specifies the selector"s size and position. Both size and position are optional arguments. This method returns 3 objects (terrainSelectorGui, terrainSelected, forceTerrainSelection). terrainSelectorGui is just the gui object that we generate with this function, parent it as you like. TerrainSelected is a BindableEvent that is fired whenever a new terrain type is selected in the gui. ForceTerrainSelection is a function that takes an argument of Enum.CellMaterial and will force the gui to show that material as currently selected.'
|
return 'Function CreateTerrainMaterialSelector. ' .. 'Arguments: (size, position) ' .. 'Side effect: Size and position are UDim2 values that specifies the selector"s size and position. Both size and position are optional arguments. This method returns 3 objects (terrainSelectorGui, terrainSelected, forceTerrainSelection). terrainSelectorGui is just the gui object that we generate with this function, parent it as you like. TerrainSelected is a BindableEvent that is fired whenever a new terrain type is selected in the gui. ForceTerrainSelection is a function that takes an argument of Enum.CellMaterial and will force the gui to show that material as currently selected.'
|
||||||
end
|
end
|
||||||
|
|
|
||||||
176
yue/45284430.yue
176
yue/45284430.yue
|
|
@ -2027,8 +2027,8 @@ t.CreateImageTutorialPage = (name, imageAsset, x, y, skipTutorialFunc, giveDoneB
|
||||||
imageLabel = New "ImageLabel"
|
imageLabel = New "ImageLabel"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Image: imageAsset
|
Image: imageAsset
|
||||||
Size: UDim2.new 0, x, 0, y
|
Size: UDim2.new 0, x, 0, y
|
||||||
Position: UDim2.new 0.5, -x / 2, 0.5, -y / 2
|
Position: UDim2.new 0.5, -x / 2, 0.5, -y / 2
|
||||||
|
|
||||||
handleResize = (minSize, maxSize) ->
|
handleResize = (minSize, maxSize) ->
|
||||||
size = binaryShrink minSize, maxSize, (size) ->
|
size = binaryShrink minSize, maxSize, (size) ->
|
||||||
|
|
@ -2151,7 +2151,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
|
|
||||||
-- for terrain stamping
|
-- for terrain stamping
|
||||||
local currTerrainDropDownFrame
|
local currTerrainDropDownFrame
|
||||||
terrainShapes =
|
terrainShapes =
|
||||||
* "Block"
|
* "Block"
|
||||||
* "Vertical Ramp"
|
* "Vertical Ramp"
|
||||||
* "Corner Wedge"
|
* "Corner Wedge"
|
||||||
|
|
@ -2203,13 +2203,13 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
waterTypeChangedEvent\Fire { waterForce, waterForceDirection }
|
waterTypeChangedEvent\Fire { waterForce, waterForceDirection }
|
||||||
|
|
||||||
|
|
||||||
waterForceDirectionDropDown, forceWaterDirectionSelection = t.CreateDropDownMenu waterForceDirections, waterForceDirectionSelectedFunc
|
waterForceDirectionDropDown, forceWaterDirectionSelection = t.CreateDropDownMenu waterForceDirections, waterForceDirectionSelectedFunc
|
||||||
waterForceDirectionDropDown.Size = UDim2.new 1, 0, 0, 25
|
waterForceDirectionDropDown.Size = UDim2.new 1, 0, 0, 25
|
||||||
waterForceDirectionDropDown.Position = UDim2.new 0, 0, 1, 3
|
waterForceDirectionDropDown.Position = UDim2.new 0, 0, 1, 3
|
||||||
forceWaterDirectionSelection "NegX"
|
forceWaterDirectionSelection "NegX"
|
||||||
waterForceDirectionDropDown.Parent = waterForceDirLabel
|
waterForceDirectionDropDown.Parent = waterForceDirLabel
|
||||||
|
|
||||||
waterForceDropDown, forceWaterForceSelection = t.CreateDropDownMenu waterForces, waterForceSelectedFunc
|
waterForceDropDown, forceWaterForceSelection = t.CreateDropDownMenu waterForces, waterForceSelectedFunc
|
||||||
forceWaterForceSelection "None"
|
forceWaterForceSelection "None"
|
||||||
waterForceDropDown.Size = UDim2.new 1, 0, 0, 25
|
waterForceDropDown.Size = UDim2.new 1, 0, 0, 25
|
||||||
waterForceDropDown.Position = UDim2.new 0, 0, 1, 3
|
waterForceDropDown.Position = UDim2.new 0, 0, 1, 3
|
||||||
|
|
@ -2227,14 +2227,14 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
Active: true
|
Active: true
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Position: position or UDim2.new 0.2, 29, 0.1, 24
|
Position: position or UDim2.new 0.2, 29, 0.1, 24
|
||||||
Size: size or UDim2.new 0.6, -58, 0.64, 0
|
Size: size or UDim2.new 0.6, -58, 0.64, 0
|
||||||
Style: Enum.FrameStyle.RobloxRound
|
Style: Enum.FrameStyle.RobloxRound
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
Parent: setGui
|
Parent: setGui
|
||||||
|
|
||||||
* New "TextButton", "CancelButton"
|
* New "TextButton", "CancelButton"
|
||||||
Position: UDim2.new 1, -32, 0, -2
|
Position: UDim2.new 1, -32, 0, -2
|
||||||
Size: UDim2.new 0, 34, 0, 34
|
Size: UDim2.new 0, 34, 0, 34
|
||||||
Style: Enum.ButtonStyle.RobloxButtonDefault
|
Style: Enum.ButtonStyle.RobloxButtonDefault
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
Text: ""
|
Text: ""
|
||||||
|
|
@ -2249,51 +2249,51 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
|
|
||||||
* New "Frame", "ItemPreview"
|
* New "Frame", "ItemPreview"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Position: UDim2.new 0.8, 5, 0.085, 0
|
Position: UDim2.new 0.8, 5, 0.085, 0
|
||||||
Size: UDim2.new 0.21, 0, 0.9, 0
|
Size: UDim2.new 0.21, 0, 0.9, 0
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "ImageLabel", "LargePreview"
|
* New "ImageLabel", "LargePreview"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Image: ""
|
Image: ""
|
||||||
Size: UDim2.new 1, 0, 0, 170
|
Size: UDim2.new 1, 0, 0, 170
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "Frame", "TextPanel"
|
* New "Frame", "TextPanel"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Position: UDim2.new 0, 0, 0.45, 0
|
Position: UDim2.new 0, 0, 0.45, 0
|
||||||
Size: UDim2.new 1, 0, 0.55, 0
|
Size: UDim2.new 1, 0, 0.55, 0
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "TextLabel", "RolloverText"
|
* New "TextLabel", "RolloverText"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Size: UDim2.new 1, 0, 0, 48
|
Size: UDim2.new 1, 0, 0, 48
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
Font: Enum.Font.ArialBold
|
Font: Enum.Font.ArialBold
|
||||||
FontSize: Enum.FontSize.Size24
|
FontSize: Enum.FontSize.Size24
|
||||||
Text: ""
|
Text: ""
|
||||||
TextColor3: Color3.new 1, 1, 1
|
TextColor3: Color3.new 1, 1, 1
|
||||||
TextWrap: true
|
TextWrap: true
|
||||||
TextXAlignment: Enum.TextXAlignment.Left
|
TextXAlignment: Enum.TextXAlignment.Left
|
||||||
TextYAlignment: Enum.TextYAlignment.Top
|
TextYAlignment: Enum.TextYAlignment.Top
|
||||||
|
|
||||||
* New "Frame", "Sets"
|
* New "Frame", "Sets"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Position: UDim2.new 0, 0, 0, 5
|
Position: UDim2.new 0, 0, 0, 5
|
||||||
Size: UDim2.new 0.23, 0, 1, -5
|
Size: UDim2.new 0.23, 0, 1, -5
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "Frame", "Line"
|
* New "Frame", "Line"
|
||||||
BackgroundColor3: Color3.new 1, 1, 1
|
BackgroundColor3: Color3.new 1, 1, 1
|
||||||
BackgroundTransparency: 0.7
|
BackgroundTransparency: 0.7
|
||||||
BorderSizePixel: 0
|
BorderSizePixel: 0
|
||||||
Position: UDim2.new 1, -3, 0.06, 0
|
Position: UDim2.new 1, -3, 0.06, 0
|
||||||
Size: UDim2.new 0, 3, 0.9, 0
|
Size: UDim2.new 0, 3, 0.9, 0
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "TextLabel", "SetsHeader"
|
* New "TextLabel", "SetsHeader"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Size: UDim2.new 0, 47, 0, 24
|
Size: UDim2.new 0, 47, 0, 24
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
Font: Enum.Font.ArialBold
|
Font: Enum.Font.ArialBold
|
||||||
FontSize: Enum.FontSize.Size24
|
FontSize: Enum.FontSize.Size24
|
||||||
|
|
@ -2304,8 +2304,8 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
|
|
||||||
setsLists, controlFrame = t.CreateTrueScrollingFrame!
|
setsLists, controlFrame = t.CreateTrueScrollingFrame!
|
||||||
with setsLists
|
with setsLists
|
||||||
.Size = UDim2.new 1, -6, 0.94, 0
|
.Size = UDim2.new 1, -6, 0.94, 0
|
||||||
.Position = UDim2.new 0, 0, 0.06, 0
|
.Position = UDim2.new 0, 0, 0.06, 0
|
||||||
.BackgroundTransparency = 1
|
.BackgroundTransparency = 1
|
||||||
.Name = "SetsLists"
|
.Name = "SetsLists"
|
||||||
.ZIndex = 6
|
.ZIndex = 6
|
||||||
|
|
@ -2321,7 +2321,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
BackgroundColor3: Color3.new 1, 1, 1
|
BackgroundColor3: Color3.new 1, 1, 1
|
||||||
BorderSizePixel: 0
|
BorderSizePixel: 0
|
||||||
Size: UDim2.new 1, -5, 0, 18
|
Size: UDim2.new 1, -5, 0, 18
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
Visible: false
|
Visible: false
|
||||||
Font: Enum.Font.Arial
|
Font: Enum.Font.Arial
|
||||||
|
|
@ -2332,7 +2332,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
setButton
|
setButton
|
||||||
|
|
||||||
buildSetButton = (name, setId, _, _, _) ->
|
buildSetButton = (name, setId, _, _, _) ->
|
||||||
button = createSetButton name
|
button = createSetButton name
|
||||||
with button
|
with button
|
||||||
.Text = name
|
.Text = name
|
||||||
.Name = "SetButton"
|
.Name = "SetButton"
|
||||||
|
|
@ -2355,7 +2355,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
if not showAdminCategories and sets[i].Name == "Beta"
|
if not showAdminCategories and sets[i].Name == "Beta"
|
||||||
numSkipped += 1
|
numSkipped += 1
|
||||||
else
|
else
|
||||||
setButtons[i - numSkipped] = buildSetButton sets[i].Name, sets[i].CategoryId, sets[i].ImageAssetId, i - numSkipped, #sets
|
setButtons[i - numSkipped] = buildSetButton sets[i].Name, sets[i].CategoryId, sets[i].ImageAssetId, i - numSkipped, #sets
|
||||||
|
|
||||||
setButtons
|
setButtons
|
||||||
|
|
||||||
|
|
@ -2385,22 +2385,22 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
* New "TextButton", "Button"
|
* New "TextButton", "Button"
|
||||||
Text: ""
|
Text: ""
|
||||||
Style: Enum.ButtonStyle.RobloxButton
|
Style: Enum.ButtonStyle.RobloxButton
|
||||||
Position: UDim2.new 0.025, 0, 0.025, 0
|
Position: UDim2.new 0.025, 0, 0.025, 0
|
||||||
Size: UDim2.new 0.95, 0, 0.95, 0
|
Size: UDim2.new 0.95, 0, 0.95, 0
|
||||||
ZIndex: 6
|
ZIndex: 6
|
||||||
|
|
||||||
* New "ImageLabel", "ButtonImage"
|
* New "ImageLabel", "ButtonImage"
|
||||||
Image: ""
|
Image: ""
|
||||||
Position: UDim2.new 0, -7, 0, -7
|
Position: UDim2.new 0, -7, 0, -7
|
||||||
Size: UDim2.new 1, 14, 1, 14
|
Size: UDim2.new 1, 14, 1, 14
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
ZIndex: 7
|
ZIndex: 7
|
||||||
|
|
||||||
with insertAssetButtonExample.button.ButtonImage\clone!
|
with insertAssetButtonExample.button.ButtonImage\clone!
|
||||||
.Name = "ConfigIcon"
|
.Name = "ConfigIcon"
|
||||||
.Visible = false
|
.Visible = false
|
||||||
.Position = UDim2.new 1, -23, 1, -24
|
.Position = UDim2.new 1, -23, 1, -24
|
||||||
.Size = UDim2.new 0, 16, 0, 16
|
.Size = UDim2.new 0, 16, 0, 16
|
||||||
.Image = ""
|
.Image = ""
|
||||||
.ZIndex = 6
|
.ZIndex = 6
|
||||||
.Parent = insertAssetButtonExample
|
.Parent = insertAssetButtonExample
|
||||||
|
|
@ -2434,7 +2434,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
TextXAlignment: Enum.TextXAlignment.Left
|
TextXAlignment: Enum.TextXAlignment.Left
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
ZIndex: parent.ZIndex + 1
|
ZIndex: parent.ZIndex + 1
|
||||||
Size: UDim2.new 0, parent.Size.X.Offset - 2, 0, 16
|
Size: UDim2.new 0, parent.Size.X.Offset - 2, 0, 16
|
||||||
Position: UDim2.new 0, 1, 0, 0
|
Position: UDim2.new 0, 1, 0, 0
|
||||||
|
|
||||||
with dropDownTextButton
|
with dropDownTextButton
|
||||||
|
|
@ -2452,24 +2452,24 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
if .Parent and .Parent\IsA "GuiObject"
|
if .Parent and .Parent\IsA "GuiObject"
|
||||||
.Parent.Visible = false
|
.Parent.Visible = false
|
||||||
|
|
||||||
selectTerrainShape terrainShapeMap[.Text]
|
selectTerrainShape terrainShapeMap[.Text]
|
||||||
|
|
||||||
dropDownTextButton
|
dropDownTextButton
|
||||||
|
|
||||||
createTerrainDropDownMenu = (zIndex) ->
|
createTerrainDropDownMenu = (zIndex) ->
|
||||||
dropDown = New "Frame", "TerrainDropDown"
|
dropDown = New "Frame", "TerrainDropDown"
|
||||||
BackgroundColor3: Color3.new 0, 0, 0
|
BackgroundColor3: Color3.new 0, 0, 0
|
||||||
BorderColor3: Color3.new 1, 0, 0
|
BorderColor3: Color3.new 1, 0, 0
|
||||||
Size: UDim2.new 0, 200, 0, 0
|
Size: UDim2.new 0, 200, 0, 0
|
||||||
Visible: false
|
Visible: false
|
||||||
ZIndex: zIndex
|
ZIndex: zIndex
|
||||||
Parent: setGui
|
Parent: setGui
|
||||||
|
|
||||||
for i = 1, #terrainShapes
|
for i = 1, #terrainShapes
|
||||||
shapeButton = createTerrainTypeButton terrainShapes[i], dropDown
|
shapeButton = createTerrainTypeButton terrainShapes[i], dropDown
|
||||||
shapeButton.Position = UDim2.new 0, 1, 0, (i - 1) * shapeButton.Size.Y.Offset
|
shapeButton.Position = UDim2.new 0, 1, 0, (i - 1) * shapeButton.Size.Y.Offset
|
||||||
shapeButton.Parent = dropDown
|
shapeButton.Parent = dropDown
|
||||||
dropDown.Size = UDim2.new 0, 200, 0, dropDown.Size.Y.Offset + shapeButton.Size.Y.Offset
|
dropDown.Size = UDim2.new 0, 200, 0, dropDown.Size.Y.Offset + shapeButton.Size.Y.Offset
|
||||||
|
|
||||||
dropDown.MouseLeave\connect ->
|
dropDown.MouseLeave\connect ->
|
||||||
dropDown.Visible = false
|
dropDown.Visible = false
|
||||||
|
|
@ -2480,12 +2480,12 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
Image: "http://www.roblox.com/asset/?id=67581509"
|
Image: "http://www.roblox.com/asset/?id=67581509"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
Size: UDim2.new 0, 16, 0, 16
|
Size: UDim2.new 0, 16, 0, 16
|
||||||
Position: UDim2.new 1, -24, 0, 6
|
Position: UDim2.new 1, -24, 0, 6
|
||||||
ZIndex: parent.ZIndex + 2
|
ZIndex: parent.ZIndex + 2
|
||||||
Parent: parent
|
Parent: parent
|
||||||
|
|
||||||
if not setGui\FindFirstChild "TerrainDropDown"
|
if not setGui\FindFirstChild "TerrainDropDown"
|
||||||
createTerrainDropDownMenu 8
|
createTerrainDropDownMenu 8
|
||||||
|
|
||||||
dropDownButton.MouseButton1Click\connect ->
|
dropDownButton.MouseButton1Click\connect ->
|
||||||
setGui.TerrainDropDown.Visible = true
|
setGui.TerrainDropDown.Visible = true
|
||||||
|
|
@ -2498,14 +2498,14 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
insertButton.Visible = true
|
insertButton.Visible = true
|
||||||
|
|
||||||
if Data.Category[Data.CurrentCategory].SetName == "High Scalability"
|
if Data.Category[Data.CurrentCategory].SetName == "High Scalability"
|
||||||
createDropDownMenuButton insertButton
|
createDropDownMenuButton insertButton
|
||||||
|
|
||||||
lastEnter = nil
|
lastEnter = nil
|
||||||
mouseEnterCon = insertButton.MouseEnter\connect ->
|
mouseEnterCon = insertButton.MouseEnter\connect ->
|
||||||
lastEnter = insertButton
|
lastEnter = insertButton
|
||||||
delay 0.1, ->
|
delay 0.1, ->
|
||||||
if lastEnter == insertButton
|
if lastEnter == insertButton
|
||||||
showLargePreview insertButton
|
showLargePreview insertButton
|
||||||
|
|
||||||
insertButton, mouseEnterCon
|
insertButton, mouseEnterCon
|
||||||
|
|
||||||
|
|
@ -2528,16 +2528,16 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
delay 0, ->
|
delay 0, ->
|
||||||
game\GetService("ContentProvider")\Preload(SmallThumbnailUrl .. assetId)
|
game\GetService("ContentProvider")\Preload(SmallThumbnailUrl .. assetId)
|
||||||
insertFrame.Button.ButtonImage.Image = SmallThumbnailUrl .. assetId
|
insertFrame.Button.ButtonImage.Image = SmallThumbnailUrl .. assetId
|
||||||
|
|
||||||
table.insert(
|
table.insert(
|
||||||
insertButtonCons,
|
insertButtonCons,
|
||||||
insertFrame.Button.MouseButton1Click\connect ->
|
insertFrame.Button.MouseButton1Click\connect ->
|
||||||
-- special case for water, show water selection gui
|
-- special case for water, show water selection gui
|
||||||
isWaterSelected = name == "Water" and
|
isWaterSelected = name == "Water" and
|
||||||
(Data.Category[Data.CurrentCategory].SetName == "High Scalability")
|
(Data.Category[Data.CurrentCategory].SetName == "High Scalability")
|
||||||
waterGui.Visible = isWaterSelected
|
waterGui.Visible = isWaterSelected
|
||||||
objectSelected name, if isWaterSelected
|
objectSelected name, if isWaterSelected
|
||||||
tonumber(assetId), nil
|
tonumber(assetId), nil
|
||||||
else
|
else
|
||||||
tonumber assetId
|
tonumber assetId
|
||||||
|
|
||||||
|
|
@ -2563,14 +2563,14 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
insertButtons[arrayPosition].Parent = setGui.SetPanel.ItemsFrame
|
insertButtons[arrayPosition].Parent = setGui.SetPanel.ItemsFrame
|
||||||
arrayPosition += 1
|
arrayPosition += 1
|
||||||
|
|
||||||
realignButtonGrid columns
|
realignButtonGrid columns
|
||||||
|
|
||||||
-- indexCopy = origArrayPos
|
-- indexCopy = origArrayPos
|
||||||
for index = origArrayPos, arrayPosition
|
for index = origArrayPos, arrayPosition
|
||||||
if insertButtons[index]
|
if insertButtons[index]
|
||||||
if contents[index]
|
if contents[index]
|
||||||
-- we don't want water to have a drop down button
|
-- we don't want water to have a drop down button
|
||||||
if contents[index].Name == "Water" and
|
if contents[index].Name == "Water" and
|
||||||
Data.Category[Data.CurrentCategory].SetName == "High Scalability"
|
Data.Category[Data.CurrentCategory].SetName == "High Scalability"
|
||||||
insertButtons[index]\FindFirstChild("DropDownButton", true)\Destroy!
|
insertButtons[index]\FindFirstChild("DropDownButton", true)\Destroy!
|
||||||
|
|
||||||
|
|
@ -2580,7 +2580,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
else
|
else
|
||||||
contents[index].AssetId
|
contents[index].AssetId
|
||||||
|
|
||||||
setInsertButtonImageBehavior insertButtons[index], true, contents[index].Name, assetId
|
setInsertButtonImageBehavior insertButtons[index], true, contents[index].Name, assetId
|
||||||
else break
|
else break
|
||||||
else break
|
else break
|
||||||
|
|
||||||
|
|
@ -2590,7 +2590,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
Data.Category[Data.CurrentCategory].Index = 0
|
Data.Category[Data.CurrentCategory].Index = 0
|
||||||
|
|
||||||
rows = 7
|
rows = 7
|
||||||
columns = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.X / buttonWidth
|
columns = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.X / buttonWidth
|
||||||
|
|
||||||
contents = Data.Category[Data.CurrentCategory].Contents
|
contents = Data.Category[Data.CurrentCategory].Contents
|
||||||
if contents
|
if contents
|
||||||
|
|
@ -2607,7 +2607,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
insertButtons = {}
|
insertButtons = {}
|
||||||
|
|
||||||
arrayPosition = 1
|
arrayPosition = 1
|
||||||
loadSectionOfItems setGui, rows, columns
|
loadSectionOfItems setGui, rows, columns
|
||||||
|
|
||||||
selectSet = (button, setName, setId, _) ->
|
selectSet = (button, setName, setId, _) ->
|
||||||
if button and Data.Category[Data.CurrentCategory]?
|
if button and Data.Category[Data.CurrentCategory]?
|
||||||
|
|
@ -2627,7 +2627,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
selectCategoryPage = (buttons, _) ->
|
selectCategoryPage = (buttons, _) ->
|
||||||
if buttons ~= Data.CurrentCategory
|
if buttons ~= Data.CurrentCategory
|
||||||
if Data.CurrentCategory
|
if Data.CurrentCategory
|
||||||
for _, button in pairs Data.CurrentCategory
|
for _, button in pairs Data.CurrentCategory
|
||||||
button.Visible = false
|
button.Visible = false
|
||||||
|
|
||||||
Data.CurrentCategory = buttons
|
Data.CurrentCategory = buttons
|
||||||
|
|
@ -2646,7 +2646,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
)
|
)
|
||||||
|
|
||||||
selectCategory = (category) ->
|
selectCategory = (category) ->
|
||||||
selectCategoryPage category, 0
|
selectCategoryPage category, 0
|
||||||
|
|
||||||
resetAllSetButtonSelection = ->
|
resetAllSetButtonSelection = ->
|
||||||
setButtons = setGui.SetPanel.Sets.SetsLists\GetChildren!
|
setButtons = setGui.SetPanel.Sets.SetsLists\GetChildren!
|
||||||
|
|
@ -2662,12 +2662,12 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
|
|
||||||
for i = 1, #userCategoryButtons do with button = userCategoryButtons[i]
|
for i = 1, #userCategoryButtons do with button = userCategoryButtons[i]
|
||||||
.Visible = true
|
.Visible = true
|
||||||
.Position = UDim2.new 0, 5, 0, currRow * .Size.Y.Offset
|
.Position = UDim2.new 0, 5, 0, currRow * .Size.Y.Offset
|
||||||
.Parent = setGui.SetPanel.Sets.SetsLists
|
.Parent = setGui.SetPanel.Sets.SetsLists
|
||||||
|
|
||||||
if i == 1 -- we will have this selected by default, so show it
|
if i == 1 -- we will have this selected by default, so show it
|
||||||
.Selected = true
|
.Selected = true
|
||||||
.BackgroundColor3 = Color3.new 0, 204 / 255, 0
|
.BackgroundColor3 = Color3.new 0, 204 / 255, 0
|
||||||
.TextColor3 = Color3.new 0, 0, 0
|
.TextColor3 = Color3.new 0, 0, 0
|
||||||
.BackgroundTransparency = 0
|
.BackgroundTransparency = 0
|
||||||
|
|
||||||
|
|
@ -2684,10 +2684,10 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
.MouseButton1Click\connect ->
|
.MouseButton1Click\connect ->
|
||||||
resetAllSetButtonSelection!
|
resetAllSetButtonSelection!
|
||||||
.Selected = not .Selected
|
.Selected = not .Selected
|
||||||
.BackgroundColor3 = Color3.new 0, 204 / 255, 0
|
.BackgroundColor3 = Color3.new 0, 204 / 255, 0
|
||||||
.TextColor3 = Color3.new 0, 0, 0
|
.TextColor3 = Color3.new 0, 0, 0
|
||||||
.BackgroundTransparency = 0
|
.BackgroundTransparency = 0
|
||||||
selectSet button, .Text, userCategoryButtons[i].SetId.Value, 0
|
selectSet button, .Text, userCategoryButtons[i].SetId.Value, 0
|
||||||
|
|
||||||
currRow += 1
|
currRow += 1
|
||||||
|
|
||||||
|
|
@ -2697,8 +2697,8 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
if buttons
|
if buttons
|
||||||
for i = 1, #buttons
|
for i = 1, #buttons
|
||||||
if buttons[i]\IsA "TextButton"
|
if buttons[i]\IsA "TextButton"
|
||||||
selectSet buttons[i], buttons[i].Text, userCategoryButtons[i].SetId.Value, 0
|
selectSet buttons[i], buttons[i].Text, userCategoryButtons[i].SetId.Value, 0
|
||||||
selectCategory userCategoryButtons
|
selectCategory userCategoryButtons
|
||||||
break
|
break
|
||||||
|
|
||||||
setGui = createSetGui!
|
setGui = createSetGui!
|
||||||
|
|
@ -2719,22 +2719,22 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
.Parent = setGui.SetPanel
|
.Parent = setGui.SetPanel
|
||||||
.BackgroundTransparency = 1
|
.BackgroundTransparency = 1
|
||||||
|
|
||||||
drillDownSetZIndex controlFrame, 7
|
drillDownSetZIndex controlFrame, 7
|
||||||
|
|
||||||
controlFrame.Parent = setGui.SetPanel
|
controlFrame.Parent = setGui.SetPanel
|
||||||
controlFrame.Position = UDim2.new 0.76, 5, 0, 0
|
controlFrame.Position = UDim2.new 0.76, 5, 0, 0
|
||||||
|
|
||||||
debounce = false
|
debounce = false
|
||||||
|
|
||||||
rows = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.Y / buttonHeight
|
rows = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.Y / buttonHeight
|
||||||
columns = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.X / buttonWidth
|
columns = math.floor setGui.SetPanel.ItemsFrame.AbsoluteSize.X / buttonWidth
|
||||||
|
|
||||||
controlFrame.ScrollBottom.Changed\connect (_) ->
|
controlFrame.ScrollBottom.Changed\connect (_) ->
|
||||||
if controlFrame.ScrollBottom.Value == true
|
if controlFrame.ScrollBottom.Value == true
|
||||||
return if debounce
|
return if debounce
|
||||||
|
|
||||||
debounce = true
|
debounce = true
|
||||||
loadSectionOfItems setGui, rows, columns
|
loadSectionOfItems setGui, rows, columns
|
||||||
debounce = false
|
debounce = false
|
||||||
|
|
||||||
userData = {}
|
userData = {}
|
||||||
|
|
@ -2749,7 +2749,7 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
||||||
newUserData[category]
|
newUserData[category]
|
||||||
|
|
||||||
if userData
|
if userData
|
||||||
userCategoryButtons = processCategory userData
|
userCategoryButtons = processCategory userData
|
||||||
|
|
||||||
populateSetsFrame!
|
populateSetsFrame!
|
||||||
|
|
||||||
|
|
@ -2788,7 +2788,7 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
-- waterEnabled = true -- todo: turn this on when water is ready
|
-- waterEnabled = true -- todo: turn this on when water is ready
|
||||||
|
|
||||||
materialToImageMap = {}
|
materialToImageMap = {}
|
||||||
materialNames =
|
materialNames =
|
||||||
* "Grass"
|
* "Grass"
|
||||||
* "Sand"
|
* "Sand"
|
||||||
* "Brick"
|
* "Brick"
|
||||||
|
|
@ -2837,11 +2837,11 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
when Enum.CellMaterial.Water, 17 then "Water"
|
when Enum.CellMaterial.Water, 17 then "Water"
|
||||||
|
|
||||||
updateMaterialChoice = (choice) ->
|
updateMaterialChoice = (choice) ->
|
||||||
currentMaterial = getEnumFromName choice
|
currentMaterial = getEnumFromName choice
|
||||||
terrainMaterialSelectionChanged\Fire currentMaterial
|
terrainMaterialSelectionChanged\Fire currentMaterial
|
||||||
|
|
||||||
-- we so need a better way to do this
|
-- we so need a better way to do this
|
||||||
for _, v in pairs materialNames
|
for _, v in pairs materialNames
|
||||||
materialToImageMap[v] = {}
|
materialToImageMap[v] = {}
|
||||||
materialToImageMap[v].Regular = "http://www.roblox.com/asset/?id=#{switch v
|
materialToImageMap[v].Regular = "http://www.roblox.com/asset/?id=#{switch v
|
||||||
when "Grass" then 56563112
|
when "Grass" then 56563112
|
||||||
|
|
@ -2861,29 +2861,29 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
when "Stone Wall" then 67531804
|
when "Stone Wall" then 67531804
|
||||||
when "Concrete" then 67532059
|
when "Concrete" then 67532059
|
||||||
when "Water" then 81407474
|
when "Water" then 81407474
|
||||||
else 66887593}"
|
else 66887593}"
|
||||||
|
|
||||||
-- fill in the rest here!!
|
-- fill in the rest here!!
|
||||||
|
|
||||||
scrollFrame, scrollUp, scrollDown, recalculateScroll = t.CreateScrollingFrame nil, "grid"
|
scrollFrame, scrollUp, scrollDown, recalculateScroll = t.CreateScrollingFrame nil, "grid"
|
||||||
|
|
||||||
with scrollFrame
|
with scrollFrame
|
||||||
.Size = UDim2.new 0.85, 0, 1, 0
|
.Size = UDim2.new 0.85, 0, 1, 0
|
||||||
.Position = UDim2.new 0, 0, 0, 0
|
.Position = UDim2.new 0, 0, 0, 0
|
||||||
.Parent = frame
|
.Parent = frame
|
||||||
|
|
||||||
with scrollUp
|
with scrollUp
|
||||||
.Parent = frame
|
.Parent = frame
|
||||||
.Visible = true
|
.Visible = true
|
||||||
.Position = UDim2.new 1, -19, 0, 0
|
.Position = UDim2.new 1, -19, 0, 0
|
||||||
|
|
||||||
with scrollDown
|
with scrollDown
|
||||||
.Parent = frame
|
.Parent = frame
|
||||||
.Visible = true
|
.Visible = true
|
||||||
.Position = UDim2.new 1, -19, 1, -17
|
.Position = UDim2.new 1, -19, 1, -17
|
||||||
|
|
||||||
goToNewMaterial = (buttonWrap, materialName) ->
|
goToNewMaterial = (buttonWrap, materialName) ->
|
||||||
updateMaterialChoice materialName
|
updateMaterialChoice materialName
|
||||||
buttonWrap.BackgroundTransparency = 0
|
buttonWrap.BackgroundTransparency = 0
|
||||||
selectedButton.BackgroundTransparency = 1
|
selectedButton.BackgroundTransparency = 1
|
||||||
selectedButton = buttonWrap
|
selectedButton = buttonWrap
|
||||||
|
|
@ -2891,8 +2891,8 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
createMaterialButton = (name) ->
|
createMaterialButton = (name) ->
|
||||||
buttonWrap = New "TextButton", "#{name}"
|
buttonWrap = New "TextButton", "#{name}"
|
||||||
Text: ""
|
Text: ""
|
||||||
Size: UDim2.new 0, 32, 0, 32
|
Size: UDim2.new 0, 32, 0, 32
|
||||||
BackgroundColor3: Color3.new 1, 1, 1
|
BackgroundColor3: Color3.new 1, 1, 1
|
||||||
BorderSizePixel: 0
|
BorderSizePixel: 0
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
AutoButtonColor: false
|
AutoButtonColor: false
|
||||||
|
|
@ -2920,7 +2920,7 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
buttonWrap
|
buttonWrap
|
||||||
|
|
||||||
for i = 1, #materialNames
|
for i = 1, #materialNames
|
||||||
imageButton = createMaterialButton materialNames[i]
|
imageButton = createMaterialButton materialNames[i]
|
||||||
|
|
||||||
if materialNames[i] == "Grass" then -- always start with grass as the default
|
if materialNames[i] == "Grass" then -- always start with grass as the default
|
||||||
selectedButton = imageButton
|
selectedButton = imageButton
|
||||||
|
|
@ -2932,13 +2932,13 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
||||||
return if not newMaterialType
|
return if not newMaterialType
|
||||||
return if currentMaterial == newMaterialType
|
return if currentMaterial == newMaterialType
|
||||||
|
|
||||||
matName = getNameFromEnum newMaterialType
|
matName = getNameFromEnum newMaterialType
|
||||||
buttons = scrollFrame\GetChildren!
|
buttons = scrollFrame\GetChildren!
|
||||||
for i = 1, #buttons
|
for i = 1, #buttons
|
||||||
if (buttons[i].Name == "Plastic (blue)" and matName == "Plastic (blue)") or
|
if (buttons[i].Name == "Plastic (blue)" and matName == "Plastic (blue)") or
|
||||||
(buttons[i].Name == "Plastic (red)" and matName == "Plastic (red)") or
|
(buttons[i].Name == "Plastic (red)" and matName == "Plastic (red)") or
|
||||||
(string.find buttons[i].Name, matName)
|
(string.find buttons[i].Name, matName)
|
||||||
goToNewMaterial buttons[i], matName
|
goToNewMaterial buttons[i], matName
|
||||||
return
|
return
|
||||||
|
|
||||||
frame.Changed\connect (prop) ->
|
frame.Changed\connect (prop) ->
|
||||||
|
|
@ -2953,8 +2953,8 @@ t.CreateLoadingFrame = (name, size, position) ->
|
||||||
|
|
||||||
loadingFrame = New "Frame", "LoadingFrame"
|
loadingFrame = New "Frame", "LoadingFrame"
|
||||||
Style: Enum.FrameStyle.RobloxRound
|
Style: Enum.FrameStyle.RobloxRound
|
||||||
Size: size or UDim2.new 0, 300, 0, 160
|
Size: size or UDim2.new 0, 300, 0, 160
|
||||||
Position: position or UDim2.new 0.5, -150, 0.5, -80
|
Position: position or UDim2.new 0.5, -150, 0.5, -80
|
||||||
|
|
||||||
* New "TextLabel", "loadingName"
|
* New "TextLabel", "loadingName"
|
||||||
BackgroundTransparency: 1
|
BackgroundTransparency: 1
|
||||||
|
|
@ -2994,7 +2994,7 @@ t.CreateLoadingFrame = (name, size, position) ->
|
||||||
Font: Enum.Font.Arial
|
Font: Enum.Font.Arial
|
||||||
Text: "0%"
|
Text: "0%"
|
||||||
FontSize: Enum.FontSize.Size14
|
FontSize: Enum.FontSize.Size14
|
||||||
TextColor3: Color3.new 1, 1, 1
|
TextColor3: Color3.new 1, 1, 1
|
||||||
|
|
||||||
{ -- Destructure
|
{ -- Destructure
|
||||||
CancelButton: cancelButton
|
CancelButton: cancelButton
|
||||||
|
|
@ -3072,7 +3072,7 @@ t.CreatePluginFrame = (name, size, position, scrollable, parent) ->
|
||||||
BackgroundColor3: Color3.new 39 / 255, 39 / 255, 39 / 255
|
BackgroundColor3: Color3.new 39 / 255, 39 / 255, 39 / 255
|
||||||
BorderColor3: Color3.new 0, 0, 0
|
BorderColor3: Color3.new 0, 0, 0
|
||||||
Size: if size
|
Size: if size
|
||||||
UDim2.new(size.X.Scale, size.X.Offset, 0, 20) + UDim2.new 0, 20, 0, 0
|
UDim2.new(size.X.Scale, size.X.Offset, 0, 20) + UDim2.new 0, 20, 0, 0
|
||||||
else
|
else
|
||||||
UDim2.new 0, 183, 0, 20
|
UDim2.new 0, 183, 0, 20
|
||||||
Active: true
|
Active: true
|
||||||
|
|
@ -3108,7 +3108,7 @@ t.CreatePluginFrame = (name, size, position, scrollable, parent) ->
|
||||||
BorderColor3: Color3.new 0, 0, 0
|
BorderColor3: Color3.new 0, 0, 0
|
||||||
Position: UDim2.new 0, 0, 1, 0
|
Position: UDim2.new 0, 0, 1, 0
|
||||||
Size: if size
|
Size: if size
|
||||||
UDim2.new(size.X.Scale, size.X.Offset, 0, 50) + UDim2.new 0, 20, 0, 0
|
UDim2.new(size.X.Scale, size.X.Offset, 0, 50) + UDim2.new 0, 20, 0, 0
|
||||||
else
|
else
|
||||||
UDim2.new 0, 183, 0, 50
|
UDim2.new 0, 183, 0, 50
|
||||||
Visible: false
|
Visible: false
|
||||||
|
|
@ -3294,7 +3294,7 @@ t.CreatePluginFrame = (name, size, position, scrollable, parent) ->
|
||||||
ZIndex: 10
|
ZIndex: 10
|
||||||
Visible: false
|
Visible: false
|
||||||
Active: true
|
Active: true
|
||||||
Parent: getScreenGuiAncestor parent
|
Parent: getScreenGuiAncestor parent
|
||||||
|
|
||||||
draggingVertical = false
|
draggingVertical = false
|
||||||
local startYPos
|
local startYPos
|
||||||
|
|
@ -3393,7 +3393,7 @@ t.Help = (funcNameOrFunc) ->
|
||||||
when 'CreateScrollingFrame', t.CreateScrollingFrame
|
when 'CreateScrollingFrame', t.CreateScrollingFrame
|
||||||
'Function CreateScrollingFrame. ' ..
|
'Function CreateScrollingFrame. ' ..
|
||||||
'Arguments: (orderList, style) ' ..
|
'Arguments: (orderList, style) ' ..
|
||||||
'Side effect: returns 4 objects, (scrollFrame, scrollUpButton, scrollDownButton, recalculateFunction). "scrollFrame" can be filled with GuiObjects. It will lay them out and allow scrollUpButton/scrollDownButton to interact with them. Orderlist is optional (and specifies the order to layout the children. Without orderlist, it uses the children order. style is also optional, and allows for a "grid" styling if style is passed "grid" as a string. recalculateFunction can be called
|
'Side effect: returns 4 objects, (scrollFrame, scrollUpButton, scrollDownButton, recalculateFunction). "scrollFrame" can be filled with GuiObjects. It will lay them out and allow scrollUpButton/scrollDownButton to interact with them. Orderlist is optional (and specifies the order to layout the children. Without orderlist, it uses the children order. style is also optional, and allows for a "grid" styling if style is passed "grid" as a string. recalculateFunction can be called
|
||||||
when a relayout is needed (
|
when a relayout is needed (
|
||||||
when orderList changes)'
|
when orderList changes)'
|
||||||
|
|
||||||
|
|
@ -3415,7 +3415,7 @@ t.Help = (funcNameOrFunc) ->
|
||||||
when 'CreateLoadingFrame', t.CreateLoadingFrame
|
when 'CreateLoadingFrame', t.CreateLoadingFrame
|
||||||
'Function CreateLoadingFrame. ' ..
|
'Function CreateLoadingFrame. ' ..
|
||||||
'Arguments: (name, size, position) ' ..
|
'Arguments: (name, size, position) ' ..
|
||||||
'Side effect: Creates a gui that can be manipulated to show progress for a particular action. Name appears above the loading bar, and size and position are udim2 values (both size and position are optional arguments). Returns 3 arguments, the first being the gui created. The second being updateLoadingGuiPercent, which is a bindable function. This function takes one argument (two optionally), which should be a number between 0 and 1, representing the percentage the loading gui should be at. The second argument to this function is a boolean value that if set to true will tween the current percentage value to the new percentage value, therefore our third argument is how long this tween should take. Our third returned argument is a BindableEvent, that
|
'Side effect: Creates a gui that can be manipulated to show progress for a particular action. Name appears above the loading bar, and size and position are udim2 values (both size and position are optional arguments). Returns 3 arguments, the first being the gui created. The second being updateLoadingGuiPercent, which is a bindable function. This function takes one argument (two optionally), which should be a number between 0 and 1, representing the percentage the loading gui should be at. The second argument to this function is a boolean value that if set to true will tween the current percentage value to the new percentage value, therefore our third argument is how long this tween should take. Our third returned argument is a BindableEvent, that
|
||||||
when fired means that someone clicked the cancel button on the dialog.'
|
when fired means that someone clicked the cancel button on the dialog.'
|
||||||
|
|
||||||
when 'CreateTerrainMaterialSelector', t.CreateTerrainMaterialSelector
|
when 'CreateTerrainMaterialSelector', t.CreateTerrainMaterialSelector
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ waitForProperty = (instance, property) ->
|
||||||
instance.Changed\wait!
|
instance.Changed\wait!
|
||||||
|
|
||||||
waitForChild = (instance, name) ->
|
waitForChild = (instance, name) ->
|
||||||
until instance\FindFirstChild name
|
until instance\FindFirstChild name
|
||||||
instance.ChildAdded\wait!
|
instance.ChildAdded\wait!
|
||||||
|
|
||||||
waitForProperty game.Players, "LocalPlayer"
|
waitForProperty game.Players, "LocalPlayer"
|
||||||
|
|
@ -111,7 +111,7 @@ game.Players.FriendRequestEvent\connect (fromPlayer, toPlayer, event) ->
|
||||||
"From #{fromPlayer.Name}",
|
"From #{fromPlayer.Name}",
|
||||||
"http://www.roblox.com/thumbs/avatar.ashx?userId=#{fromPlayer.userId}&x=48&y=48",
|
"http://www.roblox.com/thumbs/avatar.ashx?userId=#{fromPlayer.userId}&x=48&y=48",
|
||||||
8,
|
8,
|
||||||
-> makeFriend fromPlayer, toPlayer
|
-> makeFriend fromPlayer, toPlayer
|
||||||
)
|
)
|
||||||
elseif event == Enum.FriendRequestEvent.Accept
|
elseif event == Enum.FriendRequestEvent.Accept
|
||||||
game\GetService("GuiService")\SendNotification(
|
game\GetService("GuiService")\SendNotification(
|
||||||
|
|
@ -197,7 +197,7 @@ if teleportEnabled
|
||||||
yesCon?\disconnect!
|
yesCon?\disconnect!
|
||||||
noCon?\disconnect!
|
noCon?\disconnect!
|
||||||
|
|
||||||
game.GuiService\RemoveCenterDialog script.Parent\FindFirstChild "Popup"
|
game.GuiService\RemoveCenterDialog script.Parent\FindFirstChild "Popup"
|
||||||
popup\TweenSize(
|
popup\TweenSize(
|
||||||
UDim2.new(0, 0, 0, 0),
|
UDim2.new(0, 0, 0, 0),
|
||||||
Enum.EasingDirection.Out,
|
Enum.EasingDirection.Out,
|
||||||
|
|
@ -216,7 +216,7 @@ if teleportEnabled
|
||||||
popup.PopupText.Text = err
|
popup.PopupText.Text = err
|
||||||
local clickCon = popup.OKButton.MouseButton1Click\connect ->
|
local clickCon = popup.OKButton.MouseButton1Click\connect ->
|
||||||
clickCon?\disconnect!
|
clickCon?\disconnect!
|
||||||
game.GuiService\RemoveCenterDialog script.Parent\FindFirstChild "Popup"
|
game.GuiService\RemoveCenterDialog script.Parent\FindFirstChild "Popup"
|
||||||
popup\TweenSize(
|
popup\TweenSize(
|
||||||
UDim2.new(0, 0, 0, 0),
|
UDim2.new(0, 0, 0, 0),
|
||||||
Enum.EasingDirection.Out,
|
Enum.EasingDirection.Out,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue