This commit is contained in:
kevinz000
2020-01-16 00:18:40 -07:00
parent 26525b8fa7
commit 350c5aa060
11 changed files with 18 additions and 16 deletions
+2 -1
View File
@@ -97,7 +97,8 @@
/datum/action/proc/IsAvailable()
if(!owner)
return FALSE
if(!CHECK_ALL_MOBILITY(owner, required_mobility_flags))
var/mob/living/L = owner
if(istype(L) && !CHECK_ALL_MOBILITY(L, required_mobility_flags))
return FALSE
if(check_flags & AB_CHECK_RESTRAINED)
if(owner.restrained())
+2 -1
View File
@@ -117,7 +117,8 @@
if(DEAD)
to_chat(user, "<span class='notice'>You cannot [key] while dead.</span>")
return FALSE
if(restraint_check && !CHECK_MOBILITY(user, MOBILITY_MOVE))
var/mob/living/L = user
if(restraint_check && (istype(L) && !CHECK_MOBILITY(user, MOBILITY_USE)))
if(!intentional)
return FALSE
to_chat(user, "<span class='notice'>You cannot [key] while stunned.</span>")
+1 -1
View File
@@ -227,7 +227,7 @@
H.visible_message("<span class='warning'>[H] collapses!</span>", \
"<span class='userdanger'>Your legs give out!</span>")
H.DefaultCombatKnockdown(80)
if(H.staminaloss && !_REFACTORING_H.IsSleeping())
if(H.staminaloss && !H._REFACTORING_IsSleeping())
var/total_health = (H.health - H.staminaloss)
if(total_health <= HEALTH_THRESHOLD_CRIT && !H.stat)
H.visible_message("<span class='warning'>[user] delivers a heavy hit to [H]'s head, knocking [H.p_them()] out cold!</span>", \
+2 -2
View File
@@ -750,7 +750,7 @@
AI.cancel_camera()
AI.controlled_mech = src
AI.remote_control = src
AI.canmove = 1 //Much easier than adding AI checks! Be sure to set this back to 0 if you decide to allow an AI to leave a mech somehow.
AI.mobility_flags = MOBILIITY_FLAG_DEFAULT //Much easier than adding AI checks! Be sure to set this back to 0 if you decide to allow an AI to leave a mech somehow.
AI.can_shunt = 0 //ONE AI ENTERS. NO AI LEAVES.
to_chat(AI, AI.can_dominate_mechs ? "<span class='announce'>Takeover of [name] complete! You are now loaded onto the onboard computer. Do not attempt to leave the station sector!</span>" :\
"<span class='notice'>You have been uploaded to a mech's onboard computer.</span>")
@@ -922,7 +922,7 @@
brainmob.forceMove(src) //should allow relaymove
brainmob.reset_perspective(src)
brainmob.remote_control = src
brainmob.update_canmove()
brainmob.update_mobility()
brainmob.update_mouse_pointer()
icon_state = initial(icon_state)
update_icon()
@@ -205,7 +205,7 @@
buckled_mob.pixel_y = buckled_mob.get_standard_pixel_y_offset(180)
src.visible_message(text("<span class='danger'>[buckled_mob][buckled_mob.stat==DEAD?"'s corpse":""] slides off of the rack.</span>"))
density = FALSE
buckled_mob.AdjustKnockdown(30)
buckled_mob.DefaultCombatKnockdown(30)
update_icon()
useLock = FALSE // Failsafe
+2 -2
View File
@@ -135,7 +135,7 @@
if(L.anti_magic_check(check_anti_magic, check_holy))
immune += L
return
L.Stun(20, 1, 1)
L._REFACTORING_Stun(20, TRUE, TRUE)
frozen_mobs[L] = L.anchored
L.anchored = TRUE
global_frozen_atoms[L] = TRUE
@@ -146,7 +146,7 @@
/datum/proximity_monitor/advanced/timestop/proc/unfreeze_mob(mob/living/L)
escape_the_negative_zone(L)
L.AdjustStun(-20, 1, 1)
L._REFACTORING_AdjustStun(-20, TRUE, TRUE)
L.anchored = frozen_mobs[L]
frozen_mobs -= L
global_frozen_atoms -= L
@@ -22,10 +22,11 @@ In all, this is a lot like the monkey code. /N
switch(M.a_intent)
if (INTENT_HELP)
if(!recoveringstam)
SetResting(FALSE, TRUE)
AdjustAllImmobility(-60)
AdjustUnconscious(-60)
AdjustSleeping(-100)
set_resting(FALSE, TRUE, FALSE)
AdjustAllImmobility(-60, FALSE)
AdjustUnconscious(-60, FALSE)
AdjustSleeping(-100, FALSE)
update_mobililty()
visible_message("<span class='notice'>[M.name] nuzzles [src] trying to wake [p_them()] up!</span>")
if(INTENT_DISARM, INTENT_HARM)
if(health > 0)
@@ -885,7 +885,7 @@
if(do_after(src, 30, TRUE, target))
//Second check to make sure they're still valid to be carried
if(can_be_firemanned(target) && !incapacitated(FALSE, TRUE))
target.resting = FALSE
target.set_resting(FALSE, TRUE)
buckle_mob(target, TRUE, TRUE, 90, 1, 0)
return
visible_message("<span class='warning'>[src] fails to fireman carry [target]!")
@@ -1370,7 +1370,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
return TRUE
if(radiation > RAD_MOB_KNOCKDOWN && prob(RAD_MOB_KNOCKDOWN_PROB))
if(!H.IsKnockdown())
if(CHECK_MOBILITY(H, MOBILITY_STAND))
H.emote("collapse")
H.DefaultCombatKnockdown(RAD_MOB_KNOCKDOWN_AMOUNT)
to_chat(H, "<span class='danger'>You feel weak.</span>")
-1
View File
@@ -422,7 +422,6 @@
else
if(alert(src, "You sure you want to sleep for a while?", "Sleep", "Yes", "No") == "Yes")
SetSleeping(400) //Short nap
update_canmove()
/mob/proc/get_contents()
@@ -446,4 +446,4 @@ SLEEPER CODE IS IN game/objects/items/devices/dogborg_sleeper.dm !
leaping = 0
pixel_y = initial(pixel_y)
update_icons()
update_canmove()
update_mobility()