Skip to content

Commit

Permalink
Add missing getDamage function
Browse files Browse the repository at this point in the history
This updates the docs with the function used in the example bundle:
https://github.com/RanvierMUD/bundle-example-classes/blob/master/skills/lunge.js#L9-L11
  • Loading branch information
nahilep authored and shawncplus committed Aug 2, 2019
1 parent ade5eb1 commit 3845349
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/coding/classes.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ const Combat = require('../../bundle-example-combat/lib/Combat');
const damagePercent = 250;
const energyCost = 20;

function getDamage(player) {
return Combat.calculateWeaponDamage(player) * (damagePercent / 100);
}

/**
* Basic warrior attack
*/
Expand Down

0 comments on commit 3845349

Please sign in to comment.