Stormworks: Build and Rescue

Stormworks: Build and Rescue

221 ratings
3d Projection Demo (Augmented Reality)
20
10
9
11
4
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
234.031 KB
13 Apr, 2022 @ 2:38pm
20 Oct, 2023 @ 4:49pm
6 Change Notes ( view )

Subscribe to download
3d Projection Demo (Augmented Reality)

Description
Demo to show my 3d projection (Augmented Reality) in action.

Explanation and code on github: https://github.com/Jumper-44/Stormworks_AR-3D-Render

If interested in the Spatial Testing Rig
91 Comments
Basharbobo1 6 Nov, 2024 @ 6:49am 
I can code in lua somewhat, but to be honest with u am incredibly lazy, so that's why I asked you instead of looking through the github myself. Thanks for the answer tho will attempt this soon hopefully
Jumper  [author] 1 Nov, 2024 @ 7:25am 
[2/2]
By the way you are asking, then I'm assuming Lua isn't your strong front and you haven't looked through the github, or not familiar with how a virtual camera works etc. so it's fair to be uncertain.

So I assume it wouldn't be straight forward for you, but at least look though the code and readme on the github and judge for yourself. You would just need to understand the Input/Output for the cameraTransform.lua and understand the Render.lua file to project 3d points to the screen.
There's an in game example and template folders to differentiate the core functions.
Jumper  [author] 1 Nov, 2024 @ 7:23am 
[1/2]
If you convert the radar target to a global/world 3d point (x,y,z), then the code is mostly forward with how to map a point to the screen.
I used a personal Lua library, which doesn't make it quite forward with plug and play of the functions, which is a little bad on my part, as you would need to look though that library for whatever is needed, or know the SW VSCode extension for using custom libraries.

This is also using matrices to optimize for thousands of points, which takes more space than if you would have just done some vector calculations, which I've seen others that done so, some time ago. I don't have that implementation at hand, but that would've been a lot easier for plug and play to project 3d points to the hud.
Basharbobo1 31 Oct, 2024 @ 12:26pm 
is there a way to use this to pin point radar targets on a hud
Dolphin 23 Oct, 2024 @ 9:55pm 
military application when?
Jumper  [author] 2 Apr, 2024 @ 4:02am 
https://github.com/Jumper-44/Stormworks_AR-3D-Render/blob/master/Template/CameraTransform.lua#L99
There is a section for head_position_offset (approximation), also variable/vector for the relative position at the seat headrest block to the player head (When holdning nothing in hand).
That local position vector (head_position_offset) only depends on the seat look direction (and gender of player, defaults to male).

Picture of local coordinate space origin at seat headrest block:
https://github.com/Jumper-44/Stormworks_AR-3D-Render/blob/master/Pictures/Local%20Coordinate%20Space.png
Voss 30 Mar, 2024 @ 1:53am 
Would you consider publishing a standalone micro controller that just outputs the position of the player head relative to a point on the seat based on look direction?

I think it would help a lot of technical players including myself.
ZellyBelly 27 Mar, 2024 @ 3:36pm 
the next step is an entire functioning OS in stormworks.
lightnMCberger 23 Jan, 2024 @ 8:38am 
how do you learn to do this stuff
Jumper  [author] 1 Dec, 2023 @ 1:26pm 
@Voss
I've updated the github repo cameraTransform.lua and README.md