From 4d80cd8df530c327542e2d1cc918e8a37f1f0e81 Mon Sep 17 00:00:00 2001 From: Arokha Sieyes Date: Fri, 13 Apr 2018 21:08:06 -0400 Subject: [PATCH 1/3] Proteans unbuckle targets before blobbing them --- .../carbon/human/species/station/protean_vr/protean_blob.dm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm index 610315275ac..9b8fb6b5c14 100644 --- a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm +++ b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm @@ -47,6 +47,8 @@ player_msg = "In this form, you can move a little faster, your health will regenerate as long as you have metal in you, and you can ventcrawl!" + can_buckle = TRUE //Blobsurfing + //Constructor allows passing the human to sync damages /mob/living/simple_animal/protean_blob/New(var/newloc, var/mob/living/carbon/human/H) ..() @@ -183,6 +185,8 @@ if(potentials.len) var/mob/living/target = pick(potentials) if(istype(target) && vore_selected) + if(target.buckled) + target.buckled.unbuckle_mob(target, force = TRUE) target.forceMove(vore_selected) to_chat(target,"\The [src] quickly engulfs you, [vore_selected.vore_verb]ing you into their [vore_selected.name]!") From be50f394a6bc5974f20bcd74535cfa064b6321ff Mon Sep 17 00:00:00 2001 From: Arokha Sieyes Date: Sat, 14 Apr 2018 11:12:46 -0400 Subject: [PATCH 2/3] Transforming to/from protean blob unbuckles riders --- .../carbon/human/species/station/protean_vr/protean_blob.dm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm index 9b8fb6b5c14..c4b2542f227 100644 --- a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm +++ b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_blob.dm @@ -215,6 +215,9 @@ /mob/living/carbon/human/proc/nano_intoblob() if(buckled) buckled.unbuckle_mob() + if(LAZYLEN(buckled_mobs)) + for(var/buckledmob in buckled_mobs) + unbuckle_mob(buckledmob, force = TRUE) if(pulledby) pulledby.stop_pulling() stop_pulling() @@ -259,6 +262,9 @@ return if(buckled) buckled.unbuckle_mob() + if(LAZYLEN(buckled_mobs)) + for(var/buckledmob in buckled_mobs) + unbuckle_mob(buckledmob, force = TRUE) if(pulledby) pulledby.stop_pulling() stop_pulling() From 84bbfcc787b050ccc93e30e4e3d21a4adfa4133f Mon Sep 17 00:00:00 2001 From: Arokha Sieyes Date: Sat, 14 Apr 2018 12:20:50 -0400 Subject: [PATCH 3/3] Fix infinite loop of metal usage due to mismatch in values --- .../species/station/protean_vr/protean_species.dm | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_species.dm b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_species.dm index 5898afcd969..184e751a6a5 100644 --- a/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_species.dm +++ b/code/modules/mob/living/carbon/human/species/station/protean_vr/protean_species.dm @@ -1,4 +1,5 @@ #define DAM_SCALE_FACTOR 0.01 +#define METAL_PER_TICK 150 /datum/species/protean name = "Protean" name_plural = "Proteans" @@ -170,15 +171,15 @@ if(refactory && !(refactory.status & ORGAN_DEAD)) //MHydrogen adds speeeeeed - if(refactory.get_stored_material("mhydrogen") >= 100) + if(refactory.get_stored_material("mhydrogen") >= METAL_PER_TICK) H.add_modifier(/datum/modifier/protean/mhydrogen, origin = refactory) //Plasteel adds brute armor - if(refactory.get_stored_material("plasteel") >= 100) + if(refactory.get_stored_material("plasteel") >= METAL_PER_TICK) H.add_modifier(/datum/modifier/protean/plasteel, origin = refactory) //Diamond adds burn armor - if(refactory.get_stored_material("diamond") >= 100) + if(refactory.get_stored_material("diamond") >= METAL_PER_TICK) H.add_modifier(/datum/modifier/protean/diamond, origin = refactory) return ..() @@ -207,7 +208,7 @@ // Various modifiers /datum/modifier/protean stacks = MODIFIER_STACK_FORBID - var/material_use = 150 + var/material_use = METAL_PER_TICK var/material_name = DEFAULT_WALL_MATERIAL /datum/modifier/protean/on_applied() @@ -303,3 +304,4 @@ desc += "\nVALID THROUGH END OF: [time2text(world.timeofday, "Month") +" "+ num2text(text2num(time2text(world.timeofday, "YYYY"))+544)]\nREGISTRANT: [new_name]" #undef DAM_SCALE_FACTOR +#undef METAL_PER_TICK \ No newline at end of file