Skip to content

jason80/dragonfly

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dragonfly

Interactive Fiction Game Engine in Javascript

Game sample

You can find some examples in the samples directory available in English.

Setting up the project

Clone the git repository with submodules:

git clone --recurse-submodules https://github.com/jason80/dragonfly/

Create and navigate mygame dir:

mkdir dragonfly/mygame
cd dragonfly/mygame

Create the files "index.html" and "mygame.js".

Basic "index.html":

<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<title>My Game</title>
</head>
<body>
	<div id="game-area"></div>
	<script type="module" src="mygame.js"></script>
</body>
</html>

File "mygame.js":

import { Book } from "../base/book.js"

window.onload = function() {
	const book = new Book("game-area");

	book.run();
}

Tutorial:

Español

About

Interactive Fiction Game Engine in Javascript

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published