@jarrodmedrano/claude-skills 1.0.3 → 1.0.4

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 (26) hide show
  1. package/.claude/skills/bevy/SKILL.md +406 -0
  2. package/.claude/skills/bevy/references/bevy_specific_tips.md +385 -0
  3. package/.claude/skills/bevy/references/common_pitfalls.md +217 -0
  4. package/.claude/skills/bevy/references/ecs_patterns.md +277 -0
  5. package/.claude/skills/bevy/references/project_structure.md +116 -0
  6. package/.claude/skills/bevy/references/ui_development.md +147 -0
  7. package/.claude/skills/domain-driven-design/SKILL.md +459 -0
  8. package/.claude/skills/domain-driven-design/references/ddd_foundations_and_patterns.md +664 -0
  9. package/.claude/skills/domain-driven-design/references/rich_hickey_principles.md +406 -0
  10. package/.claude/skills/domain-driven-design/references/visualization_examples.md +790 -0
  11. package/.claude/skills/domain-driven-design/references/wlaschin_patterns.md +639 -0
  12. package/.claude/skills/godot/SKILL.md +728 -0
  13. package/.claude/skills/godot/assets/templates/attribute_template.gd +109 -0
  14. package/.claude/skills/godot/assets/templates/component_template.gd +76 -0
  15. package/.claude/skills/godot/assets/templates/interaction_template.gd +108 -0
  16. package/.claude/skills/godot/assets/templates/item_resource.tres +11 -0
  17. package/.claude/skills/godot/assets/templates/spell_resource.tres +20 -0
  18. package/.claude/skills/godot/references/architecture-patterns.md +608 -0
  19. package/.claude/skills/godot/references/common-pitfalls.md +518 -0
  20. package/.claude/skills/godot/references/file-formats.md +491 -0
  21. package/.claude/skills/godot/references/godot4-physics-api.md +302 -0
  22. package/.claude/skills/godot/scripts/validate_tres.py +145 -0
  23. package/.claude/skills/godot/scripts/validate_tscn.py +170 -0
  24. package/.claude/skills/react-three-fiber/SKILL.md +2055 -0
  25. package/.claude/skills/react-three-fiber/scripts/build-scene.ts +171 -0
  26. package/package.json +1 -1
