Bigosaur blog

Seeders Puzzle Reboot

It's been 4 years since I released my first Steam game: Seeders. I took a hard look at it and from this point of view, I was able to see all the shortcomings and problems it had. There was no character animation, and graphics has been lacking detail. Although the puzzles are good, the visual looks were poor. But even some puzzles, although they had good ideas behind them, were executed poorly. Players had to spend too much time actually doing the thing once they figured it out.

I decided to give a major revamp to the game. Big enough to set it up as a separate product. This time, it would be the game I really wish I made in the first place, but I just didn't have enough experience at the time. The new version is called Seeders Puzzle Reboot. Here are all the changes compared to the original Seeders Classic game:

Improved graphics. Some of the graphics used to look really plain and boring. If you played on 1080p screen or larger, you could even see the textures repeat. At the time I made the original game, I was impressed by simple graphics of games like VVVVVV and Thomas Was Alone. What I learned since is that although consistency is more important than graphics fidelity, the original Seeders had consistenly poor looking graphics. It actually took less effort than I anticipated to bring the graphics into good shape. Too bad I didn't see this as a problem in the original game.

Character animation. The old game had almost no character animation. Out main hero would look stiff and it would make the gameplay look stiff and boring as well. As I gained a lot of experience animating Son of a Witch, I put that to use. The gameplay now feels fluid and the main protagonst feels alive. There was a lot of work to be done, because there are 16 wearable hats in the game, and each one was drawn separately, so I had to make that work with animations.

No ambiguous puzzles anymore. For some of the puzzles seemed hard or impossible to execute, because the puzzle setup would lead the player into thinking that some of the solutions is possible because you might barely be there. It seemed like you can solve it in some trivial way only if you were precise down to the pixel. Based on discussion I had with some players on Steam, there were even some puzzles that could be cheesed that way. I redesigned all those puzzles to make sure it's obvious that the easy/wrong way is not possible, and players have to think of something else.

