dantman / elite-vr-cockpit

A SteamVR Overlay providing a virtual throttle and joystick and holographic buttons for ship functions, with custom integration into Elite Dangerous
Other
320 stars 36 forks source link

Feature idea - mouse mapping #227

Open demolitions opened 3 years ago

demolitions commented 3 years ago

I'm a bit late to the party, just discovered this application and I love it, pure genius.

Fiddled a bit to configure my Index controllers but got everything that I needed set up, and had a blast playing E:D without getting my HOTAS out of the closet, this is going to be how I play ever again.

Sorry for the little vent, now on to the idea: I had my mouse configured for play, and I have seen that E:D still takes input from it even if I'm in VR mode, and with a joystick connected, so: How about having some movable "invisible" panels, raycasting to them and mapping positions for a virtual mouse to interact with the left and right ship panels? I don't know if it's at all possible in overlay, it's just a thought.

dantman commented 3 years ago

How about having some movable "invisible" panels, raycasting to them and mapping positions for a virtual mouse to interact with the left and right ship panels? I don't know if it's at all possible in overlay, it's just a thought.

This is something I'm thinking of for the Station Services panel and Galaxy/System map interfaces. However you'll have to switch to the world cursor.

The problem with the side panels is that the world cursor cannot interact with them IIRC and the screen cursor is based on where you are looking so I have no sane way to figure out what the mouse position should be to hover over a spot on the side panel (assuming you're even looking at it directly enough for it to be visible on the desktop view).

Raycasted laser/touch panels would be nice. But the only way I can see them working is a pipe dream where FDev gives us a custom API to send 2d panel relative pointer events.

That said, if they also put a texture with the side panel contents that would probably also be interesting to people building full cockpits that want to mount a physical touchscreen on each side of them and replicate the side panels on them.

demolitions commented 3 years ago

assuming you're even looking at it directly enough for it to be visible on the desktop view

This shouldn't be a problem, since if you're not looking almost directly at the panel, they don't appear, at least in my setup.

But I get your point, it would be a nightmare.

Still, I'd like to pour over your code (just forked the project) and give it a try, assuming I understand how Unity treats VR overlays (never tried something like that).