@@ -0,0 +1,171 @@
1
+ #!/usr/bin/env bun
2
+
3
+ /**
4
+ * Three.js Scene Builder Helper
5
+ * Quickly scaffold Three.js scenes with common configurations
6
+ */
7
+
8
+ import { writeFile, mkdir } from 'fs/promises';
9
+ import { join } from 'path';
10
+
11
+ async function main() {
12
+ const args = process.argv.slice(2);
13
+
14
+ if (args.includes('--help') || args.includes('-h') || args.length === 0) {
15
+ console.log(`
16
+ Three.js Scene Builder
17
+
18
+ Usage:
19
+ bun run build-scene.ts <scene-name> [options]
20
+
21
+ Options:
22
+ --basic Create basic scene (default)
23
+ --vr Create VR-ready scene
24
+ --physics Include physics setup
25
+ --lighting Advanced lighting setup
26
+ --output <dir> Output directory (default: ./src/scenes)
27
+ --help, -h Show this help message
28
+
29
+ Examples:
30
+ bun run build-scene.ts MyScene
31
+ bun run build-scene.ts GameScene --vr --physics
32
+ `);
33
+ process.exit(args.length === 0 ? 1 : 0);
34
+ }
35
+
36
+ const sceneName = args[0];
37
+ const outputDir = args[args.indexOf('--output') + 1] || './src/scenes';
38
+ const isVR = args.includes('--vr');
39
+ const hasPhysics = args.includes('--physics');
40
+ const advancedLighting = args.includes('--lighting');
41
+
42
+ try {
43
+ await mkdir(outputDir, { recursive: true });
44
+
45
+ const sceneTemplate = `import * as THREE from 'three';
46
+ ${isVR ? "import { VRButton } from 'three/examples/jsm/webxr/VRButton.js';" : ''}
47
+ ${hasPhysics ? "import * as CANNON from 'cannon-es';" : ''}
48
+
49
+ export class ${sceneName} {
50
+ scene: THREE.Scene;
51
+ camera: THREE.PerspectiveCamera;
52
+ renderer: THREE.WebGLRenderer;
53
+ ${hasPhysics ? 'world: CANNON.World;' : ''}
54
+
55
+ constructor() {
56
+ this.scene = new THREE.Scene();
57
+ this.camera = new THREE.PerspectiveCamera(
58
+ 75,
59
+ window.innerWidth / window.innerHeight,
60
+ 0.1,
61
+ 1000
62
+ );
63
+ this.renderer = new THREE.WebGLRenderer({ antialias: true });
64
+
65
+ this.init();
66
+ }
67
+
68
+ init() {
69
+ // Renderer setup
70
+ this.renderer.setSize(window.innerWidth, window.innerHeight);
71
+ this.renderer.shadowMap.enabled = true;
72
+ ${isVR ? 'this.renderer.xr.enabled = true;' : ''}
73
+ document.body.appendChild(this.renderer.domElement);
74
+
75
+ ${isVR ? "document.body.appendChild(VRButton.createButton(this.renderer));" : ''}
76
+
77
+ ${hasPhysics ? this.getPhysicsSetup() : ''}
78
+
79
+ // Lighting
80
+ ${advancedLighting ? this.getAdvancedLighting() : this.getBasicLighting()}
81
+
82
+ // Camera position
83
+ this.camera.position.set(0, 2, 5);
84
+ this.camera.lookAt(0, 0, 0);
85
+
86
+ // Window resize handler
87
+ window.addEventListener('resize', () => this.onWindowResize());
88
+ }
89
+
90
+ ${hasPhysics ? `
91
+ initPhysics() {
92
+ this.world = new CANNON.World();
93
+ this.world.gravity.set(0, -9.82, 0);
94
+ }
95
+ ` : ''}
96
+
97
+ onWindowResize() {
98
+ this.camera.aspect = window.innerWidth / window.innerHeight;
99
+ this.camera.updateProjectionMatrix();
100
+ this.renderer.setSize(window.innerWidth, window.innerHeight);
101
+ }
102
+
103
+ animate() {
104
+ ${isVR ? 'this.renderer.setAnimationLoop(() => {' : 'requestAnimationFrame(() => this.animate());'}
105
+ ${hasPhysics ? 'this.world.step(1 / 60);' : ''}
106
+ this.renderer.render(this.scene, this.camera);
107
+ ${isVR ? '});' : ''}
108
+ }
109
+
110
+ start() {
111
+ this.animate();
112
+ }
113
+ }
114
+ `;
115
+
116
+ const filepath = join(outputDir, `${sceneName}.ts`);
117
+ await writeFile(filepath, sceneTemplate);
118
+
119
+ console.log(`✓ Created scene: ${filepath}`);
120
+ console.log(`
121
+ Next steps:
122
+ 1. Import and instantiate: import { ${sceneName} } from './scenes/${sceneName}';
123
+ 2. Create instance: const scene = new ${sceneName}();
124
+ 3. Start rendering: scene.start();
125
+ `);
126
+ } catch (error) {
127
+ console.error('Failed to create scene:', error);
128
+ process.exit(1);
129
+ }
130
+
131
+ function getBasicLighting(): string {
132
+ return `const ambientLight = new THREE.AmbientLight(0xffffff, 0.5);
133
+ this.scene.add(ambientLight);
134
+
135
+ const directionalLight = new THREE.DirectionalLight(0xffffff, 0.8);
136
+ directionalLight.position.set(5, 10, 5);
137
+ directionalLight.castShadow = true;
138
+ this.scene.add(directionalLight);`;
139
+ }
140
+
141
+ function getAdvancedLighting(): string {
142
+ return `// Ambient light
143
+ const ambientLight = new THREE.AmbientLight(0x404040, 0.3);
144
+ this.scene.add(ambientLight);
145
+
146
+ // Main directional light (sun)
147
+ const sunLight = new THREE.DirectionalLight(0xffffff, 1.0);
148
+ sunLight.position.set(10, 20, 10);
149
+ sunLight.castShadow = true;
150
+ sunLight.shadow.mapSize.width = 2048;
151
+ sunLight.shadow.mapSize.height = 2048;
152
+ sunLight.shadow.camera.near = 0.5;
153
+ sunLight.shadow.camera.far = 50;
154
+ this.scene.add(sunLight);
155
+
156
+ // Fill light
157
+ const fillLight = new THREE.DirectionalLight(0x8888ff, 0.3);
158
+ fillLight.position.set(-5, 5, -5);
159
+ this.scene.add(fillLight);
160
+
161
+ // Hemisphere light for sky/ground gradient
162
+ const hemisphereLight = new THREE.HemisphereLight(0x8888ff, 0x888888, 0.5);
163
+ this.scene.add(hemisphereLight);`;
164
+ }
165
+
166
+ function getPhysicsSetup(): string {
167
+ return `this.initPhysics();`;
168
+ }
169
+ }
170
+
171
+ main();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jarrodmedrano/claude-skills",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "Reusable Claude Code skills for web development projects",
5
5
  "main": "index.js",
6
6
  "bin": {