en:rpd:leech_enchantment
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en:rpd:leech_enchantment [2026/02/08 00:39] – Fix wiki broken links and naming inconsistencies mike | en:rpd:leech_enchantment [2026/03/14 22:26] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Leech Enchantment ====== | ||
| + | {{ rpd: | ||
| + | |||
| + | The Leech enchantment is a weapon enchantment that heals the wielder for a portion of the damage dealt when hitting an enemy. This creates a sustain mechanic for melee combat, allowing players to recover health while dealing damage. | ||
| + | |||
| + | ==== Description ==== | ||
| + | The Leech enchantment provides life steal functionality, | ||
| + | |||
| + | ==== Mechanics ==== | ||
| + | * **Proc Chance**: Based on weapon level and damage dealt | ||
| + | * **Healing Formula**: The healing amount is calculated as follows: | ||
| + | * Maximum heal value: damage * (level + 2) / (level + 6) | ||
| + | * Actual heal: Random value between 0 and max, capped by missing HP | ||
| + | * Only heals if the attacker has missing HP | ||
| + | * **Level Scaling**: | ||
| + | * Level 0: ~33% of damage (max) | ||
| + | * Level 1: ~43% of damage (max) | ||
| + | * Level 2: ~50% of damage (max) | ||
| + | * Higher levels continue to improve the ratio | ||
| + | * **Visual Effect**: Shows healing amount as green numbers above the character | ||
| + | * **Glow Color**: Dark red (RGB: 0x660022) | ||
| + | |||
| + | ==== Strategy ==== | ||
| + | * Most effective on fast-hitting weapons that deal consistent damage | ||
| + | * Provides sustain in prolonged fights, reducing reliance on healing potions | ||
| + | * Less effective when at full health (no healing occurs) | ||
| + | * Works well with high-damage weapons for larger healing bursts | ||
| + | * Can be the difference between life and death in difficult encounters | ||
| + | |||
| + | ==== Source Code ==== | ||
| + | * Java Implementation: | ||
| + | * The effect is applied in the proc() method | ||
| + | * Healing amount scales with weapon level using the formula: damage * (level + 2) / (level + 6) | ||
| + | * Only heals if attacker has missing HP (attacker.ht() - attacker.hp() > 0) | ||
| + | * Uses Random.IntRange() for variability in healing amount | ||
| + | |||
| + | ==== String Resources ==== | ||
| + | * The enchantment name and description are defined in the weapon enchantment string resources | ||
| + | |||
| + | ==== See Also ==== | ||
| + | * [[en: | ||
| + | * [[en: | ||
| + | * [[en: | ||
| + | * [[en: | ||
| + | * [[en: | ||
| + | |||
| + | {{tag> rpd items enchantments healing life_steal}} | ||
