This commit is contained in:
Kraseo
2020-03-06 11:58:11 +01:00
460 changed files with 212409 additions and 207837 deletions
+1 -2
View File
@@ -23,8 +23,7 @@ GLOBAL_PROTECT(protected_ranks)
name = init_name
if(!name)
qdel(src)
throw EXCEPTION("Admin rank created without name.")
return
CRASH("Admin rank created without name.")
if(init_rights)
rights = init_rights
include_rights = rights
+2 -4
View File
@@ -39,12 +39,10 @@ GLOBAL_PROTECT(href_token)
return
if(!ckey)
QDEL_IN(src, 0)
throw EXCEPTION("Admin datum created without a ckey")
return
CRASH("Admin datum created without a ckey")
if(!istype(R))
QDEL_IN(src, 0)
throw EXCEPTION("Admin datum created without a rank")
return
CRASH("Admin datum created without a rank")
target = ckey
name = "[ckey]'s admin datum ([R])"
rank = R
+1 -1
View File
@@ -21,6 +21,6 @@
target.gib(1, 1)
else
target.adjustBruteLoss(min(99,(target.health - 1)))
target.Knockdown(400)
target.DefaultCombatKnockdown(400)
target.stuttering = 20
+3 -3
View File
@@ -47,7 +47,7 @@
"emagged" = borg.emagged,
"active_module" = "[borg.module.type]",
"lawupdate" = borg.lawupdate,
"lockdown" = borg.lockcharge,
"lockdown" = borg.locked_down,
"scrambledcodes" = borg.scrambledcodes
)
.["upgrades"] = list()
@@ -122,8 +122,8 @@
message_admins("[key_name_admin(user)] disabled lawsync on [ADMIN_LOOKUPFLW(borg)].")
log_admin("[key_name(user)] disabled lawsync on [key_name(borg)].")
if ("toggle_lockdown")
borg.SetLockdown(!borg.lockcharge)
if (borg.lockcharge)
borg.SetLockdown(!borg.locked_down)
if (borg.locked_down)
message_admins("[key_name_admin(user)] locked down [ADMIN_LOOKUPFLW(borg)].")
log_admin("[key_name(user)] locked down [key_name(borg)].")
else
@@ -116,14 +116,13 @@
var/mob/living/carbon/human/M = loc
M.adjustStaminaLoss(-75)
M.SetUnconscious(0)
M.SetStun(0)
M.SetKnockdown(0)
M.SetAllImmobility(0)
combat_cooldown = 0
START_PROCESSING(SSobj, src)
/obj/item/clothing/suit/armor/abductor/vest/process()
combat_cooldown++
if(combat_cooldown==initial(combat_cooldown))
if(combat_cooldown == initial(combat_cooldown))
STOP_PROCESSING(SSobj, src)
/obj/item/clothing/suit/armor/abductor/Destroy()
@@ -512,7 +511,7 @@
L.lastattackerckey = user.ckey
L.adjustStaminaLoss(35) //because previously it took 5-6 hits to actually "incapacitate" someone for the purposes of the sleep inducement
L.Knockdown(140)
L.DefaultCombatKnockdown(140)
L.apply_effect(EFFECT_STUTTER, 7)
SEND_SIGNAL(L, COMSIG_LIVING_MINOR_SHOCK)
@@ -218,11 +218,16 @@
/mob/living/simple_animal/hostile/blob/blobbernaut/Initialize()
. = ..()
if(!independent) //no pulling people deep into the blob
verbs -= /mob/living/verb/pulled
else
if(independent)
pass_flags &= ~PASSBLOB
/mob/living/simple_animal/hostile/blob/blobbernaut/start_pulling(atom/movable/AM, state, force = pull_force, supress_message = FALSE)
if(!independent && ismob(AM))
if(!supress_message)
to_chat(src, "<span class='warning'>You are unable to grasp people in this form.</span>")
return FALSE
return ..()
/mob/living/simple_animal/hostile/blob/blobbernaut/Life()
if(..())
var/list/blobs_in_area = range(2, src)
@@ -157,6 +157,9 @@ GLOBAL_LIST_EMPTY(blob_nodes)
BM.overmind = null
BM.update_icons()
GLOB.overminds -= src
blob_mobs = null
resource_blobs = null
blobs_legit = null
SSshuttle.clearHostileEnvironment(src)
@@ -303,8 +303,7 @@
/obj/structure/blob/proc/change_to(type, controller)
if(!ispath(type))
throw EXCEPTION("change_to(): invalid type for blob")
return
CRASH("change_to(): invalid type for blob")
var/obj/structure/blob/B = new type(src.loc, controller)
B.creation_action()
B.update_icon()
@@ -96,7 +96,7 @@
// Incap?
if(must_be_capacitated)
var/mob/living/L = owner
if (L.incapacitated(TRUE, TRUE) || L.resting && !can_be_immobilized)
if (L.incapacitated(TRUE, TRUE) || !CHECK_MOBILITY(L, MOBILITY_STAND) && !can_be_immobilized)
if(display_error)
to_chat(owner, "<span class='warning'>Not while you're incapacitated!</span>")
return FALSE
@@ -1,9 +1,5 @@
// organ_internal.dm -- /obj/item/organ
// Do I have a stake in my heart?
/mob/living/AmStaked()
var/obj/item/bodypart/BP = get_bodypart("chest")
@@ -13,16 +9,14 @@
if (istype(I,/obj/item/stake/))
return TRUE
return FALSE
/mob/proc/AmStaked()
return FALSE
/mob/living/proc/StakeCanKillMe()
return IsSleeping() || stat >= UNCONSCIOUS || blood_volume <= 0 || HAS_TRAIT(src, TRAIT_DEATHCOMA) // NOTE: You can't go to sleep in a coffin with a stake in you.
///obj/item/weapon/melee/stake
/obj/item/stake/
/obj/item/stake
name = "wooden stake"
desc = "A simple wooden stake carved to a sharp point."
icon = 'icons/obj/items_and_weapons.dmi'
@@ -112,8 +106,7 @@
// Can this target be staked? If someone stands up before this is complete, it fails. Best used on someone stationary.
/mob/living/carbon/proc/can_be_staked()
//return resting || IsKnockdown() || IsUnconscious() || (stat && (stat != SOFT_CRIT || pulledby)) || (has_trait(TRAIT_FAKEDEATH)) || resting || IsStun() || IsFrozen() || (pulledby && pulledby.grab_state >= GRAB_NECK)
return (resting || lying || IsUnconscious() || pulledby && pulledby.grab_state >= GRAB_NECK)
return !CHECK_MOBILITY(src, MOBILITY_STAND)
// ABOVE: Taken from update_mobility() in living.dm
/obj/item/stake/hardened
@@ -42,25 +42,18 @@
/obj/structure/closet/crate
var/mob/living/resident // This lets bloodsuckers claim any "closet" as a Coffin, so long as they could get into it and close it. This locks it in place, too.
/obj/structure/closet/crate/coffin
var/pryLidTimer = 250
can_weld_shut = FALSE
breakout_time = 200
/obj/structure/closet/crate/coffin/blackcoffin
name = "black coffin"
desc = "For those departed who are not so dear."
icon_state = "coffin"
icon = 'icons/obj/vamp_obj.dmi'
can_weld_shut = FALSE
resistance_flags = 0 // Start off with no bonuses.
open_sound = 'sound/bloodsucker/coffin_open.ogg'
close_sound = 'sound/bloodsucker/coffin_close.ogg'
breakout_time = 600
pryLidTimer = 400
resistance_flags = NONE
integrity_failure = 70
max_integrity = 100
integrity_failure = 0.5
armor = list("melee" = 50, "bullet" = 20, "laser" = 30, "energy" = 0, "bomb" = 50, "bio" = 0, "rad" = 0, "fire" = 70, "acid" = 60)
/obj/structure/closet/crate/coffin/meatcoffin
@@ -68,8 +61,6 @@
desc = "When you're ready to meat your maker, the steaks can never be too high."
icon_state = "meatcoffin"
icon = 'icons/obj/vamp_obj.dmi'
can_weld_shut = FALSE
resistance_flags = 0 // Start off with no bonuses.
open_sound = 'sound/effects/footstep/slime1.ogg'
close_sound = 'sound/effects/footstep/slime1.ogg'
breakout_time = 200
@@ -77,24 +68,23 @@
resistance_flags = NONE
material_drop = /obj/item/reagent_containers/food/snacks/meat/slab
material_drop_amount = 3
integrity_failure = 40
integrity_failure = 0.57
armor = list("melee" = 70, "bullet" = 10, "laser" = 10, "energy" = 0, "bomb" = 70, "bio" = 0, "rad" = 0, "fire" = 70, "acid" = 100)
/obj/structure/closet/crate/coffin/metalcoffin
name = "metal coffin"
desc = "A big metal sardine can inside of another big metal sardine can, in space."
icon_state = "metalcoffin"
icon = 'icons/obj/vamp_obj.dmi'
can_weld_shut = FALSE
resistance_flags = FIRE_PROOF | LAVA_PROOF
open_sound = 'sound/effects/pressureplate.ogg'
close_sound = 'sound/effects/pressureplate.ogg'
breakout_time = 300
pryLidTimer = 200
resistance_flags = NONE
material_drop = /obj/item/stack/sheet/metal
material_drop_amount = 5
integrity_failure = 60
max_integrity = 200
integrity_failure = 0.25
armor = list("melee" = 40, "bullet" = 15, "laser" = 50, "energy" = 0, "bomb" = 10, "bio" = 0, "rad" = 0, "fire" = 70, "acid" = 60)
//////////////////////////////////////////////
@@ -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
@@ -72,8 +72,7 @@
if(rand(5 + powerlevel) >= 5)
target.visible_message("<span class='danger'>[user] lands a vicious punch, sending [target] away!</span>", \
"<span class='userdanger'>[user] has landed a horrifying punch on you, sending you flying!!</span>", null, COMBAT_MESSAGE_RANGE)
target.Knockdown(min(5, rand(10, 10 * powerlevel)) )
target.DefaultCombatKnockdown(min(5, rand(10, 10 * powerlevel)) )
// Attack!
playsound(get_turf(target), 'sound/weapons/punch4.ogg', 60, 1, -1)
user.do_attack_animation(target, ATTACK_EFFECT_SMASH)
@@ -145,7 +144,7 @@
// Knock Down (if Living)
if (isliving(M))
var/mob/living/L = M
L.Knockdown(pull_power * 10 + 20)
L.DefaultCombatKnockdown(pull_power * 10 + 20)
// Knock Back (before Knockdown, which probably cancels pull)
var/send_dir = get_dir(owner, M)
var/turf/T = get_ranged_target_turf(M, send_dir, pull_power)
@@ -306,7 +306,7 @@
// Bloodsuckers not affected by "the Kiss" of another vampire
if(!target.mind || !target.mind.has_antag_datum(ANTAG_DATUM_BLOODSUCKER))
target.Unconscious(50,0)
target.Knockdown(40 + 5 * level_current,1)
target.DefaultCombatKnockdown(40 + 5 * level_current,1)
// NOTE: THis is based on level of power!
if(ishuman(target))
target.adjustStaminaLoss(5, forced = TRUE)// Base Stamina Damage
@@ -321,4 +321,4 @@
// My mouth is no longer full
REMOVE_TRAIT(owner, TRAIT_MUTE, "bloodsucker_feed")
// Let me move immediately
user.update_canmove()
user.update_mobility()
@@ -100,8 +100,8 @@
var/mob/living/simple_animal/SA = pick(/mob/living/simple_animal/mouse,/mob/living/simple_animal/mouse,/mob/living/simple_animal/mouse, /mob/living/simple_animal/hostile/retaliate/bat) //prob(300) /mob/living/simple_animal/mouse,
new SA (owner.loc)
// TELEPORT: Move to Coffin & Close it!
user.set_resting(TRUE, TRUE, FALSE)
do_teleport(owner, bloodsuckerdatum.coffin, no_effects = TRUE, forced = TRUE, channel = TELEPORT_CHANNEL_QUANTUM)
user.resting = TRUE
user.Stun(30,1)
// CLOSE LID: If fail, force me in.
if(!bloodsuckerdatum.coffin.close(owner))
@@ -76,16 +76,17 @@
sleep(speed)
UnregisterSignal(owner, COMSIG_MOVABLE_MOVED)
hit = null
user.update_canmove()
user.update_mobility()
/datum/action/bloodsucker/targeted/haste/DeactivatePower(mob/living/user = owner, mob/living/target)
..() // activate = FALSE
user.update_canmove()
user.update_mobility()
/datum/action/bloodsucker/targeted/haste/proc/on_move()
for(var/mob/living/L in dview(1, get_turf(owner)))
if(!hit[L] && (L != owner))
hit[L] = TRUE
playsound(L, "sound/weapons/punch[rand(1,4)].ogg", 15, 1, -1)
L.Knockdown(10 + level_current * 5, override_hardstun = 0.1)
L.DefaultCombatKnockdown(10 + level_current * 5)
L.Paralyze(0.1)
L.spin(10, 1)
@@ -52,6 +52,7 @@
// set waitfor = FALSE <---- DONT DO THIS!We WANT this power to hold up ClickWithPower(), so that we can unlock the power when it's done.
var/mob/living/carbon/target = A
var/turf/T = get_turf(target)
var/mob/living/L = owner
// Clear Vars
owner.pulling = null
// Will we Knock them Down?
@@ -63,7 +64,7 @@
owner.playsound_local(owner, 'sound/bloodsucker/lunge_warn.ogg', 60, FALSE, pressure_affected = FALSE) // audio feedback to the user
if(do_mob(owner, owner, 7, TRUE, TRUE))
walk_towards(owner, T, 0.1, 10) // yes i know i shouldn't use this but i don't know how to work in anything better
if(get_turf(owner) != T && !(isliving(target) && target.Adjacent(owner)) && owner.incapacitated() && owner.resting)
if(get_turf(owner) != T && !(isliving(target) && target.Adjacent(owner)) && owner.incapacitated() && !CHECK_MOBILITY(L, MOBILITY_STAND))
var/send_dir = get_dir(owner, T)
new /datum/forced_movement(owner, get_ranged_target_turf(owner, send_dir, 1), 1, FALSE)
owner.spin(10)
@@ -84,4 +85,4 @@
/datum/action/bloodsucker/targeted/lunge/DeactivatePower(mob/living/user = owner, mob/living/target)
..() // activate = FALSE
user.update_canmove()
user.update_mobility()
@@ -82,7 +82,7 @@
to_chat(owner, "<span class='warning'>You must be facing your victim.</span>")
return FALSE
// Check: Target facing me?
if(!target.resting && !is_A_facing_B(target,owner))
if (CHECK_MOBILITY(target, MOBILITY_STAND) && !is_A_facing_B(target,owner))
if(display_error)
to_chat(owner, "<span class='warning'>Your victim must be facing you to see into your eyes.</span>")
return FALSE
@@ -81,7 +81,7 @@
if(istype(our_target, /datum/cellular_emporium))
cellular_emporium = our_target
else
throw EXCEPTION("cellular_emporium action created with non emporium")
CRASH("cellular_emporium action created with non emporium")
/datum/action/innate/cellular_emporium/Activate()
cellular_emporium.ui_interact(owner)
@@ -18,7 +18,6 @@
user.tod = STATION_TIME_TIMESTAMP("hh:mm:ss", world.time)
user.fakedeath("changeling") //play dead
user.update_stat()
user.update_canmove()
addtimer(CALLBACK(src, .proc/ready_to_regenerate, user), LING_FAKEDEATH_TIME, TIMER_UNIQUE)
return TRUE
@@ -30,7 +30,7 @@
H.confused += 3
for(var/mob/living/silicon/S in range(2,user))
to_chat(S, "<span class='userdanger'>Your sensors are disabled by a shower of blood!</span>")
S.Knockdown(60)
S.DefaultCombatKnockdown(60)
var/turf = get_turf(user)
user.gib()
. = TRUE
@@ -24,7 +24,7 @@
if(issilicon(M))
SEND_SOUND(M, sound('sound/weapons/flash.ogg'))
M.Knockdown(rand(100,200))
M.DefaultCombatKnockdown(rand(100,200))
for(var/obj/machinery/light/L in range(4, user))
L.on = 1
@@ -26,7 +26,7 @@
changeling.chem_recharge_slowdown -= 0.5
if(stacks >= 20)
to_chat(user, "<span class='danger'>We collapse in exhaustion.</span>")
user.Knockdown(60)
user.DefaultCombatKnockdown(60)
user.emote("gasp")
INVOKE_ASYNC(src, .proc/muscle_loop, user)
@@ -40,7 +40,7 @@
if(user.stat != CONSCIOUS || user.staminaloss >= 90)
active = !active
to_chat(user, "<span class='notice'>Our muscles relax without the energy to strengthen them.</span>")
user.Knockdown(40)
user.DefaultCombatKnockdown(40)
user.remove_movespeed_modifier(MOVESPEED_ID_CHANGELING_MUSCLES)
changeling.chem_recharge_slowdown -= 0.5
break
@@ -80,7 +80,7 @@
if(iscultist(L)) //No longer stuns cultists, instead sets them on fire and burns them
to_chat(L, "<span class='heavy_brass'>\"Watch your step, wretch.\"</span>")
L.adjustFireLoss(10)
L.Knockdown(20, FALSE)
L.DefaultCombatKnockdown(20, FALSE)
L.adjust_fire_stacks(5) //Burn!
L.IgniteMob()
else
@@ -155,7 +155,7 @@
if(brutedamage || burndamage)
L.adjustBruteLoss(-(brutedamage * 0.25))
L.adjustFireLoss(-(burndamage * 0.25))
L.Knockdown(50) //Completely defenseless for five seconds - mainly to give them time to read over the information they've just been presented with
L.DefaultCombatKnockdown(50) //Completely defenseless for five seconds - mainly to give them time to read over the information they've just been presented with
if(iscarbon(L))
var/mob/living/carbon/C = L
C.silent += 5
@@ -196,7 +196,7 @@
if(!iscultist(L))
L.visible_message("<span class='warning'>[L]'s eyes blaze with brilliant light!</span>", \
"<span class='userdanger'>Your vision suddenly screams with white-hot light!</span>")
L.Knockdown(15, TRUE, FALSE, 15)
L.DefaultCombatKnockdown(15, TRUE, FALSE, 15)
L.apply_status_effect(STATUS_EFFECT_KINDLE)
L.flash_act(1, 1)
if(issilicon(target))
@@ -57,15 +57,15 @@
else if(!..())
if(!L.anti_magic_check())
if(issilicon(L))
L.Knockdown(100)
L.DefaultCombatKnockdown(100)
else if(iscultist(L))
L.confused += CLAMP(10 - L.confused, 0, 5) // Spearthrow now confuses enemy cultists + just deals extra damage / sets on fire instead of hardstunning + damage
to_chat(L, "<span class ='userdanger'>[src] crashes into you with burning force, sending you reeling!</span>")
L.adjust_fire_stacks(2)
L.Knockdown(1)
L.DefaultCombatKnockdown(1)
L.IgniteMob()
else
L.Knockdown(40)
L.DefaultCombatKnockdown(40)
GLOB.clockwork_vitality += L.adjustFireLoss(bonus_burn * 3) //normally a total of 40 damage, 70 with ratvar
break_spear(T)
else
@@ -176,7 +176,7 @@
var/datum/status_effect/belligerent/B = C.apply_status_effect(STATUS_EFFECT_BELLIGERENT)
if(!QDELETED(B))
B.duration = world.time + 30
C.Knockdown(5) //knocks down for half a second if affected
C.DefaultCombatKnockdown(5) //knocks down for half a second if affected
sleep(!GLOB.ratvar_approaches ? 16 : 10)
name = "judicial blast"
layer = ABOVE_ALL_MOB_LAYER
@@ -196,7 +196,7 @@
L.visible_message("<span class='warning'>Strange energy flows into [L]'s [I.name]!</span>", \
"<span class='userdanger'>Your [I.name] shields you from [src]!</span>")
continue
L.Knockdown(15) //knocks down briefly when exploding
L.DefaultCombatKnockdown(15) //knocks down briefly when exploding
if(!iscultist(L))
L.visible_message("<span class='warning'>[L] is struck by a judicial explosion!</span>", \
"<span class='userdanger'>[!issilicon(L) ? "An unseen force slams you into the ground!" : "ERROR: Motor servos disabled by external source!"]</span>")
@@ -57,5 +57,5 @@
L.confused = min(L.confused + 15, 50)
L.dizziness = min(L.dizziness + 15, 50)
if(L.confused >= 25)
L.Knockdown(FLOOR(L.confused * 0.8, 1))
L.DefaultCombatKnockdown(FLOOR(L.confused * 0.8, 1))
take_damage(max_integrity)
@@ -22,7 +22,7 @@
if(buckled_mobs && LAZYLEN(buckled_mobs))
var/mob/living/L = buckled_mobs[1]
if(iscarbon(L))
L.Knockdown(100)
L.DefaultCombatKnockdown(100)
L.visible_message("<span class='warning'>[L] is maimed as the skewer shatters while still in [L.p_their()] body!</span>")
L.adjustBruteLoss(15)
unbuckle_mob(L)
@@ -117,6 +117,6 @@
return
skewee.visible_message("<span class='danger'>[skewee] comes free of [src] with a squelching pop!</span>", \
"<span class='boldannounce'>You come free of [src]!</span>")
skewee.Knockdown(30)
skewee.DefaultCombatKnockdown(30)
playsound(skewee, 'sound/misc/desceration-03.ogg', 50, TRUE)
unbuckle_mob(skewee)
+1 -1
View File
@@ -446,7 +446,7 @@
var/atom/throw_target = get_edge_target_turf(L, user.dir)
L.throw_at(throw_target, 7, 1, user)
else if(!iscultist(L))
L.Knockdown(160)
L.DefaultCombatKnockdown(160)
L.adjustStaminaLoss(140) //Ensures hard stamcrit
L.flash_act(1,1)
if(issilicon(target))
+14 -13
View File
@@ -46,10 +46,11 @@
/obj/item/melee/cultblade/Initialize()
. = ..()
AddComponent(/datum/component/butchering, 40, 100)
AddElement(/datum/element/sword_point)
/obj/item/melee/cultblade/attack(mob/living/target, mob/living/carbon/human/user)
if(!iscultist(user))
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
user.dropItemToGround(src, TRUE)
user.visible_message("<span class='warning'>A powerful force shoves [user] away from [target]!</span>", \
"<span class='cultlarge'>\"You shouldn't play with sharp things. You'll poke someone's eye out.\"</span>")
@@ -148,7 +149,7 @@
user.emote("scream")
user.apply_damage(30, BRUTE, pick(BODY_ZONE_L_ARM, BODY_ZONE_R_ARM))
user.dropItemToGround(src, TRUE)
user.Knockdown(50)
user.DefaultCombatKnockdown(50)
return
force = initial(force)
jaunt.Grant(user, src)
@@ -405,7 +406,7 @@
to_chat(user, "<span class='warning'>An overwhelming sense of nausea overpowers you!</span>")
user.dropItemToGround(src, TRUE)
user.Dizzy(30)
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
else
to_chat(user, "<span class='cultlarge'>\"Trying to use things you don't own is bad, you know.\"</span>")
to_chat(user, "<span class='userdanger'>The armor squeezes at your body!</span>")
@@ -457,7 +458,7 @@
to_chat(user, "<span class='warning'>An overwhelming sense of nausea overpowers you!</span>")
user.dropItemToGround(src, TRUE)
user.Dizzy(30)
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
else
to_chat(user, "<span class='cultlarge'>\"Trying to use things you don't own is bad, you know.\"</span>")
to_chat(user, "<span class='userdanger'>The robes squeeze at your body!</span>")
@@ -478,7 +479,7 @@
to_chat(user, "<span class='cultlarge'>\"You want to be blind, do you?\"</span>")
user.dropItemToGround(src, TRUE)
user.Dizzy(30)
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
user.blind_eyes(30)
/obj/item/reagent_containers/glass/beaker/unholywater
@@ -499,7 +500,7 @@
/obj/item/shuttle_curse/attack_self(mob/living/user)
if(!iscultist(user))
user.dropItemToGround(src, TRUE)
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
to_chat(user, "<span class='warning'>A powerful force shoves you away from [src]!</span>")
return
if(curselimit > 1)
@@ -705,10 +706,10 @@
if(is_servant_of_ratvar(L))
to_chat(L, "<span class='cultlarge'>\"Kneel for me, scum\"</span>")
L.confused += CLAMP(10 - L.confused, 0, 5) //confuses and lightly knockdowns + damages hostile cultists instead of hardstunning like before
L.Knockdown(15)
L.DefaultCombatKnockdown(15)
L.adjustBruteLoss(10)
else
L.Knockdown(50)
L.DefaultCombatKnockdown(50)
break_spear(T)
else
..()
@@ -843,7 +844,7 @@
INVOKE_ASYNC(src, .proc/pewpew, user, params)
var/obj/structure/emergency_shield/invoker/N = new(user.loc)
if(do_after(user, 90, target = user))
user.Knockdown(40)
user.DefaultCombatKnockdown(40)
to_chat(user, "<span class='cult italic'>You have exhausted the power of this spell!</span>")
firing = FALSE
if(N)
@@ -908,7 +909,7 @@
else
var/mob/living/L = target
if(L.density)
L.Knockdown(20)
L.DefaultCombatKnockdown(20)
L.adjustBruteLoss(45)
playsound(L, 'sound/hallucinations/wail.ogg', 50, 1)
L.emote("scream")
@@ -944,7 +945,7 @@
T.visible_message("<span class='warning'>The sheer force from [P] shatters the mirror shield!</span>")
new /obj/effect/temp_visual/cult/sparks(T)
playsound(T, 'sound/effects/glassbr3.ogg', 100)
owner.Knockdown(25)
owner.DefaultCombatKnockdown(25)
qdel(src)
return FALSE
if(P.is_reflectable)
@@ -1001,9 +1002,9 @@
else if(!..())
if(!L.anti_magic_check())
if(is_servant_of_ratvar(L))
L.Knockdown(60)
L.DefaultCombatKnockdown(60)
else
L.Knockdown(30)
L.DefaultCombatKnockdown(30)
if(D.thrower)
for(var/mob/living/Next in orange(2, T))
if(!Next.density || iscultist(Next))
+3 -3
View File
@@ -219,7 +219,7 @@ structure_check() searches for nearby cultist structures required for the invoca
L.visible_message("<span class='warning'>[L]'s eyes glow a defiant yellow!</span>", \
"<span class='cultlarge'>\"Stop resisting. You <i>will</i> be mi-\"</span>\n\
<span class='large_brass'>\"Give up and you will feel pain unlike anything you've ever felt!\"</span>")
L.Knockdown(80)
L.DefaultCombatKnockdown(80)
else if(is_convertable)
do_convert(L, invokers)
else
@@ -908,7 +908,7 @@ structure_check() searches for nearby cultist structures required for the invoca
if(affecting.key)
affecting.visible_message("<span class='warning'>[affecting] slowly relaxes, the glow around [affecting.p_them()] dimming.</span>", \
"<span class='danger'>You are re-united with your physical form. [src] releases its hold over you.</span>")
affecting.Knockdown(40)
affecting.DefaultCombatKnockdown(40)
break
if(affecting.health <= 10)
to_chat(G, "<span class='cultitalic'>Your body can no longer sustain the connection!</span>")
@@ -970,7 +970,7 @@ structure_check() searches for nearby cultist structures required for the invoca
playsound(T, 'sound/magic/enter_blood.ogg', 100, 1)
visible_message("<span class='warning'>A colossal shockwave of energy bursts from the rune, disintegrating it in the process!</span>")
for(var/mob/living/L in range(src, 3))
L.Knockdown(30)
L.DefaultCombatKnockdown(30)
empulse(T, 0.42*(intensity), 1)
var/list/images = list()
var/zmatch = T.z
+1 -1
View File
@@ -477,7 +477,7 @@ GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master",
if(SOULVALUE >= ARCH_THRESHOLD && ascendable)
A.convert_to_archdevil()
else
throw EXCEPTION("Unable to find a blobstart landmark for hellish resurrection")
CRASH("Unable to find a blobstart landmark for hellish resurrection")
/datum/antagonist/devil/proc/update_hud()
@@ -32,7 +32,7 @@
if(BANE_HARVEST)
if(istype(weapon, /obj/item/reagent_containers/food/snacks/grown/))
visible_message("<span class='warning'>The spirits of the harvest aid in the exorcism.</span>", "<span class='notice'>The harvest spirits are harming you.</span>")
Knockdown(40)
DefaultCombatKnockdown(40)
qdel(weapon)
return 2
return 1
+4 -10
View File
@@ -70,16 +70,10 @@
O.explanation_text = "Protect \the [M.current.real_name], the [M.assigned_role], from harm."
objectives += O
if(4) //flavor
if(helping_station)
var/datum/objective/flavor/ninja_helping/O = new /datum/objective/flavor/ninja_helping
O.owner = owner
O.forge_objective()
objectives += O
else
var/datum/objective/flavor/ninja_syndie/O = new /datum/objective/flavor/ninja_helping
O.owner = owner
O.forge_objective()
objectives += O
var/datum/objective/flavor/O = helping_station ? new /datum/objective/flavor/ninja_helping : new /datum/objective/flavor/ninja_syndie
O.owner = owner
O.forge_objective()
objectives += O
else
break
var/datum/objective/O = new /datum/objective/survive()
+2 -2
View File
@@ -191,7 +191,7 @@
return 0
/obj/item/IntegrateAmount() //returns the amount of resources gained when eating this item
if(custom_materials[getmaterialref(/datum/material/iron)] || custom_materials[getmaterialref(/datum/material/glass)])
if(custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)] || custom_materials[SSmaterials.GetMaterialRef(/datum/material/glass)])
return 1
return ..()
@@ -586,7 +586,7 @@
playsound(loc,'sound/effects/snap.ogg',50, 1, -1)
L.electrocute_act(0, src, 1, 1, 1)
if(iscyborg(L))
L.Knockdown(100)
L.DefaultCombatKnockdown(100)
qdel(src)
..()
@@ -261,7 +261,7 @@
GiveHint(target)
else if(is_pointed(I))
to_chat(target, "<span class='userdanger'>You feel a stabbing pain in [parse_zone(user.zone_selected)]!</span>")
target.Knockdown(40)
target.DefaultCombatKnockdown(40)
GiveHint(target)
else if(istype(I, /obj/item/bikehorn))
to_chat(target, "<span class='userdanger'>HONK</span>")
@@ -377,7 +377,10 @@
/obj/item/warpwhistle/proc/end_effect(mob/living/carbon/user)
user.invisibility = initial(user.invisibility)
user.status_flags &= ~GODMODE
user.canmove = TRUE
REMOVE_TRAIT(user, TRAIT_MOBILITY_NOMOVE, src)
REMOVE_TRAIT(user, TRAIT_MOBILITY_NOUSE, src)
REMOVE_TRAIT(user, TRAIT_MOBILITY_NOPICKUP, src)
user.update_mobility()
/obj/item/warpwhistle/attack_self(mob/living/carbon/user)
if(!istype(user) || on_cooldown)
@@ -390,7 +393,10 @@
on_cooldown = TRUE
last_user = user
playsound(T,'sound/magic/warpwhistle.ogg', 200, 1)
user.canmove = FALSE
ADD_TRAIT(user, TRAIT_MOBILITY_NOMOVE, src)
ADD_TRAIT(user, TRAIT_MOBILITY_NOUSE, src)
ADD_TRAIT(user, TRAIT_MOBILITY_NOPICKUP, src)
user.update_mobility()
new /obj/effect/temp_visual/tornado(T)
sleep(20)
if(interrupted(user))
@@ -412,7 +418,6 @@
return
if(T.z != potential_T.z || abs(get_dist_euclidian(potential_T,T)) > 50 - breakout)
do_teleport(user, potential_T, channel = TELEPORT_CHANNEL_MAGIC)
user.canmove = 0
T = potential_T
break
breakout += 1
@@ -83,8 +83,8 @@
/obj/item/soulstone/proc/release_shades(mob/user)
for(var/mob/living/simple_animal/shade/A in src)
A.status_flags &= ~GODMODE
A.canmove = TRUE
A.forceMove(get_turf(user))
A.mobility_flags = MOBILITY_FLAGS_DEFAULT
A.cancel_camera()
icon_state = "soulstone"
name = initial(name)
@@ -173,7 +173,7 @@
else
T.forceMove(src) //put shade in stone
T.status_flags |= GODMODE
T.canmove = FALSE
T.mobility_flags = NONE
T.health = T.maxHealth
icon_state = "soulstone2"
name = "soulstone: Shade of [T.real_name]"
@@ -240,8 +240,8 @@
T.dust_animation()
QDEL_IN(T, 5)
var/mob/living/simple_animal/shade/S = new /mob/living/simple_animal/shade(src)
S.status_flags |= GODMODE //So they won't die inside the stone somehow
S.canmove = FALSE//Can't move out of the soul stone
S.status_flags |= GODMODE //So they won't die inside the stone somehow
S.mobility_flags = NONE //Can't move out of the soul stone
S.name = "Shade of [T.real_name]"
S.real_name = "Shade of [T.real_name]"
T.transfer_ckey(S)
+3 -4
View File
@@ -150,7 +150,7 @@
var/mob/living/silicon/robot/R = M
log_combat(user, R, "flashed", src)
update_icon(1)
R.Knockdown(rand(80,120))
R.DefaultCombatKnockdown(rand(80,120))
var/diff = 5 * CONFUSION_STACK_MAX_MULTIPLIER - M.confused
R.confused += min(5, diff)
R.flash_act(affect_silicon = 1)
@@ -197,14 +197,13 @@
else
to_chat(user, "<span class='warning'>This mind seems resistant to the flash!</span>")
/obj/item/assembly/flash/cyborg
/obj/item/assembly/flash/cyborg/attack(mob/living/M, mob/user)
. = ..()
new /obj/effect/temp_visual/borgflash(get_turf(src))
if(. && !CONFIG_GET(flag/disable_borg_flash_knockdown) && iscarbon(M) && !M.resting && !M.get_eye_protection())
M.Knockdown(80)
if(. && !CONFIG_GET(flag/disable_borg_flash_knockdown) && iscarbon(M) && CHECK_MOBILITY(M, MOBILITY_STAND) && !M.get_eye_protection())
M.DefaultCombatKnockdown(80)
/obj/item/assembly/flash/cyborg/attack_self(mob/user)
..()
+1 -1
View File
@@ -48,7 +48,7 @@
if("feet")
if(!H.shoes || !(H.shoes.body_parts_covered & FEET))
affecting = H.get_bodypart(pick(BODY_ZONE_L_LEG, BODY_ZONE_R_LEG))
H.Knockdown(60)
H.DefaultCombatKnockdown(60)
if(BODY_ZONE_PRECISE_L_HAND, BODY_ZONE_PRECISE_R_HAND)
if(!H.gloves)
affecting = H.get_bodypart(type)
@@ -314,10 +314,6 @@
user.forceMove(loc)
user.visible_message("<span class='notice'>You hear something squeezing through the ducts...</span>", "<span class='notice'>You climb out the ventilation system.")
user.canmove = FALSE
addtimer(VARSET_CALLBACK(user, canmove, TRUE), 1)
/obj/machinery/atmospherics/AltClick(mob/living/L)
if(is_type_in_typecache(src, GLOB.ventcrawl_machinery))
return L.handle_ventcrawl(src)
@@ -144,7 +144,7 @@
for(var/i in 1 to device_type)
var/datum/pipeline/parent = parents[i]
if(!parent)
throw EXCEPTION("Component is missing a pipenet! Rebuilding...")
stack_trace("Component is missing a pipenet! Rebuilding...")
build_network()
parent.update = 1
@@ -244,7 +244,7 @@
M.forceMove(get_turf(src))
if(isliving(M))
var/mob/living/L = M
L.update_canmove()
L.update_mobility()
occupant = null
update_icon()
@@ -277,10 +277,10 @@
else
. += "[src] seems empty."
/obj/machinery/atmospherics/components/unary/cryo_cell/MouseDrop_T(mob/target, mob/user)
if(user.stat || user.lying || !Adjacent(user) || !user.Adjacent(target) || !iscarbon(target) || !user.IsAdvancedToolUser())
/obj/machinery/atmospherics/components/unary/cryo_cell/MouseDrop_T(mob/living/carbon/target, mob/user)
if(user.stat || user.lying || !Adjacent(user) || !user.Adjacent(target) || !istype(target) || !user.IsAdvancedToolUser())
return
if (target.IsKnockdown() || target.IsStun() || target.IsSleeping() || target.IsUnconscious())
if(!CHECK_MOBILITY(target, MOBILITY_MOVE))
close_machine(target)
else
user.visible_message("<b>[user]</b> starts shoving [target] inside [src].", "<span class='notice'>You start shoving [target] inside [src].</span>")
+2 -2
View File
@@ -15,10 +15,10 @@
if(!isitem(O))
return 0
var/obj/item/I = O
if(!(getmaterialref(material_id) in I.custom_materials))
if(!(SSmaterials.GetMaterialRef(material_id) in I.custom_materials))
return 0
var/amount = I.custom_materials[getmaterialref(material_id)]
var/amount = I.custom_materials[SSmaterials.GetMaterialRef(material_id)]
if(istype(I, /obj/item/stack/ore))
amount *= 0.8 // Station's ore redemption equipment is really goddamn good.
+1 -1
View File
@@ -123,7 +123,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
"has_cock" = FALSE,
"cock_shape" = "Human",
"cock_length" = 6,
"cock_girth_ratio" = COCK_GIRTH_RATIO_DEF,
"cock_diameter_ratio" = COCK_DIAMETER_RATIO_DEF,
"cock_color" = "fff",
"has_sheath" = FALSE,
"sheath_color" = "fff",
+1 -1
View File
@@ -415,7 +415,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
S["feature_cock_shape"] >> features["cock_shape"]
S["feature_cock_color"] >> features["cock_color"]
S["feature_cock_length"] >> features["cock_length"]
S["feature_cock_girth"] >> features["cock_girth"]
S["feature_cock_diameter"] >> features["cock_diameter"]
S["feature_has_sheath"] >> features["sheath_color"]
//balls features
S["feature_has_balls"] >> features["has_balls"]
+1 -1
View File
@@ -224,7 +224,7 @@
/mob/living/carbon/canSuicide()
if(!..())
return
if(IsStun() || IsKnockdown()) //just while I finish up the new 'fun' suiciding verb. This is to prevent metagaming via suicide
if(!CHECK_MULTIPLE_BITFIELDS(mobility_flags, MOBILITY_MOVE|MOBILITY_USE)) //just while I finish up the new 'fun' suiciding verb. This is to prevent metagaming via suicide
to_chat(src, "You can't commit suicide while stunned! ((You can type Ghost instead however.))")
return
if(restrained())
+1 -1
View File
@@ -243,7 +243,7 @@
icon_state = "knight_greyscale"
item_state = "knight_greyscale"
armor = list("melee" = 35, "bullet" = 10, "laser" = 10, "energy" = 10, "bomb" = 10, "bio" = 10, "rad" = 10, "fire" = 40, "acid" = 40)
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR //Can change color and add prefix
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS //Can change color and add prefix
/obj/item/clothing/head/helmet/skull
name = "skull helmet"
@@ -221,7 +221,7 @@
if(user.wear_suit == src)
if(hard_landing)
user.electrocute_act(35, src, safety = 1)
user.Knockdown(200)
user.DefaultCombatKnockdown(200)
if(!silent)
to_chat(user, "\nroot@ChronosuitMK4# chronowalk4 --stop\n")
if(camera)
@@ -481,7 +481,7 @@
adjust_momentum(0, 0, 10)
wearer.visible_message("<span class='warning'>[wearer]'s flight suit crashes into the ground!</span>")
if(knockdown)
wearer.Knockdown(80)
wearer.DefaultCombatKnockdown(80)
momentum_x = 0
momentum_y = 0
calculate_momentum_speed()
@@ -455,6 +455,18 @@
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE|HIDEHAIR|HIDEFACIALHAIR
clothing_flags = STOPSPRESSUREDAMAGE | THICKMATERIAL | BLOCK_GAS_SMOKE_EFFECT | ALLOWINTERNALS | SCAN_REAGENTS
/obj/item/clothing/head/helmet/space/hardsuit/medical/equipped(mob/living/carbon/human/user, slot)
..()
if (slot == SLOT_HEAD)
var/datum/atom_hud/DHUD = GLOB.huds[DATA_HUD_MEDICAL_ADVANCED]
DHUD.add_hud_to(user)
/obj/item/clothing/head/helmet/space/hardsuit/medical/dropped(mob/living/carbon/human/user)
..()
if (user.head == src)
var/datum/atom_hud/DHUD = GLOB.huds[DATA_HUD_MEDICAL_ADVANCED]
DHUD.remove_hud_from(user)
/obj/item/clothing/suit/space/hardsuit/medical
icon_state = "hardsuit-medical"
name = "medical hardsuit"
+1 -1
View File
@@ -267,7 +267,7 @@
icon_state = "knight_greyscale"
item_state = "knight_greyscale"
armor = list("melee" = 35, "bullet" = 10, "laser" = 10, "energy" = 10, "bomb" = 10, "bio" = 10, "rad" = 10, "fire" = 40, "acid" = 40)
material_flags = MATERIAL_ADD_PREFIX //Can change color and add prefix
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS //Can change color and add prefix
/obj/item/clothing/suit/armor/vest/durathread
name = "makeshift vest"
@@ -252,7 +252,7 @@
return
owner.visible_message("<span class='danger'>The reactive teleport system flings [H] clear of [attack_text] and slams [H.p_them()] into a fabricated table!</span>")
owner.visible_message("<font color='red' size='3'>[H] GOES ON THE TABLE!!!</font>")
owner.Knockdown(40)
owner.DefaultCombatKnockdown(40)
var/list/turfs = new/list()
for(var/turf/T in orange(tele_range, H))
if(T.density)
+1 -1
View File
@@ -63,7 +63,7 @@
else
D = new virus_type()
else
D = new /datum/disease/advance/random(max_severity, max_severity)
D = new /datum/disease/advance/random(TRUE, max_severity, max_severity)
D.carrier = TRUE
H.ForceContractDisease(D, FALSE, TRUE)
+1 -1
View File
@@ -42,7 +42,7 @@
if(R.has_buckled_mobs())
for(var/mob/living/L in R.buckled_mobs)
L.visible_message("<span class='warning'>[L] is knocked off of [R] by the charge in [R]'s chassis induced by [name]!</span>") //I know it's bad.
L.Knockdown(10)
L.DefaultCombatKnockdown(10)
R.unbuckle_mob(L)
do_sparks(5, 0, L)
..()
+6 -6
View File
@@ -220,8 +220,8 @@ GLOBAL_LIST_INIT(hallucination_list, list(
/obj/effect/hallucination/simple/xeno/throw_impact(atom/hit_atom, datum/thrownthing/throwingdatum)
update_icon("alienh_pounce")
if(hit_atom == target && target.stat!=DEAD)
target.Knockdown(100)
if(hit_atom == target && target.stat != DEAD)
target.DefaultCombatKnockdown(100)
target.visible_message("<span class='danger'>[target] flails around wildly.</span>","<span class ='userdanger'>[name] pounces on you!</span>")
/datum/hallucination/xeno_attack
@@ -308,7 +308,7 @@ GLOBAL_LIST_INIT(hallucination_list, list(
shake_camera(target, 2, 1)
if(bubblegum.Adjacent(target) && !charged)
charged = TRUE
target.Knockdown(80)
target.DefaultCombatKnockdown(80)
target.adjustStaminaLoss(40)
step_away(target, bubblegum)
shake_camera(target, 4, 3)
@@ -1106,7 +1106,7 @@ GLOBAL_LIST_INIT(hallucination_list, list(
if(istype(target, /obj/effect/dummy/phased_mob))
return
to_chat(target, "<span class='userdanger'>You fall into the chasm!</span>")
target.Knockdown(40)
target.DefaultCombatKnockdown(40)
addtimer(CALLBACK(GLOBAL_PROC, .proc/to_chat, target, "<span class='notice'>It's surprisingly shallow.</span>"), 15)
QDEL_IN(src, 30)
@@ -1245,7 +1245,7 @@ GLOBAL_LIST_INIT(hallucination_list, list(
/datum/hallucination/shock/proc/shock_drop()
target.jitteriness = max(target.jitteriness - 990, 10) //Still jittery, but vastly less
target.Knockdown(60)
target.DefaultCombatKnockdown(60)
/datum/hallucination/husks
@@ -1318,7 +1318,7 @@ GLOBAL_LIST_INIT(hallucination_list, list(
"<span class='userdanger'>[G] grabs your wrist and violently wrenches it to the side!</span>")
C.emote("scream")
C.dropItemToGround(C.get_active_held_item())
C.Knockdown(60)
C.DefaultCombatKnockdown(60)
else
to_chat(C,"<span class='userdanger'>[G] violently grabs you!</span>")
qdel(src)
@@ -51,7 +51,7 @@
head_attack_message = " on the head"
//Knockdown the target for the duration that we calculated and divide it by 5.
if(armor_duration)
target.Knockdown(min(armor_duration, 200)) // Never knockdown more than a flash!
target.DefaultCombatKnockdown(min(armor_duration, 200)) // Never knockdown more than a flash!
//Display an attack message.
if(target != user)
@@ -225,7 +225,7 @@
if(iscarbon(M))
M.visible_message("[src] bursts out of [M]!</span>")
M.emote("scream")
M.Knockdown(40)
M.DefaultCombatKnockdown(40)
M.adjustBruteLoss(60)
Expand()
return ..()
@@ -49,7 +49,7 @@
else
creamoverlay.icon_state = "creampie_human"
if(stunning)
H.Knockdown(20) //splat!
H.DefaultCombatKnockdown(20) //splat!
H.adjust_blurriness(1)
H.visible_message("<span class='warning'>[H] is creamed by [src]!</span>", "<span class='userdanger'>You've been creamed by [src]!</span>")
playsound(H, "desceration", 50, TRUE)
@@ -83,7 +83,7 @@
A.throw_at(T, 1, 1)
M.visible_message("[src] bursts out of [M]!</span>")
M.emote("scream")
M.Knockdown(40)
M.DefaultCombatKnockdown(40)
M.adjustBruteLoss(60)
return ..()
@@ -152,6 +152,6 @@ God bless America.
reagents.reaction(C, TOUCH)
C.apply_damage(min(30, reagents.total_volume), BURN, BODY_ZONE_HEAD)
reagents.remove_any((reagents.total_volume/2))
C.Knockdown(60)
C.DefaultCombatKnockdown(60)
user.changeNext_move(CLICK_CD_MELEE)
return ..()
@@ -310,7 +310,7 @@
for(var/obj/item/O in ingredients)
O.microwave_act(src)
if(O.custom_materials?.len)
metal += O.custom_materials[getmaterialref(/datum/material/iron)]
metal += O.custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)]
if(metal)
spark()
@@ -132,7 +132,8 @@
set name = "Eject Contents"
set src in oview(1)
if(usr.stat || !usr.canmove || usr.restrained())
var/mob/living/L = usr
if(!istype(L) || !CHECK_MOBILITY(L, MOBILITY_USE))
return
empty()
add_fingerprint(usr)
+13 -5
View File
@@ -46,6 +46,8 @@
var/progression = list() //Keep track of where people are in the story.
var/active = TRUE //Turn this to false to keep normal mob behavour
var/cached_z
/// I'm busy chatting, don't move.
var/busy_chatting = FALSE
/mob/living/simple_animal/jacq/Initialize()
..()
@@ -76,9 +78,9 @@
say("Hello there [gender_check(M)]!")
return ..()
if(!ckey)
canmove = FALSE
busy_chatting = FALSE
chit_chat(M)
canmove = TRUE
busy_chatting = TRUE
..()
/mob/living/simple_animal/jacq/attack_paw(mob/living/carbon/monkey/M)
@@ -86,9 +88,9 @@
say("Hello there [gender_check(M)]!")
return ..()
if(!ckey)
canmove = FALSE
busy_chatting = FALSE
chit_chat(M)
canmove = TRUE
busy_chatting = TRUE
..()
/mob/living/simple_animal/jacq/proc/poof()
@@ -99,7 +101,7 @@
s.set_up(R, 0, loc)
s.start()
visible_message("<b>[src]</b> disappears in a puff of smoke!")
canmove = TRUE
busy_chatting = TRUE
health = 25
//Try to go to populated areas
@@ -377,6 +379,12 @@
sleep(20)
poof()
/mob/living/simple_animal/jacq/update_mobility()
. = ..()
if(busy_chatting)
DISABLE_BITFIELD(., MOBILITY_MOVE)
mobility_flags = .
/obj/item/clothing/head/hardhat/pumpkinhead/jaqc
name = "Jacq o' latern"
desc = "A jacqueline o' lantern! You can't seem to get rid of it."
+5 -1
View File
@@ -4,6 +4,10 @@ GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
"power_supply", "contents", "reagents", "stat", "x", "y", "z", "group", "atmos_adjacent_turfs", "comp_lookup"
))
GLOBAL_LIST_INIT(duplicate_forbidden_vars_by_type, typecacheof_assoc_list(list(
/obj/item/gun/energy = "ammo_type"
)))
/proc/DuplicateObject(atom/original, perfectcopy = TRUE, sameloc = FALSE, atom/newloc = null, nerf = FALSE, holoitem=FALSE)
RETURN_TYPE(original.type)
if(!original)
@@ -16,7 +20,7 @@ GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
O = new original.type(newloc)
if(perfectcopy && O && original)
for(var/V in original.vars - GLOB.duplicate_forbidden_vars)
for(var/V in original.vars - GLOB.duplicate_forbidden_vars - GLOB.duplicate_forbidden_vars_by_type[O.type])
if(islist(original.vars[V]))
var/list/L = original.vars[V]
O.vars[V] = L.Copy()
+2 -2
View File
@@ -87,7 +87,7 @@
playsound(src, 'sound/items/dodgeball.ogg', 50, 1)
M.apply_damage(10, STAMINA)
if(prob(5))
M.Knockdown(60)
M.DefaultCombatKnockdown(60)
visible_message("<span class='danger'>[M] is knocked right off [M.p_their()] feet!</span>")
//
@@ -117,7 +117,7 @@
to_chat(user, "<span class='warning'>You need a better grip to do that!</span>")
return
L.forceMove(loc)
L.Knockdown(100)
L.DefaultCombatKnockdown(100)
visible_message("<span class='danger'>[user] dunks [L] into \the [src]!</span>")
user.stop_pulling()
else
+4 -4
View File
@@ -196,7 +196,7 @@
dat += "<A href='?src=[REF(src)];create=[D.id];amount=5'>x5</A>"
if(ispath(D.build_path, /obj/item/stack))
dat += "<A href='?src=[REF(src)];create=[D.id];amount=10'>x10</A>"
dat += "([D.materials[getmaterialref(/datum/material/biomass)]/efficiency])<br>"
dat += "([D.materials[SSmaterials.GetMaterialRef(/datum/material/biomass)]/efficiency])<br>"
dat += "</div>"
else
dat += "<div class='statusDisplay'>No container inside, please insert container.</div>"
@@ -233,14 +233,14 @@
menustat = "void"
/obj/machinery/biogenerator/proc/check_cost(list/materials, multiplier = 1, remove_points = TRUE)
if(materials.len != 1 || materials[1] != getmaterialref(/datum/material/biomass))
if(materials.len != 1 || materials[1] != SSmaterials.GetMaterialRef(/datum/material/biomass))
return FALSE
if (materials[getmaterialref(/datum/material/biomass)]*multiplier/efficiency > points)
if (materials[SSmaterials.GetMaterialRef(/datum/material/biomass)]*multiplier/efficiency > points)
menustat = "nopoints"
return FALSE
else
if(remove_points)
points -= materials[getmaterialref(/datum/material/biomass)]*multiplier/efficiency
points -= materials[SSmaterials.GetMaterialRef(/datum/material/biomass)]*multiplier/efficiency
update_icon()
updateUsrDialog()
return TRUE
+2 -2
View File
@@ -98,7 +98,7 @@
/obj/item/reagent_containers/food/snacks/grown/nettle/death/pickup(mob/living/carbon/user)
if(..())
if(prob(50))
user.Knockdown(100)
user.DefaultCombatKnockdown(100)
to_chat(user, "<span class='userdanger'>You are stunned by the Deathnettle as you try picking it up!</span>")
/obj/item/reagent_containers/food/snacks/grown/nettle/death/attack(mob/living/carbon/M, mob/user)
@@ -111,5 +111,5 @@
M.adjust_blurriness(force/7)
if(prob(20))
M.Unconscious(force / 0.3)
M.Knockdown(force / 0.75)
M.DefaultCombatKnockdown(force / 0.75)
M.drop_all_held_items()
@@ -190,10 +190,10 @@
var/cost = 400
if(ispath(build_type, /obj/item/electronic_assembly))
var/obj/item/electronic_assembly/E = SScircuit.cached_assemblies[build_type]
cost = E.custom_materials[getmaterialref(/datum/material/iron)]
cost = E.custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)]
else if(ispath(build_type, /obj/item/integrated_circuit))
var/obj/item/integrated_circuit/IC = SScircuit.cached_components[build_type]
cost = IC.custom_materials[getmaterialref(/datum/material/iron)]
cost = IC.custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)]
else if(!(build_type in SScircuit.circuit_fabricator_recipe_list["Tools"]))
return
@@ -260,7 +260,7 @@
blocks["max_space"] = assembly.max_components
// Start keeping track of total metal cost
blocks["metal_cost"] = assembly.custom_materials[getmaterialref(/datum/material/iron)]
blocks["metal_cost"] = assembly.custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)]
// Block 2. Components.
@@ -291,7 +291,7 @@
// Update estimated assembly complexity, taken space and material cost
blocks["complexity"] += component.complexity
blocks["used_space"] += component.size
blocks["metal_cost"] += component.custom_materials[getmaterialref(/datum/material/iron)]
blocks["metal_cost"] += component.custom_materials[SSmaterials.GetMaterialRef(/datum/material/iron)]
// Check if the assembly requires printer upgrades
if(!(component.spawn_flags & IC_SPAWN_DEFAULT))
@@ -414,7 +414,7 @@
var/datum/component/material_container/materials = GetComponent(/datum/component/material_container)
set_pin_data(IC_OUTPUT, 2, materials.total_amount)
for(var/I in 1 to mtypes.len)
var/datum/material/M = materials.materials[getmaterialref(I)]
var/datum/material/M = materials.materials[SSmaterials.GetMaterialRef(I)]
var/amount = materials[M]
if(M)
set_pin_data(IC_OUTPUT, I+2, amount)
@@ -452,7 +452,7 @@
continue
if(!mt) //Invalid input
if(U>0)
if(materials.retrieve_sheets(U, getmaterialref(mtypes[I]), T))
if(materials.retrieve_sheets(U, SSmaterials.GetMaterialRef(mtypes[I]), T))
suc = TRUE
else
if(mt.transer_amt_to(materials, U, mtypes[I]))
@@ -336,7 +336,7 @@
if(!L || !isliving(L))
return 0
L.Knockdown(stunforce)
L.DefaultCombatKnockdown(stunforce)
SEND_SIGNAL(L, COMSIG_LIVING_MINOR_SHOCK)
message_admins("stunned someone with an assembly. Last touches: Assembly: [assembly.fingerprintslast] Circuit: [fingerprintslast]")
+3 -3
View File
@@ -112,14 +112,14 @@
else
return ..()
/obj/structure/bookcase/attack_hand(mob/user)
/obj/structure/bookcase/attack_hand(mob/living/user)
. = ..()
if(.)
if(. || !istype(user))
return
if(contents.len)
var/obj/item/book/choice = input("Which book would you like to remove from the shelf?") as null|obj in contents
if(choice)
if(!usr.canmove || usr.stat || usr.restrained() || !in_range(loc, usr))
if(!CHECK_MOBILITY(user, MOBILITY_USE) || !in_range(loc, user))
return
if(ishuman(user))
if(!user.get_active_held_item())
@@ -23,7 +23,7 @@
return
template = SSmapping.shelter_templates[template_id]
if(!template)
throw EXCEPTION("Shelter template ([template_id]) not found!")
stack_trace("Shelter template ([template_id]) not found!")
qdel(src)
/obj/item/survivalcapsule/Destroy()
@@ -93,7 +93,7 @@
playsound(M,'sound/weapons/resonator_blast.ogg',50,1)
if(iscarbon(M))
var/mob/living/carbon/L = M
L.Knockdown(60)
L.DefaultCombatKnockdown(60)
if(ishuman(L))
shake_camera(L, 20, 1)
addtimer(CALLBACK(L, /mob/living/carbon.proc/vomit), 20)
+1 -1
View File
@@ -74,7 +74,7 @@ GLOBAL_LIST_EMPTY(total_extraction_beacons)
var/mutable_appearance/balloon3
if(isliving(A))
var/mob/living/M = A
M.Knockdown(320) // Keep them from moving during the duration of the extraction
M.DefaultCombatKnockdown(320) // Keep them from moving during the duration of the extraction
M.buckled = 0 // Unbuckle them to prevent anchoring problems
else
A.anchored = TRUE
+1 -1
View File
@@ -86,7 +86,7 @@
proximity_monitor = new(src, 1)
AddComponent(/datum/component/material_container, list(/datum/material/iron, /datum/material/glass, /datum/material/silver, /datum/material/gold, /datum/material/diamond, /datum/material/plasma, /datum/material/uranium, /datum/material/bananium, /datum/material/titanium, /datum/material/bluespace), INFINITY, TRUE, /obj/item/stack)
stored_research = new /datum/techweb/specialized/autounlocking/smelter
selected_material = getmaterialref(/datum/material/iron)
selected_material = SSmaterials.GetMaterialRef(/datum/material/iron)
/obj/machinery/mineral/processing_unit/Destroy()
CONSOLE = null
+1 -1
View File
@@ -29,7 +29,7 @@
/datum/material/plastic,
/datum/material/runite
), MINERAL_MATERIAL_AMOUNT * 50, FALSE, /obj/item/stack)
chosen = getmaterialref(chosen)
chosen = SSmaterials.GetMaterialRef(chosen)
/obj/machinery/mineral/mint/process()
var/turf/T = get_step(src, input_dir)
+1 -1
View File
@@ -320,7 +320,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
throwforce = 2
w_class = WEIGHT_CLASS_TINY
custom_materials = list(/datum/material/iron = 400)
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS
var/string_attached
var/list/sideslist = list("heads","tails")
var/cooldown = 0
@@ -10,7 +10,6 @@
density = FALSE
stat = DEAD
canmove = FALSE
var/mob/living/new_character //for instant transfer once the round is set up
+1 -1
View File
@@ -11,7 +11,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
layer = GHOST_LAYER
stat = DEAD
density = FALSE
canmove = 0
move_resist = INFINITY
see_invisible = SEE_INVISIBLE_OBSERVER
see_in_dark = 100
invisibility = INVISIBILITY_OBSERVER
+2 -6
View File
@@ -39,12 +39,8 @@
container = null
return ..()
/mob/living/brain/update_canmove()
if(in_contents_of(/obj/mecha))
canmove = 1
else
canmove = 0
return canmove
/mob/living/brain/update_mobility()
return ((mobility_flags = (in_contents_of(/obj/mecha)? MOBILITY_FLAGS_DEFAULT : NONE)))
/mob/living/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
return
@@ -22,11 +22,11 @@ In all, this is a lot like the monkey code. /N
switch(M.a_intent)
if (INTENT_HELP)
if(!recoveringstam)
resting = 0
AdjustStun(-60)
AdjustKnockdown(-60)
AdjustUnconscious(-60)
AdjustSleeping(-100)
set_resting(FALSE, TRUE, FALSE)
AdjustAllImmobility(-60, FALSE)
AdjustUnconscious(-60, FALSE)
AdjustSleeping(-100, FALSE)
update_mobility()
visible_message("<span class='notice'>[M.name] nuzzles [src] trying to wake [p_them()] up!</span>")
if(INTENT_DISARM, INTENT_HARM)
if(health > 0)
@@ -5,11 +5,9 @@
/mob/living/carbon/alien/adjustToxLoss(amount, updating_health = TRUE, forced = FALSE) //alien immune to tox damage
return FALSE
/* CIT CHANGE - Pffffffffffffhahahahahhaha-- No.
//aliens are immune to stamina damage.
/mob/living/carbon/alien/adjustStaminaLoss(amount, updating_health = 1)
/mob/living/carbon/alien/adjustStaminaLoss(amount, updating_health = TRUE, forced = FALSE)
return
/mob/living/carbon/alien/setStaminaLoss(amount, updating_health = 1)
/mob/living/carbon/alien/setStaminaLoss(amount, updating_health = TRUE, forced = FALSE)
return
*/
@@ -31,7 +31,7 @@
#define MAX_ALIEN_LEAP_DIST 7
/mob/living/carbon/alien/humanoid/hunter/proc/leap_at(atom/A)
if(!canmove || leaping)
if(!CHECK_MULTIPLE_BITFIELDS(mobility_flags, MOBILITY_STAND | MOBILITY_MOVE) || leaping)
return
if(pounce_cooldown > world.time)
@@ -65,21 +65,21 @@
var/mob/living/L = hit_atom
if(!L.check_shields(src, 0, "the [name]", attack_type = LEAP_ATTACK))
L.visible_message("<span class ='danger'>[src] pounces on [L]!</span>", "<span class ='userdanger'>[src] pounces on you!</span>")
L.Knockdown(100)
L.DefaultCombatKnockdown(100)
sleep(2)//Runtime prevention (infinite bump() calls on hulks)
step_towards(src,L)
else
Knockdown(40, 1, 1)
DefaultCombatKnockdown(40, 1, 1)
toggle_leap(0)
else if(hit_atom.density && !hit_atom.CanPass(src))
visible_message("<span class ='danger'>[src] smashes into [hit_atom]!</span>", "<span class ='alertalien'>[src] smashes into [hit_atom]!</span>")
Knockdown(40, 1, 1)
Paralyze(40, TRUE, TRUE)
if(leaping)
leaping = 0
update_icons()
update_canmove()
update_mobility()
/mob/living/carbon/alien/humanoid/float(on)
@@ -4,7 +4,7 @@
. = ..()
update_canmove()
update_mobility()
update_icons()
status_flags |= CANPUSH
@@ -69,11 +69,11 @@
playsound(src, 'sound/voice/hiss5.ogg', 40, 1, 1) //Alien roars when starting to break free
..(I, cuff_break = INSTANT_CUFFBREAK)
/mob/living/carbon/alien/humanoid/resist_grab(moving_resist)
if(pulledby.grab_state)
/mob/living/carbon/alien/humanoid/do_resist_grab(moving_resist, forced, silent = FALSE)
if(pulledby.grab_state && !silent)
visible_message("<span class='danger'>[src] has broken free of [pulledby]'s grip!</span>")
pulledby.stop_pulling()
. = 0
return TRUE
/mob/living/carbon/alien/humanoid/get_standard_pixel_y_offset(lying = 0)
if(leaping)
@@ -12,12 +12,12 @@
else
icon_state = "alien[caste]_dead"
else if((stat == UNCONSCIOUS && !asleep) || stat == SOFT_CRIT || IsKnockdown())
else if((stat == UNCONSCIOUS && !asleep) || stat == SOFT_CRIT || IsParalyzed())
icon_state = "alien[caste]_unconscious"
else if(leap_on_click)
icon_state = "alien[caste]_pounce"
else if(lying || resting || asleep)
else if(lying || !CHECK_MOBILITY(src, MOBILITY_STAND) || asleep)
icon_state = "alien[caste]_sleep"
else if(mob_size == MOB_SIZE_LARGE)
icon_state = "alien[caste]"
@@ -22,13 +22,13 @@
if(stat == CONSCIOUS)
stat = UNCONSCIOUS
blind_eyes(1)
update_canmove()
update_mobility()
else
if(stat == UNCONSCIOUS)
stat = CONSCIOUS
if(!recoveringstam)
resting = 0
set_resting(FALSE, TRUE)
adjust_blindness(-1)
update_canmove()
update_mobility()
update_damage_hud()
update_health_hud()
@@ -14,9 +14,9 @@
icon_state = "larva[state]_dead"
else if(handcuffed || legcuffed) //This should be an overlay. Who made this an icon_state?
icon_state = "larva[state]_cuff"
else if(stat == UNCONSCIOUS || lying || resting)
else if(stat == UNCONSCIOUS || !CHECK_MOBILITY(src, MOBILITY_STAND))
icon_state = "larva[state]_sleep"
else if(IsStun())
else if(IsStun() || IsParalyzed())
icon_state = "larva[state]_stun"
else
icon_state = "larva[state]"
@@ -140,7 +140,7 @@
else if(ishuman(owner)) //Humans, being more fragile, are more overwhelmed by the mental backlash.
to_chat(owner, "<span class='danger'>You feel a splitting pain in your head, and are struck with a wave of nausea. You cannot hear the hivemind anymore!</span>")
owner.emote("scream")
owner.Knockdown(100)
owner.DefaultCombatKnockdown(100)
owner.jitteriness += 30
owner.confused += 30
@@ -89,8 +89,8 @@
var/mob/living/carbon/alien/larva/new_xeno = new(xeno_loc)
ghost.transfer_ckey(new_xeno, FALSE)
SEND_SOUND(new_xeno, sound('sound/voice/hiss5.ogg',0,0,0,100)) //To get the player's attention
new_xeno.canmove = 0 //so we don't move during the bursting animation
new_xeno.notransform = 1
new_xeno.Paralyze(6)
new_xeno.notransform = TRUE
new_xeno.invisibility = INVISIBILITY_MAXIMUM
sleep(6)
@@ -99,8 +99,8 @@
return
if(new_xeno)
new_xeno.canmove = 1
new_xeno.notransform = 0
new_xeno.SetParalyzed(0)
new_xeno.notransform = FALSE
new_xeno.invisibility = 0
var/mob/living/carbon/old_owner = owner
+26 -18
View File
@@ -103,7 +103,7 @@
hurt = FALSE
if(hit_atom.density && isturf(hit_atom))
if(hurt)
Knockdown(20)
DefaultCombatKnockdown(20)
take_bodypart_damage(10)
if(iscarbon(hit_atom) && hit_atom != src)
var/mob/living/carbon/victim = hit_atom
@@ -112,8 +112,8 @@
if(hurt)
victim.take_bodypart_damage(10)
take_bodypart_damage(10)
victim.Knockdown(20)
Knockdown(20)
victim.DefaultCombatKnockdown(20)
DefaultCombatKnockdown(20)
visible_message("<span class='danger'>[src] crashes into [victim], knocking them both over!</span>",\
"<span class='userdanger'>You violently crash into [victim]!</span>")
playsound(src,'sound/weapons/punch1.ogg',50,1)
@@ -281,19 +281,23 @@
return FALSE
/mob/living/carbon/resist_buckle()
. = FALSE
if(restrained())
changeNext_move(CLICK_CD_BREAKOUT)
last_special = world.time + CLICK_CD_BREAKOUT
// too soon.
if(last_special > world.time)
return
var/buckle_cd = 600
if(handcuffed)
var/obj/item/restraints/O = src.get_item_by_slot(SLOT_HANDCUFFED)
buckle_cd = O.breakouttime
changeNext_move(min(CLICK_CD_BREAKOUT, buckle_cd))
last_special = world.time + min(CLICK_CD_BREAKOUT, buckle_cd)
visible_message("<span class='warning'>[src] attempts to unbuckle [p_them()]self!</span>", \
"<span class='notice'>You attempt to unbuckle yourself... (This will take around [round(buckle_cd/600,1)] minute\s, and you need to stay still.)</span>")
if(do_after(src, buckle_cd, 0, target = src))
if(do_after(src, buckle_cd, 0, target = src, required_mobility_flags = MOBILITY_RESIST))
if(!buckled)
return
buckled.user_unbuckle_mob(src,src)
buckled.user_unbuckle_mob(src, src)
else
if(src && buckled)
to_chat(src, "<span class='warning'>You fail to unbuckle yourself!</span>")
@@ -301,21 +305,26 @@
buckled.user_unbuckle_mob(src,src)
/mob/living/carbon/resist_fire()
if(last_special > world.time)
return
fire_stacks -= 5
Knockdown(60, TRUE, TRUE)
DefaultCombatKnockdown(60, TRUE, TRUE)
spin(32,2)
visible_message("<span class='danger'>[src] rolls on the floor, trying to put [p_them()]self out!</span>", \
"<span class='notice'>You stop, drop, and roll!</span>")
last_special = world.time + 30
sleep(30)
if(fire_stacks <= 0)
visible_message("<span class='danger'>[src] has successfully extinguished [p_them()]self!</span>", \
"<span class='notice'>You extinguish yourself.</span>")
ExtinguishMob()
return
/mob/living/carbon/resist_restraints()
/mob/living/carbon/resist_restraints(ignore_delay = FALSE)
var/obj/item/I = null
var/type = 0
if(!ignore_delay && (last_special > world.time))
to_chat(src, "<span class='warning'>You don't have the energy to resist your restraints that fast!</span>")
return
if(handcuffed)
I = handcuffed
type = 1
@@ -324,14 +333,13 @@
type = 2
if(I)
if(type == 1)
changeNext_move(CLICK_CD_BREAKOUT)
changeNext_move(min(CLICK_CD_BREAKOUT, I.breakouttime))
last_special = world.time + CLICK_CD_BREAKOUT
if(type == 2)
changeNext_move(CLICK_CD_RANGE)
changeNext_move(min(CLICK_CD_RANGE, I.breakouttime))
last_special = world.time + CLICK_CD_RANGE
cuff_resist(I)
/mob/living/carbon/proc/cuff_resist(obj/item/I, breakouttime = 600, cuff_break = 0)
if(I.item_flags & BEING_REMOVED)
to_chat(src, "<span class='warning'>You're already attempting to remove [I]!</span>")
@@ -341,7 +349,7 @@
if(!cuff_break)
visible_message("<span class='warning'>[src] attempts to remove [I]!</span>")
to_chat(src, "<span class='notice'>You attempt to remove [I]... (This will take around [DisplayTimeText(breakouttime)] and you need to stand still.)</span>")
if(do_after(src, breakouttime, 0, target = src))
if(do_after(src, breakouttime, 0, target = src, required_mobility_flags = MOBILITY_RESIST))
clear_cuffs(I, cuff_break)
else
to_chat(src, "<span class='warning'>You fail to remove [I]!</span>")
@@ -488,7 +496,7 @@
visible_message("<span class='warning'>[src] dry heaves!</span>", \
"<span class='userdanger'>You try to throw up, but there's nothing in your stomach!</span>")
if(stun)
Knockdown(200)
DefaultCombatKnockdown(200)
return 1
if(is_mouth_covered()) //make this add a blood/vomit overlay later it'll be hilarious
@@ -572,9 +580,9 @@
if(stam > DAMAGE_PRECISION)
var/total_health = (health - stam)
if(total_health <= crit_threshold && !stat)
if(!IsKnockdown())
if(CHECK_MOBILITY(src, MOBILITY_STAND))
to_chat(src, "<span class='notice'>You're too exhausted to keep going...</span>")
Knockdown(100)
KnockToFloor(TRUE)
update_health_hud()
/mob/living/carbon/update_sight()
@@ -814,7 +822,7 @@
else
stat = CONSCIOUS
adjust_blindness(-1)
update_canmove()
update_mobility()
update_damage_hud()
update_health_hud()
med_hud_set_status()
@@ -52,7 +52,12 @@
. = ..()
if(!HAS_TRAIT(src, TRAIT_AUTO_CATCH_ITEM) && !skip_throw_mode_check && !in_throw_mode)
return
if(get_active_held_item() || restrained())
if(incapacitated())
return
if (get_active_held_item())
if (HAS_TRAIT_FROM(src, TRAIT_AUTO_CATCH_ITEM,RISING_BASS_TRAIT))
visible_message("<span class='warning'>[src] chops [I] out of the air!</span>")
return TRUE
return
I.attack_hand(src)
if(get_active_held_item() == I) //if our attack_hand() picks up the item...
@@ -77,7 +82,7 @@
var/mob/living/carbon/tempcarb = user
if(!tempcarb.combatmode)
totitemdamage *= 0.5
if(user.resting)
if(!CHECK_MOBILITY(user, MOBILITY_STAND))
totitemdamage *= 0.5
if(!combatmode)
totitemdamage *= 1.5
@@ -188,7 +193,7 @@
do_sparks(5, TRUE, src)
var/power = M.powerlevel + rand(0,3)
Knockdown(power*20)
DefaultCombatKnockdown(power*20)
if(stuttering < power)
stuttering = power
if (prob(stunprob) && M.powerlevel >= 8)
@@ -262,7 +267,7 @@
spawn(20)
jitteriness = max(jitteriness - 990, 10) //Still jittery, but vastly less
if((!tesla_shock || (tesla_shock && siemens_coeff > 0.5)) && stun)
Knockdown(60)
DefaultCombatKnockdown(60)
if(override)
return override
else
@@ -282,13 +287,13 @@
M.visible_message("<span class='notice'>[M] shakes [src] trying to get [p_them()] up!</span>", \
"<span class='notice'>You shake [src] trying to get [p_them()] up!</span>")
else if(check_zone(M.zone_selected) == "mouth") // I ADDED BOOP-EH-DEH-NOSEH - Jon
else if(M.zone_selected == BODY_ZONE_PRECISE_MOUTH) // I ADDED BOOP-EH-DEH-NOSEH - Jon
M.visible_message( \
"<span class='notice'>[M] boops [src]'s nose.</span>", \
"<span class='notice'>You boop [src] on the nose.</span>", )
playsound(src, 'sound/items/Nose_boop.ogg', 50, 0)
else if(check_zone(M.zone_selected) == "head")
else if(check_zone(M.zone_selected) == BODY_ZONE_HEAD)
var/datum/species/S
if(ishuman(src))
S = dna.species
@@ -322,7 +327,7 @@
else
return
else if(check_zone(M.zone_selected) == "r_arm" || check_zone(M.zone_selected) == "l_arm")
else if(check_zone(M.zone_selected) == BODY_ZONE_R_ARM || check_zone(M.zone_selected) == BODY_ZONE_L_ARM)
M.visible_message( \
"<span class='notice'>[M] shakes [src]'s hand.</span>", \
"<span class='notice'>You shake [src]'s hand.</span>", )
@@ -341,16 +346,14 @@
else if (mood.sanity >= SANITY_DISTURBED)
SEND_SIGNAL(src, COMSIG_ADD_MOOD_EVENT, "friendly_hug", /datum/mood_event/betterhug, M)
AdjustStun(-60)
AdjustKnockdown(-60)
AdjustUnconscious(-60)
AdjustSleeping(-100)
AdjustAllImmobility(-60, FALSE)
AdjustUnconscious(-60, FALSE)
AdjustSleeping(-100, FALSE)
if(recoveringstam)
adjustStaminaLoss(-15)
else if(resting)
resting = 0
update_canmove()
else
set_resting(FALSE, FALSE)
update_mobility()
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
@@ -414,7 +417,7 @@
var/effect_amount = intensity - ear_safety
if(effect_amount > 0)
if(stun_pwr)
Knockdown(stun_pwr*effect_amount)
DefaultCombatKnockdown(stun_pwr*effect_amount)
if(istype(ears) && (deafen_pwr || damage_pwr))
var/ear_damage = damage_pwr * effect_amount
@@ -9,8 +9,6 @@
. += 6 - 3*get_num_arms() //crawling is harder with fewer arms
if(legcuffed)
. += legcuffed.slowdown
if(stat == SOFT_CRIT)
. += SOFTCRIT_ADD_SLOWDOWN
/mob/living/carbon/slip(knockdown_amount, obj/O, lube)
if(movement_type & FLYING && !(lube & FLYING_DOESNT_HELP))
@@ -43,3 +41,10 @@
nutrition -= HUNGER_FACTOR/10
if(m_intent == MOVE_INTENT_RUN)
nutrition -= HUNGER_FACTOR/10
/mob/living/carbon/can_move_under_living(mob/living/other)
. = ..()
if(!.) //we failed earlier don't need to fail again
return
if(!other.lying && lying) //they're up, we're down.
return FALSE
+1 -1
View File
@@ -91,7 +91,7 @@
. += "[t_He] [t_is] moving [t_his] body in an unnatural and blatantly unsimian manner."
if(combatmode)
. += "[t_He] [t_is] visibly tense[resting ? "." : ", and [t_is] standing in combative stance."]"
. += "[t_He] [t_is] visibly tense[CHECK_MOBILITY(src, MOBILITY_STAND) ? "." : ", and [t_is] standing in combative stance."]"
var/trait_exam = common_trait_examine()
if (!isnull(trait_exam))
@@ -491,7 +491,7 @@
to_chat(usr, "<span class='warning'>Unable to locate a data core entry for this person.</span>")
/mob/living/carbon/human/proc/canUseHUD()
return !(src.stat || IsKnockdown() || IsStun() || src.restrained())
return CHECK_MOBILITY(src, MOBILITY_UI)
/mob/living/carbon/human/can_inject(mob/user, error_msg, target_zone, penetrate_thick = FALSE, bypass_immunity = FALSE)
. = 1 // Default to returning true.
@@ -724,8 +724,8 @@
remove_atom_colour(TEMPORARY_COLOUR_PRIORITY, "#000000")
cut_overlay(MA)
/mob/living/carbon/human/canUseTopic(atom/movable/M, be_close=FALSE, no_dextery=FALSE, no_tk=FALSE)
if(incapacitated() || lying )
/mob/living/carbon/human/canUseTopic(atom/movable/M, be_close=FALSE, no_dextery=FALSE, no_tk=FALSE, check_resting = TRUE)
if(incapacitated() || (check_resting && !CHECK_MOBILITY(src, MOBILITY_STAND)))
to_chat(src, "<span class='warning'>You can't do that right now!</span>")
return FALSE
if(!Adjacent(M) && (M.loc != src))
@@ -836,7 +836,7 @@
visible_message("<span class='warning'>[src] dry heaves!</span>", \
"<span class='userdanger'>You try to throw up, but there's nothing in your stomach!</span>")
if(stun)
Knockdown(200)
DefaultCombatKnockdown(200)
return 1
..()
@@ -870,7 +870,7 @@
return (istype(target) && target.stat == CONSCIOUS)
/mob/living/carbon/human/proc/can_be_firemanned(mob/living/carbon/target)
return (ishuman(target) && target.lying)
return (ishuman(target) && !CHECK_MOBILITY(target, MOBILITY_STAND))
/mob/living/carbon/human/proc/fireman_carry(mob/living/carbon/target)
if(can_be_firemanned(target))
@@ -879,7 +879,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]!")
@@ -892,7 +892,7 @@
/mob/living/carbon/human/proc/piggyback(mob/living/carbon/target)
if(can_piggyback(target))
visible_message("<span class='notice'>[target] starts to climb onto [src]...</span>")
if(do_after(target, 15, target = src))
if(do_after(target, 15, target = src, required_mobility_flags = MOBILITY_STAND))
if(can_piggyback(target))
if(target.incapacitated(FALSE, TRUE) || incapacitated(FALSE, TRUE))
target.visible_message("<span class='warning'>[target] can't hang onto [src]!</span>")
@@ -49,9 +49,14 @@
if (mind.martial_art && mind.martial_art.dodge_chance)
if(!lying && dna && !dna.check_mutation(HULK))
if(prob(mind.martial_art.dodge_chance))
var/dodgemessage = pick("dodges under the projectile!","dodges to the right of the projectile!","jumps over the projectile!")
visible_message("<span class='danger'>[src] [dodgemessage]</span>", "<span class='userdanger'>You dodge the projectile!</span>")
return BULLET_ACT_BLOCK
var/static/dodgemessages = list("dodges under",0,-4,"dodges to the right of",-4,0,"dodges to the left of",4,0,"jumps over",0,4)
var/pick = pick(1,4,7,10)
var/oldx = pixel_x
var/oldy = pixel_y
animate(src,pixel_x = pixel_x + dodgemessages[pick+1],pixel_y = pixel_y + dodgemessages[pick+2],time=3)
animate(src,pixel_x = oldx,pixel_y = oldy,time=2)
visible_message("<span class='danger'>[src] [dodgemessages[pick]] the projectile!</span>", "<span class='userdanger'>You dodge the projectile!</span>")
return BULLET_ACT_FORCE_PIERCE
if(mind.martial_art && !incapacitated(FALSE, TRUE) && mind.martial_art.can_use(src) && mind.martial_art.deflection_chance) //Some martial arts users can deflect projectiles!
if(prob(mind.martial_art.deflection_chance))
if(!lying && dna && !dna.check_mutation(HULK)) //But only if they're not lying down, and hulks can't do it
@@ -174,7 +179,7 @@
"<span class='userdanger'>[M] disarmed [src]!</span>")
else if(!M.client || prob(5)) // only natural monkeys get to stun reliably, (they only do it occasionaly)
playsound(loc, 'sound/weapons/pierce.ogg', 25, 1, -1)
Knockdown(100)
DefaultCombatKnockdown(100)
log_combat(M, src, "tackled")
visible_message("<span class='danger'>[M] has tackled down [src]!</span>", \
"<span class='userdanger'>[M] has tackled down [src]!</span>")
@@ -223,9 +228,9 @@
else
playsound(loc, 'sound/weapons/pierce.ogg', 25, 1, -1)
if(!lying) //CITADEL EDIT
Knockdown(100, TRUE, FALSE, 30, 25)
DefaultCombatKnockdown(100, TRUE, FALSE, 30, 25)
else
Knockdown(100)
DefaultCombatKnockdown(100)
log_combat(M, src, "tackled")
visible_message("<span class='danger'>[M] has tackled down [src]!</span>", \
"<span class='userdanger'>[M] has tackled down [src]!</span>")
@@ -292,10 +297,10 @@
switch(M.damtype)
if("brute")
if(M.force > 35) // durand and other heavy mechas
Knockdown(50)
DefaultCombatKnockdown(50)
src.throw_at(throw_target, rand(1,5), 7)
else if(M.force >= 20 && !IsKnockdown()) // lightweight mechas like gygax
Knockdown(30)
else if(M.force >= 20 && CHECK_MOBILITY(src, MOBILITY_STAND)) // lightweight mechas like gygax
DefaultCombatKnockdown(30)
src.throw_at(throw_target, rand(1,3), 7)
update |= temp.receive_damage(dmg, 0)
playsound(src, 'sound/weapons/punch4.ogg', 50, 1)
@@ -0,0 +1,48 @@
/mob/living/carbon/human/resist_a_rest(automatic = FALSE, ignoretimer = FALSE)
if(!resting || stat || attemptingstandup)
return FALSE
if(ignoretimer)
set_resting(FALSE, FALSE)
return TRUE
if(!lying) //if they're in a chair or something they don't need to force themselves off the ground.
set_resting(FALSE, FALSE)
return TRUE
else if(!CHECK_MOBILITY(src, MOBILITY_RESIST))
if(!automatic)
to_chat(src, "<span class='warning'>You are unable to stand up right now.</span>")
return FALSE
else
var/totaldelay = 3 //A little bit less than half of a second as a baseline for getting up from a rest
if(getStaminaLoss() >= STAMINA_SOFTCRIT)
to_chat(src, "<span class='warning'>You're too exhausted to get up!")
return FALSE
attemptingstandup = TRUE
var/health_deficiency = max((maxHealth - (health - getStaminaLoss()))*0.5, 0)
if(!has_gravity())
health_deficiency = health_deficiency*0.2
totaldelay += health_deficiency
var/standupwarning = "[src] and everyone around them should probably yell at the dev team"
switch(health_deficiency)
if(-INFINITY to 10)
standupwarning = "[src] stands right up!"
if(10 to 35)
standupwarning = "[src] tries to stand up."
if(35 to 60)
standupwarning = "[src] slowly pushes [p_them()]self upright."
if(60 to 80)
standupwarning = "[src] weakly attempts to stand up."
if(80 to INFINITY)
standupwarning = "[src] struggles to stand up."
var/usernotice = automatic ? "<span class='notice'>You are now getting up. (Auto)</span>" : "<span class='notice'>You are now getting up.</span>"
visible_message("<span class='notice'>[standupwarning]</span>", usernotice, vision_distance = 5)
if(do_after(src, totaldelay, target = src, required_mobility_flags = MOBILITY_RESIST))
set_resting(FALSE, TRUE)
attemptingstandup = FALSE
return TRUE
else
attemptingstandup = FALSE
if(resting) //we didn't shove ourselves up or something
visible_message("<span class='notice'>[src] falls right back down.</span>", "<span class='notice'>You fall right back down.</span>")
if(has_gravity())
playsound(src, "bodyfall", 20, 1)
return FALSE
+17 -15
View File
@@ -1374,9 +1374,9 @@ 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.Knockdown(RAD_MOB_KNOCKDOWN_AMOUNT)
H.DefaultCombatKnockdown(RAD_MOB_KNOCKDOWN_AMOUNT)
to_chat(H, "<span class='danger'>You feel weak.</span>")
if(radiation > RAD_MOB_VOMIT && prob(RAD_MOB_VOMIT_PROB))
@@ -1524,7 +1524,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
//CITADEL CHANGES - makes resting and disabled combat mode reduce punch damage, makes being out of combat mode result in you taking more damage
if(!target.combatmode && damage < user.dna.species.punchstunthreshold)
damage = user.dna.species.punchstunthreshold - 1
if(user.resting)
if(!CHECK_MOBILITY(user, MOBILITY_STAND))
damage *= 0.5
if(!user.combatmode)
damage *= 0.25
@@ -1642,7 +1642,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
return*/
if(!target.combatmode) // CITADEL CHANGE
randn += -10 //CITADEL CHANGE - being out of combat mode makes it easier for you to get disarmed
if(user.resting) //CITADEL CHANGE
if(!CHECK_MOBILITY(user, MOBILITY_STAND)) //CITADEL CHANGE
randn += 100 //CITADEL CHANGE - No kosher disarming if you're resting
if(!user.combatmode) //CITADEL CHANGE
randn += 25 //CITADEL CHANGE - Makes it harder to disarm outside of combat mode
@@ -1725,7 +1725,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
var/mob/living/carbon/tempcarb = user
if(!tempcarb.combatmode)
totitemdamage *= 0.5
if(user.resting)
if(!CHECK_MOBILITY(user, MOBILITY_STAND))
totitemdamage *= 0.5
if(istype(H))
if(!H.combatmode)
@@ -1841,12 +1841,14 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
if(user.getStaminaLoss() >= STAMINA_SOFTCRIT)
to_chat(user, "<span class='warning'>You're too exhausted for that.</span>")
return
if(!user.resting)
if(user.IsKnockdown() || user.IsParalyzed() || user.IsStun())
to_chat(user, "<span class='warning'>You can't seem to force yourself up right now!</span>")
return
if(CHECK_MOBILITY(user, MOBILITY_STAND))
to_chat(user, "<span class='notice'>You can only force yourself up if you're on the ground.</span>")
return
user.visible_message("<span class='notice'>[user] forces [p_them()]self up to [p_their()] feet!</span>", "<span class='notice'>You force yourself up to your feet!</span>")
user.resting = 0
user.update_canmove()
user.set_resting(FALSE, TRUE)
user.adjustStaminaLossBuffered(user.stambuffer) //Rewards good stamina management by making it easier to instantly get up from resting
playsound(user, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
@@ -1859,7 +1861,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
return FALSE
if(attacker_style && attacker_style.disarm_act(user,target))
return TRUE
if(user.resting)
if(!CHECK_MOBILITY(user, MOBILITY_STAND))
return FALSE
else
if(user == target)
@@ -1872,7 +1874,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
target.w_uniform.add_fingerprint(user)
SEND_SIGNAL(target, COMSIG_HUMAN_DISARM_HIT, user, user.zone_selected)
if(!target.resting)
if(CHECK_MOBILITY(target, MOBILITY_STAND))
target.adjustStaminaLoss(5)
if(target.is_shove_knockdown_blocked())
@@ -1886,7 +1888,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
//Thank you based whoneedsspace
target_collateral_human = locate(/mob/living/carbon/human) in target_shove_turf.contents
if(target_collateral_human && !target_collateral_human.resting)
if(target_collateral_human && CHECK_MOBILITY(target_collateral_human, MOBILITY_STAND))
shove_blocked = TRUE
else
target_collateral_human = null
@@ -1897,15 +1899,15 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
var/append_message = ""
if(shove_blocked && !target.buckled)
var/directional_blocked = !target.Adjacent(target_shove_turf)
var/targetatrest = target.resting
var/targetatrest = !CHECK_MOBILITY(target, MOBILITY_STAND)
if((directional_blocked || !(target_collateral_human || target_shove_turf.shove_act(target, user))) && !targetatrest)
target.Knockdown(SHOVE_KNOCKDOWN_SOLID)
target.DefaultCombatKnockdown(SHOVE_KNOCKDOWN_SOLID)
user.visible_message("<span class='danger'>[user.name] shoves [target.name], knocking them down!</span>",
"<span class='danger'>You shove [target.name], knocking them down!</span>", null, COMBAT_MESSAGE_RANGE)
log_combat(user, target, "shoved", "knocking them down")
else if(target_collateral_human && !targetatrest)
target.Knockdown(SHOVE_KNOCKDOWN_HUMAN)
target_collateral_human.Knockdown(SHOVE_KNOCKDOWN_COLLATERAL)
target.DefaultCombatKnockdown(SHOVE_KNOCKDOWN_HUMAN)
target_collateral_human.DefaultCombatKnockdown(SHOVE_KNOCKDOWN_COLLATERAL)
user.visible_message("<span class='danger'>[user.name] shoves [target.name] into [target_collateral_human.name]!</span>",
"<span class='danger'>You shove [target.name] into [target_collateral_human.name]!</span>", null, COMBAT_MESSAGE_RANGE)
append_message += ", into [target_collateral_human.name]"
@@ -52,21 +52,20 @@
return 0
/datum/species/angel/proc/CanFly(mob/living/carbon/human/H)
if(H.stat || H.IsStun() || H.IsKnockdown())
return 0
if(!CHECK_MOBILITY(H, MOBILITY_MOVE))
return FALSE
if(H.wear_suit && ((H.wear_suit.flags_inv & HIDEJUMPSUIT) && (!H.wear_suit.species_exception || !is_type_in_list(src, H.wear_suit.species_exception)))) //Jumpsuits have tail holes, so it makes sense they have wing holes too
to_chat(H, "Your suit blocks your wings from extending!")
return 0
return FALSE
var/turf/T = get_turf(H)
if(!T)
return 0
return FALSE
var/datum/gas_mixture/environment = T.return_air()
if(environment && !(environment.return_pressure() > 30))
to_chat(H, "<span class='warning'>The atmosphere is too thin for you to fly!</span>")
return 0
else
return 1
return FALSE
return TRUE
/datum/action/innate/flight
name = "Toggle Flight"
@@ -81,12 +80,12 @@
if(H.movement_type & FLYING)
to_chat(H, "<span class='notice'>You settle gently back onto the ground...</span>")
A.ToggleFlight(H,0)
H.update_canmove()
H.update_mobility()
else
to_chat(H, "<span class='notice'>You beat your wings and begin to hover gently above the ground...</span>")
H.resting = 0
H.set_resting(FALSE, TRUE)
A.ToggleFlight(H,1)
H.update_canmove()
H.update_mobility()
/datum/species/angel/proc/flyslip(mob/living/carbon/human/H)
var/obj/buckled_obj

Some files were not shown because too many files have changed in this diff Show More