Now available via Github for anyone who wants to take a look at the inner workings
How it works
A beautiful bodge
Manipulating the view
Resetting the view to the center of the galactic map uses a series of AutoHotkey commands to zoom out, drag the mouse to orient as top down perspective, and then open the console and use the “goto 0 0” command to center the map.
Opening panels is always handled via hotkeys, which means VR-is doesn’t actually have knowledge of which panels are open/closed, only estimations based on an expected blank start state and the history of hotkeys it itself has pressed.
To achieve the effect of having multiple panels open at once, those that aren’t currently open in Stellaris have their view paused (e.g. opening the technology panel will capture and freeze the view of planetary administration so it can be referenced but no updates will be visible!)
Currently panels are updated if the player touches them with their controller
Going forward this should be expanded into a full ScreenManager class which controls each individual panel and chooses which is being updated when (perhaps based on which one is the closest the the player’s view, and so probably what they are interested in)
These are simply handled by using the hotkeys 1-9, hardcoded in Unity for mockup purposes to be the planet on 1 and the fleet on 2
Sending input to Stellaris
AutoHotkey moves the mouse cursor based on relative position of VRTK controllers over each panel
The Stellaris save format can be converted to JSON via this tool, which allows VR-is to display an overlay of the map ontop of the main screen (seen in the video as pink hyperlanes)
Player at the center of a holographic galactic map
Possible and pretty easy based on current features, placing the player in the center of the galactic map loaded from the save.json would allow them to interact with this holographic/resizable/rotatable map while the code transforms this input back into 2d screen space to click the mouse for fleet movement
Ship art based on the selected leader background
Possible I guess, just a lot of art work
Communication on main screen
Not sure how to detect when communication arrives, but otherwise easy to place in a panel in the scene somewhere
Home planet visible from windows
Possible but it would be a static view, due to only being able to have one camera!
Multiplayer, commanding the same empire
Possible by streaming Stellaris capture to all connected players, and sending back and input via AutoHotkey, however in this bodge solution they would quickly be overwriting/messing up each others commands as they all try to input at once
Maybe it would have to work like an old timeshare? Haha
I imagine this as putting on an AR headset overlay which would display the community voting chamber, and being able to see the actual empires in the balconies of the side they are voting for!
Unfortunately I don’t see how this could be possible currently other than trying to do image recognition on the empire flags, or just hardcoding it
Supports SteamVR currently but others would be easy to add due to VRTK
Assets/StreamingAssets contains all the AutoHotkey scripts:
- panic.ahk - Useful in case you lock yourself in Stellaris through panel interactions (Ctrl+F1 will exit play mode in Unity)
- resetview.ahk - Run when the player hits the "Reset View" button in VR, tries to recenter the view as top down and showing the whole galaxy
Tom’s Hotkeys (Stellaris Mod - adds ability to open Tech panel on T)
OBS (May have to scale down output resolution due to resource intensity of Stellaris and OBS and Unity)
OBS-VirtualCam (Target “OBS-Camera”, no buffered frames)
The results of Rainbow Jam 2019 are in!
|Use of Theme
|Use of Diversifiers
Play the game here!
I was inspired by playing the beautiful Eastshade (an open world painting game) but was disappointed to find no painting minigame, so of course I just had to mock one up myself.
It was originally implemented with the plan of simply using the mouse cursor to paint but then I remembered this plugin which allows the Leap Motion Controller to be used in Garry’s Mod, and again - just had to try it.
How it works is actually really simple!
The player performs a short calibration at the start; by positioning their hand (yes, hand - the brush is just a prop :]) to define 3 corners of the game window. Then their hand can be tracked relative to these to allow painting, with distance from the screen being converted to brush size.
So when the player decides on a perspective to paint a raw, normal screenshot is immediately taken and stored locally. From there it’s just drawing to various render textures in order to ‘reveal’ the part of the image under the brush & applying the selected ‘paint’. I’m using what I learned from the Magic: Anomolies to apply shaders & post-processes to the ‘paint’ to achieve different effects - these different styles are linked to the numpad as a sort of mock artist palette! These render textures caused a lot of issues with them not handling transparency as expected & their lack of documentation - but the end result is so worth it!
I had forgotten just how much fun the Leap is!
We used it for our Tragic Magic jam game and the added physicality is always just a blast!