removed unused arguments; fixed potential buffer overflow
Unfortunately I have to devote my time elsewhere for the time being.

I will continue to work on this in the future, as it's lots of fun.
Nevertheless, here is my work thus far.