This is a Godot 3.6 project configured for WebGL deployment with C#/.NET support and OpenGL ES 2.0 rendering.
- Godot 3.6 game engine
- OpenGL ES 2.0 renderer for maximum compatibility
- WebGL export support for web deployment
- C#/.NET Framework 4.7.2 support for scripting
- GitHub Pages ready for deployment with automated CI/CD
├── project.godot # Main project configuration
├── GodotWebGLProject.csproj # .NET project file
├── GodotWebGLProject.sln # Visual Studio solution
├── export_presets.cfg # Export configuration for WebGL
├── Main.tscn # Main scene
├── icon.png # Project icon
├── scenes/ # Scene files
│ └── TestScene.tscn # Test scene with interactive elements
├── scripts/ # C# scripts
│ ├── Main.cs # Main scene script
│ └── TestScene.cs # Test scene script
├── assets/ # Game assets
├── textures/ # Texture files
├── sounds/ # Audio files
└── build/ # WebGL build output
- Godot 3.6 with Mono/.NET support
- .NET Framework 4.7.2 or higher
- Visual Studio or Visual Studio Code (optional, for C# development)
- Open Godot 3.6 - This exct version, in order to be able to have dotnet on webgl build target.
- Click "Import" and select this folder
- The project should automatically detect the
project.godotfile - Click "Import & Edit"
- In Godot, go to Project > Project Settings
- Ensure the Mono tab shows the correct assembly name
- Go to Build > Build Project to compile C# scripts
- Run the project with F5 or the play button
- Go to Project > Export
- Select the HTML5 preset (already configured, if not, install the template)
- Click Export Project
- Choose the
build/directory as the export location - The exported files will be ready for web deployment
- Driver: OpenGL ES 2.0 (GLES2)
- VRAM Compression: ETC for mobile compatibility
- Canvas Resize Policy: Adaptive for responsive design
- Target Framework: .NET Framework 4.7.2
- Language Version: C# 7.3
- Assembly Name: GodotWebGLProject
- Simple welcome screen with interactive button
- Click the button 5 times or press 'T' to navigate to test scene
- Demonstrates basic C# scripting and UI interaction
- Interactive color-changing demonstration
- Shows runtime information (renderer, platform, framework)
- Keyboard controls:
- Space: Change color randomly
- R: Reset to original color
- Escape: Return to main scene
- Build the project for WebGL
- Copy the contents of the
build/folder to your repository - Enable GitHub Pages in repository settings
- Your game will be available at
https://username.github.io/repository-name
- After exporting, you can test locally using a simple HTTP server:
cd build python -m http.server 8000 - Open
http://localhost:8000in your browser
This project includes automated GitHub Actions workflow for deploying to GitHub Pages.
- Your repository must be public (or you need GitHub Pro for private repos)
- The repository should be pushed to GitHub
- You need admin access to the repository
The project will automatically build and deploy to GitHub Pages when you:
- Push to the
mainormasterbranch - Create a pull request to
mainormaster
- Go to your repository on GitHub
- Click on Settings tab
- Scroll down to Pages section in the left sidebar
- Under Source, select GitHub Actions
- In the repository Settings
- Go to Actions → General
- Under Workflow permissions, select:
- ✅ Read and write permissions
- ✅ Allow GitHub Actions to create and approve pull requests
The workflow will automatically run when you:
- Push to the
mainormasterbranch - Create a pull request to
mainormaster - Manually trigger it from the Actions tab
git add .
git commit -m "Add Godot WebGL project with GitHub Pages deployment"
git push origin mainAfter successful deployment, your game will be available at:
https://[username].github.io/[repository-name]/
You can also trigger deployment manually:
- Go to Actions tab in your repository
- Select Deploy Godot WebGL to GitHub Pages workflow
- Click Run workflow button
- Select the branch and click Run workflow
The GitHub Actions workflow will:
- Setup Environment: Install .NET, Godot 3.6, and dependencies
- Import Assets: Import all project assets in headless mode
- Build C# Project: Compile the C# scripts using Godot
- Export WebGL: Export the project to WebGL format in the
build/directory - Deploy: Upload the build artifacts to GitHub Pages
The workflow creates these files in the build/ directory:
index.html- Main HTML file*.js- JavaScript runtime files*.wasm- WebAssembly binary*.pck- Godot data package
- Workflow fails on export: Check that
export_presets.cfgis committed to the repository - Pages not updating: Ensure GitHub Pages source is set to "GitHub Actions"
- Permission errors: Verify workflow permissions are set correctly
- Go to Actions tab in your repository
- Click on the latest workflow run
- Check each step for detailed logs and error messages
- The workflow only deploys from the main/master branch
- Build artifacts are temporary and cleaned up automatically
- No sensitive information should be included in the exported game
-
C# Scripts Not Compiling
- Ensure Godot 3.6 with Mono support is installed
- Check that .NET Framework 4.7.2 is installed
- Try Build > Rebuild Project
-
WebGL Export Issues
- Ensure you have the HTML5 export templates installed
- Check that the export path is correct
- Verify browser supports WebGL
-
Performance Issues
- The project uses OpenGL ES 2.0 for maximum compatibility
- Consider optimizing textures and reducing draw calls
- Test on different devices and browsers
- This project is configured for Godot 3.6 specifically
- C# scripts use .NET Framework 4.7.2 for WebGL compatibility
- The project uses OpenGL ES 2.0 renderer for broad device support
- Export presets are pre-configured for optimal WebGL deployment
This project template is provided as-is for educational and development purposes.