Jan 7, 2021

Castlevania (NES): Good Stage Design, Horrible Programming

 As much as I love the flow of CV3's stage design, how each of the stages are distinguishable yet work well with the cohesiveness of the whole map, the individual stages themselves are not as well-crafted as CV1's. In my opinion, the first stage of CV3 is the only exception to this rule, in spite of the bells & whistles of the other stages in CV3.

First we have the castle exterior intro, which has practically become a mainstay of the series. We can forgive this in Kid Dracula, since he starts from his coffin. In terms of proper stage design, we can actually see how CV1 and CV3 differ in prioritization of mechanics. In CV1, the player is optionally introduced to candles, then forced to learn whipping mechanics with an onslaught of quick-moving enemies. The player is introduced to stairs, but not actually required to use them until the end of block 1, when the player encounters a dead end and the only way out is up. Jumping isn't even introduced as a mechanic until the player goes into the moat/sewer, at which point it is thrust upon the player, as failure to jump results in instant death. In CV3, they start with the optional candles and stairs, then force the player to learn to jump without fear of repercussion. The player is gradually introduced to the whipping mechanic by way of a single slow-moving enemy approaching the player from the opposite side of the screen. Then the player is forced to learn to use stairs by way of a dead end.

In further support of CV3's design in the first stage, breakable blocks were introduced better, I think. In CV1, the first breakable block is part of an oddly textured wall of tiles obstructing the player. We see these tiles nowhere else in the game, at least not as breakable blocks, tricking the player into thinking breakable blocks have those tiles. Of course at the end of the moat/sewer, there is a proper breakable block, hinted at by means of unreachable platforms below it, but the game already established that a particular tile denotes a breakable block. In CV3, the first breakable block is a series of steps with an oddly under-utilized area behind them. I'm giving the point to CV3. Also, CV3 introduced the player to trap doors, again initially without penalty, very early on. I have always respected that about the first stage's design.

Back to CV1, stage 2 impressed me with how the designers treated it as still an introductory stage. The player is introduced to moving platforms here. The first platform moves from ledge to ledge, allowing the player to simply walk onto it. If the player misjudges the timing, there's a solid ledge below to save the player. To be fair, this does trick the player into thinking they can just walk onto such platforms, which will give them a rude awakening when trying to walk onto the platforms later, which do not touch the edges. Again, there is a solid ledge below the first of such platforms, gently encouraging the player to learn to jump onto the platforms. I hate the spike traps in this stage, and the fact they only appear on one screen throughout the entire game is odd. CV3 handled these things so much better.

Stage 3 in CV1 is just beautiful. Don't get me wrong, it's a garish stage, but I like the little touches to it. You can see Death's hall in the background of the first area. When you climb the stairs, the castle is clearly dilapidated, the upper parts crumbling into ruin. When you walk through the door, When you get to the highest part of the stage, there is that outcropping of wall with no solid ledge over it, further suggesting the castle has fallen into ruin. Furthermore, the whole stage is mostly long ledges with nothing under them, sometimes filling players with nervousness that the solid ledges could collapse under their weight at any moment. And then, at the very end of the last walkway, it's there -- Dracula's keep and the clocktower, along with an unknown tower caught in the rays of the setting sun. That screen every time -- oh man. And no, it's not Death's hall in the sunlight, it's the red tower in CV3.

After beating the mummies, the floor "caves in" and Simon plummets to the catacombs under the castle. This could have been handled better (Simon just falls for seemingly no reason), but this is one of the best explanations for an underground stage. So many games would just have a simple cut scene, or even just dumping the player into a cave for no reason. This at least is logical and it's another staple in the franchise. 

This stage is also entertaining for me, in spite of how frustrating playing it can be. Early on, the player sees bone tiles that can be passed through, so the player knows those bone tiles are not solid. There are four such occurrences at the start of the stage. Then there is a moving platform that must be jumped onto. Between it and the ledge the player stands on is a series of those same bone tiles. By now we've established they're not solid, and yet people will invariably still try to jump down onto them, resulting in instant death. This was intentional! You could introduce me to the designer and have him tell me it wasn't, but I don't care. Clearly this was meant to fool the player. And at that same moment, once the player lands on the moving platform, the stalactites try to push the player off. This is the first time these are encountered and there's no ledge to save the player this time. Forgive me, but this was the biggest dick part of the game. There are only two stalactites, but still, with the mock ledge of bones and these stalactites, this screen was intentionally meant for a cheap kill. I still love it, though. 

Climbing out of the catacombs, you exit out into Greco-Roman ruins. This always seemed odd to me, but since they are revisited in CV3, it makes this brief area interesting. We have the Carpathians in the background and some nice, bright colors. Even if it's just for one short area, this is a nice touch that subtly enhances the world-building of the franchise. 

