Communitygithub.com

evalix098/tiktoklive

游戏动画资源深度指南:运动循环、动作关键帧、特效序列和动画精灵表,基于视频优先的流水线。

tiktoklive 是什么?

该技能提供了一个全面的指南,用于在应用构建器沙箱中生成游戏动画资源,涵盖运动循环、动作关键帧、特效序列和精灵表。其核心理念是“视频优先”:利用视频生成模型(而非图像模型)来理解连续运动,从而自动获得腿部交替、弧线连续性、布料和火焰动态等效果,然后从生成的视频中提取高质量帧。技能主要依赖于两个专用工具链:`video2dsprite`(基于视频生成精灵)和 `generate2dsprite`(直接生成精灵表),两者都需要使用固定的品红色背景(`#FF00FF`)以实现色度抠像。技能提供了详细的流水线步骤(基本帧→动画→提取→选择→打包)和一套运动法则(循环性、连续性、物理感、能量匹配),并通过“翻转测试”来确保最终帧序列的运动连贯性和循环闭合。对于一般游戏资产创建任务,此技能是 `game-asset-core` 的补充。

兼容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/evalix098/tiktoklive/tree/HEAD/.grok/skills/game-animation-frames

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

动画帧 — 视频优先

图像生成器绘制姿态;视频生成器理解运动—— 腿部交替、弧线连续性、布料和火焰动态自动产生,因为视频必须让它们动起来。 所以不要要求图像模型想象中间运动姿态:动画基础并提取真实帧。

应用构建器执行(先读)

此技能是原则(运动法则、循环质量控制、何时使用视频)。在应用构建器沙箱中,不要运行自由形式的 ffmpeg 提取或发明一个任意可抠图的 #hex 背景。

步骤执行此操作
生产精灵 / 固定网格generate2dsprite — 纯 #FF00FF 品红色表 + 色度脚本
通过视频生成更密集的运动video2dsprite — 基础图像基于 #FF00FF → imagine_image_to_video → 技能脚本 (ffmpeg + 色度)
可抠图背景始终使用 #FF00FF(使用任一流水线时必需)
本技能下面遵循循环/翻转测试/运动法则 — 在流水线运行后应用

打开 .grok/skills/video2dsprite/SKILL.md 或 .grok/skills/generate2dsprite/SKILL.md 并按照其工作流程进行生成和后处理。然后在将帧交付到游戏之前,应用此处的法则和翻转测试。

默认流水线(意图)

  1. 基础帧。 主题处于中立/起始姿态,包含完整风格描述词,侧面/游戏适当地视图,纯 #FF00FF 背景(应用构建器色度抠图)。适用 game-asset-core 默认设置。
  2. 动画。 基于基础帧调用 imagine_image_to_video:一个清晰的动作、原地进行、静态摄像机(“骑士原地行走,侧视,摄像机锁定”,6秒)。保持镜头简单——一个主题,一个动作。优先通过 video2dsprite 运行此步骤,以确保提取和色度的一致。
  3. 提取 + 清理。 使用 video2dsprite 脚本(而非临时 ffmpeg -i … fps=12 单独使用)。品红色泛洪填充/去污在那里处理;除非你完全离开品红色流水线,否则不要使用不同的纯色 #hex 重新抠图。
  4. 选择。 选择那些 (a) 捕捉动作不同阶段且 (b) 能形成循环的帧——序列结束必须能流畅过渡回开始。不要强制指定帧数:如果动作在8、10或12帧时表现最佳,就交付那么多帧(更多帧 = 引擎内更流畅)。对于一个循环,使用运动地标(脚部接触、翅膀极点、火焰峰值)选择一个完整周期。
  5. 打包。 按播放顺序交付帧(零填充名称)和/或按照 game-asset-core 规则(统一单元格,无分隔线)的精灵表—或由 video2dsprite / generate2dsprite 生成的透明条/网格。说明预期的fps。

