Index of every page on this site: llms.txt
All skills
oahc09 avatar

/cocosair

@ed38648
by oahc09oahc09/cocosairjs3 stars
2
Run it yourself

Route AIR tasks by subsystem or visual symptom; choose direct dependencies and check capabilities.

  • 10 files
  • 72.8 KB
  • MIT
  • Updated last month
  • GitHub
Use this Skill: https://skilld.dev/gh/oahc09/cocosairjs/cocosair

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesvisual-feedback.md

≈2k tokens on demand. Your agent reads this file only when SKILL.md points to it.

Visible scenes and silent rendering failures

Read this before implementing an AIR visual creation or recreation task, or when pixels look wrong without an exception. For math-only, prose-only or unrelated tasks, skip it. Use the relevant row below to choose one owner and its direct dependencies; do not load the whole suite. These are diagnostic hypotheses, not diagnoses inferred from a screenshot alone.

Start from the visible symptom

Symptom, including search terms First discriminating check Owner reference
黑块、发光体黑色; black additive object Compare one object with a known unlit color and blending off; if it appears, inspect numeric blend states, texture macros and the live material instance Runtime states / empty UBO, material mistakes
看不见、空白、缺对象; invisible or missing object Check active hierarchy, nonzero world scale, camera layer mask and clipping before rewriting the shader; for a billboard check width/height and its texture Layers, 2D owner
相机在楼群里、主体出框; camera inside scene, cropped subject Compare camera/target with whole-subject bounds, FOV and viewport aspect; fit the subject first Camera framing
全城发黑、雾吞掉主体; fog hides scene, dark frame Temporarily disable fog, then compare material/lighting/exposure independently; a changed frame narrows the cause but does not select a final density Lighting units, globals
雨线缩成点、模式切换后塌缩; streak collapses Inspect generated endpoints, length/scale and active mode branch before changing blend state; compare representative times Node operations
窗格闪烁、细节糊成噪点; repeated detail shimmers Compare actual viewport/DPR and near/far views; vary repetition scale or contrast to identify screen-space aliasing Camera projection

Before hand-writing effect JSON, read the material runtime-state and empty-block traps linked above. Before configuring scene lighting, read the globals identity clarification. This small task-specific input should arrive before a failure, without requiring the agent to guess its error keyword.

Minimal visual feedback loop

  1. Establish the requested reference or visual goal and a few observable criteria: subject framing, light/dark hierarchy, readable detail, and the intended motion or interaction. Start with a representative scene slice; do not multiply expensive effects before it is visible.
  2. Run the current candidate and capture its actual browser/compositor output at the intended viewport after assets are ready. Use available authorized browser tooling; a console without errors, successful build or GPU readback alone is not a view of the final picture. This skill ships no capture service or browser installation.
  3. Inspect the image against the reference or stated goal. Name a concrete mismatch and a falsifiable cause, such as clipped skyline, crushed shadows or subpixel windows. Change the smallest relevant parameter group, capture again under the same conditions, and compare. Do not change camera, fog, exposure and geometry together when diagnosing one failure.
  4. For motion, inspect separated representative times or the relevant interaction state; a single still cannot establish animation. During ordinary viewing retain native pacing. For controlled assertions pause and use the project's single step clock, then restore native pacing.
  5. Stop when the requested criteria are met and the affected behavior is checked. If further iterations stop improving the result or tooling/budget blocks inspection, report the concrete remaining mismatch and verification limit. Preserve the final capture and identify its candidate and viewport; do not label an unviewed result visually verified.

Fog density, orbit distance, rain length and window spacing depend on scene scale and projected size. Tune them from observations, not copied magic numbers. Separate API correctness, application logic, composition and measured rendering limits when reporting causes. A successful skill lookup establishes none of these by itself.

When a new trap is reproduced, distinguish an API contract from a scene-specific bug or artistic choice. Return confirmed reusable guidance to its existing owner with source/version evidence and a symptom term; keep unverified explanations as hypotheses. Only update persistent agent memory when the user explicitly requests it. No claim about skill coverage or visual success rate follows from this workflow without a separate evaluation.

Task recipes

For a task spanning materials, geometry, input and rendering, start with the task cookbook, then read only the references needed for the selected route. It supplies composition paths, not another API contract or a requirement to load every owner.

A flat full-screen color can be a framing failure

If a known valid shader fills the screen and the subject's silhouette disappears, compare an earlier wide view before treating it as a material defect. For an orthographic camera, moving farther away does not change projected size. Automatic fitting needs mesh/model bounds; hand-authored static createMesh geometry does not calculate them by default. Follow the bounds prerequisite and repair, then capture the same viewport and confirm the subject and margins have returned. Keep the failed screenshot as evidence of why the first repair was insufficient.

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at ed38648. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated last month
layer
router
All 1 allowed tools
Read Bash
Other metadata
compatibility
Cocos AIR source checkout or installed cocosair.js package. Browser rendering requires WebGL 2; source tooling requires Node.js >=18. Use the host-provided tools and user-authorized workspace.
when_to_use
[
  "which skill owns this AIR task",
  "choose only the dependencies needed for this step",
  "adapt Creator knowledge to code-first AIR",
  "distinguish source exports from proven browser capabilities"
]
owns
[
  "skill-routing",
  "primary-owner",
  "direct-dependencies",
  "code-first",
  "capability-layers"
]
not_for
[
  "startup errors -> cocosair-application",
  "material property failures -> cocosair-materials-effects"
]
metadata
{
  "author": "oahc09@gmail.com",
  "version": "1.0.0",
  "last-updated": "2026-10-13",
  "description_zh": "为 Cocos AIR 任务选择主技能和直接依赖,并遵循原生 API、启动时序与能力证据分层。用于开始 AIR 开发、定位能力归属或选择技能。"
}

README badge

README badge for oahc09/cocosairjs/cocosair