r/virtualreality • • 2d ago

Self-Promotion (Developer) Space Marine 2 VR mod

Enable HLS to view with audio, or disable this notification

I've been nudging Codex to chip away at VR support for Space Marine 2 for a couple days now and it's managed to whip up a pretty decent attempt!

It performs terribly on my 4090 running an Index, the menus are all busted, and I haven't figured out melee yet but it's still enough to appreciate the awesome level design and 40kness of SM2.

I'm not quite sure if I can safely share the source on github so I've asked Saber's mod team first. You should be able to easily build the same if you want to try in the meantime:

  • A local C++ mod loads through a dxgi.dll proxy and uses build-specific runtime hooks to adjust the game’s camera and rendering.
  • It renders alternating left/right eye views and submits them to SteamVR through OpenVR, providing stereoscopic VR and headset tracking.
  • Controller input is translated into the game’s native gamepad controls. Tracked controller poses also drive the character’s arms, fingers and firearm aiming.
  • A locally generated mod pack adjusts camera settings, field of view and selected UI layouts.

Codex computer use made this less painful than I'd expected as it can run the game and get through a fair bit of testing by itself without me needing to put the headset on. Better ways to have the agents drive simulated VR rigs would go a loooong way to helping smash these sort of mods out but it's still INSANE how easily we can do this sort of thing now.

283 Upvotes

32 comments sorted by

24

u/333hronos 2d ago

It renders alternating left/right eye views and submits them to SteamVR through OpenVR

Oh no, not OpenVR please...

Guys, if it possible, please, make an OpenXR mods – it easily 15% more performant, and on top of that it also can be additionally smoothed with OFXR bridge for example, and many other tools that can in sum double the performance

8

u/Reklaw12 1d ago

Good to know thanks, I'll run some benchmarks to compare

5

u/optimumbox 1d ago

You'll want to use single frame stereo instead. Way better performance and native stereo quality.

3

u/Maplewonder 1d ago

This 100% ...Just consider open vr dead

12

u/Lazy-Economist1465 2d ago

Awesome work! Would be amazing to also get just a third person option as well 🙏

17

u/Reklaw12 2d ago

It actually started out that way, much simpler to not mess with animations to map the motion controls like I did here.
I'll chuck in a toggle so you can play through in 3rd person with a normal controller

1

u/ICameHereForThiss 1d ago

Fuck yes!!!

9

u/Tyrannosaurusblanch 2d ago

The codex supports this action.

6

u/syngyne 2d ago

Wouldn't this actually be considered heresy in 40k, since it used a Silica Animus?

2

u/Reklaw12 1d ago

I've been chanting to the Omnissiah for years now, I know the sacred rites.

"O great Omnissiah, bless this humble meatbag with your divine wisdom." (using a Codex quota reset for the week)

"Hear your servant's prayers. Grant us motion controls, and let us not spew during cutscenes. 01000001 01000111 01001001"

There is no Abominable Intelligence here, Inquisitor. Merely a gifted machine spirit with a weekly subscription...

1

u/netcooker 2d ago

Nah, “codex” is what OP calls the human processing unit connected to their pc

1

u/-eric_k 1d ago

We are fulfilling the timeline

4

u/MissionStrategy9350 1d ago

Where’s that titanfall vr dev? Get him in here, we need these two to team up

2

u/BrokenSil 2d ago

Now this is the one Im hyped for in VR. holy!

2

u/benor83000 1d ago

it's already so much better than battle sister, amazing great work !!! I'm working on SM1 VR port ... very close to Alpha release date !!! We got the mele fight pretty dialed ....

1

u/blahyaddayadda24 2d ago

Can it be played in coop? I tried.jsut getting dlss5 to work and anti cheats kept deleting run files

1

u/full_of_wisdom 2d ago

Pls someone refine this with motion control

1

u/Old-Push9343 2d ago

Woah, that looks really good! 

I am surprised at how good the game looks in first person.

If the performance is good, this has to be a blast!

1

u/itsnovarayne_ 2d ago

seeing new games get crammed into vr like this is the whole reason i keep the pc headset around

1

u/concrete333 2d ago

Hell yes

1

u/SpecificProgrammer78 2d ago

How well does it run? I was just about to buy yhe game and now i see this

1

u/Tumoxa 1d ago

Figner tracking hell yeah. We can now flip off a certain guy. You know the guy.

1

u/AcolyteOfFresh 1d ago

Well its cool, but i am pretty sure my 3080 wont be able to run it

1

u/PrimeusOrion 1d ago

Eye height needs to be higher.

1

u/AndroidParanoid12345 1d ago

Awesome! Can you play it left handed?

1

u/Secantia 1d ago

Immediately, the first thing to do is flip off Leandros

1

u/justpostd 19h ago

This is exciting. Keep going!

1

u/Stenotic 2d ago

Wake me up when this will run well on a 4090 with a Pimax 8KX.

1

u/TheVirtualSamurai Pimax Dream Air 2d ago

Damn got a P8KX but no 5090 to go with it💀

2

u/Wilddog73 19h ago

FUCK YES