Thank you for your interest in contributing to VOIDSTRIKE. This document outlines the process for contributing to the project.
git clone https://github.com/your-username/voidstrike.git
cd voidstrike
npm install
npm run devOpen http://localhost:3000 in Chrome 113+ (WebGPU) or any modern browser (WebGL2 fallback).
- Fork the repository
- Create a branch for your feature or fix:
git checkout -b feature/my-feature - Make your changes following the code standards below
- Test locally:
npm run type-check && npm run lint && npm run dev - Commit with a conventional commit message
- Push and open a Pull Request
- Strict TypeScript - avoid
anyunless absolutely necessary - Prefer interfaces over types for object shapes
- Use enums for finite sets of values
- Components:
PascalCase.tsx - Utilities:
camelCase.ts - Constants:
SCREAMING_SNAKE_CASE - Interfaces/Types:
PascalCase
Professional and understated. Explain WHY, not WHAT.
// Bad: "World-Class Particle System"
// Good: "GPU Particle System"
// Bad: "// Get the player entity"
// Good: (no comment needed - code is self-explanatory)
// Good: "// Edge case: entity may be destroyed mid-frame"- All game state must be deterministic for multiplayer
- Logic in Systems, data in Components
- Use
EventBusfor cross-system communication - Use
SeededRandomfromutils/math.tsfor any randomness
Use Conventional Commits:
feat:- New featurefix:- Bug fixdocs:- Documentation onlyrefactor:- Code change that neither fixes a bug nor adds a featurestyle:- Formatting, missing semicolons, etc.test:- Adding or updating testschore:- Build process, dependencies, etc.
Examples:
feat: add siege mode to Dominion tanks
fix: prevent units from clumping at rally points
docs: update networking architecture diagram
refactor: extract spatial grid to separate module
src/
├── engine/ # Reusable game engine (ECS, systems, networking)
├── rendering/ # Three.js WebGPU rendering pipeline
├── data/ # Game configuration (units, buildings, maps)
└── components/ # React UI layer
Key principle: Everything in src/engine/ should be game-agnostic. Everything in src/data/ is VOIDSTRIKE-specific.
- Unit tests for ECS core, deterministic math, and networking
- Performance benchmarks with reproducible metrics
- Bug fixes with clear reproduction steps
- AI improvements - better micro, smarter macro decisions
- New TSL shader effects - weather, time of day, etc.
- Accessibility - keyboard navigation, screen reader support
- Additional factions or units (discuss in an issue first)
- Major architectural changes (discuss in an issue first)
-
npm run type-checkpasses -
npm run lintpasses - Changes work in both WebGPU and WebGL2 modes
- Multiplayer changes maintain determinism
- Documentation updated if adding new systems
Open an issue for:
- Bug reports (include reproduction steps)
- Feature proposals (describe the use case)
- Architecture questions
By contributing, you agree that your contributions will be licensed under the MIT License.