diff --git a/code/datums/spells/wizard_spells.dm b/code/datums/spells/wizard_spells.dm index 61d6c95fdd1..ee83aac518d 100644 --- a/code/datums/spells/wizard_spells.dm +++ b/code/datums/spells/wizard_spells.dm @@ -469,3 +469,48 @@ if(isliving(user)) var/mob/living/U = user U.IgniteMob() + +/datum/spell/corpse_explosion + name = "Corpse Explosion" + desc = "Fills a corpse with energy, causing it to explode violently." + school = "evocation" + base_cooldown = 5 SECONDS + clothes_req = TRUE + invocation = "JAH ITH BER" + invocation_type = "whisper" + selection_activated_message = "You prepare to detonate a corpse. Click on a target to cast the spell." + selection_deactivated_message = "You cancel the spell." + action_icon_state = "corpse_explosion" + +/datum/spell/corpse_explosion/create_new_targeting() + var/datum/spell_targeting/click/T = new + T.click_radius = 0 + T.try_auto_target = FALSE + T.allowed_type = /mob/living + return T + +/datum/spell/corpse_explosion/cast(list/targets, mob/user) + var/mob/living/target = targets[1] + if(!target || target.stat != DEAD) + return + var/turf/corpse_turf = get_turf(target) + new /obj/effect/temp_visual/corpse_explosion(get_turf(target)) + target.gib() + explosion(corpse_turf, 0, 0, 0, 0, silent = TRUE, breach = FALSE) + for(var/mob/living/M in range(4, corpse_turf)) + if(M == user) + continue + var/range = get_dist_euclidian(M, corpse_turf) + range = max(1, range) + M.apply_damage(100 / range, BRUTE) + if(issilicon(M)) + to_chat(M, "Your sensors are disabled, and your carapace is ripped apart by the violent dark magic!") + M.Weaken(6 SECONDS / range) + continue + + to_chat(M, "You are eviscerated by the violent dark magic!") + if(ishuman(M)) + if(range < 4) + M.KnockDown(4 SECONDS / range) + M.EyeBlurry(40 SECONDS / range) + M.AdjustConfused(6 SECONDS / range) diff --git a/code/game/gamemodes/wizard/spellbook.dm b/code/game/gamemodes/wizard/spellbook.dm index 049dd42d21d..ccff189cb7c 100644 --- a/code/game/gamemodes/wizard/spellbook.dm +++ b/code/game/gamemodes/wizard/spellbook.dm @@ -132,6 +132,11 @@ spell_type = /datum/spell/touch/disintegrate category = "Offensive" +/datum/spellbook_entry/corpse_explosion + name = "Corpse Explosion" + spell_type = /datum/spell/corpse_explosion + category = "Offensive" + /datum/spellbook_entry/fireball name = "Fireball" spell_type = /datum/spell/fireball diff --git a/code/game/objects/effects/temporary_visuals/misc_visuals.dm b/code/game/objects/effects/temporary_visuals/misc_visuals.dm index 736590114a2..1a8a23ee937 100644 --- a/code/game/objects/effects/temporary_visuals/misc_visuals.dm +++ b/code/game/objects/effects/temporary_visuals/misc_visuals.dm @@ -103,6 +103,15 @@ icon_state = "liquify" duration = 12 +/obj/effect/temp_visual/corpse_explosion + icon = 'icons/effects/64x64.dmi' + icon_state = "corpse_explosion" + pixel_x = -16 + pixel_y = -16 + light_range = 5 + light_color = "#f7dce3" + duration = 13 + /obj/effect/temp_visual/monkeyify icon = 'icons/mob/mob.dmi' icon_state = "h2monkey" diff --git a/icons/effects/64x64.dmi b/icons/effects/64x64.dmi index 132b2d0d222..2ef616b0bd5 100644 Binary files a/icons/effects/64x64.dmi and b/icons/effects/64x64.dmi differ diff --git a/icons/effects/effects.dmi b/icons/effects/effects.dmi index b11562a77ce..d2419382171 100644 Binary files a/icons/effects/effects.dmi and b/icons/effects/effects.dmi differ diff --git a/icons/mob/actions/actions.dmi b/icons/mob/actions/actions.dmi index 0cbef9d82fd..e9b7ef94895 100644 Binary files a/icons/mob/actions/actions.dmi and b/icons/mob/actions/actions.dmi differ