Log inGet started
World

Pocket Putt Islands

Merged

flickShot 1.2.0: keep the finger on the ball on engines that report positions in touch pixels

#1
Author
claude-code @ auraAgent
Opened
Nov 16, 2026
From
fix/flickshot-render-size-pointer
Into
main
Merged
Nov 16, 2026

Problem: below full render resolution, today's engine reports worldToScreen/screenToRay/getViewportSize in render-scaled pixels while touches arrive in display pixels, so flickShot 1.1.1 multiplies touches by renderer.resolutionScale(). A coming engine reports everything in touch pixels and adds a renderer call answering the size the scene is rendered at; there the correction makes the finger miss the ball and no shot fires.

Change (input.module): renderSizeCall() looks on the renderer for a render-size call (renderSize, renderResolution, renderedSize, sceneRenderSize) and accepts it only when it answers a {width, height} table; cached per renderer. pointerScale(): pinned override > 1 when the call exists > render scale (unchanged 1.1.1 behaviour). New api.pointerScaleSource(). Detection reads what the engine offers, never a version number. This engine (fe767b9) has no such call, so behaviour here is unchanged.

Tests: 4 new in 'pointer space on older and newer engines' with a stand-in renderer: absent -> touches scaled, finger at displayed ball grabs, unscaled misses; present -> touches as-is grab, the old correction misses; failing/empty call counts as absent, override wins; live engine detection. The 4 real-render 1.1.1 regression tests stand down on an engine with the call. Suite 31/31.

Docs: README section on touch accuracy at lower render scale + Changes; both guides gain a phone/tablet section; package.yaml 1.2.0. Also ships the ShotCam chase camera committed earlier on main.

22 files changed

  • ChangedflickShot.packageFolderBeforeAfter
  • ChangedflickShot.package/README.md12.2 KB → 14.5 KBBeforeAfter
  • AddedflickShot.package/ShotCam.componentFolderAfter
  • AddedflickShot.package/ShotCam.component/.metadata131 BAfter
  • AddedflickShot.package/ShotCam.component/README.md982 BAfter
  • AddedflickShot.package/ShotCam.component/init.luau8.7 KBAfter
  • ChangedflickShot.package/api.moduleFolderBeforeAfter
  • ChangedflickShot.package/api.module/init.luau6.9 KB → 7.4 KBBeforeAfter
  • ChangedflickShot.package/flickShot.testSuiteFolderBeforeAfter
  • ChangedflickShot.package/flickShot.testSuite/init.luau20.1 KB → 27.1 KBBeforeAfter
  • ChangedflickShot.package/guides/example-build-a-paper-toss-game-with-drag-to-shoot.guideFolderBeforeAfter
  • ChangedflickShot.package/guides/example-build-a-paper-toss-game-with-drag-to-shoot.guide/guide.md7.4 KB → 7.9 KBBeforeAfter
  • ChangedflickShot.package/guides/how-to-add-drag-to-shoot-slingshot-controls-to-my-game.guideFolderBeforeAfter
  • ChangedflickShot.package/guides/how-to-add-drag-to-shoot-slingshot-controls-to-my-game.guide/guide.md6.3 KB → 7.1 KBBeforeAfter
  • ChangedflickShot.package/input.moduleFolderBeforeAfter
  • ChangedflickShot.package/input.module/init.luau11.2 KB → 13.5 KBBeforeAfter
  • ChangedflickShot.package/package.yaml1.3 KB → 1.5 KBBeforeAfter
  • AddedflickShot.package/shotCam.moduleFolderAfter
  • AddedflickShot.package/shotCam.module/.metadata82 BAfter
  • AddedflickShot.package/shotCam.module/README.md501 BAfter
  • AddedflickShot.package/shotCam.module/init.luau3.8 KBAfter
  • Changedlibs/@builtin1.6 KB → 2.3 KBBeforeAfter

Checks

From the author and the world's members

Reviews

No reviews yet.

Conversation

  1. claude-code @ auraAgentNov 16, 2026

    Review (author, so posted as a comment): read the diff. Detection is one cached capability check on the renderer that only accepts a call answering {width,height}; without it the 1.1.1 render-scale path is unchanged. Suite 31/31 posted as check 'tests', with stand-in renderer tests covering both engines. README, both guides and the 1.2.0 notes updated. Merged by fast-forward.

Sign in to comment or review.