From 36c2623c62c953e33599e890b3d32073e0e2502a Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 7 Jul 2024 21:49:25 +0200 Subject: [PATCH 01/18] autoclimbable handrails --- code/game/objects/structures/barricade/handrail.dm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 2fde8de3fe98..45b243e4a9cb 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -40,6 +40,11 @@ if(E.icon_path && E.obj_icon_state_path) overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) +/obj/structure/barricade/handrail/Collided(atom/movable/AM) + if(ismob(AM)) + do_climb(AM) + ..() + /obj/structure/barricade/handrail/get_examine_text(mob/user) . = ..() switch(build_state) From 30d63c0c672f982a702e8b0dbea3589ca9674f8a Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 7 Jul 2024 21:54:58 +0200 Subject: [PATCH 02/18] renames var --- code/game/objects/structures/barricade/handrail.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 45b243e4a9cb..ab2c299dc5e0 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -40,9 +40,9 @@ if(E.icon_path && E.obj_icon_state_path) overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) -/obj/structure/barricade/handrail/Collided(atom/movable/AM) - if(ismob(AM)) - do_climb(AM) +/obj/structure/barricade/handrail/Collided(atom/movable/moveable) + if(ismob(moveable)) + do_climb(moveable) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From 068c827cf1aa2ae9f8a29790f177c1527e07dfae Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 7 Jul 2024 21:55:37 +0200 Subject: [PATCH 03/18] typo --- code/game/objects/structures/barricade/handrail.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index ab2c299dc5e0..456073f036e0 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -40,9 +40,9 @@ if(E.icon_path && E.obj_icon_state_path) overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) -/obj/structure/barricade/handrail/Collided(atom/movable/moveable) - if(ismob(moveable)) - do_climb(moveable) +/obj/structure/barricade/handrail/Collided(atom/movable/movable) + if(ismob(movable)) + do_climb(movable) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From e0df49b8fc6edf8a88b2018de6ff6df2352f7758 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 7 Jul 2024 22:03:32 +0200 Subject: [PATCH 04/18] adds in option to prevent autoclimb on the railing --- code/game/objects/structures/barricade/handrail.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 456073f036e0..deaae097b58e 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -18,6 +18,7 @@ var/build_state = BARRICADE_BSTATE_SECURED var/reinforced = FALSE //Reinforced to be a cade or not var/can_be_reinforced = TRUE //can we even reinforce this handrail or not? + var/climbable = TRUE /obj/structure/barricade/handrail/update_icon() overlays.Cut() @@ -42,7 +43,8 @@ /obj/structure/barricade/handrail/Collided(atom/movable/movable) if(ismob(movable)) - do_climb(movable) + if(climbable) + do_climb(movable) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From a9c2f73ad3615423f498d1d4213a07c95a9093c4 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 7 Jul 2024 22:05:09 +0200 Subject: [PATCH 05/18] renames var --- code/game/objects/structures/barricade/handrail.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index deaae097b58e..fe3bcfa4c5b8 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -18,7 +18,7 @@ var/build_state = BARRICADE_BSTATE_SECURED var/reinforced = FALSE //Reinforced to be a cade or not var/can_be_reinforced = TRUE //can we even reinforce this handrail or not? - var/climbable = TRUE + var/autoclimbable = TRUE /obj/structure/barricade/handrail/update_icon() overlays.Cut() @@ -43,7 +43,7 @@ /obj/structure/barricade/handrail/Collided(atom/movable/movable) if(ismob(movable)) - if(climbable) + if(autoclimbable) do_climb(movable) ..() From 2ac1d17487b61bacca6aeafbb6a3c16d46d210ba Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 8 Jul 2024 07:38:47 +0200 Subject: [PATCH 06/18] only harm intent --- code/game/objects/structures/barricade/handrail.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index fe3bcfa4c5b8..29e6edc5815b 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -18,7 +18,6 @@ var/build_state = BARRICADE_BSTATE_SECURED var/reinforced = FALSE //Reinforced to be a cade or not var/can_be_reinforced = TRUE //can we even reinforce this handrail or not? - var/autoclimbable = TRUE /obj/structure/barricade/handrail/update_icon() overlays.Cut() @@ -43,8 +42,9 @@ /obj/structure/barricade/handrail/Collided(atom/movable/movable) if(ismob(movable)) - if(autoclimbable) - do_climb(movable) + var/mob/living/climber = movable + if(climber.a_intent == INTENT_HARM) + do_climb(climber) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From e7cf2ec51852039feb7ae3260ec38271d6e6de01 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 8 Jul 2024 08:23:12 +0200 Subject: [PATCH 07/18] autoclimb --- code/game/objects/structures/barricade/handrail.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 29e6edc5815b..b4d8c96c1b67 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -18,6 +18,7 @@ var/build_state = BARRICADE_BSTATE_SECURED var/reinforced = FALSE //Reinforced to be a cade or not var/can_be_reinforced = TRUE //can we even reinforce this handrail or not? + var/autoclimb = TRUE /obj/structure/barricade/handrail/update_icon() overlays.Cut() @@ -41,7 +42,7 @@ overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) /obj/structure/barricade/handrail/Collided(atom/movable/movable) - if(ismob(movable)) + if(ismob(movable && autoclimb)) var/mob/living/climber = movable if(climber.a_intent == INTENT_HARM) do_climb(climber) From 7f3243caa1698d2caf6030e68452535635da89b7 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 8 Jul 2024 09:09:46 +0200 Subject: [PATCH 08/18] finishing --- code/game/objects/structures.dm | 7 ++++--- code/game/objects/structures/barricade/handrail.dm | 6 ++++-- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/code/game/objects/structures.dm b/code/game/objects/structures.dm index 919f185ebe9e..38f6359f0af3 100644 --- a/code/game/objects/structures.dm +++ b/code/game/objects/structures.dm @@ -110,7 +110,7 @@ /obj/structure/proc/do_climb(mob/living/user, mods) if(!can_climb(user)) - return + return FALSE var/list/climbdata = list("climb_delay" = climb_delay) SEND_SIGNAL(user, COMSIG_LIVING_CLIMB_STRUCTURE, climbdata) @@ -120,10 +120,10 @@ user.visible_message(SPAN_WARNING("[user] starts [flags_atom & ON_BORDER ? "leaping over" : climb_over_string] \the [src]!")) if(!do_after(user, final_climb_delay, INTERRUPT_NO_NEEDHAND, BUSY_ICON_GENERIC, numticks = 2)) - return + return FALSE if(!can_climb(user)) - return + return FALSE var/turf/TT = get_turf(src) if(flags_atom & ON_BORDER) @@ -145,6 +145,7 @@ user.forceMove(TT) for(var/atom/movable/thing as anything in grabbed_things) // grabbed things aren't moved to the tile immediately to: make the animation better, preserve the grab thing.forceMove(TT) + return TRUE /obj/structure/proc/structure_shaken() diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index b4d8c96c1b67..8d6b621e0296 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -42,10 +42,12 @@ overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) /obj/structure/barricade/handrail/Collided(atom/movable/movable) - if(ismob(movable && autoclimb)) + if(ismob(movable) && autoclimb) var/mob/living/climber = movable if(climber.a_intent == INTENT_HARM) - do_climb(climber) + var/climbed = do_climb(climber) + if(climbed) + climber.apply_damage(15,BRUTE) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From 81d128c4bd0d3f725387009d1030382bec10a6df Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 8 Jul 2024 09:18:21 +0200 Subject: [PATCH 09/18] finish --- code/game/objects/structures/barricade/handrail.dm | 1 + 1 file changed, 1 insertion(+) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 8d6b621e0296..ef2130af9f2d 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -48,6 +48,7 @@ var/climbed = do_climb(climber) if(climbed) climber.apply_damage(15,BRUTE) + climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From ce095c7e4e4511dc656650e7a52998f235db1e17 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 8 Jul 2024 13:52:18 +0200 Subject: [PATCH 10/18] crusher and rav behavior --- .../objects/structures/barricade/handrail.dm | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index ef2130af9f2d..8c2131d68476 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -42,13 +42,19 @@ overlays += image(E.icon_path, icon_state = E.obj_icon_state_path) /obj/structure/barricade/handrail/Collided(atom/movable/movable) - if(ismob(movable) && autoclimb) - var/mob/living/climber = movable - if(climber.a_intent == INTENT_HARM) - var/climbed = do_climb(climber) - if(climbed) - climber.apply_damage(15,BRUTE) - climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) + if(istype(movable,/mob/living/carbon/xenomorph/ravager) || istype(movable,/mob/living/carbon/xenomorph/crusher)) + var/mob/living/carbon/xenomorph/xenomorph = movable + if(!xenomorph.stat) //No dead xenos jumpin on the bed~ + visible_message(SPAN_DANGER("[xenomorph] plows straight through [src]!")) + deconstruct(FALSE) + else + if(ismob(movable) && autoclimb) + var/mob/living/climber = movable + if(climber.a_intent == INTENT_HARM) + var/climbed = do_climb(climber) + if(climbed) + climber.apply_damage(15,BRUTE) + climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From c35036f7f4a672c847e3144c370df0cb44158a37 Mon Sep 17 00:00:00 2001 From: cuberound <122645057+cuberound@users.noreply.github.com> Date: Thu, 25 Jul 2024 23:06:48 +0200 Subject: [PATCH 11/18] Update code/game/objects/structures/barricade/handrail.dm Co-authored-by: Drathek <76988376+Drulikar@users.noreply.github.com> --- code/game/objects/structures/barricade/handrail.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 8c2131d68476..18ffa0c5b765 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -44,7 +44,7 @@ /obj/structure/barricade/handrail/Collided(atom/movable/movable) if(istype(movable,/mob/living/carbon/xenomorph/ravager) || istype(movable,/mob/living/carbon/xenomorph/crusher)) var/mob/living/carbon/xenomorph/xenomorph = movable - if(!xenomorph.stat) //No dead xenos jumpin on the bed~ + if(xenomorph.stat == CONSCIOUS) //No dead xenos jumpin on the bed~ visible_message(SPAN_DANGER("[xenomorph] plows straight through [src]!")) deconstruct(FALSE) else From c008c0852d0f026c3a45b10f03f926a2b9d76c39 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Fri, 26 Jul 2024 13:17:24 +0200 Subject: [PATCH 12/18] no limb loss and attempt for move delay --- code/game/objects/structures/barricade/handrail.dm | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 8c2131d68476..6a88124b0043 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -44,7 +44,7 @@ /obj/structure/barricade/handrail/Collided(atom/movable/movable) if(istype(movable,/mob/living/carbon/xenomorph/ravager) || istype(movable,/mob/living/carbon/xenomorph/crusher)) var/mob/living/carbon/xenomorph/xenomorph = movable - if(!xenomorph.stat) //No dead xenos jumpin on the bed~ + if(!xenomorph.stat) visible_message(SPAN_DANGER("[xenomorph] plows straight through [src]!")) deconstruct(FALSE) else @@ -53,8 +53,13 @@ if(climber.a_intent == INTENT_HARM) var/climbed = do_climb(climber) if(climbed) - climber.apply_damage(15,BRUTE) - climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) + climber.client.move_delay += 3 DECISECONDS + if(prob(25)) + if(ishuman(climber)) + climber.apply_damage(15,BRUTE,no_limb_loss = TRUE) + else + climber.apply_damage(15,BRUTE) + climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) ..() /obj/structure/barricade/handrail/get_examine_text(mob/user) From 7140fd6fc2a0d6694e92d702dca0dc0815a76ba7 Mon Sep 17 00:00:00 2001 From: cuberound <122645057+cuberound@users.noreply.github.com> Date: Sun, 28 Jul 2024 16:22:18 +0200 Subject: [PATCH 13/18] Update code/game/objects/structures/barricade/handrail.dm Co-authored-by: Drathek <76988376+Drulikar@users.noreply.github.com> --- code/game/objects/structures/barricade/handrail.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 6a88124b0043..2436f2b3fe3a 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -53,7 +53,7 @@ if(climber.a_intent == INTENT_HARM) var/climbed = do_climb(climber) if(climbed) - climber.client.move_delay += 3 DECISECONDS + climber.client?.move_delay += 3 DECISECONDS if(prob(25)) if(ishuman(climber)) climber.apply_damage(15,BRUTE,no_limb_loss = TRUE) From e317454315b751119c0f6adf3c27cd087e3e37ed Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 28 Jul 2024 14:24:05 +0200 Subject: [PATCH 14/18] retypes --- code/game/objects/structures/barricade/handrail.dm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 2436f2b3fe3a..e548a80d0805 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -56,7 +56,8 @@ climber.client?.move_delay += 3 DECISECONDS if(prob(25)) if(ishuman(climber)) - climber.apply_damage(15,BRUTE,no_limb_loss = TRUE) + var/mob/living/carbon/human/human = climber + human.apply_damage(15,BRUTE,no_limb_loss = TRUE) else climber.apply_damage(15,BRUTE) climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) From 80d98b54e81544e297b4f4442d26e1dd9aae0d49 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Sun, 28 Jul 2024 14:29:47 +0200 Subject: [PATCH 15/18] crusher handeled --- code/game/objects/structures/barricade/handrail.dm | 1 + 1 file changed, 1 insertion(+) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index e548a80d0805..b029a147bde7 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -47,6 +47,7 @@ if(!xenomorph.stat) visible_message(SPAN_DANGER("[xenomorph] plows straight through [src]!")) deconstruct(FALSE) + return else if(ismob(movable) && autoclimb) var/mob/living/climber = movable From ac758a035653d7fd1a66b16fded943e36106d612 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 29 Jul 2024 18:19:08 +0200 Subject: [PATCH 16/18] corrects the delay --- code/game/objects/structures/barricade/handrail.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index b029a147bde7..e0f085c064db 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -52,9 +52,9 @@ if(ismob(movable) && autoclimb) var/mob/living/climber = movable if(climber.a_intent == INTENT_HARM) + climber.client?.move_delay += 3 DECISECONDS var/climbed = do_climb(climber) if(climbed) - climber.client?.move_delay += 3 DECISECONDS if(prob(25)) if(ishuman(climber)) var/mob/living/carbon/human/human = climber From af8fed8be7784c43bbf34ae0e7586eaa9e30e201 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 29 Jul 2024 18:20:29 +0200 Subject: [PATCH 17/18] xenos intentionaly take more damage as they have more health and welp they kinda do not care about that 15 --- code/game/objects/structures/barricade/handrail.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index e0f085c064db..983dbd82706d 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -58,7 +58,7 @@ if(prob(25)) if(ishuman(climber)) var/mob/living/carbon/human/human = climber - human.apply_damage(15,BRUTE,no_limb_loss = TRUE) + human.apply_damage(5,BRUTE,no_limb_loss = TRUE) else climber.apply_damage(15,BRUTE) climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) From 7952d21d5d40a56e7b60166a4ee30046a066bea1 Mon Sep 17 00:00:00 2001 From: vincibrv Date: Mon, 29 Jul 2024 18:21:02 +0200 Subject: [PATCH 18/18] eh okey xenos taking harm by jumping over railing is silly --- code/game/objects/structures/barricade/handrail.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/structures/barricade/handrail.dm b/code/game/objects/structures/barricade/handrail.dm index 983dbd82706d..e1315859725e 100644 --- a/code/game/objects/structures/barricade/handrail.dm +++ b/code/game/objects/structures/barricade/handrail.dm @@ -60,7 +60,7 @@ var/mob/living/carbon/human/human = climber human.apply_damage(5,BRUTE,no_limb_loss = TRUE) else - climber.apply_damage(15,BRUTE) + climber.apply_damage(5,BRUTE) climber.visible_message(SPAN_WARNING("You hit yourself as you vault over the [src]")) ..()