mostly working redex thingy. calling it quits for tonight.