[HAMMER] Compilation: Compress map to .bz2 and upload to "fastdownload"

Avaray

L2: Junior Member
Oct 14, 2011
72
4
1. Compress map to .bz2 (Bzip2)
  • Download Bzip2 from OFFICIAL LINK
  • Extract it in safe place (not to desktop)
  • Press F9 in Hammer and add new command (1)
  • Add path for bzip2 executable (2)
  • Add parameters (3)
    Code:
    -kf $path\$file.bsp
    -kf will keep original .bsp file and will overwrite existing .bz2 file
It will look like this:
bzip_exe_hammer.jpg


2. Upload compressed map to your web server (aka fastdownload)
  • Download WinSCP Portable executables from OFFICIAL WEBSITE
  • Extract it in safe place (not to desktop)
  • Press F9 in Hammer and add new command (1)
  • Add path for WinSCP executable (2)
  • IMPORTANT! In that path change .exe extension for .com (like on picture below)
  • Add parameters (3)
    Code:
    /command "open ftp://USER:PASS@tf2maps.net/" "put "$path\$file.bsp.bz2" /path/to/directory/" "exit"

    USER = username for your FTP account
    PASS = password for your FTP account
    tf2maps.net = your host address (domain or IP)
    /path/to/directory/ = path to your remote directory (where compressed map will be uploaded)
It will look like this:
winscp_exe_hammer.jpg


3. DONE!

PS. If durning compilation you will get error message like "Cant get access to disk" or "Cant find directory" that probably means you need to run Hammer with administrator privileges.
 
Last edited:

zahndah

professional letter
aa
Jul 4, 2015
721
642
Most likely you are right, I dont really know about this.
 

Crash

func_nerd
aa
Mar 1, 2010
3,315
5,499
Im 99% sure that you Need to have maps compressed to .bz2 to use sv_downloadurl (to allow people download maps from HTTP server).
Without compression .bsp files will be downloaded from Game Server.
You dont need to compress maps if you are making maps for Steam Workshop.

This is no longer the case as of a (somewhat) recent update. Bz2 is an outdated form of map compression, repacking is the new method used by the steam workshop, and you can do it manually with the instructions in the link zahndah posted above. I haven't bz2'd a release in a long time, and have had no issues with fast download servers hosting it.