====== Elemental Magic - Code References ====== ===== Java Classes ===== * [[https://github.com/NYRDS/remixed-dungeon/blob/master/RemixedDungeon/src/main/java/com/nyrds/pixeldungeon/mechanics/spells/SpellHelper.java|SpellHelper.java]] - Defines spell affinities including Elemental ===== Spell Affinity Constants ===== * **AFFINITY_ELEMENTAL**: "Elemental" - Used by spells like [[mr:freeze_globe_spell|Freeze Globe]], [[mr:ignite_spell|Ignite]], [[mr:magic_torch_spell|Magic Torch]], [[mr:wind_gust_spell|Wind Gust]] * **AFFINITY_NECROMANCY**: "Necromancy" - Used by necromancy spells * **AFFINITY_RAGE**: "Rage" - Used by rage/berserker spells * **AFFINITY_DEMONOLOGY**: "Demolonogy" (typo in code) - Used by demonology spells * **AFFINITY_NATURE**: "Nature" - Used by nature/druid spells * **AFFINITY_SHADOW**: "Shadow" - Used by shadow spells * **AFFINITY_COMMON**: "Common" - Used by common utility spells ===== Affinity to Icon Mapping ===== * **Elemental** -> Icon ID: 6 * **Necromancy** -> Icon ID: 11 * **Rage** -> Icon ID: 12 * **Common** -> Icon ID: 6 * **Combat** -> Icon ID: 15 * **Rogue** -> Icon ID: 16 * **Witchcraft** -> Icon ID: 17 * **Huntress** -> Icon ID: 18 * **Elf** -> Icon ID: 19 ===== Hero Class Affinities ===== * Hero classes have magic affinities defined in their class definitions * [[mr:mage_class|Mage]] typically uses Elemental affinity * [[mr:warrior_class|Warrior]] may use Rage or Combat affinity * [[mr:rogue_class|Rogue]] may use Rogue affinity * [[mr:huntress_class|Huntress]] uses Huntress affinity * [[mr:elf_class|Elf]] uses Elf affinity ===== Related Entities ===== * [[mr:spell_affinity|Spell Affinity]] - Base affinity system * [[mr:spell_system|Spell System]] - Overall spell system * [[mr:freeze_globe_spell|Freeze Globe Spell]] - Example elemental spell * [[mr:ignite_spell|Ignite Spell]] - Example elemental spell * [[mr:magic_torch_spell|Magic Torch Spell]] - Example elemental spell ===== String Resources ===== Elemental Necromancy Rage ===== GitHub Links ===== * [[https://github.com/NYRDS/remixed-dungeon/blob/master/RemixedDungeon/src/main/java/com/nyrds/pixeldungeon/mechanics/spells/SpellHelper.java|SpellHelper.java on GitHub]] {{tag> mr magic spell_affinity elemental code_reference}}