The Unity extension includes a hidden Developer Tab that allows easy switching between environments. This tab is only for internal development and should NOT be visible to end users.
To enable the Developer tab:
- Open the Unity project
- Navigate to:
Assets/Plugins/Game Launcher Cloud/ - Manually edit
glc_config.json(or create it if it doesn't exist) - Set
"showDeveloperTab": true
Example:
{
"showDeveloperTab": true,
"environment": 0
}- Reopen the GLC Manager window
- You'll now see a Developer tab
The Developer tab provides quick switching between:
- API URL:
https://localhost:7226/ - Frontend URL:
http://localhost:4200 - Database: Local PostgreSQL
- Cloudflare R2:
game-launcher-cloud-development - Stripe: Test mode
- API URL:
https://stagingapi.gamelauncher.cloud - Frontend URL:
https://staging.app.gamelauncher.cloud - Database: Railway Staging (nozomi)
- Cloudflare R2:
game-launcher-cloud-staging - Stripe: Test mode
- API URL:
https://api.gamelauncher.cloud - Frontend URL:
https://app.gamelauncher.cloud - Database: Railway Production (mainline)
- Cloudflare R2:
game-launcher-cloud-production - Stripe: Live mode
- Environment Dropdown - Select environment from enum
- Quick Action Buttons - One-click switch to Dev/Staging/Prod
- Current Configuration Display - Shows active API and Frontend URLs
- All Environment URLs - Reference list of all endpoints
- Toggle Developer Tab - Show/hide this tab
- Clear Auth Data - Quick logout and credential clearing
public enum GLCEnvironment
{
Production, // 0 (default)
Staging, // 1
Development // 2
}
public class GLCConfig
{
// ... other properties ...
public GLCEnvironment environment = GLCEnvironment.Production;
public bool showDeveloperTab = false;
public string GetApiUrl() { /* returns URL based on environment */ }
public string GetFrontendUrl() { /* returns URL based on environment */ }
}- Open the Developer tab
- Set Environment to
Production - Set Show Developer Tab to
false(unchecked) - Save and test
- Verify the Developer tab is no longer visible
- Build the Unity package
This ensures users don't see internal development options.
1. Set environment to "Development"
2. Run local backend (dotnet run)
3. Run local frontend (ng serve)
4. Test builds upload to local R2 bucket
1. Set environment to "Staging"
2. Use staging API keys
3. Test with staging database
4. Verify uploads go to staging R2
1. Set environment to "Production"
2. Use production API keys (carefully!)
3. Test end-to-end flow
4. Verify real builds are created
Different environments require different API keys:
- Development: Use test API keys from local database
- Staging: Use staging API keys from staging.app.gamelauncher.cloud
- Production: Use production API keys from app.gamelauncher.cloud
The extension automatically connects to the correct backend based on the selected environment.
All URLs are pulled from appsettings.json in the backend:
| Environment | Backend AppSettings File |
|---|---|
| Development | appsettings.Development.json |
| Staging | appsettings.Staging.json |
| Production | appsettings.json |
The Unity extension mirrors these URLs in the GLCConfig.GetApiUrl() and GLCConfig.GetFrontendUrl() methods.
- Check
glc_config.jsonhas"showDeveloperTab": true - Restart Unity Editor
- Reopen the GLC Manager window
- Open Developer tab
- Verify environment in dropdown
- Click appropriate Quick Action button
- Check "Current Configuration" section
- Verify backend is running (for Development)
- Check URLs match backend appsettings
- Confirm API key is valid for selected environment
- Check firewall/network settings
🔒 Never commit:
glc_config.jsonwith real API keys- Configuration with
showDeveloperTab: true - Production credentials
✅ Safe to commit:
glc_config.example.json- Code changes to environment logic
- Documentation updates
For CI/CD pipelines, you can set the environment programmatically:
// In Unity Editor script
var config = GLCConfigManager.LoadConfig();
config.environment = GLCEnvironment.Development;
config.showDeveloperTab = false;
GLCConfigManager.SaveConfig(config);For questions about the developer environment:
- 💬 Internal Slack: #unity-extension-dev
- 📧 Email: dev@gamelauncher.cloud
- 📚 Backend Docs: Check appsettings files
Remember: This developer functionality is for internal use only and should never be exposed to end users in the published Unity package!