Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A Great Return of The Transmutation Wand #13182

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions code/game/gamemodes/modes_gameplays/wizard/spellbook.dm
Original file line number Diff line number Diff line change
Expand Up @@ -320,14 +320,13 @@
dat += "[surplus] осталось.<br>"
return dat

/* Commented because admins ban everyone who uses this staff... Somebody should rebalance this thing
// Commented because admins ban everyone who uses this staff... Somebody should rebalance this thing
Slavik2001 marked this conversation as resolved.
Show resolved Hide resolved
/datum/spellbook_entry/item/staffchange
name = "Staff of Change"
desc = "An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself."
item_path = /obj/item/weapon/gun/magic/change
log_name = "ST"
cost = 4
*/

/datum/spellbook_entry/item/staffanimation
name = "Посох анимации"
Expand Down
1 change: 0 additions & 1 deletion code/modules/mob/death.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
/mob/proc/dust()
new /obj/effect/decal/cleanable/ash(loc)
dust_process()


/mob/proc/death(gibbed)
SEND_SIGNAL(src, COMSIG_MOB_DIED, gibbed)
Expand Down
2 changes: 2 additions & 0 deletions code/modules/mob/living/living.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1422,6 +1422,8 @@
/mob/living/death(gibbed)
beauty.AddModifier("stat", additive=beauty_dead)
update_health_hud()
if(wabbajacked)
unwabbajack()
return ..()

/mob/living/proc/update_beauty(datum/source, old_value)
Expand Down
6 changes: 3 additions & 3 deletions code/modules/mob/living/simple_animal/hulk.dm
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
max_n2 = 0
minbodytemp = 0
var/hulk_powers = list()
var/mob/living/original_body
var/mob/living/origin
var/health_regen = 1.5

animalistic = FALSE
Expand Down Expand Up @@ -186,8 +186,8 @@

if(mind && original_body)
mind.transfer_to(original_body)
original_body.attack_log = attack_log
original_body.attack_log += "\[[time_stamp()]\]<font color='blue'> ======HUMAN LIFE======</font>"
origin.attack_log = attack_log
origin.attack_log += "\[[time_stamp()]\]<font color='blue'> ======HUMAN LIFE======</font>"
qdel(src)

/mob/living/simple_animal/hulk/MobBump(mob/M)
Expand Down
2 changes: 1 addition & 1 deletion code/modules/projectiles/guns/magic/staff.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
ammo_type = /obj/item/ammo_casing/magic/change
icon_state = "staffofchange"
item_state = "staffofchange"
fire_delay = 30
fire_delay = 180
max_charges = 1

/obj/item/weapon/gun/magic/animate
Expand Down
147 changes: 130 additions & 17 deletions code/modules/projectiles/projectile/magic.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,49 +22,118 @@
wabbajack(target)

/obj/item/projectile/magic/proc/wabbajack(mob/living/M)
if(!istype(M) || M.stat == DEAD || M.notransform || (GODMODE & M.status_flags) || !M.client || isxenoqueen(M))
if(!istype(M) || isAI(M) || isdrone(M) || isconstruct(M) || M.stat == DEAD || M.notransform || (GODMODE & M.status_flags) || isxenoqueen(M))
return

M.notransform = TRUE
M.canmove = 0
M.icon = null
M.cut_overlays()
M.invisibility = 101
if(!issilicon(M))
for(var/obj/item/W in M)
W.layer = initial(W.layer)
W.loc = M.loc
W.dropped(M)

var/mob/living/new_mob

var/randomizer = pick("animal", "cyborg", "xeno")
if(isxeno(M))
randomizer = "xeno"
var/randomizer = pick("animal", "cyborg", "carbon")
switch(randomizer)
if("animal")
var/beast = pick(/mob/living/simple_animal/hostile/carp, /mob/living/simple_animal/hostile/tomato/angry_tomato, /mob/living/simple_animal/hostile/retaliate/goat, /mob/living/simple_animal/pig/shadowpig)
var/beast = pick(
/mob/living/simple_animal/mouse,
/mob/living/simple_animal/cow,
/mob/living/simple_animal/chicken,
/mob/living/simple_animal/chick,
/mob/living/simple_animal/cat,
/mob/living/simple_animal/corgi,
/mob/living/simple_animal/corgi/Lisa,
/mob/living/simple_animal/corgi/borgi,
/mob/living/simple_animal/corgi/puppy,
/mob/living/simple_animal/parrot,
/mob/living/simple_animal/crab,
/mob/living/simple_animal/hostile/retaliate/goat,
/mob/living/simple_animal/pig/shadowpig,
/mob/living/simple_animal/pig,
/mob/living/simple_animal/turkey,
/mob/living/simple_animal/goose,
/mob/living/simple_animal/seal,
/mob/living/simple_animal/walrus,
/mob/living/simple_animal/fox,
/mob/living/simple_animal/lizard,
/mob/living/simple_animal/pug,
/mob/living/simple_animal/shiba,
/mob/living/simple_animal/mushroom,
/mob/living/simple_animal/yithian,
/mob/living/simple_animal/spiderbot)
new_mob = new beast(M.loc)
new_mob.universal_speak = TRUE
if("cyborg")
new_mob = new /mob/living/silicon/robot(M.loc, "Default", /datum/ai_laws/asimov_xenophile, FALSE, global.chaplain_religion)
new_mob.gender = M.gender
new_mob.invisibility = 0
new_mob.job = "Cyborg"
if("xeno")
new_mob = new /mob/living/carbon/xenomorph/humanoid/maid(M.loc)
new_mob.universal_speak = TRUE
if("carbon")
var/carbon = pick(
/mob/living/carbon/human,
/mob/living/carbon/monkey,
/mob/living/carbon/monkey/tajara,
/mob/living/carbon/monkey/skrell,
/mob/living/carbon/monkey/unathi,
/mob/living/carbon/monkey/diona/podman,
/mob/living/carbon/human/tajaran,
/mob/living/carbon/human/skrell,
/mob/living/carbon/human/unathi,
/mob/living/carbon/human/podman,
/mob/living/carbon/human/abductor,
/mob/living/carbon/human/golem,
/mob/living/carbon/human/vox)
new_mob = new carbon(M.loc)
new_mob.gender = M.gender
new_mob.languages = M.languages
if(!new_mob)
return

