Revamped the entire thing to add on dynamic stacks.  It's messy code, but I'll clean it up.