@taptap/maker 0.0.41-beta.1 → 0.0.41-beta.3

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.
@@ -0,0 +1,73 @@
1
+ # LuaTween UI Integration
2
+
3
+ Use for a UI motion selection copied from the Maker console, or a request to add LuaTween
4
+ effects to an existing game. A selection authorizes local integration and requested testing,
5
+ not asset generation, publication, remote build, or replacement of the game's entry point.
6
+
7
+ ## Read the selected reference
8
+
9
+ - Resolve the user's current game and target widget first. The console's demo resource label
10
+ is not a game directory. If the target is genuinely ambiguous, ask which UI should receive
11
+ the effect; do not ask the user to choose a library or manually install it.
12
+ - Read the copied selection: family, scene/clip or skin/effect ID, and intended target.
13
+ Apply only the chosen effect to existing UI unless the user requests the complete example.
14
+ - Read the supplied `/ui-motion/runtime-reference` JSON (or downloaded reference package).
15
+ `files` contains `{path, content}`; these are delivery paths, not already-installed files.
16
+ Read `docs/LuaTween-integration.md`, `docs/luatween/README.md`, and the relevant sections
17
+ of `docs/luatween/LuaTween.md`. `library` identifies the exact source and SHA-256.
18
+ - For motion-lab selections read `scripts/MotionLabRecipes.lua` and the selected entry in
19
+ `assets/ui/motion-lab-v1/catalog.json`. For NanoVG scenes read
20
+ `assets/ui/nanovg-showcase-v1/showcase.json` and the selected `motion/*.json`. For image UI
21
+ read the selected `/ui-motion/original-reference?id=...`, UI.json,
22
+ `scripts/ImageMotionRecipes.lua` and the matching `S01–S05RedesignDemo.lua`.
23
+ In a downloaded package, use `ui-motion-native/catalog.json` and its matching files
24
+ instead of fetching the original computer's image UI reference URL.
25
+ - If a loopback link is stale, use the active distribution's `console status/open --no-open
26
+ --json` to find its current origin, then verify the library identity before continuing.
27
+ An AI running on another computer cannot use the original computer's loopback URL: use
28
+ the downloaded reference JSON instead. Do not silently switch to a different library.
29
+
30
+ ## Place only what the game needs
31
+
32
+ 1. Before writing, search the whole game for LuaTween source, require paths (including
33
+ aliases/wrappers), its update owner, and existing motion/event bindings on the target
34
+ widget. A missing `scripts/LuaTween.lua` alone does not mean the library is absent.
35
+ The bundled file adds usage comments only; `library.upstreamSha256` identifies the
36
+ original without those comments. A comment-only hash difference is not incompatibility.
37
+ Reuse an identical or verified compatible original module at its existing path, with
38
+ its existing update owner and bindings. For partial integration, add only missing pieces;
39
+ repeating the same request must not duplicate the library, scheduler or event binding.
40
+ If the module is custom or incompatible, explain the conflict and confirm how to proceed
41
+ before replacing shared code; never overwrite it silently or add a second scheduler.
42
+ 2. If absent, copy the exact `files` entry `scripts/LuaTween.lua` into the game's `scripts/`
43
+ directory, or follow its established Lua module layout. Verify the supplied SHA-256.
44
+ Default usage is `local LuaTween = require('LuaTween')`. Do not alter the original library.
45
+ 3. Keep the selected effect in the game's existing UI module (or its normal component
46
+ directory). Reuse the reference's timing, easing and property/path sequence with real
47
+ `To`, `Value`, `Path` or `Sequence` calls. Adapt bindings to the target widget; do not
48
+ reimplement interpolation or tween only a clock while manually interpolating properties.
49
+ 4. Import only needed recipe/adapter dependencies. Do not copy every demo, skin, native
50
+ host, browser renderer or Fengari into the game. If the user only wants motion, retain
51
+ the game's visuals. If they want the example UI too, preserve its editable layers and
52
+ import only the chosen design's PNG/fonts/UI.json, retaining font licenses.
53
+ 5. Media entries provide `path`, stable `url` and `sha256`; download only required files
54
+ and verify them before use. Treat supplied paths as project-relative and check containment
55
+ and existing files before extraction. Never bulk-overwrite a project with the reference.
56
+
57
+ ## Connect and verify in the game
58
+
59
+ - Attach the trigger to the actual button, panel or scene. Ordinary playback must use the
60
+ project's single `LuaTween.Update(dt)` owner. If absent, add one at the appropriate host
61
+ update hook; never add an Update subscription per animated component.
62
+ - Preserve base transforms and the target's input behavior. Handle repeated triggers,
63
+ pause/resume and re-entry. On close/destroy, kill only this component's owned handles;
64
+ never use global `KillAll`/`Clear`. Seeking for inspection must not trigger game rewards,
65
+ network calls or other business completion callbacks.
66
+ - Test through the project's normal local preview/validation workflow. Actually trigger
67
+ the target control, trigger repeatedly, close while moving, reopen and verify the effect
68
+ again. Check that unrelated animations still run and the existing UI remains usable.
69
+ Network games retain their network preview requirements; do not bypass them.
70
+ - A passing unit test, loaded window or screenshot alone is not interaction acceptance.
71
+ Report actual observations and any unverified visual/input paths honestly.
72
+ - Tell the user which UI now has the effect, how to trigger it, where the library and
73
+ integration code live, and what was verified. Do not require them to read the library.