Add Citrasa ES features.

This commit is contained in:
mason 2023-01-03 14:37:08 +00:00
parent 0a728e10d3
commit 607c422776
No known key found for this signature in database
GPG key ID: 84D9278A11FA112B
2 changed files with 80 additions and 0 deletions

View file

@ -10,6 +10,69 @@ if [ ! -d "/storage/.config/citra-emu" ]; then
cp -r "/usr/config/citra-emu" "/storage/.config/"
fi
#Move sdmc & nand to 3ds roms folder
if [ ! -d "/storage/roms/3ds/citrasa/sdmc" ]; then
mkdir -p "/storage/roms/3ds/citrasa/sdmc"
fi
rm -rf /storage/.config/citra-emu/sdmc
ln -sf /storage/roms/3ds/citrasa/sdmc /storage/.config/citra-emu/sdmc
if [ ! -d "/storage/roms/3ds/citrasa/nand" ]; then
mkdir -p "/storage/roms/3ds/citrasa/nand"
fi
rm -rf /storage/.config/citra-emu/nand
ln -sf /storage/roms/3ds/citrasa/nand /storage/.config/citra-emu/nand
#Emulation Station Features
GAME=$(echo "${1}"| sed "s#^/.*/##")
RES=$(get_setting resolution_scale 3ds "${GAME}")
SLAYOUT=$(get_setting screen_layout 3ds "${GAME}")
#Resolution Scale
if [ "$RES" = "0" ]
then
sed -i '/resolution_factor =/c\resolution_factor = 0' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$RES" = "1" ]
then
sed -i '/resolution_factor =/c\resolution_factor = 1' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$RES" = "2" ]
then
sed -i '/resolution_factor =/c\resolution_factor = 2' /storage/.config/citra-emu/sdl2-config.ini
fi
#Screen Layout
if [ "$SLAYOUT" = "0" ]
then
sed -i '/layout_option =/c\layout_option = 0' /storage/.config/citra-emu/sdl2-config.ini
sed -i '/swap_screen =/c\swap_screen = 0' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$SLAYOUT" = "1a" ]
then
sed -i '/layout_option =/c\layout_option = 1' /storage/.config/citra-emu/sdl2-config.ini
sed -i '/swap_screen =/c\swap_screen = 0' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$SLAYOUT" = "1b" ]
then
sed -i '/layout_option =/c\layout_option = 1' /storage/.config/citra-emu/sdl2-config.ini
sed -i '/swap_screen =/c\swap_screen = 1' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$SLAYOUT" = "2" ]
then
sed -i '/layout_option =/c\layout_option = 2' /storage/.config/citra-emu/sdl2-config.ini
sed -i '/swap_screen =/c\swap_screen = 0' /storage/.config/citra-emu/sdl2-config.ini
fi
if [ "$SLAYOUT" = "3" ]
then
sed -i '/layout_option =/c\layout_option = 3' /storage/.config/citra-emu/sdl2-config.ini
sed -i '/swap_screen =/c\swap_screen = 0' /storage/.config/citra-emu/sdl2-config.ini
fi
rm -rf /storage/.local/share/citra-emu
ln -sfv /storage/.config/citra-emu /storage/.local/share/citra-emu

View file

@ -200,6 +200,23 @@
</feature>
</features>
</emulator>
<emulator name="citrasa">
<features>
<feature name="resolution scale">
<choice name="Native 3DS" value="1"/>
<choice name="2x" value="2"/>
<choice name="3x" value="3"/>
<choice name="Max" value="0"/>
</feature>
<feature name="screen layout">
<choice name="top / bottom" value="0"/>
<choice name="top only" value="1a"/>
<choice name="bottom only" value="1b"/>
<choice name="big / small" value="2"/>
<choice name="side by side" value="3"/>
</feature>
</features>
</emulator>
<emulator name="retroarch" features="ratio, smooth, shaders, pixel_perfect, latency_reduction, game_translation">
<cores>
<core name="2048" features="netplay, rewind, autosave" />