@maka/maka-cli 5.8.0 → 5.10.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/bundle/typescript/package.json +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/archetypes.js +4 -2
- package/bundle/typescript/src/commands/game/sideQuest/archetypes.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/advance.js +3 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/advance.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/ask.js +14 -6
- package/bundle/typescript/src/commands/game/sideQuest/commands/ask.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/assense.js +3 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/assense.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/attack.js +24 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/attack.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/buy.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/buy.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/bypass-command.js +31 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/bypass-command.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/call.js +16 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/call.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/cast.d.ts +7 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/cast.js +86 -15
- package/bundle/typescript/src/commands/game/sideQuest/commands/cast.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/companions.js +5 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/companions.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/contacts.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/contacts.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/equip.js +5 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/equip.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/equipment.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/equipment.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/give.js +5 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/give.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/go.d.ts +5 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/go.js +94 -16
- package/bundle/typescript/src/commands/game/sideQuest/commands/go.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/grapple.d.ts +38 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/grapple.js +178 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/grapple.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/hack.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/hack.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/haggle.js +7 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/haggle.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/hints.d.ts +10 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/hints.js +24 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/hints.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/initiate.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/initiate.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/inv.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/inv.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/jump.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/jump.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/lifestyle.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/lifestyle.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/look.js +48 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/look.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/map.js +3 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/map.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/move.d.ts +41 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/move.js +160 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/move.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/order.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/order.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/persuade.js +5 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/persuade.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/project.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/project.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/quality-trade.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/quality-trade.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/rest.js +8 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/rest.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/say.js +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/say.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/search.js +15 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/search.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/sell.js +7 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/sell.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/silent.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/silent.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/sneak.js +3 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/sneak.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/solve.js +11 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/solve.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/spells.js +24 -13
- package/bundle/typescript/src/commands/game/sideQuest/commands/spells.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/summon.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/summon.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/surrender.js +4 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/surrender.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/take.js +37 -4
- package/bundle/typescript/src/commands/game/sideQuest/commands/take.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/talk.js +6 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/talk.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/treat.js +5 -0
- package/bundle/typescript/src/commands/game/sideQuest/commands/treat.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/unlock.js +9 -2
- package/bundle/typescript/src/commands/game/sideQuest/commands/unlock.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/work.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/commands/work.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/item-factory.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/item-factory.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/puzzle-factory.js +2 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/puzzle-factory.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/room-factory.js +5 -0
- package/bundle/typescript/src/commands/game/sideQuest/factories/room-factory.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/scene-chunks.d.ts +11 -0
- package/bundle/typescript/src/commands/game/sideQuest/factories/scene-chunks.js +138 -23
- package/bundle/typescript/src/commands/game/sideQuest/factories/scene-chunks.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/factories/scene-factory.js +12 -0
- package/bundle/typescript/src/commands/game/sideQuest/factories/scene-factory.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/game.d.ts +33 -1
- package/bundle/typescript/src/commands/game/sideQuest/game.js +303 -26
- package/bundle/typescript/src/commands/game/sideQuest/game.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/item.d.ts +2 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/item.js +3 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/item.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/npc.d.ts +13 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/npc.js +195 -6
- package/bundle/typescript/src/commands/game/sideQuest/models/npc.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/player.d.ts +11 -2
- package/bundle/typescript/src/commands/game/sideQuest/models/player.js +35 -5
- package/bundle/typescript/src/commands/game/sideQuest/models/player.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/puzzle.d.ts +12 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/puzzle.js +19 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/puzzle.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/room.d.ts +12 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/room.js +51 -4
- package/bundle/typescript/src/commands/game/sideQuest/models/room.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/models/scene.d.ts +45 -0
- package/bundle/typescript/src/commands/game/sideQuest/models/scene.js +197 -4
- package/bundle/typescript/src/commands/game/sideQuest/models/scene.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/scenes/scene1.json +76 -20
- package/bundle/typescript/src/commands/game/sideQuest/scenes/scene2.json +157 -34
- package/bundle/typescript/src/commands/game/sideQuest/types/save-file.d.ts +208 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/save-file.js +14 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/save-file.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/seed/exit-seed.d.ts +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/seed/item-seed.d.ts +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/seed/player-seed.d.ts +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/seed/puzzle-seed.d.ts +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/types/seed/room-seed.d.ts +6 -0
- package/bundle/typescript/src/commands/game/sideQuest/ui.d.ts +6 -0
- package/bundle/typescript/src/commands/game/sideQuest/ui.js +100 -7
- package/bundle/typescript/src/commands/game/sideQuest/ui.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/utilities/auto-fight.js +18 -4
- package/bundle/typescript/src/commands/game/sideQuest/utilities/auto-fight.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/utilities/cloud-saves.d.ts +50 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/cloud-saves.js +232 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/cloud-saves.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/combat-exchange.d.ts +10 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/combat-exchange.js +17 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/combat-exchange.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/utilities/grapple.d.ts +36 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/grapple.js +57 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/grapple.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/hints.d.ts +4 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/hints.js +55 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/hints.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/persistence.d.ts +71 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/persistence.js +447 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/persistence.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/planes.js +8 -7
- package/bundle/typescript/src/commands/game/sideQuest/utilities/planes.js.map +1 -1
- package/bundle/typescript/src/commands/game/sideQuest/utilities/spots.d.ts +121 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/spots.js +315 -0
- package/bundle/typescript/src/commands/game/sideQuest/utilities/spots.js.map +1 -0
- package/bundle/typescript/src/commands/game/sideQuest.sub.cmd.js +174 -18
- package/bundle/typescript/src/commands/game/sideQuest.sub.cmd.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
2
|
import { Category } from '../types/shared/item-enum.js';
|
|
3
|
+
import { hint } from '../utilities/hints.js';
|
|
3
4
|
/**
|
|
4
5
|
* The spellbook: how a player actually discovers what they can cast and
|
|
5
6
|
* why. Especially load-bearing for INNATE casting -- an Awakened character
|
|
@@ -58,14 +59,17 @@ export class SpellsCommand extends Command {
|
|
|
58
59
|
if (actor.sustainingPenalty > 0)
|
|
59
60
|
parts.push(`sustaining -${actor.sustainingPenalty}`);
|
|
60
61
|
lines.push(`Casting pool: ${actor.getMagicPool()}d6 (${parts.join(', ')})`);
|
|
62
|
+
// The sustained STATE is data; the release coaching is a hint
|
|
63
|
+
// (player ruling: the spellbook's reference facts stay, its
|
|
64
|
+
// tutorials go behind the hints toggle).
|
|
61
65
|
if (actor.sustainedArmor > 0) {
|
|
62
|
-
lines.push(`Sustained: armor spell, +${actor.sustainedArmor} soak (-2 dice to everything else)
|
|
66
|
+
lines.push(`Sustained: armor spell, +${actor.sustainedArmor} soak (-2 dice to everything else).${hint(' Cast armor again to release.')}`);
|
|
63
67
|
}
|
|
64
68
|
if (actor.sustainedInvisibility) {
|
|
65
|
-
lines.push(`Sustained: invisibility, +3 on sneak contests (-2 dice to everything else)
|
|
69
|
+
lines.push(`Sustained: invisibility, +3 on sneak contests (-2 dice to everything else).${hint(' Cast invisibility again to release.')}`);
|
|
66
70
|
}
|
|
67
71
|
if (actor.sustainedReflexes) {
|
|
68
|
-
lines.push(`Sustained: increase reflexes, +2 initiative (-2 dice to everything else)
|
|
72
|
+
lines.push(`Sustained: increase reflexes, +2 initiative (-2 dice to everything else).${hint(' Cast it again to release.')}`);
|
|
69
73
|
}
|
|
70
74
|
// The spells themselves -- only what this actor actually knows.
|
|
71
75
|
// Grouped RAW-style (p.283-293): combat's direct/indirect split is
|
|
@@ -73,36 +77,43 @@ export class SpellsCommand extends Command {
|
|
|
73
77
|
lines.push('');
|
|
74
78
|
lines.push('Spells you know:');
|
|
75
79
|
const known = [];
|
|
80
|
+
// Damage/drain codes are the book's DATA; the syntax parentheticals
|
|
81
|
+
// are newbie coaching -- hint-gated (player ruling).
|
|
76
82
|
if (actor.knowsSpell('manabolt')) {
|
|
77
|
-
known.push(` manabolt -- direct mana: resisted by WILLPOWER alone; armor and muscle mean nothing. Damage F-2, drain F-3
|
|
83
|
+
known.push(` manabolt -- direct mana: resisted by WILLPOWER alone; armor and muscle mean nothing. Damage F-2, drain F-3.${hint(' (cast manabolt [force] at <target>)')}`);
|
|
78
84
|
}
|
|
79
85
|
if (actor.knowsSpell('stunbolt')) {
|
|
80
|
-
known.push(` stunbolt -- direct mana, merciful: same reach as manabolt but the damage is STUN. Damage F-2, drain F-3
|
|
86
|
+
known.push(` stunbolt -- direct mana, merciful: same reach as manabolt but the damage is STUN. Damage F-2, drain F-3.${hint(' (cast stunbolt at <target>)')}`);
|
|
81
87
|
}
|
|
82
88
|
if (actor.knowsSpell('powerbolt')) {
|
|
83
|
-
known.push(` powerbolt -- direct physical: resisted by BODY alone; armor still means nothing. Damage F-2, drain F-3
|
|
89
|
+
known.push(` powerbolt -- direct physical: resisted by BODY alone; armor still means nothing. Damage F-2, drain F-3.${hint(' (cast powerbolt at <target>)')}`);
|
|
84
90
|
}
|
|
85
91
|
if (actor.knowsSpell('fireball')) {
|
|
86
|
-
known.push(` fireball -- indirect elemental: soaked like a gunshot (Body + armor, AP F/3) but it hits at FULL Force. Drain F-2
|
|
92
|
+
known.push(` fireball -- indirect elemental: soaked like a gunshot (Body + armor, AP F/3) but it hits at FULL Force. Drain F-2.${hint(' (cast fireball at <target>)')}`);
|
|
87
93
|
}
|
|
88
94
|
if (actor.knowsSpell('heal')) {
|
|
89
|
-
known.push(` heal -- knit physical wounds closed, yours or an ally's (touch range); Force caps the boxes. Drain F-4
|
|
95
|
+
known.push(` heal -- knit physical wounds closed, yours or an ally's (touch range); Force caps the boxes. Drain F-4.${hint(' (cast heal [on <ally>])')}`);
|
|
90
96
|
}
|
|
91
97
|
if (actor.knowsSpell('armor')) {
|
|
92
|
-
known.push(` armor -- sustained weave, +ceil(F/3)+focus soak at -2 dice for its bearer. Drain F-4
|
|
98
|
+
known.push(` armor -- sustained weave, +ceil(F/3)+focus soak at -2 dice for its bearer. Drain F-4.${hint(' (cast armor [on <ally>])')}`);
|
|
93
99
|
}
|
|
94
100
|
if (actor.knowsSpell('invisibility')) {
|
|
95
|
-
known.push(` invisibility -- sustained: light slides around the bearer, +3 on sneak contests at -2 dice. Drain F-4
|
|
101
|
+
known.push(` invisibility -- sustained: light slides around the bearer, +3 on sneak contests at -2 dice. Drain F-4.${hint(' (cast invisibility [on <ally>])')}`);
|
|
96
102
|
}
|
|
97
103
|
if (actor.knowsSpell('reflexes')) {
|
|
98
|
-
known.push(` increase reflexes -- sustained: +2 initiative for the bearer at -2 dice. Drain F-3
|
|
104
|
+
known.push(` increase reflexes -- sustained: +2 initiative for the bearer at -2 dice. Drain F-3.${hint(' (cast increase reflexes [on <ally>])')}`);
|
|
99
105
|
}
|
|
100
106
|
if (known.length === 0) {
|
|
101
107
|
known.push(` (none -- a focus channels power, but the spells themselves take a formula, a grimoire, or the Awakened gift)`);
|
|
102
108
|
}
|
|
103
109
|
lines.push(...known);
|
|
104
|
-
|
|
105
|
-
|
|
110
|
+
// The FORCE tutorial is pure coaching -- the whole paragraph rides
|
|
111
|
+
// the hints toggle (player ruling); veterans keep just the book.
|
|
112
|
+
const forceHelp = hint(`FORCE is the dial (SR5e p.281): "cast <spell> <force> ...". Leave it off and the spell casts at its drain-neutral Force (F3 for an F-3 spell -- costs nothing); every point higher buys power and bills drain, resisted with Willpower onto your STUN track (${actor.stunSummary()}). Cast PAST your talent${actor.isAwakened() ? ` (${actor.magic})` : ' (4, book-taught)'} and the drain turns PHYSICAL -- overcasting is how legends and corpses are made. Twice your talent is the hard ceiling.`);
|
|
113
|
+
if (forceHelp) {
|
|
114
|
+
lines.push('');
|
|
115
|
+
lines.push(forceHelp);
|
|
116
|
+
}
|
|
106
117
|
return lines.join('\n');
|
|
107
118
|
}
|
|
108
119
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spells.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/spells.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;
|
|
1
|
+
{"version":3,"file":"spells.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/spells.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C;;;;;;;GAOG;AACH,MAAM,OAAO,aAAc,SAAQ,OAAO;IAC9B,MAAM,CAAC,IAAI,GAAG,QAAQ,CAAC;IACvB,MAAM,CAAC,WAAW,GAAG,wFAAwF,CAAC;IAExH,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE;QAChC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QAEzB,kEAAkE;QAClE,qEAAqE;QACrE,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9B,KAAK,CAAC,IAAI,CAAC,0FAA0F,IAAI,CAAC,2BAA2B,CAAC,EAAE,CAAC,CAAC;QAC5I,CAAC;QACD,IAAI,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,EAAE,CAAC;YACrC,KAAK,CAAC,IAAI,CAAC,2GAA2G,IAAI,CAAC,kCAAkC,CAAC,EAAE,CAAC,CAAC;QACpK,CAAC;QACD,IAAI,KAAK,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,CAAC;YACjC,KAAK,CAAC,IAAI,CAAC,wFAAwF,IAAI,CAAC,uCAAuC,CAAC,EAAE,CAAC,CAAC;QACtJ,CAAC;QACD,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YACvB,KAAK,CAAC,IAAI,CAAC,gHAAgH,CAAC,CAAC;QAC/H,CAAC;QACD,KAAK,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,CAAC;QAErB,mEAAmE;QACnE,iEAAiE;QACjE,MAAM,SAAS,GAAG,IAAI,CAAC,gQAAgQ,KAAK,CAAC,WAAW,EAAE,2BAA2B,KAAK,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,KAAK,KAAK,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC,mBAAmB,0HAA0H,CAAC,CAAC;QAC/f,IAAI,SAAS,EAAE,CAAC;YACd,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;YACf,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QACxB,CAAC;QAED,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC1B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
2
|
import { rollPool, formatRoll } from '../utilities/dice.js';
|
|
3
|
+
import { hint } from '../utilities/hints.js';
|
|
3
4
|
/**
|
|
4
5
|
* Conjuring (SR5e p.300-303): "summon <force>" calls a spirit -- an
|
|
5
6
|
* opposed Magic + conjuring test against the spirit's Force dice. NET
|
|
@@ -87,7 +88,7 @@ export class SummonCommand extends Command {
|
|
|
87
88
|
services,
|
|
88
89
|
});
|
|
89
90
|
lines.push(shell
|
|
90
|
-
? ` Something crosses over and takes shape beside you -- materialized, patient, OWED. ${services} service${services === 1 ? '' : 's'} on the bargain
|
|
91
|
+
? ` Something crosses over and takes shape beside you -- materialized, patient, OWED. ${services} service${services === 1 ? '' : 's'} on the bargain.${hint(` (It follows; it fights -- one service per fight; "order" it; "summon" again to release it.)`)}`
|
|
91
92
|
: ` Something crosses -- and snags on a name already taken. The summons collapses.`);
|
|
92
93
|
}
|
|
93
94
|
this.logger.meta(`Drain (${drainValue}${overcast ? ', OVERCAST -- physical' : ''}): resist ${formatRoll(resist)}`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"summon.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/summon.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"summon.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/summon.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C;;;;;;;;;;;;GAYG;AACH,MAAM,OAAO,aAAc,SAAQ,OAAO;IAC9B,MAAM,CAAC,IAAI,GAAG,QAAQ,CAAC;IACvB,MAAM,CAAC,WAAW,GAAG,4LAA4L,CAAC;IAE5N,KAAK,CAAC,OAAO,CAAC,OAAiB,EAAE;QAC/B,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QACzB,MAAM,IAAI,GAAG,IAAI,CA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U,CAAC,UAAU,CAAC,CAAC;YAC7B,KAAK,CAAC,IAAI,CAAC,uDAAuD,UAAU,cAAc,KAAK,CAAC,gBAAgB,EAAE,EAAE,CAAC,CAAC;QACxH,CAAC;aAAM,CAAC;YACN,MAAM,EAAE,IAAI,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;YACtD,KAAK,CAAC,IAAI,CAAC,wBAAwB,IAAI,UAAU,KAAK,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC;YACxE,IAAI,QAAQ,GAAG,CAAC,EAAE,CAAC;gBACjB,KAAK,CAAC,IAAI,CAAC,0CAA0C,QAAQ,OAAO,QAAQ,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,0BAA0B,KAAK,CAAC,gBAAgB,EAAE,EAAE,CAAC,CAAC;YACtJ,CAAC;QACH,CAAC;QAED,IAAI,CAAC,KAAK,CAAC,YAAY,EAAE,CAAC;QAC1B,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC1B,CAAC"}
|
|
@@ -39,6 +39,10 @@ export class SurrenderCommand extends Command {
|
|
|
39
39
|
this.scene.addWorldEvent(`${actor.name} surrendered in ${actor.currentLocation?.name ?? 'the field'}.`);
|
|
40
40
|
this.logger.write(`${actor.name} surrendered.`);
|
|
41
41
|
this.scene.updateStatus();
|
|
42
|
+
// A hostile throwing in the towel can be what settles the room around
|
|
43
|
+
// a knocked-out player (a real session: Vex surrendered to the bound
|
|
44
|
+
// spirit ten seconds after the player dropped).
|
|
45
|
+
this.scene.maybeResolvePlayerKnockout();
|
|
42
46
|
return `You raise your hands -- the fight is over, as far as you're concerned. Whether they honor it is up to them.`;
|
|
43
47
|
}
|
|
44
48
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surrender.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/surrender.ts"],"names":[],"mappings":"A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AE1B,sEAAsE;QACtE,qEAAqE;QACrE,gDAAgD;QAChD,IAAI,CAAC,KAAK,CAAC,0BAA0B,EAAE,CAAC;QAExC,OAAO,6GAA6G,CAAC;IACvH,CAAC"}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
2
|
import { canReachHost } from '../utilities/planes.js';
|
|
3
|
+
import { canReach, ensureAtSpot } from '../utilities/spots.js';
|
|
4
|
+
import { hint } from '../utilities/hints.js';
|
|
3
5
|
export class TakeCommand extends Command {
|
|
4
6
|
static verb = 'take';
|
|
5
7
|
static description = 'Pick up an item. "take all" sweeps everything here -- but only after you have searched the room.';
|
|
@@ -62,7 +64,14 @@ export class TakeCommand extends Command {
|
|
|
62
64
|
if (items.length === 0) {
|
|
63
65
|
return `There's nothing here to take.`;
|
|
64
66
|
}
|
|
65
|
-
|
|
67
|
+
// "At" spots: a sweep covers where you're STANDING -- anchored goods
|
|
68
|
+
// elsewhere in the room need you (or a walk) over there.
|
|
69
|
+
const outOfReach = items.filter(i => !canReach(this.actor, i.atSpot));
|
|
70
|
+
items = items.filter(i => canReach(this.actor, i.atSpot));
|
|
71
|
+
if (items.length === 0 && outOfReach.length > 0) {
|
|
72
|
+
const spotsWith = [...new Set(outOfReach.map(i => i.atSpot))];
|
|
73
|
+
return `Nothing within reach -- the goods are over at the ${spotsWith.join(', the ')}. ("move to ${spotsWith[0]}")`;
|
|
74
|
+
}
|
|
66
75
|
const lines = [`You sweep ${room.name}:`];
|
|
67
76
|
let tookAnything = false;
|
|
68
77
|
const taken = [];
|
|
@@ -72,7 +81,9 @@ export class TakeCommand extends Command {
|
|
|
72
81
|
room.inventory.removeItem(item.name);
|
|
73
82
|
room.plainSightItems.delete(item.name.toLowerCase());
|
|
74
83
|
tookAnything = true;
|
|
75
|
-
|
|
84
|
+
// Owned goods carry their owner's name into the witness event --
|
|
85
|
+
// see the theft note on the single-item path below.
|
|
86
|
+
taken.push(item.owner && item.owner !== this.actor.name ? `${item.name} (${item.owner}'s)` : item.name);
|
|
76
87
|
this.logger.write(`take all: ${this.actor.name} took "${item.name}" from ${room.name}.`);
|
|
77
88
|
lines.push(` • took the ${item.name}`);
|
|
78
89
|
if (item.owner && item.owner !== this.actor.name) {
|
|
@@ -84,8 +95,17 @@ export class TakeCommand extends Command {
|
|
|
84
95
|
lines.push(` • the ${item.name} is too heavy to carry -- left it`);
|
|
85
96
|
}
|
|
86
97
|
}
|
|
98
|
+
// AFTER the loop, so the witnesses' event names what actually left
|
|
99
|
+
// the room (owners included) -- "everything in the room" gave a
|
|
100
|
+
// robbed NPC nothing to recognize as theirs.
|
|
101
|
+
this.actor.performAction('take', taken.length > 0 ? taken.join(', ') : 'everything in the room');
|
|
87
102
|
if (!searched) {
|
|
88
|
-
|
|
103
|
+
const note = hint(` (just what was lying in the open -- "search" to case the rest of the place)`);
|
|
104
|
+
if (note)
|
|
105
|
+
lines.push(note);
|
|
106
|
+
}
|
|
107
|
+
if (outOfReach.length > 0) {
|
|
108
|
+
lines.push(` (left where they sit: ${outOfReach.map(i => `${i.name} at the ${i.atSpot}`).join(', ')})`);
|
|
89
109
|
}
|
|
90
110
|
if (tookAnything) {
|
|
91
111
|
this.scene.updateInventory(this.scene.getPlayer().inventory);
|
|
@@ -146,9 +166,22 @@ export class TakeCommand extends Command {
|
|
|
146
166
|
return `The ${item.name} is sealed inside the host's data vault. Crack the node first ("hack") -- then it's yours.`;
|
|
147
167
|
}
|
|
148
168
|
}
|
|
169
|
+
// "At" spots: hands need to be where the goods are -- out of combat
|
|
170
|
+
// that's a free walk over (utilities/spots.ts ensureAtSpot).
|
|
171
|
+
const reach = ensureAtSpot(this.actor, item.atSpot);
|
|
172
|
+
if (reach.refusal)
|
|
173
|
+
return reach.refusal;
|
|
174
|
+
if (reach.line && this.actor === this.scene.getPlayer()) {
|
|
175
|
+
this.logger.log(reach.line);
|
|
176
|
+
}
|
|
149
177
|
// Try adding the item to the player's inventory
|
|
150
178
|
try {
|
|
151
|
-
|
|
179
|
+
// The witness event carries the RESOLVED item name and, when the
|
|
180
|
+
// goods are someone else's, the owner -- a real session's player
|
|
181
|
+
// pocketed Mr. Krow's credstick AT HIS DESK and Krow's history
|
|
182
|
+
// read only "Maka take credstick": nothing marked it as his
|
|
183
|
+
// (NPC.see keys its theft reaction off this).
|
|
184
|
+
this.actor.performAction('take', item.owner && item.owner !== this.actor.name ? `${item.name} (${item.owner}'s)` : item.name);
|
|
152
185
|
this.actor.addInventory(item);
|
|
153
186
|
this.logger.write(`Successfully added "${itemName}" to ${this.actor.name}'s inventory during 'Take' command.`);
|
|
154
187
|
if (item.owner && item.owner !== this.actor.name) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"take.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/take.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"take.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/take.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAC/D,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAE7C,MAAM,OAAO,WAAY,SAAQ,OAAO;IAC5B,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC;IACrB,MAAM,CAAC,WAAW,GAAG,kGAAkG,CAAC;IAElI,KAAK,CAAC,OAAO,CAAC,IAAc;QAC1B,IAAI,CAAC,IAAI;YAAE,OAAO,EAAE,CAAC;QACrB,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,wCAAwC,IAAI,EAAE,IAAI,CAAC,GAAG,CAAC,EAAE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C,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,WAAW,EAAE,CAAC,CAAC;YACrD,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,yBAAyB,QAAQ,UAAU,IAAI,CAAC,IAAI,0CAA0C,CAAC,CAAC;YAElH,mEAAmE;YACnE,qEAAqE;YACrE,mEAAmE;YACnE,qEAAqE;YACrE,gEAAgE;YAChE,oEAAoE;YACpE,kEAAkE;YAClE,qEAAqE;YACrE,iCAAiC;YACjC,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,KAAK,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,CAAC;YACvD,IAAI,QAAQ,EAAE,CAAC;gBACb,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,sBAAsB,QAAQ,GAAG,CAAC,CAAC;YACrD,CAAC;YACD,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,oBAAoB,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;gBACtD,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;YAC3D,CAAC;YAED,OAAO,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,sBAAsB,QAAQ,GAAG,CAAC;QAE3D,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,gCAAgC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;YACnE,OAAO,aAAa,QAAQ,0BAA0B,CAAC;QACzD,CAAC;IACH,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
|
+
import { sameSpot, spotOf, spotRefusal } from '../utilities/spots.js';
|
|
2
3
|
export function parseArgsWithQuotes(input) {
|
|
3
4
|
const regex = /"([^"]+)"|(\S+)/g;
|
|
4
5
|
const args = [];
|
|
@@ -45,6 +46,11 @@ export class TalkCommand extends Command {
|
|
|
45
46
|
if (target === speaker) {
|
|
46
47
|
return "You can't talk to yourself (try 'say' instead).";
|
|
47
48
|
}
|
|
49
|
+
// "At" spots: conversation needs shared ground (see
|
|
50
|
+
// utilities/spots.ts) -- the bartender doesn't lean across the room.
|
|
51
|
+
if (!sameSpot(speaker, target)) {
|
|
52
|
+
return spotRefusal(target.name, spotOf(target));
|
|
53
|
+
}
|
|
48
54
|
// Cross-plane whisper goes nowhere -- target.hear() would drop it
|
|
49
55
|
// silently (see Player.canPerceive), so refuse with the actual rule
|
|
50
56
|
// instead of confirming a conversation that never happened.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"talk.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/talk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAuB,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"talk.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/talk.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAuB,MAAM,cAAc,CAAC;AAE5D,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEtE,MAAM,UAAU,mBAAmB,CAAC,KAAa;IAC/C,MAAM,KAAK,GAAG,kBAAkB,CAAC;IACjC,MAAM,IAAI,GAAa,EAAE,CAAC;IAC1B,IAAI,KAAK,CAAC;IACV,OAAO,CAAC,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,KAAK,IAAI,EAAE,CAAC;QAC5C,IAAI,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC;YACb,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;QACtB,CAAC;aAAM,CAAC;YACN,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;QACtB,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AAK,UAAU,CAAC,WAAW,EAAE,CACtD,CAAC;QAEF,IAAI,CAAC,MAAM,EAAE,CAAC;YACZ,OAAO,+BAA+B,UAAU,SAAS,CAAC;QAC5D,CAAC;QAED,IAAI,MAAM,KAAK,OAAO,EAAE,CAAC;YACvB,OAAO,iDAAiD,CAAC;QAC3D,CAAC;QAED,oDAAoD;QACpD,qEAAqE;QACrE,IAAI,CAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC;YAC/B,OAAO,WAAW,CAAC,MAAM,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,CAAE,CAAC,CAAC;QACnD,CAAC;QAED,kEAAkE;QAClE,oEAAoE;QACpE,4DAA4D;QAC5D,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,CAAC,EAAE,CAAC;YACjC,OAAO,OAAO,CAAC,KAAK,KAAK,QAAQ;gBAC/B,CAAC,CAAC,GAAG,MAAM,CAAC,IAAI,iIAAiI;gBACjJ,CAAC,CAAC,GAAG,MAAM,CAAC,IAAI,+CAA+C,CAAC;QACpE,CAAC;QAED,wBAAwB;QACxB,MAAM,OAAO,CAAC,IAAI,CAAC,OAAO,EAAE,OAAO,MAAM,CAAC,IAAI,KAAK,OAAO,EAAE,CAAC,CAAC;QAC9D,MAAM,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,eAAe,OAAO,EAAE,CAAC,CAAC;QAErD,OAAO,eAAe,MAAM,CAAC,IAAI,gBAAgB,OAAO,GAAG,CAAC;IAC9D,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
|
+
import { sameSpot, spotOf, spotRefusal } from '../utilities/spots.js';
|
|
2
3
|
/**
|
|
3
4
|
* Street-doc services (SR5e p.42, "Staying Healthy"): paid physical
|
|
4
5
|
* healing at a clinic -- the certain, expensive alternative to burning
|
|
@@ -31,6 +32,10 @@ export class TreatCommand extends Command {
|
|
|
31
32
|
if (!doc) {
|
|
32
33
|
return `The clinic's open but nobody with steady hands is in it.`;
|
|
33
34
|
}
|
|
35
|
+
// "At" spots: hands-on medicine needs the patient in reach.
|
|
36
|
+
if (!sameSpot(actor, doc)) {
|
|
37
|
+
return spotRefusal(doc.name, spotOf(doc));
|
|
38
|
+
}
|
|
34
39
|
if (actor.damageTaken === 0) {
|
|
35
40
|
return `${doc.name} looks you over. "You're intact. Go be somebody's problem elsewhere."`;
|
|
36
41
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"treat.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/treat.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"treat.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/treat.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AAEjD,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAEtE;;;;;;GAMG;AACH,MAAM,OAAO,YAAa,SAAQ,OAAO;IAC7B,MAAM,CAAC,IAAI,GAAG,OAAO,CAAC;IACtB,MAAM,CAAC,WAAW,GAAG,gIAAgI,CAAC;IAExJ,MAAM,CAAU,aAAa,GAAG,GAAG,CAAC;IAE5C,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE;QAChC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QAEzB,IAAI,KAAK,CAAC,KAAK,KAAK,MAAM,EAAE,CAAC;YAC3B,OAAO,yDAAyD,CAAC;QACnE,CAAC;QACD,IAAI,KAAK,CAAC,UAAU,EAAE,CAAC;YACrB,OAAO,iCAAiC,CAAC;QAC3C,CAAC;QACD,IAAI,KAAK,CAAC,MAAM,EAAE,EAAE,CAAC;YACnB,OAAO,wBAAwB,CAAC;QAClC,CAAC;QAED,MAAM,IAAI,GAAG,KA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;YAC/E,KAAK,MAAM,OAAO,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,eAAe,IAAI,WAAW,KAAK,CAAC,QAAQ,WAAW,KAAK,CAAC,gBAAgB,EAAE,EAAE;SAC5H,CAAC;QACF,IAAI,KAAK,CAAC,WAAW,GAAG,CAAC,EAAE,CAAC;YAC1B,KAAK,CAAC,IAAI,CAAC,MAAM,KAAK,CAAC,WAAW,2DAA2D,CAAC,CAAC;QACjG,CAAC;QACD,2DAA2D;QAC3D,MAAM,IAAI,GAAG,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,GAAG,CAAC,IAAI,EAAE,OAAO,EAAE,IAAI,CAAC,CAAC;QAC9D,IAAI,IAAI;YAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC3B,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC1B,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Door } from '../models/door.js';
|
|
2
2
|
import { Command } from './command.js';
|
|
3
|
+
import { exitSpot, ensureAtSpot } from '../utilities/spots.js';
|
|
3
4
|
export class UnlockCommand extends Command {
|
|
4
5
|
static verb = 'unlock';
|
|
5
6
|
static description = 'Unlock a door.';
|
|
@@ -42,6 +43,12 @@ export class UnlockCommand extends Command {
|
|
|
42
43
|
this.logger.write(`UnlockCommand: Exit found but is not a door: "${target}"`);
|
|
43
44
|
return `There's no door named or leading to "${target}" here.`;
|
|
44
45
|
}
|
|
46
|
+
// "At" spots: a key turns in a lock you're standing at (see
|
|
47
|
+
// utilities/spots.ts) -- out of combat that's a free walk over.
|
|
48
|
+
const reach = ensureAtSpot(this.actor, exitSpot(room, direction));
|
|
49
|
+
if (reach.refusal)
|
|
50
|
+
return reach.refusal;
|
|
51
|
+
const crossNote = reach.line ? `${reach.line}\n` : '';
|
|
45
52
|
const requiredKeyOrSolution = door.unlockItemOrSolution?.toLowerCase();
|
|
46
53
|
if (requiredKeyOrSolution && this.actor.inventory.hasItem(requiredKeyOrSolution)) {
|
|
47
54
|
const key = this.actor.inventory.getItem(requiredKeyOrSolution);
|
|
@@ -51,11 +58,11 @@ export class UnlockCommand extends Command {
|
|
|
51
58
|
this.actor.performAction('unlocked', unlockMessage);
|
|
52
59
|
this.scene.addWorldEvent(`${this.actor.name} unlocked the ${direction} door in ${room.name}.`);
|
|
53
60
|
this.scene.updateExits(room);
|
|
54
|
-
return unlockMessage;
|
|
61
|
+
return crossNote + unlockMessage;
|
|
55
62
|
}
|
|
56
63
|
}
|
|
57
64
|
this.logger.write(`UnlockCommand: ${this.actor.name} does not have the required key (${requiredKeyOrSolution}) for "${target}".`);
|
|
58
|
-
return `You don't have the key or solution to unlock this door.`;
|
|
65
|
+
return crossNote + `You don't have the key or solution to unlock this door.`;
|
|
59
66
|
}
|
|
60
67
|
}
|
|
61
68
|
//# sourceMappingURL=unlock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unlock.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/unlock.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"unlock.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/unlock.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAE/D,MAAM,OAAO,aAAc,SAAQ,OAAO;IAC9B,MAAM,CAAC,IAAI,GAAG,QAAQ,CAAC;IACvB,MAAM,CAAC,WAAW,GAAG,gBAAgB,CAAC;IAEhD,KAAK,CAAC,OAAO,CAAC,IAAc;Q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C,SAAS,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;YAEhE,IAAI,GAAG,EAAE,CAAC;gBACR,MAAM,aAAa,GAAG,IAAI,CAAC,iBAAiB,CAAC,SAAS,EAAE,GAAG,CAAC,IAAI,CAAC,CAAC;gBAClE,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,kBAAkB,IAAI,CAAC,KAAK,CAAC,IAAI,wBAAwB,SAAS,aAAa,aAAa,EAAE,CAAC,CAAC;gBAClH,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,UAAU,EAAE,aAAa,CAAC,CAAC;gBACpD,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,iBAAiB,SAAS,YAAY,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;gBAC/F,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC;gBAC7B,OAAO,SAAS,GAAG,aAAa,CAAC;YACnC,CAAC;QACH,CAAC;QAED,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,kBAAkB,IAAI,CAAC,KAAK,CAAC,IAAI,oCAAoC,qBAAqB,UAAU,MAAM,IAAI,CAAC,CAAC;QAClI,OAAO,SAAS,GAAG,yDAAyD,CAAC;IAC/E,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Command } from './command.js';
|
|
2
|
+
import { hint } from '../utilities/hints.js';
|
|
2
3
|
import { Item } from '../models/item.js';
|
|
3
4
|
import { Size, Category, Rating } from '../types/shared/item-enum.js';
|
|
4
5
|
/**
|
|
@@ -61,7 +62,7 @@ export class WorkCommand extends Command {
|
|
|
61
62
|
});
|
|
62
63
|
return [
|
|
63
64
|
`${giver.name}: "${offer.brief}"`,
|
|
64
|
-
` The ${offer.itemName} changes hands. ${offer.pay} nuyen when it reaches ${offer.to}
|
|
65
|
+
` The ${offer.itemName} changes hands. ${offer.pay} nuyen when it reaches ${offer.to}.${hint(` ("give ${offer.itemName.toLowerCase()} to ${offer.to.toLowerCase()}")`)}`,
|
|
65
66
|
].join('\n');
|
|
66
67
|
}
|
|
67
68
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"work.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/commands/work.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAY,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AACzC,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAC;AAEtE;;;;;;;;GAQG;AACH,MAAM,OAAO,WAAY,SAAQ,OAAO;IAC5B,MAAM,CAAC,IAAI,GAAG,MAAM,CAAC;IACrB,MAAM,CAAC,WAAW,GAAG,4IAA4I,CAAC;IAE5K,KAAK,CAAC,OAAO,CAAC,QAAkB,EAAE;QAChC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QAEzB,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC;YACvB,OAAO,8CAA8C,CAAC;QACxD,CAAC;QACD,IAAI,KAAK,CAAC,KAAK,KAAK,MAAM,EAAE,CAAC;YAC3B,OAAO,8CAA8C,CAAC;QACxD,CAAC;QAED,MAAM,GAAG,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC;QAChC,IAAI,GAAG,EAAE,CAAC;YACR,OAAO,KAAK,CAAC,SAAS,CAAC,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC;gBAC1C,CAAC,CAAC,4BAA4B,GAAG,CAAC,QAAQ,OAAO,GAAG,CAAC,EAAE,KAAK,GAAG,CAAC,GAAG,qBAAqB;gBACxF,CAAC,CAAC,YAAY,GAAG,CAAC,IAAI,kBAAkB,GAAG,CAAC,QAAQ,2EAA2E,CAAC;QACpI,CAAC;QAED,MAAM,KAAK,GAAG,IAAI,CAAC,IAAI,CAAC,YAAY,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EAAE,qDAAqD,KAAK,CAAC,IAAI,QAAQ,KAAK,CAAC,QAAQ,kBAAkB,KAAK,CAAC,EAAE,QAAQ,KAAK,CAAC,GAAG,kDAAkD,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE;YACtO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,IAAI,4BAA4B,GAAG,EAAE,CAAC,CAAC;QACpE,CAAC,CAAC,CAAC;QAEH,OAAO;YACL,GAAG,KAAK,CAAC,IAAI,MAAM,KAAK,CAAC,KAAK,GAAG;YACjC,SAAS,KAAK,CAAC,QAAQ,mBAAmB,KAAK,CAAC,GAAG,0BAA0B,KAAK,CAAC,EAAE,IAAI,IAAI,CAAC,WAAW,KAAK,CAAC,QAAQ,CAAC,WAAW,EAAE,OAAO,KAAK,CAAC,EAAE,CAAC,WAAW,EAAE,IAAI,CAAC,EAAE;SAC1K,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACf,CAAC"}
|
|
@@ -16,7 +16,8 @@ export class ItemFactory {
|
|
|
16
16
|
satisfiesLifestyle: json.satisfiesLifestyle,
|
|
17
17
|
transferable: json.transferable,
|
|
18
18
|
plane: json.plane,
|
|
19
|
-
price: json.price
|
|
19
|
+
price: json.price,
|
|
20
|
+
atSpot: json.atSpot
|
|
20
21
|
});
|
|
21
22
|
if (json.currencyAmount && item.isCurrencyCarrier()) {
|
|
22
23
|
item.addCurrency(json.currencyAmount);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"item-factory.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/factories/item-factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEzC,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAC;AAEtE,MAAM,OAAO,WAAW;IACtB,KAAK,CAAC,kBAAkB,CAAC,IAAmB;QAC1C,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC;YACpB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC;YACrB,QAAQ,EAAE,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC;YACjC,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,MAAM,EAAE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,kBAAkB,EAAE,IAAI,CAAC,kBAAkB;YAC3C,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,KAAK,EAAE,IAAI,CAAC,KAAK;
|
|
1
|
+
{"version":3,"file":"item-factory.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/factories/item-factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEzC,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAC;AAEtE,MAAM,OAAO,WAAW;IACtB,KAAK,CAAC,kBAAkB,CAAC,IAAmB;QAC1C,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC;YACpB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC;YACrB,QAAQ,EAAE,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC;YACjC,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,MAAM,EAAE,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC;YAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,kBAAkB,EAAE,IAAI,CAAC,kBAAkB;YAC3C,YAAY,EAAE,IAAI,CAAC,YAAY;YAC/B,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,KAAK,EAAE,IAAI,CAAC,KAAK;YACjB,MAAM,EAAE,IAAI,CAAC,MAAM;SACpB,CAAC,CAAC;QAEH,IAAI,IAAI,CAAC,cAAc,IAAI,IAAI,CAAC,iBAAiB,EAAE,EAAE,CAAC;YACpD,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QACxC,CAAC;QAED,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"puzzle-factory.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/factories/puzzle-factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAI7C,MAAM,OAAO,aAAa;IACxB,KAAK,CAAC,oBAAoB,CAAC,IAAqB,EAAE,OAA0B;QAC1E,MAAM,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QACpF,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QAE9E,IAAI,IAAI,CAAC,YAAY,IAAI,CAAC,YAAY,EAAE,CAAC;YACvC,MAAM,IAAI,KAAK,CAAC,kBAAkB,IAAI,CAAC,YAAY,2BAA2B,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QAC9F,CAAC;QAED,IAAI,IAAI,CAAC,UAAU,IAAI,CAAC,UAAU,EAAE,CAAC;YACnC,MAAM,IAAI,KAAK,CAAC,gBAAgB,IAAI,CAAC,UAAU,2BAA2B,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QAC1F,CAAC;QAED,OAAO,IAAI,MAAM,CAAC;YAChB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,YAAY;YACZ,UAAU;YACV,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,UAAU,EAAE,IAAI,CAAC,UAAU;
|
|
1
|
+
{"version":3,"file":"puzzle-factory.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/factories/puzzle-factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAI7C,MAAM,OAAO,aAAa;IACxB,KAAK,CAAC,oBAAoB,CAAC,IAAqB,EAAE,OAA0B;QAC1E,MAAM,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QACpF,MAAM,UAAU,GAAG,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;QAE9E,IAAI,IAAI,CAAC,YAAY,IAAI,CAAC,YAAY,EAAE,CAAC;YACvC,MAAM,IAAI,KAAK,CAAC,kBAAkB,IAAI,CAAC,YAAY,2BAA2B,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QAC9F,CAAC;QAED,IAAI,IAAI,CAAC,UAAU,IAAI,CAAC,UAAU,EAAE,CAAC;YACnC,MAAM,IAAI,KAAK,CAAC,gBAAgB,IAAI,CAAC,UAAU,2BAA2B,IAAI,CAAC,IAAI,GAAG,CAAC,CAAC;QAC1F,CAAC;QAED,OAAO,IAAI,MAAM,CAAC;YAChB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,YAAY;YACZ,UAAU;YACV,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,UAAU,EAAE,IAAI,CAAC,UAAU;YAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;SACpB,CAAC,CAAC;IACL,CAAC;CACF"}
|
|
@@ -15,6 +15,11 @@ export class RoomFactory {
|
|
|
15
15
|
hasNode: roomJson.hasNode,
|
|
16
16
|
nodeAccess: roomJson.nodeAccess,
|
|
17
17
|
warded: roomJson.warded,
|
|
18
|
+
// "At" spots ride through -- this whitelist SILENTLY DROPS any
|
|
19
|
+
// field not named here (it already ate `owner` once; see the
|
|
20
|
+
// scene-factory patch that re-applies it).
|
|
21
|
+
spots: roomJson.spots,
|
|
22
|
+
size: roomJson.size,
|
|
18
23
|
supportedLifestyles: roomJson.supportedLifestyles
|
|
19
24
|
};
|
|
20
25
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"room-factory.js","sourceRoot":"","sources":["../../../../../../../src/commands/game/sideQuest/factories/room-factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAA0B,MAAM,qBAAqB,CAAC;AAGnE,MAAM,OAAO,WAAW;IACtB,KAAK,CAAC,kBAAkB,CAAC,MAAqB;QAC5C,MAAM,UAAU,GAA2B,IAAI,CAAC,2BAA2B,CAAC,MAAM,CAAC,CAAC;QACpF,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC,UAAU,CAAC,CAAC;QAClC,OAA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C;YAC3C,KAAK,EAAE,QAAQ,CAAC,KAAK;YACrB,IAAI,EAAE,QAAQ,CAAC,IAAI;YACnB,mBAAmB,EAAE,QAAQ,CAAC,mBAAmB;SAClD,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -88,6 +88,17 @@ export interface IRoomDetail {
|
|
|
88
88
|
name: string;
|
|
89
89
|
description: string;
|
|
90
90
|
roomType?: string;
|
|
91
|
+
size?: 'small' | 'medium' | 'large';
|
|
92
|
+
spots?: {
|
|
93
|
+
name: string;
|
|
94
|
+
tags?: string[];
|
|
95
|
+
}[];
|
|
96
|
+
npcSpots?: Record<string, string>;
|
|
97
|
+
itemSpots?: Record<string, string>;
|
|
98
|
+
/** direction -> spot each exit leaves from (a real session had a room
|
|
99
|
+
* where a barrier-blocked north exit and the south entrance BOTH read
|
|
100
|
+
* "from the entrance gate" via the doorway-name fallback). */
|
|
101
|
+
exitSpots?: Record<string, string>;
|
|
91
102
|
}
|
|
92
103
|
export interface INpcDetail {
|
|
93
104
|
name: string;
|