Haxelib (Option 1)
OpenFL is available to install from Haxelib. It supports HTML5, native desktop, native mobile, AIR and Flash development from a single toolset and the Haxe programming language.
To get started, install Haxe globally on your system.
With the latest versions of Haxe and Neko installed, open a command-prompt (Windows) or terminal (macOS/Linux) and run these commands:
In order to check if OpenFL has been installed properly, try running the
Run a Sample
You can use the "openfl create" command for a list of available samples.
For example, here is how to build and run the DisplayingABitmap sample on HTML5:
NPM (Option 2)
If you would like to use OpenFL for a web-only project, OpenFL is also available on npm.
Start by installing Node.js and npm globally.
Then, install Yeoman for generating a new OpenFL project:
Run a Sample
There are many OpenFL samples you can try, depending on the code environment you wish to use:
Choose a sample, then
npm install and
npm start in the local directory to start a development server (with hot-reloading enabled):
If you do not have a code editor already, Visual Studio Code is a good choice for that integrates well with OpenFL and NPM.
If you have any questions or concerns when you are installing OpenFL, do not hesitate to visit our friendly community forums. Thank you for trying OpenFL, and please let us help if you have any problems at all.