@quenty/blend 12.19.0-canary.ae8d76d.0 → 12.19.1-canary.4ea661c.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -1
- package/package.json +16 -16
- package/src/Shared/Blend/Blend.lua +3 -3
- package/src/Shared/Blend/BlendDefaultProps.lua +19 -19
- package/src/Shared/Blend/SpringObject.lua +4 -5
- package/src/Shared/Test/BlendChildren.story.lua +68 -60
- package/src/Shared/Test/BlendComputePairs.story.lua +16 -15
- package/src/Shared/Test/BlendFind.story.lua +22 -18
- package/src/Shared/Test/BlendPromise.story.lua +57 -53
- package/src/Shared/Test/BlendSingle.story.lua +9 -9
- package/src/Shared/Test/BlendSpring.story.lua +22 -18
- package/src/Shared/Test/BlendTextbox.story.lua +26 -21
- package/test/scripts/Client/ClientMain.client.lua +8 -8
- package/test/scripts/Server/ServerMain.server.lua +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,7 +3,15 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
## [12.19.1-canary.4ea661c.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/blend@12.19.0...@quenty/blend@12.19.1-canary.4ea661c.0) (2025-08-12)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @quenty/blend
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# [12.19.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/blend@12.18.3...@quenty/blend@12.19.0) (2025-05-10)
|
|
7
15
|
|
|
8
16
|
**Note:** Version bump only for package @quenty/blend
|
|
9
17
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quenty/blend",
|
|
3
|
-
"version": "12.19.
|
|
3
|
+
"version": "12.19.1-canary.4ea661c.0",
|
|
4
4
|
"description": "Declarative UI system.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Roblox",
|
|
@@ -28,23 +28,23 @@
|
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
30
|
"@quenty/acceltween": "2.5.3",
|
|
31
|
-
"@quenty/brio": "14.18.
|
|
32
|
-
"@quenty/ducktype": "5.
|
|
33
|
-
"@quenty/instanceutils": "13.18.
|
|
34
|
-
"@quenty/loader": "10.
|
|
35
|
-
"@quenty/maid": "3.
|
|
36
|
-
"@quenty/promise": "10.11.0
|
|
37
|
-
"@quenty/rx": "13.18.
|
|
38
|
-
"@quenty/signal": "7.
|
|
39
|
-
"@quenty/spring": "10.9.0
|
|
40
|
-
"@quenty/steputils": "3.
|
|
31
|
+
"@quenty/brio": "14.18.1-canary.4ea661c.0",
|
|
32
|
+
"@quenty/ducktype": "5.9.0",
|
|
33
|
+
"@quenty/instanceutils": "13.18.1-canary.4ea661c.0",
|
|
34
|
+
"@quenty/loader": "10.9.0",
|
|
35
|
+
"@quenty/maid": "3.5.0",
|
|
36
|
+
"@quenty/promise": "10.11.0",
|
|
37
|
+
"@quenty/rx": "13.18.1-canary.4ea661c.0",
|
|
38
|
+
"@quenty/signal": "7.11.1-canary.4ea661c.0",
|
|
39
|
+
"@quenty/spring": "10.9.0",
|
|
40
|
+
"@quenty/steputils": "3.6.0",
|
|
41
41
|
"@quenty/string": "3.3.3",
|
|
42
|
-
"@quenty/valuebaseutils": "13.18.
|
|
43
|
-
"@quenty/valueobject": "13.18.
|
|
42
|
+
"@quenty/valuebaseutils": "13.18.1-canary.4ea661c.0",
|
|
43
|
+
"@quenty/valueobject": "13.18.1-canary.4ea661c.0"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@quenty/contentproviderutils": "12.18.
|
|
47
|
-
"@quenty/playerthumbnailutils": "10.11.0
|
|
46
|
+
"@quenty/contentproviderutils": "12.18.1-canary.4ea661c.0",
|
|
47
|
+
"@quenty/playerthumbnailutils": "10.11.0"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "4ea661c3fb52b8a3843c7d879c98c1de8a733798"
|
|
50
50
|
}
|
|
@@ -8,19 +8,19 @@ local require = require(script.Parent.loader).load(script)
|
|
|
8
8
|
local AccelTween = require("AccelTween")
|
|
9
9
|
local BlendDefaultProps = require("BlendDefaultProps")
|
|
10
10
|
local Brio = require("Brio")
|
|
11
|
+
local BrioUtils = require("BrioUtils")
|
|
11
12
|
local Maid = require("Maid")
|
|
12
13
|
local MaidTaskUtils = require("MaidTaskUtils")
|
|
13
14
|
local Observable = require("Observable")
|
|
14
15
|
local Promise = require("Promise")
|
|
15
16
|
local Rx = require("Rx")
|
|
16
|
-
local
|
|
17
|
+
local RxBrioUtils = require("RxBrioUtils")
|
|
17
18
|
local RxInstanceUtils = require("RxInstanceUtils")
|
|
18
19
|
local RxValueBaseUtils = require("RxValueBaseUtils")
|
|
19
20
|
local Signal = require("Signal")
|
|
20
21
|
local StepUtils = require("StepUtils")
|
|
21
22
|
local ValueBaseUtils = require("ValueBaseUtils")
|
|
22
23
|
local ValueObject = require("ValueObject")
|
|
23
|
-
local RxBrioUtils = require("RxBrioUtils")
|
|
24
24
|
local SpringObject
|
|
25
25
|
|
|
26
26
|
local Blend = {}
|
|
@@ -1173,4 +1173,4 @@ function Blend.mount(instance: Instance, props: BlendProps): Maid.Maid
|
|
|
1173
1173
|
return maid
|
|
1174
1174
|
end
|
|
1175
1175
|
|
|
1176
|
-
return Blend
|
|
1176
|
+
return Blend
|
|
@@ -33,12 +33,12 @@ SOFTWARE.
|
|
|
33
33
|
return {
|
|
34
34
|
ScreenGui = {
|
|
35
35
|
ResetOnSpawn = false,
|
|
36
|
-
ZIndexBehavior = Enum.ZIndexBehavior.Sibling
|
|
36
|
+
ZIndexBehavior = Enum.ZIndexBehavior.Sibling,
|
|
37
37
|
},
|
|
38
38
|
|
|
39
39
|
BillboardGui = {
|
|
40
40
|
ResetOnSpawn = false,
|
|
41
|
-
ZIndexBehavior = Enum.ZIndexBehavior.Sibling
|
|
41
|
+
ZIndexBehavior = Enum.ZIndexBehavior.Sibling,
|
|
42
42
|
},
|
|
43
43
|
|
|
44
44
|
SurfaceGui = {
|
|
@@ -46,13 +46,13 @@ return {
|
|
|
46
46
|
ZIndexBehavior = Enum.ZIndexBehavior.Sibling,
|
|
47
47
|
|
|
48
48
|
SizingMode = Enum.SurfaceGuiSizingMode.PixelsPerStud,
|
|
49
|
-
PixelsPerStud = 50
|
|
49
|
+
PixelsPerStud = 50,
|
|
50
50
|
},
|
|
51
51
|
|
|
52
52
|
Frame = {
|
|
53
53
|
BackgroundColor3 = Color3.new(1, 1, 1),
|
|
54
54
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
55
|
-
BorderSizePixel = 0
|
|
55
|
+
BorderSizePixel = 0,
|
|
56
56
|
},
|
|
57
57
|
|
|
58
58
|
ScrollingFrame = {
|
|
@@ -60,7 +60,7 @@ return {
|
|
|
60
60
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
61
61
|
BorderSizePixel = 0,
|
|
62
62
|
|
|
63
|
-
ScrollBarImageColor3 = Color3.new(0, 0, 0)
|
|
63
|
+
ScrollBarImageColor3 = Color3.new(0, 0, 0),
|
|
64
64
|
},
|
|
65
65
|
|
|
66
66
|
TextLabel = {
|
|
@@ -71,7 +71,7 @@ return {
|
|
|
71
71
|
Font = Enum.Font.SourceSans,
|
|
72
72
|
Text = "",
|
|
73
73
|
TextColor3 = Color3.new(0, 0, 0),
|
|
74
|
-
TextSize = 14
|
|
74
|
+
TextSize = 14,
|
|
75
75
|
},
|
|
76
76
|
|
|
77
77
|
TextButton = {
|
|
@@ -84,7 +84,7 @@ return {
|
|
|
84
84
|
Font = Enum.Font.SourceSans,
|
|
85
85
|
Text = "",
|
|
86
86
|
TextColor3 = Color3.new(0, 0, 0),
|
|
87
|
-
TextSize = 14
|
|
87
|
+
TextSize = 14,
|
|
88
88
|
},
|
|
89
89
|
|
|
90
90
|
TextBox = {
|
|
@@ -97,13 +97,13 @@ return {
|
|
|
97
97
|
Font = Enum.Font.SourceSans,
|
|
98
98
|
Text = "",
|
|
99
99
|
TextColor3 = Color3.new(0, 0, 0),
|
|
100
|
-
TextSize = 14
|
|
100
|
+
TextSize = 14,
|
|
101
101
|
},
|
|
102
102
|
|
|
103
103
|
ImageLabel = {
|
|
104
104
|
BackgroundColor3 = Color3.new(1, 1, 1),
|
|
105
105
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
106
|
-
BorderSizePixel = 0
|
|
106
|
+
BorderSizePixel = 0,
|
|
107
107
|
},
|
|
108
108
|
|
|
109
109
|
ImageButton = {
|
|
@@ -111,31 +111,31 @@ return {
|
|
|
111
111
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
112
112
|
BorderSizePixel = 0,
|
|
113
113
|
|
|
114
|
-
AutoButtonColor = false
|
|
114
|
+
AutoButtonColor = false,
|
|
115
115
|
},
|
|
116
116
|
|
|
117
117
|
ViewportFrame = {
|
|
118
118
|
BackgroundColor3 = Color3.new(1, 1, 1),
|
|
119
119
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
120
|
-
BorderSizePixel = 0
|
|
120
|
+
BorderSizePixel = 0,
|
|
121
121
|
},
|
|
122
122
|
|
|
123
123
|
VideoFrame = {
|
|
124
124
|
BackgroundColor3 = Color3.new(1, 1, 1),
|
|
125
125
|
BorderColor3 = Color3.new(0, 0, 0),
|
|
126
|
-
BorderSizePixel = 0
|
|
126
|
+
BorderSizePixel = 0,
|
|
127
127
|
},
|
|
128
128
|
|
|
129
129
|
UIListLayout = {
|
|
130
|
-
SortOrder = Enum.SortOrder.LayoutOrder
|
|
130
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
131
131
|
},
|
|
132
132
|
|
|
133
133
|
Sound = {
|
|
134
|
-
RollOffMode = Enum.RollOffMode.InverseTapered
|
|
135
|
-
}
|
|
134
|
+
RollOffMode = Enum.RollOffMode.InverseTapered,
|
|
135
|
+
},
|
|
136
136
|
|
|
137
137
|
Part = {
|
|
138
|
-
TopSurface = Enum.SurfaceType.Smooth
|
|
139
|
-
BottomSurface = Enum.SurfaceType.Smooth
|
|
140
|
-
}
|
|
141
|
-
}
|
|
138
|
+
TopSurface = Enum.SurfaceType.Smooth,
|
|
139
|
+
BottomSurface = Enum.SurfaceType.Smooth,
|
|
140
|
+
},
|
|
141
|
+
}
|
|
@@ -603,7 +603,6 @@ function SpringObject:_getSpringForType(converted)
|
|
|
603
603
|
local currentSpring = rawget(self, "_currentSpring")
|
|
604
604
|
|
|
605
605
|
if currentSpring == nil then
|
|
606
|
-
|
|
607
606
|
-- only happens on init
|
|
608
607
|
local newSpring = Spring.new(converted)
|
|
609
608
|
|
|
@@ -649,9 +648,9 @@ function SpringObject:_getInitInfo()
|
|
|
649
648
|
end
|
|
650
649
|
|
|
651
650
|
local value = {
|
|
652
|
-
Clock = os.clock
|
|
653
|
-
Damper = 1
|
|
654
|
-
Speed = 1
|
|
651
|
+
Clock = os.clock,
|
|
652
|
+
Damper = 1,
|
|
653
|
+
Speed = 1,
|
|
655
654
|
}
|
|
656
655
|
|
|
657
656
|
rawset(self, "_initInfo", value)
|
|
@@ -667,4 +666,4 @@ function SpringObject:Destroy()
|
|
|
667
666
|
setmetatable(self, nil)
|
|
668
667
|
end
|
|
669
668
|
|
|
670
|
-
return SpringObject
|
|
669
|
+
return SpringObject
|
|
@@ -2,14 +2,15 @@
|
|
|
2
2
|
@class Blend.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local RunService = game:GetService("RunService")
|
|
8
9
|
|
|
9
10
|
local Blend = require("Blend")
|
|
10
11
|
local Maid = require("Maid")
|
|
11
|
-
local ValueObject = require("ValueObject")
|
|
12
12
|
local Rx = require("Rx")
|
|
13
|
+
local ValueObject = require("ValueObject")
|
|
13
14
|
|
|
14
15
|
return function(target)
|
|
15
16
|
local maid = Maid.new()
|
|
@@ -20,54 +21,54 @@ return function(target)
|
|
|
20
21
|
|
|
21
22
|
local uiCornerValueObject = ValueObject.new()
|
|
22
23
|
uiCornerValueObject.Value = Blend.New "UICorner" {
|
|
23
|
-
CornerRadius = UDim.new(0, 5)
|
|
24
|
-
}
|
|
24
|
+
CornerRadius = UDim.new(0, 5),
|
|
25
|
+
}
|
|
25
26
|
maid:GiveTask(uiCornerValueObject)
|
|
26
27
|
|
|
27
28
|
-- Reassign to a new value
|
|
28
29
|
maid:GiveTask(task.delay(1, function()
|
|
29
30
|
uiCornerValueObject.Value = Blend.New "UICorner" {
|
|
30
|
-
CornerRadius = UDim.new(0, 5)
|
|
31
|
-
}
|
|
31
|
+
CornerRadius = UDim.new(0, 5),
|
|
32
|
+
}
|
|
32
33
|
end))
|
|
33
34
|
|
|
34
35
|
local transparency = Blend.Computed(percentVisible, function(visible)
|
|
35
36
|
return 1 - visible
|
|
36
|
-
end)
|
|
37
|
+
end)
|
|
37
38
|
|
|
38
39
|
-- Try a kitchen sink of items
|
|
39
40
|
maid:GiveTask((Blend.New "TextLabel" {
|
|
40
|
-
Parent = target
|
|
41
|
-
Font = Enum.Font.FredokaOne
|
|
41
|
+
Parent = target,
|
|
42
|
+
Font = Enum.Font.FredokaOne,
|
|
42
43
|
Size = Blend.Computed(percentVisible, function(visible)
|
|
43
|
-
return UDim2.new(0, visible*100 + 50, 0, 50)
|
|
44
|
-
end)
|
|
45
|
-
TextTransparency = transparency
|
|
46
|
-
BackgroundTransparency = transparency
|
|
47
|
-
Position = UDim2.new(0.5, 0, 0.5, 0)
|
|
48
|
-
AnchorPoint = Vector2.new(0.5, 0.5)
|
|
49
|
-
Text = state
|
|
50
|
-
TextSize = 15
|
|
51
|
-
TextScaled = false
|
|
44
|
+
return UDim2.new(0, visible * 100 + 50, 0, 50)
|
|
45
|
+
end),
|
|
46
|
+
TextTransparency = transparency,
|
|
47
|
+
BackgroundTransparency = transparency,
|
|
48
|
+
Position = UDim2.new(0.5, 0, 0.5, 0),
|
|
49
|
+
AnchorPoint = Vector2.new(0.5, 0.5),
|
|
50
|
+
Text = state,
|
|
51
|
+
TextSize = 15,
|
|
52
|
+
TextScaled = false,
|
|
52
53
|
|
|
53
54
|
[Blend.Children] = {
|
|
54
55
|
Blend.New "UIPadding" {
|
|
55
|
-
PaddingLeft = UDim.new(0, 10)
|
|
56
|
-
PaddingRight = UDim.new(0, 10)
|
|
57
|
-
PaddingTop = UDim.new(0, 10)
|
|
58
|
-
PaddingBottom = UDim.new(0, 10)
|
|
59
|
-
}
|
|
56
|
+
PaddingLeft = UDim.new(0, 10),
|
|
57
|
+
PaddingRight = UDim.new(0, 10),
|
|
58
|
+
PaddingTop = UDim.new(0, 10),
|
|
59
|
+
PaddingBottom = UDim.new(0, 10),
|
|
60
|
+
},
|
|
60
61
|
|
|
61
62
|
Blend.New "UIScale" {
|
|
62
63
|
Scale = Blend.Computed(percentVisible, function(visible)
|
|
63
|
-
return 0.8 + 0.2*visible
|
|
64
|
-
end)
|
|
65
|
-
}
|
|
64
|
+
return 0.8 + 0.2 * visible
|
|
65
|
+
end),
|
|
66
|
+
},
|
|
66
67
|
|
|
67
|
-
uiCornerValueObject
|
|
68
|
+
uiCornerValueObject,
|
|
68
69
|
|
|
69
|
-
Rx.NEVER
|
|
70
|
-
Rx.EMPTY
|
|
70
|
+
Rx.NEVER,
|
|
71
|
+
Rx.EMPTY,
|
|
71
72
|
|
|
72
73
|
{
|
|
73
74
|
Blend.Single(Blend.Computed(percentVisible, function(visible)
|
|
@@ -75,56 +76,63 @@ return function(target)
|
|
|
75
76
|
return nil
|
|
76
77
|
else
|
|
77
78
|
return Blend.New "Frame" {
|
|
78
|
-
Size = UDim2.new(0, 150, 0, 30)
|
|
79
|
-
AnchorPoint = Vector2.new(0.5, 0)
|
|
80
|
-
Position = UDim2.new(0.5, 0, 1, 10)
|
|
81
|
-
BackgroundTransparency = transparency
|
|
79
|
+
Size = UDim2.new(0, 150, 0, 30),
|
|
80
|
+
AnchorPoint = Vector2.new(0.5, 0),
|
|
81
|
+
Position = UDim2.new(0.5, 0, 1, 10),
|
|
82
|
+
BackgroundTransparency = transparency,
|
|
82
83
|
|
|
83
84
|
Blend.New "UICorner" {
|
|
84
|
-
CornerRadius = UDim.new(0, 10)
|
|
85
|
-
}
|
|
86
|
-
}
|
|
85
|
+
CornerRadius = UDim.new(0, 10),
|
|
86
|
+
},
|
|
87
|
+
}
|
|
87
88
|
end
|
|
88
|
-
end))
|
|
89
|
-
|
|
90
|
-
};
|
|
89
|
+
end)),
|
|
90
|
+
},
|
|
91
91
|
|
|
92
92
|
{
|
|
93
93
|
Blend.Single(Blend.Computed(percentVisible, function(visible)
|
|
94
94
|
local results = {}
|
|
95
95
|
|
|
96
96
|
-- constructs a ton of children everytime this changes
|
|
97
|
-
for x=0, visible*100, 20 do
|
|
98
|
-
table.insert(
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
97
|
+
for x = 0, visible * 100, 20 do
|
|
98
|
+
table.insert(
|
|
99
|
+
results,
|
|
100
|
+
Blend.New "Frame" {
|
|
101
|
+
Size = UDim2.new(0, 8, 0, 8),
|
|
102
|
+
Position = UDim2.new(x / 100, 0, 0.9, 0),
|
|
103
|
+
AnchorPoint = Vector2.new(0.5, 0.5),
|
|
104
|
+
BorderSizePixel = 0,
|
|
105
|
+
BackgroundColor3 = Color3.new(x / 100, 0.5, 0.5),
|
|
106
|
+
BackgroundTransparency = transparency,
|
|
107
|
+
|
|
108
|
+
[Blend.Children] = {
|
|
109
|
+
Blend.New "UICorner" {
|
|
110
|
+
CornerRadius = UDim.new(0, 10),
|
|
111
|
+
},
|
|
112
|
+
},
|
|
113
|
+
}
|
|
114
|
+
)
|
|
112
115
|
end
|
|
113
116
|
|
|
114
117
|
return results
|
|
115
|
-
end))
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
+
end)),
|
|
119
|
+
},
|
|
120
|
+
},
|
|
118
121
|
}):Subscribe())
|
|
119
122
|
|
|
120
123
|
local PERIOD = 5
|
|
121
124
|
maid:GiveTask(RunService.RenderStepped:Connect(function()
|
|
122
125
|
local timeElapsed = os.clock()
|
|
123
|
-
state.Value = string.format(
|
|
124
|
-
|
|
126
|
+
state.Value = string.format(
|
|
127
|
+
"%02d:%02d:%0.3d",
|
|
128
|
+
math.floor(timeElapsed / 60) % 60,
|
|
129
|
+
math.floor(timeElapsed % 60),
|
|
130
|
+
math.floor(timeElapsed * 1000) % 1000
|
|
131
|
+
)
|
|
132
|
+
percentVisible.Value = math.clamp((math.sin(os.clock() * math.pi * 2 / PERIOD) + 1), 0, 1)
|
|
125
133
|
end))
|
|
126
134
|
|
|
127
135
|
return function()
|
|
128
136
|
maid:DoCleaning()
|
|
129
137
|
end
|
|
130
|
-
end
|
|
138
|
+
end
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
@class Blend.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local Blend = require("Blend")
|
|
8
9
|
local Maid = require("Maid")
|
|
@@ -10,17 +11,17 @@ local Maid = require("Maid")
|
|
|
10
11
|
return function(target)
|
|
11
12
|
local maid = Maid.new()
|
|
12
13
|
|
|
13
|
-
local state = Blend.State({"a", "b", "c"})
|
|
14
|
+
local state = Blend.State({ "a", "b", "c" })
|
|
14
15
|
maid:GiveTask(state)
|
|
15
16
|
|
|
16
17
|
maid:GiveTask((Blend.New "TextLabel" {
|
|
17
|
-
Parent = target
|
|
18
|
+
Parent = target,
|
|
18
19
|
|
|
19
20
|
[Blend.Children] = {
|
|
20
21
|
Blend.New "TextButton" {
|
|
21
|
-
Text = "Add"
|
|
22
|
-
AutoButtonColor = true
|
|
23
|
-
Size = UDim2.new(0, 100, 0, 20)
|
|
22
|
+
Text = "Add",
|
|
23
|
+
AutoButtonColor = true,
|
|
24
|
+
Size = UDim2.new(0, 100, 0, 20),
|
|
24
25
|
[Blend.OnEvent "Activated"] = function()
|
|
25
26
|
local newState = {}
|
|
26
27
|
for _, item in state.Value do
|
|
@@ -28,23 +29,23 @@ return function(target)
|
|
|
28
29
|
end
|
|
29
30
|
table.insert(newState, string.char(string.byte("a") + #newState))
|
|
30
31
|
state.Value = newState
|
|
31
|
-
end
|
|
32
|
-
}
|
|
32
|
+
end,
|
|
33
|
+
},
|
|
33
34
|
Blend.ComputedPairs(state, function(_index, value)
|
|
34
35
|
print("Compute", value)
|
|
35
36
|
return Blend.New "TextLabel" {
|
|
36
|
-
Text = tostring(value)
|
|
37
|
-
Size = UDim2.new(0, 20, 0, 20)
|
|
37
|
+
Text = tostring(value),
|
|
38
|
+
Size = UDim2.new(0, 20, 0, 20),
|
|
38
39
|
}
|
|
39
|
-
end)
|
|
40
|
+
end),
|
|
40
41
|
|
|
41
42
|
Blend.New "UIListLayout" {
|
|
42
|
-
Padding = UDim.new(0, 5)
|
|
43
|
-
}
|
|
44
|
-
}
|
|
43
|
+
Padding = UDim.new(0, 5),
|
|
44
|
+
},
|
|
45
|
+
},
|
|
45
46
|
}):Subscribe())
|
|
46
47
|
|
|
47
48
|
return function()
|
|
48
49
|
maid:DoCleaning()
|
|
49
50
|
end
|
|
50
|
-
end
|
|
51
|
+
end
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
@class Blend.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local RunService = game:GetService("RunService")
|
|
8
9
|
|
|
@@ -15,9 +16,12 @@ return function(target)
|
|
|
15
16
|
local isVisible = Instance.new("BoolValue")
|
|
16
17
|
isVisible.Value = false
|
|
17
18
|
|
|
18
|
-
local percentVisible = Blend.Spring(
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
local percentVisible = Blend.Spring(
|
|
20
|
+
Blend.Computed(isVisible, function(visible)
|
|
21
|
+
return visible and 1 or 0
|
|
22
|
+
end),
|
|
23
|
+
35
|
|
24
|
+
)
|
|
21
25
|
|
|
22
26
|
local transparency = Blend.Computed(percentVisible, function(percent)
|
|
23
27
|
return 1 - percent
|
|
@@ -33,7 +37,7 @@ return function(target)
|
|
|
33
37
|
maid:GiveTask(frame)
|
|
34
38
|
|
|
35
39
|
local subFrame = Instance.new("Frame")
|
|
36
|
-
subFrame.Name = "CenterFrame"
|
|
40
|
+
subFrame.Name = "CenterFrame"
|
|
37
41
|
subFrame.Size = UDim2.new(0.5, 0, 0.5, 0)
|
|
38
42
|
subFrame.BackgroundColor3 = Color3.new(0.5, 0.5, 0.5)
|
|
39
43
|
subFrame.AnchorPoint = Vector2.new(0.5, 0.5)
|
|
@@ -46,35 +50,35 @@ return function(target)
|
|
|
46
50
|
uiScale.Parent = subFrame
|
|
47
51
|
|
|
48
52
|
maid:GiveTask(Blend.mount(frame, {
|
|
49
|
-
Size = UDim2.new(0.5, 0, 0.5, 0)
|
|
53
|
+
Size = UDim2.new(0.5, 0, 0.5, 0),
|
|
50
54
|
|
|
51
55
|
Blend.New "UICorner" {
|
|
52
|
-
CornerRadius = UDim.new(0.05, 0)
|
|
53
|
-
}
|
|
56
|
+
CornerRadius = UDim.new(0.05, 0),
|
|
57
|
+
},
|
|
54
58
|
|
|
55
59
|
Blend.Find "Frame" {
|
|
56
|
-
Name = "CenterFrame"
|
|
60
|
+
Name = "CenterFrame",
|
|
57
61
|
|
|
58
62
|
Blend.Find "UIScale" {
|
|
59
|
-
Name = "MyUIScale"
|
|
63
|
+
Name = "MyUIScale",
|
|
60
64
|
|
|
61
65
|
Scale = Blend.Computed(percentVisible, function(percent)
|
|
62
|
-
return 0.8 + 0.2*percent
|
|
63
|
-
end)
|
|
64
|
-
}
|
|
66
|
+
return 0.8 + 0.2 * percent
|
|
67
|
+
end),
|
|
68
|
+
},
|
|
65
69
|
|
|
66
70
|
Blend.New "UICorner" {
|
|
67
|
-
CornerRadius = UDim.new(0.05, 0)
|
|
68
|
-
}
|
|
69
|
-
}
|
|
71
|
+
CornerRadius = UDim.new(0.05, 0),
|
|
72
|
+
},
|
|
73
|
+
},
|
|
70
74
|
}))
|
|
71
75
|
|
|
72
76
|
local PERIOD = 2
|
|
73
77
|
maid:GiveTask(RunService.RenderStepped:Connect(function()
|
|
74
|
-
isVisible.Value = os.clock()/PERIOD % 1 < 0.5
|
|
78
|
+
isVisible.Value = os.clock() / PERIOD % 1 < 0.5
|
|
75
79
|
end))
|
|
76
80
|
|
|
77
81
|
return function()
|
|
78
82
|
maid:DoCleaning()
|
|
79
83
|
end
|
|
80
|
-
end
|
|
84
|
+
end
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
@class BlendTextbox.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local RunService = game:GetService("RunService")
|
|
8
9
|
|
|
@@ -27,81 +28,84 @@ return function(target)
|
|
|
27
28
|
local userName = Blend.Dynamic(userIdState, function(userId)
|
|
28
29
|
return PlayerThumbnailUtils.promiseUserName(userId)
|
|
29
30
|
end)
|
|
30
|
-
local percentVisible = Blend.Spring(
|
|
31
|
-
|
|
32
|
-
|
|
31
|
+
local percentVisible = Blend.Spring(
|
|
32
|
+
Blend.Computed(isVisible, function(visible)
|
|
33
|
+
return visible and 1 or 0
|
|
34
|
+
end),
|
|
35
|
+
35
|
|
36
|
+
)
|
|
33
37
|
local transparency = Blend.Computed(percentVisible, function(percent)
|
|
34
38
|
return 1 - percent
|
|
35
39
|
end)
|
|
36
40
|
|
|
37
41
|
maid:GiveTask((Blend.New "Frame" {
|
|
38
|
-
Parent = target
|
|
39
|
-
Name = "ProfileImage"
|
|
40
|
-
LayoutOrder = 15
|
|
41
|
-
BackgroundTransparency = 1
|
|
42
|
-
Size = UDim2.new(0, 100, 0, 130)
|
|
43
|
-
Position = UDim2.fromScale(0.5, 0.5)
|
|
44
|
-
AnchorPoint = Vector2.new(0.5, 0.5)
|
|
42
|
+
Parent = target,
|
|
43
|
+
Name = "ProfileImage",
|
|
44
|
+
LayoutOrder = 15,
|
|
45
|
+
BackgroundTransparency = 1,
|
|
46
|
+
Size = UDim2.new(0, 100, 0, 130),
|
|
47
|
+
Position = UDim2.fromScale(0.5, 0.5),
|
|
48
|
+
AnchorPoint = Vector2.new(0.5, 0.5),
|
|
45
49
|
[Blend.Children] = {
|
|
46
50
|
Blend.New "UIScale" {
|
|
47
51
|
Scale = Blend.Computed(percentVisible, function(percent)
|
|
48
|
-
return 0.8 + 0.2*percent
|
|
49
|
-
end)
|
|
50
|
-
}
|
|
52
|
+
return 0.8 + 0.2 * percent
|
|
53
|
+
end),
|
|
54
|
+
},
|
|
51
55
|
|
|
52
56
|
Blend.New "TextLabel" {
|
|
53
|
-
Size = UDim2.new(1, 0, 0, 30)
|
|
54
|
-
Position = UDim2.new(0.5, 0, 1, 0)
|
|
55
|
-
AnchorPoint = Vector2.new(0.5, 1)
|
|
56
|
-
BackgroundTransparency = 1
|
|
57
|
-
TextTransparency = transparency
|
|
58
|
-
TextColor3 = Color3.new(1, 1, 1)
|
|
59
|
-
TextSize = 20
|
|
60
|
-
Font = Enum.Font.Gotham
|
|
61
|
-
Text = userName
|
|
62
|
-
}
|
|
57
|
+
Size = UDim2.new(1, 0, 0, 30),
|
|
58
|
+
Position = UDim2.new(0.5, 0, 1, 0),
|
|
59
|
+
AnchorPoint = Vector2.new(0.5, 1),
|
|
60
|
+
BackgroundTransparency = 1,
|
|
61
|
+
TextTransparency = transparency,
|
|
62
|
+
TextColor3 = Color3.new(1, 1, 1),
|
|
63
|
+
TextSize = 20,
|
|
64
|
+
Font = Enum.Font.Gotham,
|
|
65
|
+
Text = userName,
|
|
66
|
+
},
|
|
63
67
|
|
|
64
68
|
Blend.New "Frame" {
|
|
65
|
-
Position = UDim2.new(0.5, 0, 0, 0)
|
|
66
|
-
AnchorPoint = Vector2.new(0.5, 0)
|
|
67
|
-
Size = UDim2.new(1, 0, 1, 0)
|
|
68
|
-
BackgroundColor3 = Color3.new(0.2, 0.25, 0.2)
|
|
69
|
-
BackgroundTransparency = transparency
|
|
69
|
+
Position = UDim2.new(0.5, 0, 0, 0),
|
|
70
|
+
AnchorPoint = Vector2.new(0.5, 0),
|
|
71
|
+
Size = UDim2.new(1, 0, 1, 0),
|
|
72
|
+
BackgroundColor3 = Color3.new(0.2, 0.25, 0.2),
|
|
73
|
+
BackgroundTransparency = transparency,
|
|
70
74
|
[Blend.Children] = {
|
|
71
75
|
Blend.New "UIAspectRatioConstraint" {
|
|
72
|
-
AspectRatio = 1
|
|
73
|
-
}
|
|
76
|
+
AspectRatio = 1,
|
|
77
|
+
},
|
|
74
78
|
Blend.New "UICorner" {
|
|
75
|
-
CornerRadius = UDim.new(1, 0)
|
|
76
|
-
}
|
|
79
|
+
CornerRadius = UDim.new(1, 0),
|
|
80
|
+
},
|
|
77
81
|
Blend.New "UIPadding" {
|
|
78
|
-
PaddingLeft = UDim.new(0, 2)
|
|
79
|
-
PaddingRight = UDim.new(0, 2)
|
|
80
|
-
PaddingTop = UDim.new(0, 2)
|
|
81
|
-
PaddingBottom = UDim.new(0, 2)
|
|
82
|
-
}
|
|
82
|
+
PaddingLeft = UDim.new(0, 2),
|
|
83
|
+
PaddingRight = UDim.new(0, 2),
|
|
84
|
+
PaddingTop = UDim.new(0, 2),
|
|
85
|
+
PaddingBottom = UDim.new(0, 2),
|
|
86
|
+
},
|
|
83
87
|
|
|
84
88
|
Blend.New "ImageLabel" {
|
|
85
|
-
Size = UDim2.new(1, 0, 1, 0)
|
|
86
|
-
Image = userImage
|
|
87
|
-
BackgroundTransparency = transparency
|
|
88
|
-
ImageTransparency = transparency
|
|
89
|
-
BackgroundColor3 = Color3.new(0.1, 0.1, 0.1)
|
|
89
|
+
Size = UDim2.new(1, 0, 1, 0),
|
|
90
|
+
Image = userImage,
|
|
91
|
+
BackgroundTransparency = transparency,
|
|
92
|
+
ImageTransparency = transparency,
|
|
93
|
+
BackgroundColor3 = Color3.new(0.1, 0.1, 0.1),
|
|
90
94
|
|
|
91
95
|
[Blend.Children] = {
|
|
92
96
|
Blend.New "UICorner" {
|
|
93
|
-
CornerRadius = UDim.new(1, 0)
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
97
|
+
CornerRadius = UDim.new(1, 0),
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
},
|
|
100
104
|
}):Subscribe())
|
|
101
105
|
|
|
102
106
|
local PERIOD = 2
|
|
103
107
|
maid:GiveTask(RunService.RenderStepped:Connect(function()
|
|
104
|
-
isVisible.Value = os.clock()/PERIOD % 1 < 0.5
|
|
108
|
+
isVisible.Value = os.clock() / PERIOD % 1 < 0.5
|
|
105
109
|
end))
|
|
106
110
|
|
|
107
111
|
local alive = true
|
|
@@ -110,7 +114,7 @@ return function(target)
|
|
|
110
114
|
end)
|
|
111
115
|
maid:GiveTask(isVisible.Changed:Connect(function()
|
|
112
116
|
if not isVisible.Value then
|
|
113
|
-
task.delay(PERIOD/2, function()
|
|
117
|
+
task.delay(PERIOD / 2, function()
|
|
114
118
|
if alive then
|
|
115
119
|
userIdState.Value = Random.new():NextInteger(1, 1e9)
|
|
116
120
|
end
|
|
@@ -121,4 +125,4 @@ return function(target)
|
|
|
121
125
|
return function()
|
|
122
126
|
maid:DoCleaning()
|
|
123
127
|
end
|
|
124
|
-
end
|
|
128
|
+
end
|
|
@@ -2,11 +2,12 @@
|
|
|
2
2
|
@class BlendSingle.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
8
|
+
local Blend = require("Blend")
|
|
7
9
|
local Maid = require("Maid")
|
|
8
10
|
local Observable = require("Observable")
|
|
9
|
-
local Blend = require("Blend")
|
|
10
11
|
|
|
11
12
|
return function(target)
|
|
12
13
|
local maid = Maid.new()
|
|
@@ -15,10 +16,10 @@ return function(target)
|
|
|
15
16
|
|
|
16
17
|
local result = Blend.Single(Blend.Dynamic(state, function(text)
|
|
17
18
|
return Blend.New "TextLabel" {
|
|
18
|
-
Parent = target
|
|
19
|
-
Text = text
|
|
20
|
-
Size = UDim2.new(1, 0, 1, 0)
|
|
21
|
-
BackgroundTransparency = 0.5
|
|
19
|
+
Parent = target,
|
|
20
|
+
Text = text,
|
|
21
|
+
Size = UDim2.new(1, 0, 1, 0),
|
|
22
|
+
BackgroundTransparency = 0.5,
|
|
22
23
|
[function()
|
|
23
24
|
return Observable.new(function()
|
|
24
25
|
local internal = Maid.new()
|
|
@@ -30,11 +31,10 @@ return function(target)
|
|
|
30
31
|
|
|
31
32
|
return internal
|
|
32
33
|
end)
|
|
33
|
-
end] = true
|
|
34
|
+
end] = true,
|
|
34
35
|
}
|
|
35
36
|
end))
|
|
36
37
|
|
|
37
|
-
|
|
38
38
|
maid:GiveTask(result:Subscribe())
|
|
39
39
|
|
|
40
40
|
state.Value = "b"
|
|
@@ -42,4 +42,4 @@ return function(target)
|
|
|
42
42
|
return function()
|
|
43
43
|
maid:DoCleaning()
|
|
44
44
|
end
|
|
45
|
-
end
|
|
45
|
+
end
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
@class Blend.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local RunService = game:GetService("RunService")
|
|
8
9
|
|
|
@@ -15,40 +16,43 @@ return function(target)
|
|
|
15
16
|
local isVisible = Instance.new("BoolValue")
|
|
16
17
|
isVisible.Value = false
|
|
17
18
|
|
|
18
|
-
local percentVisible = Blend.Spring(
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
local percentVisible = Blend.Spring(
|
|
20
|
+
Blend.Computed(isVisible, function(visible)
|
|
21
|
+
return visible and 1 or 0
|
|
22
|
+
end),
|
|
23
|
+
35
|
|
24
|
+
)
|
|
21
25
|
|
|
22
26
|
local transparency = Blend.Computed(percentVisible, function(percent)
|
|
23
27
|
return 1 - percent
|
|
24
28
|
end)
|
|
25
29
|
|
|
26
30
|
maid:GiveTask((Blend.New "Frame" {
|
|
27
|
-
Size = UDim2.new(0.5, 0, 0.5, 0)
|
|
28
|
-
BackgroundColor3 = Color3.new(0.9, 0.9, 0.9)
|
|
29
|
-
AnchorPoint = Vector2.new(0.5, 0.5)
|
|
30
|
-
Position = UDim2.new(0.5, 0, 0.5, 0)
|
|
31
|
-
BackgroundTransparency = transparency
|
|
32
|
-
Parent = target
|
|
31
|
+
Size = UDim2.new(0.5, 0, 0.5, 0),
|
|
32
|
+
BackgroundColor3 = Color3.new(0.9, 0.9, 0.9),
|
|
33
|
+
AnchorPoint = Vector2.new(0.5, 0.5),
|
|
34
|
+
Position = UDim2.new(0.5, 0, 0.5, 0),
|
|
35
|
+
BackgroundTransparency = transparency,
|
|
36
|
+
Parent = target,
|
|
33
37
|
|
|
34
38
|
[Blend.Children] = {
|
|
35
39
|
Blend.New "UIScale" {
|
|
36
40
|
Scale = Blend.Computed(percentVisible, function(percent)
|
|
37
|
-
return 0.8 + 0.2*percent
|
|
38
|
-
end)
|
|
39
|
-
}
|
|
41
|
+
return 0.8 + 0.2 * percent
|
|
42
|
+
end),
|
|
43
|
+
},
|
|
40
44
|
Blend.New "UICorner" {
|
|
41
|
-
CornerRadius = UDim.new(0.05, 0)
|
|
42
|
-
}
|
|
43
|
-
}
|
|
45
|
+
CornerRadius = UDim.new(0.05, 0),
|
|
46
|
+
},
|
|
47
|
+
},
|
|
44
48
|
}):Subscribe())
|
|
45
49
|
|
|
46
50
|
local PERIOD = 5
|
|
47
51
|
maid:GiveTask(RunService.RenderStepped:Connect(function()
|
|
48
|
-
isVisible.Value = os.clock()/PERIOD % 1 < 0.5
|
|
52
|
+
isVisible.Value = os.clock() / PERIOD % 1 < 0.5
|
|
49
53
|
end))
|
|
50
54
|
|
|
51
55
|
return function()
|
|
52
56
|
maid:DoCleaning()
|
|
53
57
|
end
|
|
54
|
-
end
|
|
58
|
+
end
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
@class BlendTextbox.story
|
|
3
3
|
]]
|
|
4
4
|
|
|
5
|
-
local require =
|
|
5
|
+
local require =
|
|
6
|
+
require(game:GetService("ServerScriptService"):FindFirstChild("LoaderUtils", true).Parent).bootstrapStory(script)
|
|
6
7
|
|
|
7
8
|
local Blend = require("Blend")
|
|
8
9
|
local Maid = require("Maid")
|
|
@@ -13,42 +14,46 @@ return function(target)
|
|
|
13
14
|
local state = Blend.State("hi")
|
|
14
15
|
|
|
15
16
|
maid:GiveTask((Blend.New "Frame" {
|
|
16
|
-
Size = UDim2.new(1, 0, 1, 0)
|
|
17
|
-
BackgroundTransparency = 1
|
|
18
|
-
Parent = target
|
|
17
|
+
Size = UDim2.new(1, 0, 1, 0),
|
|
18
|
+
BackgroundTransparency = 1,
|
|
19
|
+
Parent = target,
|
|
19
20
|
|
|
20
21
|
[Blend.Children] = {
|
|
21
22
|
Blend.New "TextBox" {
|
|
22
|
-
Size = UDim2.new(0, 200, 0, 50)
|
|
23
|
-
Text = state
|
|
24
|
-
[Blend.OnChange "Text"] = state
|
|
23
|
+
Size = UDim2.new(0, 200, 0, 50),
|
|
24
|
+
Text = state,
|
|
25
|
+
[Blend.OnChange "Text"] = state,
|
|
25
26
|
[Blend.OnEvent "Focused"] = function()
|
|
26
27
|
print("Focused")
|
|
27
|
-
end
|
|
28
|
+
end,
|
|
28
29
|
|
|
29
|
-
[function(inst)
|
|
30
|
+
[function(inst)
|
|
31
|
+
return inst.Focused
|
|
32
|
+
end] = function()
|
|
30
33
|
print("Focused (via func)")
|
|
31
|
-
end
|
|
34
|
+
end,
|
|
32
35
|
|
|
33
36
|
-- this also works
|
|
34
|
-
[function(inst)
|
|
37
|
+
[function(inst)
|
|
38
|
+
return inst:GetPropertyChangedSignal("Text")
|
|
39
|
+
end] = function()
|
|
35
40
|
print("Property changed from :GetPropertyChangedSignal()")
|
|
36
|
-
end
|
|
37
|
-
}
|
|
41
|
+
end,
|
|
42
|
+
},
|
|
38
43
|
|
|
39
44
|
Blend.New "TextBox" {
|
|
40
|
-
Size = UDim2.new(0, 200, 0, 50)
|
|
41
|
-
[Blend.OnChange "Text"] = state
|
|
42
|
-
Text = state
|
|
43
|
-
}
|
|
45
|
+
Size = UDim2.new(0, 200, 0, 50),
|
|
46
|
+
[Blend.OnChange "Text"] = state, -- read state
|
|
47
|
+
Text = state, -- write state
|
|
48
|
+
},
|
|
44
49
|
|
|
45
50
|
Blend.New "UIListLayout" {
|
|
46
|
-
Padding = UDim.new(0, 10)
|
|
47
|
-
}
|
|
48
|
-
}
|
|
51
|
+
Padding = UDim.new(0, 10),
|
|
52
|
+
},
|
|
53
|
+
},
|
|
49
54
|
}):Subscribe())
|
|
50
55
|
|
|
51
56
|
return function()
|
|
52
57
|
maid:DoCleaning()
|
|
53
58
|
end
|
|
54
|
-
end
|
|
59
|
+
end
|
|
@@ -10,15 +10,15 @@ local PlayerGuiUtils = require("PlayerGuiUtils")
|
|
|
10
10
|
local state = Blend.State("a")
|
|
11
11
|
|
|
12
12
|
Blend.New "ScreenGui" {
|
|
13
|
-
Parent = PlayerGuiUtils.getPlayerGui()
|
|
13
|
+
Parent = PlayerGuiUtils.getPlayerGui(),
|
|
14
14
|
[Blend.Children] = {
|
|
15
15
|
Blend.New "TextLabel" {
|
|
16
|
-
Size = UDim2.new(0, 100, 0, 50)
|
|
17
|
-
Position = UDim2.new(0.5, 0, 0.5, 0)
|
|
18
|
-
AnchorPoint = Vector2.new(0.5, 0.5)
|
|
19
|
-
Text = state
|
|
20
|
-
}
|
|
21
|
-
}
|
|
16
|
+
Size = UDim2.new(0, 100, 0, 50),
|
|
17
|
+
Position = UDim2.new(0.5, 0, 0.5, 0),
|
|
18
|
+
AnchorPoint = Vector2.new(0.5, 0.5),
|
|
19
|
+
Text = state,
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
-
state.Value = "hi"
|
|
24
|
+
state.Value = "hi"
|