new_mob.attack_log = M.attack_log
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>[M.real_name] ([M.ckey]) became [new_mob.real_name].</font>")

new_mob.set_a_intent(INTENT_HARM)
var/mob/living/original_mob = M
if(M.original_body)
new_mob.original_body = M.original_body
else
new_mob.original_body = original_mob
M.forceMove(new_mob)

for(var/mob/living/H in M.contents)
H.forceMove(new_mob)
qdel(M)

if(M.mind)
M.mind.transfer_to(new_mob)
else
new_mob.key = M.key

new_mob.wabbajacked = 1

to_chat(new_mob, "<B>Your body forms to something else!</B>")

qdel(M)
return new_mob
/mob/living/proc/unwabbajack()
var/datum/effect/effect/system/smoke_spread/bad/smoke = new /datum/effect/effect/system/smoke_spread/bad()
smoke.set_up(10, 0, src.loc)
smoke.start()
playsound(src, 'sound/effects/bamf.ogg', VOL_EFFECTS_MASTER)

var/obj/effect/decal/remains/human/RH = new /obj/effect/decal/remains/human(src.loc)
var/matrix/Mx = matrix()
RH.transform = Mx

for(var/mob/M in contents)
M.loc = src.loc
if(isliving(M))
var/mob/living/L = M
L.Paralyse(15)
L.update_canmove()

if(mind && original_body)
mind.transfer_to(original_body)

qdel(src)

/obj/item/projectile/magic/animate
name = "bolt of animation"
Expand All @@ -82,7 +151,7 @@
C.ChangeOwner(firer)
create_spawner(/datum/spawner/living/mimic, C)
else if(isshade(change) || isxeno(change))
var/mob/living/M = wabbajack(change)
var/mob/living/M = animate_atom_living(change)
if(!M)
return
if(firer && iswizard(firer))
Expand All @@ -97,6 +166,50 @@
if(R)
R.Deconvert()

/obj/item/projectile/magic/animate/proc/animate_atom_living(mob/living/M)
if(!istype(M) || M.stat == DEAD || M.notransform || (GODMODE & M.status_flags) || !M.client || isxenoqueen(M))
return

M.notransform = TRUE
M.canmove = 0
M.icon = null
M.cut_overlays()
M.invisibility = 101

var/mob/living/new_mob

var/randomizer = pick("animal", "cyborg", "xeno")
if(isxeno(M))
randomizer = "xeno"
switch(randomizer)
if("animal")
var/beast = pick(/mob/living/simple_animal/hostile/carp, /mob/living/simple_animal/hostile/tomato/angry_tomato, /mob/living/simple_animal/hostile/retaliate/goat, /mob/living/simple_animal/pig/shadowpig)
new_mob = new beast(M.loc)
new_mob.universal_speak = TRUE
if("cyborg")
new_mob = new /mob/living/silicon/robot(M.loc, "Default", /datum/ai_laws/asimov_xenophile, FALSE, global.chaplain_religion)
new_mob.gender = M.gender
new_mob.invisibility = 0
new_mob.job = "Cyborg"
if("xeno")
new_mob = new /mob/living/carbon/xenomorph/humanoid/maid(M.loc)
new_mob.universal_speak = TRUE
if(!new_mob)
return

new_mob.attack_log = M.attack_log
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>[M.real_name] ([M.ckey]) became [new_mob.real_name].</font>")

new_mob.set_a_intent(INTENT_HARM)
if(M.mind)
M.mind.transfer_to(new_mob)
else
new_mob.key = M.key

to_chat(new_mob, "<B>Your body forms to something else!</B>")

qdel(M)
return new_mob

/obj/item/projectile/magic/resurrection
name = "bolt of resurrection"
Expand Down
3 changes: 3 additions & 0 deletions code/modules/unarmed_combat/living_procs_defines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@
var/attack_push_vis_effect
var/attack_disarm_vis_effect

var/original_body
var/wabbajacked = 0

/mob/living/proc/read_possible_combos()
set name = "Combos Cheat Sheet"
set desc = "A list of all possible combos with rough descriptions."
Expand Down
Loading