quick provides a multi-platform, lightweight, easy-to-use framework for 2D game development, focused in performance, fast development and maintainability. Based on the original engine used in titles that pioneered the HTML5 game scene, it has evolved with the continuous addition of new features and improvements.
Check the wiki-based API docs.
- Virtual resolution - run your game in any screen size without affecting your development or game logic
- Accessible - play with a common user interface for gamepad, keyboard, mice or touch screen
- Complete - no further dependencies required
- Easy to use - rich, well defined API that feels natural to game development
- Agnostic - whether you want to write your game with OOP or functional code, the choice is yours
- Open - free to use, read, and extend it. Enjoy!
Please check the Wiki for more information.
These are some games made with quick (in alphabetical order):
- Colda Kasar's Domain
- Cucurbita's Halloween
- Fighter Champion
- Missile Commander
- Super Breakout Bros
Please get your games made with quick listed here!
How to use
All you need is to add quick to your HTML file and make sure you have a canvas element somewhere in your page.
For a quick start: first, grab the latest skeleton project, which will get you productive as soon as possible.
The skeleton provide a sample quick project with an initial Scene, a black background and a player Sprite with the Controllable plugin, so you can move it with the keyboard or a gamepad. Make sure you check the Wiki and demos and plugins to harness the full potential of the library.
The input subsystem dynamically attaches physical devices such as gamepads, keyboards, mice and touch screens to virtual devices. Gamepads and keyboards are known to the game as controllers via the Controller class, while mice and touch screens are known to the game as pointers, via the Pointer class. Games can use one or more devices, such as a controller and a pointer to command a more complex game or even multiple controllers for multiplayer games.
In order to be accessible and ergonomic to the majority of players without configuration hassles, quick convenes to a common set of commands. which are:
These commands can be easily referenced to using the [[Command]] enumeration. Physical devices which implement [[Controller]] then map to these commands, as follows:
The keyboard mapping allows both left and right handed players to use a comfortable set of keys:
- Up arrow, E or I - Up
- Down arrow, D or K - Down
- Left arrow, S or J - Left
- Right arrow, F or L - Right
- Space - A
- Alt - B
- Ctrl - X
- Shift - Y
- Esc - Select
- Enter - Start
The gamepad mapping allows both digital and analog controls to be properly mapped to a game command:
- Up (digital / analog) - Up
- Down (digital / analog) - Down
- Left (digital / analog) - Left
- Right (digital / analog) - Right
- A or 1 - A
- B or 2 - B
- X or 3 - X
- Y or 4 - Y
- Select - Select
- Start - Start
While mice and touch screens have different capabilities, they share a few common concepts which we can leverage to interact them in an uniform way. Bot can provide clicks and position coordinates.
Click here for the full list of projects including reusable assets, demos and plugins.