Emerald Hill
Something something placeholder text, I need something to make sure that the summary generator is working right. blah blah blah here are some more words, I’ll put something more relevant here at some point.
To start I’ll explain how the backgrounds are made in the original game. To aid with the explanations, here’s a somewhat smudgy GIF I took of the background from Sonic 2’s debug mode:
The clouds and Island are loaded and are (in theory) repeated as many times as the level needs to fill the background for the entire level (though the sky never seems to loop before the end of the level).
The large hills at the top of the field are also loaded in this way, however part of the graphics on the hills appears to be 2 pixels wide. Initially I had assumed this was done to save space, however there are tiles on the hill that do not match this pattern and it’s more likely that parts of the background uses symmetry to save space.
Finally, the grass is made up of a few small tiles that repeat themselves several times, meaning that even though the background is so large, the grass takes up a very small amount of VRAM.
the entire background sliced up into several chunks which each move at different speeds when sonic moves forwards or backwards, this creates a parallax effect. what’s interesting about the grass is that it is sliced on every horizontal line of pixels which makes this effect very pronounced and causes the grass to appear very deeply layered, just as a moving feild would in reality.
The water has a relatively complex ripple animation which is outlined in this TSR sprite sheet shown below. Rows of pixels are shifted by varying amounts on a set loop, the shimmer at the top of the water also changes colour. This results in a very dynamic but also consistent looking ripple effect.
The SEGA Mega drive has graphical hardware specifically designed to create visuals like this which allows the game to run very smoothly, However WE does not have this specific capability (at least not in the 2D scene builder without knowing how to use LUA), meaning that I had to come up with my own solution. Naturally, the solution that I came up with at the age of 16 was to upscale all of the graphics to fit a 4K resolution and then save them as separate chunks and dump them into a 2D scene. I then applied the “scroll” effect to each of the layers.
This worked well enough and I even added a sun, some nicer water reflections to make it look a bit better (by which I mean higher resolution) and a particle creator to make some pollen.
There are 2 main problems with doing it this way though:
-
Cutting up and saving each layer takes a pretty long time in GIMP. (the grass is divided into rows 2 or 3 pixels and I was far too lazy and stupid to know how to automate such a thing).
-
Each image I added has a performance cost asscociated with it.
-
There is little benefit provided from upscaling the images before loading them into WE as opposed to just using the scale function in WE. This is something I will discuss more later.
I would save each image as a 4K layer; not just the size of the layer but on a canvas big enough to cover a 3840x2160 resolution. I did it this way so that I wouldn’t have to bother aligning them when they were imported to WE. In total there are 16 4K layers, this means that the background that was once just a decorative asset running on a 7.6MHz CPU is now utilizing around 50% of my GTX 1070.
unfortunately it seems like I didn’t know about colour indexing either so all of the graphics are stored as full 24 bit colour PNGs (which likely wasted a considerable amount of memory). The worst part is that it doesn’t even look as good as it did on the Mega Drive. Because I didn’t cut all of the layers of the grass (choosing to only cut it into 7 layers), it no longer looks as layered as it did in the original game.
I’m considering remaking this wallpaper at some point so I’ll put the updated version here if I ever get around to it.