Skip to content

Instantly share code, notes, and snippets.

@rolandoislas
Last active March 2, 2016 17:22
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rolandoislas/92edb90a9b130ca076d1 to your computer and use it in GitHub Desktop.
Save rolandoislas/92edb90a9b130ca076d1 to your computer and use it in GitHub Desktop.
Smite Install script for PlayOnLinux/PlayOnMac
#!/usr/bin/env playonlinux-bash
# A PlayOnLinux/Mac install script for SMITE.
# Date : (2015-08-18)
# Last revision : (2015-10-08 03:50)
# Wine version used : 1.7.47
# Distribution used to test : Xubuntu 14.04, OS X 10.11
# Licence : GPLv3
# Author : Rolando Islas
[ "$PLAYONLINUX" = "" ] && exit 0
source "$PLAYONLINUX/lib/sources"
TITLE="SMITE"
PREFIX="Smite"
WINEVERSION="1.7.47"
POL_SetupWindow_Init
POL_Debug_Init
POL_SetupWindow_presentation "$TITLE" "Hi-Rez Studios" "http://www.smitegame.com/" "Rolando Islas" "Smite"
POL_SetupWindow_InstallMethod "DOWNLOAD,LOCAL"
if [ "$INSTALL_METHOD" = "LOCAL" ]; then
cd "$HOME"
POL_SetupWindow_browse "$(eval_gettext 'Please select the setup file to run.')" "$TITLE" "" "Windows Executables (*.exe)|*.exe;*.EXE"
FULL_INSTALLER="$APP_ANSWER"
else
POL_System_TmpCreate "$PREFIX"
DOWNLOAD_URL="http://hirez.http.internapcdn.net/hirez/InstallSmite.exe"
DOWNLOAD_MD5="e35f14fda81d910a7407c7fc2e19212b"
DOWNLOAD_FILE="$POL_System_TmpDir/$(basename "$DOWNLOAD_URL")"
POL_Call POL_Download_retry "$DOWNLOAD_URL" "$DOWNLOAD_FILE" "$DOWNLOAD_MD5" "$TITLE installer"
FULL_INSTALLER="$DOWNLOAD_FILE"
fi
POL_System_SetArch "x86"
POL_Wine_SelectPrefix "$PREFIX"
POL_Wine_PrefixCreate "$WINEVERSION"
if [ "$POL_OS" = "Linux" ]; then
POL_Call POL_Function_RootCommand "echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope; exit"
fi
POL_Call POL_Install_d3dx10
POL_Call POL_Install_d3dx11
POL_Call POL_Install_d3dx9_43
POL_Call POL_Install_directx9
POL_Call POL_Install_dotnet35sp1
POL_Call POL_Install_dotnet40
POL_Call POL_Install_flashplayer
POL_Call POL_Install_gdiplus
POL_Call POL_Install_vcrun2008
POL_Call POL_Install_vcrun2010
POL_Call POL_Install_xact
Set_OS "win7"
POL_Wine_WaitBefore "$TITLE"
POL_Wine "$FULL_INSTALLER"
Set_OS "winxp"
POL_Call POL_Function_OverrideDLL builtin,native dnsapi
POL_Shortcut "HiRezLauncherUI.exe" "$TITLE" "" "game=300 product=17"
if [ "$INSTALL_METHOD" = "DOWNLOAD" ]; then
POL_System_TmpDelete
fi
POL_SetupWindow_Close
exit
#!/bin/bash
# A utilities script that aids in the editing of SMITE setting without being in game.
# Date : (2015-10-08)
# Last revision : (2015-10-08 3:50)
# Licence : GPLv3
# Author : Rolando Islas
SETTING_PATH="$HOME/Documents/My Games/Smite/BattleGame/Config/BattleSystemSettings.ini"
RESULT="\n"
clear
echo -e "This script will aid in the editing of SMITE's settings.\n"
function setFullscreen {
RESULT="$RESULT fullscreen: $1\n"
sed -i '' -E "s/Fullscreen=.*/Fullscreen=$1/" "$SETTING_PATH"
}
function setBorderless {
RESULT="$RESULT borderless: $1\n"
sed -i '' -E "s/Borderless=.*/Borderless=$1/" "$SETTING_PATH"
}
function setResolution {
RESULT="$RESULT resolution: $1 $2\n"
sed -i '' -E "s/ResX=.*/ResX=$1/" "$SETTING_PATH"
sed -i '' -E "s/ResY=.*/ResY=$2/" "$SETTING_PATH"
}
function run {
echo -e "Settings found at '$SETTING_PATH'.\n"
echo "Enable fullscreen?"
select yn in "Yes" "No"; do
case $yn in
Yes ) setFullscreen true; fullscreen=true; break;;
No ) setFullscreen false; fullscreen=false; break;;
esac
done
if [[ $fullscreen = false ]]; then
echo "Enable borderess window?"
select yn in "Yes" "No"; do
case $yn in
Yes ) setBorderless true; break;;
No ) setBorderless false; break;;
esac
done
fi
read res <<<$(system_profiler SPDisplaysDataType | grep Resolution | grep -oE -m1 '[0-9]{3,}')
echo "Suggested resolution: $res"
read -p "Enter desired X resolution: " x
read -p "Enter desired Y resolution: " y
if [[ -n $x ]] && [[ -n $y ]]; then
setResolution $x $y
fi
echo "The follwoing settings have been applied:"
echo -e $RESULT
}
if [[ -f "$SETTING_PATH" ]]; then
run
else
echo -e "Settings not found in '$SETTING_PATH'.\nLaunch SMITE at least once to generate the file."
fi
@forntonio
Copy link

I'm on Linux, after running the script and downloading Smite, the launcher says "Smite is damaged and needs to repair", what should I do?

EDIT: After validating twice it works..

@FlaskNField
Copy link

Hi, I'm having issues here. I run script via terminal. Click next. Click Download the program. Says "Please wait while PlayonLinux downloads: Smite installer. Then error message reads.. "Download seems corrupted. Retry?". I've retryed a few times and rebooted and tried again. Using Ubuntu and I've already run apt-get update and upgrade. Any thoughts? Thanks!

@rolandoislas
Copy link
Author

@Z3R0D4Y94 I need to check, but I believe the issue is with the installer being updated by Hi-Rez, so the checksum is different. If you download it separately and choose run it from the installer, it should work.

@rolandoislas
Copy link
Author

The script has been moved to a regular GitHub repo: https://github.com/rolandoislas/SmiteInstallScriptPOL.

_Please sumbit further issues there._

@mrmacaroon
Copy link

On patch 3.1 it says smite needs a repair? help please

@robinleruth
Copy link

Hi, I'm on fedora 23, the installation ran smoothly but at the end it says smite needs to be fixed.
I clicked on "fix" and then on "validate", then only i could play !

Great script ! I've been waiting to play Smite for 2 years (since I switched on linux), great work :)

@nagasadhu
Copy link

I am getting error while installing Xact dll

Error in source
Error 3 registering DLL /home/rushikesh/.PlayOnLinux//wineprefix/Smite/drive_c/windows/system32/xaudio2_0.dll

Can you please help??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment