@quenty/inputkeymaputils 14.7.0 → 14.8.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 +16 -0
- package/package.json +15 -15
- package/src/Shared/InputKeyMapRegistryServiceShared.lua +26 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,22 @@
|
|
|
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
|
+
# [14.8.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/inputkeymaputils@14.7.0...@quenty/inputkeymaputils@14.8.0) (2024-09-12)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* Fix return value ([277ee08](https://github.com/Quenty/NevermoreEngine/commit/277ee080da567177abe8e1778ecc2db7e28648e2))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Features
|
|
15
|
+
|
|
16
|
+
* Add InputKeyMapRegistryServiceShared:ObserveInputKeyMapList ([db86a30](https://github.com/Quenty/NevermoreEngine/commit/db86a30872163a5f5b2dc705d92b80f04c372d7e))
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
6
22
|
# [14.7.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/inputkeymaputils@14.6.2...@quenty/inputkeymaputils@14.7.0) (2024-08-09)
|
|
7
23
|
|
|
8
24
|
**Note:** Version bump only for package @quenty/inputkeymaputils
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quenty/inputkeymaputils",
|
|
3
|
-
"version": "14.
|
|
3
|
+
"version": "14.8.0",
|
|
4
4
|
"description": "System to define rebindable key bindings and inputs for Roblox.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Roblox",
|
|
@@ -26,26 +26,26 @@
|
|
|
26
26
|
"Quenty"
|
|
27
27
|
],
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@quenty/baseobject": "^10.
|
|
30
|
-
"@quenty/brio": "^14.
|
|
31
|
-
"@quenty/clienttranslator": "^14.
|
|
32
|
-
"@quenty/ducktype": "^5.
|
|
29
|
+
"@quenty/baseobject": "^10.4.0",
|
|
30
|
+
"@quenty/brio": "^14.5.0",
|
|
31
|
+
"@quenty/clienttranslator": "^14.6.0",
|
|
32
|
+
"@quenty/ducktype": "^5.4.0",
|
|
33
33
|
"@quenty/enumutils": "^3.2.0",
|
|
34
|
-
"@quenty/inputmode": "^13.
|
|
35
|
-
"@quenty/loader": "^10.
|
|
36
|
-
"@quenty/maid": "^3.
|
|
37
|
-
"@quenty/observablecollection": "^12.
|
|
34
|
+
"@quenty/inputmode": "^13.6.0",
|
|
35
|
+
"@quenty/loader": "^10.4.0",
|
|
36
|
+
"@quenty/maid": "^3.3.0",
|
|
37
|
+
"@quenty/observablecollection": "^12.5.0",
|
|
38
38
|
"@quenty/pseudolocalize": "^3.3.0",
|
|
39
|
-
"@quenty/rx": "^13.
|
|
40
|
-
"@quenty/servicebag": "^11.
|
|
41
|
-
"@quenty/statestack": "^14.
|
|
39
|
+
"@quenty/rx": "^13.5.0",
|
|
40
|
+
"@quenty/servicebag": "^11.5.0",
|
|
41
|
+
"@quenty/statestack": "^14.6.0",
|
|
42
42
|
"@quenty/string": "^3.2.0",
|
|
43
43
|
"@quenty/table": "^3.5.0",
|
|
44
|
-
"@quenty/valuebaseutils": "^13.
|
|
45
|
-
"@quenty/valueobject": "^13.
|
|
44
|
+
"@quenty/valuebaseutils": "^13.5.0",
|
|
45
|
+
"@quenty/valueobject": "^13.5.0"
|
|
46
46
|
},
|
|
47
47
|
"publishConfig": {
|
|
48
48
|
"access": "public"
|
|
49
49
|
},
|
|
50
|
-
"gitHead": "
|
|
50
|
+
"gitHead": "fb172906f3ee725269ec1e5f4daf9dca227e729d"
|
|
51
51
|
}
|
|
@@ -13,6 +13,7 @@ local require = require(script.Parent.loader).load(script)
|
|
|
13
13
|
local Maid = require("Maid")
|
|
14
14
|
local ObservableList = require("ObservableList")
|
|
15
15
|
local RxBrioUtils = require("RxBrioUtils")
|
|
16
|
+
local Rx = require("Rx")
|
|
16
17
|
|
|
17
18
|
local InputKeyMapRegistryServiceShared = {}
|
|
18
19
|
InputKeyMapRegistryServiceShared.ServiceName = "InputKeyMapRegistryServiceShared"
|
|
@@ -76,11 +77,32 @@ function InputKeyMapRegistryServiceShared:GetProvider(providerName)
|
|
|
76
77
|
return self._providerLookupByName[providerName]
|
|
77
78
|
end
|
|
78
79
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
80
|
+
function InputKeyMapRegistryServiceShared:ObserveInputKeyMapList(providerName, inputKeyMapListName)
|
|
81
|
+
assert(providerName, "Bad providerName")
|
|
82
|
+
assert(inputKeyMapListName, "Bad inputKeyMapListName")
|
|
83
|
+
|
|
84
|
+
return Rx.combineLatest({
|
|
85
|
+
providerName = providerName;
|
|
86
|
+
inputKeyMapListName = inputKeyMapListName;
|
|
87
|
+
}):Pipe({
|
|
88
|
+
Rx.map(function(state)
|
|
89
|
+
if not (type(state.inputKeyMapListName) == "string" and type(state.providerName) == "string") then
|
|
90
|
+
return nil
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
local found = self:FindInputKeyMapList(state.providerName, state.inputKeyMapListName)
|
|
94
|
+
if found then
|
|
95
|
+
return found
|
|
96
|
+
end
|
|
97
|
+
|
|
98
|
+
warn(string.format("[TriggerModel.ObserveInputKeyMapList] - Bad inputKey name %q %q\n%s",
|
|
99
|
+
tostring(state.providerName),
|
|
100
|
+
tostring(state.inputKeyMapListName)))
|
|
82
101
|
|
|
83
|
-
|
|
102
|
+
return nil
|
|
103
|
+
end);
|
|
104
|
+
})
|
|
105
|
+
end
|
|
84
106
|
|
|
85
107
|
function InputKeyMapRegistryServiceShared:FindInputKeyMapList(providerName, inputKeyMapListName)
|
|
86
108
|
assert(type(providerName) == "string", "Bad providerName")
|