0.9.3
Restore 2D 0.9.2, ignore Meshy refs, double Spinal Tap, Marrow Draught beam ammo, Second Stomach hearts fill overflow shields.
This commit is contained in:
1 parent
c41ce5fdb0
commit
988e04b2d4
10 files changed
+68
-36
No files matched your search
+3
-4
@@ -53,7 +53,7 @@ function updatePickups(dt) {
|
||||
}
|
||||
|
||||
// gems & small pickups fly to the player inside magnet radius
|
||||
if ((k.type === 'gem' || k.type === 'ammo' || (k.type === 'heart' && p.hp < p.stats.maxHp)) && d < magR) {
|
||||
if ((k.type === 'gem' || k.type === 'ammo' || (k.type === 'heart' && (p.hp < p.stats.maxHp || (p.stats.overShield > 0 && p.shieldHp < (p.stats.shieldPerk || 0) + p.stats.overShield)))) && d < magR) {
|
||||
const a = angleTo(k.x, k.y, p.x, p.y);
|
||||
const sp = lerp(320, 60, d / magR) * p.stats.magnetPull;
|
||||
k.x += Math.cos(a) * sp * dt; k.y += Math.sin(a) * sp * dt;
|
||||
@@ -73,9 +73,8 @@ function collectPickup(k) {
|
||||
Sfx.gem();
|
||||
break;
|
||||
case 'heart': {
|
||||
// At full HP hearts stay on the floor for later; Glutton's Gut heals +1
|
||||
// extra per tier below that.
|
||||
if (p.hp >= p.stats.maxHp) return false;
|
||||
// At full HP hearts stay unless Second Stomach has unused overflow-shield room.
|
||||
if (p.hp >= p.stats.maxHp && !(p.stats.overShield > 0 && p.shieldHp < (p.stats.shieldPerk || 0) + p.stats.overShield)) return false;
|
||||
const healAmt = 2 + (p.stats.gluttonGut || 0);
|
||||
healPlayer(healAmt); spawnText(p.x, p.y, '+' + healAmt, '#d92038');
|
||||
Sfx.heart();
|
||||
|
||||
Reference in new issue
Block a user