Tails Mechanics
As many of you already know, episode 5 is going to feature Tails as the primary character!
Here's the awesome title screen by Gwen btw, for those who maybe missed this posted in the Discord:
Today, I wanted to post about Tails' left-shift ability (e.g. special game map mechanic), which as you might guess is the ability to fly around the map, and how I am approaching it.
Like the layered map system built for episode 4's Northern Mountains maps, which allows game maps to have more depth, in order for Tails' flying ability to feel right, I am going to need to simulate depth and height of game objects. Here is more-or-less my plan to make it feel right...
This trick can also support elevated platforms, like where you climb the ladder to get up the big tree at the center of Knothole.
Platforms purely in the sky, like the one Bunnie can hookshot to from the second level of the tree, can also use this feature. So this should cover all of our potential use cases.
The generalizable use case is to just create a ghost collision game object from the top edge of a walkable platform to the ground, and then define the "depth" value on that object to be the number of vertical tiles that make up that platform's walkable space * tile height (32).
When it comes time for Tails to try to land somewhere, we will then take advantage of the layered map system so that when you land "on top" of a knothole hut or knothole war base thing, you are now in a higher map layer, and the space above the hut or base has collision boundaries around the walkable area, as you'd expect. Also, obviously when you are flying around, you are also in a higher map layer, which is why you are not colliding with things you were previously colliding with when you were walking.
Anyways, it's a bit more annoying to get right than it might seem. Will post a video at some point once I feel like I have got it, because I just feel like this is such a cool feature.
This sounds like a beast to code and test, but amazing if it works.
ReplyDeleteThanks! Yeah I am pumped. Thinking about flying around Knothole and all the fun puzzles and gameplay this will allow for helped me break my coding dry spell on Sonic RPG heh.
Delete