emitter.js

total 0
used 0
limit 0
/* title: Emitter category: emitter files: ../point_src/core/head.js ../point_src/pointpen.js ../point_src/pointdraw.js ../point_src/math.js ../point_src/point-content.js ../point_src/pointlistpen.js ../point_src/pointlist.js ../point_src/point.js ../point_src/events.js ../point_src/automouse.js ../point_src/functions/clamp.js ../point_src/random.js ../point_src/distances.js ../point_src/dragging.js ../point_src/stage.js ../point_src/setunset.js ../point_src/stroke.js ../point_src/relative.js ../point_src/velocity.js ../point_src/emitter.js --- */ class MainStage extends Stage { canvas = 'playspace' mounted(){ this.point = new Point(100, 100, 20) // this.events.wake() this.e1 = new Emitter(200,200, 80) this.e1.wake() let e2 = new Emitter(400,400, 60) e2.direction = {x:-1, y:0} //inward. e2.fromEdge = true e2.tickModulo = 10 e2.wake() this.e2 = e2 // let e3 = new Emitter(500,200, 60) let e3 = new Emitter(500,200, 60) e3.fromEdge = true e3.tickModulo = 10 e3.birthrate = 1 e3.lifetime = 200 e3.wake() this.e3 = e3 this.dragging.add(this.e1, e2, e3) } draw(ctx){ this.clear(ctx) let es = [this.e1, this.e2, this.e3] es.forEach(e=>{ e.step() e.rotation += 1 // e.lookAt(this.mouse.point) e.pen.circle(ctx) e.points.pen.indicators(ctx) }) this.point.pen.fill(ctx, '#880000') } } stage = MainStage.go(/*{ loop: true }*/)
Run
Meta Data
title Emitter
imports ()
files ('../point_src/core/head.js', '../point_src/pointpen.js', '../point_src/pointdraw.js', '../point_src/math.js', '../point_src/point-content.js', '../point_src/pointlistpen.js', '../point_src/pointlist.js', '../point_src/point.js', '../point_src/events.js', '../point_src/automouse.js', '../point_src/functions/clamp.js', '../point_src/random.js', '../point_src/distances.js', '../point_src/dragging.js', '../point_src/stage.js', '../point_src/setunset.js', '../point_src/stroke.js', '../point_src/relative.js', '../point_src/velocity.js', '../point_src/emitter.js')
unused_keys ()
unknown_keys ('category',)
category ['emitter']
filepath_exists True
path emitter.js
filepath emitter.js
clean_files ('../point_src/core/head.js', '../point_src/pointpen.js', '../point_src/pointdraw.js', '../point_src/math.js', '../point_src/compass.js', '../point_src/center.js', '../point_src/point-content.js', '../point_src/pointlistpen.js', '../point_src/pointlistdraw.js', '../point_src/pointlistgradient.js', '../point_src/pointlistshape.js', '../point_src/pointlistgenerator.js', '../point_src/unpack.js', '../point_src/pointlist.js', '../point_src/relative-xy.js', '../point_src/pointcast.js', '../point_src/point.js', '../point_src/events.js', '../point_src/automouse.js', '../point_src/functions/clamp.js', '../point_src/random.js', '../point_src/distances.js', '../point_src/protractor.js', '../point_src/text/beta.js', '../point_src/dragging.js', '../point_src/stage-resize.js', '../point_src/functions/resolve.js', '../point_src/stage.js', '../point_src/setunset.js', '../point_src/stroke.js', '../point_src/relative.js', '../point_src/velocity.js', '../point_src/emitter.js')
markdown {'html': '<hr />', 'content': 'title: Emitter\ncategory: emitter\nfiles:\n ../point_src/core/head.js\n ../point_src/pointpen.js\n ../point_src/pointdraw.js\n ../point_src/math.js\n ../point_src/point-content.js\n ../point_src/pointlistpen.js\n ../point_src/pointlist.js\n ../point_src/point.js\n ../point_src/events.js\n ../point_src/automouse.js\n ../point_src/functions/clamp.js\n ../point_src/random.js\n ../point_src/distances.js\n ../point_src/dragging.js\n ../point_src/stage.js\n ../point_src/setunset.js\n ../point_src/stroke.js\n ../point_src/relative.js\n ../point_src/velocity.js\n ../point_src/emitter.js\n\n\n---'}