Devlog: Enemy Updates
I've spent the last two weeks focusing on game development, having made a lot of progress. Very little of it is new content, per say, as I've primarily been recreating elements from the old engine -- particularly its roster of enemies.
Implementation has been much quicker, not only because I can reference my older code, but also because of the new tools I've created that improve my code's function & cleanliness. Of course, I can still streamline or re-translate it even further, but I'll save that for another time.
As of right now, only two enemies (excluding o_dracula, and the level 1 bat & zombie) are left, with every other enemy having been implemented in the new engine.
Recent Additions:
- Enemy: Gargoyle Turret
- Enemy: Nightcloud
- Enemy: Fireball (variants: Base / Drop / Demon)
- Enemy: Mudwoman
- Enemy: Crawling Zombie
- Enemy: Spike Trap
- Enemy: Demon (now with a new previously cut attack animation variant)
- Enemy: Ghost Orb
- Enemy: Gillman (new functionality: custom jump height & leaves after attacking)
- Enemy: Draugr Skeleton (Sword)
- Enemy: Draugr Hunter (Axe)
- Enemy: Skeleton Biker
- Enemy: Hitbox Objects (used for melee attacks or extending an enemy's hitbox)
- Streamlined Enemy Projectile functions
- Additional Room Editor functions
Many of the enemies have been improved -- not only in how its code works, but in small ways that affect the gameplay. For instance, the Gillman and Demon now have more obvious attack telegraphing before shooting. I've also added a few new minor tools for extra dev power.

Function: Actor Create Projectile
I've created a new function that streamlines the process of making enemies that attack with projectiles. Enemies will call this function in their attack state, and the projectile created will depend on the information provided to this function.
For instance: I can create "o_fireball", and set it to use a sprite different from its default, so it looks like an entirely new attack, despite being the same object.

But there's more... I've created a set of projectile variables inside o_enemy, which can also be manually adjusted for every enemy instance inside the room editor. I can probably improve it even more, but this lets me customize the specific type of projectile created per enemy.
So two cannon enemies in the same room can shoot totally different types of projectiles. I don't expect to make constant use of it, but it's good that I CAN make use of it.

Function: Actor Create Hitbox
Similar to the previous function; an enemy may call this script to create a new hitbox object -- which can also be used for attacking, but its identity is much more generic. This hitbox can be used for two primary purposes:
- A constant "body part" of an enemy, forming an irregular hitbox shape (like a T shape).
- Generated during a state-exclusive enemy attack (like swinging a sword).
This hitbox can be destroyed after it has served its purpose, or it will simply follow its owner -- effectively acting like an extension of that owner (since an enemy's collision mask is typically only allowed to be a simple rectangle with four sides).
I can adjust its properties, like whether it will accept damage from the player. I can also apply a unique set of weakness values to the hitbox, so it can either serve as a weak point (like a big eyeball) or even block damage from hitting its owner (like a shield).


Now I can make it so that it dealing damage to an enemy requires hitting a specific part of its body or even reward players for hitting more vulnerable parts of the body. This was already an idea I had played with in the old demo, but the new weakness system lets me do even more.
It is worth noting that:
After implementing the remaining two enemies (since the rest are variants or a lazy boss), I'll only have a handful of gameplay features left to recreate:
- Level: Crumbling Floor
- Level: Mel Zones (updates the dialogue used by the Mel Button)
- Level: Conveyor Belts
- Mechanic: Show Portraits (previously used in game over)
- Items: HP / MP Upgrades (And the Item Memory to ensure they can't respawn)
- Dialogue System
While I may not recreate all of these systems immediately (or in the same way)... We've almost reached a point where the new engine is on par with the old engine in terms of development capabilities (that is, assuming I haven't missed anything and there aren't any hidden bugs). As a result, we might be able focus on creating new content & systems shortly after. Very cool.
-
Don't forget to eat & sleep.





