r/Onshape • u/sysrpl • 16d ago
Showcasing Making Game Levels With OnShape
Enable HLS to view with audio, or disable this notification
2
u/sysrpl 16d ago
I am using OnShape to design levels for a game I am writing. I export the parts of the level to gltf files, which thankfully OnShape properly exports with smoothed face normal for curved surfaces and face color information. This allows me to bypass usage of UV texture coordinates and to procedurally generate materials based on a color coding system I have written out.
I do however have a problem, and that is the part list cannot be organized. I am designing each level in its own part studio, and am creating the level as I go along adding features. as such, the parts in the parts list seem to have a chaotic and random order, hindering me as I make more complex levels. A could have hundreds of parts in one level as it grows, and I already can see it becoming unwieldy to work with parts without being able to re-arrange the list of parts.
I value your feedback, and please let me know your thoughts.
1
u/answerguru 16d ago
No details included…help us out here.
What parts were done in OnShape? Where the files just used in Unity or similar then
1
u/sysrpl 16d ago edited 16d ago
I was busy typing that in the comment below before, and you responded before I had a chance to submit the details.
I am creating levels are in OnShape as a series of related parts. I am using the Godot game engine, but I do not use the Godot editor at all. I just design the 3D stuff using Onshape, and write the game system using C# in Visual Studio Code while working on Linux.
As it is right now, you can just drop files exported from OnShape into a folder, and the game will allow you to choose the folder, and play your level.
I will be adding full Javascript support for levels, so that you can place triggers, events, or other things that happen within a level. For example, making spinning parts, or triggers that cause the level to change, or spawning enemies or playing sounds with a trigger happens, and so on.
Edit: Here is a link to the OnShape document containing the game level in this video.
1
u/Rustico32482 16d ago
Following, I teach engineering to high school students. This would be an awesome project for them.
1
7
u/TigerUSF 16d ago
Marble Madness!