Loading...
Loading...
Expert skill for building web-based game engines and games using HTML5, Canvas, WebGL, and JavaScript. Use when asked to create games, build game engines, implement game physics, handle collision detection, set up game loops, manage sprites, add game controls, or work with 2D/3D rendering. Covers techniques for platformers, breakout-style games, maze games, tilemaps, audio, multiplayer via WebRTC, and publishing games.
npx skill4agent add github/awesome-copilot game-enginerequestAnimationFrame<canvas>requestAnimationFrameassets/| Template | Description |
|---|---|
| 2D Breakout-style game with pure JavaScript |
| Maze game with device orientation controls |
| Platformer game using Phaser framework |
| Game base template repository structure |
| Simple 2D platformer engine with collisions |
references/| Reference | Topics Covered |
|---|---|
| Game development introduction and anatomy |
| Canvas, WebGL, Web Audio, Gamepad, and other web APIs |
| Collision detection, tilemaps, async scripts, audio |
| 3D theory, frameworks, shaders, WebXR |
| Touch, keyboard, mouse, and gamepad controls |
| Distribution, promotion, and monetization |
| Raycasting, collision, physics, vector math |
| Game development glossary |
| Core design principles for game engines |
| Issue | Solution |
|---|---|
| Canvas is blank | Check that you are calling drawing methods after getting the context and inside the game loop |
| Game runs at different speeds | Use delta time in update calculations instead of fixed values |
| Collision detection is inconsistent | Use continuous collision detection or reduce time steps for fast-moving objects |
| Audio does not play | Browsers require user interaction before playing audio; trigger playback from a click handler |
| Performance is poor | Profile with browser dev tools, reduce draw calls, use object pooling, and optimize asset sizes |
| Touch controls are unresponsive | Prevent default touch behavior and handle touch events separately from mouse events |
| WebGL context lost | Handle the |