btc: Rewrite module in moonscript, just because