@adatechnology/game-test-room 0.25.0 → 0.25.2

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/dist/index.js CHANGED
@@ -8074,6 +8074,7 @@ function createTestRoom(options) {
8074
8074
  return true;
8075
8075
  };
8076
8076
  const extraScenarios = [...options.scenarios ?? []];
8077
+ let moduleHeld = false;
8077
8078
  const moduleCheck = (ok, text, data, itemId) => {
8078
8079
  log.add({ channel: "check", type: ok ? "pass" : "fail", text: `${ok ? "\u2713" : "\u2717"} ${text}`, itemId, data: { ok, ...data } });
8079
8080
  };
@@ -8198,7 +8199,11 @@ function createTestRoom(options) {
8198
8199
  loading,
8199
8200
  addView: (view) => moduleViews.add(view),
8200
8201
  setViewCamera: (view) => moduleViews.setMain(view ?? null),
8201
- holdPlayer: (held) => player.setWalkHeld(held),
8202
+ holdPlayer: (held) => {
8203
+ moduleHeld = held;
8204
+ player.setWalkHeld(held);
8205
+ },
8206
+ playerHeld: () => moduleHeld,
8202
8207
  ...options.blastShove ? { blastShove: options.blastShove } : {},
8203
8208
  blastReach: (point, target, ignore) => world.blastReach(point, target, ignore ? { ignore } : {}),
8204
8209
  tool: () => ({
@@ -8334,6 +8339,8 @@ function createTestRoom(options) {
8334
8339
  let handle = null;
8335
8340
  return {
8336
8341
  id: `vfx:${id}`,
8342
+ // the room was drawn in every fog state just before: each frame of a blast draws the effects alone
8343
+ root: () => vfx.root,
8337
8344
  play() {
8338
8345
  handle = vfx.play({ effect: id, point: [0, 0.1, -4], direction: [0, 1, 0], normal: [0, 1, 0] });
8339
8346
  },