From f359332cf481c532999dd0f6c5d6c6e54b899912 Mon Sep 17 00:00:00 2001 From: ntr Date: Sat, 5 Jan 2019 15:47:26 +1100 Subject: [PATCH] fix heal --- server/WORKLOG.md | 9 ++------- server/src/skill.rs | 9 ++++----- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/server/WORKLOG.md b/server/WORKLOG.md index 981ada3c..b746135e 100644 --- a/server/WORKLOG.md +++ b/server/WORKLOG.md @@ -10,17 +10,12 @@ strangle ## NOW -* zones - * differnt game types based on tag - * open w/ item? +* order cryps based on id +* reduce inventory ## SOON * aoe skills -* hash cryp name for avatar - -* order cryps based on id - * keep track of games joined * concede game on leave * ko all cryps on team, check status diff --git a/server/src/skill.rs b/server/src/skill.rs index a5b868b9..2081ebf7 100644 --- a/server/src/skill.rs +++ b/server/src/skill.rs @@ -708,7 +708,7 @@ impl Skill { Skill::Blast => blast(cryp, target, resolution), Skill::Amplify => amplify(cryp, target, resolution), // increase magic dmg Skill::Decay => decay(cryp, target, resolution), // dot - Skill::DecayTick => decay_tick(cryp, target, resolution), // hot + Skill::DecayTick => decay_tick(cryp, target, resolution), // dot Skill::Drain => drain(cryp, target, resolution), Skill::DrainTick => drain_tick(cryp, target, resolution), // hot Skill::Curse => curse(cryp, target, resolution), @@ -818,11 +818,10 @@ fn empower(_cryp: &mut Cryp, target: &mut Cryp, mut resolution: Resolution) -> R return resolution; } -// TODO put overhealing back -fn heal(cryp: &mut Cryp, _target: &mut Cryp, resolution: Resolution) -> Resolution { - let _amount = cryp.phys_dmg(); +fn heal(cryp: &mut Cryp, target: &mut Cryp, mut resolution: Resolution) -> Resolution { + let amount = cryp.spell_dmg(); + resolution.results.push(target.heal(Skill::Heal, amount)); return resolution; - } fn triage(cryp: &mut Cryp, target: &mut Cryp, mut resolution: Resolution) -> Resolution {