UPDATE 04/11/2019: This guide is very outdated. Since this day me and my friend MrLevRocks have updated this and published a new version of it in SFGHQ. https://www.sonicfangameshq.com/forums/threads/an-introduction-to-the-basics-of-stage-art-in-2d-sonic-games.363/
The intention of this guide is to show some of the things which I, PVic, personally find to be important. I'm not any god in making video games so many things here are either missing or just my opinion on what I think is better. All I want is to help people to not have to go through the same steps as I had to.
[1] - Tiling.
Things like the image below are very ugly and are quite common in the worst fangames. Never do something like this.
[2] - Borders
It took me two years to figure out how much borders in tilesets are important (The first game which I implemented borders in my tilesets [intentionally] being Sonic BFSS). It makes ALL the difference.
[3] - Decorations
Bland stages can take away the immersion of the player from the stage. There are people who don't like to decorate stages a lot since it can look cluterred but I'm honestly always fond of very decorated stages, as long as they fit.
[4] - Variation in the tileset.
This is a bit hard to actually do, but it's important. Most fangames nowadays only follow the basic Green Hill pattern example which is just a 32 x 32 pattern and slap a grass on top. That is not even how Green Hill works.
The one in the top is the original Green Hill, the one in the bottom is from a mediocre fangame.
I wasn't quite able to do much about it in this image to exemplify the idea, but I attempted to add the Wood Zone bushes and that coconut looking thing to add some sort of variety. Analyse 2D Sonic stages to notice how it works yourself. I find the best examples to be Studiopolis and Chemical Plant.
[4] Background and in the foreground
One of the most basic concepts is parallaxing. Most Sonic Worlds shovel ware lack parallax scrolling.
Backgrounds also always need to have some sort of animation happening so it looks like something is happening/ to add more life to the game. In Green Hill the clouds have movement, the mountains have those waterfalls, and the water has an animation.
In this example I added the Green Hill Zone Water and some bushes in the foreground to exemplify my point. The clouds would be moving to the left, the water would be animating and there would be a layer of bushes in the foreground
There are a few other things you need to know, specially things such as the color pallete, but some of this stuff can be quite complex for beginners so I skipped over them, but I hope atleast got some of the basic ideas down.
Since I started to make fangames I had to figure out this stuff on my own, since there was noone there to guide me own on what to do. I hope this helps atleast someone out there who is trying to learn how to make their own fangame.