Open davidj1987 opened 8 years ago
Genesis Plus GX libretro port uses
So it's either that:
or
As for why RETRO_DEVICE_LIGHTGUN is not used for getting lightgun screen position, the X / Y values returned by this libretro device are actually relative coordinates, which is not very usable for a gun position on screen when you have no idea of the initial position.
I tried just now after I originally posted this seeing that Retropie and Retroarch has had updates since I posted. I can report that a mouse does work in other emulators for light gun games but not Genesis Plus GX. However, I did find the mouse sort of works in Genesis Plus GX.
Body Count for example does work with a mouse, if you set it to Mega Drive mouse. It doesn't matter if Player 1 or 2 is set to use a mouse. However, Menacer and light phaser games don't work with a mouse. All you can do is just press the left mouse button and it will register as a fire button.
It is fine in the Windows version though.
I'm very interested to see how this thread plays out. I was just looking at the EMS Top Gun 3 to find out if It would be possible to play Snatcher with a gun. The other missing link of course, is menacer/enforcer support.
RETRO_DEVICE_POINTER is not for mice but for absolute coordinate devices (trackpads, touchscreens, etc). It should use RETRO_DEVICE_MOUSE, really (or ideally, both). any mouse device plugged in to a raspberry pi will work with RETRO_DEVICE_MOUSE if it's used.
You can see an implementation of RETRO_DEVICE_MOUSE here: https://github.com/libretro/mame2003-libretro/blob/master/src/libretro/libretro.c#L358
You are not teaching me anything I don't already know, read my previous answers. Sega Mouse is emulated using RETRO_DEVICE_MOUSE but lightguns ARE absolute coordinates devices so it makes more sense to use RETRO_DEVICE_POINTER for emulating them.
It is supported by libretro API so it's perfectly valid to use it in a libretro core.This is not my problem if it is not yet implemented by Retroarch in every drivers (lightguns work fine with a physical mouse in Windows port of Retroarch by the way so it's definitively possible to implement it in other drivers).
Keep in mind a libretro core is meant to be portable across platforms, it doesn't have to know or guess which physical device you are using as pointing device and it is not necessarely limited to mouse as with a raspberry pi, it could use wii remote or touchable screen.
agreed. but i reckon we could spoof an absolute coord from a relative coord in the RA udev driver. eg https://msdn.microsoft.com/en-us/library/windows/desktop/ee418779(v=vs.85).aspx
ie, take 0,0 to be the start value and use the relative coords passed in by the mouse to move from that.
maybe i will have a play with it later :)
Hey everyone. I came across this thread while looking for information about light gun games working on Retropie. I have gotten it to work with a Wiimote/DolphinBar combo on various AdvMame games (Operation Wolf, Operation Thunderbolt) with relative ease (i.e. without tweaking code).
However, I don't know much about changing settings within the emulator itself, and the SMS/Genesis (probably NES too) shooter games haven't recognize my Wiimote/DolphinBar setup. I assume I have to change settings within the emulator cores. I'm wondering if someone here could point me in the right direction. Thanks!
Actually.... the plot thickens, sorta. When I switched my emulator for the shooting games over, it recognized the Wiimote as a gun, and the trigger would actually fire... but I couldn't actually move the crosshairs/target. It was just stuck in the same place. Any advice would be more than welcome!
For whatever reason I cannot get this to work on the Raspberry Pi. A mouse works fine on the PC version of Retroarch as a Lightgun if you set it properly (i.e. light phaser for SMS games, Menacer for Genesis games) but it does not on the Raspberry Pi if you have a mouse hooked up, a mouse works fine in the Retroarch GUI if you enable it, but as for Genesis Plus GX the buttons work so when you press the left or right mouse button they fire as they should but you cannot move the cursor.