floaty is a JavaScript port of Pico-8 which aims for feature parity (with deviations in implementation where appropriate). I created floaty so that I could teach JavaScript to non-coders without all the boilerplate it takes to go from an empty document to a working game.

I hope that it gets to the point where I can follow any Pico-8 tutorial by using the corresponding JavaScript functions and data types. I hope that it gets to the point where anyone can build a game by pasting a script tag in their HTML document and starting to code.

Showcase

Platformer (WIP) by assertchris
OinkPop (WIP) by assertchris
Minesweeper (WIP) by assertchris

Getting Started

Here's a tiny example of some of the code you'll need to make a game:

import { Engine } from 'https://floaty.dev/engine-v1.js';

var engine = new Engine();
engine.expose();

var sprites = {
    // this is where your sprites go
};

var sounds = {
    // this is where your sounds go
};

function init() {
    // things to do when the game starts
}

function update() {
    // things to do each game tick:
    // updating the game state
    // moving the player
    // handling input
}

function draw() {
    // things to do each time the screen updates:
    // - clearing the canvas
    // - drawing on the canvas
}

engine.start({
    sprites,
    sounds,
    init,
    update,
    draw,
});

// code: https://codepen.io/assertchris/pen/yLZMVGO

Roadmap

  • Allow users to change their profile URL in the asset editor.
  • Add music to assets editor + engine.
  • Add maps to assets editor + engine.
  • Add camera functions to engine.
  • Make video + text tutorials for various games.

Timeline

July 2023 - October 2023
October 2023 - November 2023
December 2023 - Now
  • Add SFX to the assets editor
  • Improve documentation around sfx
floaty is developed by assertchris as part of sandcastle.games