User Tools

Site Tools


mr:dark_sacrifice_spell

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
mr:dark_sacrifice_spell [2026/02/28 13:38] – Wiki standards compliance: Fix broken links, add images, improve mr: namespace page Qwen Assistantmr:dark_sacrifice_spell [2026/02/28 13:40] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== Dark Sacrifice Spell - Code References ======
 +
 +{{ rpd:images:dark_sacrifice_spell.png|Dark Sacrifice Spell }}
 +
 +===== Lua Script Implementation =====
 +  * [[https://github.com/NYRDS/remixed-dungeon/blob/master/scripts/spells/DarkSacrifice.lua|DarkSacrifice.lua]]
 +
 +**Script Details:**
 +  * File: ''scripts/spells/DarkSacrifice.lua''
 +  * Type: Spell (Necromancy affinity)
 +  * Targeting: Character targeting
 +  * Level requirement: 3
 +  * Mana cost: 3
 +  * Cast time: 0.5 seconds
 +
 +**Spell Mechanics (from Lua code):**
 +<code lua>
 +return spell.init{
 +    desc  = function ()
 +        return {
 +            image         = 1,
 +            imageFile     = "spellsIcons/necromancy.png",
 +            name          = "DarkSacrifice_Name",
 +            info          = "DarkSacrifice_Info",
 +            magicAffinity = "Necromancy",
 +            targetingType = "char",
 +            level         = 3,
 +            spellCost     = 3,
 +            castTime      = 0.5
 +        }
 +    end,
 +    castOnChar = function(self, spell, caster, sacrifice)
 +        -- Sacrifices a owned minion to create liquid flame explosion
 +        -- Explosion damage based on minion HP and caster skill level
 +    end
 +}
 +</code>
 +
 +**Behavior:**
 +  * Targets a character (must be owned by the caster)
 +  * Sacrifices the targeted minion
 +  * Creates a Liquid Flame blob at the sacrifice location
 +  * Explosion damage scales with: ''sacrifice:hp() * caster:skillLevel()''
 +  * Plays cursed sound effect on successful sacrifice
 +  * Shows shadow particle curse effect on sacrifice sprite
 +
 +===== String Resources =====
 +**English (values/strings_all.xml):**
 +<code xml>
 +<string name="DarkSacrifice_Name">Dark Sacrifice</string>
 +<string name="DarkSacrifice_Info">Sacrifice your loyal minion to cause an explosion. The area covered by the explosion will depend on the remaining health of the servant and your skill level.</string>
 +<string name="DarkSacrifice_Ok">My life is yours!</string>
 +<string name="DarkSacrifice_Resist">You have no power over me</string>
 +<string name="DarkSacrifice_Hint">Choose your loyal servant to sacrifice!</string>
 +</code>
 +
 +**Russian (values-ru/strings_all.xml):**
 +<code xml>
 +<string name="DarkSacrifice_Name">Тёмная жертва</string>
 +<string name="DarkSacrifice_Info">Пожертвуйте своим верным прислужником, чтобы вызвать взрыв. Площадь, охваченная взрывом, будет зависеть от оставшегося здоровья слуги и вашего уровня мастерства.</string>
 +<string name="DarkSacrifice_Ok">Моя жизнь принадлежит тебе!</string>
 +<string name="DarkSacrifice_Resist">Ты не имеешь власти надо мной</string>
 +<string name="DarkSacrifice_Hint">Выберите верного слугу для жертвоприношения!</string>
 +</code>
 +
 +**Other Languages:**
 +  * German (values-de): ''Dunkle Opferung''
 +  * Ukrainian (values-uk): ''Темна жертва''
 +  * Greek (values-el): ''Σκοτεινή θυσία''
 +  * Indonesian (values-in): ''Pengorbanan Gelap''
 +
 +===== Related Code References =====
 +  * Spell base class: [[https://github.com/NYRDS/remixed-dungeon/blob/master/RemixedDungeon/src/main/assets/scripts/lib/spell.lua|spell.lua]]
 +  * Common classes: [[https://github.com/NYRDS/remixed-dungeon/blob/master/RemixedDungeon/src/main/assets/scripts/lib/commonClasses.lua|commonClasses.lua]]
 +  * Liquid Flame blob: Used for explosion effect
 +  * Sound effect: ''snd_cursed''
 +  * Particle effect: ''RPD.Sfx.ShadowParticle.CURSE''
 +
 +===== Game Mechanics References =====
 +  * Magic Affinity: [[en:rpd:spell_affinities#necromancy|Necromancy]]
 +  * Spell system: [[en:rpd:spell_system|Spell System]]
 +  * Spells overview: [[en:rpd:spells_overview|Spells Overview]]
 +
 +{{tag> mr spell necromancy code-reference lua}}
  
mr/dark_sacrifice_spell.txt · Last modified: by 127.0.0.1