krot

cs install

Nov 2nd, 2019
449
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 2.17 KB | None | 0 0
  1. apt-get update
  2. apt-get install unzip -y
  3. apt-get install expect -y
  4.  
  5. sudo dpkg --add-architecture i386
  6. sudo apt-get update
  7. sudo apt-get install lib32gcc1
  8.  
  9.  
  10. # Counter strike
  11. mkdir server ; mkdir steamcmd ; cd steamcmd
  12. wget http://media.steampowered.com/installer/steamcmd_linux.tar.gz
  13. tar -xvzf steamcmd_linux.tar.gz
  14.  
  15. expect -c 'set timeout 9999; \
  16. spawn ~/steamcmd/steamcmd.sh; \
  17. expect "Steam>" { send "login anonymous\r" }; \
  18. expect "Steam>" { send "force_install_dir ../hlds\r" }; \
  19. expect "Steam>" { send "app_update 90 validate\r" }; \
  20. expect "Steam>" { send "app_update 90 validate\r" }; \
  21. expect "Steam>" { send "exit" }'
  22.  
  23. # Metamod
  24. cd ~/hlds/cstrike
  25. wget https://www.amxmodx.org/release/metamod-1.21.1-am.zip
  26. unzip metamod-1.21.1-am.zip
  27. touch ~/hlds/cstrike/addons/metamod/plugins.ini
  28. cd ~/hlds/cstrike
  29. echo 'gamedll_linux "addons/metamod/dlls/metamod.so"' >> liblist.gam
  30.  
  31.  
  32. # AMMmodx
  33. wget https://www.amxmodx.org/release/amxmodx-1.8.2-base-linux.tar.gz
  34. tar xzvf amxmodx-1.8.2-base-linux.tar.gz
  35.  
  36. wget http://www.amxmodx.org/amxxdrop/1.10/amxmodx-1.10.0-git5217-cstrike-linux.tar.gz
  37. tar xzvf amxmodx-1.10.0-git5217-cstrike-linux.tar.gz
  38. echo "linux addons/amxmodx/dlls/amxmodx_mm_i386.so" >> ~/hlds/cstrike/addons/metamod/plugins.ini
  39.  
  40. # dProto
  41. cd ~/hlds/cstrike/addons/
  42. mkdir dproto ; cd dproto
  43. wget http://www.amxmodx.lt/installer_files/dproto_i386.so
  44. cd ~/hlds/cstrike/addons/
  45. wget http://www.amxmodx.lt/installer_files/dproto.cfg
  46. echo "linux addons/dproto/dproto_i386.so" >> ~/hlds/cstrike/addons/metamod/plugins.ini
  47.  
  48.  
  49. # Setup play script
  50. cd ~/hlds
  51. ./hlds_run -game cstrike +ip 0.0.0.0 +maxplayers 12 +map de_dust2
  52. ./hlds_run -nomaster -game cstrike -port 26756 +ip 0.0.0.0 -insecure
  53.  
  54. echo -e "cd /root/server && ./hlds_run -console -game cstrike -ip 0.0.0.0 -port 29015 +maxplayers 32 +map \${1-de_dust2}" > ~/play.sh
  55.  
  56.  
  57. chmod +x ~/play.sh
  58.  
  59. # Helpers
  60. ln -s /root/server/cstrike/maps /maps
  61.  
  62. # Start game to overcome THE BUG
  63. timeout 5 ~/play.sh
  64.  
  65. echo -e "\n----------------------------\nStart by running `~/play.sh [map]`\n----------------------------\n"
  66.  
  67.  
  68. --
  69. рабочий способ
  70. https://hub.docker.com/r/ggoulart/cs1.6-server-more-maps
Add Comment
Please, Sign In to add comment