Skip to content

Commit

Permalink
Initial commit - first post
Browse files Browse the repository at this point in the history
  • Loading branch information
robzedgames committed Oct 16, 2024
0 parents commit f06123d
Show file tree
Hide file tree
Showing 22 changed files with 1,243 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.jekyll-cache/
_site/
1 change: 1 addition & 0 deletions CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
robzed.com
5 changes: 5 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# frozen_string_literal: true

source "https://rubygems.org"

gem "jekyll", "4.3.4"
74 changes: 74 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
GEM
remote: https://rubygems.org/
specs:
addressable (2.8.7)
public_suffix (>= 2.0.2, < 7.0)
bigdecimal (3.1.8)
colorator (1.1.0)
concurrent-ruby (1.3.4)
em-websocket (0.5.3)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0)
eventmachine (1.2.7)
ffi (1.17.0-x86_64-darwin)
forwardable-extended (2.6.0)
google-protobuf (4.28.2-x86_64-darwin)
bigdecimal
rake (>= 13)
http_parser.rb (0.8.0)
i18n (1.14.6)
concurrent-ruby (~> 1.0)
jekyll (4.3.4)
addressable (~> 2.4)
colorator (~> 1.0)
em-websocket (~> 0.5)
i18n (~> 1.0)
jekyll-sass-converter (>= 2.0, < 4.0)
jekyll-watch (~> 2.0)
kramdown (~> 2.3, >= 2.3.1)
kramdown-parser-gfm (~> 1.0)
liquid (~> 4.0)
mercenary (>= 0.3.6, < 0.5)
pathutil (~> 0.9)
rouge (>= 3.0, < 5.0)
safe_yaml (~> 1.0)
terminal-table (>= 1.8, < 4.0)
webrick (~> 1.7)
jekyll-sass-converter (3.0.0)
sass-embedded (~> 1.54)
jekyll-watch (2.2.1)
listen (~> 3.0)
kramdown (2.4.0)
rexml
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
liquid (4.0.4)
listen (3.9.0)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
mercenary (0.4.0)
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (6.0.1)
rake (13.2.1)
rb-fsevent (0.11.2)
rb-inotify (0.11.1)
ffi (~> 1.0)
rexml (3.3.8)
rouge (4.4.0)
safe_yaml (1.0.5)
sass-embedded (1.79.5-x86_64-darwin)
google-protobuf (~> 4.27)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
unicode-display_width (2.6.0)
webrick (1.8.2)

PLATFORMS
x86_64-darwin-23

DEPENDENCIES
jekyll (= 4.3.4)

BUNDLED WITH
2.3.26
6 changes: 6 additions & 0 deletions _categories/coding.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
layout: category
name: Coding
category: coding
---
All things tech related.
6 changes: 6 additions & 0 deletions _categories/game-design.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
layout: category
name: Game Design
category: game-design
---
More design related topics.
3 changes: 3 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
collections:
categories:
output: true
6 changes: 6 additions & 0 deletions _data/navigation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
- name: Home
link: /
- name: About
link: /about.html
- name: Articles
link: /articles.html
16 changes: 16 additions & 0 deletions _includes/navigation.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<nav class="navbar">
<div class="container">
<ul class="navbar-list">
{% for item in site.data.navigation %}
<li class="navbar-item">
{% assign link_classes = 'navbar-link' %}
{% if page.url == item.link %}
{% assign link_classes = link_classes | append: ' active' %}
{% endif %}

<a href="{{ item.link }}" class="{{ link_classes }}">{{ item.name }}</a>
</li>
{% endfor %}
</ul>
</div>
</nav>
16 changes: 16 additions & 0 deletions _layouts/category.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
layout: default
---

<div class="container">
<div class="row">
<h3 class="post-title">{{ page.name }}</h3>

<ul>
{% assign filtered_posts = site.posts | where: 'category', page.category %}
{% for post in filtered_posts %}
<li><a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</ul>
</div>
</div>
21 changes: 21 additions & 0 deletions _layouts/default.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Rob Zed Games - {{ page.title }}</title>
<link rel="stylesheet" href="/assets/css/normalize.css">
<link rel="stylesheet" href="/assets/css/skeleton.css">
<link rel="stylesheet" href="/assets/css/styles.css">
</head>
<body>
<div class="container">
<div class="row">
{% include navigation.html %}
{{ content }}
</div>
</div>
<div class="container footer">
<p>© Robert Ziehl, 2024</p>
</div>
</body>
</html>
15 changes: 15 additions & 0 deletions _layouts/post.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
layout: default
---
<h3 class="post-title">{{ page.title | capitalize }}</h3>
<h5 class="post-subtitle">{{ page.subtitle | capitalize }}</h5>

