thanks Tindust, for caring - but the function was ok, just a typo.
@jcl - yes, that would be nice if you'll have a look on that. I can send you the resource (in fact I had the same idea you had - and tested various ones). Maybe experimanting with that may help. Desperately as I was I began to write my own packer format...