#!/bin/bash # Script d'installation et de configuration automatisé pour CS 1.6 Lan, avec Wine sur Linux # Il faut posséder les fichiers suivants : # - cslan-HL143lite.exe # - cslan-CS16lan.exe # - cslan-pack_amx3.exe # - cslan-patch143.exe # Fonction config qui peut aussi etre appelée par 'install-linux.sh cfg' config() { read -n1 -p "Configurer la partie ? (O/n)" ch case $ch in o|O) echo;; n|N) echo;; *) echo MAUVAIS CHOIX.; exit;; esac exit } if [ $1 = cfg ]; then config; fi if [ ! -f /usr/bin/wine ] then read -n1 -p "Wine n'est pas installé. Voulez vous l'installer maintenant ? (O/n)" ch case $ch in o|O) if [ -f /usr/bin/pacman ]; then sudo pacman -Sy wine --noconfirm; fi if [ -f /usr/bin/apt ]; then sudo apt update; sudo apt -y install wine; fi if [ -f /usr/bin/emerge ]; then sudo emerge wine; fi if [ -f /usr/bin/yum ]; then sudo yum -y wine; fi ;; n|N) exit;; *) echo Mauvais choix.; exit;; esac fi if [ -f /usr/bin/pacman ] && [ ! -d /usr/lib32/gstreamer-1.0 ]; then sudo pacman -Sy --noconfirm lib32-gst-plugins-base; fi echo Installation de Half Life 1.4.3 Lite... env WINEPREFIX=~/.cslan wine cslan-HL143lite.exe > /dev/null echo Installation de Counter Strike 1.6 LAN... env WINEPREFIX=~/.cslan wine cslan-CS16lan.exe > /dev/null echo Installation du Pack AMX v3... env WINEPREFIX=~/.cslan wine cslan-pack_amx3.exe > /dev/null echo Installation du Patch nosteam... env WINEPREFIX=~/.cslan wine cslan-patch143.exe > /dev/null echo Activation de la console avec la touche L... echo "bind \"l\" \"toggleconsole\"" > "~/.cslan/drive_c/Program Files (x86)/Valve Lan/cstrike/userconfig.cfg" echo echo "GO LAAAAAAAAAAAN !!!! :D" echo