Add project docs, MIT license, and AI dev guidelines
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
# Contributing to FrogFPS
|
||||
|
||||
## Coding Standards
|
||||
|
||||
### C# Conventions
|
||||
|
||||
- Use `PascalCase` for class names, `camelCase` for methods/properties
|
||||
- Godot nodes: use `[Export]` for inspector-exposed fields
|
||||
- Signals: connect via code using `Connect()` or `[Signal]` attribute
|
||||
- Prefer composition over inheritance where possible
|
||||
|
||||
### Scene Files (.tscn)
|
||||
|
||||
- Keep scene hierarchy flat — avoid deep nesting
|
||||
- Use unique node names (no "Node", "Node2D", etc.)
|
||||
- Group related nodes under a named parent
|
||||
|
||||
### Git Workflow
|
||||
|
||||
- Small, focused commits with descriptive messages
|
||||
- Branch naming: `feature/<name>`, `bugfix/<name>`
|
||||
- Pull requests should include what/why, not just what changed
|
||||
|
||||
## AI Development Guidelines
|
||||
|
||||
When working with AI assistants on this project:
|
||||
|
||||
1. **Context first** — share relevant scene structure and existing code before asking for implementations
|
||||
2. **Godot patterns** — AI should follow Godot 4 C# conventions (signals, `_Process`, `_PhysicsProcess`, etc.)
|
||||
3. **Incremental changes** — one feature at a time; verify each works before moving on
|
||||
4. **Scene integrity** — don't modify `.tscn` files directly unless necessary; prefer code-based node creation
|
||||
|
||||
## Quick Reference
|
||||
|
||||
| Concept | Pattern |
|
||||
|---------|---------|
|
||||
| Node script | `public partial class MyClass : Node3D { ... }` |
|
||||
| Export variable | `[Export] public int Health { get; set; } = 100;` |
|
||||
| Signal | `[Signal] public delegate void HealthChangedEventHandler(int newHealth);` |
|
||||
| Process loop | `public override void _Process(double delta) { ... }` |
|
||||
| Physics loop | `public override void _PhysicsProcess(double delta) { ... }` |
|
||||
Reference in New Issue
Block a user