star-canvas 0.1.9 → 0.1.10

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.d.cts CHANGED
@@ -64,7 +64,7 @@ interface GameContext {
64
64
  loop: (tick: GameTick) => GameLoop;
65
65
  /** The dedicated UI overlay manager. */
66
66
  readonly ui: GameUI;
67
- /** Converts DOM event coords to logical stage coords (CSS px). Clamps to canvas bounds. */
67
+ /** @deprecated Use g.tap/g.pointer coordinates directly they're already in canvas-space. */
68
68
  toStagePoint: (e: {
69
69
  clientX: number;
70
70
  clientY: number;
@@ -77,11 +77,11 @@ interface GameContext {
77
77
  x: number;
78
78
  y: number;
79
79
  }>() => DragState<T>;
80
- /** Register handler for tap/click (fires on pointerdown). Works anywhere on screen including letterbox. */
80
+ /** @deprecated Use g.tap polling in the game loop instead. */
81
81
  onTap: (handler: InputHandler) => void;
82
- /** Register handler for pointer move. Works anywhere on screen including letterbox. */
82
+ /** @deprecated Use g.pointer polling in the game loop instead. */
83
83
  onMove: (handler: InputHandler) => void;
84
- /** Register handler for pointer release (fires on pointerup). Works anywhere on screen including letterbox. */
84
+ /** @deprecated Use g.released polling in the game loop instead. */
85
85
  onRelease: (handler: InputHandler) => void;
86
86
  /** Tap this frame (pointerdown). Null if none. Canvas-space coords. Read in your game loop. */
87
87
  readonly tap: {
package/dist/index.d.ts CHANGED
@@ -64,7 +64,7 @@ interface GameContext {
64
64
  loop: (tick: GameTick) => GameLoop;
65
65
  /** The dedicated UI overlay manager. */
66
66
  readonly ui: GameUI;
67
- /** Converts DOM event coords to logical stage coords (CSS px). Clamps to canvas bounds. */
67
+ /** @deprecated Use g.tap/g.pointer coordinates directly they're already in canvas-space. */
68
68
  toStagePoint: (e: {
69
69
  clientX: number;
70
70
  clientY: number;
@@ -77,11 +77,11 @@ interface GameContext {
77
77
  x: number;
78
78
  y: number;
79
79
  }>() => DragState<T>;
80
- /** Register handler for tap/click (fires on pointerdown). Works anywhere on screen including letterbox. */
80
+ /** @deprecated Use g.tap polling in the game loop instead. */
81
81
  onTap: (handler: InputHandler) => void;
82
- /** Register handler for pointer move. Works anywhere on screen including letterbox. */
82
+ /** @deprecated Use g.pointer polling in the game loop instead. */
83
83
  onMove: (handler: InputHandler) => void;
84
- /** Register handler for pointer release (fires on pointerup). Works anywhere on screen including letterbox. */
84
+ /** @deprecated Use g.released polling in the game loop instead. */
85
85
  onRelease: (handler: InputHandler) => void;
86
86
  /** Tap this frame (pointerdown). Null if none. Canvas-space coords. Read in your game loop. */
87
87
  readonly tap: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "star-canvas",
3
- "version": "0.1.9",
3
+ "version": "0.1.10",
4
4
  "private": false,
5
5
  "description": "Canvas game utilities for reliable game initialization - part of Star SDK.",
6
6
  "type": "module",