Skip to content
This repository has been archived by the owner on May 8, 2024. It is now read-only.

Update Drastic and MelonDS HK for Ace & set MelonDS as default #3058

Merged
merged 1 commit into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ controls_a[CONTROL_INDEX_A] = 32
controls_a[CONTROL_INDEX_B] = 480
controls_a[CONTROL_INDEX_X] = 122
controls_a[CONTROL_INDEX_Y] = 120
controls_a[CONTROL_INDEX_L] = 481
controls_a[CONTROL_INDEX_R] = 99
controls_a[CONTROL_INDEX_L] = 113
controls_a[CONTROL_INDEX_R] = 111
controls_a[CONTROL_INDEX_START] = 13
controls_a[CONTROL_INDEX_SELECT] = 485
controls_a[CONTROL_INDEX_HINGE] = 104
Expand All @@ -54,10 +54,10 @@ controls_a[CONTROL_INDEX_TOUCH_CURSOR_PRESS] = 65535
controls_a[CONTROL_INDEX_MENU] = 27
controls_a[CONTROL_INDEX_SAVE_STATE] = 115
controls_a[CONTROL_INDEX_LOAD_STATE] = 108
controls_a[CONTROL_INDEX_FAST_FORWARD] = 111
controls_a[CONTROL_INDEX_FAST_FORWARD] = 116
controls_a[CONTROL_INDEX_SWAP_SCREENS] = 109
controls_a[CONTROL_INDEX_SWAP_ORIENTATION_A] = 1026
controls_a[CONTROL_INDEX_SWAP_ORIENTATION_B] = 116
controls_a[CONTROL_INDEX_SWAP_ORIENTATION_B] = 65535
controls_a[CONTROL_INDEX_LOAD_GAME] = 65535
controls_a[CONTROL_INDEX_QUIT] = 65535
controls_a[CONTROL_INDEX_FAKE_MICROPHONE] = 65535
Expand Down Expand Up @@ -89,7 +89,7 @@ controls_b[CONTROL_INDEX_TOUCH_CURSOR_DOWN] = 1156
controls_b[CONTROL_INDEX_TOUCH_CURSOR_LEFT] = 1219
controls_b[CONTROL_INDEX_TOUCH_CURSOR_RIGHT] = 1155
controls_b[CONTROL_INDEX_TOUCH_CURSOR_PRESS] = 1035
controls_b[CONTROL_INDEX_MENU] = 1033
controls_b[CONTROL_INDEX_MENU] = 120
controls_b[CONTROL_INDEX_SAVE_STATE] = 65535
controls_b[CONTROL_INDEX_LOAD_STATE] = 65535
controls_b[CONTROL_INDEX_FAST_FORWARD] = 65535
Expand Down
8 changes: 8 additions & 0 deletions packages/emulators/standalone/drastic-sa/package.mk
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,19 @@ post_install() {
case ${DEVICE} in
S922X)
LIBEGL="export SDL_VIDEO_GL_DRIVER=\/usr\/lib\/egl\/libGL.so.1 SDL_VIDEO_EGL_DRIVER=\/usr\/lib\/egl\/libEGL.so.1"
HOTKEY=""
;;
RK3588)
LIBEGL=""
HOTKEY="export HOTKEY="guide""
;;
*)
LIBEGL=""
HOTKEY=""
;;
esac
sed -e "s/@LIBEGL@/${LIBEGL}/g" \
-i ${INSTALL}/usr/bin/start_drastic.sh
sed -e "s/@HOTKEY@/${HOTKEY}/g" \
-i ${INSTALL}/usr/bin/start_drastic.sh
}
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ rm -rf /storage/.config/drastic/backup
ln -sf /storage/roms/nds /storage/.config/drastic/backup

