tpmkms 9.8.0-beta.8 → 9.9.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/common/actions.instance.json +4 -4
- package/common/actions.js +9 -9
- package/common/askfor.instance.json +12 -184
- package/common/askfor.js +19 -11
- package/common/asking.js +13 -5
- package/common/can.instance.json +2 -18
- package/common/can.js +2 -2
- package/common/comparable.instance.json +6 -12
- package/common/concept.instance.json +8 -4
- package/common/concept.js +2 -0
- package/common/conjunction.js +6 -4
- package/common/control.js +5 -5
- package/common/countable.js +1 -0
- package/common/dateTimeSelectors.instance.json +1 -1
- package/common/dateTimeSelectors.js +1 -1
- package/common/dates.instance.json +11 -1
- package/common/dates.js +6 -1
- package/common/debug.instance.json +5 -1
- package/common/debug.js +2 -0
- package/common/dialogues.js +37 -35
- package/common/dimension.instance.json +144 -446
- package/common/dimension.js +14 -8
- package/common/drone.instance.json +43 -19
- package/common/drone.js +29 -35
- package/common/drone_v1.instance.json +13 -3
- package/common/drone_v1.js +14 -9
- package/common/evaluate.js +2 -2
- package/common/fastfood.instance.json +12 -4
- package/common/fastfood.js +27 -12
- package/common/formulas.instance.json +138 -12
- package/common/formulas.js +15 -6
- package/common/gdefaults.js +2 -71
- package/common/helpers/dialogues.js +1 -10
- package/common/helpers/properties.js +6 -10
- package/common/helpers.js +5 -2
- package/common/hierarchy.js +11 -7
- package/common/math.instance.json +141 -4
- package/common/math.js +18 -5
- package/common/menus.instance.json +6 -2
- package/common/menus.js +5 -2
- package/common/meta.js +12 -12
- package/common/nameable.js +6 -2
- package/common/ordering.instance.json +1 -2
- package/common/percentages.js +4 -2
- package/common/pipboy.instance.json +38 -27
- package/common/pipboy.js +21 -14
- package/common/properties.instance.json +2319 -560
- package/common/properties.js +146 -37
- package/common/punctuation.js +1 -0
- package/common/rates.instance.json +1 -1
- package/common/rates.js +2 -2
- package/common/reminders.instance.json +16 -0
- package/common/reminders.js +23 -19
- package/common/reports.instance.json +4 -6
- package/common/reports.js +12 -12
- package/common/sdefaults.js +11 -9
- package/common/stm.js +11 -14
- package/common/testing.js +2 -2
- package/common/time.instance.json +42 -15
- package/common/time.js +7 -6
- package/common/ui.js +5 -5
- package/common/words.js +106 -1
- package/common/wp.instance.json +10 -3
- package/common/wp.js +5 -1
- package/package.json +2 -2
|
@@ -128,8 +128,8 @@
|
|
|
128
128
|
"bridge": "{ ...next(after[0]), condition: before[0], modifiers: ['condition'] }"
|
|
129
129
|
},
|
|
130
130
|
{
|
|
131
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:166",
|
|
132
131
|
"id": "on",
|
|
132
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:167",
|
|
133
133
|
"isA": [
|
|
134
134
|
"preposition"
|
|
135
135
|
],
|
|
@@ -139,8 +139,8 @@
|
|
|
139
139
|
"semantic": "({api, context}) => {\n api.change(context.item.marker)\n }"
|
|
140
140
|
},
|
|
141
141
|
{
|
|
142
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:177",
|
|
143
142
|
"id": "change",
|
|
143
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:178",
|
|
144
144
|
"isA": [
|
|
145
145
|
"verb"
|
|
146
146
|
],
|
|
@@ -156,8 +156,8 @@
|
|
|
156
156
|
"semantic": "({api, context}) => {\n api.change(context.item.marker)\n }"
|
|
157
157
|
},
|
|
158
158
|
{
|
|
159
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:189",
|
|
160
159
|
"id": "disarm",
|
|
160
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:190",
|
|
161
161
|
"isA": [
|
|
162
162
|
"verb"
|
|
163
163
|
],
|
|
@@ -165,8 +165,8 @@
|
|
|
165
165
|
"semantic": "({api, context}) => {\n api.disarm()\n }"
|
|
166
166
|
},
|
|
167
167
|
{
|
|
168
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:198",
|
|
169
168
|
"id": "strip",
|
|
169
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:199",
|
|
170
170
|
"isA": [
|
|
171
171
|
"verb"
|
|
172
172
|
],
|
|
@@ -174,8 +174,8 @@
|
|
|
174
174
|
"semantic": "({api, context}) => {\n api.strip()\n }"
|
|
175
175
|
},
|
|
176
176
|
{
|
|
177
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:207",
|
|
178
177
|
"id": "call",
|
|
178
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:208",
|
|
179
179
|
"isA": [
|
|
180
180
|
"verb"
|
|
181
181
|
],
|
|
@@ -185,8 +185,8 @@
|
|
|
185
185
|
"semantic": "({api, context}) => {\n api.setName(context.item, context.name.name.value)\n }"
|
|
186
186
|
},
|
|
187
187
|
{
|
|
188
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:218",
|
|
189
188
|
"id": "putOn",
|
|
189
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:219",
|
|
190
190
|
"isA": [
|
|
191
191
|
"verb"
|
|
192
192
|
],
|
|
@@ -196,8 +196,8 @@
|
|
|
196
196
|
"semantic": "({api, context}) => {\n if (context.item.name) {\n api.wear({ name: context.item.name.value, type: 'outfit' })\n } else {\n api.wear({ type: context.item.value })\n }\n }"
|
|
197
197
|
},
|
|
198
198
|
{
|
|
199
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:233",
|
|
200
199
|
"id": "wear",
|
|
200
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:234",
|
|
201
201
|
"isA": [
|
|
202
202
|
"verb"
|
|
203
203
|
],
|
|
@@ -216,8 +216,8 @@
|
|
|
216
216
|
"semantic": "({api, context}) => {\n if (context.item.name) {\n api.wear({ name: context.item.name.value, type: 'outfit' })\n } else {\n api.wear({ type: context.item.value })\n }\n }"
|
|
217
217
|
},
|
|
218
218
|
{
|
|
219
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:250",
|
|
220
219
|
"id": "equip",
|
|
220
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:251",
|
|
221
221
|
"isA": [
|
|
222
222
|
"verb"
|
|
223
223
|
],
|
|
@@ -244,19 +244,19 @@
|
|
|
244
244
|
"semantic": "async ({api, context}) => {\n let condition\n if (context.item.condition) {\n // { selector: 'highest', property: 'damage' }\n condition = { selector: context.item.condition.condition.marker, property: context.item.condition.marker }\n }\n api.equip({ type: context.item.value, condition })\n }"
|
|
245
245
|
},
|
|
246
246
|
{
|
|
247
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:268",
|
|
248
247
|
"id": "toDrink",
|
|
248
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:269",
|
|
249
249
|
"isA": [
|
|
250
250
|
"verb"
|
|
251
251
|
],
|
|
252
252
|
"level": 0,
|
|
253
253
|
"bridge": "{ ...next(operator), item: after[0] }",
|
|
254
254
|
"generatorp": "async ({context, g}) => `drink ${await g(context.item)}`",
|
|
255
|
-
"semantic": "async ({api, context, e}) => {\n const value = await e(context.item)\n api.drink(value.value)\n }"
|
|
255
|
+
"semantic": "async ({api, context, e}) => {\n const value = await e(context.item, where())\n api.drink(value.value)\n }"
|
|
256
256
|
},
|
|
257
257
|
{
|
|
258
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:280",
|
|
259
258
|
"id": "eat",
|
|
259
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:281",
|
|
260
260
|
"localHierarchy": [
|
|
261
261
|
[
|
|
262
262
|
"unknown",
|
|
@@ -272,15 +272,15 @@
|
|
|
272
272
|
"semantic": "async ({api, context}) => {\n api.eat(context.item.value)\n }"
|
|
273
273
|
},
|
|
274
274
|
{
|
|
275
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:292",
|
|
276
275
|
"id": "take",
|
|
276
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:293",
|
|
277
277
|
"isA": [
|
|
278
278
|
"verb"
|
|
279
279
|
],
|
|
280
280
|
"level": 0,
|
|
281
281
|
"bridge": "{ ...next(operator), item: after[0] }",
|
|
282
282
|
"generatorp": "async ({context, g}) => `take ${await g(context.item)}`",
|
|
283
|
-
"semantic": "async ({api, context, e}) => {\n const value = await e(context.item)\n api.take(value.value)\n }"
|
|
283
|
+
"semantic": "async ({api, context, e}) => {\n const value = await e(context.item, where())\n api.take(value.value)\n }"
|
|
284
284
|
},
|
|
285
285
|
{
|
|
286
286
|
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:304",
|
|
@@ -324,16 +324,18 @@
|
|
|
324
324
|
},
|
|
325
325
|
{
|
|
326
326
|
"id": "apply",
|
|
327
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:344",
|
|
327
328
|
"isA": [
|
|
328
329
|
"verb"
|
|
329
330
|
],
|
|
330
331
|
"level": 0,
|
|
331
332
|
"bridge": "{ ...next(operator), item: after[0] }",
|
|
332
333
|
"generatorp": "async ({context, g}) => `apply ${await g(context.item)}`",
|
|
333
|
-
"semantic": "async ({api, context, e}) => {\n // { item: 'stimpak', quantity: <number>, to?: [ { part: ['arm', 'leg', 'torso', head'], side?: ['left', 'right'] } ] }\n const quantity = context.item.quantity ? (await e(context.item.quantity)).value : 1\n api.apply({ item: 'stimpak', quantity })\n }"
|
|
334
|
+
"semantic": "async ({api, context, e}) => {\n // { item: 'stimpak', quantity: <number>, to?: [ { part: ['arm', 'leg', 'torso', head'], side?: ['left', 'right'] } ] }\n const quantity = context.item.quantity ? (await e(context.item.quantity, where())).value : 1\n api.apply({ item: 'stimpak', quantity })\n }"
|
|
334
335
|
},
|
|
335
336
|
{
|
|
336
337
|
"id": "go",
|
|
338
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:357",
|
|
337
339
|
"isA": [
|
|
338
340
|
"verb"
|
|
339
341
|
],
|
|
@@ -344,6 +346,7 @@
|
|
|
344
346
|
},
|
|
345
347
|
{
|
|
346
348
|
"id": "to2",
|
|
349
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:368",
|
|
347
350
|
"isA": [
|
|
348
351
|
"preposition"
|
|
349
352
|
],
|
|
@@ -353,6 +356,7 @@
|
|
|
353
356
|
},
|
|
354
357
|
{
|
|
355
358
|
"id": "showWeapons",
|
|
359
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:376",
|
|
356
360
|
"isA": [
|
|
357
361
|
"verb"
|
|
358
362
|
],
|
|
@@ -363,6 +367,7 @@
|
|
|
363
367
|
},
|
|
364
368
|
{
|
|
365
369
|
"id": "show",
|
|
370
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:391",
|
|
366
371
|
"isA": [
|
|
367
372
|
"verb"
|
|
368
373
|
],
|
|
@@ -399,6 +404,7 @@
|
|
|
399
404
|
},
|
|
400
405
|
{
|
|
401
406
|
"id": "content",
|
|
407
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:435",
|
|
402
408
|
"isA": [
|
|
403
409
|
"showable"
|
|
404
410
|
],
|
|
@@ -4337,8 +4343,7 @@
|
|
|
4337
4343
|
"modifiers": [
|
|
4338
4344
|
"determiner"
|
|
4339
4345
|
],
|
|
4340
|
-
"level": 0
|
|
4341
|
-
"evaluate": false
|
|
4346
|
+
"level": 0
|
|
4342
4347
|
},
|
|
4343
4348
|
"two": {
|
|
4344
4349
|
"value": "equipable",
|
|
@@ -11039,8 +11044,8 @@
|
|
|
11039
11044
|
"bridge": "{ ...next(after[0]), condition: before[0], modifiers: ['condition'] }"
|
|
11040
11045
|
},
|
|
11041
11046
|
{
|
|
11042
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:166",
|
|
11043
11047
|
"id": "on",
|
|
11048
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:167",
|
|
11044
11049
|
"isA": [
|
|
11045
11050
|
"preposition"
|
|
11046
11051
|
],
|
|
@@ -11048,8 +11053,8 @@
|
|
|
11048
11053
|
"bridge": "{ ...before, marker: operator('putOn', 0), dead: false }"
|
|
11049
11054
|
},
|
|
11050
11055
|
{
|
|
11051
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:177",
|
|
11052
11056
|
"id": "change",
|
|
11057
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:178",
|
|
11053
11058
|
"isA": [
|
|
11054
11059
|
"verb"
|
|
11055
11060
|
],
|
|
@@ -11063,22 +11068,22 @@
|
|
|
11063
11068
|
]
|
|
11064
11069
|
},
|
|
11065
11070
|
{
|
|
11066
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:189",
|
|
11067
11071
|
"id": "disarm",
|
|
11072
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:190",
|
|
11068
11073
|
"isA": [
|
|
11069
11074
|
"verb"
|
|
11070
11075
|
]
|
|
11071
11076
|
},
|
|
11072
11077
|
{
|
|
11073
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:198",
|
|
11074
11078
|
"id": "strip",
|
|
11079
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:199",
|
|
11075
11080
|
"isA": [
|
|
11076
11081
|
"verb"
|
|
11077
11082
|
]
|
|
11078
11083
|
},
|
|
11079
11084
|
{
|
|
11080
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:207",
|
|
11081
11085
|
"id": "call",
|
|
11086
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:208",
|
|
11082
11087
|
"isA": [
|
|
11083
11088
|
"verb"
|
|
11084
11089
|
],
|
|
@@ -11086,8 +11091,8 @@
|
|
|
11086
11091
|
"bridge": "{ ...next(operator), item: after[0], name: after[1] }"
|
|
11087
11092
|
},
|
|
11088
11093
|
{
|
|
11089
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:218",
|
|
11090
11094
|
"id": "putOn",
|
|
11095
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:219",
|
|
11091
11096
|
"isA": [
|
|
11092
11097
|
"verb"
|
|
11093
11098
|
],
|
|
@@ -11095,8 +11100,8 @@
|
|
|
11095
11100
|
"bridge": "{ ...next(operator), item: after[0] }"
|
|
11096
11101
|
},
|
|
11097
11102
|
{
|
|
11098
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:233",
|
|
11099
11103
|
"id": "wear",
|
|
11104
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:234",
|
|
11100
11105
|
"isA": [
|
|
11101
11106
|
"verb"
|
|
11102
11107
|
],
|
|
@@ -11113,8 +11118,8 @@
|
|
|
11113
11118
|
"bridge": "{ ...next(operator), item: after[0] }"
|
|
11114
11119
|
},
|
|
11115
11120
|
{
|
|
11116
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:250",
|
|
11117
11121
|
"id": "equip",
|
|
11122
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:251",
|
|
11118
11123
|
"isA": [
|
|
11119
11124
|
"verb"
|
|
11120
11125
|
],
|
|
@@ -11139,8 +11144,8 @@
|
|
|
11139
11144
|
"bridge": "{ ...next(operator), item: after[0] }"
|
|
11140
11145
|
},
|
|
11141
11146
|
{
|
|
11142
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:268",
|
|
11143
11147
|
"id": "toDrink",
|
|
11148
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:269",
|
|
11144
11149
|
"isA": [
|
|
11145
11150
|
"verb"
|
|
11146
11151
|
],
|
|
@@ -11148,8 +11153,8 @@
|
|
|
11148
11153
|
"bridge": "{ ...next(operator), item: after[0] }"
|
|
11149
11154
|
},
|
|
11150
11155
|
{
|
|
11151
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:280",
|
|
11152
11156
|
"id": "eat",
|
|
11157
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:281",
|
|
11153
11158
|
"localHierarchy": [
|
|
11154
11159
|
[
|
|
11155
11160
|
"unknown",
|
|
@@ -11163,8 +11168,8 @@
|
|
|
11163
11168
|
"bridge": "{ ...next(operator), item: after[0] }"
|
|
11164
11169
|
},
|
|
11165
11170
|
{
|
|
11166
|
-
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:292",
|
|
11167
11171
|
"id": "take",
|
|
11172
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:293",
|
|
11168
11173
|
"isA": [
|
|
11169
11174
|
"verb"
|
|
11170
11175
|
],
|
|
@@ -11213,6 +11218,7 @@
|
|
|
11213
11218
|
},
|
|
11214
11219
|
{
|
|
11215
11220
|
"id": "apply",
|
|
11221
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:344",
|
|
11216
11222
|
"isA": [
|
|
11217
11223
|
"verb"
|
|
11218
11224
|
],
|
|
@@ -11221,6 +11227,7 @@
|
|
|
11221
11227
|
},
|
|
11222
11228
|
{
|
|
11223
11229
|
"id": "go",
|
|
11230
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:357",
|
|
11224
11231
|
"isA": [
|
|
11225
11232
|
"verb"
|
|
11226
11233
|
],
|
|
@@ -11229,6 +11236,7 @@
|
|
|
11229
11236
|
},
|
|
11230
11237
|
{
|
|
11231
11238
|
"id": "to2",
|
|
11239
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:368",
|
|
11232
11240
|
"isA": [
|
|
11233
11241
|
"preposition"
|
|
11234
11242
|
],
|
|
@@ -11237,6 +11245,7 @@
|
|
|
11237
11245
|
},
|
|
11238
11246
|
{
|
|
11239
11247
|
"id": "showWeapons",
|
|
11248
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:376",
|
|
11240
11249
|
"isA": [
|
|
11241
11250
|
"verb"
|
|
11242
11251
|
],
|
|
@@ -11245,6 +11254,7 @@
|
|
|
11245
11254
|
},
|
|
11246
11255
|
{
|
|
11247
11256
|
"id": "show",
|
|
11257
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:391",
|
|
11248
11258
|
"isA": [
|
|
11249
11259
|
"verb"
|
|
11250
11260
|
],
|
|
@@ -11279,6 +11289,7 @@
|
|
|
11279
11289
|
},
|
|
11280
11290
|
{
|
|
11281
11291
|
"id": "content",
|
|
11292
|
+
"where": "/home/dev/code/theprogrammablemind/kms/common/pipboy.js:435",
|
|
11282
11293
|
"isA": [
|
|
11283
11294
|
"showable"
|
|
11284
11295
|
],
|
package/common/pipboy.js
CHANGED
|
@@ -163,8 +163,8 @@ const config = {
|
|
|
163
163
|
bridge: "{ ...next(after[0]), condition: before[0], modifiers: ['condition'] }",
|
|
164
164
|
},
|
|
165
165
|
{
|
|
166
|
-
where: where(),
|
|
167
166
|
id: "on",
|
|
167
|
+
where: where(),
|
|
168
168
|
isA: ['preposition'],
|
|
169
169
|
level: 0,
|
|
170
170
|
bridge: "{ ...before, marker: operator('putOn', 0), dead: false }",
|
|
@@ -174,8 +174,8 @@ const config = {
|
|
|
174
174
|
}
|
|
175
175
|
},
|
|
176
176
|
{
|
|
177
|
-
where: where(),
|
|
178
177
|
id: "change",
|
|
178
|
+
where: where(),
|
|
179
179
|
isA: ['verb'],
|
|
180
180
|
level: 0,
|
|
181
181
|
bridge: "{ ...next(operator), item: after[0] }",
|
|
@@ -186,8 +186,8 @@ const config = {
|
|
|
186
186
|
}
|
|
187
187
|
},
|
|
188
188
|
{
|
|
189
|
-
where: where(),
|
|
190
189
|
id: "disarm",
|
|
190
|
+
where: where(),
|
|
191
191
|
isA: ['verb'],
|
|
192
192
|
generatorp: ({context}) => `disarm`,
|
|
193
193
|
semantic: ({api, context}) => {
|
|
@@ -195,8 +195,8 @@ const config = {
|
|
|
195
195
|
}
|
|
196
196
|
},
|
|
197
197
|
{
|
|
198
|
-
where: where(),
|
|
199
198
|
id: "strip",
|
|
199
|
+
where: where(),
|
|
200
200
|
isA: ['verb'],
|
|
201
201
|
generatorp: ({context}) => `strip`,
|
|
202
202
|
semantic: ({api, context}) => {
|
|
@@ -204,8 +204,8 @@ const config = {
|
|
|
204
204
|
}
|
|
205
205
|
},
|
|
206
206
|
{
|
|
207
|
-
where: where(),
|
|
208
207
|
id: "call",
|
|
208
|
+
where: where(),
|
|
209
209
|
isA: ['verb'],
|
|
210
210
|
level: 0,
|
|
211
211
|
bridge: "{ ...next(operator), item: after[0], name: after[1] }",
|
|
@@ -215,8 +215,8 @@ const config = {
|
|
|
215
215
|
}
|
|
216
216
|
},
|
|
217
217
|
{
|
|
218
|
-
where: where(),
|
|
219
218
|
id: "putOn",
|
|
219
|
+
where: where(),
|
|
220
220
|
isA: ['verb'],
|
|
221
221
|
level: 0,
|
|
222
222
|
bridge: "{ ...next(operator), item: after[0] }",
|
|
@@ -230,8 +230,8 @@ const config = {
|
|
|
230
230
|
}
|
|
231
231
|
},
|
|
232
232
|
{
|
|
233
|
-
where: where(),
|
|
234
233
|
id: "wear",
|
|
234
|
+
where: where(),
|
|
235
235
|
isA: ['verb'],
|
|
236
236
|
words: ['where'], // the speech recognizer hears 'where' not 'wear'
|
|
237
237
|
localHierarchy: [ ['unknown', 'wearable'] ],
|
|
@@ -247,8 +247,8 @@ const config = {
|
|
|
247
247
|
}
|
|
248
248
|
},
|
|
249
249
|
{
|
|
250
|
-
where: where(),
|
|
251
250
|
id: "equip",
|
|
251
|
+
where: where(),
|
|
252
252
|
isA: ['verb'],
|
|
253
253
|
words: ['use'],
|
|
254
254
|
level: 0,
|
|
@@ -265,20 +265,20 @@ const config = {
|
|
|
265
265
|
}
|
|
266
266
|
},
|
|
267
267
|
{
|
|
268
|
-
where: where(),
|
|
269
268
|
id: "toDrink",
|
|
269
|
+
where: where(),
|
|
270
270
|
isA: ['verb'],
|
|
271
271
|
level: 0,
|
|
272
272
|
bridge: "{ ...next(operator), item: after[0] }",
|
|
273
273
|
generatorp: async ({context, g}) => `drink ${await g(context.item)}`,
|
|
274
274
|
semantic: async ({api, context, e}) => {
|
|
275
|
-
const value = await e(context.item)
|
|
275
|
+
const value = await e(context.item, where())
|
|
276
276
|
api.drink(value.value)
|
|
277
277
|
}
|
|
278
278
|
},
|
|
279
279
|
{
|
|
280
|
-
where: where(),
|
|
281
280
|
id: "eat",
|
|
281
|
+
where: where(),
|
|
282
282
|
localHierarchy: [ ['unknown', 'edible'] ],
|
|
283
283
|
isA: ['verb'],
|
|
284
284
|
level: 0,
|
|
@@ -289,14 +289,14 @@ const config = {
|
|
|
289
289
|
}
|
|
290
290
|
},
|
|
291
291
|
{
|
|
292
|
-
where: where(),
|
|
293
292
|
id: "take",
|
|
293
|
+
where: where(),
|
|
294
294
|
isA: ['verb'],
|
|
295
295
|
level: 0,
|
|
296
296
|
bridge: "{ ...next(operator), item: after[0] }",
|
|
297
297
|
generatorp: async ({context, g}) => `take ${await g(context.item)}`,
|
|
298
298
|
semantic: async ({api, context, e}) => {
|
|
299
|
-
const value = await e(context.item)
|
|
299
|
+
const value = await e(context.item, where())
|
|
300
300
|
api.take(value.value)
|
|
301
301
|
}
|
|
302
302
|
},
|
|
@@ -341,18 +341,20 @@ const config = {
|
|
|
341
341
|
*/
|
|
342
342
|
{
|
|
343
343
|
id: "apply",
|
|
344
|
+
where: where(),
|
|
344
345
|
isA: ['verb'],
|
|
345
346
|
level: 0,
|
|
346
347
|
bridge: "{ ...next(operator), item: after[0] }",
|
|
347
348
|
generatorp: async ({context, g}) => `apply ${await g(context.item)}`,
|
|
348
349
|
semantic: async ({api, context, e}) => {
|
|
349
350
|
// { item: 'stimpak', quantity: <number>, to?: [ { part: ['arm', 'leg', 'torso', head'], side?: ['left', 'right'] } ] }
|
|
350
|
-
const quantity = context.item.quantity ? (await e(context.item.quantity)).value : 1
|
|
351
|
+
const quantity = context.item.quantity ? (await e(context.item.quantity, where())).value : 1
|
|
351
352
|
api.apply({ item: 'stimpak', quantity })
|
|
352
353
|
}
|
|
353
354
|
},
|
|
354
355
|
{
|
|
355
356
|
id: "go",
|
|
357
|
+
where: where(),
|
|
356
358
|
isA: ['verb'],
|
|
357
359
|
level: 0,
|
|
358
360
|
bridge: "{ ...next(operator), showable: after[0].showable }",
|
|
@@ -363,6 +365,7 @@ const config = {
|
|
|
363
365
|
},
|
|
364
366
|
{
|
|
365
367
|
id: "to2",
|
|
368
|
+
where: where(),
|
|
366
369
|
isA: ['preposition'],
|
|
367
370
|
level: 0,
|
|
368
371
|
bridge: "{ ...next(operator), showable: after[0] }",
|
|
@@ -370,6 +373,7 @@ const config = {
|
|
|
370
373
|
},
|
|
371
374
|
{
|
|
372
375
|
id: "showWeapons",
|
|
376
|
+
where: where(),
|
|
373
377
|
isA: ['verb'],
|
|
374
378
|
level: 0,
|
|
375
379
|
bridge: "{ ...next(operator), showable: after[0] }",
|
|
@@ -384,6 +388,7 @@ const config = {
|
|
|
384
388
|
},
|
|
385
389
|
{
|
|
386
390
|
id: "show",
|
|
391
|
+
where: where(),
|
|
387
392
|
isA: ['verb'],
|
|
388
393
|
level: 0,
|
|
389
394
|
bridge: "{ ...next(operator), showable: after[0] }",
|
|
@@ -410,6 +415,7 @@ const config = {
|
|
|
410
415
|
/*
|
|
411
416
|
{
|
|
412
417
|
id: "testsetup1",
|
|
418
|
+
where: where(),
|
|
413
419
|
scope: "testing",
|
|
414
420
|
level: 0,
|
|
415
421
|
bridge: "{ ...next(operator), type: after[0] }" ,
|
|
@@ -426,6 +432,7 @@ const config = {
|
|
|
426
432
|
*/
|
|
427
433
|
{
|
|
428
434
|
id: "content",
|
|
435
|
+
where: where(),
|
|
429
436
|
isA: ['showable'],
|
|
430
437
|
words: [
|
|
431
438
|
['stat', 'stat'],
|