@citedy/game-sounds 1.0.0

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.
Files changed (30) hide show
  1. package/.claude-plugin/plugin.json +8 -0
  2. package/LICENSE +21 -0
  3. package/README.md +95 -0
  4. package/config.json +11 -0
  5. package/hooks/hooks.json +24 -0
  6. package/package.json +30 -0
  7. package/scripts/play-sound.sh +86 -0
  8. package/skills/game-sounds/SKILL.md +40 -0
  9. package/sounds/warcraft/error/never-mind.mp3 +0 -0
  10. package/sounds/warcraft/error/peasant-angry.mp3 +0 -0
  11. package/sounds/warcraft/error/stop-poking-me.mp3 +0 -0
  12. package/sounds/warcraft/error/that-was-mistake.mp3 +0 -0
  13. package/sounds/warcraft/permission/peasant-what.mp3 +0 -0
  14. package/sounds/warcraft/permission/waiting-on-you.mp3 +0 -0
  15. package/sounds/warcraft/permission/what-now.mp3 +0 -0
  16. package/sounds/warcraft/permission/what.mp3 +0 -0
  17. package/sounds/warcraft/session-start/peasant-ready.mp3 +0 -0
  18. package/sounds/warcraft/session-start/ready-to-work.mp3 +0 -0
  19. package/sounds/warcraft/session-start/something-need-doing.mp3 +0 -0
  20. package/sounds/warcraft/session-start/what-need.mp3 +0 -0
  21. package/sounds/warcraft/task-acknowledge/okie-dokie.mp3 +0 -0
  22. package/sounds/warcraft/task-acknowledge/peasant-right.mp3 +0 -0
  23. package/sounds/warcraft/task-acknowledge/peasant-yes.mp3 +0 -0
  24. package/sounds/warcraft/task-acknowledge/right-o.mp3 +0 -0
  25. package/sounds/warcraft/task-acknowledge/work-work.mp3 +0 -0
  26. package/sounds/warcraft/task-acknowledge/zug-zug.mp3 +0 -0
  27. package/sounds/warcraft/task-complete/jobs-done.mp3 +0 -0
  28. package/sounds/warcraft/task-complete/objective-completed.mp3 +0 -0
  29. package/sounds/warcraft/task-complete/tools-ready.mp3 +0 -0
  30. package/sounds/warcraft/task-complete/work-complete.mp3 +0 -0
