Playing around with vectors…

Having to relearn a bit of math, I wish paid more attention in linear algebra!

Going from this (click for GIF):

intersect

…to this:

light2

At the moment it uses a relatively quick line-intersection algorithm which performs pretty well with two polygons, but I’ll have to see how it scales up with some more of them, heh.

Tags: gif, light, love2d, lua, progress