diff --git a/code/datums/datumvars.dm b/code/datums/datumvars.dm index 591efbc60d..e0058ee9d4 100644 --- a/code/datums/datumvars.dm +++ b/code/datums/datumvars.dm @@ -349,15 +349,20 @@ client if (L.len > 0 && !(name == "underlays" || name == "overlays" || name == "vars" || L.len > 500)) // not sure if this is completely right... - if (0) // (L.vars.len > 0) + if(0) //(L.vars.len > 0) html += "
    " - for (var/entry in L) - html += debug_variable(entry, L[entry], level + 1) + html += "
" else html += "" else html += "[name] = [value]" diff --git a/code/datums/mind.dm b/code/datums/mind.dm index 30ff780a11..9422943f47 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -18,6 +18,7 @@ datum/mind var/has_been_rev = 0//Tracks if this mind has been a rev or not var/rev_cooldown = 0 + var/list/tempobjectives = list() //because otherwise they get de-referenced. proc/transfer_to(mob/new_character) if(current) diff --git a/code/game/atom_procs.dm b/code/game/atom_procs.dm index 244ff000d6..4d554d339b 100644 --- a/code/game/atom_procs.dm +++ b/code/game/atom_procs.dm @@ -81,16 +81,16 @@ /atom/proc/add_fingerprint(mob/living/M as mob) if(isnull(M)) return if(isnull(M.key)) return - if (!( src.flags ) & 256) + if (!( flags ) & 256) return if (ishuman(M)) if(!fingerprintshidden) fingerprintshidden = list() add_fibers(M) if (M.mutations2 & mFingerprints) - if(src.fingerprintslast != M.key) - src.fingerprintshidden += "(Has no fingerprints) Real name: [M.real_name], Key: [M.key]" - src.fingerprintslast = M.key + if(fingerprintslast != M.key) + fingerprintshidden += "(Has no fingerprints) Real name: [M.real_name], Key: [M.key]" + fingerprintslast = M.key return 0 var/mob/living/carbon/human/H = M if (!istype(H.dna, /datum/dna) || !H.dna.uni_identity || (length(H.dna.uni_identity) != 32)) @@ -98,24 +98,24 @@ H.dna = new /datum/dna(null) H.check_dna() if (H.gloves && H.gloves != src) - if(src.fingerprintslast != H.key) - src.fingerprintshidden += text("(Wearing gloves). Real name: [], Key: []",H.real_name, H.key) - src.fingerprintslast = H.key + if(fingerprintslast != H.key) + fingerprintshidden += text("(Wearing gloves). Real name: [], Key: []",H.real_name, H.key) + fingerprintslast = H.key H.gloves.add_fingerprint(M) if(H.gloves != src) if(prob(75) && istype(H.gloves, /obj/item/clothing/gloves/latex)) return 0 else if(H.gloves && !istype(H.gloves, /obj/item/clothing/gloves/latex)) return 0 - if(src.fingerprintslast != H.key) - src.fingerprintshidden += text("Real name: [], Key: []",H.real_name, H.key) - src.fingerprintslast = H.key + if(fingerprintslast != H.key) + fingerprintshidden += text("Real name: [], Key: []",H.real_name, H.key) + fingerprintslast = H.key if(!fingerprints) fingerprints = list() var/new_prints = 0 var/prints - for(var/i = 1, i <= src.fingerprints.len, i++) - var/list/L = params2list(src.fingerprints[i]) + for(var/i = 1, i <= fingerprints.len, i++) + var/list/L = params2list(fingerprints[i]) if(L[num2text(1)] == md5(H.dna.uni_identity)) new_prints = i prints = L[num2text(2)] @@ -123,30 +123,28 @@ else var/test_print = stars(L[num2text(2)], rand(80,90)) if(stringpercent(test_print) == 32) - if(src.fingerprints.len == 1) - src.fingerprints = list() + if(fingerprints.len == 1) + fingerprints = list() else - for(var/j = i, j < (src.fingerprints.len), j++) - src.fingerprints[j] = src.fingerprints[j+1] - src.fingerprints.len-- + fingerprints.Cut(i,i+1) else - src.fingerprints[i] = "1=[L[num2text(1)]]&2=[test_print]" + fingerprints[i] = "1=[L[num2text(1)]]&2=[test_print]" if(new_prints) - src.fingerprints[new_prints] = text("1=[]&2=[]", md5(H.dna.uni_identity), stringmerge(prints,stars(md5(H.dna.uni_identity), (H.gloves ? rand(10,20) : rand(25,40))))) - else if(new_prints == 0) - if(!src.fingerprints || !src.fingerprints.len) - src.fingerprints = list(text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40)))) + fingerprints[new_prints] = text("1=[]&2=[]", md5(H.dna.uni_identity), stringmerge(prints,stars(md5(H.dna.uni_identity), (H.gloves ? rand(10,20) : rand(25,40))))) + else + if(!fingerprints || !fingerprints.len) + fingerprints = list(text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40)))) else - src.fingerprints += text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40))) - for(var/i = 1, i <= src.fingerprints.len, i++) - if(length(src.fingerprints[i]) != 69) - src.fingerprints.Remove(src.fingerprints[i]) + fingerprints += text("1=[]&2=[]", md5(H.dna.uni_identity), stars(md5(H.dna.uni_identity), H.gloves ? rand(10,20) : rand(25,40))) + for(var/i = 1, i <= fingerprints.len, i++) + if(length(fingerprints[i]) != 69) + fingerprints.Remove(fingerprints[i]) if(fingerprints && !fingerprints.len) del(fingerprints) return 1 else - if(src.fingerprintslast != M.key) - src.fingerprintshidden += text("Real name: [], Key: []",M.real_name, M.key) - src.fingerprintslast = M.key + if(fingerprintslast != M.key) + fingerprintshidden += text("Real name: [], Key: []",M.real_name, M.key) + fingerprintslast = M.key return //returns 1 if made bloody, returns 0 otherwise diff --git a/code/game/gamemodes/newobjective.dm b/code/game/gamemodes/newobjective.dm index dcd77d63c2..3f69a957d1 100644 --- a/code/game/gamemodes/newobjective.dm +++ b/code/game/gamemodes/newobjective.dm @@ -1,52 +1,85 @@ /proc/GenerateTheft(var/job,var/datum/mind/traitor) var/list/datum/objective/objectives = list() + var/list/weight = list() + var/index = 1 for(var/o in typesof(/datum/objective/steal)) if(o != /datum/objective/steal) //Make sure not to get a blank steal objective. var/datum/objective/target = new o(null,job) - objectives += list(target = target.weight) - - //objectives += GenerateAssassinate(job,traitor) - return objectives + weight += list("[index]" = target.weight) + objectives += target + index++ + world << objectives.len + return list(objectives, weight) /proc/GenerateAssassinate(var/job,var/datum/mind/traitor) var/list/datum/objective/assassinate/missions = list() + var/list/weight = list() + var/index = 1 for(var/datum/mind/target in ticker.minds) if((target != traitor) && istype(target.current, /mob/living/carbon/human)) if(target && target.current) var/datum/objective/target_obj = new /datum/objective/assassinate(null,job,target) - missions += list(target_obj = target_obj.weight) - return missions + weight += list("[index]" = target_obj.weight) + missions += target_obj + index++ + world << missions.len + return list(missions, weight) /proc/GenerateFrame(var/job,var/datum/mind/traitor) var/list/datum/objective/frame/missions = list() + var/list/weight = list() + var/index = 1 for(var/datum/mind/target in ticker.minds) if((target != traitor) && istype(target.current, /mob/living/carbon/human)) if(target && target.current) var/datum/objective/target_obj = new /datum/objective/frame(null,job,target) - missions += list(target_obj = target_obj.weight) - return missions + weight += list("[index]" = target_obj.weight) + missions += target_obj + index++ + world << missions.len + return list(missions, weight) /proc/GenerateProtection(var/job,var/datum/mind/traitor) var/list/datum/objective/frame/missions = list() + var/list/weight = list() + var/index = 1 for(var/datum/mind/target in ticker.minds) if((target != traitor) && istype(target.current, /mob/living/carbon/human)) if(target && target.current) var/datum/objective/target_obj = new /datum/objective/protection(null,job,target) - missions += list(target_obj = target_obj.weight) - return missions + weight += list("[index]" = target_obj.weight) + missions += target_obj + index++ + world << missions.len + return list(missions, weight) +/proc/PickObjectiveFromList(var/list/objectivesArray) + var/list/datum/objectives = objectivesArray[1] + var/pick_index = text2num(pickweight(objectivesArray[2])) + return objectives[pick_index] +/proc/RemoveObjectiveFromList(var/list/objectiveArray, var/datum/objective/objective) + var/list/datum/objective/temp = objectiveArray[1] + var/list/weight = objectiveArray[2] + var/index = temp.Find(objective) + if(index == temp.len) + temp.Cut(index) + weight.Cut(index) + else + temp.Cut(index, index+1) + weight.Cut(index, index+1) + return list(temp,weight) /proc/SelectObjectives(var/job,var/datum/mind/traitor,var/hijack = 0) - var/list/datum/objective/chosenobjectives = list() - var/list/datum/objective/theftobjectives = GenerateTheft(job,traitor) //Separated all the objective types so they can be picked independantly of each other. - var/list/datum/objective/killobjectives = GenerateAssassinate(job,traitor) - var/list/datum/objective/frameobjectives = GenerateFrame(job,traitor) - var/list/datum/objective/protectobjectives = GenerateProtection(job,traitor) + var/list/chosenobjectives = list() + var/list/theftobjectives = GenerateTheft(job,traitor) //Separated all the objective types so they can be picked independantly of each other. + var/list/killobjectives = GenerateAssassinate(job,traitor) + var/list/frameobjectives = GenerateFrame(job,traitor) + var/list/protectobjectives = GenerateProtection(job,traitor) //var/points var/totalweight var/selectobj @@ -54,27 +87,30 @@ while(totalweight < 100) selectobj = rand(1,100) //Randomly determine the type of objective to be given. - if(!length(killobjectives) || !length(protectobjectives)) //If any of these lists are empty, just give them theft objectives. - var/datum/objective/objective = pickweight(theftobjectives) + if(!length(killobjectives[1]) || !length(protectobjectives[1])|| !length(frameobjectives[1])) //If any of these lists are empty, just give them theft objectives. + var/datum/objective/objective = PickObjectiveFromList(theftobjectives) chosenobjectives += objective totalweight += objective.points - theftobjectives -= objective + theftobjectives = RemoveObjectiveFromList(theftobjectives, objective) else switch(selectobj) if(1 to 55) //Theft Objectives (55% chance) - var/datum/objective/objective = pickweight(theftobjectives) + var/datum/objective/objective = PickObjectiveFromList(theftobjectives) for(1 to 10) if(objective.points + totalweight <= 110) break - objective = pickweight(theftobjectives) + objective = PickObjectiveFromList(theftobjectives) chosenobjectives += objective totalweight += objective.points - theftobjectives -= objective + theftobjectives = RemoveObjectiveFromList(theftobjectives, objective) if(56 to 92) //Assassination Objectives (37% chance) - var/datum/objective/assassinate/objective = pickweight(killobjectives) + var/datum/objective/assassinate/objective = PickObjectiveFromList(killobjectives) + world << objective for(1 to 10) if(objective.points + totalweight <= 110) break - objective = pickweight(killobjectives) + objective = PickObjectiveFromList(killobjectives) + if(!objective) + continue for(var/datum/objective/protection/conflicttest in chosenobjectives) //Check to make sure we aren't telling them to Assassinate somebody they need to Protect. if(conflicttest.target == objective.target) conflict = 1 @@ -86,23 +122,37 @@ if(!conflict) chosenobjectives += objective totalweight += objective.points - killobjectives -= objective + killobjectives = RemoveObjectiveFromList(killobjectives, objective) conflict = 0 if(93 to 95) //Framing Objectives (3% chance) - var/datum/objective/objective = pickweight(frameobjectives) + var/datum/objective/objective = PickObjectiveFromList(frameobjectives) for(1 to 10) if(objective.points + totalweight <= 110) break - objective = pickweight(frameobjectives) - chosenobjectives += objective - totalweight += objective.points - frameobjectives -= objective + objective = PickObjectiveFromList(frameobjectives) + if(!objective) + continue + for(var/datum/objective/protection/conflicttest in chosenobjectives) //Check to make sure we aren't telling them to Assassinate somebody they need to Protect. + if(conflicttest.target == objective.target) + conflict = 1 + break + for(var/datum/objective/assassinate/conflicttest in chosenobjectives) //Check to make sure we aren't telling them to Protect somebody they need to Assassinate. + if(conflicttest.target == objective.target) + conflict = 1 + break + if(!conflict) + chosenobjectives += objective + totalweight += objective.points + frameobjectives = RemoveObjectiveFromList(frameobjectives, objective) + conflict = 0 if(96 to 100) //Protection Objectives (5% chance) - var/datum/objective/protection/objective = pickweight(protectobjectives) + var/datum/objective/protection/objective = PickObjectiveFromList(protectobjectives) for(1 to 10) if(objective.points + totalweight <= 110) break - objective = pickweight(protectobjectives) + objective = PickObjectiveFromList(protectobjectives) + if(!objective) + continue for(var/datum/objective/assassinate/conflicttest in chosenobjectives) //Check to make sure we aren't telling them to Protect somebody they need to Assassinate. if(conflicttest.target == objective.target) conflict = 1 @@ -114,7 +164,7 @@ if(!conflict) chosenobjectives += objective totalweight += objective.points - protectobjectives -= objective + protectobjectives = RemoveObjectiveFromList(protectobjectives, objective) conflict = 0 var/hasendgame = 0 diff --git a/code/game/machinery/doors/door.dm b/code/game/machinery/doors/door.dm index 128b01d9ee..a1d6311b34 100644 --- a/code/game/machinery/doors/door.dm +++ b/code/game/machinery/doors/door.dm @@ -185,7 +185,11 @@ if (src.density) open() else + var/holdopen_old = holdopen + holdopen = 0 close() + spawn(1) + holdopen = holdopen_old else if (src.density) flick("door_deny", src) return diff --git a/code/game/objects/items/weapons/cards_ids.dm b/code/game/objects/items/weapons/cards_ids.dm index e190fbd2c6..e2dd58be85 100644 --- a/code/game/objects/items/weapons/cards_ids.dm +++ b/code/game/objects/items/weapons/cards_ids.dm @@ -195,26 +195,26 @@ FINGERPRINT CARD return "There are no fingerprints on this card." return -/obj/item/weapon/f_card/attack_hand(mob/user as mob) +///obj/item/weapon/f_card/attack_hand(mob/user as mob) - if ((user.r_hand == src || user.l_hand == src)) - src.add_fingerprint(user) - var/obj/item/weapon/f_card/F = new /obj/item/weapon/f_card( user ) - F.amount = 1 - src.amount-- - if (user.hand) - user.l_hand = F - else - user.r_hand = F - F.layer = 20 - F.add_fingerprint(user) - if (src.amount < 1) - //SN src = null - del(src) - return - else - ..() - return +// if ((user.r_hand == src || user.l_hand == src)) +// add_fingerprint(user) +// var/obj/item/weapon/f_card/F = new /obj/item/weapon/f_card( user ) +// F.amount = 1 +// src.amount-- +// if (user.hand) +// user.l_hand = F +// else +// user.r_hand = F +// F.layer = 20 +// F.add_fingerprint(user) +// if (src.amount < 1) +// //SN src = null +// del(src) +// return +// else +// ..() +// return /obj/item/weapon/f_card/attackby(obj/item/weapon/W as obj, mob/user as mob) ..() @@ -253,10 +253,10 @@ FINGERPRINT CARD ..() if (!istype(usr, /mob/living/silicon)) - if (src.fingerprints) + if (fingerprints) if (src.amount > 1) var/obj/item/weapon/f_card/F = new /obj/item/weapon/f_card(get_turf(src)) F.amount = --src.amount - src.amount = 1 - src.icon_state = "fingerprint1" + amount = 1 + icon_state = "fingerprint1" return \ No newline at end of file diff --git a/code/modules/DetectiveWork/detective_work.dm b/code/modules/DetectiveWork/detective_work.dm index 6878b2dd5a..7e5b2bcdfb 100644 --- a/code/modules/DetectiveWork/detective_work.dm +++ b/code/modules/DetectiveWork/detective_work.dm @@ -199,7 +199,6 @@ obj/machinery/computer/forensic_scanning M.drop_item() I.loc = src process_card() - usr << "You insert the card, and it is destroyed by the machinery in the process of comparing prints." else usr << "\red Invalid Object Rejected." if("database") @@ -646,7 +645,9 @@ obj/machinery/computer/forensic_scanning return proc/process_card() //Same as above, but for fingerprint cards - if(card.fingerprints && !(card.amount > 1)) + if(card.fingerprints && !(card.amount > 1) && islist(card.fingerprints) && files && files.len) + usr << "You insert the card, and it is destroyed by the machinery in the process of comparing prints." + var/found = 0 for(var/k = 1, k <= card.fingerprints.len, k++) var/list/test_prints = params2list(card.fingerprints[k]) var/print = test_prints[num2text(1)] @@ -657,7 +658,12 @@ obj/machinery/computer/forensic_scanning if(perp == print) test_list[1] = "1=" + print + "&2=" + print files[i] = test_list + found = 1 break + if(found) + usr << "The machinery finds can completes a match." + else + usr << "No match found." del(card) else usr << "\red ERROR: No prints/too many cards." diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm index 363d95d88f..d9b99a5ee7 100644 --- a/code/modules/admin/verbs/randomverbs.dm +++ b/code/modules/admin/verbs/randomverbs.dm @@ -511,8 +511,9 @@ Traitors and the like can also be revived with the previous role mostly intact. e.perma_injury = 0 e.update_icon() for(var/datum/organ/wound/W in e.wounds) - if(W.bleeding) + if(W.bleeding || !W.is_healing) W.stopbleeding() + del(H.vessel) H.vessel = new/datum/reagents(560) H.vessel.my_atom = H H.vessel.add_reagent("blood",560) diff --git a/code/modules/chemical/Chemistry-Holder.dm b/code/modules/chemical/Chemistry-Holder.dm index da6e433f02..d429802cb5 100644 --- a/code/modules/chemical/Chemistry-Holder.dm +++ b/code/modules/chemical/Chemistry-Holder.dm @@ -317,6 +317,10 @@ datum for(var/A in reagent_list) var/datum/reagent/R = A + if(R.id == "blood" && reagent == R.id) + if(R.data && data) + if(R.data["donor"] != data["donor"]) + continue if (R.id == reagent) R.volume += amount update_total() diff --git a/code/modules/chemical/Chemistry-Reagents.dm b/code/modules/chemical/Chemistry-Reagents.dm index b9b360eeb8..d54eafc97c 100644 --- a/code/modules/chemical/Chemistry-Reagents.dm +++ b/code/modules/chemical/Chemistry-Reagents.dm @@ -103,8 +103,8 @@ datum color = "#C80000" // rgb: 200, 0, 0 on_mob_life(var/mob/living/M) if(istype(M, /mob/living/carbon/human) && blood_incompatible(data["blood_type"],M.dna.b_type)) - M.adjustToxLoss(rand(1.5,3)) - M.adjustOxyLoss(rand(1.5,3)) + M.adjustToxLoss(rand(0.5,1.5)) + M.adjustOxyLoss(rand(1,1.5)) ..() return diff --git a/code/modules/chemical/Chemistry-Tools.dm b/code/modules/chemical/Chemistry-Tools.dm index acc4fb665a..0d60cbb089 100644 --- a/code/modules/chemical/Chemistry-Tools.dm +++ b/code/modules/chemical/Chemistry-Tools.dm @@ -1078,8 +1078,8 @@ var/trans if(B && ishuman(target)) var/mob/living/carbon/human/H = target - H.vessel.add_reagent("blood",5,B) - src.reagents.remove_reagent("blood",5) + H.vessel.add_reagent("blood",(B.volume > 5? 5 : B.volume),B.data) + src.reagents.remove_reagent("blood",(B.volume > 5? 5 : B.volume)) else trans = src.reagents.trans_to(target, amount_per_transfer_from_this) user << "\blue You inject [trans] units of the solution. The syringe now contains [src.reagents.total_volume] units." diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index 627ec60cd0..8a038c8416 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -349,11 +349,11 @@ "severe burn" = "severe burn", "deep burn" = "deep burn", "carbonised area" = "carbonised area") switch(i) if(2) //Healing wounds. - if(tallied in list("cut","tiny bruise","small burn")) + if(tallied in list("cut","small burn")) continue tallied_rename = list("deep cut" = "clotted cut", "flesh wound" = "small bandaged wound",\ "gaping wound" = "bandaged wound", "big gaping wound" = "gauze wrapped wound",\ - "massive wound" = "massive blood soaked bandage", "small bruise" = "small bruise",\ + "massive wound" = "massive blood soaked bandage", "tiny bruise" = "tiny bruise", "small bruise" = "small bruise",\ "moderate bruise" = "moderate bruise", "large bruise" = "large bruise",\ "huge bruise" = "huge bruise", "monumental bruise" = "monumental bruise",\ "moderate burn" = "moderate salved burn", "large burn" = "large salved burn",\ @@ -380,7 +380,7 @@ "large burn" = "large burn scar", "severe burn" = "severe burn scar",\ "deep burn" = "deep burn scar", "carbonised area" = "healing carbonised area") if(5) - if(tallied in list("cut","deep cut","tiny bruise", "small bruise", "moderate bruise","small burn", "moderate burn")) + if(tallied in list("cut","deep cut","tiny bruise", "moderate bruise", "small bruise","small burn", "moderate burn")) continue tallied_rename = list("flesh wound" = "small scar", "gaping wound" = "straight scar",\ "big gaping wound" = "jagged scar", "massive wound" = "gigantic scar",\ @@ -429,6 +429,7 @@ flavor_text_string += flavor_text[text] flavor_text_string += " on [t_his] [named].
" wound_flavor_text["[named]"] = flavor_text_string + world << "[named] + [flavor_text_string]" if(wound_flavor_text["head"] && !skipmask && !(wear_mask && istype(wear_mask, /obj/item/clothing/mask/gas))) msg += wound_flavor_text["head"] else if(is_bleeding["head"]) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 7eff4a056f..b9935eb3bd 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -114,7 +114,7 @@ update_clothing() src << "\blue Your icons have been generated!" - vessel = new/datum/reagents(560) + vessel = new/datum/reagents(600) vessel.my_atom = src vessel.add_reagent("blood",560) spawn(1) fixblood() diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index d93cd88af4..82d714813d 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -447,7 +447,7 @@ return null update_canmove() - if(paralysis || stunned || weakened || buckled || (changeling && changeling.changeling_fakedeath)) canmove = 0 + if(paralysis || resting || stunned || weakened || buckled || (changeling && changeling.changeling_fakedeath)) canmove = 0 else canmove = 1 handle_breath(datum/gas_mixture/breath) diff --git a/code/modules/mob/mob_movement.dm b/code/modules/mob/mob_movement.dm index d30fc1ab88..bb80c60740 100644 --- a/code/modules/mob/mob_movement.dm +++ b/code/modules/mob/mob_movement.dm @@ -156,7 +156,7 @@ if(Process_Grab()) return //Making mob movememnt changes instant. - if(mob.paralysis || mob.stunned || mob.weakened || mob.buckled || (mob.changeling && mob.changeling.changeling_fakedeath)) + if(mob.paralysis || mob.stunned || mob.resting || mob.weakened || mob.buckled || (mob.changeling && mob.changeling.changeling_fakedeath)) mob.canmove = 0 return else diff --git a/code/modules/mob/organ/organ.dm b/code/modules/mob/organ/organ.dm index 6fb0e1c62d..4e3acabe4f 100644 --- a/code/modules/mob/organ/organ.dm +++ b/code/modules/mob/organ/organ.dm @@ -73,6 +73,11 @@ owner = H H.organs[name] = src + Del() + for(var/datum/organ/wound/W in wounds) + del(W) + ..() + proc/take_damage(brute, burn, sharp, used_weapon = null) if((brute <= 0) && (burn <= 0)) return 0 @@ -432,7 +437,7 @@ proc/become_scar() healing_state = 1 //Patched - spawn(200) //20 seconds + spawn(200*slowheal) //20 seconds update_health(5) //Heals some. sleep(rand(1800,3000)*slowheal) //3-5 minutes diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index c388bba979..b11348dd6b 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -98,7 +98,7 @@ playsound(user, fire_sound, 10, 1) else playsound(user, fire_sound, 50, 1) - M.apply_damage(30+in_chamber.damage, BRUTE, used_weapon = "Point Blank Shot") //So we'll put him an inch from death. + M.apply_damage(30+in_chamber.damage, BRUTE, user.zone_sel.selecting, used_weapon = "Point Blank Shot") //So we'll put him an inch from death. M.attack_log += text("\[[]\] []/[] shot []/[] point blank with a []", time_stamp(), user, user.ckey, M, M.ckey, src) user.attack_log += text("\[[]\] []/[] shot []/[] point blank with a []", time_stamp(), user, user.ckey, M, M.ckey, src) log_admin("ATTACK: [user] ([user.ckey]) shot [M] ([M.ckey]) point blank with [src].")