oskarrough/slaytheweb

Smarter dungeons

Offen

#150 geöffnet am 30.06.2021

 (2 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)JavaScript (57 Forks)auto 404
featurehelp wanted

Repository-Metriken

Stars
 (294 Sterne)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Problem

Current state of the dungeons:

  • The monsters you have to fight in the dungeons are randomly chosen.
  • Monsters are divided into three categories: monsters, elites and bosses.

You only meet bosses at the end, so that's fine.

But monsters and elites are scattered around the floors and since it's random, you might meet a very difficult monster on floor 1 and an easy one on the last floors.

Solution

It'd make for a more fun and balanced game if the logic for choosing a monster and/or elite was smarter.

We could extend the function to choose a monster and elite to account for the floor you are currently on. A plan could look like this:

  • Add difficulties to the monster rooms

The difficulties could be numbers (1-3?) or a size (s, m, l, xl) or just a string easy, medium, hard.

  • Add categories/tags to the monster rooms

The tags I'm not sure we need for now, but could indicate what type of fight it is. For example aoe, single target, scaling, kill fast before it kills you and so on.

  • Improve logic for choosing which monster or elite room

See code here: https://github.com/oskarrough/slaytheweb/blob/9e466aa87da8156215fa017cef681c3505e83db0/public/game/dungeon.js#L75-L76)

Remember to use state.dungeon.y (the current floor) as well to make it balanced.

Contributor Guide