by now this is just a quick hack, so don't expect it to be too crazy about sanity checks and such

comments: