Live data from Hacker News

Show HN: The full source code and assets for my custom game engine and game

news.ycombinator.com

1–10 of 38 posts

Show HN: The full source code and assets for my custom game engine and game

#1
I always enjoy reading posts about indie game development and looking at the source code of games other people have built. So for any game I release I naturally I want to do the same.

https://github.com/Mknsri/HockeySlam

Hockey Slam is a hockey shootout game on Android which I built almost from scratch. Some of the engine features include 3D graphics with PBR materials, a rudimentary physics system, replays, a multithreaded job system and a hot-reload DLL platform for developing on Windows.

I detailed the creation of the game in it's own post, but now that time has passed I am releasing the source code and assets under the MIT license. You can still find the making of here: https://hockeyslam.com/makingof

I'm happy to answer any questions you might have.

Re: Show HN: The full source code and assets for my custom game engine and game

#3
post #2

I'm also making a game from scratch and reinventing wheels. What is the processing that you are doing for GLES? I see the GLSL_PREPROCESS in the GLSL.

I wanted to include common code for all shaders in a simple way, but I was too lazy write a proper parser. So instead I used the C++ preprocessor and macros to include things from common shader code and combine them in the build step.

Re: Show HN: The full source code and assets for my custom game engine and game

#6
post #3
post #2

I'm also making a game from scratch and reinventing wheels. What is the processing that you are doing for GLES? I see the GLSL_PREPROCESS in the GLSL.

I wanted to include common code for all shaders in a simple way, but I was too lazy write a proper parser. So instead I used the C++ preprocessor and macros to include things from common shader code and combine them in the build step.

FYI: https://docs.gl/es2/glShaderSource takes an array of strings and just internally appends them together. So, rather than trying to #include common code for all my shaders, I just pass a common_code_string and a shader_specific_code_string every time.
Post reply on HN