<p class="post-date">
{{ page.date | date_to_string }}
{% assign category = site.categories | where: 'short_name', page.category | first %}
{% if category %}
- <a href="{{ category.url }}">{{ category.name }}</a>
{% endif %}
</p>

{{ content }}
66 changes: 66 additions & 0 deletions _posts/2024-10-16-state-of-the-engine.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
---
layout: post
category: coding
subtitle: And Drawing Lines In The Sand
---

I have been working on the same side project for three years now (although bits and pieces date back later than that) and I feel like it's a good time to reflect on how far I have come and what the next steps are.

Here's some rough metrics for the current codebase:

* **24722** lines of code (actual source lines, not whitespace or comments. This also excludes all open source dependencies)
* **2895** comments
* **379** todos
* **5926** lines of JSON data (the game is fairly data driven although a good chunk of this is a massive map file that features a 2D grid)

*Full disclosure*: I am coding my game engine from scratch using [SDL2](https://www.libsdl.org/) and C++ as the foundation. I opted not to use a commercially available engine like Unity or Unreal for my game.

So yes, that means I need more time up front to actually build my own engine as a trade-off against the continuous cost of version changes. This could still be [a more time consuming approach](https://moonstoneequation.com/a-warning-to-others/) for me but honestly I find it more productive. But the age old question of *"are you making a game or an engine?"* comes to mind and as a programmer first, it's easy to get wrapped up in coding technical details (I am definitely guilty of this).

Now though, I need to realistically focus on the game itself.

---

I think while I have a lot of the systems in place or at least rough versions of them, a pragmatic line in the sand would be the difference between production ready technical aspects and actual gameplay. Production ready things would include handling integrated versus dedicated GPUs, UTF-8 support, a full featured settings screen, remapping controls, high DPI support, achievements and testing different CPU architectures.

My core focus now will be on the main gameplay to get something playable and fun. Then I think I will extend that to the first vertical slice and polishing that as much as possible. This is an exercise that the developers of Hollow Knight, Team Cherry did. It helps set the standard for what the rest of the game should look like plus it also makes
a good cut-off point for a demo (which I think is becoming more and more important with Steam Next Fest being a key marketing opportunity for indies).

After that I will begin roughing out the rest of the world, making the story playable from beginning to end.
Then probably some rounds of polish, playtesting and finally all those production ready criteria mentioned above as well as optimization.

---

As of today this is quick overview of some of the main systems in my engine:

* **AI**: Behaviour trees. Needs unit testing to iron out any edge case bugs but otherwise it's dangerous enough to make something functional as demonstrated with the first creature in the game. Pathfinding needs to be implemented still.
* **Animation**: Frame based animations implemented with different frame lengths supported as well as events that can be triggered on specific frames which helps
for playing sounds and actually doing certain behaviours.
* **Audio**: There is a basic engine done with Fmod. Still needs panning and fading over time effects, some basic 2d location for sound would be nice to have too.
* **Collision**: Basic bounding box checks for now, will need some work for sure especially with some of the more physics based entities.
* **Cutscenes**: Mostly there, a few events still needed and some bugs need to be worked out.
* **ECS**: Custom solution, using it more as an organizational pattern as opposed to an optimization one right now. Quite a lot of components already completed, proving to be quite reusable.
* **Input**: Very simple implementation right now. Needs controller support and maybe a more data-driven approach to which actions get triggered in what context.
* **Map Editor**: Very early stages. Missing a lot of functionality.
* **Message Queue**: Decent implementation that can be used across broader systems. Ability to add additional information with a message would be nice.
* **Rendering**: Mostly good. Water rendering will need to be implemented properly and particle systems need to be finished. Lighting is pretty much done though.
* **Resource Loading**: Pretty good system in place. I have a side project to make this even more data driven so I can really simplify all the serialization code.
* **Saves**: Entities get saved properly for the most part. Map changes do not as well as some other game state.
* **Tests**: I think there’s a basic test runner and maybe some of the math tests but otherwise severely lacking.
* **UI Framework**: Mostly there. Dropdowns, scrollbars and text inputs all need some fixes. Multiline paragraphs still haven't been implemented.

So not a bad base overall, it could be better, there's lots of gaps but my spare time has been dedicated to this very sporadically. I think it's enough to whip up a prototype so that's my turning point from initial engine to game prototype. On rainy days when I need a break from my current task list I might pick something engine related to improve or maybe work on some dev tools (like an in-game console, hot reloading or debug view). They might speed up development in some situations.

---

But going full circle back to the beginning of this post, I am really curious to see by the end of this project, years from now, what the metrics will look like. I find posts like [this classic](https://kotaku.com/the-exceptional-beauty-of-doom-3s-source-code-5975610) great for providing some similar stats.

> *To put things into perspective: Dyad has 193k lines of code, all C++. Doom 3 has 601k, Quake III has 229k and Quake II has 136k. That puts Dyad somewhere in between Quake II and Quake III. These are large projects.*
Dwarf Fortress is supposedly [700K LOC](https://stackoverflow.blog/2021/12/31/700000-lines-of-code-20-years-and-one-developer-how-dwarf-fortress-is-built/) (although Tarn Adams did the metric by searching for `;` characters and not using a tool like `sloc`).

These are by no means an objective level of quality or perfection but they are fun perspectives to indulge in from time to time.

---

In the next post, I want to continue this chain of thought and talk about actually building out a game idea.
85 changes: 85 additions & 0 deletions _sass/main.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
.header {
margin-top: 6rem;
text-align: center;
}

.about-header {
margin-top: 4rem;
text-align: center;
}

/* Navbar */
.navbar {
display: none;
}
.navbar + .docs-section {
border-top-width: 0; }
.navbar,
.navbar-spacer {
display: block;
width: 100%;
height: 6.5rem;
background: #fff;
z-index: 99;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee; }
.navbar-spacer {
display: none; }
.navbar > .container {
width: 100%; }
.navbar-list {
list-style: none;
margin-bottom: 0; }
.navbar-item {
position: relative;
float: left;
margin-bottom: 0; }
.navbar-link {
text-transform: uppercase;
font-size: 11px;
font-weight: 600;
letter-spacing: .2rem;
margin-right: 35px;
text-decoration: none;
line-height: 6.5rem;
color: #222; }
.navbar-link.active {
color: #33C3F0; }
.has-docked-nav .navbar {
position: fixed;
top: 0;
left: 0; }
.has-docked-nav .navbar-spacer {
display: block; }
/* Re-overiding the width 100% declaration to match size of % based container */
.has-docked-nav .navbar > .container {
width: 80%;
}

.footer {
text-align: center;
}

.avatar {
margin-top: 6rem;
margin-left: auto;
margin-right: auto;
background-image: url('../../assets/images/avatar.png');
width: 96px;
height: 96px;
background-size: cover;
background-position: top center;
border-radius: 50%;
}

.post-title {
margin-top: 4rem;
}

.post-subtitle {
color: #666;
}

.post-date {
color: #888;
}
30 changes: 30 additions & 0 deletions about.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
layout: default
title: About
---

<div class="container">
<div class="row">
<div class="avatar"></div>
</div>
<div class="row about-header">
<h4>About</h4>
</div>
<div class="row">
<p>Hi, I'm Rob! And I'm currently working on an unannounced game.</p>

<p>I'm doing the art, code, music, sound effects and writing all myself so it's still quite a way out.</p>

<p>
I think there needs to be more games designed for mental health, not necessarily touching on the topic but just serving as pure escapism.
We all need a break from the stress of day to day life. I hope this game can provide that for anyone who plays it.
</p>
<p>
It's going to be an adventure, light hearted and down to earth. Expect some humour and shenanigans. As well as a lot of interactivity, secrets and surprises.
</p>

<p>In the meanwhile, I'm going to be writing about my progress and thoughts as I go along.</p>

<p><em>Stay tuned!</em></p>
</div>
</div>
17 changes: 17 additions & 0 deletions articles.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
layout: default
title: Blog
---
<div class="container">
<div class="row">
<h3 class="post-title">Articles</h3>

<ul>
{% for post in site.posts %}
<li>
{{ post.date | date_to_string }} - <strong><a href="{{ post.url }}">{{ post.title }}</strong>: {{ post.subtitle }}</a>
</li>
{% endfor %}
</ul>
</div>
</div>
Loading

0 comments on commit f06123d

Please sign in to comment.