simpleparticlesystem.pde
来自「This is processing for java examples.」· PDE 代码 · 共 28 行
PDE
28 行
/** * Simple Particle System * by Daniel Shiffman. * * Particles are generated each cycle through draw(), * fall with gravity and fade out over time * A ParticleSystem object manages a variable size (ArrayList) * list of particles. */ ParticleSystem ps;void setup() { size(640, 360); colorMode(RGB, 255, 255, 255, 100); ps = new ParticleSystem(1, new PVector(width/2,height/2,0)); smooth();}void draw() { background(0); ps.run(); ps.addParticle(mouseX,mouseY);}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?