@maka/maka-cli 5.176.0 → 5.178.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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maka/maka-cli",
3
- "version": "5.176.0",
3
+ "version": "5.178.0",
4
4
  "type": "module",
5
5
  "summary": "A command line tool for scaffolding Meteor 3.x applications using either React.",
6
6
  "description": "A command line tool for scaffolding Meteor 3.x applications using React.",
@@ -100,7 +100,14 @@ export class SayCommand extends Command {
100
100
  // comms visually reads as a different "space" than in-person speech.
101
101
  const inCall = !!currentPlayer.activeCallPartner || !!currentPlayer.crewChannel;
102
102
  const prefix = inCall ? `${CALL_ICON} ` : '';
103
- this.logger.logWithColor(`${prefix}${message}`, inCall ? CALL_COLOR : 'yellow', { actor: currentPlayer.name });
103
+ const speech = {
104
+ speaker: currentPlayer.name,
105
+ text: message,
106
+ self: true,
107
+ ...(inCall ? { comms: true } : {}),
108
+ ...(currentPlayer.gender ? { gender: currentPlayer.gender } : {}),
109
+ };
110
+ this.logger.logWithColor(`${prefix}${message}`, inCall ? CALL_COLOR : 'yellow', { actor: currentPlayer.name }, { speech });
104
111
  }
105
112
  // "say" and "call" are deliberately similar -- once a call connects
106
113
  // (see call.ts), the two ends keep talking with the same "say" command
@@ -437,5 +437,8 @@
437
437
  // release) still-embedded hubSeed. Hosted hub sessions
438
438
  // (createHeadlessHub) run the solo hub loop in the site's process with
439
439
  // a save sink; a browser player can enter the hub.
440
- export const ENGINE_VERSION = '1.51.0';
440
+ // 1.52.0 (2026-09-12): THE EMBEDDED HUB SEED IS GONE FROM SAVES. The one
441
+ // release of dual-writing is over: a save carries hubSeedRef only, and
442
+ // the site (sheet fallback) reads hubSeed on older docs alone.
443
+ export const ENGINE_VERSION = '1.52.0';
441
444
  //# sourceMappingURL=engine-version.js.map
