mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 08:08:49 +01:00
Fixes some more climbing/buckling issues (#83986)
## About The Pull Request First of all, updates `COMPONENT_CANCEL_MOUSEDROPPED_ONTO` in the same way Melbert did for `COMPONENT_CANCEL_MOUSEDROP_ONTO`, so it will only block other interactions if it succeeds. Second of all, makes the climbable element compatible with buckling again, since the two behaviors have a lot of overlap. ## Why It's Good For The Game Fixes a bug (Fixes #83998) where the chaplain altar can't be buckled to. There might be other, similar cases that I'm not aware of. ## Changelog 🆑 fix: The chaplain altar can once again be buckled to. /🆑
This commit is contained in:
@@ -82,6 +82,10 @@
|
||||
log_combat(user, climbed_thing, "climbed onto")
|
||||
if(adjusted_climb_stun)
|
||||
user.Stun(adjusted_climb_stun)
|
||||
var/atom/movable/buckle_target = climbed_thing
|
||||
if(istype(buckle_target))
|
||||
if(buckle_target.is_buckle_possible(user))
|
||||
buckle_target.buckle_mob(user)
|
||||
else
|
||||
to_chat(user, span_warning("You fail to climb onto [climbed_thing]."))
|
||||
LAZYREMOVEASSOC(current_climbers, climbed_thing, user)
|
||||
@@ -112,7 +116,6 @@
|
||||
/datum/element/climbable/proc/mousedrop_receive(atom/climbed_thing, atom/movable/dropped_atom, mob/user, params)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
. = COMPONENT_CANCEL_MOUSEDROPPED_ONTO
|
||||
if(user != dropped_atom || !isliving(dropped_atom))
|
||||
return
|
||||
if(!HAS_TRAIT(dropped_atom, TRAIT_FENCE_CLIMBER) && !HAS_TRAIT(dropped_atom, TRAIT_CAN_HOLD_ITEMS)) // If you can hold items you can probably climb a fence
|
||||
@@ -120,3 +123,4 @@
|
||||
var/mob/living/living_target = dropped_atom
|
||||
if(living_target.mobility_flags & MOBILITY_MOVE)
|
||||
INVOKE_ASYNC(src, PROC_REF(climb_structure), climbed_thing, living_target, params)
|
||||
return COMPONENT_CANCEL_MOUSEDROPPED_ONTO
|
||||
|
||||
Reference in New Issue
Block a user