Hardest puzzles are optional. Some of the puzzles were really hard to solve (for example, the machine that moves parts of the level in level 3) or execute (falling through the laser-protected hole while a beryillium pipe is falling at the same time protecting you). And for some, it took a lot of time to repeat if you made an error (like those 4 alien robots at the start of level 5). All those puzzles are now optional, you can do them to get more wearable hats. Because of these changes I had to draw more hats, so there are 17 in the game now (default + Jason's + 15 to collect).

More Co-op puzzles. While the co-op mode in the original game is fully playable, it felt like some of the puzzles were really lacking co-op support. Now, many of the puzzles are still the same a single player, but you have to solve them in different ways to enable two players to go through. This is especially visible with lasers in level 5, where you have to pass the vehicles to each other, or carry the other player on top of spaceship, etc. But I also added more co-op only puzzles (i.e. you won't get to see those in single player) and some of the existing puzzles were redesigned for co-op by removing some pieces which made them trivially easy or adding some pieces that made them more interesting. I also left some of the tricky puzzles from the original mode to be available only in co-op mode, as I expect two players to be smarter collectively.

Music improvements. The main menu music was just too intense. It's a catchy tune, but I really started to cringe every time I launched the game - and I had to to that hundreds of times during testing. I replaced it with a nice, relaxing tune that sets a nice atmosphere, but never gets boring nor annoying. I also migrated my audio mixer code from Son of a Witch, so now all the songs have normalized volume. It was all over the place in the original game and you usually had to adjust the music volume between levels.

Added missing sound effects. One of the reasons the game felt stiff and boring was because there were next to zero sound effects. You would push a rock or a metal piece and they would feel like paper cutouts instead. You would jump on top of spaceship and there was no sound. I have added over a dozen missing sound effects and coupled with music volume fixes I wrote about above, playing the game now feels like you are really there and your actions have impact.

General polish. There are lot of small things that make the game look and feel nice. Simplest things like menu transitions, subtle animations when you select menu items, etc. I built these systems for Son of a Witch and now I migrated them back to the Seeders engine as well.

Seeders Puzzle Reboot is that great puzzle adventure game that the original Seeders was supposed to be from the very start. I just wasn't experienced enough at the time to make it this good. Seeders Puzzle Reboot will be exclusive to Nintendo Switch for now.

Feedback & Share Bigosaur, 2019-07-02

Paladin / Alchemist / RPG / Arena update

A free DLC-sized update is coming out on March 21st. At first I wanted this to be a separate DLC, but I decided that splitting the player community is a bad idea and earning just a little bit more money isn't worth it. I want everyone to enjoy the same game.

New features:

  • new RPG game mode where you keep all gear and restart the current level when you die
  • new Endless Arena mode where you fight waves of enemies
  • new hero: Paladin, who has divine shield and does double damage to undead
  • new hero: Alchemist, who has a Golem companion, and prepares potions
  • 8 pets with new effects: Crocodile, Mouse, Bee, Monkey, Whale, Cow, Ladybug, Cat
  • 3 new random potion effects: Cold blood, Veteran Elixir, Astral Projection
  • 6 new special effect items: Ghost orb, Critic’s Shield, Paladin Shield, Alchemist’s Visor, Halo, Ancient Voodoo Doll
  • 10 new weapons: General Sword, Cripling Katana, Executioner’s Sword, Dark Slayer, Splitting Axe, Paladin Sword, Alchemist Sword, King Cobra Staff, Snow Tiger’s Paw, Steady Shot Bow
  • 6 new achievements
  • 2 new allied troop summons: Baby Yeti, Stone Golem
  • added a new blocked challenge room in the forest
  • added a new challenge room with baby dragons
  • added a new challenge room in the ice level (it’s a surprise)
  • added a quest room in the ice level to unlock the Alchemist hero

Gameplay balancing:

  • allowed summoning mercenaries into boss fights (except the final boss)
  • removed slowdown effect from Heavy Boots
  • Retort no longer creates mana potions
  • only one Retort shows for sale in shops
  • removed poison immunity for the final boss
  • significantly increased Poison Cloud spell damage
  • Poison Cloud effect scales with enemy size
  • improved AI for Snail, Ram and Snake pets
  • using teleport staff twice returns you to the starting point
  • fixed runestone drops in various barbarian challenges


  • Ethereal bow now shoots through barrels and boxes
  • Dog pet doesn’t take mercenary’s beer in the tavern
  • Foundry doesn’t melt mercenary’s beer anynore
  • Thief and Ringleader don’t jump on allies when confused
  • fixed bug with item drops when Yeti Elder and Earth Golem roll
  • fixed drawing position when Barbarian is mounted
  • fixed rare sound effect bug with Yeti babies
  • fixed position for some of the teleportation animations
  • fixed text showing last level seed instead of control hint after player dies
  • fixed occasional crash on MacOSX
Feedback & Share Bigosaur, 2019-03-14

Replaying hero unlock quests

Some of the players asked me how to replay quests that unlock heroes. You can do this by clearing the achievements that unlock them. To clear the achievements, you need too enter the DM mode. DM means Developer Mode or Dungon Master, whichever you prefer.

  • Start the game and press T to open the chat box.
  • Type /dm1 and press Enter.
  • Type /ca ACHIEVEMENT_NAMEsee below to clear the achievement. For example /ca EYE locks the skeleton hero.
  • Type /dm0 to exit DM mode.
  • Close the game completely and start it again.

Here's the ACHIEVEMENT_NAME for every hero:

  • Sorceress: /ca PROLOGUE
  • Druid: /ca DUCK
  • Archer: /ca ARCHER
  • Pyromancer: /ca FIREMAGE
  • Skeleton: /ca EYE
  • Rogue: /ca ROGUE

Barbarian challenges achievements are named BARBARIAN1 through BARBARIAN12.

Feedback & Share Bigosaur, 2018-11-21

Big Son of a Witch update

Version 3.7.3 is online:

- new hero class: Rogue. Special ability is to use the sneak attack as the special attack with any melee weapon. You can still use the weapon's regular rage attack if you use it in the off-hand slot. He also has a special item that can unlock any door (except boss room doors), so you can unlock treasure rooms and escape tough battles
- Added a bunch of new achievements
- New potion: Vampire blood (get HP from kills. Multiple potions stack)
- New potion: Pickpocket (earn extra gold until you get hit. Stacks)
- New potion: Confidence (deal extra damage when full HP. Stacks)
- Added a new combat item: Sticky bombs. You can plant these as traps. When an enemy walks into one, it activates.
- Added a new pet: Racoon, who randomly drops sticky bombs across the room
- Added a new special room in the castle: the Gallery Room. This room is filled with enemy portraits and you can pick your favorite enemy to do double damage to them.

New NPCs:

- Join the Vampire Slayer NPC in the catacombs and help her kill a vampiress or the vampire boss for reward
- Dwarfs now sell stuff in the ice level
- Dwarven Blacksmith shows up sometimes and gives you ability to smelt weapons into runestones which are used to upgrade other weapons
- Mercenary NPC in the castle tavern gives you an item which can be used to hire mercenaries for fixed amount of gold. DON'T TOUCH HIS BEER!
- Vampire Sword now gives HP while hitting enemies (instead of on-kill)
- A Redhead Warrior NPC might challenge you for a duel on the battlements

Tweaks and improvements:

- Redhead Warriors in the desert now buff their swords before doing the petrify attack
- Disabled invulnerability frames for revival in dungeon shops
- Reviving in regular game now gives 41HP instead of 61HP
- Celestial Hammer rage attack now strikes all enemies in the room
- Darkness, Confidence, Money is Power, Mega Boost effects scale the skill percentage instead of adding to it. For example, if you have 50% melee and 100% darkness, it results in 100% melee skill (not 150%).
- fixed bug when the remote player could join the game twice (i.e. two heroes would show up) if (s)he pressed the button twice too quickly
- fixed bug then Steam library is installed in a path with non-ASCII characters
- minor fixes and tweaks to UI
- updated some of the translations
- dialogue in the intro story now supports translations

Have fun playing!

Feedback & Share Bigosaur, 2018-09-21

Son of a Witch launches on Switch September 4, 2018!

August 22, 2018 -- Son of a Witch, the adorable action roguelike that won over hearts with official selections at IndieCade Europe 2016, IndiePrize 2017, and Game Access '17, is about to launch on Nintendo Switch on September 4, 2018.

After 3 years of development and a successful launch on Steam where it currently holds 92% positive rating, the game is about to hit the console platform where its couch co-op gameplay will shine. A new release trailer highlights the magical hack and slash hijinks players will be able to enjoy in solo, co-op, and four-player sessions.

Son of a Witch recalls the compulsive replay-ability of your favorite roguelikes but wraps it all in a charming package, making it a lot more welcoming to a wide range of gamers than your standard fare. But don't let the cutesy graphics fool you: Son of a Witch offers deep mechanics that reward constant experimentation and learning. Son of a Witch boasts over 120 unique weapons and items to discover. Players will only find a small section of these in each run, meaning the game is completely different every single time you play. There are also 7 playable characters with wildly different skill sets and abilities, over 20 bosses to beat, and 30 pet animals to find.

Bigosaur is expecting the game to be even more popular on Switch, because players often like to play in couch co-op setting on the console. Milan Babuškov, creator of the game, said "After completing Castle Crashers for the second time, I started thinking: what would make a beat'em up game more replayable and interesting in the long run? Inspired by some roguelike games like The Binding of Isaac, I added procedural map generation and over a hundred different magic spells, items, weapons, quests and game mechanics that you can combine in interesting ways. Always having a new map to explore and weapon combos to discover is the reason many players already have 100+ hours in game on PC. I'm excited to see the community feedback on Switch, as it will be a great motivation to continue improving the game in the future."

Son of a Witch will launch on American eShop on September 4, 2018. Check out the release trailer here.

About Son of a Witch

Key Features

  • Explore non-linear procedurally generated dungeons
  • Fight your way through random encounters with monsters and a selection of 24 bosses
  • Find shops, treasure rooms and challenge rooms
  • Complete NPC quests to unlock playable characters
  • Get help from one of 26 cute pet companions
  • Drink random potions to power up or increase the challenge
  • Identify and use powerful magic scrolls
  • Every weapon has some unique ability or attack type
  • Every item you find has its use or special mechanics
  • Single player and up to 4 player co-op
  • Three diferent play styles: melee beat'em up, magic shooter and archers sniping enemies from the distance
  • Permadeath. A new world is created every time you start the game, so it's always fresh and interesting to explore

Game information

Title: Son of a Witch

eShop page:

Genre: Fantasy, Indie, Co-Op, Roguelike, Hack and Slash, Dungeon Crawler

Developer: Bigosaur

Publisher: Bigosaur

Nintendo Switch release date: September 4, 2018

Screenshots, graphics assets:

Contact information

Milan Babuskov, Bigosaur

Feedback & Share Bigosaur, 2018-08-22

Steam release!

The first complete version of Son of a Witch is now released on Steam. After almost 3 years of development the game is finally complete. We have gone a long way since being featured by IndieCade and greenlit by the Steam community. With almost weekly updates it has been an exhausting but also a very enjoyable experience.

This is the first release that covers everything I planned to make initially, and much more on top of that. But, this is not the end. There are many more things to come. During the development both the players and myself got a lot of new ideas, so you can expect to see some big updates in the future: more weapons and items with new effects, more mounts, more pets, more special rooms and NPC quests, and more magic.

The next step is porting the game to Nintendo Switch. I plan to do that over the Summer and have the game ready for late August or early September.

After that, I plan to have one big update with new content, most probably for the holidays by the end of the year.

Feedback & Share Bigosaur, 2018-05-16

Mixing beat’em up brawler with bullet hell shooter in a single game

The initial idea for Son of a Witch was to build a game that could be easily described as Castle Crashers meets The Binding of Isaac. I wanted to have endlessly replayable beat'em up experience with much deeper mechanics and ranged combat. But how do you combine two pretty different play styles?

Beat'em up vs dual stick shooting

In beat'em up games you have to line up with the enemy vertically to hit them. In a bullet hell shooter like Enter the Gungeon you can shoot in all directions. These two simply wouldn't work well if you just mashed them together, so I introduced some modifications. The main one was restricting ranged combat to the horizontal direction. You can shoot to the left or to the right. This goes for arrows, thrown weapons and orbs (magic projectiles similar to tears in Isaac). With some upgrades you can get spread shots, or mirror the projeciles on the other side, but the basic targeting is to the left or right.

Having to line up to attack with both melee and ranged attacks made the combat easy to read and perform even when there are different types of heroes and enemies fighting. The standard vertical evading of melee hits now works for ranged projectiles coming your way as well.

Level layout

Beat'em up games usually have horizontally long, linear levels. There's almost no exploration, you just head to the right. I wanted to give the players that great sense of exploration you get from roguelike games: the map is randomly generated and non-linear. Sometimes it branches, sometimes it loops back. You are guaranteed to find a treasure room on every floor. There are 2-3 shops and often special rooms with NPC quests or mini-game challenges. Even if you find the boss and exit to the next level early, it's worth exploring the rest of the level to find better gear and level up your heroes.

During playtesting I found that most players like exploration. The only problem could appear in 4-player co-op games when sometimes the players would spend too much time arguing which way to go. This is especially visible for situations when many new players join the game and just want to move ahead without discovering all the subtle mechanics the game offers. For such players, I added a Party Mode which features a linear level layout, but still gives you random weapons, shops and NPC quests.

Balancing ranged and melee combat

Initially the ranged characters had a huge starting advantage: they could hit an enemy without them striking back. If we just took your standard beat'em up monsters and threw them in a game where all the heroes are ranged, it would be really hard to provide a good challenge to the players. Either the enemies would have to be very fast to close the distance or they would have to have a lot of health to survive until they can threaten the player. Because of this, the enemies in Son of the Witch were designed differently: many of the enemies have range attacks and melee-only monsters serve as live protective moving shields. They usually walk in front of ranged characters and try to engage in hand-to-hand combat with the players while the ranged units are attacking them from the distance.

Having more ranged enemies results in having to do more dodging in Son of a Witch than your regular beat'em up game. There are often some projectiles coming your way and you have to evade them. Since the projectiles are only flying horizontally, there's less dodging that your regular bullet hell requires. So, this mix is somewhere in the middle and you don't need inhuman dodging skills that some of the bullet hell shooters require.

With all this said, you might still feel like the melee heroes are at a disadvantage. To balance things out, I added more mechanics that give melee fighters an edge in some different areas: While magic ranged attacks only deal damage to the enemies, the melee attacks also stun them for a second, interrupting their attacks or magic spells. If you use a weapon with the quick attack (all swords and some axes) you can stun-lock most of the enemies and just keep attacking until they die (or some other enemy hits you). Beside this, melee weapons have special rage attacks that can knock down enemies and stun many of the bosses.

One of my design goals was making sure that melee and range heroes synergize when playing together in co-op games. Having different combat mechanics actually works really good. The knights can stun enemies and keep the ranged attackers busy while the mages shoot them from the distance while buffing and healing their allies.

Knights can use magic too, just not that effective

Beside magic projectiles, there's a wide range of magic spells. There are many different magic staves and every staff has a different spell effect: poison enemies, set them on fire, freeze them, slow them down or speed up your party, shoot lightning, create magic turrets that shoot at the enemies on their own, create obstacles on the screen, teleport yourself into safe spots, etc. Son of a Witch allows you to have multiple weapons at the same time, so you can combine different spells during the same fight.

The magic is very powerful, so at first it seemed like the mage heroes would once again be much more powerful. To balance that out, I allowed for melee fighters and archers to also use the magic items, but with less efficency. For example, the Snake Staff will buff a weapon with poison, but the damage the poison has a base value that does scales with the heroes Magic skill. So, a Knight hitting someone with poisoned sword would inflict 3 poison damage per tick, while a mage doing the same would do 5 poison damage per tick. Another example would be the Earthquake staff that knocks down all the enemies and breaks the rocks with usable items weapon upgrades. When a Knight uses the staff, it would knock down everyone and break 2 rocks on the screen. When a mage uses it, it would break 5 rocks on the screen. Some other weapons work completely the same. For example the Teleport staff just teleports the hero regardless of the level of Magic skill they have.

Item and weapon drops

When you mix two different play styles, you need to make sure that the player gets upgrades and powerups they can use. If I'm playing a mage hero, I don't need a triple-damage upgrade for an axe type of weapon. This can be a big problem for procedurally generated games. If you leave everything to the random number generator, your game won't be enjoyable.

In Son of a Witch, I solved this problem by rating every item and weapon in melee/magic/ranged category and then multiplying the drop rates with the skill levels of heroes in each of the categories. For example, let's say we have an item with a drop chance of 10% and it's an item only used by Melee characters. Let's say it's a single player game, and the player selects a Mage hero, who has 30% Melee skill. At the start of the game, we reduce to drop rate to 30% of the original, making it on 3% chance now.

You might wonder why don't we disable it completely? It's because it's really rare that a weapon or item is completely useless. Even if you are a mage, having a sword available could be useful to do some quests (for example, when the pricess is attacked by goblins, the stun-lock ability of the swords is really useful) or complete some NPC quests easier. Beside that, the game gives you many upgrades during a run, so you might sometimes decide to switch hero class or become multi-class at some point and having at least some of the weapons available helps.

By the way, Son of a Witch launches on Steam today. Check it out.

Feedback & Share Bigosaur, 2018-05-16

Designing death in co-op roguelikes

Single-player roguelikes have a somewhat easy task when it comes to player death. The genre itself dictates that once you die, it's game over. At least, if we adhere to the strict definition of roguelike. Some of the games allow for some progress to spill over into the next game, but all of them make you start over. Without this mechanics, the game isn't considered roguelike.

Now, what happens when two or more players are playing? Is it Game Over as soon as one of the players dies? Or do you allow reviving the players? What conditions need to be met for the player to revive? Answering these questions makes a huge difference in the way the game is played. When deciding what's the best approach, one should consider what is the way you want your game to be played. Do you want to limit the game to player pairs of similar skill level, or you allow newbies to play together with pros? This is an important decision, because roguelikes are often hard games to play. Let's look at some examples and see how different decisions influence the gameplay.

Enter the Gungeon

Enter the Gungeon has limited co-op mode - only two players and the second player can only play a single character. Once a player dies, he becomes a ghost with very limited gameplay options. The revive mechanic is rather interesting. There's an item that allows you to revive the other player once. This works pretty good until a player dies for the second time. After that, you can soon get into a position where only one player plays for a very long time as the only other way to revive dead players is to beat the boss or find and open a chest. This means that Gungeon is pretty hard core and expects both players to play well. If one of the players is a newb, he will die often and get bored waiting to be revived all the time.

The Binding of Isaac

BoI doesn't really have the full multiplayer game. Only the main player gets all the powerups and pickups and others can only play as babies with limited power. The main player shares their health with babies, so it's easy to revive them when they die. It's an interesting mechanics, which makes it more enjoyable as there's no waiting time. However, less skilled players can quickly ruin the game for more experienced ones who have to decide between spending most of the game playing with low health or telling their partners to go hide in a corner and/or wait to revive.

Rampage Knights

In Rampage Knights the dead player turns into a ghost who can move around and knock enemies into pits or interfere with their attacks. With some item upgrades, the ghost can also poison enemies or set them on fire. This is a pretty good mechanics because newbies can actually kill enemies pretty quickly even when dead.

The player stays in the ghost form until 10 enemies are killed. This is a decent solution to the death problem, but it does have its drawbacks. The main problem is that the players are revived to full health, so the players can simply take turns dying and go through the whole game with 30+ deaths. Another problem is that completing a level gets the dead player revived as well. So if someone is low on health after the boss fight, he can simply jump into a pit and get full health at the start of the next level. All this makes co-op in Rampage Knights much easier than the single player mode.


Spelunky also has the dead ghost mechanics. Dead players can knock down some enemies into pits or spikes, activate traps, etc. To revive them, the players have to find and hit a coffin. This is a good solution, however sometimes the dead players can get bored while waiting. Although they can do stuff, it isn't much compared to playing the game while alive. The only big problem with this approach is that the coffin only revives one player, and there's only one coffin per level. So, if you play 3-player or 4-player game it means that some of the players would have to wait for two or three levels before they even have a chance to be revived. This pretty much ruins any fun for players who want to complete the game and not just goof around.

Castle Crashers and Lost Castle

Castle Crashers isn't really a roguelike, but I included it because of an interesting revive mechanics that was also reused in the recent Lost Castle roguelike. When a player dies, others have to come to them and revive them. This means they have to stand still and not fight the enemies for a while. While this mechanics works pretty good in Castle Crashers, in Lost Castle the enemies are much more aggressive, and it's almost impossible to revive dead players until the room is clear of enemies. Since the game has some enemies with high health this can take a while and the dead players can quickly get bored. Combining an experienced player to play with a beginner is not an enjoyable experience for any of them as the newb will keep dying and the pro will spend a lot of their time trying to revive the dead ally instead of fighting the monsters.

Son of a Witch

When designing death in Son of a Witch, I took a look at many games and weighted carefully what would be a good approach. The death mechanics had to satisfy the following goals:

  • The game is a roguelike, so death should have some weight
  • Players shouldn't be able to revive each other infinitely in a loop
  • Pros and newbs should be able to play together and both enjoy the game
  • When someone dies, they shouldn't have to wait long before they can play again with all of their powers

The goals were simple, but achieving them took a bunch of iterations. When I presented the game during EGX, I made changes to the way the death works every day and then watched how it affected hundreds of players who played the demo. It only started to work well when I mixed up a couple of different mechanics:

1. The main way to revive players is to kill enemies

When a player dies, he remains dead until all the enemies in the room are gone.

2. Allow reviving during the battle, but at a cost

You can revive all dead players with a Life Staff which can be used once every 5 rooms. With mana potions you can do it more often, even multiple times per battle. This means that the players can stack up on mana potions for tough boss battles.

The Life Staff is pretty common drop, but it's isn't guaranteed to show up in every game and you don't know when or where would you find it. This encourages the players to explore and unlock every gold treasure chest they find.

Additionally, undead heroes can also be revived with the Staff of the Dead which animates the undead

3. Players should be encouraged to cooperate

Once a player is dead, a 20 second countdown starts, and others have to revive him or clear the room of enemies. If the players have no Life or Death Staff, they have to fight quickly to save the game. The bosses have more HP, so the timer is set to 60 for the boss battles.

The possibility of the countdown timer makes the players care about each other more. Experienced players will seek to help newbies during the fights to prevent them from getting overwhelmed and killed.

The timer also removes the boring parts. If a player dies he knows that in 20 seconds he will either be revived or a new game will start. In any case, he won't have to sit and watch while his friends are having fun.

4. A true roguelike offers alternatives

Beside the Life Staff, there are a couple of items that can be used to instantly end the battle and revive the dead:

Barrelize scroll quickly turns all the enemies into barrels and thus ends the battle. It's risky to do with bosses because they turn into big exploding barrels.

You can use the Peace scroll that makes all the enemies peaceful. It doesn't work for bosses, so it's useful outside the boss fights.

You can teleport away from the room with enemies to another room. This resets the timer to 20 seconds or stops it completely if you teleport into an empty room. There are two ways to teleport: The Random Teleport scroll and the Silver Coin which teleport you into a random shop on that level. The teleport scroll can be dangerous as you might show up in a boss room. The best time to use it is during the boss fight after you have cleared all the other rooms in the level and you know it will teleport you into an empty room.

5. Have an easy-mode character for newbies

Sometimes it's best to prevent players from dying at all by allowing them to heal more often. In Son of a Witch, there's a playable healer character who can create food to heal the whole party. It's a great choice for new players and having some extra healing options can also help an experienced player when they are playing together.

Feedback & Share Bigosaur, 2018-05-12

Simple A* pathfinding alternative with interesting side-effects

A* pathfinding has become de facto standard for pathfinding in 2D games. However, it does place some constraints on your level design. While it works great in tile based games, I wanted to be able to place objects randomly at any pixel coordinate in the world. With big map and many of units it can get expensive to compute. In this case, developers usually just optimize their game loop, so that the algorithm doesn't get called for every render frame. Since my game is fast paced, I wanted AI to be really responsive to players moving around, so I searched for alternatives.

Another problem with A* pathfinding is that it's almost perfect. Enemies always take the optimal path and become too predicable. I wanted to have some randomness and surprise factor without having to complicate the AI code too much. I also wanted some enemies to be dumb and sometimes not "see" the way to get to the player immediately. But I didn't want them to become too dumb and get stuck on simple obstacles.

And then I discovered steering and obstacle avoidance. The algorithms are simpler, easier to implement and less expensive to compute. You can tweak many parameters to get different behaviors. With simple tweaks you can get the enemies to defend some areas, wait to attack until the player comes closer, act as a grounp, surround the player, etc. With a little bit of experimentation you can get some behaviors that seem very intelligent.

Since I'm making a game where the players usually have to line up with enemies to hit them, I decided to make that easier for players by having the enemies do the same whenever they can. When the enemy is far away, their priority is to line up with the player while coming close enough to land a hit:

The player can now just move to the right and not worry about having to line up themselves. Additionally, if the player has a ranged attack (throwing axe, shooting arrows, fireballs, etc.) he can simply start shooting and the enemy will make sure he gets in the path of the projectile before it arrives. This makes the combat feel fluid and easy to execute.

For most brawlers the approach above would be enough. Castle Crashers, Rampage Knights and similar games manage to get away with such simple AI because they made their levels with almost no obstacles in the middle of the screen. For my game, I wanted to have more interesting screens with more stuff in the middle: rocks, trees, bushes, pits, etc. on the outside and furniture inside buildings. So, AI needs to be smart about those.

Enter obstacles

Now, what happens when we have some obstacles in between. My approach was simply to allow the enemy to hit the obstacle and then figure out how to go around it:

How do you decide which way to go around? Remember, we are not trying to make the enemies perfect planners, so they can make mistakes. One approach is to simply check which path to go around the object would be shorter. This works fine, but I found out that simply choosing a random direction (UP or DOWN when the goblin hits the bush in the above image) works much better. When you have 4-5 enemies going after the same player, they would split and go around that tree using upper or lower path. It makes behaviour for a group of enemies seem more natural.

What if the unit has two paths of which one is significantly longer than the other? Or what if one of the paths leads to a dead end? Without going back to full A* pathfinding, we can simply make the enemy figure out they took a wrong turn and reset their 'going around the obstacle' state. We can have a simple variable saying how long should avoiding an obstacle take and tweak that based on the level design and the behavior we want to get.

Protecting an area

Now, let's say you want the enemy to protect an area and wait for the player to come closer? We don't need to change any of the AI code at all, just wall off the relevant part of the level and make sure it's longer than the 'longest path to go around' variable from the main AI code I mentioned above.

The green line in the image above shows a long fence the enemies won't cross because the parameter for going around the obstacle is using a lower value than the green line's length. As the player comes closer to the bottom of the screen, the enemies start to have higher chance of coming out of their area to attack him.

This works pretty good in more complex screens. Having the enemies divided naturally by the level layout makes the game more enjoyable for the player as he can fight enemies in multiple stages stages.

In the image above you can see three disctinct areas for combat. The player is now in control and can decide on the tactics. Does he storm the enemy in the middle and then have two separate groups to fight. Or he would stay on top of the screen and allow all three of them to come closer so he can use combo to hit all of them with a single shot.

Having the enemy AI constrained by the level layout makes the combat much more tactical than your standard beat 'em up. Now you just need to create interesting level layouts to give enough options to the player.

Using steering to avoid erradic movement

Now, what's steering? Since we run the obstacle avoidance AI all the time, we want to make sure that the enemy movement feels natural. Going diagonally towards down-left and suddenly turning up would feel strange. So, when the player drastically changes his position, we try to rotate the enemy movement in 45 degree steps. This makes the enemies movement fluid and easier to track. Of course, if you hit an obstacle, you would do a 90 degree turn instead.

Sometimes you just want the unit to stop and go the other way. For example, if the tracked player is dead or escaped the room and the enemy starts tracking another player on the other side of the room. In these cases I allowed sudden turns because it feels ok in my game. But if you try it out and it feels wrong, you can smooth it out by steering in 45 degree steps every X milliseconds until you start going into the right direction. The exact value for X depends on the type of unit moving, so you should experiment until it feels good.

Group behavior for enemies

If you make the enemies treat each other as obstacles, you can get very interesting side effects. Most beat 'em up games allow enemies to walk through each other, but if you forbid that and use obstacle avoidance for AI, you can get cool group behaviors. For example, the enemies spontaneously form groups like in the image above without any changes to the base obstacle avoidance code presented so far.

Surrounding the player

In the images above, you can see three enemies approaching the player. As first one starts to attack, the second one is avoiding the obstacle, i.e. avoiding the first attacker. As he gets close enough, he starts attacking too. In my game the weapon hit boxes are a little bit bigger vertically than the unit boxes, so you can attack an enemy if you're standing adjacent to them vertically as well. From the still screenshot it isn't obvious, but when you see it happening in real time it makes perfect sense.

After that, the third one comes and avoids the initial two attackers. While doing so, he gets past the player as well. Then he turns to face the player and starts attacking from the other side.

What's most interesting is that all of this happens automatically with the standard obstacle avoidance code. You don't have to program some special AI code for it.

Since Son of a Witch is a fun and cartoony game, I only used the most simplest algorithms, but you can make it more sophisticated if you want to. I recommend checking out the red3d website for more behaviors like Seek and Flee, Pursue and Evade, Containment, Wall Following, Queuing (at a doorway), Flocking (combining: separation, alignment, cohesion), etc.

Feedback & Share Bigosaur, 2018-05-06

Past blog entries

Game website | Graphics, screenshots, .gifs for media Website Home Page Website Home Page Blog main page YouTube channel Twitter account Google+ page Facebook page