Making unique and experimental indie games
Schmidt Workshops
  • Home
  • Contact
  • Star Explorers Devlog

Refactoring Star Explorers

6/25/2021

0 Comments

 
I have been updating Star Explorers quite a lot recently. Ever since the Realms Deep event in 2020, I found there was more interest in Star Explorers than in my other game Paradox Vector, and it caused me to focus on improving and updating the game.  You can see about a third of a second of Star Explorers around the 36 second mark in this Realms Deep trailer...
Aside from adding lots of new features, like an alien city, meteor strikes, tornadoes and other emergent systems, I have also wanted to invest some time in refactoring some of the old, foundational scripts that were written over 7 years ago. These systems were never really revisited, and some notable bugs would remind me every so often that the game was metaphorically sitting on a pile of horse manure.

A Two Week Trial
So, I finally put my thoughts together and decided to do a small experiment. I would start a fresh project and import only the game assets, like textures, 3D models and sounds, writing the actual script from scratch. I allotted myself two weeks to accomplish this task, and would decide on any long term changes after this two week period expired.

I did not expect to get very far in two weeks, but I felt that was enough time to figure out how things would go. Well, they went pretty well. I was able to rewrite many of the game's basic systems in a much more efficient way than I had 7 years ago. This highlighted to me many of the redundancies and problems that were plaguing my current script. It also gave me the confidence I needed to actually go in and change some of those scripts.

While this new version of Star Explorers will probably never be played by anyone, it has served an important purpose and will contribute greatly to the future of the game.
Picture
Here is an image of the totally re-written version of Star Explorers
Back to Square One
Now I have returned to the current testing branch version of Star Explorers, and have completely rewritten the galaxy save and load functions, based on this new approach. It still uses a lot of the same scripts, but the core of how the game actually works is totally different. A player may not notice it at all of course, other than having less crashes and maybe a little shorter loading times in some cases.

Specifically, I have taken a very new approach to saving and updating the galaxy information. Previously, when a player started a new game, it would generate a new galaxy, and write that galaxy's data to a file. This file would then be used to reload the galaxy whenever the player loaded a saved game, or traveled from a planet's surface back to their spaceship. The galaxy file was never altered after it was initially written, so that forced me to come up with an elaborate system of other files which stored any information that may have changed in the galaxy. So any stars or planets that were scanned would have to write new files with scan information. Then, when reloading the galaxy, each star would have to access these additional files, in order to update their skills (skills are just entity specific variables in 3D Gamestudio). This was a constant headache for me, as the system was so complex and interdependent, that any changes to the game would easily cause problems and lead to unforeseen bugs.

The new system has the same basic output, but handles the data completely differently. It again creates a galaxy, and writes the information to a file. That file is accessed and used whenever the player loads a game, or returns to the spaceship. However, instead of the elaborate system of supporting files, the game simply rewrites the galaxy file every time the game is saved, so entity skills are always kept up to date in that one, simple file.

It seems like a no-brainer in terms of how to save game data. However, when I started this project seven years ago, I had no idea how any of this was going to work. I did not even know star information/skills would have to change or be updated, so these things were written incrementally on top of what was already there. Since my galaxy save and load script “worked” I would simply write new scripts around what was already in place. Only years later could I look back and see exactly how problematic the whole system had become.

Valuable Lessons for the Thoughtless Programmer
Ultimately, this experience taught me something many veteran programmers will say quite often, that you should plan out your scripts before writing them,  This is why design documents are important, thinking through how a system will work very thoroughly will save you a lot of time and effort in the long run.  I have a background in art, not programming, and I have tended to take a similar approach in making games.  Getting an idea, and pursuing it is fun, and can be valuable.  But if you want to make a game *other* people can enjoy, you have to really make the effort to ensure it is functioning properly. 

I am nearing a point where the new version is just about ready for play-testing. I'm excited and kind of scared, as bugs do have a habit of reaching players when they may have evaded my attempts to discover them.
Picture
Here is the current Star Chart, with recently added color coding on stars and planets
Next Steps: Revisiting the Star Chart
The next plan is to take another close look at the Star Chart. Again, the Star Chart was written by a younger version of myself. It took it's approach very literally. Instead of just looking at the galaxy file, and plotting stars and planets according to that, the game actually created a separate database of star and planet information when the player scanned each heavenly body. This approach seemed so logical at the time, especially when the galaxy file itself could not be updated, and was based on the same set of limitations I described above. But now, instead of dealing with a separate, complex set of files, the Star Chart could simply take existing galaxy file information and use that to display its data.

Once again, this seems so easy and logical. But tell that to a guy who, seven or eight years ago, decided to write a procedural galaxy generation script with no previous experience and no idea how to do it.
0 Comments

About Star Explorers

5/7/2021

3 Comments

 
I wanted to start writing about Star Explorers, for the players, for the potential players, and for myself, as a way to document my thinking behind the game.  This is not where I will be posting updates or announcing changes to the game, you can see all that on the Steam Page, but I want this to be about the deeper stuff.  This first post is dedicated to those shows, books, games and ideas that really formed the primary influences of Star Explorers.

Minecraft meets Star Trek
The whole idea for Star Explorers came up some time in 2013, around October if memory serves, and it was a result of playing a bunch of Minecraft and watching a ton of Star Trek: The Next Generation episodes on Netflix.  I remember specifically the image of the Enterprise orbiting a new world, and wondering if I could make different worlds, like Minecraft does, but in a way where a player could visit many of them in the same game. 

