diff --git a/code/__defines/is_helpers.dm b/code/__defines/is_helpers.dm index d7bab37345..f97f206634 100644 --- a/code/__defines/is_helpers.dm +++ b/code/__defines/is_helpers.dm @@ -54,4 +54,4 @@ //--------------- //#define isturf(D) istype(D, /turf) //Built in #define isopenspace(A) istype(A, /turf/simulated/open) -#define isspace(A) istype(A, /turf/space) +#define isspace(A) istype(A, /turf/space) diff --git a/code/_onclick/rig.dm b/code/_onclick/rig.dm index e281505dc2..953531a49d 100644 --- a/code/_onclick/rig.dm +++ b/code/_onclick/rig.dm @@ -63,7 +63,11 @@ return loc == card /mob/living/proc/HardsuitClickOn(var/atom/A, var/alert_ai = 0) +<<<<<<< HEAD if(!can_use_rig()) +======= + if(!can_use_rig() || !checkClickCooldown()) +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor return 0 var/obj/item/weapon/rig/rig = get_rig() if(istype(rig) && !rig.offline && rig.selected_module) diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm index 87a09d538a..26dd1d4a78 100644 --- a/code/game/atoms_movable.dm +++ b/code/game/atoms_movable.dm @@ -21,7 +21,11 @@ var/icon_rotation = 0 // Used to rotate icons in update_transform() var/old_x = 0 var/old_y = 0 +<<<<<<< HEAD var/datum/riding/riding_datum //VOREStation Add - Moved from /obj/vehicle +======= + var/datum/riding/riding_datum = null +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor var/does_spin = TRUE // Does the atom spin when thrown (of course it does :P) var/movement_type = NONE diff --git a/code/game/objects/structures/door_assembly.dm b/code/game/objects/structures/door_assembly.dm index e0a94e285b..40c47c9bb9 100644 --- a/code/game/objects/structures/door_assembly.dm +++ b/code/game/objects/structures/door_assembly.dm @@ -14,8 +14,8 @@ var/glass = 0 // 0 = glass can be installed. -1 = glass can't be installed. 1 = glass is already installed. Text = mineral plating is installed instead. var/created_name = null - New() - update_state() +/obj/structure/door_assembly/New() + update_state() /obj/structure/door_assembly/door_assembly_com base_icon_state = "com" @@ -136,23 +136,23 @@ airlock_type = "/multi_tile/glass" glass = -1 //To prevent bugs in deconstruction process. - New() - if(dir in list(EAST, WEST)) - bound_width = width * world.icon_size - bound_height = world.icon_size - else - bound_width = world.icon_size - bound_height = width * world.icon_size - update_state() +/obj/structure/door_assembly/multi_tile/New() + if(dir in list(EAST, WEST)) + bound_width = width * world.icon_size + bound_height = world.icon_size + else + bound_width = world.icon_size + bound_height = width * world.icon_size + update_state() - Moved(atom/old_loc, direction, forced = FALSE) - . = ..() - if(dir in list(EAST, WEST)) - bound_width = width * world.icon_size - bound_height = world.icon_size - else - bound_width = world.icon_size - bound_height = width * world.icon_size +/obj/structure/door_assembly/multi_tile/Moved(atom/old_loc, direction, forced = FALSE) + . = ..() + if(dir in list(EAST, WEST)) + bound_width = width * world.icon_size + bound_height = world.icon_size + else + bound_width = world.icon_size + bound_height = width * world.icon_size /obj/structure/door_assembly/proc/rename_door(mob/living/user) var/t = sanitizeSafe(input(user, "Enter the name for the windoor.", src.name, src.created_name), MAX_NAME_LEN) diff --git a/code/game/objects/structures/stool_bed_chair_nest/chairs.dm b/code/game/objects/structures/stool_bed_chair_nest/chairs.dm index d471ba3840..e4c8479572 100644 --- a/code/game/objects/structures/stool_bed_chair_nest/chairs.dm +++ b/code/game/objects/structures/stool_bed_chair_nest/chairs.dm @@ -159,6 +159,20 @@ else unbuckle_mob() +/obj/structure/bed/chair/office/handle_buckled_mob_movement(atom/new_loc, direction, movetime) + for(var/A in buckled_mobs) + var/mob/living/occupant = A + occupant.buckled = null + occupant.Move(loc, direction, movetime) + occupant.buckled = src + if (occupant && (loc != occupant.loc)) + if (propelled) + for (var/mob/O in src.loc) + if (O != occupant) + Bump(O) + else + unbuckle_mob() + /obj/structure/bed/chair/office/Bump(atom/A) ..() if(!has_buckled_mobs()) return diff --git a/code/game/objects/structures/target_stake.dm b/code/game/objects/structures/target_stake.dm index 1e9c091ccb..7802e258ea 100644 --- a/code/game/objects/structures/target_stake.dm +++ b/code/game/objects/structures/target_stake.dm @@ -8,45 +8,45 @@ w_class = ITEMSIZE_HUGE var/obj/item/target/pinned_target // the current pinned target - Moved(atom/old_loc, direction, forced = FALSE) - . = ..() - // Move the pinned target along with the stake - if(pinned_target in view(3, src)) - pinned_target.forceMove(loc) +/obj/structure/target_stake/Moved(atom/old_loc, direction, forced = FALSE) + . = ..() + // Move the pinned target along with the stake + if(pinned_target in view(3, src)) + pinned_target.forceMove(loc) - else // Sanity check: if the pinned target can't be found in immediate view - pinned_target = null - density = 1 + else // Sanity check: if the pinned target can't be found in immediate view + pinned_target = null + density = 1 - attackby(obj/item/W as obj, mob/user as mob) - // Putting objects on the stake. Most importantly, targets - if(pinned_target) - return // get rid of that pinned target first! +/obj/structure/target_stake/attackby(obj/item/W as obj, mob/user as mob) + // Putting objects on the stake. Most importantly, targets + if(pinned_target) + return // get rid of that pinned target first! - if(istype(W, /obj/item/target)) - density = 0 - W.density = 1 - user.remove_from_mob(W) - W.loc = loc - W.layer = ABOVE_JUNK_LAYER - pinned_target = W - to_chat(user, "You slide the target into the stake.") - return + if(istype(W, /obj/item/target)) + density = 0 + W.density = 1 + user.remove_from_mob(W) + W.loc = loc + W.layer = ABOVE_JUNK_LAYER + pinned_target = W + to_chat(user, "You slide the target into the stake.") + return - attack_hand(mob/user as mob) - // taking pinned targets off! - if(pinned_target) - density = 1 - pinned_target.density = 0 - pinned_target.layer = OBJ_LAYER +/obj/structure/target_stake/attack_hand(mob/user as mob) + // taking pinned targets off! + if(pinned_target) + density = 1 + pinned_target.density = 0 + pinned_target.layer = OBJ_LAYER - pinned_target.loc = user.loc - if(ishuman(user)) - if(!user.get_active_hand()) - user.put_in_hands(pinned_target) - to_chat(user, "You take the target out of the stake.") - else - pinned_target.loc = get_turf(user) + pinned_target.loc = user.loc + if(ishuman(user)) + if(!user.get_active_hand()) + user.put_in_hands(pinned_target) to_chat(user, "You take the target out of the stake.") + else + pinned_target.loc = get_turf(user) + to_chat(user, "You take the target out of the stake.") - pinned_target = null + pinned_target = null diff --git a/code/modules/ai/interfaces.dm b/code/modules/ai/interfaces.dm index 74ad2eb1a4..798c94bc01 100644 --- a/code/modules/ai/interfaces.dm +++ b/code/modules/ai/interfaces.dm @@ -76,6 +76,7 @@ /mob/living/proc/IMove(turf/newloc, safety = TRUE) if(!checkMoveCooldown()) return MOVEMENT_ON_COOLDOWN +<<<<<<< HEAD // Check to make sure moving to newloc won't actually kill us. e.g. we're a slime and trying to walk onto water. if(istype(newloc)) @@ -94,9 +95,31 @@ var/delay_will_be = movement_delay() . = SelfMove(newloc, get_dir(loc,newloc), delay_will_be) ? MOVEMENT_SUCCESSFUL : MOVEMENT_FAILED +======= + + // Check to make sure moving to newloc won't actually kill us. e.g. we're a slime and trying to walk onto water. + if(istype(newloc)) + if(safety && !newloc.is_safe_to_enter(src)) + return MOVEMENT_FAILED + + // Move()ing to another tile successfully returns 32 because BYOND. Would rather deal with TRUE/FALSE-esque terms. + // Note that moving to the same tile will be 'successful'. + var/turf/old_T = get_turf(src) + + // An adjacency check to avoid mobs phasing diagonally past windows. + // This might be better in general movement code but I'm too scared to add it, and most things don't move diagonally anyways. + if(!old_T.Adjacent(newloc)) + return MOVEMENT_FAILED + + . = SelfMove(newloc) ? MOVEMENT_SUCCESSFUL : MOVEMENT_FAILED +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(. == MOVEMENT_SUCCESSFUL) set_dir(get_dir(old_T, newloc)) // Apply movement delay. // Player movement has more factors but its all in the client and fixing that would be its own project. +<<<<<<< HEAD setMoveCooldown(delay_will_be) +======= + setMoveCooldown(movement_delay()) +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor return \ No newline at end of file diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 554d873dd5..d8275da362 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -1,3 +1,4 @@ +<<<<<<< HEAD /mob/living/carbon/Initialize() . = ..() //setup reagent holders @@ -413,3 +414,408 @@ clear_alert("handcuffed") update_action_buttons() //some of our action buttons might be unusable when we're handcuffed. update_inv_handcuffed() +======= +/mob/living/carbon/Initialize() + . = ..() + //setup reagent holders + bloodstr = new/datum/reagents/metabolism/bloodstream(500, src) + ingested = new/datum/reagents/metabolism/ingested(500, src) + touching = new/datum/reagents/metabolism/touch(500, src) + reagents = bloodstr + if (!default_language && species_language) + default_language = GLOB.all_languages[species_language] + +/mob/living/carbon/Life() + ..() + + handle_viruses() + + // Increase germ_level regularly + if(germ_level < GERM_LEVEL_AMBIENT && prob(30)) //if you're just standing there, you shouldn't get more germs beyond an ambient level + germ_level++ + +/mob/living/carbon/Destroy() + qdel(ingested) + qdel(touching) + // We don't qdel(bloodstr) because it's the same as qdel(reagents) + for(var/guts in internal_organs) + qdel(guts) + for(var/food in stomach_contents) + qdel(food) + return ..() + +/mob/living/carbon/rejuvenate() + bloodstr.clear_reagents() + ingested.clear_reagents() + touching.clear_reagents() + ..() + +/mob/living/carbon/Moved(atom/old_loc, direction, forced = FALSE) + . = ..() + if(src.nutrition && src.stat != 2) + adjust_nutrition(-DEFAULT_HUNGER_FACTOR / 10) + if(src.m_intent == "run") + adjust_nutrition(-DEFAULT_HUNGER_FACTOR / 10) + + if((FAT in src.mutations) && src.m_intent == "run" && src.bodytemperature <= 360) + src.bodytemperature += 2 + + // Moving around increases germ_level faster + if(germ_level < GERM_LEVEL_MOVE_CAP && prob(8)) + germ_level++ + +/mob/living/carbon/relaymove(var/mob/living/user, direction) + if((user in src.stomach_contents) && istype(user)) + if(user.last_special <= world.time) + user.last_special = world.time + 50 + src.visible_message("You hear something rumbling inside [src]'s stomach...") + var/obj/item/I = user.get_active_hand() + if(I && I.force) + var/d = rand(round(I.force / 4), I.force) + if(istype(src, /mob/living/carbon/human)) + var/mob/living/carbon/human/H = src + var/obj/item/organ/external/organ = H.get_organ(BP_TORSO) + if (istype(organ)) + if(organ.take_damage(d, 0)) + H.UpdateDamageIcon() + H.updatehealth() + else + src.take_organ_damage(d) + user.visible_message("[user] attacks [src]'s stomach wall with the [I.name]!") + playsound(user.loc, 'sound/effects/attackblob.ogg', 50, 1) + + if(prob(src.getBruteLoss() - 50)) + for(var/atom/movable/A in stomach_contents) + A.loc = loc + stomach_contents.Remove(A) + src.gib() + +/mob/living/carbon/gib() + for(var/mob/M in src) + if(M in src.stomach_contents) + src.stomach_contents.Remove(M) + M.loc = src.loc + for(var/mob/N in viewers(src, null)) + if(N.client) + N.show_message(text("[M] bursts out of [src]!"), 2) + ..() + +/mob/living/carbon/attack_hand(mob/M as mob) + if(!istype(M, /mob/living/carbon)) return + if (ishuman(M)) + var/mob/living/carbon/human/H = M + var/obj/item/organ/external/temp = H.organs_by_name["r_hand"] + if (H.hand) + temp = H.organs_by_name["l_hand"] + if(temp && !temp.is_usable()) + to_chat(H, "You can't use your [temp.name]") + return + + return + +/mob/living/carbon/electrocute_act(var/shock_damage, var/obj/source, var/siemens_coeff = 1.0, var/def_zone = null, var/stun = 1) + if(status_flags & GODMODE) return 0 //godmode + if(def_zone == "l_hand" || def_zone == "r_hand") //Diona (And any other potential plant people) hands don't get shocked. + if(species.flags & IS_PLANT) + return 0 + shock_damage *= siemens_coeff + if (shock_damage<1) + return 0 + + src.apply_damage(0.2 * shock_damage, BURN, def_zone, used_weapon="Electrocution") //shock the target organ + src.apply_damage(0.4 * shock_damage, BURN, BP_TORSO, used_weapon="Electrocution") //shock the torso more + src.apply_damage(0.2 * shock_damage, BURN, null, used_weapon="Electrocution") //shock a random part! + src.apply_damage(0.2 * shock_damage, BURN, null, used_weapon="Electrocution") //shock a random part! + + playsound(loc, "sparks", 50, 1, -1) + if (shock_damage > 15) + src.visible_message( + "[src] was electrocuted[source ? " by the [source]" : ""]!", \ + "You feel a powerful shock course through your body!", \ + "You hear a heavy electrical crack." \ + ) + else + src.visible_message( + "[src] was shocked[source ? " by the [source]" : ""].", \ + "You feel a shock course through your body.", \ + "You hear a zapping sound." \ + ) + + if(stun) + switch(shock_damage) + if(16 to 20) + Stun(2) + if(21 to 25) + Weaken(2) + if(26 to 30) + Weaken(5) + if(31 to INFINITY) + Weaken(10) //This should work for now, more is really silly and makes you lay there forever + + var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread + s.set_up(5, 1, loc) + s.start() + + return shock_damage + +/mob/living/carbon/proc/help_shake_act(mob/living/carbon/M) + if (src.health >= config.health_threshold_crit) + if(src == M && istype(src, /mob/living/carbon/human)) + var/mob/living/carbon/human/H = src + var/datum/gender/T = gender_datums[H.get_visible_gender()] + src.visible_message( \ + "[src] examines [T.himself].", \ + "You check yourself for injuries." \ + ) + + for(var/obj/item/organ/external/org in H.organs) + var/list/status = list() + var/brutedamage = org.brute_dam + var/burndamage = org.burn_dam + /* + if(halloss > 0) //Makes halloss show up as actual wounds on self examine. + if(prob(30)) + brutedamage += halloss + if(prob(30)) + burndamage += halloss + */ + switch(brutedamage) + if(1 to 20) + status += "bruised" + if(20 to 40) + status += "wounded" + if(40 to INFINITY) + status += "mangled" + + switch(burndamage) + if(1 to 10) + status += "numb" + if(10 to 40) + status += "blistered" + if(40 to INFINITY) + status += "peeling away" + + if(org.is_stump()) + status += "MISSING" + if(org.status & ORGAN_MUTATED) + status += "weirdly shapen" + if(org.dislocated == 2) + status += "dislocated" + if(org.status & ORGAN_BROKEN) + status += "hurts when touched" + if(org.status & ORGAN_DEAD) + status += "is bruised and necrotic" + if(!org.is_usable() || org.is_dislocated()) + status += "dangling uselessly" + if(status.len) + src.show_message("My [org.name] is [english_list(status)].",1) + else + src.show_message("My [org.name] is OK.",1) + + if((SKELETON in H.mutations) && (!H.w_uniform) && (!H.wear_suit)) + H.play_xylophone() + else if (on_fire) + playsound(src.loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1) + if (M.on_fire) + M.visible_message("[M] tries to pat out [src]'s flames, but to no avail!", + "You try to pat out [src]'s flames, but to no avail! Put yourself out first!") + else + M.visible_message("[M] tries to pat out [src]'s flames!", + "You try to pat out [src]'s flames! Hot!") + if(do_mob(M, src, 15)) + src.adjust_fire_stacks(-0.5) + if (prob(10) && (M.fire_stacks <= 0)) + M.adjust_fire_stacks(1) + M.IgniteMob() + if (M.on_fire) + M.visible_message("The fire spreads from [src] to [M]!", + "The fire spreads to you as well!") + else + src.adjust_fire_stacks(-0.5) //Less effective than stop, drop, and roll - also accounting for the fact that it takes half as long. + if (src.fire_stacks <= 0) + M.visible_message("[M] successfully pats out [src]'s flames.", + "You successfully pat out [src]'s flames.") + src.ExtinguishMob() + src.fire_stacks = 0 + else + if (istype(src,/mob/living/carbon/human) && src:w_uniform) + var/mob/living/carbon/human/H = src + H.w_uniform.add_fingerprint(M) + + var/show_ssd + var/mob/living/carbon/human/H = src + var/datum/gender/T = gender_datums[H.get_visible_gender()] // make sure to cast to human before using get_gender() or get_visible_gender()! + if(istype(H)) show_ssd = H.species.show_ssd + if(show_ssd && !client && !teleop) + M.visible_message("[M] shakes [src] trying to wake [T.him] up!", \ + "You shake [src], but [T.he] [T.does] not respond... Maybe [T.he] [T.has] S.S.D?") + else if(lying || src.sleeping) + src.sleeping = max(0,src.sleeping-5) + if(src.sleeping == 0) + src.resting = 0 + M.visible_message("[M] shakes [src] trying to wake [T.him] up!", \ + "You shake [src] trying to wake [T.him] up!") + else + var/mob/living/carbon/human/hugger = M + var/datum/gender/TM = gender_datums[M.get_visible_gender()] + if(M.resting == 1) //Are they resting on the ground? + M.visible_message("[M] grabs onto [src] and pulls [TM.himself] up", \ + "You grip onto [src] and pull yourself up off the ground!") + if(M.fire_stacks >= (src.fire_stacks + 3)) //Fire checks. + src.adjust_fire_stacks(1) + M.adjust_fire_stacks(-1) + if(M.on_fire) + src.IgniteMob() + if(do_after(M, 0.5 SECONDS)) //.5 second delay. Makes it a bit stronger than just typing rest. + M.resting = 0 //Hoist yourself up up off the ground. No para/stunned/weakened removal. + else if(istype(hugger)) + hugger.species.hug(hugger,src) + else + M.visible_message("[M] hugs [src] to make [T.him] feel better!", \ + "You hug [src] to make [T.him] feel better!") + if(M.fire_stacks >= (src.fire_stacks + 3)) + src.adjust_fire_stacks(1) + M.adjust_fire_stacks(-1) + if(M.on_fire) + src.IgniteMob() + AdjustParalysis(-3) + AdjustStunned(-3) + AdjustWeakened(-3) + + playsound(src.loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1) + +/mob/living/carbon/proc/eyecheck() + return 0 + +/mob/living/carbon/flash_eyes(intensity = FLASH_PROTECTION_MODERATE, override_blindness_check = FALSE, affect_silicon = FALSE, visual = FALSE, type = /obj/screen/fullscreen/flash) + if(eyecheck() < intensity || override_blindness_check) + return ..() + +// ++++ROCKDTBEN++++ MOB PROCS -- Ask me before touching. +// Stop! ... Hammertime! ~Carn + +/mob/living/carbon/proc/getDNA() + return dna + +/mob/living/carbon/proc/setDNA(var/datum/dna/newDNA) + dna = newDNA + +// ++++ROCKDTBEN++++ MOB PROCS //END + +/mob/living/carbon/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) + ..() + var/temp_inc = max(min(BODYTEMP_HEATING_MAX*(1-get_heat_protection()), exposed_temperature - bodytemperature), 0) + bodytemperature += temp_inc + +/mob/living/carbon/can_use_hands() + if(handcuffed) + return 0 + if(buckled && istype(buckled, /obj/structure/bed/nest)) // buckling does not restrict hands + return 0 + return 1 + +/mob/living/carbon/restrained() + if (handcuffed) + return 1 + return + +/mob/living/carbon/u_equip(obj/item/W as obj) + if(!W) return 0 + + else if (W == handcuffed) + handcuffed = null + update_inv_handcuffed() + if(buckled && buckled.buckle_require_restraints) + buckled.unbuckle_mob() + + else if (W == legcuffed) + legcuffed = null + update_inv_legcuffed() + else + ..() + + return + +//generates realistic-ish pulse output based on preset levels +/mob/living/carbon/proc/get_pulse(var/method) //method 0 is for hands, 1 is for machines, more accurate + var/temp = 0 //see setup.dm:694 + switch(src.pulse) + if(PULSE_NONE) + return "0" + if(PULSE_SLOW) + temp = rand(40, 60) + return num2text(method ? temp : temp + rand(-10, 10)) + if(PULSE_NORM) + temp = rand(60, 90) + return num2text(method ? temp : temp + rand(-10, 10)) + if(PULSE_FAST) + temp = rand(90, 120) + return num2text(method ? temp : temp + rand(-10, 10)) + if(PULSE_2FAST) + temp = rand(120, 160) + return num2text(method ? temp : temp + rand(-10, 10)) + if(PULSE_THREADY) + return method ? ">250" : "extremely weak and fast, patient's artery feels like a thread" +// output for machines^ ^^^^^^^output for people^^^^^^^^^ + +/mob/living/carbon/verb/mob_sleep() + set name = "Sleep" + set category = "IC" + + if(usr.sleeping) + to_chat(usr, "You are already sleeping") + return + if(alert(src,"You sure you want to sleep for a while?","Sleep","Yes","No") == "Yes") + usr.sleeping = 20 //Short nap + +/mob/living/carbon/Bump(atom/A) + if(now_pushing) + return + ..() + if(istype(A, /mob/living/carbon) && prob(10)) + spread_disease_to(A, "Contact") + +/mob/living/carbon/cannot_use_vents() + return + +/mob/living/carbon/slip(var/slipped_on,stun_duration=8) + if(buckled) + return 0 + stop_pulling() + to_chat(src, "You slipped on [slipped_on]!") + playsound(src.loc, 'sound/misc/slip.ogg', 50, 1, -3) + Weaken(FLOOR(stun_duration/2, 1)) + return 1 + +/mob/living/carbon/proc/add_chemical_effect(var/effect, var/magnitude = 1) + if(effect in chem_effects) + chem_effects[effect] += magnitude + else + chem_effects[effect] = magnitude + +/mob/living/carbon/get_default_language() + if(default_language) + if(can_speak(default_language)) + return default_language + else + return GLOB.all_languages[LANGUAGE_GIBBERISH] + + if(!species) + return null + + return species.default_language ? GLOB.all_languages[species.default_language] : null + +/mob/living/carbon/proc/should_have_organ(var/organ_check) + return 0 + +/mob/living/carbon/can_feel_pain(var/check_organ) + if(isSynthetic()) + return 0 + return !(species.flags & NO_PAIN) + +/mob/living/carbon/needs_to_breathe() + if(does_not_breathe) + return FALSE + return ..() + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 0af9f90225..9ac2827e31 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -1658,7 +1658,11 @@ var/obj/item/organ/external/e = organs_by_name[name] if(!e) continue +<<<<<<< HEAD if((e.status & ORGAN_BROKEN && (!e.splinted || (e.splinted && e.splinted in e.contents && prob(30))) || e.status & ORGAN_BLEEDING) && (getBruteLoss() + getFireLoss() >= 100)) +======= + if((e.status & ORGAN_BROKEN && (!e.splinted || (e.splinted in e.contents && prob(30))) || e.status & ORGAN_BLEEDING) && (getBruteLoss() + getFireLoss() >= 100)) +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor return 1 else return ..() @@ -1679,9 +1683,13 @@ if(istype(loc, /turf/simulated)) var/turf/T = loc T.add_blood(src) +<<<<<<< HEAD . = ..() /mob/living/carbon/human/reduce_cuff_time() if(istype(gloves, /obj/item/clothing/gloves/gauntlets/rig)) return 2 return ..() +======= + . = ..() +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor diff --git a/code/modules/mob/living/carbon/human/human_movement.dm b/code/modules/mob/living/carbon/human/human_movement.dm index cd2d368d6d..2ffd9c6195 100644 --- a/code/modules/mob/living/carbon/human/human_movement.dm +++ b/code/modules/mob/living/carbon/human/human_movement.dm @@ -2,10 +2,19 @@ /mob/living/carbon/human/movement_delay(oldloc, direct) +<<<<<<< HEAD . = 0 if (istype(loc, /turf/space)) return ..() - 1 +======= + . = ..() + + if(species.slowdown) + . = species.slowdown + + if (istype(loc, /turf/space)) return -1 // It's hard to be slowed down in space by... anything +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(species.slowdown) . += species.slowdown @@ -25,6 +34,7 @@ if(can_feel_pain()) if(halloss >= 10) . += (halloss / 10) //halloss shouldn't slow you down if you can't even feel it +<<<<<<< HEAD var/hungry = (500 - nutrition) / 5 //VOREStation Edit - Fixed 500 here instead of our huge MAX_NUTRITION if (hungry >= 70) . += hungry/50 @@ -45,6 +55,10 @@ if(H.weight > L.weight) . += 1 //VOREstation end +======= + var/hungry = (MAX_NUTRITION - nutrition) / 5 + if (hungry >= 70) . += hungry/50 +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(istype(buckled, /obj/structure/bed/chair/wheelchair)) for(var/organ_name in list(BP_L_HAND, BP_R_HAND, BP_L_ARM, BP_R_ARM)) @@ -112,12 +126,15 @@ . -= chem_effects[CE_SPEEDBOOST] // give 'em a buff on top. . = max(HUMAN_LOWEST_SLOWDOWN, . + config.human_delay) // Minimum return should be the same as force_max_speed +<<<<<<< HEAD . += ..() /mob/living/carbon/human/Moved() . = ..() if(embedded_flag) handle_embedded_objects() //Moving with objects stuck in you can cause bad times. +======= +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor // This calculates the amount of slowdown to receive from items worn. This does NOT include species modifiers. // It is in a seperate place to avoid an infinite loop situation with dragging mobs dragging each other. diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 316bb2be88..a017b0457d 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -785,6 +785,11 @@ default behaviour is: to_chat(usr, "OOC Metadata is not supported by this server!") //VOREStation Edit End - Making it so SSD people have prefs with fallback to original style. +<<<<<<< HEAD +======= + return + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor // Almost all of this handles pulling movables behind us /mob/living/Move(atom/newloc, direct, movetime) if(buckled && buckled.loc != newloc) //not updating position @@ -797,9 +802,14 @@ default behaviour is: // Prior to our move it's already too far away if(pullee && get_dist(src, pullee) > 1) stop_pulling() +<<<<<<< HEAD // Shenanigans! if(pullee && !isturf(pullee.loc) && pullee.loc != loc) log_debug("[src]'s pull on [pullee] was broken despite [pullee] being in [pullee.loc]. Pull stopped manually.") +======= + // Shenanigans! Pullee closed into locker for eg. + if(pullee && !isturf(pullee.loc) && pullee.loc != loc) +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor stop_pulling() // Can't pull with no hands if(restrained()) @@ -819,11 +829,19 @@ default behaviour is: if(lying && !buckled && pull_damage() && A.has_gravity && (prob(getBruteLoss() * 200 / maxHealth))) adjustBruteLoss(2) visible_message("\The [src]'s [isSynthetic() ? "state" : "wounds"] worsen terribly from being dragged!") +<<<<<<< HEAD /mob/living/Moved(var/atom/oldloc, direct, forced, movetime) . = ..() handle_footstep(loc) +======= + +/mob/living/Moved(var/atom/oldloc, direct, forced, movetime) + . = ..() + handle_footstep(loc) + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(pulling) // we were pulling a thing and didn't lose it during our move. if(pulling.anchored || !isturf(pulling.loc)) stop_pulling() @@ -1235,7 +1253,11 @@ default behaviour is: //actually throw it! src.visible_message("[src] has thrown [item].") +<<<<<<< HEAD if((istype(src.loc, /turf/space)) || (src.lastarea?.has_gravity == 0)) +======= + if((isspace(src.loc)) || (src.lastarea?.has_gravity == 0)) +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor src.inertia_dir = get_dir(target, src) step(src, inertia_dir) diff --git a/code/modules/mob/living/living_movement.dm b/code/modules/mob/living/living_movement.dm index 8256fe29a0..9407a7cb18 100644 --- a/code/modules/mob/living/living_movement.dm +++ b/code/modules/mob/living/living_movement.dm @@ -8,7 +8,10 @@ return !P.can_hit_target(src, P.permutated, src == P.original, TRUE) return (!mover.density || !density || lying) -/mob/living/SelfMove(turf/n, direct) +/mob/CanZASPass(turf/T, is_zone) + return ATMOS_PASS_YES + +/mob/living/SelfMove(turf/n, direct, movetime) // If on walk intent, don't willingly step into hazardous tiles. // Unless the walker is confused. if(m_intent == "walk" && confused <= 0) diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index 63267c6e09..36293e8bad 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -943,6 +943,13 @@ update_canmove() /mob/living/silicon/robot/mode() +<<<<<<< HEAD +======= + set name = "Activate Held Object" + set category = "IC" + set src = usr + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(!checkClickCooldown()) return diff --git a/code/modules/mob/living/silicon/robot/robot_movement.dm b/code/modules/mob/living/silicon/robot/robot_movement.dm index 4b1c533f21..f74211b7e4 100644 --- a/code/modules/mob/living/silicon/robot/robot_movement.dm +++ b/code/modules/mob/living/silicon/robot/robot_movement.dm @@ -15,6 +15,7 @@ //No longer needed, but I'll leave it here incase we plan to re-use it. /mob/living/silicon/robot/movement_delay() +<<<<<<< HEAD . = speed if(module_active && istype(module_active,/obj/item/borg/combat/mobility)) @@ -23,9 +24,19 @@ . += config.robot_delay . += ..() +======= + . = ..() + + . += speed + + if(module_active && istype(module_active,/obj/item/borg/combat/mobility)) + . -= 3 + + . += config.robot_delay +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor // NEW: Use power while moving. -/mob/living/silicon/robot/SelfMove(turf/n, direct) +/mob/living/silicon/robot/SelfMove(turf/n, direct, movetime) if (!is_component_functioning("actuator")) return 0 diff --git a/code/modules/mob/living/simple_mob/simple_mob.dm b/code/modules/mob/living/simple_mob/simple_mob.dm index 82d16472c1..42366d7bd9 100644 --- a/code/modules/mob/living/simple_mob/simple_mob.dm +++ b/code/modules/mob/living/simple_mob/simple_mob.dm @@ -193,7 +193,7 @@ . = ..() to_chat(src,"You are \the [src]. [player_msg]") -/mob/living/simple_mob/SelfMove(turf/n, direct) +/mob/living/simple_mob/SelfMove(turf/n, direct, movetime) var/turf/old_turf = get_turf(src) var/old_dir = dir . = ..() @@ -211,7 +211,13 @@ return ..() */ /mob/living/simple_mob/movement_delay() +<<<<<<< HEAD . = movement_cooldown +======= + . = ..() + + . += movement_cooldown +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor if(force_max_speed) return -3 @@ -237,10 +243,15 @@ if(m_intent == "walk") . *= 1.5 +<<<<<<< HEAD . += config.animal_delay . += ..() +======= + + . += config.animal_delay +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor /mob/living/simple_mob/Stat() diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index 4d3187bdd2..a3a8b7ab16 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -40,7 +40,10 @@ else living_mob_list += src lastarea = get_area(src) +<<<<<<< HEAD hook_vr("mob_new",list(src)) //VOREStation Code +======= +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor update_transform() // Some mobs may start bigger or smaller than normal. return ..() diff --git a/code/modules/mob/mob_movement.dm b/code/modules/mob/mob_movement.dm index 3d0f88e7a7..0948c119dc 100644 --- a/code/modules/mob/mob_movement.dm +++ b/code/modules/mob/mob_movement.dm @@ -122,6 +122,7 @@ // Nothing to do in nullspace if(!my_mob.loc) return +<<<<<<< HEAD // Used many times below, faster reference. var/atom/loc = my_mob.loc @@ -130,6 +131,16 @@ if(my_mob.control_object) Move_object(direct) +======= + + // Used many times below, faster reference. + var/atom/loc = my_mob.loc + + // We're controlling an object which is SOMEHOW DIFFERENT FROM AN EYE?? + if(my_mob.control_object) + Move_object(direct) + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor // Ghosty mob movement if(my_mob.incorporeal_move && isobserver(my_mob)) Process_Incorpmove(direct) @@ -170,12 +181,21 @@ */ if(Process_Grab()) +<<<<<<< HEAD return // Can't move if(!my_mob.canmove) return +======= + return + + // Can't move + if(!my_mob.canmove) + return + +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor // Relaymove could handle it if(my_mob.machine) var/result = my_mob.machine.relaymove(my_mob, direct) diff --git a/code/modules/vehicles/vehicle.dm b/code/modules/vehicles/vehicle.dm index ed7bdc9a2a..c25b9bad2f 100644 --- a/code/modules/vehicles/vehicle.dm +++ b/code/modules/vehicles/vehicle.dm @@ -42,8 +42,11 @@ var/load_offset_y = 0 //pixel_y offset for item overlay var/mob_offset_y = 0 //pixel_y offset for mob overlay +<<<<<<< HEAD //var/datum/riding/riding_datum = null //VOREStation Edit - Moved to movables. +======= +>>>>>>> 6de7439... Merge pull request #7082 from VOREStation/aro-moverefactor //------------------------------------------- // Standard procs //-------------------------------------------