@quenty/playerutils 8.17.3 → 8.17.4-canary.11a5dcf.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 +11 -0
- package/package.json +8 -8
- package/src/Shared/RxPlayerUtils.lua +6 -7
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
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
|
+
## [8.17.4-canary.11a5dcf.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/playerutils@8.17.3...@quenty/playerutils@8.17.4-canary.11a5dcf.0) (2025-05-10)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* Additional type checking updates ([05ba29a](https://github.com/Quenty/NevermoreEngine/commit/05ba29a03efc9f3feed74b34f1d9dfb237496214))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
## [8.17.3](https://github.com/Quenty/NevermoreEngine/compare/@quenty/playerutils@8.17.2...@quenty/playerutils@8.17.3) (2025-04-10)
|
|
7
18
|
|
|
8
19
|
**Note:** Version bump only for package @quenty/playerutils
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quenty/playerutils",
|
|
3
|
-
"version": "8.17.
|
|
3
|
+
"version": "8.17.4-canary.11a5dcf.0",
|
|
4
4
|
"description": "Player utility functions",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Roblox",
|
|
@@ -28,12 +28,12 @@
|
|
|
28
28
|
"access": "public"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@quenty/brio": "
|
|
32
|
-
"@quenty/instanceutils": "
|
|
33
|
-
"@quenty/loader": "
|
|
34
|
-
"@quenty/maid": "
|
|
35
|
-
"@quenty/promise": "
|
|
36
|
-
"@quenty/rx": "
|
|
31
|
+
"@quenty/brio": "14.17.4-canary.11a5dcf.0",
|
|
32
|
+
"@quenty/instanceutils": "13.17.4-canary.11a5dcf.0",
|
|
33
|
+
"@quenty/loader": "10.8.4-canary.11a5dcf.0",
|
|
34
|
+
"@quenty/maid": "3.4.4-canary.11a5dcf.0",
|
|
35
|
+
"@quenty/promise": "10.10.5-canary.11a5dcf.0",
|
|
36
|
+
"@quenty/rx": "13.17.4-canary.11a5dcf.0"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "11a5dcf7d4c7a0bfbf3337e97d30e8346ea09d3f"
|
|
39
39
|
}
|
|
@@ -11,9 +11,8 @@ local Players = game:GetService("Players")
|
|
|
11
11
|
local Brio = require("Brio")
|
|
12
12
|
local Maid = require("Maid")
|
|
13
13
|
local Observable = require("Observable")
|
|
14
|
+
local Rx = require("Rx")
|
|
14
15
|
local RxInstanceUtils = require("RxInstanceUtils")
|
|
15
|
-
local _Rx = require("Rx")
|
|
16
|
-
local _Observable = require("Observable")
|
|
17
16
|
|
|
18
17
|
local RxPlayerUtils = {}
|
|
19
18
|
|
|
@@ -22,7 +21,7 @@ local RxPlayerUtils = {}
|
|
|
22
21
|
@param predicate ((Player) -> boolean)?
|
|
23
22
|
@return Observable<Brio<Player>>
|
|
24
23
|
]=]
|
|
25
|
-
function RxPlayerUtils.observePlayersBrio(predicate:
|
|
24
|
+
function RxPlayerUtils.observePlayersBrio(predicate: Rx.Predicate<Player>?): Observable.Observable<Brio.Brio<Player>>
|
|
26
25
|
assert(type(predicate) == "function" or predicate == nil, "Bad predicate!")
|
|
27
26
|
|
|
28
27
|
return Observable.new(function(sub)
|
|
@@ -58,7 +57,7 @@ end
|
|
|
58
57
|
|
|
59
58
|
@return Observable<Brio<Player>>
|
|
60
59
|
]=]
|
|
61
|
-
function RxPlayerUtils.observeLocalPlayerBrio():
|
|
60
|
+
function RxPlayerUtils.observeLocalPlayerBrio(): Observable.Observable<Brio.Brio<Player>>
|
|
62
61
|
return RxInstanceUtils.observePropertyBrio(Players, "LocalPlayer", function(value)
|
|
63
62
|
return value ~= nil
|
|
64
63
|
end)
|
|
@@ -69,7 +68,7 @@ end
|
|
|
69
68
|
@param predicate ((Player) -> boolean)?
|
|
70
69
|
@return Observable<Player>
|
|
71
70
|
]=]
|
|
72
|
-
function RxPlayerUtils.observePlayers(predicate:
|
|
71
|
+
function RxPlayerUtils.observePlayers(predicate: Rx.Predicate<Player>?): Observable.Observable<Player>
|
|
73
72
|
assert(type(predicate) == "function" or predicate == nil, "Bad predicate")
|
|
74
73
|
|
|
75
74
|
return Observable.new(function(sub)
|
|
@@ -99,7 +98,7 @@ end
|
|
|
99
98
|
@param player Player
|
|
100
99
|
@return Observable<()>
|
|
101
100
|
]=]
|
|
102
|
-
function RxPlayerUtils.observeFirstAppearanceLoaded(player: Player):
|
|
101
|
+
function RxPlayerUtils.observeFirstAppearanceLoaded(player: Player): Observable.Observable<()>
|
|
103
102
|
assert(typeof(player) == "Instance", "Bad player")
|
|
104
103
|
|
|
105
104
|
return Observable.new(function(sub)
|
|
@@ -134,4 +133,4 @@ function RxPlayerUtils.observeFirstAppearanceLoaded(player: Player): _Observable
|
|
|
134
133
|
end)
|
|
135
134
|
end
|
|
136
135
|
|
|
137
|
-
return RxPlayerUtils
|
|
136
|
+
return RxPlayerUtils
|