@umang-boss/claudemon 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 (203) hide show
  1. package/README.md +164 -0
  2. package/bin/claudemon.js +52 -0
  3. package/bunfig.toml +2 -0
  4. package/cli/doctor.ts +334 -0
  5. package/cli/index.ts +42 -0
  6. package/cli/install.ts +248 -0
  7. package/cli/shared.ts +102 -0
  8. package/cli/uninstall.ts +155 -0
  9. package/cli/update.ts +318 -0
  10. package/hooks/post-tool-use.sh +127 -0
  11. package/hooks/stop.sh +49 -0
  12. package/hooks/user-prompt-submit.sh +73 -0
  13. package/package.json +68 -0
  14. package/scripts/download-colorscripts.ts +311 -0
  15. package/skills/buddy/SKILL.md +47 -0
  16. package/sprites/colorscripts/small/1-bulbasaur.txt +11 -0
  17. package/sprites/colorscripts/small/10-caterpie.txt +9 -0
  18. package/sprites/colorscripts/small/100-voltorb.txt +8 -0
  19. package/sprites/colorscripts/small/101-electrode.txt +9 -0
  20. package/sprites/colorscripts/small/102-exeggcute.txt +10 -0
  21. package/sprites/colorscripts/small/103-exeggutor.txt +23 -0
  22. package/sprites/colorscripts/small/104-cubone.txt +11 -0
  23. package/sprites/colorscripts/small/105-marowak.txt +16 -0
  24. package/sprites/colorscripts/small/106-hitmonlee.txt +16 -0
  25. package/sprites/colorscripts/small/107-hitmonchan.txt +19 -0
  26. package/sprites/colorscripts/small/108-lickitung.txt +10 -0
  27. package/sprites/colorscripts/small/109-koffing.txt +14 -0
  28. package/sprites/colorscripts/small/11-metapod.txt +10 -0
  29. package/sprites/colorscripts/small/110-weezing.txt +23 -0
  30. package/sprites/colorscripts/small/111-rhyhorn.txt +11 -0
  31. package/sprites/colorscripts/small/112-rhydon.txt +20 -0
  32. package/sprites/colorscripts/small/113-chansey.txt +11 -0
  33. package/sprites/colorscripts/small/114-tangela.txt +10 -0
  34. package/sprites/colorscripts/small/115-kangaskhan.txt +18 -0
  35. package/sprites/colorscripts/small/116-horsea.txt +10 -0
  36. package/sprites/colorscripts/small/117-seadra.txt +11 -0
  37. package/sprites/colorscripts/small/118-goldeen.txt +11 -0
  38. package/sprites/colorscripts/small/119-seaking.txt +16 -0
  39. package/sprites/colorscripts/small/12-butterfree.txt +20 -0
  40. package/sprites/colorscripts/small/120-staryu.txt +10 -0
  41. package/sprites/colorscripts/small/121-starmie.txt +17 -0
  42. package/sprites/colorscripts/small/122-mr-mime.txt +18 -0
  43. package/sprites/colorscripts/small/123-scyther.txt +21 -0
  44. package/sprites/colorscripts/small/124-jynx.txt +18 -0
  45. package/sprites/colorscripts/small/125-electabuzz.txt +19 -0
  46. package/sprites/colorscripts/small/126-magmar.txt +19 -0
  47. package/sprites/colorscripts/small/127-pinsir.txt +19 -0
  48. package/sprites/colorscripts/small/128-tauros.txt +20 -0
  49. package/sprites/colorscripts/small/129-magikarp.txt +13 -0
  50. package/sprites/colorscripts/small/13-weedle.txt +10 -0
  51. package/sprites/colorscripts/small/130-gyarados.txt +21 -0
  52. package/sprites/colorscripts/small/131-lapras.txt +19 -0
  53. package/sprites/colorscripts/small/132-ditto.txt +8 -0
  54. package/sprites/colorscripts/small/133-eevee.txt +10 -0
  55. package/sprites/colorscripts/small/134-vaporeon.txt +16 -0
  56. package/sprites/colorscripts/small/135-jolteon.txt +17 -0
  57. package/sprites/colorscripts/small/136-flareon.txt +18 -0
  58. package/sprites/colorscripts/small/137-porygon.txt +10 -0
  59. package/sprites/colorscripts/small/138-omanyte.txt +10 -0
  60. package/sprites/colorscripts/small/139-omastar.txt +18 -0
  61. package/sprites/colorscripts/small/14-kakuna.txt +10 -0
  62. package/sprites/colorscripts/small/140-kabuto.txt +8 -0
  63. package/sprites/colorscripts/small/141-kabutops.txt +17 -0
  64. package/sprites/colorscripts/small/142-aerodactyl.txt +17 -0
  65. package/sprites/colorscripts/small/143-snorlax.txt +21 -0
  66. package/sprites/colorscripts/small/144-articuno.txt +24 -0
  67. package/sprites/colorscripts/small/145-zapdos.txt +20 -0
  68. package/sprites/colorscripts/small/146-moltres.txt +23 -0
  69. package/sprites/colorscripts/small/147-dratini.txt +10 -0
  70. package/sprites/colorscripts/small/148-dragonair.txt +12 -0
  71. package/sprites/colorscripts/small/149-dragonite.txt +21 -0
  72. package/sprites/colorscripts/small/15-beedrill.txt +13 -0
  73. package/sprites/colorscripts/small/150-mewtwo.txt +22 -0
  74. package/sprites/colorscripts/small/151-mew.txt +14 -0
  75. package/sprites/colorscripts/small/16-pidgey.txt +10 -0
  76. package/sprites/colorscripts/small/17-pidgeotto.txt +11 -0
  77. package/sprites/colorscripts/small/18-pidgeot.txt +18 -0
  78. package/sprites/colorscripts/small/19-rattata.txt +12 -0
  79. package/sprites/colorscripts/small/2-ivysaur.txt +11 -0
  80. package/sprites/colorscripts/small/20-raticate.txt +12 -0
  81. package/sprites/colorscripts/small/21-spearow.txt +9 -0
  82. package/sprites/colorscripts/small/22-fearow.txt +12 -0
  83. package/sprites/colorscripts/small/23-ekans.txt +12 -0
  84. package/sprites/colorscripts/small/24-arbok.txt +16 -0
  85. package/sprites/colorscripts/small/25-pikachu.txt +11 -0
  86. package/sprites/colorscripts/small/26-raichu.txt +19 -0
  87. package/sprites/colorscripts/small/27-sandshrew.txt +10 -0
  88. package/sprites/colorscripts/small/28-sandslash.txt +16 -0
  89. package/sprites/colorscripts/small/29-nidoran-f.txt +11 -0
  90. package/sprites/colorscripts/small/3-venusaur.txt +21 -0
  91. package/sprites/colorscripts/small/30-nidorina.txt +12 -0
  92. package/sprites/colorscripts/small/31-nidoqueen.txt +19 -0
  93. package/sprites/colorscripts/small/32-nidoran-m.txt +11 -0
  94. package/sprites/colorscripts/small/33-nidorino.txt +12 -0
  95. package/sprites/colorscripts/small/34-nidoking.txt +18 -0
  96. package/sprites/colorscripts/small/35-clefairy.txt +11 -0
  97. package/sprites/colorscripts/small/36-clefable.txt +17 -0
  98. package/sprites/colorscripts/small/37-vulpix.txt +11 -0
  99. package/sprites/colorscripts/small/38-ninetales.txt +18 -0
  100. package/sprites/colorscripts/small/39-jigglypuff.txt +11 -0
  101. package/sprites/colorscripts/small/4-charmander.txt +11 -0
  102. package/sprites/colorscripts/small/40-wigglytuff.txt +20 -0
  103. package/sprites/colorscripts/small/41-zubat.txt +11 -0
  104. package/sprites/colorscripts/small/42-golbat.txt +18 -0
  105. package/sprites/colorscripts/small/43-oddish.txt +11 -0
  106. package/sprites/colorscripts/small/44-gloom.txt +12 -0
  107. package/sprites/colorscripts/small/45-vileplume.txt +17 -0
  108. package/sprites/colorscripts/small/46-paras.txt +11 -0
  109. package/sprites/colorscripts/small/47-parasect.txt +12 -0
  110. package/sprites/colorscripts/small/48-venonat.txt +14 -0
  111. package/sprites/colorscripts/small/49-venomoth.txt +19 -0
  112. package/sprites/colorscripts/small/5-charmeleon.txt +13 -0
  113. package/sprites/colorscripts/small/50-diglett.txt +8 -0
  114. package/sprites/colorscripts/small/51-dugtrio.txt +18 -0
  115. package/sprites/colorscripts/small/52-meowth.txt +12 -0
  116. package/sprites/colorscripts/small/53-persian.txt +20 -0
  117. package/sprites/colorscripts/small/54-psyduck.txt +12 -0
  118. package/sprites/colorscripts/small/55-golduck.txt +17 -0
  119. package/sprites/colorscripts/small/56-mankey.txt +11 -0
  120. package/sprites/colorscripts/small/57-primeape.txt +13 -0
  121. package/sprites/colorscripts/small/58-growlithe.txt +12 -0
  122. package/sprites/colorscripts/small/59-arcanine.txt +20 -0
  123. package/sprites/colorscripts/small/6-charizard.txt +21 -0
  124. package/sprites/colorscripts/small/60-poliwag.txt +9 -0
  125. package/sprites/colorscripts/small/61-poliwhirl.txt +11 -0
  126. package/sprites/colorscripts/small/62-poliwrath.txt +17 -0
  127. package/sprites/colorscripts/small/63-abra.txt +12 -0
  128. package/sprites/colorscripts/small/64-kadabra.txt +14 -0
  129. package/sprites/colorscripts/small/65-alakazam.txt +19 -0
  130. package/sprites/colorscripts/small/66-machop.txt +11 -0
  131. package/sprites/colorscripts/small/67-machoke.txt +12 -0
  132. package/sprites/colorscripts/small/68-machamp.txt +19 -0
  133. package/sprites/colorscripts/small/69-bellsprout.txt +9 -0
  134. package/sprites/colorscripts/small/7-squirtle.txt +10 -0
  135. package/sprites/colorscripts/small/70-weepinbell.txt +11 -0
  136. package/sprites/colorscripts/small/71-victreebel.txt +17 -0
  137. package/sprites/colorscripts/small/72-tentacool.txt +12 -0
  138. package/sprites/colorscripts/small/73-tentacruel.txt +20 -0
  139. package/sprites/colorscripts/small/74-geodude.txt +9 -0
  140. package/sprites/colorscripts/small/75-graveler.txt +12 -0
  141. package/sprites/colorscripts/small/76-golem.txt +18 -0
  142. package/sprites/colorscripts/small/77-ponyta.txt +13 -0
  143. package/sprites/colorscripts/small/78-rapidash.txt +18 -0
  144. package/sprites/colorscripts/small/79-slowpoke.txt +12 -0
  145. package/sprites/colorscripts/small/8-wartortle.txt +12 -0
  146. package/sprites/colorscripts/small/80-slowbro.txt +18 -0
  147. package/sprites/colorscripts/small/81-magnemite.txt +9 -0
  148. package/sprites/colorscripts/small/82-magneton.txt +18 -0
  149. package/sprites/colorscripts/small/83-farfetchd.txt +12 -0
  150. package/sprites/colorscripts/small/84-doduo.txt +10 -0
  151. package/sprites/colorscripts/small/85-dodrio.txt +17 -0
  152. package/sprites/colorscripts/small/86-seel.txt +13 -0
  153. package/sprites/colorscripts/small/87-dewgong.txt +20 -0
  154. package/sprites/colorscripts/small/88-grimer.txt +10 -0
  155. package/sprites/colorscripts/small/89-muk.txt +14 -0
  156. package/sprites/colorscripts/small/9-blastoise.txt +20 -0
  157. package/sprites/colorscripts/small/90-shellder.txt +10 -0
  158. package/sprites/colorscripts/small/91-cloyster.txt +18 -0
  159. package/sprites/colorscripts/small/92-gastly.txt +12 -0
  160. package/sprites/colorscripts/small/93-haunter.txt +14 -0
  161. package/sprites/colorscripts/small/94-gengar.txt +19 -0
  162. package/sprites/colorscripts/small/95-onix.txt +22 -0
  163. package/sprites/colorscripts/small/96-drowzee.txt +12 -0
  164. package/sprites/colorscripts/small/97-hypno.txt +19 -0
  165. package/sprites/colorscripts/small/98-krabby.txt +12 -0
  166. package/sprites/colorscripts/small/99-kingler.txt +20 -0
  167. package/src/engine/constants.ts +121 -0
  168. package/src/engine/encounter-pool.ts +71 -0
  169. package/src/engine/encounters.ts +308 -0
  170. package/src/engine/evolution-data.ts +535 -0
  171. package/src/engine/evolution.ts +310 -0
  172. package/src/engine/pokemon-data.ts +1838 -0
  173. package/src/engine/reactions.ts +877 -0
  174. package/src/engine/starter-pool.ts +47 -0
  175. package/src/engine/stats.ts +97 -0
  176. package/src/engine/types.ts +312 -0
  177. package/src/engine/xp.ts +135 -0
  178. package/src/gamification/achievements.ts +204 -0
  179. package/src/gamification/legendary-quests.ts +265 -0
  180. package/src/gamification/milestones.ts +86 -0
  181. package/src/hooks/award-xp.ts +131 -0
  182. package/src/hooks/increment-counter.ts +27 -0
  183. package/src/server/index.ts +78 -0
  184. package/src/server/instructions.ts +194 -0
  185. package/src/server/tools/achievements.ts +118 -0
  186. package/src/server/tools/catch.ts +295 -0
  187. package/src/server/tools/display-helpers.ts +35 -0
  188. package/src/server/tools/evolve.ts +236 -0
  189. package/src/server/tools/legendary.ts +78 -0
  190. package/src/server/tools/party.ts +251 -0
  191. package/src/server/tools/pet.ts +124 -0
  192. package/src/server/tools/pokedex.ts +286 -0
  193. package/src/server/tools/rename.ts +63 -0
  194. package/src/server/tools/show.ts +136 -0
  195. package/src/server/tools/starter.ts +175 -0
  196. package/src/server/tools/stats.ts +123 -0
  197. package/src/server/tools/visibility.ts +65 -0
  198. package/src/sprites/index.ts +45 -0
  199. package/src/state/io.ts +91 -0
  200. package/src/state/schemas.ts +131 -0
  201. package/src/state/state-manager.ts +321 -0
  202. package/statusline/buddy-status.sh +233 -0
  203. package/tsconfig.json +37 -0
