Particles randomly move until touching a stationary particle. Over time particles form a tree-like fractal shape.
first difference: instead of spawning a ton of particles at once, this version just spawns a single particle at a time, which means there is no risk of two particles intersecting each other second difference: instead of choosing a direction to go and bouncing off the edges until the particle collides with a color, this version calculates the distance to the DLA and advances that distance in a random direction, both of these are done every tick. Sort of like ray marching, but not really. All this means that I had to store all particles that already belong to the DLA in a list and then check against all of them to see which one is the closest, and this is pretty inefficient, especially when the particle size is 1. It is possible to use a quadtree to speed this up, but actually doing that in scratch is a sign you truly hate yourself. and, in fact, the way that all this is being done in this version is the most accurate according to the definition of a DLA if you consider brownian motion to be a random walk in a 2D continuous plane third difference: since I needed to know the radius of the particles in pixels, I changed the size of the sprites so that their radius is 1 pixel at 100% size, which made it possible to calculate everything properly