-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathtpp
executable file
·61 lines (46 loc) · 1.46 KB
/
tpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#!/bin/sh
#Install virtualboy, get pokemon red ROM and launch pokemon
VBAM_PKG="vbam-wx" #choose wx version for no reason, change if some other version is better
VBAM_CMD="wxvbam"
#check if virtualboy advanced is installed (don't know if this is the best way)
x=`pacman -Qs $VBAM_PKG`
if [ -n "$x" ]
then
echo "VBAM is installed!"
else
echo "VBAM is not installed! installing.."
pacman -S $VBAM_PKG --noconfirm
fi
x=`pacman -Qs wget`
if [ -n "$x" ]
then
echo "wget is installed!"
else
echo "wget is not installed! installing.."
pacman -S wget --noconfirm
fi
#Also install zsh because i can't get bash to download the ROM file....
x=`pacman -Qs zsh`
if [ -n "$x" ]
then
echo "zsh is installed!"
else
echo "zsh is not installed! installing.."
pacman -S zsh --noconfirm
fi
#Virtualboy and zsh is now installed.
ROM_FILE=$HOME/roms/red.zip
if [ ! -f $ROM_FILE ] #Test if rom is already downloaded
then
#Make dir for rom file
mkdir $HOME/roms -p
#Download pokemon ROM
#uses zsh because i can't get it to work in bash with all the spaces, etc. Some bash-wizz should fix it.
zsh -c '
ROM_URL="https://www.loveroms.com/r/Gameboy Color/P-T/Pokemon - Red Version (UE)[!].zip"
wget $ROM_URL -O $HOME/roms/red.zip'
fi
#Define Virtualboy arguments
VBAM_ARGS="-f $ROM_FILE " #-f means fullscreen
#Run Virtualboy
$VBAM_CMD $VBAM_ARGS