Right after the ruins, you fight The Creature and Igor. We all know this is just a nod to Universal and Hammer films and would feel out of place if this wasn't a Castlevania game, except they tie the Creature in to the world as well. Death's tower is a dungeon at the lower level, because that's where The Creature was being kept, kind of like The Forgotten One. Once you go upstairs, there are coffins everywhere. You would think it's because Dracula is a vampire, but no -- they were coffins stolen from the cemetery for parts used to make The Creature. This is made further evident by the alchemy lab and electrical contraptions on the next screens. The hall of portraits let the player know they've left the depths of the castle and things are going to get serious.

Hear me out, but I think Death and The Creature got swapped around. I don't know if Death was considered too hard, so they moved him up, or if he was supposed to be the second-to-last boss all along, but The Creature logically does not make sense as a catacombs boss. Death's stage is clearly a reference to Frankenstein. It would make much more sense for Death to be the boss of the catacombs and The Creature to be the boss of the lab. By putting Death as the boss of the lab, though, it further develops the world. The Creature is thus not just a monster movie homage, he represents Dracula trying to overcome Death. The fact that The Creature lurks in the dungeon and Death is not the final boss of the game, we see that Dracula did beat Death on more than one level. 

I won't add much about the clocktower and Dracula's keep. The final stage is just a great stage. We start outside at the top of one of the dilapidated castle walls while the bats we routinely see flying out from Dracula's castle "flutter" about. Then we go inside the clocktower. What I love about this part is we actually see no bottom to the tower. Why does the clocktower in CV3 have cogs all the way down the tower? They should only be near the clock mechanism itself, which is what we see in CV1. I wish we could see the actual mechanism clock itself, but whatever. Then that great dilapidated stairwell with the moon in the background... Beautiful.


But man, oh man. The programming sucks. Not only were the crows bugged out because of a simple typo, I've noticed a couple other enemy details due to sloppy programming. 

Bone-tossing skeletons can jump into walls because they only check for collisions in front of their legs while walking, not while jumping. Mermen have no wall collision checks, making them glitched in the catacombs and allowing them to walk through all solids in front of them. That's also why they get stuck inside the stalactites. 

Then there's the fact enemies can walk off-screen toward the right to their demise, but will reverse direction when reaching the left edge of the screen. For example, axe armors should back up away from the player and reverse direction upon reaching the edge of the screen. However, this only works on the left edge of the screen. On the right edge, by the time this subroutine is called, the axe armor is already in the "kill zone". 

I just realized I never translated the code for Bone Statues, so I looked into that today. All I can say is, "Wow." I see what they were trying to do, but they didn't do it, so the code is garbage. Let me explain. When the Bone Statue shoots a fireball, first of all, all the fireballs shoot from the same position around the middle of the statue. The statue also turns to face the player every step. It's a statue. Turning to face the player. I don't know, maybe I'm being unfair. 

Anyway, for each fireball, the code checks the current stage and runs a unique code for stages 6 and 15, otherwise it runs its generic code. The problem is, all three codes are the exact same code. Clearly, they had planned for one of two things to happen. If you consider stage 6, one statue is nestled on stepped blocks and another one is just above that. We can deduce they intended the statues to always shoot left away from the blocks. They probably scrapped this because the top statue wasn't on the steps and the player could jump over it. This is less obvious in stage 15, which has the statues somewhat out in the open, but arguably intended to shoot right. This leads me to the other possible reason they had this branching code. The fireballs all three statues spit use one of just three possible indexing ranges. Perhaps at one point in development, another enemy was using those same indexes, so maybe they intended to program exception handling for the statues on those particular stages. CV3 did the same thing with some of their enemies, so it's a logical deduction. The issue is the same problem can be found inside the spawners, only more egregiously. Many enemy spawners will set the speed and direction of the monsters they spawn. There is so much wasted memory. Excluding the bosses and their attacks, most enemies in CV1 have their spawner code duplicated two or even three times. I don't just mean multiple JSR calls, but entire blocks copied verbatim throughout the program! 

So here's the deal: I had a hunch the issue I ranted about in the above paragraph may have arisen from porting the code over to the North American release. As it turns out, that was indeed what happened. Specifically, the duplicated code was a left over from the Famicom Disk System version of Akumajou Dracula, which mapped data to lower WRAM ($6000-$7FFF) whereas the NES version used a mapper ($8000-$FFFF). The WRAM data was different between stages, whereas the mapper data could persist across all stages. Rather than reworking the code, they just remapped everything and left the duplicated code intact.

Not to mention, there are two distinct code styles between the regular enemy spawners, and there are less than 20 spawners. They use the same instance index ranges (4-6, 7-8, 9-12), but some have the subroutine for finding an available index inside the spawner's routine, while others call an outside subroutine. It's a mess.

To be fair, CV1's code is more concise than CV3's. Enemy code in CV3 is needlessly verbose. 

Interesting factoid: Instead of destroying an instance, the programmers just change the instance to a different object which destroys itself. Go fig.

No comments:

Post a Comment

©TheouAegis Productions™. Powered by Blogger.