English | 日本語
crisp-game-lib
is a JavaScript library for creating browser games quickly and easily.
Download docs/getting_started/index.html.
Open index.html
in a text editor and write the code of your game in the <script>
element.
Open index.html
in a browser and play the game.
You can publish the game by putting index.html
on your web server.
Clone or download this repository.
npm install
Copy the docs/_template
directory and rename it to docs/[your own game name]
.
Open docs/[your own game name]/main.js
with the editor (VSCode is recommended) and write your own game code.
npm run watch_games
Open the URL http://localhost:4000?[your own game name]
with a browser to play the game. The page is live-reloaded when the code is rewritten.
Place main.js
, docs/bundle.js, and docs/index.html on the webserver in the following directory structure.
┝ [games root directory (any name)]
┝ [your own game name]
│ └ main.js
┝ bundle.js
└ index.html
Open the URL [Address of games root directory]/index.html?[your own game name]
with a browser.
If you want to build a game using a bundler (e.g. Vite), do the following.
npm install crisp-game-lib
at your project directory.
Copy docs/_template_bundler/index.html and docs/_template_bundler/main.js to your project directory.
Write game code in main.js
.
Build with the bundler.
If you want to describe the game using TypeScript, rename main.js
to main.ts
.
Kenta Cho’s “Crisp Game Lib” Games, written by Terry Cavanagh, known as the developer of Super Hexagon and VVVVVV
Guide to getting started with CrispGameLib, written by Juno Nguyen
crisp-game-lib, a game library for creating mini-games with minimal effort
color("transparent")
, you can get the result of collision detection without drawing any shape on the screen.title
and description
strings. If you want to use seed
in options
to adjust the generated sound, it is better to do so after the title
and description
are fixed.simple
or dark
theme. Do not specify a theme that uses pixi.js (pixel
, shape
, shapeDark
, crt
) in options. WebGL post-effects may worsen performance.sss.playMml()
function.Generated using TypeDoc