npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

superpowers-game-datgui-plugin

v0.4.0

Published

Exposes the dat.GUI library to the Typescript API of the Superpowers Game system for Superpowers, the extensible HTML5 2D+3D game engine.

Downloads

9

Readme

Superpowers Game dat.GUI plugin

This plugin allows to use the dat.GUI library inside the games mades with the Superpowers Game system for Superpowers, the extensible HTML5 2D+3D game engine.

A lightweight graphical user interface for changing variables in JavaScript.

Get started with dat.GUI by reading the tutorial at http://workshop.chromeexperiments.com/examples/gui.

You can use dat.GUI in Superpowers exactly as in any Javascript application.

Despite having few interests for a shipped game, dat.GUI can be used as a a very fast way to create debug/placeholder menus in no time.

var menu = {
  FirstScene: function() {
    Sup.loadScene( <Sup.Scene>Sup.get("My First Scene") );
  },
  OtherScene: function() {
    Sup.loadScene( Sup.get("My Other Scene", Sup.Scene) );
  },
  doOtherGameStuff: Game.doOtherStuff 
  // Game.doOtherStuff() is defined somewhere else...
};

var gui = new dat.GUI();
gui.add( menu, "FirstScene" );
gui.add( menu, "OtherScene" );
gui.add( menu, "doOtherGameStuff" );

Note that the plugin uses a fork of dat.GUI that adds new features useful for Superpowers.

The ease of creation and use of dat.GUI's UIs also makes it a good candidate to power a UI for asset editors for instance.

Documentation

http://florentpoujol.github.io/superpowers-game-datgui-plugin.
It adds a bare-bone API in addition to this readme.

You can also access the documentation offline in the plugin's public/docs folder or via the "Plugins documentation" tool provided by the Plugins documentation plugin.

Installation

Download the latest release, unzip it, rename the folder to dat-gui, move it inside app/systems/supGame/plugins/florentpoujol/ then restart your server.

Advanced:

Get it via npm:

cd app/systems/supGame/plugins
npm install superpowers-game-datgui-plugin

The name of the vendors or plugins in the app/systems/supGame/plugins/ folder don't matter.
So you can leave the plugin path as node_modules/superpowers-game-datgui-plugin.