Changed constants and ZLIB usage