# Start the Game

## Quick Start (Windows)

### Option 1: Run Directly (Recommended)
```powershell
cd e:\Development\Repositories\tribegen
php -S localhost:8000 -t public/
```

Then open your browser to: **http://localhost:8000**

### Option 2: Using PowerShell Script
Run this command in PowerShell:
```powershell
cd e:\Development\Repositories\tribegen; php -S localhost:8000 -t public/
```

### Option 3: Using Batch File
Create a file named `start.bat` with:
```batch
@echo off
cd /d "%~dp0"
php -S localhost:8000 -t public/
pause
```

Then double-click `start.bat` to start.

---

## Troubleshooting

### PHP Not Found
Make sure PHP is installed and in your PATH:
```powershell
php -v
```

If not installed:
- Download from https://www.php.net/downloads
- Add PHP folder to Windows PATH
- Restart terminal/PowerShell

### Port 8000 Already in Use
If port 8000 is busy, use a different port:
```powershell
php -S localhost:8001 -t public/
```

Then open: **http://localhost:8001**

### Database Error
The database is automatically created. If you get an error:
1. Ensure `data/` folder exists (it should)
2. Make sure `data/` is writable
3. Delete `data/tribegen.db` if corrupted
4. Refresh the page

### Can't Connect
- Make sure you're using `http://` not `https://`
- Try `127.0.0.1:8000` instead of `localhost:8000`
- Check firewall isn't blocking port 8000

---

## What to Do After Starting

1. **Register** a new account (any email/password)
2. **Login** with your account
3. **Create New Tribe** button
4. **Enter tribe name** and generate
5. **Select leader** and name them
6. **Select 5 members** for your tribe
7. **Play the game!**

---

## Game Features to Try

- Click events (hunting, exploration, farming)
- End month to progress time
- Watch kobolds age
- See what happens during events

---

## File Locations

- Game files: `e:\Development\Repositories\tribegen\public\`
- Database: `e:\Development\Repositories\tribegen\data\tribegen.db`
- Code: `e:\Development\Repositories\tribegen\src\`

---

## Browser Requirements

Any modern browser:
- Chrome/Edge (recommended)
- Firefox
- Safari
- Opera

---

## Stop the Server

Press `Ctrl+C` in the PowerShell/Command Prompt window.

---

## More Information

- **GETTING_STARTED.md** - Full getting started guide
- **QUICKSTART.md** - Gameplay guide
- **README.md** - Feature list
- **ARCHITECTURE.md** - Technical details

---

## Common URLs

- Game: **http://localhost:8000**
- Alternative: **http://127.0.0.1:8000**
- Different port: **http://localhost:8001** (if 8000 busy)

---

Enjoy your Kobold tribe! 🎮
