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

tempe.three.proton.js

v1.0.0

Published

three.proton is a magical 3d particle engine using [three.js]

Downloads

8

Readme

three.proton

** This is a fork from https://github.com/a-jie/three.proton that I published on npm so I could use it in my project. I am not the original author. **

three.proton is a magical 3d particle engine using three.js. It is based on the Proton Engine library. It inherited Proton's most api. I think it is the simplest three.js particle engine.Check out examples at https://a-jie.github.io/three.proton/

Features

  • Four kinds of renderers

    • MeshRender
    • SpriteRender
    • PointsRender
    • CustomRender
  • Three kinds of emitters which can simulate many different physical effects

    • Emitter
    • BehaviourEmitter
    • FollowEmitter
  • Perfectly compatible with the three.js library.

It was very, very easy to use

Installation

Install using npm

anix

npm install three.proton.js --save
... 
import Proton from 'three.proton.js';

Include in html

<script type="text/javascript" src="js/three.proton.min.js"></script> 

Usage

var proton = new Proton();
var emitter = new Proton.Emitter();

//setRate
emitter.rate = new Proton.Rate(new Proton.Span(4, 16), new Proton.Span(.01));

//addInitialize
emitter.addInitialize(new Proton.Position(new Proton.PointZone(0, 0)));
emitter.addInitialize(new Proton.Mass(1));
emitter.addInitialize(new Proton.Radius(6, 12));
emitter.addInitialize(new Proton.Life(3));
emitter.addInitialize(new Proton.V(45, new Proton.Vector3D(0, 1, 0), 180));

//addBehaviour
emitter.addBehaviour(new Proton.Alpha(1, 0));
emitter.addBehaviour(new Proton.Scale(.1, 1.3));

var color1 = new THREE.Color();
var color2 = new THREE.Color();
var colorBehaviour = new Proton.Color(color1, color2);
emitter.addBehaviour(colorBehaviour);
emitter.emit();

//add emitter
proton.addEmitter(emitter);

//add renderer
proton.addRender(new Proton.SpriteRender(scene));

Building three.proton

Node is a dependency, use terminal to install it with with: git clone git://github.com/a-jie/three.proton.git Then navigate to the build directory by running: cd ./build Finally run the build command: node build.js

License

Proton is released under the MIT License. http://www.opensource.org/licenses/mit-license