Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Extract file name from called ROM
- gname="$(basename "$3")"
- # build path to file and remove extension from ROM to add mp4 extension
- # $HOME variable will help users that are not stick to raspberry ;)
- ifgame="$HOME/RetroPie/videoloadingscreens/${gname%.*}.mp4"
- ifsystem="$HOME/RetroPie/videoloadingscreens/$1.mp4"
- default="$HOME/RetroPie/videoloadingscreens/default.mp4"
- # If condition to check filename with -f switch, f means regular file
- if [[ -f $ifgame ]]; then
- cvlc --quiet --fullscreen --play-and-exit "$ifgame" > /dev/null 2>&1
- elif [[ -f $ifsystem ]]; then
- cvlc --quiet --fullscreen --play-and-exit "$ifsystem" > /dev/null 2>&1
- elif [[ -f $default ]]; then
- cvlc --quiet --fullscreen --play-and-exit "$default" > /dev/null 2>&1
- fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement