Revert "Manual update"

This reverts commit 7aa67928b3.
This commit is contained in:
Aurorablade
2015-05-06 20:57:37 -04:00
parent 55c2ad3941
commit 56ea5311a9
106 changed files with 672 additions and 2494 deletions
+3
View File
@@ -572,6 +572,9 @@ var/global/nologevent = 0
<A href='?src=\ref[src];quick_create_object=1'>Quick Create Object</A><br>
<A href='?src=\ref[src];create_turf=1'>Create Turf</A><br>
<A href='?src=\ref[src];create_mob=1'>Create Mob</A><br>
<br><A href='?src=\ref[src];vsc=airflow'>Edit Airflow Settings</A><br>
<A href='?src=\ref[src];vsc=plasma'>Edit Plasma Settings</A><br>
<A href='?src=\ref[src];vsc=default'>Choose a default ZAS setting</A><br>
"}
usr << browse(dat, "window=admin2;size=210x280")
-6
View File
@@ -501,12 +501,6 @@
if(ticker.mode.traitors.len)
dat += check_role_table("Traitors", ticker.mode.traitors, src)
if(ticker.mode.shadows.len)
dat += check_role_table("Shadowlings", ticker.mode.shadows, src)
if(ticker.mode.thralls.len)
dat += check_role_table("Shadowling Thralls", ticker.mode.thralls, src)
if(ticker.mode.vampires.len)
dat += check_role_table("Vampires", ticker.mode.vampires, src)
+2 -2
View File
@@ -13,8 +13,8 @@
display_name = holder.fakekey
for(var/mob/M in mob_list)
if((M.mind && M.mind.special_role && M.client) || (M.client && M.client.holder && (M.client.holder.rights & R_ADMIN)) )
if((M.mind && M.mind.special_role && M.client) || (M.client && M.client.holder))
M << "<font color='#960018'><span class='ooc'><span class='prefix'>AOOC:</span> <EM>[display_name]:</EM> <span class='message'>[msg]</span></span></font>"
log_ooc("(ANTAG) [key] : [msg]")
log_ooc("(ANTAG) [key] : [msg]")
+1 -1
View File
@@ -23,7 +23,7 @@
///////////////
//SOUND STUFF//
///////////////
var/ambience_playing = 0
var/ambience_playing= null
var/played = 0
////////////
+1 -3
View File
@@ -17,14 +17,12 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
"raider" = IS_MODE_COMPILED("heist"), // 1024 / 11
"vampire" = IS_MODE_COMPILED("vampire"), // 2048 / 12
"mutineer" = IS_MODE_COMPILED("mutiny"), // 4096 / 13
"blob" = IS_MODE_COMPILED("blob"), // 8192 / 14
"shadowling" = IS_MODE_COMPILED("shadowling") //16384 / 15
"blob" = IS_MODE_COMPILED("blob") // 8192 / 14
)
var/global/list/special_role_times = list( //minimum age (in days) for accounts to play these roles
num2text(BE_PAI) = 0,
num2text(BE_TRAITOR) = 7,
num2text(BE_CHANGELING) = 14,
num2text(BE_SHADOWLING) = 14,
num2text(BE_WIZARD) = 14,
num2text(BE_REV) = 14,
num2text(BE_VAMPIRE) = 14,
-1
View File
@@ -3,7 +3,6 @@
desc = "Because you really needed another excuse to punch your crewmates."
icon_state = "boxing"
item_state = "boxing"
species_restricted = null
species_fit = list("Vox")
sprite_sheets = list(
"Vox" = 'icons/mob/species/vox/gloves.dmi'
-97
View File
@@ -1,97 +0,0 @@
/obj/item/clothing/gloves/ring
name = "iron ring"
desc = "A band that goes around your finger. It's considered gauche to wear more than one."
gender = "neuter" // not plural anymore
transfer_prints = TRUE
icon_state = "ironring"
item_state = ""
icon = 'icons/obj/clothing/rings.dmi'
var/material = "iron"
var/stud = 0
species_restricted = null
New()
..()
update_icon()
update_icon()
if(stud)
icon_state = "d_[initial(icon_state)]"
else
icon_state = initial(icon_state)
examine()
..()
usr << "This one is made of [material]."
if(stud)
usr << "It is adorned with a single gem."
/obj/item/clothing/gloves/ring/attackby(obj/item/I as obj, mob/user as mob, params)
if(istype(I, /obj/item/stack/sheet/mineral/diamond))
var/obj/item/stack/sheet/mineral/diamond/D = I
if(stud)
usr << "<span class='notice'>The [src] already has a gem.</span>"
else
if(D.amount >= 1)
D.use(1)
stud = 1
update_icon()
usr << "<span class='notice'>You socket the diamond into the [src].</span>"
// s'pensive
/obj/item/clothing/gloves/ring/silver
name = "silver ring"
icon_state = "silverring"
material = "silver"
/obj/item/clothing/gloves/ring/silver/blessed // todo
name = "blessed silver ring"
/obj/item/clothing/gloves/ring/gold
name = "gold ring"
icon_state = "goldring"
material = "gold"
/obj/item/clothing/gloves/ring/gold/blessed
name = "wedding band"
// cheap
/obj/item/clothing/gloves/ring/plastic
name = "white plastic ring"
icon_state = "whitering"
material = "plastic"
/obj/item/clothing/gloves/ring/plastic/blue
name = "blue plastic ring"
icon_state = "bluering"
/obj/item/clothing/gloves/ring/plastic/red
name = "red plastic ring"
icon_state = "redring"
/obj/item/clothing/gloves/ring/plastic/random
New()
var/c = pick("white","blue","red")
name = "[c] plastic ring"
icon_state = "[c]ring"
// weird
/obj/item/clothing/gloves/ring/glass
name = "glass ring"
icon_state = "whitering"
material = "glass"
/obj/item/clothing/gloves/ring/plasma
name = "plasma ring"
icon_state = "plasmaring"
material = "plasma"
/obj/item/clothing/gloves/ring/uranium
name = "uranium ring"
icon_state = "uraniumring"
material = "uranium"
// cultish
/obj/item/clothing/gloves/ring/shadow
name = "shadow ring"
icon_state = "shadowring"
material = "shadows"
-5
View File
@@ -117,11 +117,6 @@
desc = "A beret with the engineering insignia emblazoned on it. For engineers that are more inclined towards style than safety."
icon_state = "e_beret_badge"
/obj/item/clothing/head/beret/atmos
name = "atmospherics beret"
desc = "A beret for those who have shown immaculate proficienty in piping. Or plumbing."
icon_state = "a_beret_badge"
//Medical
/obj/item/clothing/head/surgery
name = "surgical cap"
+4 -5
View File
@@ -140,13 +140,12 @@
desc = "it's a cybernetically enhanced jumpsuit used for administrative duties."
gas_transfer_coefficient = 0.01
permeability_coefficient = 0.01
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS|HEAD
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
armor = list(melee = 100, bullet = 100, laser = 100,energy = 100, bomb = 100, bio = 100, rad = 100)
cold_protection = UPPER_TORSO | LOWER_TORSO | LEGS | FEET | ARMS | HANDS | HEAD
cold_protection = UPPER_TORSO | LOWER_TORSO | LEGS | FEET | ARMS | HANDS
min_cold_protection_temperature = SPACE_SUIT_MIN_COLD_PROTECTION_TEMPERATURE
heat_protection = UPPER_TORSO | LOWER_TORSO|LEGS|FEET|ARMS|HANDS | HEAD
max_heat_protection_temperature = FIRE_IMMUNITY_SUIT_MAX_TEMP_PROTECT
slowdown = -10
heat_protection = UPPER_TORSO | LOWER_TORSO|LEGS|FEET|ARMS|HANDS
max_heat_protection_temperature = SPACE_SUIT_MAX_HEAT_PROTECTION_TEMPERATURE
siemens_coefficient = 0
/obj/item/clothing/under/johnny
-13
View File
@@ -101,19 +101,6 @@
overlays = list()
string_attached = null
user << "<span class='notice'>You detach the string from the coin.</span>"
else if(istype(W,/obj/item/weapon/weldingtool))
var/obj/item/weapon/weldingtool/WT = W
if(WT.welding && WT.remove_fuel(0, user))
var/typelist = list("iron" = /obj/item/clothing/gloves/ring,
"silver" = /obj/item/clothing/gloves/ring/silver,
"gold" = /obj/item/clothing/gloves/ring/gold,
"plasma" = /obj/item/clothing/gloves/ring/plasma,
"uranium" = /obj/item/clothing/gloves/ring/uranium)
var/typekey = typelist[cmineral]
if(ispath(typekey))
user << "\blue You make [src] into a ring."
new typekey(get_turf(loc))
qdel(src)
else ..()
/obj/item/weapon/coin/attack_self(mob/user as mob)
+2 -2
View File
@@ -9,7 +9,7 @@
opacity = 1
density = 1
blocks_air = 1
temperature = TCMB
temperature = T0C
var/mineral/mineral
var/mined_ore = 0
var/last_act = 0
@@ -392,7 +392,7 @@
icon_state = "asteroid"
oxygen = 0.01
nitrogen = 0.01
temperature = TCMB
temperature = T0C
icon_plating = "asteroid"
var/dug = 0 //0 = has not yet been dug, 1 = has already been dug
has_resources = 1
+3 -3
View File
@@ -3,7 +3,7 @@
/mob/proc/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -31,7 +31,7 @@
/mob/proc/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -54,7 +54,7 @@
/mob/proc/melt()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
-8
View File
@@ -356,14 +356,6 @@
key = "g"
flags = RESTRICTED | HIVEMIND
/datum/language/shadowling
name = "Shadowling Hivemind"
desc = "Shadowlings and their thralls are capable of communicating over a psychic hivemind."
speech_verb = "says"
colour = "shadowling"
key = "8"
flags = RESTRICTED | HIVEMIND
/datum/language/ling/broadcast(var/mob/living/speaker,var/message,var/speaker_mask)
if(speaker.mind && speaker.mind.changeling)
@@ -49,8 +49,6 @@ In all, this is a lot like the monkey code. /N
/mob/living/carbon/alien/attack_hand(mob/living/carbon/human/M as mob)
if(..()) //to allow surgery to return properly.
return 0
if(istype(src,/mob/living/carbon/alien/humanoid))
return 0 //this is horrible but 100% necessary
switch(M.a_intent)
if("help")
@@ -1,7 +1,7 @@
/mob/living/carbon/alien/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -22,7 +22,7 @@
/mob/living/carbon/alien/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -254,7 +254,18 @@
help_shake_act(M)
if ("grab")
grabbedby(M)
if (M == src || anchored)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab(M, src)
M.put_in_active_hand(G)
G.synch()
LAssailant = M
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
visible_message("<span class='warning'>[M] has grabbed [src] passively!</span>")
if ("harm")
M.do_attack_animation(src)
@@ -53,7 +53,7 @@
/mob/living/carbon/alien/humanoid/regenerate_icons()
..()
if (notransform) return
if (monkeyizing) return
update_inv_head(0,0)
update_inv_wear_suit(0,0)
@@ -23,8 +23,8 @@
/obj/item/organ/brain/New()
..()
spawn(5)
for(var/mob/living/carbon/brain/bmob in src) //I'm going to hell for this, but there's no other way to stop these runtimes.
bmob.client.screen.len = null //clear the hud
if(brainmob && brainmob.client)
brainmob.client.screen.len = null //clear the hud
/obj/item/organ/brain/proc/transfer_identity(var/mob/living/carbon/H)
name = "\the [H]'s [initial(src.name)]"
@@ -19,7 +19,7 @@
/mob/living/carbon/brain/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -169,17 +169,17 @@
..()
/obj/item/device/mmi/posibrain/New()
for(var/mob/living/carbon/brain/bmob in src) //Also going to hell for this, but this should fix the runtimes.
bmob = new /mob/living/carbon/brain(src)
bmob.name = "[pick(list("PBU","HIU","SINA","ARMA","OSI"))]-[rand(100, 999)]"
bmob.real_name = src.brainmob.name
bmob.loc = src
bmob.container = src
bmob.robot_talk_understand = 1
bmob.stat = 0
bmob.silent = 0
bmob.brain_op_stage = 4.0
dead_mob_list -= bmob
src.brainmob = new(src)
src.brainmob.name = "[pick(list("PBU","HIU","SINA","ARMA","OSI"))]-[rand(100, 999)]"
src.brainmob.real_name = src.brainmob.name
src.brainmob.loc = src
src.brainmob.container = src
src.brainmob.robot_talk_understand = 1
src.brainmob.stat = 0
src.brainmob.silent = 0
src.brainmob.brain_op_stage = 4.0
dead_mob_list -= src.brainmob
..()
+35 -51
View File
@@ -27,47 +27,34 @@ mob/living
if(germ_level < GERM_LEVEL_MOVE_CAP && prob(8))
germ_level++
#define STOMACH_ATTACK_DELAY 4
/mob/living/carbon/var/last_stomach_attack //defining this here because no one would look in carbon_defines for it
/mob/living/carbon/relaymove(var/mob/user, direction)
if(user in src.stomach_contents)
if(last_stomach_attack + STOMACH_ATTACK_DELAY > world.time) return
last_stomach_attack = world.time
for(var/mob/M in hearers(4, src))
if(M.client)
M.show_message(text("\red You hear something rumbling inside [src]'s stomach..."), 2)
var/obj/item/I = user.get_active_hand()
if(I && I.force)
var/d = rand(round(I.force / 4), I.force)
if(istype(src, /mob/living/carbon/human))
var/mob/living/carbon/human/H = src
var/obj/item/organ/external/organ = H.get_organ("chest")
if (istype(organ))
if(organ.take_damage(d, 0))
H.UpdateDamageIcon()
H.updatehealth()
else
src.take_organ_damage(d)
for(var/mob/M in viewers(user, null))
if(prob(40))
for(var/mob/M in hearers(4, src))
if(M.client)
M.show_message(text("\red <B>[user] attacks [src]'s stomach wall with the [I.name]!"), 2)
playsound(user.loc, 'sound/effects/attackblob.ogg', 50, 1)
M.show_message(text("\red You hear something rumbling inside [src]'s stomach..."), 2)
var/obj/item/I = user.get_active_hand()
if(I && I.force)
var/d = rand(round(I.force / 4), I.force)
if(istype(src, /mob/living/carbon/human))
var/mob/living/carbon/human/H = src
var/obj/item/organ/external/organ = H.get_organ("chest")
if (istype(organ))
if(organ.take_damage(d, 0))
H.UpdateDamageIcon()
H.updatehealth()
else
src.take_organ_damage(d)
for(var/mob/M in viewers(user, null))
if(M.client)
M.show_message(text("\red <B>[user] attacks [src]'s stomach wall with the [I.name]!"), 2)
playsound(user.loc, 'sound/effects/attackblob.ogg', 50, 1)
if(prob(src.getBruteLoss() - 50))
for(var/atom/movable/A in stomach_contents)
A.loc = loc
stomach_contents.Remove(A)
src.gib()
#undef STOMACH_ATTACK_DELAY
if(prob(src.getBruteLoss() - 50))
for(var/atom/movable/A in stomach_contents)
A.loc = loc
stomach_contents.Remove(A)
src.gib()
/mob/living/carbon/gib()
for(var/mob/M in src)
@@ -334,25 +321,22 @@ mob/living
src << "You must be conscious to do this!"
return
/mob/living/proc/add_ventcrawl(obj/machinery/atmospherics/starting_machine)
var/datum/pipe_network/network = starting_machine.return_network(starting_machine)
if(!network)
return
for(var/datum/pipeline/pipeline in network.line_members)
for(var/obj/machinery/atmospherics/A in (pipeline.members || pipeline.edges))
if(!A.pipe_image)
A.pipe_image = image(A, A.loc, layer = 20, dir = A.dir) //the 20 puts it above Byond's darkness (not its opacity view)
pipes_shown += A.pipe_image
client.images += A.pipe_image
/mob/living/proc/add_ventcrawl(obj/machinery/atmospherics/unary/starting_machine)
for(var/datum/pipeline/pipeline in starting_machine.network.line_members)
for(var/atom/A in (pipeline.members || pipeline.edges))
var/image/new_image = image(A, A.loc, dir = A.dir)
pipes_shown += new_image
client.images += new_image
/mob/living/proc/remove_ventcrawl()
if(client)
for(var/image/current_image in pipes_shown)
client.images -= current_image
client.eye = src
for(var/image/current_image in pipes_shown)
client.images -= current_image
pipes_shown.len = 0
if(client)
client.eye = src
/mob/living/carbon/clean_blood()
. = ..()
if(ishuman(src))
@@ -1,7 +1,7 @@
/mob/living/carbon/human/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -42,7 +42,7 @@
/mob/living/carbon/human/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -62,7 +62,7 @@
/mob/living/carbon/human/melt()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
+1 -24
View File
@@ -36,7 +36,7 @@
on_CD = handle_emote_CD() //proc located in code\modules\mob\emote.dm
else //Everyone else fails, skip the emote attempt
return
if("scream", "fart", "flip", "snap")
if("scream", "fart", "flip")
on_CD = handle_emote_CD() //proc located in code\modules\mob\emote.dm
//Everything else, including typos of the above emotes
else
@@ -720,29 +720,6 @@
m_type = 2
if ("snap")
if(prob(95))
m_type = 2
var/mob/living/carbon/human/H = src
var/obj/item/organ/external/L = H.get_organ("l_hand")
var/obj/item/organ/external/R = H.get_organ("r_hand")
var/left_hand_good = 0
var/right_hand_good = 0
if(L && (!(L.status & ORGAN_DESTROYED)) && (!(L.status & ORGAN_SPLINTED)) && (!(L.status & ORGAN_BROKEN)))
left_hand_good = 1
if(R && (!(R.status & ORGAN_DESTROYED)) && (!(R.status & ORGAN_SPLINTED)) && (!(R.status & ORGAN_BROKEN)))
right_hand_good = 1
if (!left_hand_good && !right_hand_good)
usr << "You need at least one hand in good working order to snap your fingers."
return
message = "<b>[src]</b> snaps \his fingers."
playsound(src.loc, 'sound/effects/fingersnap.ogg', 50, 1, -3)
else
message = "<span class='danger'><b>[src]</b> snaps \his fingers right off!</span>"
playsound(src.loc, 'sound/effects/snap.ogg', 50, 1)
// Needed for M_TOXIC_FART
if("fart")
@@ -247,7 +247,7 @@
while(limbs_affected != 0)
processing_dismember = pick(organs)
if(processing_dismember.limb_name != "chest" && processing_dismember.limb_name != "head" && processing_dismember.limb_name != "groin")
if(processing_dismember.name != "chest" && processing_dismember.name != "head" && processing_dismember.name != "groin")
processing_dismember.droplimb(1,pick(0,1,2),0,1)
limbs_affected -= 1
@@ -271,7 +271,7 @@
while(limbs_affected != 0)
processing_dismember = pick(organs)
if(processing_dismember.limb_name != "chest" && processing_dismember.limb_name != "head" && processing_dismember.limb_name != "groin")
if(processing_dismember.name != "chest" && processing_dismember.name != "head" && processing_dismember.name != "groin")
processing_dismember.droplimb(1,pick(0,2),0,1)
limbs_affected -= 1
@@ -281,7 +281,7 @@
while(limbs_affected != 0)
processing_dismember = pick(organs)
if(processing_dismember.limb_name != "chest" && processing_dismember.limb_name != "head" && processing_dismember.limb_name != "groin")
if(processing_dismember.name != "chest" && processing_dismember.name != "head" && processing_dismember.name != "groin")
processing_dismember.droplimb(1,pick(0,2),0,1)
limbs_affected -= 1
@@ -303,7 +303,7 @@
while(limbs_affected != 0)
processing_dismember = pick(organs)
if(processing_dismember.limb_name != "chest" && processing_dismember.limb_name != "head" && processing_dismember.limb_name != "groin")
if(processing_dismember.name != "chest" && processing_dismember.name != "head" && processing_dismember.name != "groin")
processing_dismember.droplimb(1,1,0,1)
limbs_affected -= 1
@@ -316,7 +316,7 @@
var/update = 0
var/weapon_message = "Explosive Blast"
for(var/obj/item/organ/external/temp in organs)
switch(temp.limb_name)
switch(temp.name)
if("head")
update |= temp.take_damage(b_loss * 0.2, f_loss * 0.2, used_weapon = weapon_message)
if("chest")
@@ -1400,8 +1400,6 @@
regenerate_icons()
fixblood()
UpdateAppearance()
if(species)
return 1
else
@@ -91,7 +91,7 @@
stance_damage = 0
// standing is poor
if(stance_damage >= 4)
if(stance_damage >= 4 || (stance_damage >= 2 && prob(5)))
if(!(lying || resting))
if(species && !(species.flags & NO_PAIN))
emote("scream")
+3 -18
View File
@@ -46,7 +46,7 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
set invisibility = 0
//set background = 1
if (notransform) return
if (monkeyizing) return
if(!loc) return // Fixing a null error that occurs when the mob isn't found in the world -- TLE
..()
@@ -760,24 +760,9 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
if(A.lighting_use_dynamic) light_amount = T.lighting_lumcount
else light_amount = 10
if(light_amount > species.light_dam) //if there's enough light, start dying
if(species.light_effect_amp)
adjustFireLoss(5) //This gets doubled by Shadowling's innate fire weakness, so it ends up being 10.
else
adjustFireLoss(1)
adjustBruteLoss(1)
src << "<span class='userdanger'>The light burns you!</span>"
src << 'sound/weapons/sear.ogg'
take_overall_damage(1,1)
else //heal in the dark
if(species.light_effect_amp)
adjustFireLoss(-5)
adjustBruteLoss(-5)
adjustBrainLoss(-25) //gibbering shadowlings are hilarious but also bad to have
adjustCloneLoss(-1)
SetWeakened(0)
SetStunned(0)
else
adjustFireLoss(-1)
adjustBruteLoss(-1)
heal_overall_damage(1,1)
//The fucking FAT mutation is the greatest shit ever. It makes everyone so hot and bothered.
@@ -471,10 +471,8 @@ proc/get_damage_icon_part(damage_state, body_part)
//For legacy support.
/mob/living/carbon/human/regenerate_icons()
..()
if(notransform) return
if(monkeyizing) return
update_mutations(0)
update_body(0)
update_hair(0)
update_mutantrace(0)
update_inv_w_uniform(0,0)
update_inv_wear_id(0)
@@ -9,7 +9,7 @@
set invisibility = 0
//set background = 1
if (src.notransform)
if (src.monkeyizing)
return
..()
@@ -1,7 +1,7 @@
/mob/living/carbon/monkey/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -21,7 +21,7 @@
/mob/living/carbon/monkey/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -12,7 +12,7 @@
/mob/living/carbon/monkey/Life()
set invisibility = 0
//set background = 1
if (notransform) return
if (monkeyizing) return
if (update_muts)
update_muts=0
domutcheck(src,null,MUTCHK_FORCED)
+1 -2
View File
@@ -41,8 +41,7 @@
var/brute_mod = null // Physical damage reduction/malus.
var/burn_mod = null // Burn damage reduction/malus.
var/light_dam //Light level above which species takes damage, and below which it heals.
var/light_effect_amp //If 0, takes/heals 1 burn and brute per tick. Otherwise, both healing and damage effects are amplified.
var/light_dam
var/max_hurt_damage = 9 // Max melee damage dealt + 5 if hulk
var/list/default_genes = list()
+234 -304
View File
@@ -1,7 +1,7 @@
/mob/living/Life()
..()
if (notransform) return
if (monkeyizing) return
if(!loc) return // Fixing a null error that occurs when the mob isn't found in the world -- TLE
if(mind)
if(mind in ticker.mode.implanted)
@@ -460,9 +460,6 @@
for(var/mob/living/carbon/slime/M in view(1,src))
M.UpdateFeed(src)
/*//////////////////////
START RESIST PROCS
*///////////////////////
/mob/living/verb/resist()
set name = "Resist"
@@ -476,327 +473,260 @@
//Getting out of someone's inventory.
if(istype(src.loc,/obj/item/weapon/holder))
resist_holder()
var/obj/item/weapon/holder/H = src.loc //Get our item holder.
var/mob/M = H.loc //Get our mob holder (if any).
if(istype(M))
M.unEquip(H)
M << "[H] wriggles out of your grip!"
src << "You wriggle out of [M]'s grip!"
else if(istype(H.loc,/obj/item))
src << "You struggle free of [H.loc]."
H.loc = get_turf(H)
if(istype(M))
for(var/atom/A in M.contents)
if(istype(A,/mob/living/simple_animal/borer) || istype(A,/obj/item/weapon/holder))
return
M.status_flags &= ~PASSEMOTES
return
//Resisting control by an alien mind.
if(istype(src.loc,/mob/living/simple_animal/borer))
resist_borer()
var/mob/living/simple_animal/borer/B = src.loc
var/mob/living/captive_brain/H = src
H << "\red <B>You begin doggedly resisting the parasite's control (this will take approximately sixty seconds).</B>"
B.host << "\red <B>You feel the captive mind of [src] begin to resist your control.</B>"
spawn(rand(350,450)+B.host.brainloss)
if(!B || !B.controlling)
return
B.host.adjustBrainLoss(rand(5,10))
H << "\red <B>With an immense exertion of will, you regain control of your body!</B>"
B.host << "\red <B>You feel control of the host brain ripped from your grasp, and retract your probosci before the wild neural impulses can damage you.</b>"
B.detatch()
verbs -= /mob/living/carbon/proc/release_control
verbs -= /mob/living/carbon/proc/punish_host
verbs -= /mob/living/carbon/proc/spawn_larvae
return
//resisting grabs (as if it helps anyone...)
if ((!(L.stat) && !(L.restrained())))
resist_grab(L) //this passes L because the proc requires a typecasted mob/living instead of just 'src'
if ((!( L.stat ) && !( L.restrained() )))
var/resisting = 0
for(var/obj/O in L.requests)
L.requests.Remove(O)
del(O)
resisting++
for(var/obj/item/weapon/grab/G in usr.grabbed_by)
resisting++
if (G.state == 1)
del(G)
else
if (G.state == 2)
if (prob(25))
for(var/mob/O in viewers(L, null))
O.show_message(text("\red [] has broken free of []'s grip!", L, G.assailant), 1)
del(G)
else
if (G.state == 3)
if (prob(5))
for(var/mob/O in viewers(usr, null))
O.show_message(text("\red [] has broken free of []'s headlock!", L, G.assailant), 1)
del(G)
if(resisting)
for(var/mob/O in viewers(usr, null))
O.show_message(text("\red <B>[] resists!</B>", L), 1)
//unbuckling yourself
if(L.buckled && (L.last_special <= world.time) )
resist_buckle(L) //this passes L because the proc requires a typecasted mob/living instead of just 'src'
if(iscarbon(L))
var/mob/living/carbon/C = L
if( C.handcuffed )
C.changeNext_move(CLICK_CD_BREAKOUT)
C.last_special = world.time + CLICK_CD_BREAKOUT
C << "\red You attempt to unbuckle yourself. (This will take around 2 minutes and you need to stand still)"
for(var/mob/O in viewers(L))
O.show_message("\red <B>[usr] attempts to unbuckle themself!</B>", 1)
spawn(0)
if(do_after(usr, 1200))
if(!C.buckled)
return
for(var/mob/O in viewers(C))
O.show_message("\red <B>[usr] manages to unbuckle themself!</B>", 1)
C << "\blue You successfully unbuckle yourself."
C.buckled.manual_unbuckle(C)
else
L.buckled.manual_unbuckle(L)
//Breaking out of a locker?
else if(src.loc && (istype(src.loc, /obj/structure/closet)))
resist_closet()
else if( src.loc && (istype(src.loc, /obj/structure/closet)) )
var/breakout_time = 2 //2 minutes by default
var/obj/structure/closet/C = L.loc
if(C.opened)
return //Door's open... wait, why are you in it's contents then?
if(istype(L.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
if(!SC.locked && !SC.welded)
return //It's a secure closet, but isn't locked. Easily escapable from, no need to 'resist'
else
if(!C.welded)
return //closed but not welded...
// else Meh, lets just keep it at 2 minutes for now
// breakout_time++ //Harder to get out of welded lockers than locked lockers
//okay, so the closet is either welded or locked... resist!!!
L.changeNext_move(CLICK_CD_BREAKOUT)
L.last_special = world.time + CLICK_CD_BREAKOUT
L << "\red You lean on the back of \the [C] and start pushing the door open. (this will take about [breakout_time] minutes)"
for(var/mob/O in viewers(usr.loc))
O.show_message("\red <B>The [L.loc] begins to shake violently!</B>", 1)
spawn(0)
if(do_after(usr,(breakout_time*60*10))) //minutes * 60seconds * 10deciseconds
if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened
return
//Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'...
if(istype(L.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
if(!SC.locked && !SC.welded)
return
else
if(!C.welded)
return
//Well then break it!
if(istype(usr.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
SC.desc = "It appears to be broken."
SC.icon_state = SC.icon_off
flick(SC.icon_broken, SC)
sleep(10)
flick(SC.icon_broken, SC)
sleep(10)
SC.broken = 1
SC.locked = 0
SC.update_icon()
usr << "\red You successfully break out!"
for(var/mob/O in viewers(L.loc))
O.show_message("\red <B>\the [usr] successfully broke out of \the [SC]!</B>", 1)
if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace)
var/obj/structure/bigDelivery/BD = SC.loc
BD.attack_hand(usr)
SC.open()
else
C.welded = 0
C.update_icon()
usr << "\red You successfully break out!"
for(var/mob/O in viewers(L.loc))
O.show_message("\red <B>\the [usr] successfully broke out of \the [C]!</B>", 1)
if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above
var/obj/structure/bigDelivery/BD = C.loc
BD.attack_hand(usr)
C.open()
//breaking out of handcuffs
else if(iscarbon(L))
var/mob/living/carbon/CM = L
if(CM.on_fire && CM.canmove)
resist_stop_drop_roll(CM) //this passes CM because the proc requires a typecasted mob/living/carbon instead of just 'src'
if(CM.handcuffed && CM.canmove && (CM.last_special <= world.time))//this passes CM because the proc requires a typecasted mob/living/carbon instead of just 'src'
resist_handcuffs(CM)
else if(CM.legcuffed && CM.canmove && (CM.last_special <= world.time)) //this passes CM because the proc requires a typecasted mob/living/carbon instead of just 'src'
resist_legcuffs(CM)
/*////////////////////
RESIST SUBPROCS
*/////////////////////
/* resist_holder allows small mobs that can be picked up to get out of their holder, so they aren't stuck forever.
*/////
/mob/living/proc/resist_holder()
var/obj/item/weapon/holder/H = src.loc //Get our item holder.
var/mob/M = H.loc //Get our mob holder (if any).
if(istype(M))
M.unEquip(H)
M << "[H] wriggles out of your grip!"
src << "You wriggle out of [M]'s grip!"
else if(istype(H.loc,/obj/item))
src << "You struggle free of [H.loc]."
H.loc = get_turf(H)
if(istype(M))
for(var/atom/A in M.contents)
if(istype(A,/mob/living/simple_animal/borer) || istype(A,/obj/item/weapon/holder))
return
M.status_flags &= ~PASSEMOTES
return
/* resist_borer allows a mob to regain control of their body after a borer has assumed control.
*/////
/mob/living/proc/resist_borer()
var/mob/living/simple_animal/borer/B = src.loc
var/mob/living/captive_brain/H = src
H << "\red <B>You begin doggedly resisting the parasite's control (this will take approximately sixty seconds).</B>"
B.host << "\red <B>You feel the captive mind of [src] begin to resist your control.</B>"
spawn(rand(350,450)+B.host.brainloss)
if(!B || !B.controlling)
CM.fire_stacks -= 5
CM.weakened = max(CM.weakened, 3)//We dont check for CANWEAKEN, I don't care how immune to weakening you are, if you're rolling on the ground, you're busy.
CM.update_canmove()
CM.spin(32,2)
CM.visible_message("<span class='danger'>[CM] rolls on the floor, trying to put themselves out!</span>", \
"<span class='notice'>You stop, drop, and roll!</span>")
sleep(30)
if(fire_stacks <= 0)
CM.visible_message("<span class='danger'>[CM] has successfully extinguished themselves!</span>", \
"<span class='notice'>You extinguish yourself.</span>")
ExtinguishMob()
return
B.host.adjustBrainLoss(rand(5,10))
H << "\red <B>With an immense exertion of will, you regain control of your body!</B>"
B.host << "\red <B>You feel control of the host brain ripped from your grasp, and retract your probosci before the wild neural impulses can damage you.</b>"
B.detatch()
verbs -= /mob/living/carbon/proc/release_control
verbs -= /mob/living/carbon/proc/punish_host
verbs -= /mob/living/carbon/proc/spawn_larvae
return
/* resist_grab allows a mob to resist a grab from another mob when disarming is not an option/neckgrabbed.
*/////
/mob/living/proc/resist_grab(var/mob/living/L)
var/resisting = 0
for(var/obj/O in L.requests)
L.requests.Remove(O)
del(O)
resisting++
for(var/obj/item/weapon/grab/G in usr.grabbed_by)
resisting++
if (G.state == 1)
del(G)
else
if(G.state == 2)
if(prob(25))
for(var/mob/O in viewers(L, null))
O.show_message(text("\red [] has broken free of []'s grip!", L, G.assailant), 1)
del(G)
if(CM.handcuffed && CM.canmove && (CM.last_special <= world.time))
CM.changeNext_move(CLICK_CD_BREAKOUT)
CM.last_special = world.time + CLICK_CD_BREAKOUT
if(isalienadult(CM) || (HULK in usr.mutations))//Don't want to do a lot of logic gating here.
usr << "\red You attempt to break your handcuffs. (This will take around 5 seconds and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message(text("\red <B>[] is trying to break the handcuffs!</B>", CM), 1)
spawn(0)
if(do_after(CM, 50))
if(!CM.handcuffed || CM.buckled)
return
for(var/mob/O in viewers(CM))
O.show_message(text("\red <B>[] manages to break the handcuffs!</B>", CM), 1)
CM << "\red You successfully break your handcuffs."
CM.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
del(CM.handcuffed)
CM.handcuffed = null
CM.update_inv_handcuffed()
else
if(G.state == 3)
if(prob(5))
for(var/mob/O in viewers(usr, null))
O.show_message(text("\red [] has broken free of []'s headlock!", L, G.assailant), 1)
del(G)
var/obj/item/weapon/restraints/handcuffs/HC = CM.handcuffed
var/breakouttime = 1200 //A default in case you are somehow handcuffed with something that isn't an obj/item/weapon/restraints/handcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
if(istype(HC)) //If you are handcuffed with actual handcuffs... Well what do I know, maybe someone will want to handcuff you with toilet paper in the future...
breakouttime = HC.breakouttime
displaytime = breakouttime / 600 //Minutes
CM << "\red You attempt to remove \the [HC]. (This will take around [displaytime] minutes and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message( "\red <B>[usr] attempts to remove \the [HC]!</B>", 1)
spawn(0)
if(do_after(CM, breakouttime))
if(!CM.handcuffed || CM.buckled)
return // time leniency for lag which also might make this whole thing pointless but the server
for(var/mob/O in viewers(CM))// lags so hard that 40s isn't lenient enough - Quarxink
O.show_message("\red <B>[CM] manages to remove the handcuffs!</B>", 1)
CM << "\blue You successfully remove \the [CM.handcuffed]."
CM.unEquip(CM.handcuffed)
if(resisting)
for(var/mob/O in viewers(usr, null))
O.show_message(text("\red <B>[] resists!</B>", L), 1)
/* resist_buckle allows a mob that is bucklecuffed to break free of the chair/bed/whatever
*/////
/mob/living/proc/resist_buckle(var/mob/living/L)
if(iscarbon(L))
var/mob/living/carbon/C = L
if(C.handcuffed)
C.changeNext_move(CLICK_CD_BREAKOUT)
C.last_special = world.time + CLICK_CD_BREAKOUT
C << "\red You attempt to unbuckle yourself. (This will take around 2 minutes and you need to stay still)</span>"
for(var/mob/O in viewers(L))
O.show_message("\red <B>[usr] attempts to unbuckle themself!</B>", 1)
spawn(0)
if(do_after(usr, 1200))
if(!C.buckled)
return
for(var/mob/O in viewers(C))
O.show_message("\red <B>[usr] manages to unbuckle themself!</B>", 1)
C << "\blue You successfully unbuckle yourself."
C.buckled.manual_unbuckle(C)
else
L.buckled.manual_unbuckle(L)
/* resist_closet() allows a mob to break out of a welded/locked closet
*/////
/mob/living/proc/resist_closet()
var/breakout_time = 2 //2 minutes by default
var/mob/living/L = src
var/obj/structure/closet/C = L.loc
if(C.opened)
return //Door's open... wait, why are you in it's contents then?
if(istype(L.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
if(!SC.locked && !SC.welded)
return //It's a secure closet, but isn't locked. Easily escapable from, no need to 'resist'
else
if(!C.welded)
return //closed but not welded...
// else Meh, lets just keep it at 2 minutes for now
// breakout_time++ //Harder to get out of welded lockers than locked lockers
//okay, so the closet is either welded or locked... resist!!!
L.changeNext_move(CLICK_CD_BREAKOUT)
L.last_special = world.time + CLICK_CD_BREAKOUT
L << "\red You lean on the back of \the [C] and start pushing the door open. (this will take about [breakout_time] minutes)"
for(var/mob/O in viewers(usr.loc))
O.show_message("\red <B>The [L.loc] begins to shake violently!</B>", 1)
spawn(0)
if(do_after(usr,(breakout_time*60*10))) //minutes * 60seconds * 10deciseconds
if(!C || !L || L.stat != CONSCIOUS || L.loc != C || C.opened) //closet/user destroyed OR user dead/unconcious OR user no longer in closet OR closet opened
return
//Perform the same set of checks as above for weld and lock status to determine if there is even still a point in 'resisting'...
if(istype(L.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
if(!SC.locked && !SC.welded)
return
else if(CM.legcuffed && CM.canmove && (CM.last_special <= world.time))
CM.changeNext_move(CLICK_CD_BREAKOUT)
CM.last_special = world.time + CLICK_CD_BREAKOUT
if(isalienadult(CM) || (HULK in usr.mutations))//Don't want to do a lot of logic gating here.
usr << "\red You attempt to break your legcuffs. (This will take around 5 seconds and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message(text("\red <B>[] is trying to break the legcuffs!</B>", CM), 1)
spawn(0)
if(do_after(CM, 50))
if(!CM.legcuffed || CM.buckled)
return
for(var/mob/O in viewers(CM))
O.show_message(text("\red <B>[] manages to break the legcuffs!</B>", CM), 1)
CM << "\red You successfully break your legcuffs."
CM.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
del(CM.legcuffed)
CM.legcuffed = null
CM.update_inv_legcuffed()
else
if(!C.welded)
return
//Well then break it!
if(istype(usr.loc, /obj/structure/closet/secure_closet))
var/obj/structure/closet/secure_closet/SC = L.loc
SC.desc = "It appears to be broken."
SC.icon_state = SC.icon_off
flick(SC.icon_broken, SC)
sleep(10)
flick(SC.icon_broken, SC)
sleep(10)
SC.broken = 1
SC.locked = 0
SC.update_icon()
usr << "\red You successfully break out!"
for(var/mob/O in viewers(L.loc))
O.show_message("\red <B>\the [usr] successfully broke out of \the [SC]!</B>", 1)
if(istype(SC.loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace)
var/obj/structure/bigDelivery/BD = SC.loc
BD.attack_hand(usr)
SC.open()
else
C.welded = 0
C.update_icon()
usr << "\red You successfully break out!"
for(var/mob/O in viewers(L.loc))
O.show_message("\red <B>\the [usr] successfully broke out of \the [C]!</B>", 1)
if(istype(C.loc, /obj/structure/bigDelivery)) //nullspace ect.. read the comment above
var/obj/structure/bigDelivery/BD = C.loc
BD.attack_hand(usr)
C.open()
/* resist_stop_drop_roll allows a mob to stop, drop, and roll in order to put out a fire burning on them.
*/////
/mob/living/proc/resist_stop_drop_roll(var/mob/living/carbon/CM)
CM.fire_stacks -= 5
CM.weakened = max(CM.weakened, 3)//We dont check for CANWEAKEN, I don't care how immune to weakening you are, if you're rolling on the ground, you're busy.
CM.update_canmove()
CM.spin(32,2)
CM.visible_message("<span class='danger'>[CM] rolls on the floor, trying to put themselves out!</span>", \
"<span class='notice'>You stop, drop, and roll!</span>")
sleep(30)
if(fire_stacks <= 0)
CM.visible_message("<span class='danger'>[CM] has successfully extinguished themselves!</span>", \
"<span class='notice'>You extinguish yourself.</span>")
ExtinguishMob()
return
/* resist_handcuffs allows a mob to break/remove their handcuffs after a delay
*/////
/mob/living/proc/resist_handcuffs(var/mob/living/carbon/CM)
CM.changeNext_move(CLICK_CD_BREAKOUT)
CM.last_special = world.time + CLICK_CD_BREAKOUT
var/obj/item/weapon/restraints/handcuffs/HC = CM.handcuffed
var/breakouttime = 1200 //A default in case you are somehow handcuffed with something that isn't an obj/item/weapon/restraints/handcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
var/hulklien = 0 //variable used to define if someone is a hulk or alien
if(istype(HC)) //If you are handcuffed with actual handcuffs... Well what do I know, maybe someone will want to handcuff you with toilet paper in the future...
breakouttime = HC.breakouttime
displaytime = breakouttime / 600 //Minutes
if(isalienadult(CM) || (HULK in usr.mutations))
hulklien = 1
breakouttime = 50
displaytime = 5
CM << "\red You attempt to remove \the [HC]. (This will take around [displaytime] [hulklien ? "seconds" : "minute[displaytime==1 ? "" : "s"]"] and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message( "\red <B>[usr] attempts to [hulklien ? "break" : "remove"] \the [HC]!</B>", 1)
spawn(0)
if(do_after(CM, breakouttime))
if(!CM.handcuffed || CM.buckled)
return // time leniency for lag which also might make this whole thing pointless but the server
for(var/mob/O in viewers(CM))// lags so hard that 40s isn't lenient enough - Quarxink
O.show_message("\red <B>[CM] manages to [hulklien ? "break" : "remove"] the handcuffs!</B>", 1)
CM << "\blue You successfully [hulklien ? "break" : "remove"] \the [CM.handcuffed]."
if(hulklien)
CM.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
del(CM.handcuffed)
CM.handcuffed = null
CM.update_inv_handcuffed()
return
CM.unEquip(CM.handcuffed)
/* resist_legcuffs allows a mob to break/remove their legcuffs after a delay
*/////
/mob/living/proc/resist_legcuffs(var/mob/living/carbon/CM)
var/obj/item/weapon/restraints/legcuffs/HC = CM.legcuffed
var/breakouttime = 1200 //A default in case you are somehow legcuffed with something that isn't an obj/item/weapon/legcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
var/hulklien = 0 //variable used to define if someone is a hulk or alien
if(istype(HC)) //If you are legcuffed with actual legcuffs... Well what do I know, maybe someone will want to legcuff you with toilet paper in the future...
breakouttime = HC.breakouttime
displaytime = breakouttime / 600 //Minutes
if(isalienadult(CM) || (HULK in usr.mutations))
hulklien = 1
breakouttime = 50
displaytime = 5
CM << "\red You attempt to remove \the [HC]. (This will take around [displaytime] [hulklien ? "seconds" : "minute[displaytime==1 ? "" : "s"]"] and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message( "\red <B>[usr] attempts to [hulklien ? "break" : "remove"] \the [HC]!</B>", 1)
spawn(0)
if(do_after(CM, breakouttime))
if(!CM.legcuffed || CM.buckled)
return // time leniency for lag which also might make this whole thing pointless but the server
for(var/mob/O in viewers(CM))// lags so hard that 40s isn't lenient enough - Quarxink
O.show_message("\red <B>[CM] manages to [hulklien ? "break" : "remove"] the legcuffs!</B>", 1)
CM << "\blue You successfully [hulklien ? "break" : "remove"] \the [CM.legcuffed]."
if(!hulklien)
CM.unEquip(CM.legcuffed)
if(hulklien)
CM.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ))
qdel(CM.legcuffed)
CM.legcuffed = null
CM.update_inv_legcuffed()
/*//////////////////////
END RESIST PROCS
*///////////////////////
var/obj/item/weapon/restraints/legcuffs/HC = CM.legcuffed
var/breakouttime = 1200 //A default in case you are somehow legcuffed with something that isn't an obj/item/weapon/legcuffs type
var/displaytime = 2 //Minutes to display in the "this will take X minutes."
if(istype(HC)) //If you are legcuffed with actual legcuffs... Well what do I know, maybe someone will want to legcuff you with toilet paper in the future...
breakouttime = HC.breakouttime
displaytime = breakouttime / 600 //Minutes
CM << "\red You attempt to remove \the [HC]. (This will take around [displaytime] minutes and you need to stand still)"
for(var/mob/O in viewers(CM))
O.show_message( "\red <B>[usr] attempts to remove \the [HC]!</B>", 1)
spawn(0)
if(do_after(CM, breakouttime))
if(!CM.legcuffed || CM.buckled)
return // time leniency for lag which also might make this whole thing pointless but the server
for(var/mob/O in viewers(CM))// lags so hard that 40s isn't lenient enough - Quarxink
O.show_message("\red <B>[CM] manages to remove the legcuffs!</B>", 1)
CM << "\blue You successfully remove \the [CM.legcuffed]."
CM.unEquip(CM.legcuffed)
CM.legcuffed = null
CM.update_inv_legcuffed()
/mob/living/carbon/proc/spin(spintime, speed)
spawn()
-8
View File
@@ -7,11 +7,6 @@
//If they're SSD, remove it so they can wake back up.
player_logged = 0
//login during ventcrawl
if(istype(loc, /obj/machinery/atmospherics)) //attach us back into the pipes
remove_ventcrawl()
add_ventcrawl(loc)
//Round specific stuff like hud updates
if(ticker && ticker.mode)
var/ref = "\ref[mind]"
@@ -32,7 +27,4 @@
if("vampire")
if((ref in ticker.mode.thralls) || (mind in ticker.mode.enthralled))
ticker.mode.update_vampire_icons_added(mind)
if("shadowling")
if((mind in ticker.mode.shadowling_thralls) || (mind in ticker.mode.shadows))
ticker.mode.update_shadow_icons_added(src.mind)
return .
+1
View File
@@ -6,6 +6,7 @@ var/list/ai_verbs_default = list(
/mob/living/silicon/ai/proc/ai_alerts,
/mob/living/silicon/ai/proc/announcement,
/mob/living/silicon/ai/proc/ai_call_shuttle,
/mob/living/silicon/ai/proc/ai_cancel_call,
/mob/living/silicon/ai/proc/ai_camera_track,
/mob/living/silicon/ai/proc/ai_camera_list,
/mob/living/silicon/ai/proc/ai_goto_location,
+2 -2
View File
@@ -1,7 +1,7 @@
/mob/living/silicon/gib()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -22,7 +22,7 @@
/mob/living/silicon/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -2,7 +2,7 @@
set invisibility = 0
set background = 1
if (src.notransform)
if (src.monkeyizing)
return
@@ -1,7 +1,7 @@
/mob/living/silicon/robot/gib()
//robots don't die when gibbed. instead they drop their MMI'd brain
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -23,7 +23,7 @@
/mob/living/silicon/robot/dust()
death(1)
var/atom/movable/overlay/animation = null
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -18,8 +18,6 @@
/obj/item/mounted/frame/apc_frame,
/obj/item/mounted/frame/alarm_frame,
/obj/item/mounted/frame/firealarm,
/obj/item/mounted/frame/newscaster_frame,
/obj/item/mounted/frame/intercom,
/obj/item/weapon/table_parts,
/obj/item/weapon/rack_parts,
/obj/item/weapon/camera_assembly,
@@ -88,10 +86,7 @@
wrapped.loc = user
//Pass the attack on to the target. This might delete/relocate wrapped.
if(!target.attackby(wrapped, user, params) && target && wrapped)
// If the attackby didn't resolve or delete the target or wrapped, afterattack
// (Certain things, such as mountable frames, rely on afterattack)
wrapped.afterattack(target, user, 1, params)
target.attackby(wrapped,user, params)
//If wrapped did neither get deleted nor put into target, put it back into the gripper.
if(wrapped && user && (wrapped.loc == user))
@@ -193,17 +193,16 @@
var/slot_num
if(slot_start == 0)
slot_num = 0
slot_start = 3
slot_num = 1
slot_start = 2
else
slot_num = slot_start
slot_num = slot_start + 1
do
slot_num++
if(slot_num > 3) slot_num = 1 //Wrap around.
while(slot_start != slot_num) //If we wrap around without finding any free slots, just give up.
if(module_active(slot_num))
select_module(slot_num)
return
while(slot_start != slot_num) //If we wrap around without finding any free slots, just give up.
slot_num++
if(slot_num > 3) slot_num = 1 //Wrap around.
return
@@ -2,7 +2,7 @@
set invisibility = 0
//set background = 1
if (src.notransform)
if (src.monkeyizing)
return
src.blinded = null
@@ -10,7 +10,7 @@ var/list/robot_verbs_default = list(
icon_state = "robot"
maxHealth = 100
health = 100
universal_understand = 1
universal_speak = 1
var/sight_mode = 0
var/custom_name = ""
@@ -819,9 +819,9 @@ var/list/robot_verbs_default = list(
return ..()
/mob/living/silicon/robot/emag_act(user as mob)
if(!ishuman(user) && !issilicon(user))
if(!ishuman(user))
return
var/mob/living/M = user
var/mob/living/carbon/human/H = user
if(!opened)//Cover is closed
if(locked)
if(prob(90))
@@ -844,8 +844,8 @@ var/list/robot_verbs_default = list(
sleep(6)
if(prob(50))
emagged = 1
if(src.hud_used)
src.hud_used.update_robot_modules_display() //Shows/hides the emag item if the inventory screen is already open.
if(H.hud_used)
H.hud_used.update_robot_modules_display() //Shows/hides the emag item if the inventory screen is already open.
lawupdate = 0
connected_ai = null
user << "You emag [src]'s interface."
@@ -855,8 +855,8 @@ var/list/robot_verbs_default = list(
clear_inherent_laws()
laws = new /datum/ai_laws/syndicate_override
var/time = time2text(world.realtime,"hh:mm:ss")
lawchanges.Add("[time] <B>:</B> [M.name]([M.key]) emagged [name]([key])")
set_zeroth_law("Only [M.real_name] and people he designates as being such are Syndicate Agents.")
lawchanges.Add("[time] <B>:</B> [H.name]([H.key]) emagged [name]([key])")
set_zeroth_law("Only [H.real_name] and people he designates as being such are Syndicate Agents.")
src << "\red ALERT: Foreign software detected."
sleep(5)
src << "\red Initiating diagnostics..."
@@ -872,7 +872,7 @@ var/list/robot_verbs_default = list(
src << "\red ERRORERRORERROR"
src << "<b>Obey these laws:</b>"
laws.show_laws(src)
src << "\red \b ALERT: [M.real_name] is your new master. Obey your new laws and his commands."
src << "\red \b ALERT: [H.real_name] is your new master. Obey your new laws and his commands."
if(src.module && istype(src.module, /obj/item/weapon/robot_module/miner))
for(var/obj/item/weapon/pickaxe/borgdrill/D in src.module.modules)
del(D)
@@ -142,7 +142,7 @@
/obj/item/stack/sheet/metal = 50,
/obj/item/stack/sheet/glass = 50,
/obj/item/stack/sheet/rglass = 50,
/obj/item/stack/cable_coil/cyborg = 50,
/obj/item/stack/cable_coil = 50,
/obj/item/stack/rods = 15,
/obj/item/stack/tile/plasteel = 15
)
@@ -179,7 +179,7 @@
G.amount = 50
src.modules += G
var/obj/item/stack/cable_coil/cyborg/W = new /obj/item/stack/cable_coil/cyborg(src)
var/obj/item/stack/cable_coil/W = new /obj/item/stack/cable_coil(src)
W.amount = 50
src.modules += W
@@ -389,7 +389,7 @@
/obj/item/stack/tile/plasteel = 15,
/obj/item/stack/sheet/metal = 20,
/obj/item/stack/sheet/glass = 20,
/obj/item/stack/cable_coil/cyborg = 30
/obj/item/stack/cable_coil = 30
)
New()
@@ -1,33 +0,0 @@
/mob/living/simple_animal/ascendant_shadowling
name = "Ascendant Shadowling"
desc = "A large, floating eldritch horror. It has pulsing markings all about its body and large horns. It seems to be floating without any form of support."
icon = 'icons/mob/mob.dmi'
icon_state = "shadowling_ascended"
icon_living = "shadowling_ascended"
speak_emote = list("telepathically thunders", "telepathically booms")
force_threshold = INFINITY //Can't die by normal means
health = 100000
maxHealth = 100000
speed = 0
var/phasing = 0
see_in_dark = 8
see_invisible = SEE_INVISIBLE_MINIMUM
response_help = "stares at"
response_disarm = "flails at"
response_harm = "flails at"
harm_intent_damage = 0
melee_damage_lower = 35
melee_damage_upper = 35
attacktext = "claws at"
attack_sound = 'sound/weapons/slash.ogg'
minbodytemp = 0
maxbodytemp = INFINITY
environment_smash = 2
faction = list("faithless")
/mob/living/simple_animal/ascendant_shadowling/Process_Spacemove(var/movement_dir = 0)
return 1 //copypasta from carp code
+1 -1
View File
@@ -1023,7 +1023,7 @@ var/list/slot_equipment_priority = list( \
if(world.time < client.move_delay) return 0
if(stat==2) return 0
if(anchored) return 0
if(notransform) return 0
if(monkeyizing) return 0
if(restrained()) return 0
return 1
+1 -1
View File
@@ -57,7 +57,7 @@
var/disabilities = 0 //Carbon
var/atom/movable/pulling = null
var/next_move = null
var/notransform = null //Carbon
var/monkeyizing = null //Carbon
var/other = 0.0
var/hand = null
var/eye_blind = null //Carbon
+9 -46
View File
@@ -1,13 +1,6 @@
#define UPGRADE_COOLDOWN 40
#define UPGRADE_KILL_TIMER 100
//times it takes for a mob to eat
#define EAT_TIME_XENO 30
#define EAT_TIME_FAT 100
//time it takes for a mob to be eaten (in deciseconds) (overrides mob eat time)
#define EAT_TIME_MOUSE 30
/obj/item/weapon/grab
name = "grab"
flags = NOBLUDGEON | ABSTRACT
@@ -194,47 +187,22 @@
if(!affecting)
return
if(M == affecting) //what the actual fuck is this
if(M == affecting)
s_click(hud)
return
if(M == assailant && state >= GRAB_AGGRESSIVE) //no eatin unless you have an agressive grab
if(checkvalid(user, affecting)) //wut
if(M == assailant && state >= GRAB_AGGRESSIVE)
if( (ishuman(user) && (FAT in user.mutations) && iscarbon(affecting) ) || ( isalien(user) && iscarbon(affecting) ) || ( istype(user,/mob/living/carbon/human/kidan) && istype(affecting,/mob/living/carbon/monkey/diona) ) || ( ishuman(user) && user.get_species() == "Tajaran" && istype(affecting,/mob/living/simple_animal/mouse) ) )
var/mob/living/carbon/attacker = user
user.visible_message("<span class='danger'>[user] is attempting to devour \the [affecting]!</span>")
if(!do_mob(user, affecting) || !do_after(user, checktime(user, affecting))) return
if(istype(user, /mob/living/carbon/alien/humanoid/hunter) || istype(affecting, /mob/living/simple_animal/mouse)) //mice are easy to eat
if(!do_mob(user, affecting)||!do_after(user, 30)) return
else
if(!do_mob(user, affecting)||!do_after(user, 100)) return
user.visible_message("<span class='danger'>[user] devours \the [affecting]!</span>")
affecting.loc = user //add the mob to the user
attacker.stomach_contents.Add(affecting) //list keeping
affecting.loc = user
attacker.stomach_contents.Add(affecting)
del(src)
/obj/item/weapon/grab/proc/checkvalid(var/mob/attacker, var/mob/prey) //does all the checking for the attack proc to see if a mob can eat another with the grab
if(ishuman(attacker) && (FAT in attacker.mutations) && iscarbon(prey) && !isalien(prey)) //Fat people eating carbon mobs but not xenos
return 1
if(isalien(attacker) && iscarbon(prey)) //Xenomorphs eating carbon mobs
return 1
if(ishuman(attacker) && attacker.get_species() == "Kidan" && istype(prey,/mob/living/carbon/monkey/diona)) //Kidan eating nymphs
return 1
if(ishuman(attacker) && attacker.get_species() == "Tajaran" && istype(prey,/mob/living/simple_animal/mouse)) //Tajaran eating mice. Meow!
return 1
return 0
/obj/item/weapon/grab/proc/checktime(var/mob/attacker, var/mob/prey) //Returns the time the attacker has to wait before they eat the prey
if(isalien(attacker))
return EAT_TIME_XENO //xenos get a speed boost
if(istype(prey,/mob/living/simple_animal/mouse)) //mice get eaten at xeno-eating-speed regardless
return EAT_TIME_MOUSE
return EAT_TIME_FAT //if it doesn't fit into the above, it's probably a fat guy, take EAT_TIME_FAT to do it
/obj/item/weapon/grab/dropped()
del(src)
@@ -243,8 +211,3 @@
/obj/item/weapon/grab/Destroy()
del(hud)
..()
#undef EAT_TIME_XENO
#undef EAT_TIME_FAT
#undef EAT_TIME_MOUSE
+1 -1
View File
@@ -190,7 +190,7 @@
if(isAI(mob))
return AIMove(n,direct,mob)
if(mob.notransform) return//This is sota the goto stop mobs from moving var
if(mob.monkeyizing) return//This is sota the goto stop mobs from moving var
if(isliving(mob))
var/mob/living/L = mob
+15 -15
View File
@@ -5,14 +5,14 @@
/*
/mob/living/carbon/human/proc/monkeyize()
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
if (W==w_uniform) // will be torn
continue
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
stunned = 1
icon = null
@@ -62,7 +62,7 @@
return ..()
/mob/living/carbon/human/AIize(move=1) // 'move' argument needs defining here too because BYOND is dumb
if (notransform)
if (monkeyizing)
return
for(var/t in organs)
del(t)
@@ -70,11 +70,11 @@
return ..(move)
/mob/living/carbon/AIize()
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -178,12 +178,12 @@
//human -> robot
/mob/living/carbon/human/proc/Robotize()
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -236,12 +236,12 @@
//human -> alien
/mob/living/carbon/human/proc/Alienize()
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -267,12 +267,12 @@
return
/mob/living/carbon/human/proc/slimeize(adult as num, reproduce as num)
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -302,12 +302,12 @@
return
/mob/living/carbon/human/proc/corgize()
if (notransform)
if (monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
@@ -332,13 +332,13 @@
usr << "\red Sorry but this mob type is currently unavailable."
return
if(notransform)
if(monkeyizing)
return
for(var/obj/item/W in src)
unEquip(W)
regenerate_icons()
notransform = 1
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
+3 -4
View File
@@ -210,11 +210,11 @@
if(owner && loc == owner)
if(!cannot_amputate && config.limbs_can_break && (brute_dam + burn_dam) >= (max_damage * config.organ_health_multiplier))
var/dropped
if(burn >= 20 && prob(burn / 2))
if(burn >= 20 && prob(burn))
if(body_part == HEAD) return
dropped = 1
droplimb(0,DROPLIMB_BURN)
if(!dropped && prob(brute / 2))
if(!dropped && prob(brute))
if(edge)
droplimb(0,DROPLIMB_EDGE)
else
@@ -664,7 +664,6 @@ Note that amputating the affected organ does in fact remove the infection from t
return
if(DROPLIMB_BURN)
new /obj/effect/decal/cleanable/ash(get_turf(victim))
qdel(src)
if(DROPLIMB_BLUNT)
var/obj/effect/decal/cleanable/blood/gibs/gore = new victim.species.single_gib_type(get_turf(victim))
if(victim.species.flesh_color)
@@ -678,8 +677,8 @@ Note that amputating the affected organ does in fact remove the infection from t
I.removed()
if(istype(loc,/turf))
I.throw_at(get_edge_target_turf(src,pick(alldirs)),rand(1,3),30)
qdel(src)
del(src)
/****************************************************
HELPERS
-8
View File
@@ -635,11 +635,3 @@ obj/structure/cable/proc/cableColor(var/colorC)
else
return ..()
/obj/item/stack/cable_coil/cyborg
name = "cyborg cable coil"
/obj/item/stack/cable_coil/cyborg/attack_self(mob/user)
var/cable_color = input(user,"Pick a cable color.","Cable Color") in list("red","yellow","green","blue","pink","orange","cyan","white")
_color = cable_color
update_icon()
+10 -91
View File
@@ -1,27 +1,10 @@
//clusterCheckFlags defines
//All based on clusterMin and clusterMax as guides
//Individual defines
#define CLUSTER_CHECK_NONE 0 //No checks are done, cluster as much as possible
#define CLUSTER_CHECK_DIFFERENT_TURFS 2 //Don't let turfs of DIFFERENT types cluster
#define CLUSTER_CHECK_DIFFERENT_ATOMS 4 //Don't let atoms of DIFFERENT types cluster
#define CLUSTER_CHECK_SAME_TURFS 8 //Don't let turfs of the SAME type cluster
#define CLUSTER_CHECK_SAME_ATOMS 16 //Don't let atoms of the SAME type cluster
//Combined defines
#define CLUSTER_CHECK_SAMES 24 //Don't let any of the same type cluster
#define CLUSTER_CHECK_DIFFERENTS 6 //Don't let any of different types cluster
#define CLUSTER_CHECK_ALL_TURFS 10 //Don't let ANY turfs cluster same and different types
#define CLUSTER_CHECK_ALL_ATOMS 20 //Don't let ANY atoms cluster same and different types
//All
#define CLUSTER_CHECK_ALL 30 //Don't let anything cluster, like, at all
/datum/mapGenerator
//Map information
var/list/map = list()
var/turf/bottomLeft = null
var/turf/topRight = null
//mapGeneratorModule information
var/list/modules = list()
@@ -30,62 +13,21 @@
..()
initialiseModules()
//Defines the region the map represents, sets map
//Defines the region the map represents, sets map, bottomLeft, topRight
//Returns the map
/datum/mapGenerator/proc/defineRegion(var/turf/Start, var/turf/End, var/replace = 0)
/datum/mapGenerator/proc/defineRegion(var/turf/Start, var/turf/End)
if(!checkRegion(Start, End))
return 0
if(replace)
undefineRegion()
map |= block(Start,End)
return map
//Defines the region the map represents, as a CIRCLE!, sets map
//Returns the map
/datum/mapGenerator/proc/defineCircularRegion(var/turf/Start, var/turf/End, var/replace = 0)
if(!checkRegion(Start, End))
if(!Start || !End)
return 0
bottomLeft = Start
topRight = End
var/centerX = abs(max(End.x-Start.x,1))
var/centerY = abs(max(End.y-Start.y,1))
var/lilZ = min(Start.z,End.z)
var/bigZ = max(Start.z,End.z)
var/centerZ = max(abs(bigZ-(lilZ/2)),1) //Spherical maps! woo!
var/radius = abs(max(centerX,centerY)) //take the biggest displacement as the radius
if(replace)
undefineRegion()
//Sphere mode engage
var/evenCheckZ = 0
if(max(bigZ,lilZ) % 2 == 0)
evenCheckZ = centerZ+1
for(var/i = lilZ, i <= bigZ, i++)
var/theRadius = radius
if(i != centerZ)
if(i != evenCheckZ)
theRadius = max(radius/max((2*abs(centerZ-i)),1),1)
map |= circlerange(locate(centerX,centerY,i),theRadius)
map = block(bottomLeft,topRight)
return map
//Empties the map list, he's dead jim.
/datum/mapGenerator/proc/undefineRegion()
map = list() //bai bai
//Checks for and Rejects bad region coordinates
//Returns 1/0
/datum/mapGenerator/proc/checkRegion(var/turf/Start, var/turf/End)
@@ -110,8 +52,7 @@
if(!modules || !modules.len)
return
for(var/datum/mapGeneratorModule/mod in modules)
spawn(0)
mod.generate()
mod.generate()
//Requests the mapGeneratorModule(s) to (re)generate this one turf
@@ -122,8 +63,7 @@
if(!modules || !modules.len)
return
for(var/datum/mapGeneratorModule/mod in modules)
spawn(0)
mod.place(T)
mod.place(T)
//Replaces all paths in the module list with actual module datums
@@ -174,27 +114,6 @@
src << "End Coords: [endCoords[1]] - [endCoords[2]] - [endCoords[3]]"
return
var/list/clusters = list("None"=CLUSTER_CHECK_NONE,"All"=CLUSTER_CHECK_ALL,"Sames"=CLUSTER_CHECK_SAMES,"Differents"=CLUSTER_CHECK_DIFFERENTS, \
"Same turfs"=CLUSTER_CHECK_SAME_TURFS, "Same atoms"=CLUSTER_CHECK_SAME_ATOMS, "Different turfs"=CLUSTER_CHECK_DIFFERENT_TURFS, \
"Different atoms"=CLUSTER_CHECK_DIFFERENT_ATOMS, "All turfs"=CLUSTER_CHECK_ALL_TURFS,"All atoms"=CLUSTER_CHECK_ALL_ATOMS)
var/moduleClusters = input("Cluster Flags (Cancel to leave unchanged from defaults)","Map Gen Settings") as null|anything in clusters
//null for default
var/theCluster = 0
if(moduleClusters != "None")
if(!clusters[moduleClusters])
src << "Invalid Cluster Flags"
return
theCluster = clusters[moduleClusters]
else
theCluster = CLUSTER_CHECK_NONE
if(theCluster)
for(var/datum/mapGeneratorModule/M in N.modules)
M.clusterCheckFlags = theCluster
src << "Defining Region"
N.defineRegion(Start, End)
src << "Region Defined"
@@ -1,12 +1,16 @@
#define CLUSTER_CHECK_NONE 0 //No checks are done, cluster as much as possible
#define CLUSTER_CHECK_ATOMS 2 //Don't let atoms cluster, based on clusterMin and clusterMax as guides
#define CLUSTER_CHECK_TURFS 4 //Don't let turfs cluster, based on clusterMin and clusterMax as guides
#define CLUSTER_CHECK_ALL 6 //Don't let anything cluster, based on clusterMind and clusterMax as guides
/datum/mapGeneratorModule
var/datum/mapGenerator/mother = null
var/list/spawnableAtoms = list()
var/list/spawnableTurfs = list()
var/clusterMax = 5
var/clusterMin = 1
var/clusterCheckFlags = CLUSTER_CHECK_SAME_ATOMS
var/allowAtomsOnSpace = FALSE
var/clusterCheckFlags = CLUSTER_CHECK_ALL
//Syncs the module up with it's mother
@@ -31,74 +35,27 @@
return 0
var/clustering = 0
var/skipLoopIteration = FALSE
//Turfs don't care whether atoms can be placed here
for(var/turfPath in spawnableTurfs)
//Clustering!
if(clusterMax && clusterMin)
//You're the same as me? I hate you I'm going home
if(clusterCheckFlags & CLUSTER_CHECK_SAME_TURFS)
if(clusterCheckFlags & CLUSTER_CHECK_TURFS)
if(clusterMax && clusterMin)
clustering = rand(clusterMin,clusterMax)
for(var/turf/F in trange(clustering,T))
if(istype(F,turfPath))
skipLoopIteration = TRUE
break
if(skipLoopIteration)
skipLoopIteration = FALSE
if(locate(/atom/movable) in range(clustering, T))
continue
//You're DIFFERENT to me? I hate you I'm going home
if(clusterCheckFlags & CLUSTER_CHECK_DIFFERENT_TURFS)
clustering = rand(clusterMin,clusterMax)
for(var/turf/F in trange(clustering,T))
if(!(istype(F,turfPath)))
skipLoopIteration = TRUE
break
if(skipLoopIteration)
skipLoopIteration = FALSE
continue
//Success!
if(prob(spawnableTurfs[turfPath]))
T.ChangeTurf(turfPath)
//Atoms DO care whether atoms can be placed here
if(checkPlaceAtom(T))
for(var/atomPath in spawnableAtoms)
//Clustering!
if(clusterMax && clusterMin)
//You're the same as me? I hate you I'm going home
if(clusterCheckFlags & CLUSTER_CHECK_SAME_ATOMS)
clustering = rand(clusterMin, clusterMax)
for(var/atom/movable/M in range(clustering,T))
if(istype(M,atomPath))
skipLoopIteration = TRUE
break
if(skipLoopIteration)
skipLoopIteration = FALSE
if(clusterCheckFlags & CLUSTER_CHECK_ATOMS)
if(clusterMax && clusterMin)
clustering = rand(clusterMin,clusterMax)
if(locate(/atom/movable) in range(clustering, T))
continue
//You're DIFFERENT from me? I hate you I'm going home
if(clusterCheckFlags & CLUSTER_CHECK_DIFFERENT_ATOMS)
clustering = rand(clusterMin, clusterMax)
for(var/atom/movable/M in range(clustering,T))
if(!(istype(M,atomPath)))
skipLoopIteration = TRUE
break
if(skipLoopIteration)
skipLoopIteration = FALSE
continue
//Success!
if(prob(spawnableAtoms[atomPath]))
new atomPath(T)
new atomPath (T)
. = 1
@@ -114,8 +71,6 @@
if(A.density)
. = 0
break
if(!allowAtomsOnSpace && (istype(T,/turf/space)))
. = 0
///////////////////////////////////////////////////////////
@@ -34,4 +34,4 @@
//Grass tufts with a high spawn chance
/datum/mapGeneratorModule/denseLayer/grassTufts
spawnableTurfs = list()
spawnableAtoms = list(/obj/structure/flora/ausbushes/grassybush = 75)
spawnableAtoms = list(/obj/structure/flora/ausbushes/grassybush = 75)
@@ -11,22 +11,14 @@ mapGenerator:
Desc: a mapGenerator is a master datum that collects
and syncs all mapGeneratorModules in it's modules list
defineRegion(var/turf/Start, var/turf/End, var/replace = 0)
Example: defineRegion(locate(1,1,1),locate(5,5,5),0)
defineRegion(var/list/startList, var/list/endList)
Example: defineRegion(locate(1,1,1),locate(5,5,5))
Desc: Sets the bounds of the mapGenerator's "map"
defineCircularRegion(var/turf/Start, var/turf/End, var/replace = 0)
Example: defineCircularRegion(locate(1,1,1),locate(5,5,5),0)
Desc: Sets the mapGenerator's "map" as a circle, with center in the middle of Start and End's X,Y,Z coordinates
undefineRegion()
Example: undefineRegion()
Desc: Empties the map generator list
checkRegion(var/turf/Start, var/turf/End)
Example: checkRegion(locate(1,1,1), locate(5,5,5))
Desc: Checks if a rectangle between Start's coords and End's coords is valid
Existing Calls: mapGenerator/defineRegion(), mapGenerator/defineCircularRegion()
Existing Calls: mapGenerator/defineRegion()
generate()
Example: generate()
@@ -116,6 +108,8 @@ Variable Breakdown (For Mappers):
mapGenerator
map - INTERNAL, do not touch
bottomLeft - INTERNAL, do not touch
topRight - INTERNAL, do not touch
modules - A list of typepaths of mapGeneratorModules
mapGeneratorModule
@@ -124,23 +118,13 @@ Variable Breakdown (For Mappers):
spawnableTurfs - A list of typepaths and their probability to spawn, eg: spawnableTurfs = list(/turf/unsimulated/floor/grass = 100)
clusterMax - The max range to check for something being "too close" for this atom/turf to spawn, the true value is random between clusterMin and clusterMax
clusterMin - The min range to check for something being "too close" for this atom/turf to spawn, the true value is random between clusterMin and clusterMax
clusterCheckFlags - A Bitfield that controls how the cluster checks work, All based on clusterMin and clusterMax guides
allowAtomsOnSpace - A Boolean for if we allow atoms to spawn on space tiles
clusterCheckFlags - A Bitfield that controls how the cluster checks work.
clusterCheckFlags flags:
CLUSTER_CHECK_NONE 0 //No checks are done, cluster as much as possible
CLUSTER_CHECK_DIFFERENT_TURFS 2 //Don't let turfs of DIFFERENT types cluster
CLUSTER_CHECK_DIFFERENT_ATOMS 4 //Don't let atoms of DIFFERENT types cluster
CLUSTER_CHECK_SAME_TURFS 8 //Don't let turfs of the SAME type cluster
CLUSTER_CHECK_SAME_ATOMS 16 //Don't let atoms of the SAME type cluster
CLUSTER_CHECK_SAMES 24 //Don't let any of the same type cluster
CLUSTER_CHECK_DIFFERENTS 6 //Don't let any different types cluster
CLUSTER_CHECK_ALL_TURFS 10 //Don't let ANY turfs cluster same and different types
CLUSTER_CHECK_ALL_ATOMS 20 //Don't let ANY atoms cluster same and different types
CLUSTER_CHECK_ALL 30 //Don't let anything cluster, like, at all
CLUSTER_CHECK_NONE 0 //No checks are done, cluster as much as possible
CLUSTER_CHECK_ATOMS 2 //Don't let atoms cluster, based on clusterMin and clusterMax as guides
CLUSTER_CHECK_TURFS 4 //Don't let turfs cluster, based on clusterMin and clusterMax as guides
CLUSTER_CHECK_ALL 6 //Don't let anything cluster, based on clusterMind and clusterMax as guides
*/
@@ -2,9 +2,9 @@
//Exists primarily as a test type.
/datum/mapGenerator/nature
modules = list(/datum/mapGeneratorModule/bottomLayer/grassTurfs, \
/datum/mapGeneratorModule/pineTrees, \
modules = list(/datum/mapGeneratorModule/pineTrees, \
/datum/mapGeneratorModule/deadTrees, \
/datum/mapGeneratorModule/randBushes, \
/datum/mapGeneratorModule/randRocks, \
/datum/mapGeneratorModule/bottomLayer/grassTurfs, \
/datum/mapGeneratorModule/denseLayer/grassTufts)
-2
View File
@@ -108,8 +108,6 @@
if(H.species.name == "Golem")
user << "\red Your metal fingers don't fit in the trigger guard!"
return
if(user.dna && user.dna.species == "Shadowling")
user << "<span class='danger'>The muzzle flash would cause damage to your form!</span>"
add_fingerprint(user)
+1 -2
View File
@@ -45,7 +45,6 @@
var/weaken = 0
var/paralyze = 0
var/irradiate = 0
var/slur = 0
var/stutter = 0
var/eyeblur = 0
var/drowsy = 0
@@ -80,7 +79,7 @@
if(!isliving(target)) return 0
if(isanimal(target)) return 0
var/mob/living/L = target
return L.apply_effects(stun, weaken, paralyze, irradiate, slur, stutter, eyeblur, drowsy, agony, blocked, stamina, jitter)
return L.apply_effects(stun, weaken, paralyze, irradiate, stutter, eyeblur, drowsy, agony, blocked, stamina, jitter)
proc/check_fire(var/mob/living/target as mob, var/mob/living/user as mob) //Checks if you can hit them or not.
if(!istype(target) || !istype(user))
@@ -12,8 +12,8 @@
/obj/item/projectile/change/proc/wabbajack (mob/M as mob in living_mob_list)
if(istype(M, /mob/living) && M.stat != DEAD)
if(M.notransform) return
M.notransform = 1
if(M.monkeyizing) return
M.monkeyizing = 1
M.canmove = 0
M.icon = null
M.overlays.Cut()
+2 -2
View File
@@ -127,8 +127,8 @@
proc/wabbajack(mob/living/M)
if(istype(M))
if(istype(M, /mob/living) && M.stat != DEAD)
if(M.notransform) return
M.notransform = 1
if(M.monkeyizing) return
M.monkeyizing = 1
M.canmove = 0
M.icon = null
M.overlays.Cut()
+1 -1
View File
@@ -63,7 +63,7 @@ datum
if(current_list_element > reagent_list.len) current_list_element = 1
var/datum/reagent/current_reagent = reagent_list[current_list_element]
src.remove_reagent(current_reagent.id, min(1, amount - total_transfered))
src.remove_reagent(current_reagent.id, 1)
current_list_element++
total_transfered++
+2 -2
View File
@@ -393,8 +393,8 @@ datum
if(!M) M = holder.my_atom
if(istype(M, /mob/living/carbon) && M.stat != DEAD)
M << "\red Your flesh rapidly mutates!"
if(M.notransform) return
M.notransform = 1
if(M.monkeyizing) return
M.monkeyizing = 1
M.canmove = 0
M.icon = null
M.overlays.Cut()
@@ -1,16 +1,11 @@
/obj/item/weapon/reagent_containers/food/drinks/cans
var canopened = 0
New()
..()
flags ^= OPENCONTAINER
attack_self(mob/user as mob)
if (canopened == 0)
playsound(src.loc,'sound/effects/canopen.ogg', rand(10,50), 1)
user << "<span class='notice'>You open the drink with an audible pop!</span>"
canopened = 1
flags |= OPENCONTAINER
else
return
@@ -18,19 +13,117 @@
if (canopened == 0)
user << "<span class='notice'>You need to open the drink!</span>"
return
return ..(M, user, def_zone)
var/datum/reagents/R = src.reagents
var/fillevel = gulp_size
if(!R.total_volume || !R)
user << "\red None of [src] left, oh no!"
return 0
if(M == user)
M << "\blue You swallow a gulp of [src]."
if(reagents.total_volume)
reagents.trans_to_ingest(M, gulp_size)
reagents.reaction(M, INGEST)
spawn(5)
reagents.trans_to(M, gulp_size)
playsound(M.loc,'sound/items/drink.ogg', rand(10,50), 1)
return 1
else if( istype(M, /mob/living/carbon/human) )
if (canopened == 0)
user << "<span class='notice'>You need to open the drink!</span>"
return
else if (canopened == 1)
for(var/mob/O in viewers(world.view, user))
O.show_message("\red [user] attempts to feed [M] [src].", 1)
if(!do_mob(user, M)) return
for(var/mob/O in viewers(world.view, user))
O.show_message("\red [user] feeds [M] [src].", 1)
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been fed [src.name] by [user.name] ([user.ckey]) Reagents: [reagentlist(src)]</font>")
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Fed [M.name] by [M.name] ([M.ckey]) Reagents: [reagentlist(src)]</font>")
msg_admin_attack("[key_name(user)][isAntag(user) ? "(ANTAG)" : ""] fed [key_name(M)] with [src.name] Reagents: [reagentlist(src)] (INTENT: [uppertext(user.a_intent)]) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
if(reagents.total_volume)
reagents.trans_to_ingest(M, gulp_size)
if(isrobot(user)) //Cyborg modules that include drinks automatically refill themselves, but drain the borg's cell
var/mob/living/silicon/robot/bro = user
bro.cell.use(30)
var/refill = R.get_master_reagent_id()
spawn(600)
R.add_reagent(refill, fillevel)
playsound(M.loc,'sound/items/drink.ogg', rand(10,50), 1)
return 1
return 0
afterattack(obj/target, mob/user, proximity)
if(!proximity) return
if(istype(target, /obj/structure/reagent_dispensers) && (canopened == 0))
user << "<span class='notice'>You need to open the drink!</span>"
return
else if(target.is_open_container() && (canopened == 0))
user << "<span class='notice'>You need to open the drink!</span>"
return
else
return ..(target, user, proximity)
if(istype(target, /obj/structure/reagent_dispensers)) //A dispenser. Transfer FROM it TO us.
if (canopened == 0)
user << "<span class='notice'>You need to open the drink!</span>"
return
if(!target.reagents.total_volume)
user << "\red [target] is empty."
return
if(reagents.total_volume >= reagents.maximum_volume)
user << "\red [src] is full."
return
var/trans = target.reagents.trans_to(src, target:amount_per_transfer_from_this)
user << "\blue You fill [src] with [trans] units of the contents of [target]."
else if(target.is_open_container()) //Something like a glass. Player probably wants to transfer TO it.
if (canopened == 0)
user << "<span class='notice'>You need to open the drink!</span>"
return
if (istype(target, /obj/item/weapon/reagent_containers/food/drinks/cans))
var/obj/item/weapon/reagent_containers/food/drinks/cans/cantarget = target
if(cantarget.canopened == 0)
user << "<span class='notice'>You need to open the drink you want to pour into!</span>"
return
if(!reagents.total_volume)
user << "\red [src] is empty."
return
if(target.reagents.total_volume >= target.reagents.maximum_volume)
user << "\red [target] is full."
return
var/datum/reagent/refill
var/datum/reagent/refillName
if(isrobot(user))
refill = reagents.get_master_reagent_id()
refillName = reagents.get_master_reagent_name()
var/trans = src.reagents.trans_to(target, amount_per_transfer_from_this)
user << "\blue You transfer [trans] units of the solution to [target]."
if(isrobot(user)) //Cyborg modules that include drinks automatically refill themselves, but drain the borg's cell
var/mob/living/silicon/robot/bro = user
var/chargeAmount = max(30,4*trans)
bro.cell.use(chargeAmount)
user << "Now synthesizing [trans] units of [refillName]..."
spawn(300)
reagents.add_reagent(refill, trans)
user << "Cyborg [src] refilled."
return
/* examine()
set src in view()
@@ -46,7 +46,7 @@
var/mob/living/carbon/human/H = M
if(H.species.flags & IS_SYNTHETIC)
user << "\red They have a monitor for a head, where do you think you're going to put that?"
H << "\red They have a monitor for a head, where do you think you're going to put that?"
return
for(var/mob/O in viewers(world.view, user))
@@ -84,13 +84,6 @@
afterattack(obj/target, mob/user, proximity)
if(!proximity) return
// Moved from the can code; not necessary since closed cans aren't open containers now, but, eh.
if (istype(target, /obj/item/weapon/reagent_containers/food/drinks/cans))
var/obj/item/weapon/reagent_containers/food/drinks/cans/cantarget = target
if(cantarget.canopened == 0)
user << "<span class='notice'>You need to open the drink you want to pour into!</span>"
return
if(istype(target, /obj/structure/reagent_dispensers)) //A dispenser. Transfer FROM it TO us.
if(!target.reagents.total_volume)
@@ -86,6 +86,7 @@
user << "\red There is already a blood sample in this syringe"
return
if(istype(target, /mob/living/carbon))//maybe just add a blood reagent to all mobs. Then you can suck them dry...With hundreds of syringes. Jolly good idea.
var/amount = src.reagents.maximum_volume - src.reagents.total_volume
var/mob/living/carbon/T = target
if(!T.dna)
usr << "You are unable to locate any blood. (To be specific, your target seems to be missing their DNA datum)"
@@ -111,11 +112,6 @@
if(!do_mob(user, target, time))
return
var/amount = src.reagents.maximum_volume - src.reagents.total_volume
if(amount == 0)
usr << "<span class='warning'>The syringe is full!</span>"
return
var/datum/reagent/B
if(istype(T,/mob/living/carbon/human))
var/mob/living/carbon/human/H = T
@@ -162,11 +158,6 @@
if(!target.is_open_container() && !ismob(target) && !istype(target, /obj/item/weapon/reagent_containers/food) && !istype(target, /obj/item/slime_extract) && !istype(target, /obj/item/clothing/mask/cigarette) && !istype(target, /obj/item/weapon/storage/fancy/cigarettes))
user << "\red You cannot directly fill this object."
return
if(istype(target, /obj/item/clothing/mask/cigarette))
var/obj/item/clothing/mask/cigarette/C = target
if(istype(C.loc, /obj/item/weapon/storage/fancy/cigarettes))
user << "\red You cannot inject a cigarette while it's still in the pack."
return
if(target.reagents.total_volume >= target.reagents.maximum_volume)
user << "\red [target] is full."
return
@@ -122,14 +122,6 @@
build_path = /obj/item/weapon/airlock_electronics
category = list("initial", "Electronics")
/datum/design/intercom_electronics
name = "Intercom Electronics"
id = "intercom_electronics"
build_type = AUTOLATHE
materials = list("$metal" = 50, "$glass" = 50)
build_path = /obj/item/weapon/intercom_electronics
category = list("initial", "Electronics")
/datum/design/console_screen
name = "Console Screen"
id = "console_screen"
@@ -92,14 +92,13 @@
reconnect_scanner()
if(owned_scanner)
var/artifact_in_use = 0
scanned_object = null
for(var/obj/O in owned_scanner.loc)
if(O == owned_scanner)
continue
if(O.invisibility)
continue
if(istype(O, /obj/machinery/artifact))
var/obj/machinery/artifact/A = O
if(istype(scanned_object, /obj/machinery/artifact))
var/obj/machinery/artifact/A = scanned_object
if(A.being_used)
artifact_in_use = 1
else