仅当视频无法生成运动时(罕见情况:非常风格化的姿态、单个戏剧性关键帧),才退回到逐关键帧的 imagine_text_to_image(当使用精灵脚本进行后处理时仍使用 #FF00FF),然后自己规划阶段并遵守下面的法则。对于清晰的生产型多帧网格,优先使用 generate2dsprite。

运动法则(无论何种流水线,都要根据这些进行验证)

  • 循环是循环的;交替步态的一半周期是镜像的。
  • 连续性:肢体、道具、解剖结构、效果在连续路径上移动——相邻帧之间没有传送、消失或重复。
  • 静止帧中也能体现物理感:空中显示空气、预备压缩、跟随过冲;效果保持锚定在起源,除非请求移动它们。
  • 能量匹配要求:待命/微妙意味着帧之间几乎没有差异。

验证 — 翻转测试

严格按顺序查看最终帧并叙述运动;明确检查循环闭合(最后一帧→第一帧)。叙述中的任何迟疑都是失败的帧。视频流水线通常第一次尝试就能通过这个测试——这就是它作为默认流水线的理由。

Individual skills in this repo

This repo contains 17 individual skills — each has its own dedicated page.

evalix098/tiktoklive

Add user accounts and sign-in to this TanStack Start app. Use when the app needs authentication, sign-in, user accounts, protected routes, or per-user data. Triggers on "auth", "login", "log in", "sign in", "sign up", "account", "users", "authentication", "protected", "who is logged in", "current user", "per-user".

evalix098/tiktoklive

Build browser games and interactive/canvas/3D experiences in this TanStack Start + React app. Use for any game, simulation, or WebGL/Canvas experience — 2D or 3D, single-player. Covers the game loop & timing, 3D orientation/camera conventions, collision, performance, assets, audio, save, game feel, and per-genre playbooks. For WASD / vehicle / flight **input signs and inverted A/D**, open the **`controls`** skill — do not rely on this file or racing-kart alone. Triggers on "game", "minecraft", "fps", "platformer", "racing", "tetris", "snake", "shooter", "3d", "three.js", "canvas", "voxel", "physics".

evalix098/tiktoklive

Player-facing input signs for browser games: WASD, vehicles, flight, FPS mouse-look, and the #1 failure mode (inverted A/D). Mandatory control self-tests and a tiny test interface so you can verify A turns left before shipping. Load for ANY game with movement, steering, flying, driving, tanks, boats, mechs, drones, planes, karts, third-person follow cams — not only racing. Triggers on "controls", "WASD", "inverted", "steer", "flight", "airplane", "kart", "vehicle", "yaw", "roll", "pitch", "mouse look", "A/D".

evalix098/tiktoklive

Design and build polished, non-generic UI for this TanStack Start + React + Tailwind v4 + shadcn/Radix app. Use whenever you create or restyle any interface surface — pages, landing pages, dashboards, forms, modals, nav, and game overlays (start screens, HUD, menus). Covers design tokens, layout, typography, color, spacing, motion, and the anti-"AI-slop" rules that keep output from looking generic. Triggers on "design", "UI", "make it look good", "polish", "landing page", "theme", "style", "redesign", "ugly", "clean up".

evalix098/tiktoklive

Core discipline for ANY game-asset generation with Imagine tools: the engine-ready defaults users don't state, spec checklists, style anchoring, read-back verification, honest defect flagging. Use whenever generating any game art (sprites, sheets, animations, tiles, UI, FX) — then ALSO load the matching specialist skill: game-animation-frames for anything that moves, game-tilesets for tiles/terrain, game-character-consistency for recurring characters, game-ui-icons for UI and icons.

evalix098/tiktoklive

Deep guide for CHARACTER IDENTITY across images: turnarounds (front/side/ back), state and damage variants, palette swaps, equipment changes, and same-character-in-context sets. Use whenever generating character turnarounds, character sheets, variants of an existing sprite, or any same-subject multi-image set. Complements game-asset-core.

evalix098/tiktoklive

Deep guide for game TILE assets: seamless tileable textures, terrain transition tilesets, autotiles, and ground/platform tiles. Use whenever generating tileable textures, tilesets, terrain transitions, or seamless patterns. Complements game-asset-core.

evalix098/tiktoklive

Deep guide for game UI assets: buttons with interaction states, panels, bars, wordmark logos, and icon sets. Use whenever generating game UI elements, HUD assets, inventory icons, icon sets, buttons, or title logos. Complements game-asset-core.

evalix098/tiktoklive

Generate production-oriented 2D game maps with `imagine_text_to_image`: RPG/top-down maps, side-scroller parallax stages, tilemaps, layered raster maps, prop packs, collision zones, and walkable areas. Use when building browser games that need real map art (not pure code-drawn tiles), layered props, or map collision metadata. Triggers on "map", "level", "stage", "tilemap", "overworld", "dungeon", "side scroller background", "prop pack", "2D map".

evalix098/tiktoklive

Generate and postprocess 2D game sprites and animation sheets: pixel-art characters, NPCs, creatures, spells, projectiles, impacts, props, summons, and transparent PNG/GIF exports. Use when building browser games that need real sprite sheets (not code-drawn placeholders), matching a map art style, or producing magenta-background sheets for chroma-key cleanup. Triggers on "sprite", "sprite sheet", "animation sheet", "pixel art character", "walk cycle", "attack animation", "projectile sprite", "2D game asset".

evalix098/tiktoklive

How to use the Imagine tools in Grok Build: imagine_text_to_image, imagine_image_to_image, imagine_reference_to_image, imagine_text_to_video, imagine_image_to_video, imagine_reference_to_video, and render_file for chat previews. When to build a visual with code instead of generating it, prompt-craft, reference-first handling of real people, factual grounding, and asset-consistency. Load this whenever generating or editing an image or video is on the table. Tool-usage-driven, not triggered by a user merely mentioning images.

evalix098/tiktoklive

Peer-to-peer realtime multiplayer over WebRTC data channels: every user of the deployed app connects directly to every other user (full mesh), the server only brokers the handshake at /api/rtc. Lowest possible latency, zero per-message server cost. Use for 2-8 player co-op/casual realtime: shared cursors, drawing, party games, casual action. Triggers: p2p, peer to peer, webrtc, low latency multiplayer, direct connection.

evalix098/tiktoklive

Use Neon Postgres (the database) in this TanStack Start app. Use when the app needs to store or query data, persist state, or keep per-user data. Triggers on "database", "Postgres", "Neon", "save data", "store data", "persist", "tables", "SQL", "query", "migrations".

evalix098/tiktoklive

Share-link previews and app identity for apps on *.grok.me: the injector-owned og:image card, the SVG favicon, and PWA icons for installable apps. Use when scaffolding, renaming, or restyling the app — and for share / unfurl / OG / Twitter card questions. A custom 1200×630 card from the app's own art is the default — games of every kind (DOM board/word games included), whimsical apps, creative tools, and brand-forward pages; only plain utilities keep the placeholder. Always run the brand-asset pass as a `task` subagent and never wait for it. Triggers on "share", "rename", "app name", "OG", "Open Graph", "twitter card", "unfurl", "og:image", "og:type", "x:game:image", "x-banner", "link preview", "social card", "thumbnail", "preview image", "favicon", "app icon", "PWA", "manifest", "installable", "home screen", "SEO", "meta description".

evalix098/tiktoklive

Official Three.js API and TSL (Three.js Shading Language) reference for LLM code generation. Load when writing or debugging three.js / WebGL / WebGPU / custom materials / shaders / GLTF / advanced three APIs beyond basic game loop/controls. Prefer building-games for game correctness (loop, WASD, camera, orientation); use this skill for full API/TSL depth. Triggers on "three.js", "threejs", "WebGPU", "TSL", "NodeMaterial", "shader", "GLTF", "MeshStandard", "OrbitControls", "WebGLRenderer".

evalix098/tiktoklive

Grok Build only. Turn a 2D character still into denser animation sprites via imagine_text_to_image base → imagine_image_to_video (6s/10s run-in-place) → ffmpeg frames → magenta chroma-key → dense sampled strips/grids/GIFs. Use when the user wants video-to-sprite, smoother run/walk cycles, or denser intermediate poses. Prefer generate2dsprite for crisp production pixel sheets. Triggers on "video to sprite", "imagine_image_to_video sprite", "dense walk cycle", "smooth run animation from video".

evalix098/tiktoklive

Call the xAI API (Grok) from this app's server code using the injected XAI_API_KEY: chat/LLM features, image and video generation (Imagine), and voice (text-to-speech). Use when the app needs any "AI" / "assistant" / "chatbot" / "Grok" functionality, runtime image/video generation, or speech. Triggers on "AI", "LLM", "chatbot", "assistant", "Grok", "xAI", "generate text", "summarize", "generate image", "AI video", "voice", "text to speech", "TTS", "OpenAI" (use xAI instead).

相关技能