v0.10: Bugs, new shop, health regen


Good evening.

Bugs

  1. The reroll button is now correctly disabled after the player buys an upgrade and dips their available gold below the reroll cost. Before, the button would remain enabled, but it didn't do anything.
  2. The player ship will now correctly reverse its deterioration after sufficient healing. (If you haven't noticed, the ship sprite changes as you take more damage. This process can now reverse.)

Changes

  1. The "Projectile Count" upgrade has had its cost reduced to be equal to the other upgrades in its rarities. I still think it's the best upgrade in the game, but with this many more upgrades available, the chance of it appearing is lower. The feeling of being able to afford any different Epic/Legendary, but not that one, is not good.
    1. The actual fix here is that I should make this upgrade come with a downside, like -25% damage or something, to balance it.
  2. The shop now behaves pretty differently:
    1. There are four items on display, up from three.
    2. Purchasing an upgrade no longer refills that upgrade slot. The only way to change the upgrade offered in a given slot is to reroll, which resets all of them.
      1. The old methodology sometimes resulted in the cost of a reroll being higher than the cost of buying an upgrade, which meant it was sometimes correct to buy any random upgrade just to reroll that individual slot. No!
      2. The intention here is that you're shown 4 items, you buy the ones you want, and then you reroll to refresh all four slots.

Features

  1. The game now has eight space nebula backgrounds that it chooses from for the menu, upgrade, and game screens.
  2. I've added health regeneration and its corresponding upgrades.
    1. Common: 30g, 1 stack of regen
    2. Rare: 50g, 2 stacks of regen
    3. Epic: 75g, 3 stacks of regen
    4. Legendary: 100g, 5 stacks of regen

Health regen works like this: At the start of the round, I set a timer that heals the player for 1 health when it expires. The timer's wait time is calculated with the following formula:

3 / ( 1.0 + ( ( NUM_STACKS - 1) / 2.25 ) )

This is taken from Brotato, but modified slightly to be a little faster. All the relevant values are higher in my game -- player max health, damage received by enemies -- so I want our health regen to be higher. Here's a table of how much health you can expect to get back:

Number of Regen StacksHP per second
00
10.18518518518519
20.33333333333333
30.48148148148148
40.62962962962963
50.77777777777778
60.92592592592593
71.07407407407407
81.22222222222222
91.37037037037037
101.51851851851852
111.66666666666667
121.81481481481482
131.96296296296296
142.11111111111111
152.25925925925926
162.40740740740741
172.55555555555556
182.7037037037037
192.85185185185185
203


If these seem low, maybe they are! Only one way to find out.

Files

bb.zip Play in browser
Jun 09, 2024