Premium Features

Download Video

How to Code: Particle Tunnels

Published a year ago

To achieve the effect of particles expanding outwards in ring formation, you need to know a little bit of trigonometry. The real question is, "How do you get particles to be placed evenly along the edge of a circle?" By using sine and cosine functions, you can return coordinates for each particle, where if you're increasing the radian value that goes into sine and cosine over time, you get different locations along a circle's edge. Using these values as a particles velocity, you can create a ring expansion effect, where if used correctly, gets the end result we're looking for.


Want to participate?

Create a free Chris Courses account to begin

Snigafurt posted 4 months ago
chris posted 4 months ago
Cheat Sheet Preview

Download The Official Chris Courses HTML5 Canvas Cheat Sheet

Essential canvas syntax at your fingertips.

Download Now

Providing the lift to launch your development career

ยฉ 2021 Chris Courses. All rights reserved.