@quenty/adorneeutils 3.3.5 → 3.3.6
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 +16 -81
- package/deploy.nevermore.json +10 -0
- package/package.json +8 -2
- package/src/Shared/AdorneeUtils.lua +32 -23
- package/src/Shared/AdorneeUtils.spec.lua +1086 -0
- package/src/jest.config.lua +3 -0
- package/src/node_modules.project.json +7 -0
- package/test/default.project.json +25 -0
- package/test/scripts/Server/ServerMain.server.lua +14 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,160 +3,95 @@
|
|
|
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
|
-
## [3.3.
|
|
7
|
-
|
|
6
|
+
## [3.3.6](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.5...@quenty/adorneeutils@3.3.6) (2026-08-24)
|
|
8
7
|
|
|
9
8
|
### Bug Fixes
|
|
10
9
|
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
- Tools being treated as models/instances in AdorneeUtils because of inheritance change ([048dcb5](https://github.com/Quenty/NevermoreEngine/commit/048dcb5460c2c221fac027d5746b2e5692a3a37c))
|
|
13
11
|
|
|
12
|
+
## [3.3.5](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.4...@quenty/adorneeutils@3.3.5) (2026-01-12)
|
|
14
13
|
|
|
14
|
+
### Bug Fixes
|
|
15
15
|
|
|
16
|
+
- Fix dependency installation process for pnpm ([9651b09](https://github.com/Quenty/NevermoreEngine/commit/9651b09af34f252ef3f9c7c539793cc878dd8cba))
|
|
16
17
|
|
|
17
18
|
## [3.3.4](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.3...@quenty/adorneeutils@3.3.4) (2026-01-10)
|
|
18
19
|
|
|
19
20
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
20
21
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
22
|
## [3.3.3](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.1...@quenty/adorneeutils@3.3.3) (2025-04-07)
|
|
26
23
|
|
|
27
|
-
|
|
28
24
|
### Bug Fixes
|
|
29
25
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
26
|
+
- Add types to packages ([2374fb2](https://github.com/Quenty/NevermoreEngine/commit/2374fb2b043cfbe0e9b507b3316eec46a4e353a0))
|
|
27
|
+
- Bump package versions for republishing ([ba47c62](https://github.com/Quenty/NevermoreEngine/commit/ba47c62e32170bf74377b0c658c60b84306dc294))
|
|
36
28
|
|
|
37
29
|
## [3.3.2](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.1...@quenty/adorneeutils@3.3.2) (2025-04-07)
|
|
38
30
|
|
|
39
|
-
|
|
40
31
|
### Bug Fixes
|
|
41
32
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
33
|
+
- Add types to packages ([2374fb2](https://github.com/Quenty/NevermoreEngine/commit/2374fb2b043cfbe0e9b507b3316eec46a4e353a0))
|
|
47
34
|
|
|
48
35
|
## [3.3.1](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.3.0...@quenty/adorneeutils@3.3.1) (2025-03-21)
|
|
49
36
|
|
|
50
37
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
51
38
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
39
|
# [3.3.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.2.0...@quenty/adorneeutils@3.3.0) (2024-12-03)
|
|
57
40
|
|
|
58
|
-
|
|
59
41
|
### Bug Fixes
|
|
60
42
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
43
|
+
- Use modern Roblox APIs ([b4b9047](https://github.com/Quenty/NevermoreEngine/commit/b4b90471fbb678c6fb84664dbfc32cb9bfc56c2c))
|
|
66
44
|
|
|
67
45
|
# [3.2.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.1.0...@quenty/adorneeutils@3.2.0) (2024-05-09)
|
|
68
46
|
|
|
69
|
-
|
|
70
47
|
### Bug Fixes
|
|
71
48
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
49
|
+
- Fix .package-lock.json replicating in packages ([75d0efe](https://github.com/Quenty/NevermoreEngine/commit/75d0efeef239f221d93352af71a5b3e930ec23c5))
|
|
77
50
|
|
|
78
51
|
# [3.1.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@3.0.0...@quenty/adorneeutils@3.1.0) (2023-05-26)
|
|
79
52
|
|
|
80
|
-
|
|
81
53
|
### Features
|
|
82
54
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
55
|
+
- Initial refactor of guis to use ValueObject instead of ValueObject ([723aba0](https://github.com/Quenty/NevermoreEngine/commit/723aba0208cae7e06c9d8bf2d8f0092d042d70ea))
|
|
88
56
|
|
|
89
57
|
# [3.0.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@2.3.0...@quenty/adorneeutils@3.0.0) (2022-05-21)
|
|
90
58
|
|
|
91
59
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
92
60
|
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
61
|
# [2.3.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@2.2.0...@quenty/adorneeutils@2.3.0) (2022-03-27)
|
|
98
62
|
|
|
99
63
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
100
64
|
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
65
|
# [2.2.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@2.1.1...@quenty/adorneeutils@2.2.0) (2022-01-17)
|
|
106
66
|
|
|
107
67
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
108
68
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
69
|
## [2.1.1](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@2.1.0...@quenty/adorneeutils@2.1.1) (2021-12-30)
|
|
114
70
|
|
|
115
71
|
**Note:** Version bump only for package @quenty/adorneeutils
|
|
116
72
|
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
73
|
# [2.1.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@2.0.0...@quenty/adorneeutils@2.1.0) (2021-09-22)
|
|
122
74
|
|
|
123
|
-
|
|
124
75
|
### Bug Fixes
|
|
125
76
|
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
77
|
+
- Add attachment for bounding box in adornee utils ([e2d2f25](https://github.com/Quenty/NevermoreEngine/commit/e2d2f25027ea5acb3f9caff47e2919f9577e6318))
|
|
131
78
|
|
|
132
79
|
# [2.0.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/adorneeutils@1.2.0...@quenty/adorneeutils@2.0.0) (2021-09-05)
|
|
133
80
|
|
|
134
|
-
|
|
135
81
|
### Bug Fixes
|
|
136
82
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
83
|
+
- Remove peer dependencies. This is because lerna doesn't really support peer dependencies being linked and getting a new version on build, which is unfortunate. ([5f5aeee](https://github.com/Quenty/NevermoreEngine/commit/5f5aeeea8de9975435309e53679f0ef7064f9dd0))
|
|
142
84
|
|
|
143
85
|
# 1.2.0 (2021-07-31)
|
|
144
86
|
|
|
145
|
-
|
|
146
87
|
### Bug Fixes
|
|
147
88
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
89
|
+
- Add CI and CD ([47513e9](https://github.com/Quenty/NevermoreEngine/commit/47513e9b568162707534af132396dd8756947dd3))
|
|
90
|
+
- Adjust CI badge to show automatic build and release state ([5a55d3f](https://github.com/Quenty/NevermoreEngine/commit/5a55d3f19bf8d66a760d67da9b56ed47fab74656))
|
|
91
|
+
- Fix selene linting ([45fc074](https://github.com/Quenty/NevermoreEngine/commit/45fc07489ee59127ac6582689f19a0e87c1e5b5a))
|
|
153
92
|
|
|
154
93
|
## 1.0.2 (2021-07-25)
|
|
155
94
|
|
|
156
|
-
|
|
157
|
-
|
|
158
95
|
## 1.0.1 (2021-07-25)
|
|
159
96
|
|
|
160
|
-
|
|
161
|
-
|
|
162
97
|
# 1.0.0 (2021-07-24)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quenty/adorneeutils",
|
|
3
|
-
"version": "3.3.
|
|
3
|
+
"version": "3.3.6",
|
|
4
4
|
"description": "AdorneeUtils - Generic adornee functions to make attaching to objects in Roblox easier.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Roblox",
|
|
@@ -24,11 +24,17 @@
|
|
|
24
24
|
"scripts": {
|
|
25
25
|
"preinstall": "npx only-allow pnpm"
|
|
26
26
|
},
|
|
27
|
+
"dependencies": {
|
|
28
|
+
"@quenty/loader": "10.11.1",
|
|
29
|
+
"@quenty/maid": "3.11.1",
|
|
30
|
+
"@quenty/nevermore-test-runner": "1.5.1",
|
|
31
|
+
"@quentystudios/jest-lua": "3.10.0-quenty.2"
|
|
32
|
+
},
|
|
27
33
|
"contributors": [
|
|
28
34
|
"Quenty"
|
|
29
35
|
],
|
|
30
36
|
"publishConfig": {
|
|
31
37
|
"access": "public"
|
|
32
38
|
},
|
|
33
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "1a2c0cc735d06b4adcd324f60302b950e12d68b0"
|
|
34
40
|
}
|
|
@@ -7,6 +7,8 @@
|
|
|
7
7
|
@class AdorneeUtils
|
|
8
8
|
]=]
|
|
9
9
|
|
|
10
|
+
-- NOTE: `Tool` inherits from `Model`, so every `IsA` chain below tests `Tool` before `Model`.
|
|
11
|
+
|
|
10
12
|
local AdorneeUtils = {}
|
|
11
13
|
|
|
12
14
|
--[=[
|
|
@@ -19,6 +21,13 @@ function AdorneeUtils.getCenter(adornee: Instance): Vector3?
|
|
|
19
21
|
|
|
20
22
|
if adornee:IsA("BasePart") then
|
|
21
23
|
return adornee.Position
|
|
24
|
+
elseif adornee:IsA("Tool") then
|
|
25
|
+
local handle = adornee:FindFirstChild("Handle")
|
|
26
|
+
if handle and handle:IsA("BasePart") then
|
|
27
|
+
return handle.Position
|
|
28
|
+
else
|
|
29
|
+
return nil
|
|
30
|
+
end
|
|
22
31
|
elseif adornee:IsA("Model") then
|
|
23
32
|
return adornee:GetBoundingBox().Position
|
|
24
33
|
elseif adornee:IsA("Attachment") then
|
|
@@ -37,13 +46,6 @@ function AdorneeUtils.getCenter(adornee: Instance): Vector3?
|
|
|
37
46
|
else
|
|
38
47
|
return nil
|
|
39
48
|
end
|
|
40
|
-
elseif adornee:IsA("Tool") then
|
|
41
|
-
local handle = adornee:FindFirstChild("Handle")
|
|
42
|
-
if handle and handle:IsA("BasePart") then
|
|
43
|
-
return handle.Position
|
|
44
|
-
else
|
|
45
|
-
return nil
|
|
46
|
-
end
|
|
47
49
|
else
|
|
48
50
|
return nil
|
|
49
51
|
end
|
|
@@ -56,7 +58,9 @@ end
|
|
|
56
58
|
@return Vector3? -- Size of the bounding box
|
|
57
59
|
]=]
|
|
58
60
|
function AdorneeUtils.getBoundingBox(adornee: Instance): (CFrame?, Vector3?)
|
|
59
|
-
if adornee:IsA("
|
|
61
|
+
if adornee:IsA("Tool") then
|
|
62
|
+
return AdorneeUtils.getPartCFrame(adornee), AdorneeUtils.getAlignedSize(adornee)
|
|
63
|
+
elseif adornee:IsA("Model") then
|
|
60
64
|
return adornee:GetBoundingBox()
|
|
61
65
|
elseif adornee:IsA("Attachment") then
|
|
62
66
|
return adornee.WorldCFrame, Vector3.zero -- This is a point
|
|
@@ -122,7 +126,12 @@ end
|
|
|
122
126
|
@return Vector3?
|
|
123
127
|
]=]
|
|
124
128
|
function AdorneeUtils.getAlignedSize(adornee: Instance): Vector3?
|
|
125
|
-
if adornee:IsA("
|
|
129
|
+
if adornee:IsA("Tool") then
|
|
130
|
+
local part = AdorneeUtils.getPart(adornee)
|
|
131
|
+
if part then
|
|
132
|
+
return part.Size
|
|
133
|
+
end
|
|
134
|
+
elseif adornee:IsA("Model") then
|
|
126
135
|
return select(2, adornee:GetBoundingBox())
|
|
127
136
|
elseif adornee:IsA("Humanoid") then
|
|
128
137
|
local character = adornee.Parent
|
|
@@ -197,6 +206,13 @@ function AdorneeUtils.getPart(adornee: Instance): BasePart?
|
|
|
197
206
|
|
|
198
207
|
if adornee:IsA("BasePart") then
|
|
199
208
|
return adornee
|
|
209
|
+
elseif adornee:IsA("Tool") then
|
|
210
|
+
local handle = adornee:FindFirstChild("Handle")
|
|
211
|
+
if handle and handle:IsA("BasePart") then
|
|
212
|
+
return handle
|
|
213
|
+
else
|
|
214
|
+
return nil
|
|
215
|
+
end
|
|
200
216
|
elseif adornee:IsA("Model") then
|
|
201
217
|
if adornee.PrimaryPart ~= nil then
|
|
202
218
|
return adornee.PrimaryPart
|
|
@@ -210,13 +226,6 @@ function AdorneeUtils.getPart(adornee: Instance): BasePart?
|
|
|
210
226
|
return adornee.RootPart
|
|
211
227
|
elseif adornee:IsA("Accessory") or adornee:IsA("Clothing") then
|
|
212
228
|
return adornee:FindFirstChildWhichIsA("BasePart") :: BasePart
|
|
213
|
-
elseif adornee:IsA("Tool") then
|
|
214
|
-
local handle = adornee:FindFirstChild("Handle")
|
|
215
|
-
if handle and handle:IsA("BasePart") then
|
|
216
|
-
return handle
|
|
217
|
-
else
|
|
218
|
-
return nil
|
|
219
|
-
end
|
|
220
229
|
else
|
|
221
230
|
return nil
|
|
222
231
|
end
|
|
@@ -232,6 +241,13 @@ function AdorneeUtils.getRenderAdornee(adornee: Instance): Instance?
|
|
|
232
241
|
|
|
233
242
|
if adornee:IsA("BasePart") then
|
|
234
243
|
return adornee
|
|
244
|
+
elseif adornee:IsA("Tool") then
|
|
245
|
+
local handle = adornee:FindFirstChild("Handle")
|
|
246
|
+
if handle and handle:IsA("BasePart") then
|
|
247
|
+
return handle
|
|
248
|
+
else
|
|
249
|
+
return nil
|
|
250
|
+
end
|
|
235
251
|
elseif adornee:IsA("Model") then
|
|
236
252
|
return adornee
|
|
237
253
|
elseif adornee:IsA("Attachment") then
|
|
@@ -241,13 +257,6 @@ function AdorneeUtils.getRenderAdornee(adornee: Instance): Instance?
|
|
|
241
257
|
elseif adornee:IsA("Accessory") or adornee:IsA("Clothing") then
|
|
242
258
|
local basePart = adornee:FindFirstChildWhichIsA("BasePart")
|
|
243
259
|
return basePart
|
|
244
|
-
elseif adornee:IsA("Tool") then
|
|
245
|
-
local handle = adornee:FindFirstChild("Handle")
|
|
246
|
-
if handle and handle:IsA("BasePart") then
|
|
247
|
-
return handle
|
|
248
|
-
else
|
|
249
|
-
return nil
|
|
250
|
-
end
|
|
251
260
|
else
|
|
252
261
|
return nil
|
|
253
262
|
end
|