cd /storage/.config/drastic/
@HOTKEY@
@LIBEGL@
$GPTOKEYB "drastic" -c "drastic.gptk" &
./drastic "$1"
Expand Down
22 changes: 11 additions & 11 deletions packages/emulators/standalone/melonds-sa/config/RK3588/melonDS.ini
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ Joy_Right=16842767
Joy_Left=17891342
Joy_Up=65548
Joy_Down=1114125
Joy_R=86114303
Joy_L=35782655
Joy_R=85065727
Joy_L=34734079
Joy_X=3
Joy_Y=4
HKKey_Lid=-1
HKKey_Mic=-1
HKKey_Mic=77
HKKey_Pause=-1
HKKey_Reset=-1
HKKey_FastForward=-1
HKKey_FastForward=70
HKKey_FastForwardToggle=-1
HKKey_FullscreenToggle=-1
HKKey_SwapScreens=-1
Expand All @@ -37,25 +37,25 @@ HKKey_FrameStep=-1
HKKey_PowerButton=-1
HKKey_VolumeUp=-1
HKKey_VolumeDown=-1
HKKey_SaveState=-1
HKKey_LoadState=-1
HKKey_SaveState=83
HKKey_LoadState=76
HKJoy_Lid=-1
HKJoy_Mic=10
HKJoy_Mic=-1
HKJoy_Pause=-1
HKJoy_Reset=-1
HKJoy_FastForward=-1
HKJoy_FastForwardToggle=-1
HKJoy_FullscreenToggle=-1
HKJoy_SwapScreens=9
HKJoy_SwapScreenEmphasis=2
HKJoy_SwapScreens=2
HKJoy_SwapScreenEmphasis=-1
HKJoy_SolarSensorDecrease=-1
HKJoy_SolarSensorIncrease=-1
HKJoy_FrameStep=-1
HKJoy_PowerButton=-1
HKJoy_VolumeUp=-1
HKJoy_VolumeDown=-1
HKJoy_SaveState=6
HKJoy_LoadState=5
HKJoy_SaveState=-1
HKJoy_LoadState=-1
JoystickID=0
WindowWidth=1920
WindowHeight=1080
Expand Down
31 changes: 31 additions & 0 deletions packages/emulators/standalone/melonds-sa/config/melonDS.gptk
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
back = \\
start = \\
a = \\
b = \\
x = \\
y = \\
l1 = \\
l1_hk = l
l2 = \\
l2_hk = m
l3 = \\
r1 = \\
r1_hk = s
r2 = \\
r2_hk = f
r3 = mouse_left
up = \\
down = \\
left = \\
right = \\
left_analog_up = \\
left_analog_down = \\
left_analog_left = \\
left_analog_right = \\
right_analog_up = mouse_movement_up
right_analog_down = mouse_movement_down
right_analog_left = mouse_movement_left
right_analog_right = mouse_movement_right
deadzone_triggers = 3000
mouse_scale = 6128
mouse_delay = 16
13 changes: 12 additions & 1 deletion packages/emulators/standalone/melonds-sa/package.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PKG_NAME="melonds-sa"
PKG_LICENSE="GPLv3"
PKG_SITE="https://github.com/melonDS-emu/melonDS"
PKG_URL="${PKG_SITE}.git"
PKG_DEPENDS_TARGET="SDL2 qt5 libslirp libepoxy libarchive ecm libpcap"
PKG_DEPENDS_TARGET="SDL2 qt5 libslirp libepoxy libarchive ecm libpcap control-gen"
PKG_LONGDESC="DS emulator, sorta. The goal is to do things right and fast"
PKG_TOOLCHAIN="cmake"