@@ -12,7 +12,7 @@ import { findCatalogItem, itemFromCatalog, loadCatalog, augFor, spellFor, adeptP
12
12
  import { SKILL_GROUPS } from '../skill-groups.js';
13
13
  import { serializePlayer, serializeItem } from '../utilities/persistence.js';
14
14
  import { canonicalLifestyleTier, LIFESTYLE_TIERS, canonicalLifestyleOption, lifestyleOptionAllowed, LIFESTYLE_OPTIONS, } from '../utilities/commerce.js';
15
- import { SAVE_VERSION, DUAL_WRITE_HUB_SEED } from '../types/save-file.js';
15
+ import { SAVE_VERSION } from '../types/save-file.js';
16
16
  import { hubSeedRefOf } from '../utilities/hub-seed.js';
17
17
  /**
18
18
  * THE ENGINE-SIDE CHARACTER FACTORY -- one payload in, one bootable save
@@ -538,10 +538,9 @@ export function buildFromChargen(payload) {
538
538
  * truth this migration removes. Nothing in this repo creates a
539
539
  * character without first holding the served seed.
540
540
  *
541
- * The save records the seed by REFERENCE (hubSeedRef, from the stamp
542
- * the server put on it) and, for one release, still embeds it
543
- * (hubSeed) so a binary from before the migration can resume the
544
- * runner -- see ISaveFileV1.hubSeed and DUAL_WRITE_HUB_SEED in game.ts.
541
+ * The save records the seed by REFERENCE only (hubSeedRef, from the
542
+ * stamp the server put on it); the embedded copy stopped being written
543
+ * in 5.177.0 -- see ISaveFileV1.hubSeed.
545
544
  */
546
545
  export function createNewCharacterSave(payload, hubSeed) {
547
546
  if (!hubSeed || typeof hubSeed !== 'object' || !Array.isArray(hubSeed.rooms)) {
@@ -573,7 +572,6 @@ export function createNewCharacterSave(payload, hubSeed) {
573
572
  hubName: hubSeed.name ?? 'the hub',
574
573
  },
575
574
  hubSeedRef: hubSeedRefOf(hubSeed),
576
- ...(DUAL_WRITE_HUB_SEED ? { hubSeed } : {}),
577
575
  player: serializePlayer(player),
578
576
  game: {
579
577
  lifestyleTier, lifestyleOptions, rentDebt: 0, tier: 1, contacts: [],
@@ -18,7 +18,7 @@ import { Category, Size, Rating } from './types/shared/item-enum.js';
18
18
  import { Item } from './models/item.js';
19
19
  import { Room, Container } from './models/_index.js';
20
20
  import { Door } from './models/door.js';
21
- import { SAVE_VERSION, DUAL_WRITE_HUB_SEED } from './types/save-file.js';
21
+ import { SAVE_VERSION } from './types/save-file.js';
22
22
  import { hubSeedRefOf } from './utilities/hub-seed.js';
23
23
  import { serializePlayer, restorePlayer, captureHubOverlay, applyHubOverlay, applyHomeBlock, writeSaveAtomic, deleteSave, restoreItem, readSave, serializeItem, saveSlug, spillPathFor, } from './utilities/persistence.js';
24
24
  import { heartbeatPresence, heartbeatPresenceNow } from './utilities/social.js';
@@ -3536,9 +3536,9 @@ ${client.name} won't be remembering anything. Dead Johnsons pay nothing -- and t
3536
3536
  // BY REFERENCE (engine 1.51.0): the stamp maka-cli.com put on the
3537
3537
  // seed this session plays. An unstamped seed (a hand-written
3538
3538
  // fixture, a scene handed straight to Game.getInstance) records no
3539
- // ref; the dual-written embed below still carries it this release.
3539
+ // ref. The seed itself is never embedded (5.177.0): a resume plays
3540
+ // whatever maka-cli.com serves.
3540
3541
  hubSeedRef: hubSeedRefOf(this._hubSeed),
3541
- ...(DUAL_WRITE_HUB_SEED ? { hubSeed: this._hubSeed } : {}),
3542
3542
  player: serializePlayer(this.player),
3543
3543
  game: {
3544
3544
  location: this.hubLocationSnapshot(),
@@ -84,13 +84,14 @@ export class EmitterLogger extends Logger {
84
84
  const actor = g?.scene.getPlayerByName(d.actorName);
85
85
  return actor?.currentLocation ? { room: actor.currentLocation.name } : { actor: d.actorName };
86
86
  }
87
- log(message, scope) {
87
+ log(message, scope, data) {
88
88
  this.emit('log', message, scope ?? this.ambient('log'), {
89
89
  actor: currentSession()?.dispatch?.actorName,
90
+ ...(data ? { data } : {}),
90
91
  });
91
92
  }
92
- logWithColor(message, color = 'white', scope) {
93
- this.log(`{${color}-fg}${message}{/${color}-fg}`, scope);
93
+ logWithColor(message, color = 'white', scope, data) {
94
+ this.log(`{${color}-fg}${message}{/${color}-fg}`, scope, data);
94
95
  }
95
96
  meta(message, color, scope) {
96
97
  const text = color ? `{${color}-fg}${message}{/${color}-fg}` : message;
@@ -766,7 +766,8 @@ export class NPC extends Player {
766
766
  // SPEECH STAYS IN THE STORY. Someone on the other end of the bond
767
767
  // talking to you is fiction, and burying it in the Mechanics
768
768
  // ticker would mean missing "Rattle's not budging, need your call".
769
- this.logger.logWithColor(`${style.icon} ${this.name}: "${spoken}"`, style.color);
769
+ const speech = { speaker: this.name, text: spoken, link: true, ...(this.gender ? { gender: this.gender } : {}) };
770
+ this.logger.logWithColor(`${style.icon} ${this.name}: "${spoken}"`, style.color, undefined, { speech });
770
771
  }
771
772
  else {
772
773
  // TELEMETRY GOES TO MECHANICS (player ruling 2026-08-25: the
@@ -2821,11 +2821,22 @@ export class Player extends AbstractPlayer {
2821
2821
  // room -- a cross-room say over a call would render to the wrong
2822
2822
  // side, and two humans sharing a room would each see the line
2823
2823
  // twice. Solo Logger ignores the scope (inert third arg).
2824
+ // SPOKEN LINES AS DATA (emitter.ts SpeechData): the words ride beside
2825
+ // the text so the browser can hand them to a voice. Inert solo.
2826
+ const speech = (comms) => ({
2827
+ speech: {
2828
+ speaker: actor.name,
2829
+ text: message,
2830
+ ...(actor === this ? { self: true } : {}),
2831
+ ...(comms ? { comms: true } : {}),
2832
+ ...(actor.gender ? { gender: actor.gender } : {}),
2833
+ },
2834
+ });
2824
2835
  if (this.activeCallPartner === actor && actor.currentLocation !== this.currentLocation) {
2825
- this.logger.logWithColor(`${CALL_ICON} ${actor.name} (over comms): ${message}`, CALL_COLOR, { actor: this.name });
2836
+ this.logger.logWithColor(`${CALL_ICON} ${actor.name} (over comms): ${message}`, CALL_COLOR, { actor: this.name }, speech(true));
2826
2837
  return;
2827
2838
  }
2828
- this.logger.logWithColor(`{white-fg}${actor.name}:{/white-fg} ${message}`, (actor === this) ? 'yellow' : 'green', { actor: this.name });
2839
+ this.logger.logWithColor(`{white-fg}${actor.name}:{/white-fg} ${message}`, (actor === this) ? 'yellow' : 'green', { actor: this.name }, speech(false));
2829
2840
  }
2830
2841
  see(actor, verb, details, quiet) {
2831
2842
  if (actor !== this && this.canPerceive(actor)) {
@@ -11,12 +11,4 @@
11
11
  * deletion -- an old save outlives the build that can't read it).
12
12
  */
13
13
  export const SAVE_VERSION = 1;
14
- /**
15
- * ONE RELEASE OF DUAL-WRITING (user decision 2026-09-12). While true,
16
- * every save carries BOTH hubSeedRef and the embedded hubSeed, so a
17
- * terminal still on 5.175.x can resume a runner the browser hub or a
18
- * 5.176.0 terminal has touched. 5.177.0 flips this off; readers never
19
- * depend on it either way.
20
- */
21
- export const DUAL_WRITE_HUB_SEED = true;
22
14
  //# sourceMappingURL=save-file.js.map
@@ -88,7 +88,7 @@ export class Logger {
88
88
  // solo screen shows the local player everything its callers already
89
89
  // gated for. A headless session's EmitterLogger reads it (or applies
90
90
  // the ambient dispatch default) to stamp per-player visibility.
91
- log(message, _scope) {
91
+ log(message, _scope, _data) {
92
92
  const logBox = this.screen?.children.find(child => child.type === 'box' && child.options.id === 'logBox');
93
93
  if (logBox) {
94
94
  logBox.insertBottom(message); // Supports color tags
@@ -106,9 +106,11 @@ export class Logger {
106
106
  // not the system log (player request: two files).
107
107
  this.transcript(message);
108
108
  }
109
- logWithColor(message, color = 'white', scope) {
109
+ // `data` rides the same way as `scope`: inert on the solo screen, stamped
110
+ // onto the event by a headless session's EmitterLogger (GameEvent.data).
111
+ logWithColor(message, color = 'white', scope, data) {
110
112
  const coloredMessage = `{${color}-fg}${message}{/${color}-fg}`;
111
- this.log(coloredMessage, scope);
113
+ this.log(coloredMessage, scope, data);
112
114
  }
113
115
  /**
114
116
  * The MECHANICS ticker (readability pass): dice anatomy and resource
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@maka/maka-cli",
3
- "version": "5.176.0",
3
+ "version": "5.178.0",
4
4
  "type": "module",
5
5
  "summary": "A command line tool for scaffolding Meteor 3.x applications using either React.",
6
6
  "description": "A command line tool for scaffolding Meteor 3.x applications using React.",