It's that image of the Enterprise's view screen, with a planet slowly circling on the left, and space extending off to the right, that I really wanted to capture.  There is something magical about the idea of treading on new ground.  The mystery of what may or may not exist on the surface of a new world.  The expectancy and anticipation of it all, just like the crew of the Enterprise must have felt (theoretically) whenever they approached a new, unexplored planet, and could see it from the relative safety of their ship before attempting to transport down ... that's what originally motivated me to make this game.
Picture
Of course I had an interest in actual space exploration.  Much of my art leading up to this involved paintings of the moon, stars and planets.  I had written a Children's book called "The Adventures of the Salamander" in which the protagonist, Slippy the Salamander, visits the moon, and is whisked off to another world in one of his many adventures.

Star Wars, Star Trek, Alien, Battlestar Galactica, Buck Rogers and many others films and television shows formed a foundation of my childhood and later, reading the works of H.P. Lovecraft, Isaac Asimov, Douglas Adams, Frank Herbert, the Strugatsky brothers and others formed a more detailed, serious, and occasionally silly, take on the subject of space travel and other worlds. 

Other Games
Video games were one area in which my interest in space did not really become prominent.  I think it had mainly to do with the fact that space games tend to take place in space, where I was more interested in visiting other worlds, space being merely the means of reaching them.  There were games like this, of course, but somehow most had escaped my notice in one way or another.  One I remember from my childhood was Rescue on Fractalis, which, while not a great game in my opinion, did introduce the idea of procedurally generated worlds to my young mind. 

In gaming I tended to be interested in fantasy RPGs, and later first person action games.  These of course also allow you to explore different worlds, but usually only one at a time.  So from a gameplay perspective, Star Explorers is not really influenced by space games as much as RPG and FPS games. 
Picture
S.T.A.L.K.E.R. Shadows of Chernobyl, despite taking place of earth, and having very little, if anything, to do with space, probably forms the primary gameplay influence on Star Explorers.  I wanted each world to have a day/night cycle.  This was directly taken from S.T.A.L.K.E.R., along with the changing weather patterns, and harsh environmental factors.  It was the atmosphere, and open ended exploration of the S.T.A.L.K.E.R. games that I really loved the most, making them my favorite game series to date.  I wanted to capture some of that in the worlds of Star Explorers.  Whether I achieved anything remotely similar, I leave to players to decide. 

Regarding No Man's Sky
No Man's Sky needs to be mentioned here.  There are a number of very obvious overlaps between Star Explorers and No Man's Sky.  I have written extensively about this already, here.  Briefly, while they do share a lot of superficial similarities, Star Explorers was already a working prototype before I had even encountered No Man's Sky.  It's hard to convince people that simultaneous invention exists, but indeed it is a well known phenomenon.  I would only say that while I totally respect that game and what it is, when I actually played it, it did not fulfill the sense of exploration and discovery that I was aiming for.  Many players have expressed similar sentiments after playing both games, and I think this serves as an interesting case study in how games based on an almost identical "idea" can result in two very different interpretations and expressions of that idea. 
Picture
Behind the Game
So far, I've covered only the things that have influenced Star Explorers as a game.  But there is another deeper idea behind it.  The very idea of space travel and exploration is something I am fascinated by.  We look at games as fantasy and escapism, but in regard to Star Explorers, there is a definite element of reality that cannot be ignored. 

After all, we live in space.  The earth, our home for as long as humans can remember, is orbiting its own star, one of billions in our galaxy, one of billions of galaxies in the known universe.  The fact is that we are already in space and it is just waiting to be explored.  My ultimate feeling is a kind of sadness that humans cannot seem to realize how vast an opportunity this is, as we resort to squabbling over the resources of our one, small world. 

Sure, there was a time when space travel was unthinkable, and most of the current conflicts are based on things that happened before this momentous possibility became apparent.  It's also not my suggestion to ignore real injustices and problems on earth, when practical space travel is still a thing that is generations away.  But for me, the very possibility of travel to other worlds makes me think we should strive to overcome our differences, support one another, and work together towards this goal.  We are all Earthlings, are we not? 

Many have suggested that a common enemy, an alien threat perhaps, might help us unite and treat each other with dignity and respect.  I think that may be true, but does it have to be a green alien with big eyes and a laser?  What about the threat of an asteroid that might emerge suddenly?  What about the threat of a solar flare?  What about the expiration of our sun?  These very real threats face us right now (okay the sun is a few billion years off but you get the idea) and we could use them to help us see our shared humanity. 

In Star Explorers, it's already too late.  The Earth is destroyed, and humans have taken refuge in the mothership Altair.  Your task is to find another earth like planet, and to help guide the mothership and keep it fueled on its journey across the galaxy.  So Star Explorers is my way of trying to help us see the vast potential of human activity in space, and perhaps to help us forgive and move past the wrongs of history.  That's a big stretch for a video game, but it's worth a try, right?
3 Comments

    Author

    Michael Klaus Schmidt is an artist and game developer writing about his game Star Explorers

    Archives

    June 2021
    May 2021

    Categories

    All

    RSS Feed

Powered by Create your own unique website with customizable templates.