@@ -0,0 +1,8 @@
1
+ {
2
+ "name": "@citedy/game-sounds",
3
+ "version": "1.0.0",
4
+ "description": "Game sound effects for Claude Code — Warcraft, StarCraft, Diablo & more. Work work! 🔨",
5
+ "author": "Citedy <hello@citedy.com>",
6
+ "homepage": "https://www.citedy.com",
7
+ "repository": "https://github.com/citedy/game-sounds"
8
+ }
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Citedy
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,95 @@
1
+ # @citedy/game-sounds
2
+
3
+ Game sound effects for [Claude Code](https://docs.anthropic.com/en/docs/claude-code) — hear Warcraft Peon voice lines as you code!
4
+
5
+ **"Work work!"** when you submit a prompt. **"Job's done!"** when the task completes. **"Stop poking me!"** on errors.
6
+
7
+ ## Install
8
+
9
+ ```bash
10
+ # npm
11
+ npm install -g @citedy/game-sounds
12
+ claude --plugin-dir $(npm root -g)/@citedy/game-sounds
13
+
14
+ # Or clone locally
15
+ git clone https://github.com/citedy/game-sounds.git
16
+ claude --plugin-dir ./game-sounds
17
+ ```
18
+
19
+ ## Sound Packs
20
+
21
+ ### Warcraft (default)
22
+
23
+ | Event | Sound Category | Example Phrases |
24
+ |-------|---------------|-----------------|
25
+ | Session Start | `session-start` | "Ready to work", "Something need doing?" |
26
+ | Prompt Submit | `task-acknowledge` | "Work work", "Zug zug", "Okie dokie" |
27
+ | Task Complete | `task-complete` | "Job's done!", "Work complete" |
28
+ | Error | `error` | "Stop poking me!", "That was a mistake" |
29
+ | Notification | `permission` | "What?", "What now?" |
30
+
31
+ More packs coming soon: StarCraft, Diablo, Zelda, Mario...
32
+
33
+ ## Commands
34
+
35
+ Use `/game-sounds` in Claude Code to manage settings:
36
+
37
+ ```
38
+ /game-sounds # Show current config
39
+ /game-sounds volume 0.3 # Set volume (0.0-1.0)
40
+ /game-sounds pack warcraft # Switch sound pack
41
+ /game-sounds list # List available packs
42
+ /game-sounds toggle error # Enable/disable event category
43
+ /game-sounds test # Play a test sound
44
+ ```
45
+
46
+ ## Config
47
+
48
+ Edit `config.json` to customize:
49
+
50
+ ```json
51
+ {
52
+ "volume": 0.5,
53
+ "active_pack": "warcraft",
54
+ "enabled_events": {
55
+ "session-start": true,
56
+ "task-acknowledge": true,
57
+ "task-complete": true,
58
+ "error": true,
59
+ "permission": true
60
+ }
61
+ }
62
+ ```
63
+
64
+ ## Platform Support
65
+
66
+ - **macOS**: `afplay` (built-in)
67
+ - **Linux**: `paplay` (PulseAudio), `pw-play` (PipeWire), or `ffplay` (FFmpeg)
68
+
69
+ ## Adding Custom Sound Packs
70
+
71
+ Create a new directory under `sounds/` with the pack name:
72
+
73
+ ```
74
+ sounds/
75
+ └── my-pack/
76
+ ├── session-start/
77
+ ├── task-complete/
78
+ ├── task-acknowledge/
79
+ ├── error/
80
+ └── permission/
81
+ ```
82
+
83
+ Add `.mp3`, `.wav`, or `.ogg` files to each category folder. Then switch:
84
+
85
+ ```
86
+ /game-sounds pack my-pack
87
+ ```
88
+
89
+ ## Credits
90
+
91
+ Sound files sourced from [PeonPing](https://github.com/PeonPing/peon-ping). Warcraft is a trademark of Blizzard Entertainment.
92
+
93
+ ---
94
+
95
+ Made with ⚔️ by [Citedy](https://www.citedy.com) — AI platform for SEO content automation.
package/config.json ADDED
@@ -0,0 +1,11 @@
1
+ {
2
+ "volume": 0.5,
3
+ "active_pack": "warcraft",
4
+ "enabled_events": {
5
+ "session-start": true,
6
+ "task-acknowledge": true,
7
+ "task-complete": true,
8
+ "error": true,
9
+ "permission": true
10
+ }
11
+ }
@@ -0,0 +1,24 @@
1
+ {
2
+ "hooks": [
3
+ {
4
+ "event": "SessionStart",
5
+ "command": "bash $CLAUDE_PLUGIN_ROOT/scripts/play-sound.sh session-start",
6
+ "timeout": 5000
7
+ },
8
+ {
9
+ "event": "UserPromptSubmit",
10
+ "command": "bash $CLAUDE_PLUGIN_ROOT/scripts/play-sound.sh task-acknowledge",
11
+ "timeout": 5000
12
+ },
13
+ {
14
+ "event": "Stop",
15
+ "command": "bash $CLAUDE_PLUGIN_ROOT/scripts/play-sound.sh task-complete",
16
+ "timeout": 5000
17
+ },
18
+ {
19
+ "event": "Notification",
20
+ "command": "bash $CLAUDE_PLUGIN_ROOT/scripts/play-sound.sh permission",
21
+ "timeout": 5000
22
+ }
23
+ ]
24
+ }
package/package.json ADDED
@@ -0,0 +1,30 @@
1
+ {
2
+ "name": "@citedy/game-sounds",
3
+ "version": "1.0.0",
4
+ "description": "Game sound effects for Claude Code — Warcraft, StarCraft & more. Work work! 🔨",
5
+ "keywords": [
6
+ "claude-code",
7
+ "claude-code-plugin",
8
+ "game-sounds",
9
+ "warcraft",
10
+ "sound-effects",
11
+ "developer-experience"
12
+ ],
13
+ "author": "Citedy <hello@citedy.com>",
14
+ "license": "MIT",
15
+ "homepage": "https://www.citedy.com",
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "https://github.com/citedy/game-sounds"
19
+ },
20
+ "files": [
21
+ ".claude-plugin/",
22
+ "hooks/",
23
+ "scripts/",
24
+ "skills/",
25
+ "sounds/",
26
+ "config.json",
27
+ "README.md",
28
+ "LICENSE"
29
+ ]
30
+ }
@@ -0,0 +1,86 @@
1
+ #!/usr/bin/env bash
2
+ # play-sound.sh — Play a random game sound for a Claude Code event
3
+ # Usage: play-sound.sh <category>
4
+ # Categories: session-start, task-acknowledge, task-complete, error, permission
5
+
6
+ set -euo pipefail
7
+
8
+ CATEGORY="${1:-}"
9
+ if [[ -z "$CATEGORY" ]]; then
10
+ exit 0
11
+ fi
12
+
13
+ # Resolve plugin root
14
+ PLUGIN_ROOT="${CLAUDE_PLUGIN_ROOT:-$(cd "$(dirname "$0")/.." && pwd)}"
15
+ CONFIG_FILE="$PLUGIN_ROOT/config.json"
16
+
17
+ # Read config
18
+ if [[ ! -f "$CONFIG_FILE" ]]; then
19
+ exit 0
20
+ fi
21
+
22
+ # Parse config with built-in tools (no jq dependency)
23
+ VOLUME=$(python3 -c "import json; print(json.load(open('$CONFIG_FILE'))['volume'])" 2>/dev/null || echo "0.5")
24
+ ACTIVE_PACK=$(python3 -c "import json; print(json.load(open('$CONFIG_FILE'))['active_pack'])" 2>/dev/null || echo "warcraft")
25
+ EVENT_ENABLED=$(python3 -c "import json; c=json.load(open('$CONFIG_FILE')); print(c['enabled_events'].get('$CATEGORY', True))" 2>/dev/null || echo "True")
26
+
27
+ if [[ "$EVENT_ENABLED" == "False" ]]; then
28
+ exit 0
29
+ fi
30
+
31
+ # Find sound files
32
+ SOUND_DIR="$PLUGIN_ROOT/sounds/$ACTIVE_PACK/$CATEGORY"
33
+ if [[ ! -d "$SOUND_DIR" ]]; then
34
+ exit 0
35
+ fi
36
+
37
+ # Collect all mp3/wav/ogg files
38
+ SOUNDS=()
39
+ while IFS= read -r -d '' f; do
40
+ SOUNDS+=("$f")
41
+ done < <(find "$SOUND_DIR" -type f \( -name "*.mp3" -o -name "*.wav" -o -name "*.ogg" \) -print0 2>/dev/null)
42
+ if [[ ${#SOUNDS[@]} -eq 0 ]]; then
43
+ exit 0
44
+ fi
45
+
46
+ # No-repeat: avoid playing the same sound twice in a row
47
+ LAST_PLAYED_FILE="/tmp/game-sounds-last-$CATEGORY"
48
+ LAST_PLAYED=""
49
+ if [[ -f "$LAST_PLAYED_FILE" ]]; then
50
+ LAST_PLAYED=$(cat "$LAST_PLAYED_FILE" 2>/dev/null || true)
51
+ fi
52
+
53
+ # Pick a random sound, avoiding last played if possible
54
+ if [[ ${#SOUNDS[@]} -gt 1 ]]; then
55
+ ATTEMPTS=0
56
+ while true; do
57
+ IDX=$((RANDOM % ${#SOUNDS[@]}))
58
+ SOUND="${SOUNDS[$IDX]}"
59
+ if [[ "$SOUND" != "$LAST_PLAYED" ]] || [[ $ATTEMPTS -ge 5 ]]; then
60
+ break
61
+ fi
62
+ ATTEMPTS=$((ATTEMPTS + 1))
63
+ done
64
+ else
65
+ SOUND="${SOUNDS[0]}"
66
+ fi
67
+
68
+ # Save last played
69
+ echo "$SOUND" > "$LAST_PLAYED_FILE"
70
+
71
+ # Play sound (background, non-blocking)
72
+ if command -v afplay &>/dev/null; then
73
+ # macOS
74
+ afplay -v "$VOLUME" "$SOUND" &
75
+ elif command -v paplay &>/dev/null; then
76
+ # Linux (PulseAudio) — paplay doesn't support volume flag easily, use pw-play
77
+ paplay "$SOUND" &
78
+ elif command -v pw-play &>/dev/null; then
79
+ # Linux (PipeWire)
80
+ pw-play --volume "$VOLUME" "$SOUND" &
81
+ elif command -v ffplay &>/dev/null; then
82
+ # Fallback: ffplay
83
+ ffplay -nodisp -autoexit -volume "$(python3 -c "print(int($VOLUME * 100))")" "$SOUND" &>/dev/null &
84
+ fi
85
+
86
+ exit 0
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: game-sounds
3
+ description: Manage game sound effects — change volume, switch sound packs, list available sounds
4
+ user_invocable: true
5
+ ---
6
+
7
+ # /game-sounds — Game Sound Manager
8
+
9
+ Manage your game sound effects for Claude Code.
10
+
11
+ ## Usage
12
+
13
+ When the user invokes `/game-sounds`, parse their arguments and execute the appropriate action:
14
+
15
+ ### Commands
16
+
17
+ - `/game-sounds` — Show current config (active pack, volume, enabled events)
18
+ - `/game-sounds volume <0.0-1.0>` — Set volume level
19
+ - `/game-sounds pack <name>` — Switch active sound pack (e.g., warcraft, starcraft)
20
+ - `/game-sounds list` — List available sound packs and their sounds
21
+ - `/game-sounds toggle <event>` — Enable/disable a specific event category
22
+ - `/game-sounds test [category]` — Play a test sound from the given category (default: session-start)
23
+
24
+ ## Implementation
25
+
26
+ Read and modify the config file at `$CLAUDE_PLUGIN_ROOT/config.json`.
27
+
28
+ For **volume**: Update the `volume` field (float 0.0 to 1.0).
29
+ For **pack**: Update `active_pack` field. Verify the pack directory exists in `$CLAUDE_PLUGIN_ROOT/sounds/`.
30
+ For **toggle**: Flip the boolean in `enabled_events.<event>`.
31
+ For **test**: Run `bash $CLAUDE_PLUGIN_ROOT/scripts/play-sound.sh <category>`.
32
+ For **list**: Scan `$CLAUDE_PLUGIN_ROOT/sounds/` directories and list packs with file counts.
33
+
34
+ Use the Bash tool to read/write config.json and the Read tool to display current settings.
35
+
36
+ ### Example responses
37
+
38
+ **Status**: "🎮 Game Sounds: Warcraft pack, volume 0.5, all events enabled"
39
+ **Volume change**: "🔊 Volume set to 0.3"
40
+ **Pack switch**: "⚔️ Switched to starcraft pack"