mirror of
https://github.com/Sheldan/canvas.git
synced 2026-03-24 13:44:41 +00:00
survivors: healing 1 health if picking up health
fixing pull range up only increasing absolute
This commit is contained in:
@@ -116,7 +116,9 @@ export class PullRangeUp extends BaseItem {
|
|||||||
|
|
||||||
export class HealthUp extends BaseItem {
|
export class HealthUp extends BaseItem {
|
||||||
pickup(player: Player, world: World) {
|
pickup(player: Player, world: World) {
|
||||||
player.changeBaseStat(1, PlayerStats.increaseHealth)
|
let healthAmount = 1;
|
||||||
|
player.changeBaseStat(healthAmount, PlayerStats.increaseHealth)
|
||||||
|
player.heal(healthAmount)
|
||||||
super.pickup(player, world)
|
super.pickup(player, world)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ export class PlayerStats {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static factorPullRange(stats: PlayerStats, value: number) {
|
static factorPullRange(stats: PlayerStats, value: number) {
|
||||||
stats._pullRange += value
|
stats._pullRange *= value
|
||||||
}
|
}
|
||||||
|
|
||||||
static increaseHealth(stats: PlayerStats, value: number) {
|
static increaseHealth(stats: PlayerStats, value: number) {
|
||||||
|
|||||||
Reference in New Issue
Block a user