@@ -0,0 +1,311 @@
1
+ #!/usr/bin/env bun
2
+ /**
3
+ * Download pokemon-colorscripts from GitHub.
4
+ *
5
+ * Fetches pre-rendered ANSI art .txt files for Gen 1 Pokemon
6
+ * from the pokemon-colorscripts repository.
7
+ *
8
+ * Usage:
9
+ * bun run scripts/download-colorscripts.ts # incremental (skip existing)
10
+ * bun run scripts/download-colorscripts.ts --force # re-download all
11
+ * bun run scripts/download-colorscripts.ts 1 25 150 # specific IDs only
12
+ */
13
+
14
+ import { existsSync, mkdirSync, writeFileSync } from "node:fs";
15
+ import { join } from "node:path";
16
+
17
+ // ── Configuration ─────────────────────────────────────────────
18
+
19
+ const PROJECT_ROOT = join(import.meta.dir, "..");
20
+ const COLORSCRIPT_DIR = join(PROJECT_ROOT, "sprites", "colorscripts");
21
+
22
+ const BASE_URL =
23
+ "https://raw.githubusercontent.com/tageraf1n/pokemon-colorscripts/main/colorscripts";
24
+
25
+ const TOTAL_GEN1 = 151;
26
+
27
+ const SIZES = ["small", "large"] as const;
28
+ type Size = (typeof SIZES)[number];
29
+
30
+ // ── Name Mapping ──────────────────────────────────────────────
31
+
32
+ /**
33
+ * Pokemon names as they appear in the colorscripts repository.
34
+ * Most match the standard lowercase name, but a few have special forms.
35
+ */
36
+ const NAME_OVERRIDES: ReadonlyMap<number, string> = new Map([
37
+ [29, "nidoran-f"],
38
+ [32, "nidoran-m"],
39
+ [83, "farfetchd"],
40
+ [122, "mr.-mime"],
41
+ ]);
42
+
43
+ /**
44
+ * Gen 1 Pokemon names indexed by ID (1-151).
45
+ * Used for both the download URL and the local filename.
46
+ */
47
+ const POKEMON_NAMES: ReadonlyMap<number, string> = new Map([
48
+ [1, "bulbasaur"],
49
+ [2, "ivysaur"],
50
+ [3, "venusaur"],
51
+ [4, "charmander"],
52
+ [5, "charmeleon"],
53
+ [6, "charizard"],
54
+ [7, "squirtle"],
55
+ [8, "wartortle"],
56
+ [9, "blastoise"],
57
+ [10, "caterpie"],
58
+ [11, "metapod"],
59
+ [12, "butterfree"],
60
+ [13, "weedle"],
61
+ [14, "kakuna"],
62
+ [15, "beedrill"],
63
+ [16, "pidgey"],
64
+ [17, "pidgeotto"],
65
+ [18, "pidgeot"],
66
+ [19, "rattata"],
67
+ [20, "raticate"],
68
+ [21, "spearow"],
69
+ [22, "fearow"],
70
+ [23, "ekans"],
71
+ [24, "arbok"],
72
+ [25, "pikachu"],
73
+ [26, "raichu"],
74
+ [27, "sandshrew"],
75
+ [28, "sandslash"],
76
+ [29, "nidoran-f"],
77
+ [30, "nidorina"],
78
+ [31, "nidoqueen"],
79
+ [32, "nidoran-m"],
80
+ [33, "nidorino"],
81
+ [34, "nidoking"],
82
+ [35, "clefairy"],
83
+ [36, "clefable"],
84
+ [37, "vulpix"],
85
+ [38, "ninetales"],
86
+ [39, "jigglypuff"],
87
+ [40, "wigglytuff"],
88
+ [41, "zubat"],
89
+ [42, "golbat"],
90
+ [43, "oddish"],
91
+ [44, "gloom"],
92
+ [45, "vileplume"],
93
+ [46, "paras"],
94
+ [47, "parasect"],
95
+ [48, "venonat"],
96
+ [49, "venomoth"],
97
+ [50, "diglett"],
98
+ [51, "dugtrio"],
99
+ [52, "meowth"],
100
+ [53, "persian"],
101
+ [54, "psyduck"],
102
+ [55, "golduck"],
103
+ [56, "mankey"],
104
+ [57, "primeape"],
105
+ [58, "growlithe"],
106
+ [59, "arcanine"],
107
+ [60, "poliwag"],
108
+ [61, "poliwhirl"],
109
+ [62, "poliwrath"],
110
+ [63, "abra"],
111
+ [64, "kadabra"],
112
+ [65, "alakazam"],
113
+ [66, "machop"],
114
+ [67, "machoke"],
115
+ [68, "machamp"],
116
+ [69, "bellsprout"],
117
+ [70, "weepinbell"],
118
+ [71, "victreebel"],
119
+ [72, "tentacool"],
120
+ [73, "tentacruel"],
121
+ [74, "geodude"],
122
+ [75, "graveler"],
123
+ [76, "golem"],
124
+ [77, "ponyta"],
125
+ [78, "rapidash"],
126
+ [79, "slowpoke"],
127
+ [80, "slowbro"],
128
+ [81, "magnemite"],
129
+ [82, "magneton"],
130
+ [83, "farfetchd"],
131
+ [84, "doduo"],
132
+ [85, "dodrio"],
133
+ [86, "seel"],
134
+ [87, "dewgong"],
135
+ [88, "grimer"],
136
+ [89, "muk"],
137
+ [90, "shellder"],
138
+ [91, "cloyster"],
139
+ [92, "gastly"],
140
+ [93, "haunter"],
141
+ [94, "gengar"],
142
+ [95, "onix"],
143
+ [96, "drowzee"],
144
+ [97, "hypno"],
145
+ [98, "krabby"],
146
+ [99, "kingler"],
147
+ [100, "voltorb"],
148
+ [101, "electrode"],
149
+ [102, "exeggcute"],
150
+ [103, "exeggutor"],
151
+ [104, "cubone"],
152
+ [105, "marowak"],
153
+ [106, "hitmonlee"],
154
+ [107, "hitmonchan"],
155
+ [108, "lickitung"],
156
+ [109, "koffing"],
157
+ [110, "weezing"],
158
+ [111, "rhyhorn"],
159
+ [112, "rhydon"],
160
+ [113, "chansey"],
161
+ [114, "tangela"],
162
+ [115, "kangaskhan"],
163
+ [116, "horsea"],
164
+ [117, "seadra"],
165
+ [118, "goldeen"],
166
+ [119, "seaking"],
167
+ [120, "staryu"],
168
+ [121, "starmie"],
169
+ [122, "mr-mime"],
170
+ [123, "scyther"],
171
+ [124, "jynx"],
172
+ [125, "electabuzz"],
173
+ [126, "magmar"],
174
+ [127, "pinsir"],
175
+ [128, "tauros"],
176
+ [129, "magikarp"],
177
+ [130, "gyarados"],
178
+ [131, "lapras"],
179
+ [132, "ditto"],
180
+ [133, "eevee"],
181
+ [134, "vaporeon"],
182
+ [135, "jolteon"],
183
+ [136, "flareon"],
184
+ [137, "porygon"],
185
+ [138, "omanyte"],
186
+ [139, "omastar"],
187
+ [140, "kabuto"],
188
+ [141, "kabutops"],
189
+ [142, "aerodactyl"],
190
+ [143, "snorlax"],
191
+ [144, "articuno"],
192
+ [145, "zapdos"],
193
+ [146, "moltres"],
194
+ [147, "dratini"],
195
+ [148, "dragonair"],
196
+ [149, "dragonite"],
197
+ [150, "mewtwo"],
198
+ [151, "mew"],
199
+ ]);
200
+
201
+ // ── Download Logic ────────────────────────────────────────────
202
+
203
+ /** Get the remote filename for a Pokemon in the colorscripts repo. */
204
+ function getRemoteName(id: number): string {
205
+ return NAME_OVERRIDES.get(id) ?? POKEMON_NAMES.get(id) ?? `pokemon-${id}`;
206
+ }
207
+
208
+ /** Get the local filename for a Pokemon. */
209
+ function getLocalName(id: number): string {
210
+ const name = POKEMON_NAMES.get(id) ?? `pokemon-${id}`;
211
+ return `${id}-${name}.txt`;
212
+ }
213
+
214
+ /** Download a single colorscript file. */
215
+ async function downloadColorscript(
216
+ id: number,
217
+ size: Size,
218
+ force: boolean,
219
+ ): Promise<"downloaded" | "skipped" | "failed"> {
220
+ const localName = getLocalName(id);
221
+ const outputPath = join(COLORSCRIPT_DIR, size, localName);
222
+
223
+ if (!force && existsSync(outputPath)) {
224
+ return "skipped";
225
+ }
226
+
227
+ const remoteName = getRemoteName(id);
228
+ const url = `${BASE_URL}/${size}/regular/${remoteName}`;
229
+
230
+ try {
231
+ const resp = await fetch(url);
232
+ if (!resp.ok) {
233
+ console.error(` [FAIL] #${id} ${remoteName} (${size}): HTTP ${resp.status}`);
234
+ return "failed";
235
+ }
236
+
237
+ const text = await resp.text();
238
+ writeFileSync(outputPath, text, "utf-8");
239
+ return "downloaded";
240
+ } catch (err) {
241
+ console.error(` [FAIL] #${id} ${remoteName} (${size}): ${String(err)}`);
242
+ return "failed";
243
+ }
244
+ }
245
+
246
+ // ── CLI & Main ────────────────────────────────────────────────
247
+
248
+ function parseArgs(): { force: boolean; ids: number[] } {
249
+ const args = process.argv.slice(2);
250
+ const force = args.includes("--force");
251
+ const ids = args
252
+ .filter((a) => a !== "--force")
253
+ .map((a) => parseInt(a, 10))
254
+ .filter((n) => !isNaN(n) && n >= 1 && n <= TOTAL_GEN1);
255
+
256
+ return { force, ids };
257
+ }
258
+
259
+ async function main(): Promise<void> {
260
+ console.log("\n Claudemon Colorscript Downloader\n");
261
+
262
+ const { force, ids: requestedIds } = parseArgs();
263
+ const targetIds =
264
+ requestedIds.length > 0 ? requestedIds : Array.from({ length: TOTAL_GEN1 }, (_, i) => i + 1);
265
+
266
+ console.log(
267
+ ` Downloading ${targetIds.length} sprite(s)${force ? " (force)" : " (incremental)"}`,
268
+ );
269
+
270
+ // Ensure output directories exist
271
+ for (const size of SIZES) {
272
+ mkdirSync(join(COLORSCRIPT_DIR, size), { recursive: true });
273
+ }
274
+
275
+ let downloaded = 0;
276
+ let skipped = 0;
277
+ let failed = 0;
278
+
279
+ for (const id of targetIds) {
280
+ for (const size of SIZES) {
281
+ const result = await downloadColorscript(id, size, force);
282
+ switch (result) {
283
+ case "downloaded":
284
+ downloaded++;
285
+ break;
286
+ case "skipped":
287
+ skipped++;
288
+ break;
289
+ case "failed":
290
+ failed++;
291
+ break;
292
+ }
293
+ }
294
+
295
+ if (downloaded > 0 && downloaded % 20 === 0) {
296
+ const name = POKEMON_NAMES.get(id) ?? `pokemon-${id}`;
297
+ console.log(` [${downloaded}] latest: #${id} ${name}`);
298
+ }
299
+ }
300
+
301
+ console.log(`\n Done! Downloaded: ${downloaded}, Skipped: ${skipped}, Failed: ${failed}\n`);
302
+
303
+ if (failed > 0) {
304
+ process.exit(1);
305
+ }
306
+ }
307
+
308
+ main().catch((err) => {
309
+ console.error("Fatal error:", err);
310
+ process.exit(1);
311
+ });
@@ -0,0 +1,47 @@
1
+ ---
2
+ name: buddy
3
+ description: Interact with your Claudemon Pokemon coding companion — show, pet, stats, starter, evolve, catch, party, pokedex, achievements, legendary
4
+ allowed-tools: mcp__claudemon__*
5
+ ---
6
+
7
+ ## IMPORTANT: First Run Behavior
8
+
9
+ When `$ARGUMENTS` is empty OR `show`, FIRST call `buddy_show`.
10
+ If buddy_show returns an error saying no Pokemon exists or asks to pick a starter,
11
+ then IMMEDIATELY call `buddy_starter` (with no choice) to show the 3 starter options.
12
+ This ensures first-time users get the starter selection flow automatically.
13
+
14
+ ## Command Routing
15
+
16
+ | Input | Tool Call |
17
+ |-------|-----------|
18
+ | (empty) or `show` | `buddy_show` — if it fails (no Pokemon), then call `buddy_starter` |
19
+ | `compact` | `buddy_show` with detail="compact" |
20
+ | `stats` | `buddy_stats` |
21
+ | `pet` | `buddy_pet` |
22
+ | `starter` | `buddy_starter` (shows 3 choices) |
23
+ | `starter 1` or `starter 2` or `starter 3` | `buddy_starter` with choice=N |
24
+ | `evolve` | `buddy_evolve` |
25
+ | `evolve confirm` | `buddy_evolve` with confirm=true |
26
+ | `catch` | `buddy_catch` |
27
+ | `catch confirm` | `buddy_catch` with confirm=true |
28
+ | `party` | `buddy_party` with action="list" |
29
+ | `switch N` | `buddy_party` with action="switch", slot=N |
30
+ | `deposit N` | `buddy_party` with action="deposit", slot=N |
31
+ | `withdraw N` | `buddy_party` with action="withdraw", slot=N |
32
+ | `pokedex` | `buddy_pokedex` |
33
+ | `pokedex all` | `buddy_pokedex` with filter="all" |
34
+ | `pokedex caught` | `buddy_pokedex` with filter="caught" |
35
+ | `pokedex seen` | `buddy_pokedex` with filter="seen" |
36
+ | `pokedex [name]` | `buddy_pokedex` with pokemon=name |
37
+ | `pokedex [number]` | `buddy_pokedex` with pokemon=number |
38
+ | `achievements` | `buddy_achievements` |
39
+ | `legendary` | `buddy_legendary` |
40
+ | `rename <name>` | `buddy_rename` with name=NAME — give a nickname (max 20 chars) |
41
+ | `rename` (empty) | `buddy_rename` with name="" — reset to species name |
42
+ | `hide` | `buddy_hide` — hide sprite from status line |
43
+ | `unhide` | `buddy_unhide` — show sprite in status line |
44
+ | `help` | List all available /buddy commands |
45
+
46
+ Pass $ARGUMENTS to determine which subcommand to route to.
47
+ Display all tool output EXACTLY as returned — do not summarize or modify the output.
@@ -0,0 +1,11 @@
1
+ ▄▀▄▀▄
2
+ ▄▄▀▀▀▀▀▀▄▄
3
+ ▄ ▄▀▀▀▀▀▀▀▀▀▀▀▀▄
4
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
5
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
8
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
9
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀
10
+ ▀▀▀▀
11
+ 
@@ -0,0 +1,9 @@
1
+ ▄▀▄ ▄▄▄
2
+ ▀▀▀▀▀▀▀▀
3
+ ▀▀▀▀▀▀▀▀▀▄
4
+ ▀▀▀▀▀▀▀▀▀▀▀
5
+ ▀▀▀▀▀▀▀▀▀▀▀▄▀▄
6
+ ▀▀▀▀▀▀▀▀▄▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀
8
+ ▀▀▀▀▀▀
9
+ 
@@ -0,0 +1,8 @@
1
+ ▄▄▀▀▀▀▄▄
2
+ ▄▀▀▀▀▀▀▀▀▀▀▄
3
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▄
4
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀
5
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀
8
+ 
@@ -0,0 +1,9 @@
1
+ ▄▄▀▀▀▀▄▄
2
+ ▀▀▀▀▀▀▀▀▀▀▀▀
3
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀
4
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
5
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀
8
+ ▀▀▀▀▀▀▀▀
9
+ 
@@ -0,0 +1,10 @@
1
+ ▄▄ ▄▀▀▀▄
2
+ ▄▀▀▀▀▄▀▀▀▀▀▀▀ ▄▄
3
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
4
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
5
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
8
+ ▀▀▀▀ ▀▀▀▀▀▀▀▀
9
+ ▀▀▀▀▀▀
10
+ 
@@ -0,0 +1,23 @@
1
+ ▄▀▀
2
+ ▀▀▀▀
3
+ ▄▀▀▀▄▄ ▀▀▀▀ ▄▄▄▄
4
+ ▀▀▀▀▀▀▄ ▀▀▀▀ ▄▀▀▀▀▀▀▀
5
+ ▄▄▄▄▄▄ ▀▀▀▀▀▄ ▀▀▀▀ ▄▀▀▀▀▀▄▄▄▀▀▀▀▀▀▄
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
8
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▄▄▄
9
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
10
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
11
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
12
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
13
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
14
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
15
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
16
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
17
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀
18
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
19
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
20
+ ▀▀▀▀▀▀▀▀ ▄▀▀▀▀▀▀▄
21
+ ▀▀▀ ▀▀▀▀▀▀▀▀
22
+ ▀▀▀▀
23
+ 
@@ -0,0 +1,11 @@
1
+ ▄▀▀▄▄▄▄▄ ▄▄
2
+ ▀▀▀▀▀▀▀▀▀▀▀▀
3
+ ▀▀▀▀▀▀▀▀▀▀▀
4
+ ▄▀▀▀▀▀▀▀▀▀▀▀▄
5
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▄▄ ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▄
8
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
9
+ ▀▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀
10
+ ▀▀ ▀▀
11
+ 
@@ -0,0 +1,16 @@
1
+ ▄▀▄ ▄▄
2
+ ▀▀▀▀▄▀▀▀▀▄▄▄▀▀▀▀
3
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
4
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀
5
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
8
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
9
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
10
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
11
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▀▀▀▀▀▀
12
+ ▄▀▀▀▄▄▄▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▀▀▀▀
13
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▄
14
+ ▀▀▀▀▀▀▀▀ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
15
+ ▀▀▀▀▀ ▀▀▀ ▀▀▀▀▀
16
+ 
@@ -0,0 +1,16 @@
1
+ ▄▄▀▀▀▀▀▄▄
2
+ ▄▀▀▀▀▀▀▀▀▀▀▀▄
3
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
4
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
5
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
6
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▄▀▀▄▄ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
8
+ ▀▀▀▀▀▀▀▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
9
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▀▀▀▀▀
10
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
11
+ ▀▀▀▀▀▀▀ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▄
12
+ ▀▀▀ ▀▀▀▀▀▄▄ ▀ ▀▀
13
+ ▄▄▀▀▀▀▀▀
14
+ ▀▀▀▀▀▀▀▀
15
+ ▀▀▀▀▀
16
+ 
@@ -0,0 +1,19 @@
1
+ ▄▀▀▄
2
+ ▄▀▀▀▀▀ ▄▀▀▄
3
+ ▄▀▀▀▀▀▀▄▀▀▀▀ ▄▄
4
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
5
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
6
+ ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
7
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
8
+ ▄▄▄ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄▄▄
9
+ ▄▀▀▀▀▀▀▀▄▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▄
10
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
11
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
12
+ ▀▀▀▀▀▀▀ ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▀▄
13
+ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
14
+ ▄▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
15
+ ▄▄▀▀▀▀▀ ▀▀▀▀▄▄
16
+ ▀▀▀▀▀▀ ▀▀▀▀▀▀
17
+ ▀▀▀ ▀▀▀▀▀
18
+ ▀▀▀
19
+