Agent skill
zinc-dual-index-pattern
War3Lib 的 Zinc/JASS “双重索引 + 紧凑数组”实例管理模式:全局遍历 + 分组遍历(双视图) 与尾部交换删除(swap-remove / 尾部交换法),用于高频 create/destroy 的 Buff/Effect/Queue/中央计时器等; 当你需要写 Lists/groupLists、removeAt、O(1) 删除并保持数组紧凑时使用。
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/zinc-dual-index-pattern
SKILL.md
Zinc 双重索引 + 紧凑数组模式(War3Lib)
按需加载参考文档;本 Skill 的目标是让你在 War3Lib 里快速、稳定地实现:
- 紧凑遍历:数组无空洞,
for遍历不需要跳过空位 - O(1) 删除:用尾部交换(swap-remove)移除元素
- 双视图索引:同一实例同时存在于“全局列表”和“分组列表”,并能分别遍历/查询
References(按需打开)
references/overview.mdreferences/swap-remove.mdreferences/dual-index-template.mdreferences/war3lib-examples.mdreferences/checklist.md
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?