# Repository Guidelines

## Project Structure & Module Organization
- Core addon logic lives in `HeadCount.lua` and splits responsibility via clear modules such as `RaidTracker.lua`, `Player.lua`, and `Loot.lua`.
- `libs/` vendors Ace2/other dependencies; keep third-party bundles untouched unless updating to a newer release.
- `locale/` houses translation tables that mirror the strings used by `HeadCountOptions.lua` and other UI helpers.
- XML layout lives in `HeadCountFrames.xml`, while `HeadCountFrames.lua` wires widgets to events—keep UI tweaks there.

## Build, Test, and Development Commands
- There is no automated build pipeline: package for distribution by compressing the addon folder (e.g., `Compress-Archive -Path * -DestinationPath HeadCount.zip` on Windows) and drop the ZIP into `%APPDATA%\World of Warcraft\Interface\AddOns`.
- Reload the game UI (`/reload`) after replacing files to exercise changes immediately.
- Use in-game console commands exposed by `HeadCountOptions.lua` for quick configuration checks.

## Coding Style & Naming Conventions
- Lua code follows the existing style: tabs for indentation, two-space alignment inside tables, and comment blocks prefixed with `--` or `--[[ ... ]]`.
- Keep global identifiers CamelCase (e.g., `HeadCount`, `RaidTracker`), use `lowerCamelCase` for instance methods, and prefix helper modules with descriptive nouns.
- Favor descriptive local variables, document side effects briefly above complex logic, and keep function bodies <80 columns when possible.

## Testing Guidelines
- No automated testing framework is defined—validate work by loading the addon in the target WoW client, triggering the relevant event (raid join/leave), and checking the log/UI panels.
- Manually verify localization strings by switching locale files or toggling the language option inside the addon menu.

## Commit & Pull Request Guidelines
- There is no recorded git history in this repository, so adopt a conventional style: short imperative verbs (`Add`, `Update`, `Fix`) followed by a concise subject and optional ticket reference.
- PR descriptions should explain the problem, summary of changes, and verification steps; include screenshots if UI changes are involved and link any related issues or requests.

## Localization & Packaging Tips
- Keep `locale/` synchronized with new or renamed strings—each locale file mirrors the English table from `locale/enUS.lua`.
- When bundling releases, include `.toc`, `.xml`, and `.lua` files plus any updated `libs/` entries; avoid copying the `.git` folder into release packages.