Expand Down Expand Up @@ -48,6 +48,7 @@ makeinstall_target() {

mkdir -p ${INSTALL}/usr/config/melonDS
cp -rf ${PKG_DIR}/config/${DEVICE}/* ${INSTALL}/usr/config/melonDS
cp -rf ${PKG_DIR}/config/melonDS.gptk ${INSTALL}/usr/config/melonDS

cp -rf ${PKG_DIR}/scripts/* ${INSTALL}/usr/bin
chmod +x ${INSTALL}/usr/bin/start_melonds.sh
Expand All @@ -64,4 +65,14 @@ post_install() {
esac
sed -e "s/@PANFROST@/${PANFROST}/g" \
-i ${INSTALL}/usr/bin/start_melonds.sh
case ${DEVICE} in
RK3588)
HOTKEY="export HOTKEY="guide""
;;
*)
HOTKEY=""
;;
esac
sed -e "s/@HOTKEY@/${HOTKEY}/g" \
-i ${INSTALL}/usr/bin/start_melonds.sh
}
12 changes: 12 additions & 0 deletions packages/emulators/standalone/melonds-sa/scripts/start_melonds.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@

set_kill set "-9 melonDS"

#load gptokeyb support files
control-gen_init.sh
source /storage/.config/gptokeyb/control.ini
get_controls

if [ ! -d "/storage/.config/melonDS" ]; then
mkdir -p "/storage/.config/melonDS"
cp -r "/usr/config/melonDS" "/storage/.config/"
Expand All @@ -16,6 +21,11 @@ if [ ! -d "/storage/roms/savestates/nds" ]; then
mkdir -p "/storage/roms/savestates/nds"
fi

#Make sure melonDS gptk config exists
if [ ! -f "/storage/.config/melonDS/melonDS.gptk" ]; then
cp -r "/usr/config/melonDS/melonDS.gptk" "/storage/.config/melonDS/melonDS.gptk"
fi

#Emulation Station Features
GAME=$(echo "${1}"| sed "s#^/.*/##")
GRENDERER=$(get_setting graphics_backend nds "${GAME}")
Expand Down Expand Up @@ -81,11 +91,13 @@ fi
#Set QT Platform to Wayland
export QT_QPA_PLATFORM=wayland
@PANFROST@
@HOTKEY@

#Run MelonDS emulator
if [ "$SUI" = "1" ]
then
/usr/bin/melonDS
else
$GPTOKEYB "melonDS" -c "/storage/.config/melonDS/melonDS.gptk" &
/usr/bin/melonDS -f "${1}"
fi
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
190014b3010000009178000000050000,r33s_joypad,platform:Linux,x:b2,a:b1,b:b0,y:b3,back:b8,start:b9,dpleft:b12,dpdown:b11,dpright:b13,dpup:b10,leftshoulder:b4,lefttrigger:b6,rightshoulder:b5,righttrigger:b7,
1900e5914b4800007711000077010000,RGB20S Gamepad,platform:Linux,x:b2,a:b1,b:b0,y:b3,back:b12,start:b13,dpleft:b10,dpdown:b9,dpright:b11,dpup:b8,leftshoulder:b4,lefttrigger:b6,rightshoulder:b5,righttrigger:b7,leftstick:b14,rightstick:b15,leftx:a0,lefty:a1,rightx:a2,righty:a3,
1900e7444b4800000111000034020000,rg552_joypad,platform:Linux,x:b2,a:b1,b:b0,y:b3,back:b8,start:b9,dpleft:b15,dpdown:b14,dpright:b16,dpup:b13,leftshoulder:b4,lefttrigger:b6,rightshoulder:b5,righttrigger:b7,leftstick:b11,rightstick:b12,leftx:a0,lefty:a1,rightx:a2,righty:a3,
03001a3447616d65466f726365204100,GameForce ACE Gamepad,a:b1,b:b0,dpdown:b13,dpleft:b14,+lefty:-a1,-leftx:-a0,+leftx:+a0,-lefty:+a1,leftshoulder:b5,leftstick:b10,lefttrigger:-a2,dpright:b15,+righty:+a4,-rightx:-a3,+rightx:+a3,-righty:-a4,rightshoulder:b6,rightstick:b11,righttrigger:-a5,back:b7,start:b8,dpup:b12,x:b3,y:b4,platform:Linux,
03001a3447616d65466f726365204100,GameForce ACE Gamepad,a:b1,b:b0,dpdown:b13,dpleft:b14,+lefty:-a1,-leftx:-a0,+leftx:+a0,-lefty:+a1,leftshoulder:b5,leftstick:b10,lefttrigger:-a2,dpright:b15,+righty:+a4,-rightx:-a3,+rightx:+a3,-righty:-a4,rightshoulder:b6,rightstick:b11,righttrigger:-a5,back:b7,guide:b9,start:b8,dpup:b12,x:b3,y:b4,platform:Linux,
1900c3ea010000000100000001010000,odroidgo3_joypad,a:b1,b:b0,dpdown:b13,dpleft:b14,+lefty:+a1,-leftx:-a0,+leftx:+a0,-lefty:-a1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,dpright:b15,+righty:+a3,-rightx:-a2,+rightx:+a2,-righty:-a3,rightshoulder:b5,rightstick:b11,righttrigger:b7,back:b8,start:b9,dpup:b12,x:b2,y:b3,platform:Linux,
4 changes: 4 additions & 0 deletions packages/jelos/sources/post-update
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ if [ "${model}" = "Powkiddy RGB10" ]; then
rm -f /storage/joypads/odroidgo2_v11_joypad.cfg
fi

### 20240319 - Fix MelonDS and Drastic Configs
rsync -ah --update /usr/config/melonDS/* /storage/.config/melondDS 2>/dev/null
rsync -ah --update /usr/config/drastic/* /storage/.config/drastic 2>/dev/null

### 20240207 - Update Vita launchers and data.
rsync -ah --update /usr/config/vita3k/* /storage/.config/vita3k 2>/dev/null
rm -f "/storage/.config/vita3k/launcher/Start Vita3K.sh"
4 changes: 2 additions & 2 deletions packages/virtual/emulators/package.mk
Original file line number Diff line number Diff line change
Expand Up @@ -687,8 +687,8 @@ makeinstall_target() {
;;
RK3588*)
add_emu_core nds drastic drastic-sa false
add_emu_core nds retroarch melonds true
add_emu_core nds melonds melonds-sa false
add_emu_core nds retroarch melonds false
add_emu_core nds melonds melonds-sa true
add_emu_core nds retroarch desmume false
;;
RK3*)
Expand Down