Improve formatting of corescripts
This commit is contained in:
parent
b7200e253f
commit
37d28a3999
|
|
@ -115,8 +115,8 @@ getRbxUtility = ->
|
|||
|
||||
|
||||
preloadAssets = ->
|
||||
for i = 1, #assetUrls
|
||||
game\GetService"ContentProvider"\Preload assetUrls[i]
|
||||
for i in *assetUrls
|
||||
game\GetService"ContentProvider"\Preload i
|
||||
|
||||
|
||||
----------------------------- End Util Functions ---------------------------------------------
|
||||
|
|
@ -157,12 +157,12 @@ setButtonsVisible = (...) ->
|
|||
argCount = select "#", ...
|
||||
|
||||
bodyFrameChildren = purchaseDialog.BodyFrame\GetChildren!
|
||||
for i = 1, #bodyFrameChildren
|
||||
if bodyFrameChildren[i]\IsA "GuiButton"
|
||||
bodyFrameChildren[i].Visible = false
|
||||
for i in *bodyFrameChildren
|
||||
if i\IsA "GuiButton"
|
||||
i.Visible = false
|
||||
for j = 1, argCount
|
||||
if bodyFrameChildren[i] == args[j]
|
||||
bodyFrameChildren[i].Visible = true
|
||||
if i == args[j]
|
||||
i.Visible = true
|
||||
break
|
||||
|
||||
signalPromptEnded = (isSuccess) ->
|
||||
|
|
@ -611,9 +611,9 @@ getToolAssetID = (assetID) ->
|
|||
return newTool
|
||||
|
||||
toolChildren = newTool\GetChildren!
|
||||
for i = 1, #toolChildren
|
||||
if toolChildren[i]\IsA "Tool"
|
||||
return toolChildren[i]
|
||||
for i in *toolChildren
|
||||
if i\IsA "Tool"
|
||||
return i
|
||||
nil
|
||||
|
||||
|
||||
|
|
@ -723,11 +723,12 @@ doAcceptPurchase = (_) ->
|
|||
response = getRbxUtility!.DecodeJSON response
|
||||
|
||||
if response
|
||||
if response["success"] == false
|
||||
if response["status"] ~= "AlreadyOwned"
|
||||
print "web return response of fail on purchase of", currentAssetId, currentProductId
|
||||
purchaseFailed response["status"] == "EconomyDisabled"
|
||||
return
|
||||
if response["success"] == false and
|
||||
response["status"] ~= "AlreadyOwned"
|
||||
|
||||
print "web return response of fail on purchase of", currentAssetId, currentProductId
|
||||
purchaseFailed response["status"] == "EconomyDisabled"
|
||||
return
|
||||
|
||||
else
|
||||
print "web return response of non parsable JSON on purchase of", currentAssetId
|
||||
|
|
@ -1054,9 +1055,9 @@ cutSizeInHalfRecursive = (_) ->
|
|||
--[[changeSize instance,0.5
|
||||
|
||||
children = instance\GetChildren!
|
||||
for i = 1, #children
|
||||
cutSizeInHalfRecursive children[i]
|
||||
end]]
|
||||
for i in *children
|
||||
cutSizeInHalfRecursive i
|
||||
]]
|
||||
|
||||
|
||||
doubleSizeRecursive = (_) ->
|
||||
|
|
@ -1064,9 +1065,9 @@ doubleSizeRecursive = (_) ->
|
|||
--[[changeSize instance,2
|
||||
|
||||
children = instance\GetChildren!
|
||||
for i = 1, #children
|
||||
doubleSizeRecursive children[i]
|
||||
end]]
|
||||
for i in *children
|
||||
doubleSizeRecursive i
|
||||
]]
|
||||
|
||||
-- depending on screen size, we need to change the gui
|
||||
changeGuiToScreenSize = (smallScreen) ->
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ createButton = (actionName, functionInfoTable) ->
|
|||
button = createNewButton actionName, functionInfoTable
|
||||
|
||||
local position
|
||||
for i = 1, #buttonVector do
|
||||
for i = 1, #buttonVector
|
||||
if buttonVector[i] == "empty"
|
||||
position = i
|
||||
break
|
||||
|
|
@ -200,9 +200,9 @@ removeAction = (actionName) ->
|
|||
if actionButton
|
||||
actionButton.Parent = nil
|
||||
|
||||
for i = 1, #buttonVector
|
||||
if buttonVector[i] == actionButton
|
||||
buttonVector[i] = "empty"
|
||||
for i in *buttonVector
|
||||
if i == actionButton
|
||||
i = "empty"
|
||||
break
|
||||
|
||||
actionButton\Destroy!
|
||||
|
|
|
|||
|
|
@ -519,8 +519,8 @@ initializeDeveloperConsole = ->
|
|||
|
||||
posOffset = 0
|
||||
|
||||
for i = 1, #childMessages
|
||||
childMessages[i].Visible = false
|
||||
for i in *childMessages
|
||||
i.Visible = false
|
||||
|
||||
for i = 1, #messageList
|
||||
local message
|
||||
|
|
@ -856,8 +856,8 @@ initializeDeveloperConsole = ->
|
|||
|
||||
history = game\GetService"LogService"\GetLogHistory!
|
||||
|
||||
for i = 1, #history
|
||||
AddLocalMessage history[i].message, history[i].messageType, history[i].timestamp
|
||||
for i in *history
|
||||
AddLocalMessage i.message, i.messageType, i.timestamp
|
||||
|
||||
with game\GetService"LogService"
|
||||
.MessageOut\connect (message, messageType) ->
|
||||
|
|
|
|||
|
|
@ -91,35 +91,35 @@ wait 5 -- make sure we are loaded in, won't need tool tips for first 5 seconds a
|
|||
|
||||
bottomLeftChildren = bottomLeftControl\GetChildren!
|
||||
|
||||
for i = 1, #bottomLeftChildren
|
||||
if bottomLeftChildren[i].Name == "Exit"
|
||||
for i in *bottomLeftChildren
|
||||
if i.Name == "Exit"
|
||||
|
||||
with exitTip = frameTip\clone!
|
||||
.RobloxLocked = true
|
||||
.Text = "Leave Place"
|
||||
.Position = UDim2.new 0, 0, -1, 0
|
||||
.Size = UDim2.new 1, 0, 1, 0
|
||||
.Parent = bottomLeftChildren[i]
|
||||
.Parent = i
|
||||
setUpListeners exitTip
|
||||
|
||||
elseif bottomLeftChildren[i].Name == "SettingsButton"
|
||||
createSettingsButtonTip bottomLeftChildren[i]
|
||||
elseif i.Name == "SettingsButton"
|
||||
createSettingsButtonTip i
|
||||
|
||||
---------------- set up Bottom Right Tool Tips -------------------------
|
||||
|
||||
bottomRightChildren = bottomRightControl\GetChildren!
|
||||
|
||||
for i = 1, #bottomRightChildren
|
||||
if bottomRightChildren[i].Name\find"Camera"?
|
||||
for i in *bottomRightChildren
|
||||
if i.Name\find"Camera"?
|
||||
with cameraTip = frameTip\clone!
|
||||
.RobloxLocked = true
|
||||
.Text = "Camera View"
|
||||
|
||||
.Position = if bottomRightChildren[i].Name\find "Zoom"
|
||||
.Position = if i.Name\find "Zoom"
|
||||
UDim2.new -1, 0, -1.5
|
||||
else
|
||||
UDim2.new 0, 0, -1.5, 0
|
||||
|
||||
.Size = UDim2.new 2, 0, 1.25, 0
|
||||
.Parent = bottomRightChildren[i]
|
||||
.Parent = i
|
||||
setUpListeners cameraTip
|
||||
|
|
|
|||
|
|
@ -138,24 +138,24 @@ while true
|
|||
fire = config\FindFirstChild "Fire"
|
||||
stun = config\FindFirstChild "Stun"
|
||||
with regen do if regen
|
||||
delta += .Value.X
|
||||
if .Value.Y >= 0
|
||||
.Value = Vector3.new .Value.X + .Value.Z, .Value.Y - s, .Value.Z -- maybe have 3rd parameter be an increaser/decreaser?
|
||||
elseif .Value.Y == -1
|
||||
.Value = Vector3.new .Value.X + .Value.Z, -1, .Value.Z
|
||||
else
|
||||
\remove!
|
||||
-- infinity is -1
|
||||
delta += .Value.X
|
||||
if .Value.Y >= 0
|
||||
.Value = Vector3.new .Value.X + .Value.Z, .Value.Y - s, .Value.Z -- maybe have 3rd parameter be an increaser/decreaser?
|
||||
elseif .Value.Y == -1
|
||||
.Value = Vector3.new .Value.X + .Value.Z, -1, .Value.Z
|
||||
else
|
||||
\remove!
|
||||
-- infinity is -1
|
||||
|
||||
with poison do if poison
|
||||
delta -= .Value.X
|
||||
if .Value.Y >= 0
|
||||
.Value = Vector3.new .Value.X + .Value.Z, .Value.Y - s, .Value.Z
|
||||
elseif .Value.Y == -1
|
||||
.Value = Vector3.new .Value.X + .Value.Z, -1, .Value.Z
|
||||
else
|
||||
\remove!
|
||||
-- infinity is -1
|
||||
delta -= .Value.X
|
||||
if .Value.Y >= 0
|
||||
.Value = Vector3.new .Value.X + .Value.Z, .Value.Y - s, .Value.Z
|
||||
elseif .Value.Y == -1
|
||||
.Value = Vector3.new .Value.X + .Value.Z, -1, .Value.Z
|
||||
else
|
||||
\remove!
|
||||
-- infinity is -1
|
||||
|
||||
with ice do if ice
|
||||
--print "IN ICE"
|
||||
|
|
@ -182,39 +182,37 @@ while true
|
|||
Torso.Anchored = true
|
||||
currentChildren = script.Parent\GetChildren!
|
||||
backpackTools = game.Players\GetPlayerFromCharacter(script.Parent).Backpack\GetChildren!
|
||||
for i = 1, #currentChildren
|
||||
if currentChildren[i].className == "Tool"
|
||||
inCharTag\Clone!.Parent = currentChildren[i]
|
||||
for i in *currentChildren
|
||||
if i.className == "Tool"
|
||||
inCharTag\Clone!.Parent = i
|
||||
print backpackTools
|
||||
table.insert backpackTools, currentChildren[i]
|
||||
table.insert backpackTools, i
|
||||
|
||||
for i = 1, #backpackTools
|
||||
if not backpackTools[i]\FindFirstChild"RobloxBuildTool"?
|
||||
hider\Clone!.Parent = backpackTools[i]
|
||||
backpackTools[i].Parent = game.Lighting
|
||||
for i in *backpackTools
|
||||
if not i\FindFirstChild"RobloxBuildTool"?
|
||||
hider\Clone!.Parent = i
|
||||
i.Parent = game.Lighting
|
||||
|
||||
wait 0.2
|
||||
for i = 1, #backpackTools
|
||||
backpackTools[i].Parent = game.Players\GetPlayerFromCharacter(script.Parent).Backpack
|
||||
for i in *backpackTools
|
||||
i.Parent = game.Players\GetPlayerFromCharacter(script.Parent).Backpack
|
||||
|
||||
stun.Value = stun.Value - s
|
||||
else
|
||||
Torso.Anchored = false
|
||||
for i = 1, #backpackTools
|
||||
rbTool = backpackTools[i]\FindFirstChild "RobloxBuildTool"
|
||||
if rbTool
|
||||
rbTool\Remove!
|
||||
for i in *backpackTools
|
||||
i\FindFirstChild"RobloxBuildTool"?\Remove!
|
||||
|
||||
backpackTools[i].Parent = game.Lighting
|
||||
i.Parent = game.Lighting
|
||||
|
||||
wait 0.2
|
||||
for i = 1, #backpackTools
|
||||
wasInChar = backpackTools[i]\FindFirstChild "InCharTag"
|
||||
if wasInChar
|
||||
for i in *backpackTools
|
||||
wasInChar = i\FindFirstChild "InCharTag"
|
||||
i.Parent = if wasInChar
|
||||
wasInChar\Remove!
|
||||
backpackTools[i].Parent = script.Parent
|
||||
script.Parent
|
||||
else
|
||||
backpackTools[i].Parent = game.Players\GetPlayerFromCharacter(script.Parent).Backpack
|
||||
game.Players\GetPlayerFromCharacter(script.Parent).Backpack
|
||||
|
||||
stun\Remove!
|
||||
|
||||
|
|
@ -224,9 +222,9 @@ while true
|
|||
--health += delta * s * Humanoid.MaxHealth
|
||||
|
||||
health = Humanoid.Health + delta * s
|
||||
if health * 1.01 < Humanoid.MaxHealth
|
||||
Humanoid.Health = health
|
||||
Humanoid.Health = if health * 1.01 < Humanoid.MaxHealth
|
||||
health
|
||||
--myHealth.Value = math.floor Humanoid.Health
|
||||
elseif delta > 0
|
||||
Humanoid.Health = Humanoid.MaxHealth
|
||||
Humanoid.MaxHealth
|
||||
--myHealth.Value = Humanoid.Health
|
||||
|
|
|
|||
106
yue/45284430.yue
106
yue/45284430.yue
|
|
@ -36,16 +36,14 @@ ScopedConnect = (parentInstance, instance, event, signalFunc, syncFunc, removeFu
|
|||
--Entering the world, make sure we are connected/synced
|
||||
if not eventConnection
|
||||
eventConnection = instance[event]\connect signalFunc
|
||||
if syncFunc
|
||||
syncFunc!
|
||||
syncFunc?!
|
||||
|
||||
|
||||
else
|
||||
--Probably leaving the world, so disconnect for now
|
||||
if eventConnection
|
||||
eventConnection\disconnect!
|
||||
if removeFunc
|
||||
removeFunc!
|
||||
removeFunc?!
|
||||
|
||||
|
||||
--Hook it up to ancestryChanged signal
|
||||
|
|
@ -127,8 +125,7 @@ setSliderPos = (newAbsPosX, slider, sliderPosition, bar, steps) ->
|
|||
|
||||
cancelSlide = (areaSoak) ->
|
||||
areaSoak.Visible = false
|
||||
if areaSoakMouseMoveCon
|
||||
areaSoakMouseMoveCon\disconnect!
|
||||
areaSoakMouseMoveCon?\disconnect!
|
||||
|
||||
|
||||
t.CreateStyledMessageDialog = (title, message, style, buttons) ->
|
||||
|
|
@ -828,36 +825,36 @@ t.CreateTrueScrollingFrame = ->
|
|||
scrollUpButton.MouseEnter\connect ->
|
||||
scrollUpButton.BackgroundTransparency = 0.1
|
||||
upChildren = scrollUpButton\GetChildren!
|
||||
for i = 1, #upChildren
|
||||
upChildren[i].BackgroundTransparency = 0.1
|
||||
for i in *upChildren
|
||||
i.BackgroundTransparency = 0.1
|
||||
|
||||
|
||||
scrollUpButton.MouseLeave\connect ->
|
||||
scrollUpButton.BackgroundTransparency = 0.5
|
||||
upChildren = scrollUpButton\GetChildren!
|
||||
for i = 1, #upChildren
|
||||
upChildren[i].BackgroundTransparency = 0.5
|
||||
for i in *upChildren
|
||||
i.BackgroundTransparency = 0.5
|
||||
|
||||
|
||||
scrollDownButton = scrollUpButton\clone!
|
||||
scrollDownButton.Name = "ScrollDownButton"
|
||||
scrollDownButton.Position = UDim2.new 0, 0, 1, -18
|
||||
downChildren = scrollDownButton\GetChildren!
|
||||
for i = 1, #downChildren
|
||||
downChildren[i].Position = UDim2.new 0, 3 + (i - 1), 0.5, -2 + (i - 1)
|
||||
for i in *downChildren
|
||||
i.Position = UDim2.new 0, 3 + (i - 1), 0.5, -2 + (i - 1)
|
||||
|
||||
scrollDownButton.MouseEnter\connect ->
|
||||
scrollDownButton.BackgroundTransparency = 0.1
|
||||
downChildren = scrollDownButton\GetChildren!
|
||||
for i = 1, #downChildren
|
||||
downChildren[i].BackgroundTransparency = 0.1
|
||||
for i in *downChildren
|
||||
i.BackgroundTransparency = 0.1
|
||||
|
||||
|
||||
scrollDownButton.MouseLeave\connect ->
|
||||
scrollDownButton.BackgroundTransparency = 0.5
|
||||
downChildren = scrollDownButton\GetChildren!
|
||||
for i = 1, #downChildren
|
||||
downChildren[i].BackgroundTransparency = 0.5
|
||||
for i in *downChildren
|
||||
i.BackgroundTransparency = 0.5
|
||||
|
||||
|
||||
scrollDownButton.Parent = controlFrame
|
||||
|
|
@ -962,15 +959,15 @@ t.CreateTrueScrollingFrame = ->
|
|||
highY = instance.AbsolutePosition.Y + instance.AbsoluteSize.Y
|
||||
|
||||
children = instance\GetChildren!
|
||||
for i = 1, #children
|
||||
drillDownSetHighLow children[i]
|
||||
for i in *children
|
||||
drillDownSetHighLow i
|
||||
|
||||
|
||||
resetHighLow = ->
|
||||
firstChildren = scrollingFrame\GetChildren!
|
||||
|
||||
for i = 1, #firstChildren
|
||||
drillDownSetHighLow firstChildren[i]
|
||||
for i in *firstChildren
|
||||
drillDownSetHighLow i
|
||||
|
||||
|
||||
recalculate = ->
|
||||
|
|
@ -991,13 +988,13 @@ t.CreateTrueScrollingFrame = ->
|
|||
hiddenYAmount = (scrollingFrame.AbsoluteSize.Y - (highY - lowY)) * percentFrame
|
||||
|
||||
guiChildren = scrollingFrame\GetChildren!
|
||||
for i = 1, #guiChildren
|
||||
if guiChildren[i] ~= controlFrame
|
||||
guiChildren[i].Position = UDim2.new(
|
||||
guiChildren[i].Position.X.Scale,
|
||||
guiChildren[i].Position.X.Offset,
|
||||
for i in *guiChildren
|
||||
if i ~= controlFrame
|
||||
i.Position = UDim2.new(
|
||||
i.Position.X.Scale,
|
||||
i.Position.X.Offset,
|
||||
0,
|
||||
math.ceil(guiChildren[i].AbsolutePosition.Y) - math.ceil lowY + hiddenYAmount
|
||||
math.ceil(i.AbsolutePosition.Y) - math.ceil lowY + hiddenYAmount
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -2306,11 +2303,11 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
|||
|
||||
drillDownSetZIndex = (parent, index) ->
|
||||
children = parent\GetChildren!
|
||||
for i = 1, #children
|
||||
if children[i]\IsA "GuiObject"
|
||||
children[i].ZIndex = index
|
||||
for i in *children
|
||||
if i\IsA "GuiObject"
|
||||
i.ZIndex = index
|
||||
|
||||
drillDownSetZIndex children[i], index
|
||||
drillDownSetZIndex i, index
|
||||
|
||||
|
||||
-- for terrain stamping
|
||||
|
|
@ -2697,8 +2694,8 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
|||
realignButtonGrid = (columns) ->
|
||||
x = 0
|
||||
y = 0
|
||||
for i = 1, #insertButtons
|
||||
insertButtons[i].Position = UDim2.new 0, buttonWidth * x, 0, buttonHeight * y
|
||||
for i in *insertButtons
|
||||
i.Position = UDim2.new 0, buttonWidth * x, 0, buttonHeight * y
|
||||
x += 1
|
||||
if x >= columns
|
||||
x = 0
|
||||
|
|
@ -2786,12 +2783,11 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
|||
contents = Data.Category[Data.CurrentCategory].Contents
|
||||
if contents
|
||||
-- remove our buttons and their connections
|
||||
for i = 1, #insertButtons
|
||||
insertButtons[i]\remove!
|
||||
for i in *insertButtons
|
||||
i\remove!
|
||||
|
||||
for i = 1, #insertButtonCons
|
||||
if insertButtonCons[i]
|
||||
insertButtonCons[i]\disconnect!
|
||||
for i in *insertButtonCons
|
||||
i?\disconnect!
|
||||
|
||||
|
||||
insertButtonCons = {}
|
||||
|
|
@ -2846,12 +2842,12 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
|||
|
||||
resetAllSetButtonSelection = ->
|
||||
setButtons = setGui.SetPanel.Sets.SetsLists\GetChildren!
|
||||
for i = 1, #setButtons
|
||||
if setButtons[i]\IsA "TextButton"
|
||||
setButtons[i].Selected = false
|
||||
setButtons[i].BackgroundTransparency = 1
|
||||
setButtons[i].TextColor3 = Color3.new 1, 1, 1
|
||||
setButtons[i].BackgroundColor3 = Color3.new 1, 1, 1
|
||||
for i in *setButtons
|
||||
if i\IsA "TextButton"
|
||||
i.Selected = false
|
||||
i.BackgroundTransparency = 1
|
||||
i.TextColor3 = Color3.new 1, 1, 1
|
||||
i.BackgroundColor3 = Color3.new 1, 1, 1
|
||||
|
||||
|
||||
populateSetsFrame = ->
|
||||
|
|
@ -2939,8 +2935,8 @@ t.CreateSetPanel = (userIdsForSets, objectSelected, dialogClosed, size, position
|
|||
|
||||
|
||||
userData = {}
|
||||
for id = 1, #userIdsForSets
|
||||
newUserData = game\GetService"InsertService"\GetUserSets userIdsForSets[id]
|
||||
for id in *userIdsForSets
|
||||
newUserData = game\GetService"InsertService"\GetUserSets id
|
||||
if newUserData and #newUserData > 2
|
||||
-- start at #3 to skip over My Decals and My Models for each account
|
||||
for category = 3, #newUserData
|
||||
|
|
@ -3155,10 +3151,10 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
|||
buttonWrap
|
||||
|
||||
|
||||
for i = 1, #materialNames
|
||||
imageButton = createMaterialButton materialNames[i]
|
||||
for i in *materialNames
|
||||
imageButton = createMaterialButton i
|
||||
|
||||
if materialNames[i] == "Grass" -- always start with grass as the default
|
||||
if i == "Grass" -- always start with grass as the default
|
||||
selectedButton = imageButton
|
||||
imageButton.BackgroundTransparency = 0
|
||||
|
||||
|
|
@ -3172,17 +3168,17 @@ t.CreateTerrainMaterialSelector = (size, position) ->
|
|||
|
||||
matName = getNameFromEnum newMaterialType
|
||||
buttons = scrollFrame\GetChildren!
|
||||
for i = 1, #buttons
|
||||
if buttons[i].Name == "Plastic (blue)" and matName == "Plastic (blue)"
|
||||
goToNewMaterial buttons[i], matName
|
||||
for i in *buttons
|
||||
if i.Name == "Plastic (blue)" and matName == "Plastic (blue)"
|
||||
goToNewMaterial i, matName
|
||||
return
|
||||
|
||||
if buttons[i].Name == "Plastic (red)" and matName == "Plastic (red)"
|
||||
goToNewMaterial buttons[i], matName
|
||||
if i.Name == "Plastic (red)" and matName == "Plastic (red)"
|
||||
goToNewMaterial i, matName
|
||||
return
|
||||
|
||||
if string.find buttons[i].Name, matName
|
||||
goToNewMaterial buttons[i], matName
|
||||
if string.find i.Name, matName
|
||||
goToNewMaterial i, matName
|
||||
return
|
||||
|
||||
frame.Changed\connect (prop) ->
|
||||
|
|
|
|||
|
|
@ -88,9 +88,9 @@ resumeGameFunction = (shield) ->
|
|||
)
|
||||
delay tweenTime, ->
|
||||
shield.Visible = false
|
||||
for i = 1, #centerDialogs
|
||||
centerDialogs[i].Visible = false
|
||||
game.GuiService\RemoveCenterDialog centerDialogs[i]
|
||||
for i in *centerDialogs
|
||||
i.Visible = false
|
||||
game.GuiService\RemoveCenterDialog i
|
||||
|
||||
game.GuiService\RemoveCenterDialog shield
|
||||
settingsButton.Active = true
|
||||
|
|
@ -106,9 +106,9 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
lastMenuSelection = {}
|
||||
|
||||
containerChildren = container\GetChildren!
|
||||
for i = 1, #containerChildren
|
||||
if containerChildren[i].Name == menuName
|
||||
containerChildren[i].Visible = true
|
||||
for i in *containerChildren
|
||||
if i.Name == menuName
|
||||
i.Visible = true
|
||||
currentMenuSelection =
|
||||
container: container
|
||||
name: menuName
|
||||
|
|
@ -117,7 +117,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
|
||||
-- selectedMenu = true
|
||||
if size and position
|
||||
containerChildren[i]\TweenSizeAndPosition(
|
||||
i\TweenSizeAndPosition(
|
||||
size,
|
||||
position,
|
||||
Enum.EasingDirection.InOut,
|
||||
|
|
@ -126,7 +126,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
true
|
||||
)
|
||||
elseif size
|
||||
containerChildren[i]\TweenSizeAndPosition(
|
||||
i\TweenSizeAndPosition(
|
||||
size,
|
||||
UDim2.new(0.5, -size.X.Offset / 2, 0.5, -size.Y.Offset / 2),
|
||||
Enum.EasingDirection.InOut,
|
||||
|
|
@ -135,7 +135,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
true
|
||||
)
|
||||
else
|
||||
containerChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(0, 0, 0, 0),
|
||||
Enum.EasingDirection.InOut,
|
||||
Enum.EasingStyle.Sine,
|
||||
|
|
@ -145,7 +145,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
|
||||
else
|
||||
if moveDirection == "left"
|
||||
containerChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(-1, -525, 0, 0),
|
||||
Enum.EasingDirection.InOut,
|
||||
Enum.EasingStyle.Sine,
|
||||
|
|
@ -153,7 +153,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
true
|
||||
)
|
||||
elseif moveDirection == "right"
|
||||
containerChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(1, 525, 0, 0),
|
||||
Enum.EasingDirection.InOut,
|
||||
Enum.EasingStyle.Sine,
|
||||
|
|
@ -161,7 +161,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
true
|
||||
)
|
||||
elseif moveDirection == "up"
|
||||
containerChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(0, 0, -1, -400),
|
||||
Enum.EasingDirection.InOut,
|
||||
Enum.EasingStyle.Sine,
|
||||
|
|
@ -169,7 +169,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
true
|
||||
)
|
||||
elseif moveDirection == "down"
|
||||
containerChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(0, 0, 1, 400),
|
||||
Enum.EasingDirection.InOut,
|
||||
Enum.EasingStyle.Sine,
|
||||
|
|
@ -178,7 +178,7 @@ goToMenu = (container, menuName, moveDirection, size, position) ->
|
|||
)
|
||||
|
||||
delay tweenTime, ->
|
||||
containerChildren[i].Visible = false
|
||||
i.Visible = false
|
||||
|
||||
|
||||
resetLocalCharacter = ->
|
||||
|
|
@ -279,9 +279,9 @@ recordVideoClick = (recordVideoButton, stopRecordButton) ->
|
|||
backToGame = (buttonClicked, shield, settingsButton) ->
|
||||
buttonClicked.Parent.Parent.Parent.Parent.Visible = false
|
||||
shield.Visible = false
|
||||
for i = 1, #centerDialogs
|
||||
game.GuiService\RemoveCenterDialog centerDialogs[i]
|
||||
centerDialogs[i].Visible = false
|
||||
for i in *centerDialogs
|
||||
game.GuiService\RemoveCenterDialog i
|
||||
i.Visible = false
|
||||
|
||||
centerDialogs = {}
|
||||
game.GuiService\RemoveCenterDialog shield
|
||||
|
|
@ -1487,9 +1487,9 @@ if LoadLibrary
|
|||
)
|
||||
elseif #lastMenuSelection > 0
|
||||
if #centerDialogs > 0
|
||||
for i = 1, #centerDialogs
|
||||
game.GuiService\RemoveCenterDialog centerDialogs[i]
|
||||
centerDialogs[i].Visible = false
|
||||
for i in *centerDialogs
|
||||
game.GuiService\RemoveCenterDialog i
|
||||
i.Visible = false
|
||||
|
||||
centerDialogs = {}
|
||||
|
||||
|
|
|
|||
|
|
@ -1781,8 +1781,8 @@ UpdateMaximize = ->
|
|||
for _, i in ipairs MiddleFrames
|
||||
if i\FindFirstChild "ClickListener"
|
||||
i.ClickListener.Size = UDim2.new 0.96, 0, i.ClickListener.Size.Y.Scale, 0
|
||||
for j = 1, #ScoreNames, 1
|
||||
scoreval = ScoreNames[j]
|
||||
for j in *ScoreNames
|
||||
scoreval = j
|
||||
if i\FindFirstChild(scoreval["Name"]) and scoreval["XOffset"]
|
||||
-- print "updateing stat position: #{scoreval["Name"]}"
|
||||
i[scoreval["Name"]]\TweenPosition(
|
||||
|
|
@ -2625,7 +2625,7 @@ TeamSortFunc = (a, b) ->
|
|||
team team entry to sum the scores of
|
||||
--]]
|
||||
AddTeamScores = (team) ->
|
||||
for j = 1, #ScoreNames, 1
|
||||
for j = 1, #ScoreNames
|
||||
i = ScoreNames[j]
|
||||
tscore = 0
|
||||
for _, j in ipairs team["MyPlayers"]
|
||||
|
|
|
|||
|
|
@ -158,8 +158,7 @@ if teleportEnabled
|
|||
local clickCon
|
||||
clickCon = popup.OKButton.MouseButton1Click\connect ->
|
||||
game\GetService"TeleportService"\TeleportCancel!
|
||||
if clickCon
|
||||
clickCon\disconnect!
|
||||
clickCon?\disconnect!
|
||||
game.GuiService\RemoveCenterDialog script.Parent\FindFirstChild "Popup"
|
||||
popup\TweenSize(
|
||||
UDim2.new(0, 0, 0, 0),
|
||||
|
|
|
|||
145
yue/53878057.yue
145
yue/53878057.yue
|
|
@ -181,8 +181,8 @@ removeGear = (gear) ->
|
|||
|
||||
waitForChild player, "Backpack"
|
||||
allEmpty = true
|
||||
for i = 1, #gearSlots
|
||||
if gearSlots[i] ~= "empty"
|
||||
for i in *gearSlots
|
||||
if i ~= "empty"
|
||||
allEmpty = false
|
||||
|
||||
if allEmpty
|
||||
|
|
@ -257,34 +257,33 @@ checkToolAncestry = (child, parent) ->
|
|||
return if child\FindFirstChild "RobloxBuildTool"
|
||||
-- don't show roblox build tools
|
||||
if child\IsA"Tool" or child\IsA "HopperBin"
|
||||
for i = 1, #gearSlots
|
||||
if gearSlots[i] ~= "empty" and gearSlots[i].GearReference.Value == child
|
||||
for i in *gearSlots
|
||||
if i ~= "empty" and i.GearReference.Value == child
|
||||
if not parent?
|
||||
gearSlots[i].Kill.Value = true
|
||||
i.Kill.Value = true
|
||||
return false
|
||||
elseif child.Parent == player.Character
|
||||
gearSlots[i].Selected = true
|
||||
i.Selected = true
|
||||
return true
|
||||
elseif child.Parent == player.Backpack
|
||||
if child\IsA"Tool" or child\IsA "HopperBin"
|
||||
gearSlots[i].Selected = false
|
||||
i.Selected = false
|
||||
|
||||
return true
|
||||
|
||||
|
||||
gearSlots[i].Kill.Value = true
|
||||
i.Kill.Value = true
|
||||
return false
|
||||
|
||||
|
||||
removeAllEquippedGear = (physGear) ->
|
||||
stuff = player.Character\GetChildren!
|
||||
for i = 1, #stuff
|
||||
if (stuff[i]\IsA"Tool" or stuff[i]\IsA"HopperBin") and stuff[i] ~= physGear
|
||||
if stuff[i]\IsA "Tool"
|
||||
stuff[i].Parent = player.Backpack
|
||||
for i in *stuff
|
||||
if (i\IsA"Tool" or i\IsA"HopperBin") and i ~= physGear
|
||||
if i\IsA "Tool"
|
||||
i.Parent = player.Backpack
|
||||
|
||||
if stuff[i]\IsA "HopperBin"
|
||||
stuff[i]\Disable!
|
||||
if i\IsA "HopperBin"
|
||||
i\Disable!
|
||||
|
||||
normalizeButton = (button, speed) ->
|
||||
return if not button
|
||||
|
|
@ -322,11 +321,11 @@ enlargeButton = (button) ->
|
|||
return if not button.Parent
|
||||
return if not button.Selected
|
||||
|
||||
for i = 1, #gearSlots
|
||||
break if gearSlots[i] == "empty"
|
||||
for i in *gearSlots
|
||||
break if i == "empty"
|
||||
|
||||
if gearSlots[i] ~= button
|
||||
normalizeButton gearSlots[i]
|
||||
if i ~= button
|
||||
normalizeButton i
|
||||
|
||||
return if not enlargeOverride
|
||||
|
||||
|
|
@ -427,10 +426,10 @@ activateGear = (num) ->
|
|||
|
||||
|
||||
normalizeAllButtons = ->
|
||||
for i = 1, #gearSlots
|
||||
break if gearSlots[i] == "empty"
|
||||
if gearSlots[i] ~= button
|
||||
normalizeButton gearSlots[i], 0.1
|
||||
for i in *gearSlots
|
||||
break if i == "empty"
|
||||
if i ~= button
|
||||
normalizeButton i, 0.1
|
||||
|
||||
|
||||
waitForDebounce = ->
|
||||
|
|
@ -504,11 +503,11 @@ resolveDrag = (gearClone, x, y) ->
|
|||
frame = gearClone.Parent
|
||||
frames = frame.Parent\GetChildren!
|
||||
|
||||
for i = 1, #frames
|
||||
if frames[i]\IsA"Frame" and
|
||||
pointInRectangle mousePoint, frames[i].AbsolutePosition, frames[i].AbsoluteSize
|
||||
for i in *frames
|
||||
if i\IsA"Frame" and
|
||||
pointInRectangle mousePoint, i.AbsolutePosition, i.AbsoluteSize
|
||||
|
||||
swapGear gearClone, frames[i]
|
||||
swapGear gearClone, i
|
||||
return true
|
||||
|
||||
if (x < frame.AbsolutePosition.x or x > (frame.AbsolutePosition.x + frame.AbsoluteSize.x)) or
|
||||
|
|
@ -524,17 +523,16 @@ resolveDrag = (gearClone, x, y) ->
|
|||
|
||||
|
||||
unequipAllItems = (dontEquipThis) ->
|
||||
for i = 1, #gearSlots
|
||||
break if gearSlots[i] == "empty"
|
||||
for i in *gearSlots
|
||||
break if i == "empty"
|
||||
|
||||
with gearSlots[i]
|
||||
if .GearReference.Value and .GearReference.Value ~= dontEquipThis
|
||||
if .GearReference.Value\IsA "HopperBin"
|
||||
.GearReference.Value\Disable!
|
||||
elseif .GearReference.Value\IsA "Tool"
|
||||
.GearReference.Value.Parent = game.Players.LocalPlayer.Backpack
|
||||
if i.GearReference.Value and i.GearReference.Value ~= dontEquipThis
|
||||
if i.GearReference.Value\IsA "HopperBin"
|
||||
i.GearReference.Value\Disable!
|
||||
elseif i.GearReference.Value\IsA "Tool"
|
||||
i.GearReference.Value.Parent = game.Players.LocalPlayer.Backpack
|
||||
|
||||
.Selected = false
|
||||
i.Selected = false
|
||||
|
||||
|
||||
showToolTip = (button, tip) ->
|
||||
|
|
@ -576,8 +574,8 @@ addingPlayerChild = (child, equipped, addToSlot, inventoryGearButton) ->
|
|||
|
||||
|
||||
if not addToSlot
|
||||
for i = 1, #gearSlots
|
||||
if gearSlots[i] ~= "empty" and gearSlots[i].GearReference.Value == child -- we already have gear, do nothing
|
||||
for i in *gearSlots
|
||||
if i ~= "empty" and i.GearReference.Value == child -- we already have gear, do nothing
|
||||
debounce = false
|
||||
return
|
||||
|
||||
|
|
@ -677,15 +675,15 @@ addingPlayerChild = (child, equipped, addToSlot, inventoryGearButton) ->
|
|||
dragBeginPos = pos
|
||||
gearClone.ZIndex = 7
|
||||
children = gearClone\GetChildren!
|
||||
for i = 1, #children
|
||||
if children[i]\IsA "TextLabel"
|
||||
children[i].ZIndex = if string.find children[i].Name, "Shadow"
|
||||
for i in *children
|
||||
if i\IsA "TextLabel"
|
||||
i.ZIndex = if string.find i.Name, "Shadow"
|
||||
8
|
||||
else
|
||||
9
|
||||
|
||||
elseif children[i]\IsA"Frame" or children[i]\IsA "ImageLabel"
|
||||
children[i].ZIndex = 7
|
||||
elseif i\IsA"Frame" or i\IsA "ImageLabel"
|
||||
i.ZIndex = 7
|
||||
|
||||
|
||||
dragStop = gearClone.DragStopped\connect (x, y) ->
|
||||
|
|
@ -695,15 +693,15 @@ addingPlayerChild = (child, equipped, addToSlot, inventoryGearButton) ->
|
|||
3
|
||||
|
||||
children = gearClone\GetChildren!
|
||||
for i = 1, #children
|
||||
if children[i]\IsA "TextLabel"
|
||||
children[i].ZIndex = if string.find children[i].Name, "Shadow"
|
||||
for i in *children
|
||||
if i\IsA "TextLabel"
|
||||
i.ZIndex = if string.find i.Name, "Shadow"
|
||||
3
|
||||
else
|
||||
4
|
||||
|
||||
elseif children[i]\IsA"Frame" or children[i]\IsA "ImageLabel"
|
||||
children[i].ZIndex = 2
|
||||
elseif i\IsA"Frame" or i\IsA "ImageLabel"
|
||||
i.ZIndex = 2
|
||||
|
||||
resolveDrag gearClone, x, y
|
||||
|
||||
|
|
@ -756,8 +754,8 @@ addingPlayerChild = (child, equipped, addToSlot, inventoryGearButton) ->
|
|||
while backpackIsOpen!
|
||||
wait 0.03
|
||||
|
||||
for i = 1, #gearSlots
|
||||
if gearSlots[i] ~= "empty"
|
||||
for i in *gearSlots
|
||||
if i ~= "empty"
|
||||
backpackButton.Position = UDim2.new 0.5, -60, 1, -108
|
||||
if backpackEnabled
|
||||
backpackButton.Visible = true
|
||||
|
|
@ -785,15 +783,15 @@ addToInventory = (child) ->
|
|||
spreadOutGear = ->
|
||||
loadoutChildren = currentLoadout\GetChildren!
|
||||
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA "Frame"
|
||||
loadoutChildren[i].BackgroundTransparency = 0.5
|
||||
slot = tonumber string.sub loadoutChildren[i].Name, 5
|
||||
for i in *loadoutChildren
|
||||
if i\IsA "Frame"
|
||||
i.BackgroundTransparency = 0.5
|
||||
slot = tonumber string.sub i.Name, 5
|
||||
if slot == 0
|
||||
slot = 10
|
||||
|
||||
if robloxGui.AbsoluteSize.Y <= 320
|
||||
loadoutChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new(0, (slot - 1) * 60, 0, 0),
|
||||
Enum.EasingDirection.Out,
|
||||
Enum.EasingStyle.Quad,
|
||||
|
|
@ -801,7 +799,7 @@ spreadOutGear = ->
|
|||
true
|
||||
)
|
||||
else
|
||||
loadoutChildren[i]\TweenPosition(
|
||||
i\TweenPosition(
|
||||
UDim2.new((slot - 1) / 10, 0, 0, 0),
|
||||
Enum.EasingDirection.Out,
|
||||
Enum.EasingStyle.Quad,
|
||||
|
|
@ -815,16 +813,16 @@ centerGear = ->
|
|||
gearButtons = {}
|
||||
local lastSlotAdd
|
||||
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA "Frame"
|
||||
if #loadoutChildren[i]\GetChildren! > 0
|
||||
if loadoutChildren[i].Name == "Slot0"
|
||||
lastSlotAdd = loadoutChildren[i]
|
||||
for i in *loadoutChildren
|
||||
if i\IsA "Frame"
|
||||
if #i\GetChildren! > 0
|
||||
if i.Name == "Slot0"
|
||||
lastSlotAdd = i
|
||||
else
|
||||
table.insert gearButtons, loadoutChildren[i]
|
||||
table.insert gearButtons, i
|
||||
|
||||
|
||||
loadoutChildren[i].BackgroundTransparency = 1
|
||||
i.BackgroundTransparency = 1
|
||||
|
||||
|
||||
if lastSlotAdd
|
||||
|
|
@ -949,11 +947,10 @@ delay 2, ->
|
|||
--while true
|
||||
if not backpackWasOpened
|
||||
if robloxGui.AbsoluteSize.Y <= 320
|
||||
cChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #cChildren
|
||||
slotNum = tonumber string.sub cChildren[i].Name, 5, string.len cChildren[i].Name
|
||||
for i in *currentLoadout\GetChildren!
|
||||
slotNum = tonumber string.sub i.Name, 5, string.len i.Name
|
||||
if type(slotNum) == "number"
|
||||
cChildren[i].Position = UDim2.new 0, (slotNum - 1) * 60, 0, 0
|
||||
i.Position = UDim2.new 0, (slotNum - 1) * 60, 0, 0
|
||||
|
||||
wait 0.25
|
||||
|
||||
|
|
@ -984,10 +981,10 @@ humanoidDiedCon = player.Character.Humanoid.Died\connect ->
|
|||
|
||||
|
||||
player.CharacterRemoving\connect ->
|
||||
for i = 1, #gearSlots
|
||||
if gearSlots[i] ~= "empty"
|
||||
gearSlots[i].Parent = nil
|
||||
gearSlots[i] = "empty"
|
||||
for i in *gearSlots
|
||||
if i ~= "empty"
|
||||
i.Parent = nil
|
||||
i = "empty"
|
||||
|
||||
|
||||
player.CharacterAdded\connect ->
|
||||
|
|
@ -1040,10 +1037,10 @@ player.CharacterAdded\connect ->
|
|||
(robloxGui.AbsoluteSize.Y <= 320)
|
||||
|
||||
cChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #cChildren
|
||||
slotNum = tonumber string.sub cChildren[i].Name, 5, string.len cChildren[i].Name
|
||||
for i in *cChildren
|
||||
slotNum = tonumber string.sub i.Name, 5, string.len i.Name
|
||||
if type(slotNum) == "number"
|
||||
cChildren[i].Position = UDim2.new 0, (slotNum - 1) * 60, 0, 0
|
||||
i.Position = UDim2.new 0, (slotNum - 1) * 60, 0, 0
|
||||
|
||||
wait 0.25
|
||||
|
||||
|
|
|
|||
121
yue/73157242.yue
121
yue/73157242.yue
|
|
@ -94,8 +94,8 @@ rotatePartAndChildren = (part, rotCF, offsetFromOrigin) ->
|
|||
|
||||
-- recursively do the same to all children
|
||||
partChildren = part\GetChildren!
|
||||
for c = 1, #partChildren
|
||||
rotatePartAndChildren partChildren[c], rotCF, offsetFromOrigin
|
||||
for c in *partChildren
|
||||
rotatePartAndChildren c, rotCF, offsetFromOrigin
|
||||
|
||||
modelRotate = (model, yAngle) ->
|
||||
rotCF = CFrame.Angles 0, yAngle, 0
|
||||
|
|
@ -161,8 +161,8 @@ findSeatsInModel = (parent, seatTable) ->
|
|||
table.insert seatTable, parent
|
||||
|
||||
myChildren = parent\GetChildren!
|
||||
for j = 1, #myChildren
|
||||
findSeatsInModel myChildren[j], seatTable
|
||||
for j in *myChildren
|
||||
findSeatsInModel j, seatTable
|
||||
|
||||
|
||||
setSeatEnabledStatus = (model, isEnabled) ->
|
||||
|
|
@ -171,19 +171,19 @@ setSeatEnabledStatus = (model, isEnabled) ->
|
|||
|
||||
if isEnabled
|
||||
-- remove any welds called "SeatWeld" in seats
|
||||
for i = 1, #seatList
|
||||
nextSeat = seatList[i]\FindFirstChild "SeatWeld"
|
||||
for i in *seatList
|
||||
nextSeat = i\FindFirstChild "SeatWeld"
|
||||
while nextSeat
|
||||
nextSeat\Remove!
|
||||
nextSeat = seatList[i]\FindFirstChild "SeatWeld"
|
||||
nextSeat = i\FindFirstChild "SeatWeld"
|
||||
|
||||
|
||||
else
|
||||
-- put a weld called "SeatWeld" in every seat
|
||||
-- this tricks it into thinking there's already someone sitting there, and it won't make you sit XD
|
||||
for i = 1, #seatList
|
||||
for i in *seatList
|
||||
New "Weld", "SeatWeld"
|
||||
Parent: seatList[i]
|
||||
Parent: i
|
||||
|
||||
|
||||
autoAlignToFace = (parts) ->
|
||||
|
|
@ -404,8 +404,8 @@ spaceAboveCharacter = (charTorso, newTorsoY, stampData) ->
|
|||
100
|
||||
)
|
||||
|
||||
for j = 1, #partsAboveChar
|
||||
if partsAboveChar[j].CanCollide and not partsAboveChar[j]\IsDescendantOf stampData.CurrentParts
|
||||
for j in *partsAboveChar
|
||||
if j.CanCollide and not j\IsDescendantOf stampData.CurrentParts
|
||||
return false
|
||||
|
||||
if clusterPartsInRegion(
|
||||
|
|
@ -510,12 +510,12 @@ findConfigAtMouseTarget = (Mouse, stampData) ->
|
|||
--[[if targetPart.Parent\IsA "Model"
|
||||
hitFace = modelTargetSurface(targetPart.Parent, Mouse.Hit.p, game.Workspace.CurrentCamera.CoordinateFrame.p) -- best, if you get it right
|
||||
WORLD_AXES = { Vector3.new(1, 0, 0), Vector3.new(0, 1, 0), Vector3.new(0, 0, 1) }
|
||||
if hitFace > 0
|
||||
targetVectorInWorld = targetCFrame\vectorToWorldSpace WORLD_AXES[hitFace]
|
||||
targetVectorInWorld = if hitFace > 0
|
||||
targetCFrame\vectorToWorldSpace WORLD_AXES[hitFace]
|
||||
elseif hitFace < 0
|
||||
targetVectorInWorld = targetCFrame\vectorToWorldSpace -WORLD_AXES[-hitFace]
|
||||
targetCFrame\vectorToWorldSpace -WORLD_AXES[-hitFace]
|
||||
|
||||
end]]
|
||||
]]
|
||||
|
||||
|
||||
local targetRefPointInTarget, insertRefPointInInsert
|
||||
|
|
@ -613,8 +613,8 @@ saveTheWelds = (object, manualWeldTable, manualWeldParentTable) ->
|
|||
table.insert manualWeldParentTable, object.Parent
|
||||
else
|
||||
children = object\GetChildren!
|
||||
for i = 1, #children
|
||||
saveTheWelds children[i], manualWeldTable, manualWeldParentTable
|
||||
for i in *children
|
||||
saveTheWelds i, manualWeldTable, manualWeldParentTable
|
||||
|
||||
|
||||
restoreTheWelds = (manualWeldTable, manualWeldParentTable) ->
|
||||
|
|
@ -1399,7 +1399,7 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
for _, script in pairs scripts
|
||||
if not script.Disabled
|
||||
script.Disabled = true
|
||||
stampData.DisabledScripts[#stampData.DisabledScripts + 1] = script
|
||||
stampData.DisabledScripts[] = script
|
||||
|
||||
|
||||
for _, part in pairs parts
|
||||
|
|
@ -1502,8 +1502,8 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
|
||||
skipThisCell = false
|
||||
|
||||
for b = 1, #cellBlockingParts
|
||||
if isBlocker cellBlockingParts[b]
|
||||
for b in *cellBlockingParts
|
||||
if isBlocker b
|
||||
skipThisCell = true
|
||||
break
|
||||
|
||||
|
|
@ -1512,15 +1512,15 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
-- pop players up above any set cells
|
||||
alreadyPushedUp = {}
|
||||
-- if no blocking model below, then see if stamping on top of a character
|
||||
for b = 1, #cellBlockingParts
|
||||
if cellBlockingParts[b].Parent and
|
||||
not alreadyPushedUp[cellBlockingParts[b].Parent] and
|
||||
cellBlockingParts[b].Parent\FindFirstChild "Humanoid" and
|
||||
cellBlockingParts[b].Parent\FindFirstChild"Humanoid"\IsA "Humanoid"
|
||||
for b in *cellBlockingParts
|
||||
if b.Parent and
|
||||
not alreadyPushedUp[b.Parent] and
|
||||
b.Parent\FindFirstChild "Humanoid" and
|
||||
b.Parent\FindFirstChild"Humanoid"\IsA "Humanoid"
|
||||
|
||||
-----------------------------------------------------------------------------------
|
||||
blockingPersonTorso = cellBlockingParts[b].Parent\FindFirstChild "Torso"
|
||||
alreadyPushedUp[cellBlockingParts[b].Parent] = true
|
||||
blockingPersonTorso = b.Parent\FindFirstChild "Torso"
|
||||
alreadyPushedUp[b.Parent] = true
|
||||
|
||||
if blockingPersonTorso
|
||||
-- if so, let's push the person upwards so they pop on top of the stamped model/part (but only if there's space above them)
|
||||
|
|
@ -1621,20 +1621,20 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
math.floor lines[i].Z + 0.5
|
||||
) -- round to integers
|
||||
|
||||
if lines[i].X > 0
|
||||
xInc[i] = 1
|
||||
xInc[i] = if lines[i].X > 0
|
||||
1
|
||||
elseif lines[i].X < 0
|
||||
xInc[i] = -1
|
||||
-1
|
||||
|
||||
if lines[i].Y > 0
|
||||
yInc[i] = 1
|
||||
yInc[i] = if lines[i].Y > 0
|
||||
1
|
||||
elseif lines[i].Y < 0
|
||||
yInc[i] = -1
|
||||
-1
|
||||
|
||||
if lines[i].Z > 0
|
||||
zInc[i] = 1
|
||||
zInc[i] = if lines[i].Z > 0
|
||||
1
|
||||
elseif lines[i].Z < 0
|
||||
zInc[i] = -1
|
||||
-1
|
||||
|
||||
|
||||
incrementVect[i] = Vector3.new xInc[i], yInc[i], zInc[i]
|
||||
|
|
@ -1767,16 +1767,13 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
error "Error: RbxStamper.DoStamperMouseUp: Mouse is of type", Mouse.className, "should be of type Mouse"
|
||||
return false
|
||||
|
||||
|
||||
if not stampData.Dragger
|
||||
error "Error: RbxStamper.DoStamperMouseUp: stampData.Dragger is nil"
|
||||
return false
|
||||
|
||||
|
||||
if not HighScalabilityLine
|
||||
return false
|
||||
|
||||
|
||||
local checkHighScalabilityStamp
|
||||
if stampInModel
|
||||
local canStamp
|
||||
|
|
@ -1834,23 +1831,23 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
100
|
||||
)
|
||||
|
||||
for b = 1, #blockingParts
|
||||
if isBlocker blockingParts[b]
|
||||
for b in *blockingParts
|
||||
if isBlocker b
|
||||
flashRedBox!
|
||||
return false
|
||||
|
||||
|
||||
alreadyPushedUp = {}
|
||||
-- if no blocking model below, then see if stamping on top of a character
|
||||
for b = 1, #blockingParts
|
||||
if blockingParts[b].Parent and
|
||||
not alreadyPushedUp[blockingParts[b].Parent] and
|
||||
blockingParts[b].Parent\FindFirstChild"Humanoid" and
|
||||
blockingParts[b].Parent\FindFirstChild"Humanoid"\IsA "Humanoid"
|
||||
for b in *blockingParts
|
||||
if b.Parent and
|
||||
not alreadyPushedUp[b.Parent] and
|
||||
b.Parent\FindFirstChild"Humanoid" and
|
||||
b.Parent\FindFirstChild"Humanoid"\IsA "Humanoid"
|
||||
|
||||
---------------------------------------------------------------------------
|
||||
blockingPersonTorso = blockingParts[b].Parent\FindFirstChild "Torso"
|
||||
alreadyPushedUp[blockingParts[b].Parent] = true
|
||||
blockingPersonTorso = b.Parent\FindFirstChild "Torso"
|
||||
alreadyPushedUp[b.Parent] = true
|
||||
|
||||
if blockingPersonTorso
|
||||
-- if so, let's push the person upwards so they pop on top of the stamped model/part (but only if there's space above them)
|
||||
|
|
@ -2115,9 +2112,9 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
true
|
||||
|
||||
pauseStamper = ->
|
||||
for i = 1, #mouseCons -- stop the mouse from doing anything
|
||||
mouseCons[i]\disconnect!
|
||||
mouseCons[i] = nil
|
||||
for i in *mouseCons -- stop the mouse from doing anything
|
||||
i\disconnect!
|
||||
i = nil
|
||||
|
||||
mouseCons = {}
|
||||
|
||||
|
|
@ -2144,9 +2141,7 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
|
||||
surfaceNormal = isPositive * modelCFrame\vectorToWorldSpace AXIS_VECTORS[whichSurface]
|
||||
|
||||
for i = 1, #parts
|
||||
currPart = parts[i]
|
||||
|
||||
for currPart in *parts
|
||||
-- now just need to find which surface of currPart most closely match surfaceNormal and then set that to Unjoinable
|
||||
surfaceNormalInLocalCoords = currPart.CFrame\vectorToObjectSpace surfaceNormal
|
||||
if math.abs(surfaceNormalInLocalCoords.X) > math.abs surfaceNormalInLocalCoords.Y
|
||||
|
|
@ -2186,10 +2181,10 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
if unjoinableTag
|
||||
for unjoinableSurface in string.gmatch unjoinableTag.Value, "[^,]*"
|
||||
if tonumber unjoinableSurface
|
||||
if clone\IsA "Model"
|
||||
prepareUnjoinableSurfaces clone\GetModelCFrame!, parts, tonumber unjoinableSurface
|
||||
prepareUnjoinableSurfaces if clone\IsA "Model"
|
||||
clone\GetModelCFrame!, parts, tonumber unjoinableSurface
|
||||
else
|
||||
prepareUnjoinableSurfaces clone.CFrame, parts, tonumber unjoinableSurface
|
||||
clone.CFrame, parts, tonumber unjoinableSurface
|
||||
|
||||
|
||||
stampData.ErrorBox = errorBox
|
||||
|
|
@ -2211,10 +2206,10 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
mouseTarget = Mouse.Target
|
||||
|
||||
|
||||
if mouseTarget and not mouseTarget.Parent\FindFirstChild"RobloxModel"?
|
||||
game.JointsService\SetJoinAfterMoveTarget mouseTarget
|
||||
game.JointsService\SetJoinAfterMoveTarget if mouseTarget and not mouseTarget.Parent\FindFirstChild"RobloxModel"?
|
||||
mouseTarget
|
||||
else
|
||||
game.JointsService\SetJoinAfterMoveTarget nil
|
||||
nil
|
||||
|
||||
game.JointsService\ShowPermissibleJoints!
|
||||
|
||||
|
|
@ -2318,9 +2313,9 @@ t.SetupStamperDragger = (modelToStamp, Mouse, StampInModel, AllowedStampRegion,
|
|||
-- High-Scalability and with the new model orientation setting methods (model\ResetOrientationToIdentity!) [HotThoth]
|
||||
|
||||
control.Destroy = -> -- Stops current Stamp operation and destroys control construct
|
||||
for i = 1, #mouseCons
|
||||
mouseCons[i]\disconnect!
|
||||
mouseCons[i] = nil
|
||||
for i in *mouseCons
|
||||
i\disconnect!
|
||||
i = nil
|
||||
|
||||
keyCon?\disconnect!
|
||||
|
||||
|
|
|
|||
|
|
@ -187,24 +187,23 @@ clearHighlight = (button) ->
|
|||
|
||||
inLoadout = (gear) ->
|
||||
children = currentLoadout\GetChildren!
|
||||
for i = 1, #children
|
||||
if children[i]\IsA "Frame"
|
||||
button = children[i]\GetChildren!
|
||||
for i in *children
|
||||
if i\IsA "Frame"
|
||||
button = i\GetChildren!
|
||||
if #button > 0 and
|
||||
button[1].GearReference.Value and
|
||||
button[1].GearReference.Value == gear
|
||||
return true
|
||||
|
||||
return true
|
||||
|
||||
false
|
||||
|
||||
updateGridActive = ->
|
||||
for _, v in pairs backpackItems
|
||||
if buttons[v]
|
||||
local gear
|
||||
gearRef = buttons[v]\FindFirstChild "GearReference"
|
||||
|
||||
if gearRef
|
||||
gear = gearRef.Value
|
||||
gear = gearRef?.Value
|
||||
|
||||
buttons[v].Active = if (not gear) or inLoadout gear
|
||||
false
|
||||
|
|
@ -232,9 +231,9 @@ UnequipGearMenuClick = (element, menu) ->
|
|||
gearToUnequip = inventoryButton.GearReference.Value
|
||||
loadoutChildren = currentLoadout\GetChildren!
|
||||
slot = -1
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA "Frame"
|
||||
button = loadoutChildren[i]\GetChildren!
|
||||
for i in *loadoutChildren
|
||||
if i\IsA "Frame"
|
||||
button = i\GetChildren!
|
||||
if button[1] and button[1].GearReference.Value == gearToUnequip
|
||||
slot = button[1].SlotNumber.Text
|
||||
break
|
||||
|
|
@ -367,9 +366,9 @@ getGearContextMenu = ->
|
|||
findEmptySlot = ->
|
||||
local smallestNum
|
||||
loadout = currentLoadout\GetChildren!
|
||||
for i = 1, #loadout
|
||||
if loadout[i]\IsA"Frame" and #loadout[i]\GetChildren! <= 0
|
||||
frameNum = tonumber string.sub loadout[i].Name, 5
|
||||
for i in *loadout
|
||||
if i\IsA"Frame" and #i\GetChildren! <= 0
|
||||
frameNum = tonumber string.sub i.Name, 5
|
||||
if frameNum == 0
|
||||
frameNum = 10
|
||||
|
||||
|
|
@ -383,15 +382,15 @@ findEmptySlot = ->
|
|||
|
||||
checkForSwap = (button, x, y) ->
|
||||
loadoutChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA"Frame" and string.find loadoutChildren[i].Name, "Slot"
|
||||
if x >= loadoutChildren[i].AbsolutePosition.x and
|
||||
x <= (loadoutChildren[i].AbsolutePosition.x + loadoutChildren[i].AbsoluteSize.x)
|
||||
for i in *loadoutChildren
|
||||
if i\IsA"Frame" and string.find i.Name, "Slot"
|
||||
if x >= i.AbsolutePosition.x and
|
||||
x <= (i.AbsolutePosition.x + i.AbsoluteSize.x)
|
||||
|
||||
if y >= loadoutChildren[i].AbsolutePosition.y and
|
||||
y <= (loadoutChildren[i].AbsolutePosition.y + loadoutChildren[i].AbsoluteSize.y)
|
||||
if y >= i.AbsolutePosition.y and
|
||||
y <= (i.AbsolutePosition.y + i.AbsoluteSize.y)
|
||||
|
||||
slot = tonumber string.sub loadoutChildren[i].Name, 5
|
||||
slot = tonumber string.sub i.Name, 5
|
||||
swapGearSlot slot, button
|
||||
return true
|
||||
false
|
||||
|
|
@ -563,12 +562,12 @@ showEntireGrid = ->
|
|||
centerGear = (loadoutChildren) ->
|
||||
gearButtons = {}
|
||||
local lastSlotAdd
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA"Frame" and #loadoutChildren[i]\GetChildren! > 0
|
||||
if loadoutChildren[i].Name == "Slot0"
|
||||
lastSlotAdd = loadoutChildren[i]
|
||||
for i in *loadoutChildren
|
||||
if i\IsA"Frame" and #i\GetChildren! > 0
|
||||
if i.Name == "Slot0"
|
||||
lastSlotAdd = i
|
||||
else
|
||||
table.insert gearButtons, loadoutChildren[i]
|
||||
table.insert gearButtons, i
|
||||
|
||||
if lastSlotAdd
|
||||
table.insert gearButtons, lastSlotAdd
|
||||
|
|
@ -627,9 +626,9 @@ loadoutCheck = (child, selectState) ->
|
|||
|
||||
-- removeAllEquippedGear = (physGear) ->
|
||||
-- stuff = player.Character\GetChildren!
|
||||
-- for i = 1, #stuff
|
||||
-- if (stuff[i]\IsA"Tool" or stuff[i]\IsA"HopperBin") and stuff[i] ~= physGear
|
||||
-- stuff[i].Parent = playerBackpack
|
||||
-- for i in *stuff
|
||||
-- if (i\IsA"Tool" or stuff[i]\IsA"HopperBin") and i ~= physGear
|
||||
-- i.Parent = playerBackpack
|
||||
|
||||
-- equipGear = (physGear) ->
|
||||
-- removeAllEquippedGear physGear
|
||||
|
|
@ -644,8 +643,8 @@ setupCharacterConnections = ->
|
|||
|
||||
-- make sure we get all the children
|
||||
backpackChildren = game.Players.LocalPlayer.Backpack\GetChildren!
|
||||
for i = 1, #backpackChildren
|
||||
addToGrid backpackChildren[i]
|
||||
for i in *backpackChildren
|
||||
addToGrid i
|
||||
|
||||
|
||||
characterChildAddedCon?\disconnect!
|
||||
|
|
@ -672,8 +671,8 @@ filterGear = (terms) ->
|
|||
for _, v in pairs backpackItems
|
||||
if buttons[v]
|
||||
gearString = trim string.lower buttons[v].GearReference.Value.Name
|
||||
for i = 1, #terms
|
||||
if string.match gearString, terms[i]
|
||||
for i in *terms
|
||||
if string.match gearString, i
|
||||
table.insert filteredGear, buttons[v]
|
||||
break
|
||||
|
||||
|
|
@ -718,8 +717,8 @@ nukeBackpack = ->
|
|||
|
||||
backpackItems = {}
|
||||
scrollingFrameChildren = grid.ScrollingFrame\GetChildren!
|
||||
for i = 1, #scrollingFrameChildren
|
||||
scrollingFrameChildren[i]\remove!
|
||||
for i in *scrollingFrameChildren
|
||||
i\remove!
|
||||
|
||||
coreGuiChanged = (coreGuiType, enabled) ->
|
||||
if coreGuiType == Enum.CoreGuiType.Backpack or coreGuiType == Enum.CoreGuiType.All
|
||||
|
|
@ -728,8 +727,8 @@ coreGuiChanged = (coreGuiType, enabled) ->
|
|||
|
||||
|
||||
backpackChildren = player.Backpack\GetChildren!
|
||||
for i = 1, #backpackChildren
|
||||
addToGrid backpackChildren[i]
|
||||
for i in *backpackChildren
|
||||
addToGrid i
|
||||
|
||||
|
||||
------------------------- Start Lifelong Connections -----------------------
|
||||
|
|
@ -784,10 +783,10 @@ swapSlot.Changed\connect ->
|
|||
updateGridActive!
|
||||
|
||||
loadoutChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #loadoutChildren
|
||||
if loadoutChildren[i]\IsA"Frame" and string.find loadoutChildren[i].Name, "Slot"
|
||||
loadoutChildren[i].ChildRemoved\connect -> updateGridActive!
|
||||
loadoutChildren[i].ChildAdded\connect -> updateGridActive!
|
||||
for i in *loadoutChildren
|
||||
if i\IsA"Frame" and string.find i.Name, "Slot"
|
||||
i.ChildRemoved\connect -> updateGridActive!
|
||||
i.ChildAdded\connect -> updateGridActive!
|
||||
|
||||
|
||||
------------------------- End Lifelong Connections -----------------------
|
||||
|
|
@ -802,8 +801,8 @@ resizeGrid!
|
|||
|
||||
-- make sure any items in the loadout are accounted for in inventory
|
||||
loadoutChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #loadoutChildren
|
||||
loadoutCheck loadoutChildren[i], false
|
||||
for i in *loadoutChildren
|
||||
loadoutCheck i, false
|
||||
|
||||
if not backpack.Visible
|
||||
centerGear currentLoadout\GetChildren!
|
||||
|
|
|
|||
|
|
@ -124,8 +124,7 @@ deactivateBackpack = ->
|
|||
active = false
|
||||
|
||||
initHumanoidDiedConnections = ->
|
||||
if humanoidDiedCon
|
||||
humanoidDiedCon\disconnect!
|
||||
humanoidDiedCon?\disconnect!
|
||||
|
||||
waitForProperty game.Players.LocalPlayer, "Character"
|
||||
waitForChild game.Players.LocalPlayer.Character, "Humanoid"
|
||||
|
|
@ -215,9 +214,9 @@ toggleBackpack = ->
|
|||
hideBackpack!
|
||||
|
||||
clChildren = currentLoadout\GetChildren!
|
||||
for i = 1, #clChildren
|
||||
if clChildren[i] and clChildren[i]\IsA "Frame"
|
||||
frame = clChildren[i]
|
||||
for i in *clChildren
|
||||
if i and i\IsA "Frame"
|
||||
frame = i
|
||||
if #frame\GetChildren! > 0
|
||||
backpackButton.Position = UDim2.new 0.5, -60, 1, -108
|
||||
backpackButton.Visible = true
|
||||
|
|
|
|||
|
|
@ -970,10 +970,10 @@ GetNameValue = (pName) ->
|
|||
cValue = string.byte string.sub pName, index, index
|
||||
reverseIndex = #pName - index + 1
|
||||
if #pName % 2 == 1
|
||||
reverseIndex = reverseIndex - 1
|
||||
reverseIndex -= 1
|
||||
if reverseIndex % 4 >= 2
|
||||
cValue = -cValue
|
||||
value = value + cValue
|
||||
value += cValue
|
||||
value % 8
|
||||
|
||||
Chat.ComputeChatColor = (pName) =>
|
||||
|
|
@ -1007,8 +1007,6 @@ Chat.EnableScrolling = (toggle) =>
|
|||
-- Chat.OnScroll = (speed) =>
|
||||
-- if @MouseOnFrame
|
||||
-- --
|
||||
-- end
|
||||
-- end
|
||||
|
||||
-- Check if we are running on a touch device
|
||||
Chat.IsTouchDevice ==>
|
||||
|
|
@ -1019,16 +1017,16 @@ Chat.IsTouchDevice ==>
|
|||
|
||||
-- Scrolling
|
||||
-- Chat.ScrollQueue = (value) =>
|
||||
-- for i = 1, #@MessageQueue
|
||||
-- if @MessageQueue[i]
|
||||
-- for _, label in pairs @MessageQueue[i]
|
||||
-- next = @MessageQueue[i].Next
|
||||
-- previous = @MessageQueue[i].Previous
|
||||
-- for i in *@MessageQueue
|
||||
-- if i
|
||||
-- for _, label in pairs i
|
||||
-- next = i.Next
|
||||
-- previous = i.Previous
|
||||
-- if label and label\IsA('TextLabel') or label\IsA 'TextButton'
|
||||
-- if value > 0 and previous and previous['Message']
|
||||
-- label.Position = previous['Message'].Position
|
||||
-- label.Position = if value > 0 and previous and previous['Message']
|
||||
-- previous['Message'].Position
|
||||
-- elseif value < 1 and next['Message']
|
||||
-- label.Position = previous['Message'].Position
|
||||
-- previous['Message'].Position
|
||||
|
||||
-- Handles the rendering of the text objects in their appropriate places
|
||||
Chat.UpdateQueue = (field, diff) =>
|
||||
|
|
@ -1128,8 +1126,7 @@ Chat.UpdateChat = (cPlayer, message) =>
|
|||
--Chat.Messages_List = {}
|
||||
table.insert Chat.Messages_List, messageField
|
||||
Chat.MessageThread = coroutine.create ->
|
||||
for i = 1, #Chat.Messages_List
|
||||
field = Chat.Messages_List[i]
|
||||
for field in *Chat.Messages_List
|
||||
Chat\CreateMessage field["Player"], field["Message"]
|
||||
Chat.Messages_List = {}
|
||||
|
||||
|
|
@ -1138,9 +1135,9 @@ Chat.UpdateChat = (cPlayer, message) =>
|
|||
table.insert Chat.Messages_List, messageField
|
||||
|
||||
-- Chat.RecalculateSpacing ==>
|
||||
--[[for i = 1, #@MessageQueue
|
||||
pLabel = @MessageQueue[i]['Player']
|
||||
mLabel = @MessageQueue[i]['Message']
|
||||
--[[for i in *@MessageQueue
|
||||
pLabel = i['Player']
|
||||
mLabel = i['Message']
|
||||
|
||||
prevYScale = mLabel.Size.Y.Scale
|
||||
prevText = mLabel.Text
|
||||
|
|
@ -1153,7 +1150,7 @@ Chat.UpdateChat = (cPlayer, message) =>
|
|||
|
||||
diff = mLabel.Size.Y.Scale - prevYScale
|
||||
|
||||
Chat\UpdateQueue @MessageQueue[i], diff
|
||||
Chat\UpdateQueue i, diff
|
||||
end ]]
|
||||
|
||||
-- Chat.ApplyFilter = (str) =>
|
||||
|
|
@ -1179,22 +1176,21 @@ Chat.CreateMessage = (cPlayer, message) =>
|
|||
--[[pLabel = @MessageQueue[#@MessageQueue]['Player']
|
||||
mLabel = @MessageQueue[#@MessageQueue]['Message']
|
||||
|
||||
pLabel.Text = pName .. ':'
|
||||
pLabel.Text = pName .. ":"
|
||||
pLabel.Name = pName
|
||||
|
||||
local pColor
|
||||
if cPlayer.Neutral
|
||||
pLabel.TextColor3 = Chat\ComputeChatColor pName
|
||||
pLabel.TextColor3 = if cPlayer.Neutral
|
||||
Chat\ComputeChatColor pName
|
||||
else
|
||||
pLabel.TextColor3 = cPlayer.TeamColor.Color
|
||||
cPlayer.TeamColor.Color
|
||||
|
||||
local nString
|
||||
|
||||
if not @CachedSpaceStrings_List[pName]
|
||||
nString = Chat\ComputeSpaceString pLabel
|
||||
nString = if not @CachedSpaceStrings_List[pName]
|
||||
Chat\ComputeSpaceString pLabel
|
||||
else
|
||||
nString = @CachedSpaceStrings_List[pName]
|
||||
end
|
||||
@CachedSpaceStrings_List[pName]
|
||||
|
||||
mLabel.Text = ""
|
||||
mLabel.Name = pName .. " - message"
|
||||
|
|
@ -1227,10 +1223,10 @@ Chat.CreateMessage = (cPlayer, message) =>
|
|||
TextStrokeTransparency: 0.75
|
||||
--Active = false
|
||||
|
||||
if cPlayer.Neutral
|
||||
pLabel.TextColor3 = Chat\ComputeChatColor pName
|
||||
pLabel.TextColor3 = if cPlayer.Neutral
|
||||
Chat\ComputeChatColor pName
|
||||
else
|
||||
pLabel.TextColor3 = cPlayer.TeamColor.Color
|
||||
cPlayer.TeamColor.Color
|
||||
|
||||
nString = if not @CachedSpaceStrings_List[pName]
|
||||
Chat\ComputeSpaceString pLabel
|
||||
|
|
@ -1331,7 +1327,7 @@ Chat.CreateSafeChatOptions = (list, rootButton) =>
|
|||
)
|
||||
|
||||
|
||||
count = count + 1
|
||||
count += 1
|
||||
|
||||
if type(list[msg]) == "table"
|
||||
text_List[rootButton][chatText] = Chat\CreateSafeChatOptions list[msg], chatText
|
||||
|
|
@ -1635,10 +1631,10 @@ Chat.CullThread ==>
|
|||
-- RobloxLock everything so users can't delete them(?)
|
||||
Chat.LockAllFields = (gui) =>
|
||||
children = gui\GetChildren!
|
||||
for i = 1, #children
|
||||
children[i].RobloxLocked = true
|
||||
if #children[i]\GetChildren! > 0
|
||||
Chat\LockAllFields children[i]
|
||||
for i in *children
|
||||
i.RobloxLocked = true
|
||||
if #i\GetChildren! > 0
|
||||
Chat\LockAllFields i
|
||||
|
||||
Chat.CoreGuiChanged = (coreGuiType, enabled) =>
|
||||
if coreGuiType == Enum.CoreGuiType.Chat or coreGuiType == Enum.CoreGuiType.All
|
||||
|
|
|
|||
Loading…
Reference in New Issue