mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-25 06:00:16 +01:00
Carbon Dismemberment , second attempt. (#20461)
* - I rearranged X_defense.dm mob files, more damage_procs.dm.Here's what's inside: * X_defense.dm: is for the procs of attacks onto the mob, all the XXX_act() proc (things happening to the mob), as well as protection check and get procs (armor, ear prot, projectile dismemberment) * damage_procs.dm: actual damage procs like adjustBruteLoss() getfireloss, any proc that handles damaging. - some bugfixes with gibspawner effects. - monkey's bodyparts can be dismembered and are used to create its icon. - brains are no longer carbons. - all carbon have bodyparts that can be dropped when the mob is gibbed. - adminspawned bodyparts now have a default icon. - robotic parts are now a child of bodyparts. - health analyzer on alien/monkey shows damage on each limb - added admin option to add/remove bodyparts for all carbon (instead of just remove on humans) - Fixes keycheck message spam for janicart and all when trying to move. - Fixes bug with buckling to a scooter while limbless. - removed arg "hit_zone" in proj's on_hit() because we can already use the def_zone var (where hit_zone got its value) - Fixes mob not getting any damage when hit by a projectile on their missing limb, despite a hit message shown). carbon/apply_damage() now when we specify a def_zone and the corresponding BP is missing we default to the chest instead of stopping the proc. Consistently with how human/attacked_by() default to its attack to chest if missing limb. - Fixes mini uzi icon when empty and no mag (typo). - I renamed and changed a bit check_eye_prot and ear prot - renamed flash_eyes to flash_act() - I made a soundbang_act() similar to flash_act but for loud bangs. - added a gib and dust animation to larva. - husked monkeys - no damage overlay for husk or skeleton. - damage overlay for robotic limb now. - no damage overlay when organic bodypart husked. - one handed human with a bloody hand still get a bloody single hand overlay. - fix admin heal being unable to heal robotic bodyparts. - slightly touched robotic bodypart sprites (head one pixel too high) - Fixes 18532 "beheaded husk has hair". - Fixes 18584 "Ling stasis appearance bug" - no more eyes or lipstick on husks. - can remove flashes/wires/cells from robot chest and head with crowbar. - Fixes not being able to surgically amputate robotic arm/leg. * More merge conflict fixes and adding the new files I forgot to add. * of course I forgot birdstation * More typos and stuff I forgot to undo. * Fixing a typo in examine.dm Removing an unnecessary check. Making admin heal regenerate limbs on all carbons. Monkey-human transformation now transfer missing limbs info and presence of a cavity implant. NODISMEMBER species can still lack a limb if the mob lacked a limb and changed into that new species. Changeling Regenerate ability now also regenerate limbs when in monkey form. (and remove some cryptic useless code) * Fixing more conflicts with remie's multihands PR. * Fixes runtime with hud when calling build_hand_slots(). Fixes lightgeist healing not working. Fixes null.handle_fall() runtimes with pirate mobs. Fixes typo in has_left_hadn() and has_right_hand(). * Derp, forgot to remove debug message.
This commit is contained in:
@@ -5810,7 +5810,7 @@
|
||||
pixel_x = -5;
|
||||
pixel_y = -2
|
||||
},
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/plasteel/white{
|
||||
heat_capacity = 1e+006
|
||||
},
|
||||
|
||||
@@ -446,8 +446,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"abh" = (
|
||||
|
||||
@@ -1344,8 +1344,8 @@
|
||||
/area/turret_protected/aisat_interior)
|
||||
"acv" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/robot_suit,
|
||||
/obj/item/robot_parts/head,
|
||||
/obj/item/robot_suit,
|
||||
/obj/item/bodypart/head/robot,
|
||||
/obj/machinery/atmospherics/pipe/simple/supply/hidden,
|
||||
/turf/open/floor/bluegrid,
|
||||
/area/turret_protected/aisat_interior)
|
||||
@@ -1418,9 +1418,9 @@
|
||||
/area/turret_protected/aisat_interior)
|
||||
"acF" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/robot_parts/chest,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/obj/item/bodypart/chest/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/obj/structure/cable/blue{
|
||||
tag = "icon-2-8";
|
||||
icon_state = "2-8"
|
||||
@@ -1443,7 +1443,7 @@
|
||||
/area/turret_protected/aisat_interior)
|
||||
"acI" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/structure/cable/blue{
|
||||
tag = "icon-2-4";
|
||||
icon_state = "2-4"
|
||||
@@ -1511,7 +1511,7 @@
|
||||
},
|
||||
/obj/machinery/atmospherics/pipe/manifold/scrubbers/hidden,
|
||||
/obj/item/device/assembly/flash/handheld,
|
||||
/obj/item/robot_parts/r_leg,
|
||||
/obj/item/bodypart/r_leg/robot,
|
||||
/turf/open/floor/plasteel/black,
|
||||
/area/turret_protected/aisat_interior)
|
||||
"acP" = (
|
||||
@@ -1575,7 +1575,7 @@
|
||||
/area/turret_protected/aisat_interior)
|
||||
"acU" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/l_leg,
|
||||
/obj/item/bodypart/l_leg/robot,
|
||||
/obj/structure/cable/blue{
|
||||
tag = "icon-4-8";
|
||||
icon_state = "4-8"
|
||||
@@ -3189,8 +3189,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"agA" = (
|
||||
@@ -16264,7 +16264,7 @@
|
||||
/area/maintenance/fore)
|
||||
"aIo" = (
|
||||
/obj/structure/rack,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/obj/item/stack/sheet/metal{
|
||||
amount = 2
|
||||
},
|
||||
@@ -17026,7 +17026,7 @@
|
||||
"aJN" = (
|
||||
/obj/structure/table,
|
||||
/obj/item/stack/cable_coil/green,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/obj/item/weapon/storage/fancy/cigarettes/cigpack_robustgold,
|
||||
/obj/item/weapon/reagent_containers/food/drinks/mug/coco,
|
||||
/turf/open/floor/plating,
|
||||
@@ -18024,7 +18024,7 @@
|
||||
/area/maintenance/port)
|
||||
"aMb" = (
|
||||
/obj/effect/spawner/lootdrop/maintenance,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/plating,
|
||||
/area/maintenance/port)
|
||||
"aMc" = (
|
||||
@@ -63145,7 +63145,7 @@
|
||||
/turf/open/floor/plating,
|
||||
/area/maintenance/apmaint)
|
||||
"cvz" = (
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/obj/structure/closet,
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/large,
|
||||
/obj/effect/spawner/lootdrop/maintenance,
|
||||
|
||||
@@ -3505,8 +3505,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"agJ" = (
|
||||
|
||||
@@ -55774,12 +55774,12 @@
|
||||
d2 = 2;
|
||||
icon_state = "1-2"
|
||||
},
|
||||
/obj/item/robot_parts/chest{
|
||||
/obj/item/bodypart/chest/robot{
|
||||
name = "cyborg torso";
|
||||
pixel_x = -2;
|
||||
pixel_y = 2
|
||||
},
|
||||
/obj/item/robot_parts/head{
|
||||
/obj/item/bodypart/head/robot{
|
||||
name = "cyborg head";
|
||||
pixel_x = 3;
|
||||
pixel_y = 2
|
||||
@@ -90220,8 +90220,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"cYu" = (
|
||||
|
||||
@@ -14145,8 +14145,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"Gv" = (
|
||||
|
||||
@@ -54091,8 +54091,8 @@
|
||||
dir = 1
|
||||
},
|
||||
/obj/structure/table,
|
||||
/obj/item/robot_parts/r_arm,
|
||||
/obj/item/robot_parts/l_arm,
|
||||
/obj/item/bodypart/r_arm/robot,
|
||||
/obj/item/bodypart/l_arm/robot,
|
||||
/turf/open/floor/mineral/titanium,
|
||||
/area/shuttle/syndicate)
|
||||
"coo" = (
|
||||
|
||||
@@ -84,6 +84,14 @@
|
||||
#define ORGAN_ORGANIC 1
|
||||
#define ORGAN_ROBOTIC 2
|
||||
|
||||
#define BODYPART_ORGANIC 1
|
||||
#define BODYPART_ROBOTIC 2
|
||||
|
||||
#define MONKEY_BODYPART "monkey"
|
||||
#define ALIEN_BODYPART "alien"
|
||||
#define LARVA_BODYPART "larva"
|
||||
#define DEVIL_BODYPART "devil"
|
||||
|
||||
//Nutrition levels for humans. No idea where else to put it
|
||||
#define NUTRITION_LEVEL_FAT 600
|
||||
#define NUTRITION_LEVEL_FULL 550
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
#define ismonkey(A) (istype(A, /mob/living/carbon/monkey))
|
||||
|
||||
#define isbrain(A) (istype(A, /mob/living/carbon/brain))
|
||||
#define isbrain(A) (istype(A, /mob/living/brain))
|
||||
|
||||
#define isalien(A) (istype(A, /mob/living/carbon/alien))
|
||||
|
||||
|
||||
@@ -337,7 +337,7 @@ Turf and target are seperate in case you want to teleport some distance from a t
|
||||
moblist.Add(M)
|
||||
for(var/mob/living/carbon/human/M in sortmob)
|
||||
moblist.Add(M)
|
||||
for(var/mob/living/carbon/brain/M in sortmob)
|
||||
for(var/mob/living/brain/M in sortmob)
|
||||
moblist.Add(M)
|
||||
for(var/mob/living/carbon/alien/M in sortmob)
|
||||
moblist.Add(M)
|
||||
|
||||
@@ -60,3 +60,12 @@
|
||||
for(var/obj/item/I in D.held_items)
|
||||
I.screen_loc = null
|
||||
D.client.screen -= I
|
||||
|
||||
|
||||
//Dextrous simple mobs can use hands!
|
||||
/mob/living/simple_animal/create_mob_hud()
|
||||
if(client && !hud_used)
|
||||
if(dextrous)
|
||||
hud_used = new dextrous_hud_type(src, ui_style2icon(client.prefs.UI_style))
|
||||
else
|
||||
..()
|
||||
|
||||
@@ -241,5 +241,5 @@
|
||||
i++
|
||||
for(var/obj/screen/human/equip/E in static_inventory)
|
||||
E.screen_loc = ui_equip_position(mymob)
|
||||
|
||||
show_hud(HUD_STYLE_STANDARD,mymob)
|
||||
if(mymob.hud_used)
|
||||
show_hud(HUD_STYLE_STANDARD,mymob)
|
||||
@@ -358,7 +358,6 @@
|
||||
var/mob/living/carbon/human/H = mymob
|
||||
|
||||
var/mob/screenmob = viewer || H
|
||||
|
||||
if(screenmob.hud_used.hud_shown)
|
||||
if(H.s_store)
|
||||
H.s_store.screen_loc = ui_sstore1
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
mymob.client.screen = list()
|
||||
mymob.client.screen += mymob.client.void
|
||||
|
||||
/mob/living/carbon/brain/create_mob_hud()
|
||||
/mob/living/brain/create_mob_hud()
|
||||
if(client && !hud_used)
|
||||
hud_used = new /datum/hud/brain(src)
|
||||
|
||||
|
||||
@@ -34,6 +34,8 @@
|
||||
user.lastattacked = M
|
||||
M.lastattacker = user
|
||||
|
||||
if(user != M)
|
||||
user.do_attack_animation(M)
|
||||
M.attacked_by(src, user)
|
||||
|
||||
add_logs(user, M, "attacked", src.name, "(INTENT: [uppertext(user.a_intent)]) (DAMTYPE: [uppertext(damtype)])")
|
||||
@@ -58,19 +60,27 @@
|
||||
user.visible_message("<span class='danger'>[user] has hit [src] with [I]!</span>", "<span class='danger'>You hit [src] with [I]!</span>")
|
||||
|
||||
/mob/living/attacked_by(obj/item/I, mob/living/user)
|
||||
if(user != src)
|
||||
user.do_attack_animation(src)
|
||||
if(send_item_attack_message(I, user))
|
||||
if(apply_damage(I.force, I.damtype))
|
||||
if(I.damtype == BRUTE)
|
||||
if(prob(33))
|
||||
I.add_mob_blood(src)
|
||||
var/turf/location = get_turf(src)
|
||||
add_splatter_floor(location)
|
||||
if(get_dist(user, src) <= 1) //people with TK won't get smeared with blood
|
||||
user.add_mob_blood(src)
|
||||
return TRUE
|
||||
send_item_attack_message(I, user)
|
||||
if(I.force)
|
||||
apply_damage(I.force, I.damtype)
|
||||
if(I.damtype == BRUTE)
|
||||
if(prob(33))
|
||||
I.add_mob_blood(src)
|
||||
var/turf/location = get_turf(src)
|
||||
add_splatter_floor(location)
|
||||
if(get_dist(user, src) <= 1) //people with TK won't get smeared with blood
|
||||
user.add_mob_blood(src)
|
||||
return TRUE //successful attack
|
||||
|
||||
/mob/living/simple_animal/attacked_by(obj/item/I, mob/living/user)
|
||||
if(!I.force)
|
||||
user.visible_message("<span class='warning'>[user] gently taps [src] with [I].</span>",\
|
||||
"<span class='warning'>This weapon is ineffective, it does no damage!</span>")
|
||||
else if(I.force < force_threshold || I.damtype == STAMINA)
|
||||
visible_message("<span class='warning'>[I] bounces harmlessly off of [src].</span>",\
|
||||
"<span class='warning'>[I] bounces harmlessly off of [src]!</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
// Proximity_flag is 1 if this afterattack was called on something adjacent, in your square, or on your person.
|
||||
// Click parameters is the params string from byond Click() code, see that documentation.
|
||||
@@ -90,7 +100,7 @@
|
||||
if(I.attack_verb && I.attack_verb.len)
|
||||
message_verb = "[pick(I.attack_verb)]"
|
||||
else if(!I.force)
|
||||
return 0
|
||||
return
|
||||
var/message_hit_area = ""
|
||||
if(hit_area)
|
||||
message_hit_area = " in the [hit_area]"
|
||||
@@ -102,12 +112,3 @@
|
||||
"<span class='userdanger'>[attack_message]</span>")
|
||||
return 1
|
||||
|
||||
/mob/living/simple_animal/send_item_attack_message(obj/item/I, mob/living/user, hit_area)
|
||||
if(!I.force)
|
||||
user.visible_message("<span class='warning'>[user] gently taps [src] with [I].</span>",\
|
||||
"<span class='warning'>This weapon is ineffective, it does no damage!</span>")
|
||||
else if(I.force < force_threshold || I.damtype == STAMINA)
|
||||
visible_message("<span class='warning'>[I] bounces harmlessly off of [src].</span>",\
|
||||
"<span class='warning'>[I] bounces harmlessly off of [src]!</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
@@ -50,9 +50,8 @@
|
||||
for(var/datum/mutation/human/HM in dna.mutations)
|
||||
HM.on_ranged_attack(src, A)
|
||||
|
||||
var/turf/T = A
|
||||
if(istype(T) && get_dist(src,T) <= 1)
|
||||
src.Move_Pulled(T)
|
||||
if(isturf(A) && get_dist(src,A) <= 1)
|
||||
src.Move_Pulled(A)
|
||||
|
||||
/*
|
||||
Animals & All Unspecified
|
||||
@@ -111,7 +110,7 @@
|
||||
*/
|
||||
/mob/living/carbon/alien/UnarmedAttack(atom/A)
|
||||
A.attack_alien(src)
|
||||
/atom/proc/attack_alien(mob/user)
|
||||
/atom/proc/attack_alien(mob/living/carbon/alien/user)
|
||||
attack_paw(user)
|
||||
return
|
||||
/mob/living/carbon/alien/RestrainedClickOn(atom/A)
|
||||
@@ -135,6 +134,68 @@
|
||||
/mob/living/simple_animal/slime/RestrainedClickOn(atom/A)
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
Drones
|
||||
*/
|
||||
/mob/living/simple_animal/drone/UnarmedAttack(atom/A)
|
||||
A.attack_drone(src)
|
||||
|
||||
/atom/proc/attack_drone(mob/living/simple_animal/drone/user)
|
||||
attack_hand(user) //defaults to attack_hand. Override it when you don't want drones to do same stuff as humans.
|
||||
|
||||
/mob/living/simple_animal/slime/RestrainedClickOn(atom/A)
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
True Devil
|
||||
*/
|
||||
|
||||
/mob/living/carbon/true_devil/UnarmedAttack(atom/A, proximity)
|
||||
A.attack_hand(src)
|
||||
|
||||
/*
|
||||
Brain
|
||||
*/
|
||||
|
||||
/mob/living/brain/UnarmedAttack(atom/A)//Stops runtimes due to attack_animal being the default
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
pAI
|
||||
*/
|
||||
|
||||
/mob/living/silicon/pai/UnarmedAttack(atom/A)//Stops runtimes due to attack_animal being the default
|
||||
return
|
||||
|
||||
|
||||
/*
|
||||
Simple animals
|
||||
*/
|
||||
|
||||
/mob/living/simple_animal/UnarmedAttack(atom/A, proximity)
|
||||
if(!dextrous)
|
||||
return ..()
|
||||
if(!ismob(A))
|
||||
A.attack_hand(src)
|
||||
update_inv_hands()
|
||||
|
||||
|
||||
/*
|
||||
Hostile animals
|
||||
*/
|
||||
|
||||
/mob/living/simple_animal/hostile/UnarmedAttack(atom/A)
|
||||
target = A
|
||||
if(dextrous && !is_type_in_typecache(A, environment_target_typecache) && !ismob(A))
|
||||
..()
|
||||
else
|
||||
AttackingTarget()
|
||||
|
||||
|
||||
|
||||
/*
|
||||
New Players:
|
||||
Have no reason to click on anything at all.
|
||||
|
||||
+37
-10
@@ -279,11 +279,11 @@ var/global/list/internal_byond_list_vars = list("contents" = TRUE, "verbs" = TRU
|
||||
if(iscarbon(D))
|
||||
body += "<option value>---</option>"
|
||||
body += "<option value='?_src_=vars;editorgans=\ref[D]'>Modify organs</option>"
|
||||
body += "<option value='?_src_=vars;editbodypart=\ref[D]'>Modify bodypart</option>"
|
||||
body += "<option value='?_src_=vars;makeai=\ref[D]'>Make AI</option>"
|
||||
if(ishuman(D))
|
||||
body += "<option value='?_src_=vars;makemonkey=\ref[D]'>Make monkey</option>"
|
||||
body += "<option value='?_src_=vars;setspecies=\ref[D]'>Set Species</option>"
|
||||
body += "<option value='?_src_=vars;removebodypart=\ref[D]'>Remove Body Part</option>"
|
||||
body += "<option value='?_src_=vars;makerobot=\ref[D]'>Make cyborg</option>"
|
||||
body += "<option value='?_src_=vars;makealien=\ref[D]'>Make alien</option>"
|
||||
body += "<option value='?_src_=vars;makeslime=\ref[D]'>Make slime</option>"
|
||||
@@ -898,25 +898,51 @@ body
|
||||
var/newtype = species_list[result]
|
||||
H.set_species(newtype)
|
||||
|
||||
else if(href_list["removebodypart"])
|
||||
else if(href_list["editbodypart"])
|
||||
if(!check_rights(R_SPAWN))
|
||||
return
|
||||
|
||||
var/mob/living/carbon/human/H = locate(href_list["removebodypart"])
|
||||
if(!istype(H))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon/human"
|
||||
var/mob/living/carbon/C = locate(href_list["editbodypart"])
|
||||
if(!istype(C))
|
||||
usr << "This can only be done to instances of type /mob/living/carbon"
|
||||
return
|
||||
|
||||
var/result = input(usr, "Please choose which body part to remove","Remove Body Part") as null|anything in list("head", "l_arm", "r_arm", "l_leg", "r_leg")
|
||||
var/edit_action = input(usr, "What would you like to do?","Modify Body Part") as null|anything in list("add","remove", "augment")
|
||||
if(!edit_action)
|
||||
return
|
||||
var/list/limb_list = list("head", "l_arm", "r_arm", "l_leg", "r_leg")
|
||||
if(edit_action == "augment")
|
||||
limb_list += "chest"
|
||||
var/result = input(usr, "Please choose which body part to [edit_action]","[capitalize(edit_action)] Body Part") as null|anything in limb_list
|
||||
|
||||
if(!H)
|
||||
if(!C)
|
||||
usr << "Mob doesn't exist anymore"
|
||||
return
|
||||
|
||||
if(result)
|
||||
var/obj/item/bodypart/BP = H.get_bodypart(result)
|
||||
if(BP)
|
||||
BP.drop_limb()
|
||||
var/obj/item/bodypart/BP = C.get_bodypart(result)
|
||||
switch(edit_action)
|
||||
if("remove")
|
||||
if(BP)
|
||||
BP.drop_limb()
|
||||
else
|
||||
usr << "[C] doesn't have such bodypart."
|
||||
if("add")
|
||||
if(BP)
|
||||
usr << "[C] already has such bodypart."
|
||||
else
|
||||
if(!C.regenerate_limb(result))
|
||||
usr << "[C] cannot have such bodypart."
|
||||
if("augment")
|
||||
if(ishuman(C))
|
||||
if(BP)
|
||||
BP.change_bodypart_status(BODYPART_ROBOTIC, 1)
|
||||
else
|
||||
usr << "[C] doesn't have such bodypart."
|
||||
else
|
||||
usr << "Only humans can be augmented."
|
||||
|
||||
|
||||
|
||||
else if(href_list["purrbation"])
|
||||
if(!check_rights(R_SPAWN))
|
||||
@@ -985,3 +1011,4 @@ body
|
||||
log_admin("[key_name(usr)] dealt [amount] amount of [Text] damage to [L] ")
|
||||
message_admins("<span class='notice'>[key_name(usr)] dealt [amount] amount of [Text] damage to [L] </span>")
|
||||
href_list["datumrefresh"] = href_list["mobToDamage"]
|
||||
|
||||
|
||||
@@ -33,30 +33,19 @@ Bonus
|
||||
Convert(M)
|
||||
return
|
||||
|
||||
/datum/symptom/damage_converter/proc/Convert(mob/living/M)
|
||||
/datum/symptom/damage_converter/proc/Convert(mob/living/carbon/C)
|
||||
|
||||
var/get_damage = rand(1, 2)
|
||||
var/heal_amt = rand(1, 2)
|
||||
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/list/parts = C.get_damaged_bodyparts(1,1) //1,1 because it needs inputs.
|
||||
|
||||
var/list/parts = H.get_damaged_bodyparts(1,1) //1,1 because it needs inputs.
|
||||
|
||||
if(!parts.len)
|
||||
return
|
||||
|
||||
for(var/obj/item/bodypart/L in parts)
|
||||
L.heal_damage(get_damage, get_damage, 0)
|
||||
M.adjustToxLoss(get_damage*parts.len)
|
||||
|
||||
else
|
||||
if(M.getFireLoss() > 0 || M.getBruteLoss() > 0)
|
||||
M.adjustFireLoss(-get_damage)
|
||||
M.adjustBruteLoss(-get_damage)
|
||||
M.adjustToxLoss(get_damage)
|
||||
else
|
||||
return
|
||||
if(!parts.len)
|
||||
return
|
||||
|
||||
for(var/obj/item/bodypart/L in parts)
|
||||
if(L.heal_damage(heal_amt, heal_amt))
|
||||
C.update_damage_overlays()
|
||||
C.adjustToxLoss(heal_amt*parts.len)
|
||||
return 1
|
||||
|
||||
/*
|
||||
|
||||
@@ -30,14 +30,14 @@ Bonus
|
||||
/datum/symptom/genetic_mutation/Activate(datum/disease/advance/A)
|
||||
..()
|
||||
if(prob(SYMPTOM_ACTIVATION_PROB * 5)) // 15% chance
|
||||
var/mob/living/carbon/M = A.affected_mob
|
||||
if(!M.has_dna())
|
||||
var/mob/living/carbon/C = A.affected_mob
|
||||
if(!C.has_dna())
|
||||
return
|
||||
switch(A.stage)
|
||||
if(4, 5)
|
||||
M << "<span class='warning'>[pick("Your skin feels itchy.", "You feel light headed.")]</span>"
|
||||
M.dna.remove_mutation_group(possible_mutations)
|
||||
randmut(M, possible_mutations)
|
||||
C << "<span class='warning'>[pick("Your skin feels itchy.", "You feel light headed.")]</span>"
|
||||
C.dna.remove_mutation_group(possible_mutations)
|
||||
C.randmut(possible_mutations)
|
||||
return
|
||||
|
||||
// Archive their DNA before they were infected.
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your muscles ache.</span>"
|
||||
if(prob(20))
|
||||
affected_mob.take_organ_damage(1)
|
||||
affected_mob.take_bodypart_damage(1)
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your stomach hurts.</span>"
|
||||
if(prob(20))
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your muscles ache.</span>"
|
||||
if(prob(20))
|
||||
affected_mob.take_organ_damage(1)
|
||||
affected_mob.take_bodypart_damage(1)
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your stomach hurts.</span>"
|
||||
if(prob(20))
|
||||
@@ -45,7 +45,7 @@
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your muscles ache.</span>"
|
||||
if(prob(20))
|
||||
affected_mob.take_organ_damage(1)
|
||||
affected_mob.take_bodypart_damage(1)
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>Your stomach hurts.</span>"
|
||||
if(prob(20))
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
affected_mob.emote("cough")
|
||||
if(prob(1))
|
||||
affected_mob << "<span class='danger'>You're burning in your own skin!</span>"
|
||||
affected_mob.take_organ_damage(0,5)
|
||||
affected_mob.take_bodypart_damage(0,5)
|
||||
|
||||
if(3)
|
||||
affected_mob.bodytemperature += 20
|
||||
@@ -32,5 +32,5 @@
|
||||
affected_mob.emote("cough")
|
||||
if(prob(5))
|
||||
affected_mob << "<span class='danger'>You're burning in your own skin!</span>"
|
||||
affected_mob.take_organ_damage(0,5)
|
||||
affected_mob.take_bodypart_damage(0,5)
|
||||
return
|
||||
|
||||
+51
-27
@@ -11,13 +11,15 @@
|
||||
var/list/mutations = list() //All mutations are from now on here
|
||||
var/list/temporary_mutations = list() //Timers for temporary mutations
|
||||
var/list/previous = list() //For temporary name/ui/ue/blood_type modifications
|
||||
var/mob/living/carbon/holder
|
||||
var/mob/living/holder
|
||||
|
||||
/datum/dna/New(mob/living/carbon/new_holder)
|
||||
/datum/dna/New(mob/living/new_holder)
|
||||
if(new_holder)
|
||||
holder = new_holder
|
||||
|
||||
/datum/dna/proc/transfer_identity(mob/living/carbon/destination, transfer_SE = 0)
|
||||
if(!istype(destination))
|
||||
return
|
||||
destination.dna.unique_enzymes = unique_enzymes
|
||||
destination.dna.uni_identity = uni_identity
|
||||
destination.dna.blood_type = blood_type
|
||||
@@ -166,12 +168,36 @@
|
||||
features = random_features()
|
||||
|
||||
|
||||
/datum/dna/stored //subtype used by brain mob's stored_dna
|
||||
|
||||
/datum/dna/stored/add_mutation(mutation_name) //no mutation changes on stored dna.
|
||||
return
|
||||
|
||||
/datum/dna/stored/remove_mutation(mutation_name)
|
||||
return
|
||||
|
||||
/datum/dna/stored/check_mutation(mutation_name)
|
||||
return
|
||||
|
||||
/datum/dna/stored/remove_all_mutations()
|
||||
return
|
||||
|
||||
/datum/dna/stored/remove_mutation_group(list/group)
|
||||
return
|
||||
|
||||
/////////////////////////// DNA MOB-PROCS //////////////////////
|
||||
|
||||
/mob/proc/set_species(datum/species/mrace, icon_update = 1)
|
||||
return
|
||||
|
||||
/mob/living/brain/set_species(datum/species/mrace, icon_update = 1)
|
||||
if(mrace)
|
||||
if(ispath(mrace))
|
||||
stored_dna.species = new mrace()
|
||||
else
|
||||
stored_dna.species = mrace //not calling any species update procs since we're a brain, not a monkey/human
|
||||
|
||||
|
||||
/mob/living/carbon/set_species(datum/species/mrace, icon_update = 1)
|
||||
if(mrace && has_dna())
|
||||
dna.species.on_species_loss(src)
|
||||
@@ -290,48 +316,46 @@ mob/living/carbon/human/updateappearance(icon_update=1, mutcolor_update=0, mutat
|
||||
return 0
|
||||
return getleftblocks(istring, blocknumber, blocksize) + replacement + getrightblocks(istring, blocknumber, blocksize)
|
||||
|
||||
/proc/randmut(mob/living/carbon/M, list/candidates, difficulty = 2)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/randmut(list/candidates, difficulty = 2)
|
||||
if(!has_dna())
|
||||
return
|
||||
var/datum/mutation/human/num = pick(candidates)
|
||||
. = num.force_give(M)
|
||||
return
|
||||
. = num.force_give(src)
|
||||
|
||||
/proc/randmutb(mob/living/carbon/M)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/randmutb()
|
||||
if(!has_dna())
|
||||
return
|
||||
var/datum/mutation/human/HM = pick((bad_mutations | not_good_mutations) - mutations_list[RACEMUT])
|
||||
. = HM.force_give(M)
|
||||
. = HM.force_give(src)
|
||||
|
||||
/proc/randmutg(mob/living/carbon/M)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/randmutg()
|
||||
if(!has_dna())
|
||||
return
|
||||
var/datum/mutation/human/HM = pick(good_mutations)
|
||||
. = HM.force_give(M)
|
||||
. = HM.force_give(src)
|
||||
|
||||
/proc/randmutvg(mob/living/carbon/M)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/randmutvg()
|
||||
if(!has_dna())
|
||||
return
|
||||
var/datum/mutation/human/HM = pick((good_mutations) - mutations_list[HULK] - mutations_list[DWARFISM])
|
||||
. = HM.force_give(M)
|
||||
. = HM.force_give(src)
|
||||
|
||||
/proc/randmuti(mob/living/carbon/M)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/randmuti()
|
||||
if(!has_dna())
|
||||
return
|
||||
var/num = rand(1, DNA_UNI_IDENTITY_BLOCKS)
|
||||
var/newdna = setblock(M.dna.uni_identity, num, random_string(DNA_BLOCK_SIZE, hex_characters))
|
||||
M.dna.uni_identity = newdna
|
||||
M.updateappearance(mutations_overlay_update=1)
|
||||
return
|
||||
var/newdna = setblock(dna.uni_identity, num, random_string(DNA_BLOCK_SIZE, hex_characters))
|
||||
dna.uni_identity = newdna
|
||||
updateappearance(mutations_overlay_update=1)
|
||||
|
||||
/proc/clean_dna(mob/living/carbon/M)
|
||||
if(!M.has_dna())
|
||||
/mob/living/carbon/proc/clean_dna()
|
||||
if(!has_dna())
|
||||
return
|
||||
M.dna.remove_all_mutations()
|
||||
dna.remove_all_mutations()
|
||||
|
||||
/proc/clean_randmut(mob/living/carbon/M, list/candidates, difficulty = 2)
|
||||
clean_dna(M)
|
||||
randmut(M, candidates, difficulty)
|
||||
/mob/living/carbon/proc/clean_randmut(list/candidates, difficulty = 2)
|
||||
clean_dna()
|
||||
randmut(candidates, difficulty)
|
||||
|
||||
/proc/scramble_dna(mob/living/carbon/M, ui=FALSE, se=FALSE, probability)
|
||||
if(!M.has_dna())
|
||||
|
||||
@@ -482,7 +482,7 @@
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.apply_damage(2*force, BRUTE, "head")
|
||||
else
|
||||
user.take_organ_damage(2*force)
|
||||
user.take_bodypart_damage(2*force)
|
||||
return
|
||||
if(isrobot(target))
|
||||
return ..()
|
||||
|
||||
@@ -187,7 +187,7 @@
|
||||
/datum/mutation/human/cold_resistance/on_life(mob/living/carbon/human/owner)
|
||||
if(owner.getFireLoss())
|
||||
if(prob(1))
|
||||
owner.heal_organ_damage(0,1) //Is this really needed?
|
||||
owner.heal_bodypart_damage(0,1) //Is this really needed?
|
||||
|
||||
/datum/mutation/human/x_ray
|
||||
|
||||
@@ -252,11 +252,11 @@
|
||||
var/mob/new_mob
|
||||
if(prob(95))
|
||||
if(prob(50))
|
||||
new_mob = randmutb(owner)
|
||||
new_mob = owner.randmutb()
|
||||
else
|
||||
new_mob = randmuti(owner)
|
||||
new_mob = owner.randmuti()
|
||||
else
|
||||
new_mob = randmutg(owner)
|
||||
new_mob = owner.randmutg()
|
||||
if(new_mob && ismob(new_mob))
|
||||
owner = new_mob
|
||||
. = owner
|
||||
|
||||
@@ -150,15 +150,14 @@
|
||||
if(H.dna && H.dna.species)
|
||||
if(!(RADIMMUNE in H.dna.species.specflags))
|
||||
if(prob(max(0,100-resist)))
|
||||
randmuti(H)
|
||||
H.randmuti()
|
||||
if(prob(50))
|
||||
if(prob(90))
|
||||
randmutb(H)
|
||||
H.randmutb()
|
||||
else
|
||||
randmutg(H)
|
||||
H.randmutg()
|
||||
H.domutcheck()
|
||||
L.rad_act(20,1)
|
||||
|
||||
/datum/weather/rad_storm/end()
|
||||
if(..())
|
||||
return
|
||||
|
||||
@@ -146,7 +146,7 @@
|
||||
reset_perspective(destination)
|
||||
update_canmove() //if the mob was asleep inside a container and then got forceMoved out we need to make them fall.
|
||||
|
||||
/mob/living/carbon/brain/forceMove(atom/destination)
|
||||
/mob/living/brain/forceMove(atom/destination)
|
||||
if(container)
|
||||
container.forceMove(destination)
|
||||
else //something went very wrong.
|
||||
|
||||
@@ -13,21 +13,20 @@
|
||||
/obj/effect/proc_holder/changeling/regenerate/sting_action(mob/living/user)
|
||||
user << "<span class='notice'>You feel an itching, both inside and \
|
||||
outside as your tissues knit and reknit.</span>"
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.restore_blood()
|
||||
H.remove_all_embedded_objects()
|
||||
var/list/missing = H.get_missing_limbs()
|
||||
if(iscarbon(user))
|
||||
var/mob/living/carbon/C = user
|
||||
var/list/missing = C.get_missing_limbs()
|
||||
if(missing.len)
|
||||
playsound(user, 'sound/magic/Demon_consume.ogg', 50, 1)
|
||||
H.visible_message("<span class='warning'>[user]'s missing limbs \
|
||||
C.visible_message("<span class='warning'>[user]'s missing limbs \
|
||||
reform, making a loud, grotesque sound!</span>",
|
||||
"<span class='userdanger'>Your limbs regrow, making a \
|
||||
loud, crunchy sound and giving you great pain!</span>",
|
||||
"<span class='italics'>You hear organic matter ripping \
|
||||
and tearing!</span>")
|
||||
H.emote("scream")
|
||||
H.regenerate_limbs(1)
|
||||
|
||||
CHECK_DNA_AND_SPECIES(H)
|
||||
H.dna.species.on_species_gain(H, H.dna.species)
|
||||
C.emote("scream")
|
||||
C.regenerate_limbs(1)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.restore_blood()
|
||||
H.remove_all_embedded_objects()
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
break
|
||||
|
||||
stacks++
|
||||
//user.take_organ_damage(stacks * 0.03, 0)
|
||||
//user.take_bodypart_damage(stacks * 0.03, 0)
|
||||
user.staminaloss += stacks * 1.3 //At first the changeling may regenerate stamina fast enough to nullify fatigue, but it will stack
|
||||
|
||||
if(stacks == 11) //Warning message that the stacks are getting too high
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
var/mob/living/carbon/C = target
|
||||
if(C.status_flags & CANWEAKEN)
|
||||
C.do_jitter_animation(500)
|
||||
C.take_organ_damage(20, 0) //The process is extremely painful
|
||||
C.take_bodypart_damage(20, 0) //The process is extremely painful
|
||||
|
||||
target.visible_message("<span class='danger'>[target] begins to violenty convulse!</span>","<span class='userdanger'>You feel a tiny prick and a begin to uncontrollably convulse!</span>")
|
||||
spawn(10)
|
||||
|
||||
@@ -546,10 +546,12 @@ Judgement: 10 servants, 100 CV, and any existing AIs are converted or destroyed
|
||||
var/mob/living/carbon/human/H = invoker
|
||||
for(var/X in H.bodyparts)
|
||||
var/obj/item/bodypart/BP = X
|
||||
if(ratvar_awakens || BP.status == ORGAN_ROBOTIC && total_power_drained < augument_damage_threshhold) //if ratvar is alive, it won't damage and will always heal augumented limbs
|
||||
BP.heal_damage(power_damage, power_damage, 1) //heals one point of burn and brute for every ~100W drained on augumented limbs
|
||||
if(ratvar_awakens || BP.status == BODYPART_ROBOTIC && total_power_drained < augument_damage_threshhold) //if ratvar is alive, it won't damage and will always heal augumented limbs
|
||||
if(BP.heal_damage(power_damage, power_damage, 1, 0)) //heals one point of burn and brute for every ~100W drained on augumented limbs
|
||||
H.update_damage_overlays()
|
||||
else
|
||||
BP.take_damage(0, power_damage)
|
||||
if(BP.take_damage(0, power_damage))
|
||||
H.update_damage_overlays()
|
||||
else if(isanimal(invoker))
|
||||
var/mob/living/simple_animal/A = invoker
|
||||
A.adjustHealth(-power_damage) //if a simple animal is using volt void, just heal it
|
||||
|
||||
@@ -711,10 +711,10 @@
|
||||
color = "#FAE48C"
|
||||
|
||||
/obj/effect/clockwork/sigil/transgression/sigil_effects(mob/living/L)
|
||||
var/target_flashed = L.flash_eyes()
|
||||
var/target_flashed = L.flash_act()
|
||||
for(var/mob/living/M in viewers(5, src))
|
||||
if(!is_servant_of_ratvar(M) && M != L)
|
||||
M.flash_eyes()
|
||||
M.flash_act()
|
||||
if(iscultist(L))
|
||||
L << "<span class='heavy_brass'>\"Watch your step, wretch.\"</span>"
|
||||
L.adjustBruteLoss(10)
|
||||
|
||||
@@ -150,7 +150,6 @@
|
||||
return 0
|
||||
else
|
||||
mob << "<span class='danger'>You have a [item_name] in your [where]."
|
||||
mob.update_icons()
|
||||
if(where == "backpack")
|
||||
var/obj/item/weapon/storage/B = mob.back
|
||||
B.orient2hud(mob)
|
||||
|
||||
@@ -34,7 +34,7 @@ This file contains the arcane tome files.
|
||||
M.reagents.add_reagent("unholywater",holy2unholy)
|
||||
add_logs(user, M, "smacked", src, " removing the holy water from them")
|
||||
return
|
||||
M.take_organ_damage(0, 15) //Used to be a random between 5 and 20
|
||||
M.take_bodypart_damage(0, 15) //Used to be a random between 5 and 20
|
||||
playsound(M, 'sound/weapons/sear.ogg', 50, 1)
|
||||
M.visible_message("<span class='danger'>[user] strikes [M] with the arcane tome!</span>", \
|
||||
"<span class='userdanger'>[user] strikes you with the tome, searing your flesh!</span>")
|
||||
|
||||
@@ -253,7 +253,7 @@
|
||||
else
|
||||
target.Weaken(10)
|
||||
target.Stun(10)
|
||||
target.flash_eyes(1,1)
|
||||
target.flash_act(1,1)
|
||||
if(issilicon(target))
|
||||
var/mob/living/silicon/S = target
|
||||
S.emp_act(1)
|
||||
@@ -316,7 +316,7 @@
|
||||
target << "<span class='userdanger'>You see a brief but horrible vision of Ratvar, rusted and scrapped, being torn apart.</span>"
|
||||
target.emote("scream")
|
||||
target.confused = max(0, target.confused + 3)
|
||||
target.flash_eyes()
|
||||
target.flash_act()
|
||||
qdel(src)
|
||||
|
||||
|
||||
|
||||
@@ -22,13 +22,20 @@
|
||||
mob_size = MOB_SIZE_LARGE
|
||||
var/mob/living/oldform
|
||||
var/list/devil_overlays[DEVIL_TOTAL_LAYERS]
|
||||
bodyparts = list(/obj/item/bodypart/chest/devil, /obj/item/bodypart/head/devil, /obj/item/bodypart/l_arm/devil,
|
||||
/obj/item/bodypart/r_arm/devil, /obj/item/bodypart/r_leg/devil, /obj/item/bodypart/l_leg/devil)
|
||||
|
||||
|
||||
|
||||
/mob/living/carbon/true_devil/New()
|
||||
internal_organs += new /obj/item/organ/brain/
|
||||
create_bodyparts() //initialize bodyparts
|
||||
|
||||
create_internal_organs()
|
||||
..()
|
||||
|
||||
/mob/living/carbon/true_devil/create_internal_organs()
|
||||
internal_organs += new /obj/item/organ/brain
|
||||
internal_organs += new /obj/item/organ/tongue
|
||||
for(var/X in internal_organs)
|
||||
var/obj/item/organ/I = X
|
||||
I.Insert(src)
|
||||
..()
|
||||
|
||||
|
||||
@@ -95,11 +102,17 @@
|
||||
/mob/living/carbon/true_devil/assess_threat()
|
||||
return 666
|
||||
|
||||
/mob/living/carbon/true_devil/flash_eyes(intensity = 1, override_blindness_check = 0, affect_silicon = 0)
|
||||
/mob/living/carbon/true_devil/flash_act(intensity = 1, override_blindness_check = 0, affect_silicon = 0)
|
||||
if(mind && has_bane(BANE_LIGHT))
|
||||
mind.disrupt_spells(-500)
|
||||
return ..() //flashes don't stop devils UNLESS it's their bane.
|
||||
|
||||
/mob/living/carbon/true_devil/soundbang_act()
|
||||
return 0
|
||||
|
||||
/mob/living/carbon/true_devil/get_ear_protection()
|
||||
return 2
|
||||
|
||||
|
||||
/mob/living/carbon/true_devil/attacked_by(obj/item/I, mob/living/user, def_zone)
|
||||
var/weakness = check_weakness(I, user)
|
||||
@@ -120,9 +133,6 @@
|
||||
"<span class='userdanger'>[attack_message]</span>")
|
||||
return TRUE
|
||||
|
||||
/mob/living/carbon/true_devil/UnarmedAttack(atom/A, proximity)
|
||||
A.attack_hand(src)
|
||||
|
||||
/mob/living/carbon/true_devil/Process_Spacemove(movement_dir = 0)
|
||||
return 1
|
||||
|
||||
@@ -200,4 +210,14 @@
|
||||
if(has_bane(BANE_LIGHT))
|
||||
b_loss *=2
|
||||
adjustBruteLoss(b_loss)
|
||||
return ..()
|
||||
return ..()
|
||||
|
||||
|
||||
/mob/living/carbon/true_devil/update_body() //we don't use the bodyparts layer for devils.
|
||||
return
|
||||
|
||||
/mob/living/carbon/true_devil/update_body_parts()
|
||||
return
|
||||
|
||||
/mob/living/carbon/true_devil/update_damage_overlays() //devils don't have damage overlays.
|
||||
return
|
||||
@@ -149,7 +149,6 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
. += 1
|
||||
else
|
||||
mob << "The <b>chameleon security HUD</b> in your [where4] will help you keep track of who is mindshield-implanted, and unable to be recruited."
|
||||
mob.update_icons()
|
||||
return .
|
||||
|
||||
|
||||
@@ -167,7 +166,7 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
|
||||
if(iscarbon(gangster_mind.current))
|
||||
var/mob/living/carbon/carbon_mob = gangster_mind.current
|
||||
carbon_mob.silent = max(carbon_mob.silent, 5)
|
||||
carbon_mob.flash_eyes(1, 1)
|
||||
carbon_mob.flash_act(1, 1)
|
||||
gangster_mind.current.Stun(5)
|
||||
gangster_mind.current << "<FONT size=3 color=red><B>You are now a member of the [G.name] Gang!</B></FONT>"
|
||||
gangster_mind.current << "<font color='red'>Help your bosses take over the station by claiming territory with <b>special spraycans</b> only they can provide. Simply spray on any unclaimed area of the station.</font>"
|
||||
|
||||
@@ -459,11 +459,11 @@ Congratulations! You are now trained for xenobiology research!"}
|
||||
return
|
||||
var/mob/living/carbon/C = L
|
||||
if(!C.handcuffed)
|
||||
if(C.get_num_arms() >= 2)
|
||||
if(C.get_num_arms() >= 2 || C.get_arm_ignore())
|
||||
playsound(loc, 'sound/weapons/cablecuff.ogg', 30, 1, -2)
|
||||
C.visible_message("<span class='danger'>[user] begins restraining [C] with [src]!</span>", \
|
||||
"<span class='userdanger'>[user] begins shaping an energy field around your hands!</span>")
|
||||
if(do_mob(user, C, 30) && C.get_num_arms() >= 2)
|
||||
if(do_mob(user, C, 30) && (C.get_num_arms() >= 2 || C.get_arm_ignore()))
|
||||
if(!C.handcuffed)
|
||||
C.handcuffed = new /obj/item/weapon/restraints/handcuffs/energy/used(C)
|
||||
C.update_handcuffed()
|
||||
|
||||
@@ -23,9 +23,9 @@
|
||||
var/list/organ_types = list(/obj/item/organ/heart)
|
||||
|
||||
/datum/surgery_step/extract_organ/preop(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
|
||||
for(var/obj/item/I in target.internal_organs)
|
||||
if(I.type in organ_types)
|
||||
IC = I
|
||||
for(var/atom/A in target.internal_organs)
|
||||
if(A.type in organ_types)
|
||||
IC = A
|
||||
break
|
||||
user.visible_message("[user] starts to remove [target]'s organs.", "<span class='notice'>You start to remove [target]'s organs...</span>")
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
if(eyes_s)
|
||||
photo.Blend(eyes_s, ICON_OVERLAY)
|
||||
|
||||
var/icon/splat = icon("icon" = 'icons/mob/dam_human.dmi',"icon_state" = "chest30")
|
||||
var/icon/splat = icon("icon" = 'icons/mob/dam_mob.dmi',"icon_state" = "chest30")
|
||||
photo.Blend(splat,ICON_OVERLAY)
|
||||
|
||||
return photo
|
||||
|
||||
@@ -528,13 +528,13 @@ var/global/list/possible_items = list()
|
||||
|
||||
/datum/objective/steal/give_special_equipment()
|
||||
if(owner && owner.current && targetinfo)
|
||||
if(istype(owner.current, /mob/living/carbon/human))
|
||||
if(ishuman(owner.current))
|
||||
var/mob/living/carbon/human/H = owner.current
|
||||
var/list/slots = list ("backpack" = slot_in_backpack)
|
||||
for(var/eq_path in targetinfo.special_equipment)
|
||||
var/obj/O = new eq_path
|
||||
H.equip_in_one_of_slots(O, slots)
|
||||
H.update_icons()
|
||||
|
||||
|
||||
var/global/list/possible_items_special = list()
|
||||
/datum/objective/steal/special //ninjas are so special they get their own subtype good for them
|
||||
|
||||
@@ -143,8 +143,6 @@
|
||||
var/where2 = mob.equip_in_one_of_slots(C, slots)
|
||||
mob.equip_in_one_of_slots(R,slots)
|
||||
|
||||
mob.update_icons()
|
||||
|
||||
if (!where2)
|
||||
mob << "The Syndicate were unfortunately unable to get you a chameleon security HUD."
|
||||
else
|
||||
@@ -248,7 +246,7 @@
|
||||
if(iscarbon(rev_mind.current))
|
||||
var/mob/living/carbon/carbon_mob = rev_mind.current
|
||||
carbon_mob.silent = max(carbon_mob.silent, 5)
|
||||
carbon_mob.flash_eyes(1, 1)
|
||||
carbon_mob.flash_act(1, 1)
|
||||
rev_mind.current.Stun(5)
|
||||
rev_mind.current << "<span class='danger'><FONT size = 3> You are now a revolutionary! Help your cause. Do not harm your fellow freedom fighters. You can identify your comrades by the red \"R\" icons, and your leaders by the blue \"R\" icons. Help them kill the heads to win the revolution!</FONT></span>"
|
||||
rev_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been converted to the revolution!</font>"
|
||||
|
||||
@@ -375,7 +375,6 @@
|
||||
if (equipped_slot)
|
||||
where = "In your [equipped_slot]"
|
||||
mob << "<BR><BR><span class='info'>[where] is a folder containing <b>secret documents</b> that another Syndicate group wants. We have set up a meeting with one of their agents on station to make an exchange. Exercise extreme caution as they cannot be trusted and may be hostile.</span><BR>"
|
||||
mob.update_icons()
|
||||
|
||||
/datum/game_mode/proc/update_traitor_icons_added(datum/mind/traitor_mind)
|
||||
var/datum/atom_hud/antag/traitorhud = huds[ANTAG_HUD_TRAITOR]
|
||||
|
||||
@@ -357,7 +357,7 @@ var/global/list/multiverse = list()
|
||||
if("cyborg")
|
||||
for(var/X in M.bodyparts)
|
||||
var/obj/item/bodypart/affecting = X
|
||||
affecting.change_bodypart_status(ORGAN_ROBOTIC)
|
||||
affecting.change_bodypart_status(BODYPART_ROBOTIC)
|
||||
M.equip_to_slot_or_del(new /obj/item/clothing/glasses/thermal/eyepatch(M), slot_glasses)
|
||||
M.put_in_hands_or_del(sword)
|
||||
|
||||
@@ -460,7 +460,6 @@ var/global/list/multiverse = list()
|
||||
else
|
||||
return
|
||||
|
||||
M.update_icons()
|
||||
M.update_body_parts()
|
||||
|
||||
var/obj/item/weapon/card/id/W = new /obj/item/weapon/card/id
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
for(var/datum/mind/wizard in wizards)
|
||||
if(!istype(wizard.current,/mob/living/carbon))
|
||||
continue
|
||||
if(istype(wizard.current,/mob/living/carbon/brain))
|
||||
if(istype(wizard.current,/mob/living/brain))
|
||||
continue
|
||||
if(wizard.current.stat==DEAD)
|
||||
continue
|
||||
|
||||
@@ -160,7 +160,6 @@
|
||||
wizard_mob << "The spellbook is bound to you, and others cannot use it."
|
||||
wizard_mob << "In your pockets you will find a teleport scroll. Use it as needed."
|
||||
wizard_mob.mind.store_memory("<B>Remember:</B> do not forget to prepare your spells.")
|
||||
wizard_mob.update_icons()
|
||||
return 1
|
||||
|
||||
|
||||
|
||||
@@ -169,9 +169,9 @@
|
||||
var/list/unclean_mutations = (not_good_mutations|bad_mutations)
|
||||
H.dna.remove_mutation_group(unclean_mutations)
|
||||
if(efficiency > 5 && prob(20))
|
||||
randmutvg(H)
|
||||
H.randmutvg()
|
||||
if(efficiency < 3 && prob(50))
|
||||
var/mob/M = randmutb(H)
|
||||
var/mob/M = H.randmutb()
|
||||
if(ismob(M))
|
||||
H = M
|
||||
|
||||
@@ -325,7 +325,7 @@
|
||||
|
||||
if (mess) //Clean that mess and dump those gibs!
|
||||
mess = FALSE
|
||||
gibs(loc)
|
||||
new /obj/effect/gibspawner/generic(loc)
|
||||
audible_message("<span class='italics'>You hear a splat.</span>")
|
||||
icon_state = "pod_0"
|
||||
return
|
||||
@@ -338,7 +338,7 @@
|
||||
occupant.grab_ghost()
|
||||
occupant << "<span class='notice'><b>There is a bright flash!</b><br>\
|
||||
<i>You feel like a new being.</i></span>"
|
||||
occupant.flash_eyes()
|
||||
occupant.flash_act()
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
occupant.forceMove(T)
|
||||
|
||||
@@ -498,7 +498,7 @@
|
||||
M.hallucination += 30
|
||||
else
|
||||
usr << "<span class='userdanger'>Something strikes you from behind! It hurts like hell and feel like a blunt weapon, but nothing is there...</span>"
|
||||
M.take_organ_damage(30)
|
||||
M.take_bodypart_damage(30)
|
||||
playsound(loc, 'sound/weapons/genhit2.ogg', 100, 1)
|
||||
if(ORION_TRAIL_ILLNESS)
|
||||
var/severity = rand(1,3) //pray to RNGesus. PRAY, PIGS
|
||||
@@ -516,7 +516,7 @@
|
||||
if(prob(75))
|
||||
M.Weaken(3)
|
||||
say("A sudden gust of powerful wind slams [M] into the floor!")
|
||||
M.take_organ_damage(25)
|
||||
M.take_bodypart_damage(25)
|
||||
playsound(src.loc, 'sound/weapons/Genhit.ogg', 100, 1)
|
||||
else
|
||||
M << "<span class='userdanger'>A violent gale blows past you, and you barely manage to stay standing!</span>"
|
||||
|
||||
@@ -611,11 +611,9 @@ var/list/airlock_overlays = list()
|
||||
if(!istype(H.head, /obj/item/clothing/head/helmet))
|
||||
H.visible_message("<span class='danger'>[user] headbutts the airlock.</span>", \
|
||||
"<span class='userdanger'>You headbutt the airlock!</span>")
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart("head")
|
||||
H.Stun(5)
|
||||
H.Weaken(5)
|
||||
if(affecting && affecting.take_damage(10, 0))
|
||||
H.update_damage_overlays(0)
|
||||
H.apply_damage(10, BRUTE, "head")
|
||||
else
|
||||
visible_message("<span class='danger'>[user] headbutts the airlock. Good thing they're wearing a helmet.</span>")
|
||||
return
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
if (get_dist(src, L) > range)
|
||||
continue
|
||||
|
||||
if(L.flash_eyes(affect_silicon = 1))
|
||||
if(L.flash_act(affect_silicon = 1))
|
||||
L.Weaken(strength)
|
||||
if(L.weakeyes)
|
||||
L.Weaken(strength * 1.5)
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
var/mob/living/silicon/robot/R = occupant
|
||||
restock_modules()
|
||||
if(repairs)
|
||||
R.heal_organ_damage(repairs, repairs - 1)
|
||||
R.heal_bodypart_damage(repairs, repairs - 1)
|
||||
if(R.cell)
|
||||
R.cell.charge = min(R.cell.charge + recharge_speed, R.cell.maxcharge)
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
anchored = 1
|
||||
var/metal_amount = 0
|
||||
var/operating = 0
|
||||
var/obj/item/robot_parts/being_built = null
|
||||
var/obj/item/being_built = null
|
||||
use_power = 1
|
||||
idle_power_usage = 20
|
||||
active_power_usage = 5000
|
||||
@@ -90,37 +90,37 @@ Please wait until completion...</TT><BR>
|
||||
|
||||
switch (part_type)
|
||||
if (1)
|
||||
build_type = "/obj/item/robot_parts/l_arm"
|
||||
build_type = "/obj/item/bodypart/l_arm/robot"
|
||||
build_time = 200
|
||||
build_cost = 10000
|
||||
|
||||
if (2)
|
||||
build_type = "/obj/item/robot_parts/r_arm"
|
||||
build_type = "/obj/item/bodypart/r_arm/robot"
|
||||
build_time = 200
|
||||
build_cost = 10000
|
||||
|
||||
if (3)
|
||||
build_type = "/obj/item/robot_parts/l_leg"
|
||||
build_type = "/obj/item/bodypart/l_leg/robot"
|
||||
build_time = 200
|
||||
build_cost = 10000
|
||||
|
||||
if (4)
|
||||
build_type = "/obj/item/robot_parts/r_leg"
|
||||
build_type = "/obj/item/bodypart/r_leg/robot"
|
||||
build_time = 200
|
||||
build_cost = 10000
|
||||
|
||||
if (5)
|
||||
build_type = "/obj/item/robot_parts/chest"
|
||||
build_type = "/obj/item/bodypart/chest/robot"
|
||||
build_time = 350
|
||||
build_cost = 40000
|
||||
|
||||
if (6)
|
||||
build_type = "/obj/item/robot_parts/head"
|
||||
build_type = "/obj/item/bodypart/head/robot"
|
||||
build_time = 350
|
||||
build_cost = 5000
|
||||
|
||||
if (7)
|
||||
build_type = "/obj/item/robot_parts/robot_suit"
|
||||
build_type = "/obj/item/robot_suit"
|
||||
build_time = 600
|
||||
build_cost = 15000
|
||||
|
||||
@@ -146,6 +146,4 @@ Please wait until completion...</TT><BR>
|
||||
src.overlays -= "fab-active"
|
||||
return
|
||||
|
||||
for (var/mob/M in viewers(1, src))
|
||||
if (M.client && M.machine == src)
|
||||
src.attack_hand(M)
|
||||
updateUsrDialog()
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
var/language = "Human" // MMIs, pAIs, Cyborgs and humans all speak Human
|
||||
var/mobtype = C.parameters["mobtype"]
|
||||
|
||||
var/list/humans = typesof(/mob/living/carbon/human, /mob/living/carbon/brain)
|
||||
var/list/humans = typesof(/mob/living/carbon/human, /mob/living/brain)
|
||||
var/list/monkeys = typesof(/mob/living/carbon/monkey)
|
||||
var/list/silicons = typesof(/mob/living/silicon)
|
||||
var/list/slimes = typesof(/mob/living/simple_animal/slime)
|
||||
|
||||
@@ -343,7 +343,7 @@
|
||||
mechsyringe.icon = initial(mechsyringe.icon)
|
||||
mechsyringe.reagents.reaction(M, INJECT)
|
||||
mechsyringe.reagents.trans_to(M, mechsyringe.reagents.total_volume)
|
||||
M.take_organ_damage(2)
|
||||
M.take_bodypart_damage(2)
|
||||
add_logs(originaloccupant, M, "shot", "syringegun")
|
||||
break
|
||||
else if(mechsyringe.loc == trg)
|
||||
|
||||
@@ -83,13 +83,11 @@
|
||||
add_logs(user, target, "attacked", "[name]", "(INTENT: [uppertext(user.a_intent)]) (DAMTYPE: [uppertext(damtype)])")
|
||||
if(ishuman(target))
|
||||
var/mob/living/carbon/human/H = target
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart("chest")
|
||||
affecting.take_damage(drill_damage)
|
||||
H.update_damage_overlays(0)
|
||||
H.apply_damage(drill_damage, BRUTE, "chest")
|
||||
else if(target.stat == DEAD && target.butcher_results)
|
||||
target.harvest(chassis) // Butcher the mob with our drill.
|
||||
else
|
||||
target.take_organ_damage(drill_damage)
|
||||
target.take_bodypart_damage(drill_damage)
|
||||
|
||||
if(target)
|
||||
target.Paralyse(10)
|
||||
|
||||
@@ -845,7 +845,7 @@
|
||||
else if(occupant)
|
||||
user << "<span class='warning'>Occupant detected!</span>"
|
||||
return 0
|
||||
else if(dna_lock && (!mmi_as_oc.brainmob.dna || dna_lock!=mmi_as_oc.brainmob.dna.unique_enzymes))
|
||||
else if(dna_lock && (!mmi_as_oc.brainmob.stored_dna || dna_lock!=mmi_as_oc.brainmob.stored_dna.unique_enzymes))
|
||||
user << "<span class='warning'>Access denied. [name] is secured with a DNA lock.</span>"
|
||||
return 0
|
||||
|
||||
@@ -905,8 +905,8 @@
|
||||
if(ishuman(occupant))
|
||||
mob_container = occupant
|
||||
RemoveActions(occupant, human_occupant=1)
|
||||
else if(istype(occupant, /mob/living/carbon/brain))
|
||||
var/mob/living/carbon/brain/brain = occupant
|
||||
else if(istype(occupant, /mob/living/brain))
|
||||
var/mob/living/brain/brain = occupant
|
||||
RemoveActions(brain)
|
||||
mob_container = brain.container
|
||||
else if(isAI(occupant) && forced) //This should only happen if there are multiple AIs in a round, and at least one is Malf.
|
||||
|
||||
@@ -21,18 +21,21 @@
|
||||
return ..()
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/proc/streak(list/directions)
|
||||
spawn (0)
|
||||
var/direction = pick(directions)
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50; 4), i++)
|
||||
sleep(3)
|
||||
if (i > 0)
|
||||
var/obj/effect/decal/cleanable/xenoblood/b = new /obj/effect/decal/cleanable/xenoblood/xsplatter(src.loc)
|
||||
for(var/datum/disease/D in src.viruses)
|
||||
var/datum/disease/ND = D.Copy(1)
|
||||
b.viruses += ND
|
||||
ND.holder = b
|
||||
if (step_to(src, get_step(src, direction), 0))
|
||||
break
|
||||
set waitfor = 0
|
||||
var/direction = pick(directions)
|
||||
for(var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++)
|
||||
sleep(2)
|
||||
if (i > 0)
|
||||
var/obj/effect/decal/cleanable/xenoblood/b = new /obj/effect/decal/cleanable/xenoblood/xsplatter(src.loc)
|
||||
for(var/datum/disease/D in src.viruses)
|
||||
var/datum/disease/ND = D.Copy(1)
|
||||
b.viruses += ND
|
||||
ND.holder = b
|
||||
if (!step_to(src, get_step(src, direction), 0))
|
||||
break
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/replace_decal(obj/effect/decal/cleanable/C)
|
||||
return //gibs can stack, so gibspawner can work properly
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xsplatter
|
||||
random_icon_states = list("xgibbl1", "xgibbl2", "xgibbl3", "xgibbl4", "xgibbl5")
|
||||
@@ -57,12 +60,21 @@
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/body
|
||||
random_icon_states = list("xgibhead", "xgibtorso")
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/torso
|
||||
random_icon_states = list("xgibtorso")
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/limb
|
||||
random_icon_states = list("xgibleg", "xgibarm")
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/core
|
||||
random_icon_states = list("xgibmid1", "xgibmid2", "xgibmid3")
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/larva
|
||||
random_icon_states = list("xgiblarva1", "xgiblarva2")
|
||||
|
||||
/obj/effect/decal/cleanable/xenoblood/xgibs/larva/body
|
||||
random_icon_states = list("xgiblarvahead", "xgiblarvatorso")
|
||||
|
||||
/obj/effect/decal/cleanable/blood/xtracks
|
||||
icon_state = "xtracks"
|
||||
random_icon_states = null
|
||||
|
||||
@@ -77,6 +77,10 @@
|
||||
/obj/effect/decal/cleanable/blood/gibs/body
|
||||
random_icon_states = list("gibhead", "gibtorso")
|
||||
|
||||
/obj/effect/decal/cleanable/blood/gibs/torso
|
||||
random_icon_states = list("gibtorso")
|
||||
|
||||
|
||||
/obj/effect/decal/cleanable/blood/gibs/limb
|
||||
random_icon_states = list("gibleg", "gibarm")
|
||||
|
||||
@@ -87,17 +91,20 @@
|
||||
/obj/effect/decal/cleanable/blood/gibs/proc/streak(list/directions)
|
||||
set waitfor = 0
|
||||
var/direction = pick(directions)
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50; 4), i++)
|
||||
sleep(3)
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++)
|
||||
sleep(2)
|
||||
if (i > 0)
|
||||
var/obj/effect/decal/cleanable/blood/b = new /obj/effect/decal/cleanable/blood/splatter(src.loc)
|
||||
for(var/datum/disease/D in src.viruses)
|
||||
var/datum/disease/ND = D.Copy(1)
|
||||
b.viruses += ND
|
||||
ND.holder = b
|
||||
if (step_to(src, get_step(src, direction), 0))
|
||||
if (!step_to(src, get_step(src, direction), 0))
|
||||
break
|
||||
|
||||
/obj/effect/decal/cleanable/blood/gibs/replace_decal(obj/effect/decal/cleanable/C)
|
||||
return //gibs can stack, so gibspawner can work properly
|
||||
|
||||
/obj/effect/decal/cleanable/blood/drip
|
||||
name = "drips of blood"
|
||||
desc = "It's red."
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
/obj/effect/decal/cleanable/robot_debris/proc/streak(list/directions)
|
||||
set waitfor = 0
|
||||
var/direction = pick(directions)
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50; 4), i++)
|
||||
sleep(3)
|
||||
for (var/i = 0, i < pick(1, 200; 2, 150; 3, 50), i++)
|
||||
sleep(2)
|
||||
if (i > 0)
|
||||
if (prob(40))
|
||||
new /obj/effect/decal/cleanable/oil/streak(src.loc)
|
||||
@@ -24,9 +24,12 @@
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
if (step_to(src, get_step(src, direction), 0))
|
||||
if (!step_to(src, get_step(src, direction), 0))
|
||||
break
|
||||
|
||||
/obj/effect/decal/cleanable/robot_debris/replace_decal(obj/effect/decal/cleanable/C)
|
||||
return //robot debris can stack, so gibspawner can work properly
|
||||
|
||||
/obj/effect/decal/cleanable/robot_debris/ex_act()
|
||||
return
|
||||
|
||||
|
||||
@@ -11,6 +11,9 @@
|
||||
desc = "They look like the remains of something... alien. They have a strange aura about them."
|
||||
icon_state = "remainsxeno"
|
||||
|
||||
/obj/effect/decal/remains/xeno/larva
|
||||
icon_state = "remainslarva"
|
||||
|
||||
/obj/effect/decal/remains/robot
|
||||
desc = "They look like the remains of something mechanical. They have a strange aura about them."
|
||||
icon = 'icons/mob/robots.dmi'
|
||||
|
||||
@@ -1,62 +0,0 @@
|
||||
/proc/gibs(atom/location, list/viruses, datum/dna/MobDNA)
|
||||
new /obj/effect/gibspawner/generic(location,viruses,MobDNA)
|
||||
|
||||
/proc/hgibs(atom/location, list/viruses, datum/dna/MobDNA)
|
||||
new /obj/effect/gibspawner/human(location,viruses,MobDNA)
|
||||
|
||||
/proc/xgibs(atom/location, list/viruses)
|
||||
new /obj/effect/gibspawner/xeno(location,viruses)
|
||||
|
||||
/proc/robogibs(atom/location, list/viruses)
|
||||
new /obj/effect/gibspawner/robot(location,viruses)
|
||||
|
||||
/obj/effect/gibspawner
|
||||
var/sparks = 0 //whether sparks spread on Gib()
|
||||
var/virusProb = 20 //the chance for viruses to spread on the gibs
|
||||
var/list/gibtypes = list()
|
||||
var/list/gibamounts = list()
|
||||
var/list/gibdirections = list() //of lists
|
||||
|
||||
/obj/effect/gibspawner/New(location, var/list/viruses, var/datum/dna/MobDNA)
|
||||
..()
|
||||
|
||||
Gib(loc,viruses,MobDNA)
|
||||
|
||||
/obj/effect/gibspawner/proc/Gib(atom/location, list/viruses = list(), datum/dna/MobDNA = null)
|
||||
if(gibtypes.len != gibamounts.len || gibamounts.len != gibdirections.len)
|
||||
world << "<span class='danger'>Gib list length mismatch!</span>"
|
||||
return
|
||||
|
||||
var/obj/effect/decal/cleanable/blood/gibs/gib = null
|
||||
|
||||
if(sparks)
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(2, 1, location)
|
||||
s.start()
|
||||
|
||||
for(var/i = 1, i<= gibtypes.len, i++)
|
||||
if(gibamounts[i])
|
||||
for(var/j = 1, j<= gibamounts[i], j++)
|
||||
var/gibType = gibtypes[i]
|
||||
gib = new gibType(location)
|
||||
if(istype(location,/mob/living/carbon))
|
||||
var/mob/living/carbon/digester = location
|
||||
digester.stomach_contents += gib
|
||||
|
||||
if(viruses.len > 0)
|
||||
for(var/datum/disease/D in viruses)
|
||||
if(prob(virusProb))
|
||||
var/datum/disease/viruus = D.Copy(1)
|
||||
gib.viruses += viruus
|
||||
viruus.holder = gib
|
||||
|
||||
if(MobDNA)
|
||||
gib.blood_DNA[MobDNA.unique_enzymes] = MobDNA.blood_type
|
||||
else if(istype(src, /obj/effect/gibspawner/generic)) // Probably a monkey
|
||||
gib.blood_DNA["Non-human DNA"] = "A+"
|
||||
var/list/directions = gibdirections[i]
|
||||
if(istype(loc,/turf))
|
||||
if(directions.len)
|
||||
gib.streak(directions)
|
||||
|
||||
qdel(src)
|
||||
@@ -1,4 +1,53 @@
|
||||
|
||||
/obj/effect/gibspawner
|
||||
var/sparks = 0 //whether sparks spread
|
||||
var/virusProb = 20 //the chance for viruses to spread on the gibs
|
||||
var/list/gibtypes = list() //typepaths of the gib decals to spawn
|
||||
var/list/gibamounts = list() //amount to spawn for each gib decal type we'll spawn.
|
||||
var/list/gibdirections = list() //of lists of possible directions to spread each gib decal type towards.
|
||||
|
||||
/obj/effect/gibspawner/New(location, list/viruses, datum/dna/MobDNA)
|
||||
..()
|
||||
|
||||
if(gibtypes.len != gibamounts.len || gibamounts.len != gibdirections.len)
|
||||
world << "<span class='danger'>Gib list length mismatch!</span>"
|
||||
return
|
||||
|
||||
var/obj/effect/decal/cleanable/blood/gibs/gib = null
|
||||
|
||||
if(sparks)
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(2, 1, location)
|
||||
s.start()
|
||||
|
||||
for(var/i = 1, i<= gibtypes.len, i++)
|
||||
if(gibamounts[i])
|
||||
for(var/j = 1, j<= gibamounts[i], j++)
|
||||
var/gibType = gibtypes[i]
|
||||
gib = new gibType(location)
|
||||
if(istype(location,/mob/living/carbon))
|
||||
var/mob/living/carbon/digester = location
|
||||
digester.stomach_contents += gib
|
||||
|
||||
if(viruses && viruses.len > 0)
|
||||
for(var/datum/disease/D in viruses)
|
||||
if(prob(virusProb))
|
||||
var/datum/disease/viruus = D.Copy(1)
|
||||
gib.viruses += viruus
|
||||
viruus.holder = gib
|
||||
|
||||
if(MobDNA)
|
||||
gib.blood_DNA[MobDNA.unique_enzymes] = MobDNA.blood_type
|
||||
else if(istype(src, /obj/effect/gibspawner/generic)) // Probably a monkey
|
||||
gib.blood_DNA["Non-human DNA"] = "A+"
|
||||
var/list/directions = gibdirections[i]
|
||||
if(isturf(loc))
|
||||
if(directions.len)
|
||||
gib.streak(directions)
|
||||
|
||||
qdel(src)
|
||||
|
||||
|
||||
|
||||
/obj/effect/gibspawner/generic
|
||||
gibtypes = list(/obj/effect/decal/cleanable/blood/gibs,/obj/effect/decal/cleanable/blood/gibs,/obj/effect/decal/cleanable/blood/gibs/core)
|
||||
@@ -16,17 +65,55 @@
|
||||
/obj/effect/gibspawner/human/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 50, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST),list(WEST, NORTHWEST, SOUTHWEST),list(EAST, NORTHEAST, SOUTHEAST), alldirs, alldirs, list())
|
||||
gibamounts[6] = pick(0,1,2)
|
||||
..()
|
||||
|
||||
|
||||
/obj/effect/gibspawner/humanbodypartless //only the gibs that don't look like actual full bodyparts (except torso).
|
||||
gibtypes = list(/obj/effect/decal/cleanable/blood/gibs, /obj/effect/decal/cleanable/blood/gibs/core,/obj/effect/decal/cleanable/blood/gibs, /obj/effect/decal/cleanable/blood/gibs/core, /obj/effect/decal/cleanable/blood/gibs, /obj/effect/decal/cleanable/blood/gibs/torso)
|
||||
gibamounts = list(1, 1, 1, 1, 1, 1)
|
||||
|
||||
/obj/effect/gibspawner/humanbodypartless/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 50, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST),list(WEST, NORTHWEST, SOUTHWEST),list(EAST, NORTHEAST, SOUTHEAST), alldirs, list())
|
||||
..()
|
||||
|
||||
|
||||
/obj/effect/gibspawner/xeno
|
||||
gibtypes = list(/obj/effect/decal/cleanable/xenoblood/xgibs/up,/obj/effect/decal/cleanable/xenoblood/xgibs/down,/obj/effect/decal/cleanable/xenoblood/xgibs,/obj/effect/decal/cleanable/xenoblood/xgibs,/obj/effect/decal/cleanable/xenoblood/xgibs/body,/obj/effect/decal/cleanable/xenoblood/xgibs/limb,/obj/effect/decal/cleanable/xenoblood/xgibs/core)
|
||||
gibtypes = list(/obj/effect/decal/cleanable/xenoblood/xgibs/up,/obj/effect/decal/cleanable/xenoblood/xgibs/down,/obj/effect/decal/cleanable/xenoblood/xgibs, /obj/effect/decal/cleanable/xenoblood/xgibs, /obj/effect/decal/cleanable/xenoblood/xgibs/body, /obj/effect/decal/cleanable/xenoblood/xgibs/limb, /obj/effect/decal/cleanable/xenoblood/xgibs/core)
|
||||
gibamounts = list(1,1,1,1,1,1,1)
|
||||
|
||||
/obj/effect/gibspawner/xeno/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 60, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST),list(WEST, NORTHWEST, SOUTHWEST),list(EAST, NORTHEAST, SOUTHEAST), alldirs, alldirs, list())
|
||||
gibamounts[6] = pick(0,1,2)
|
||||
..()
|
||||
|
||||
|
||||
/obj/effect/gibspawner/xenobodypartless //only the gibs that don't look like actual full bodyparts (except torso).
|
||||
gibtypes = list(/obj/effect/decal/cleanable/xenoblood/xgibs, /obj/effect/decal/cleanable/xenoblood/xgibs/core,/obj/effect/decal/cleanable/xenoblood/xgibs, /obj/effect/decal/cleanable/xenoblood/xgibs/core, /obj/effect/decal/cleanable/xenoblood/xgibs, /obj/effect/decal/cleanable/xenoblood/xgibs/torso)
|
||||
gibamounts = list(1, 1, 1, 1, 1, 1)
|
||||
|
||||
|
||||
/obj/effect/gibspawner/xenobodypartless/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 60, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST),list(WEST, NORTHWEST, SOUTHWEST),list(EAST, NORTHEAST, SOUTHEAST), alldirs, list())
|
||||
..()
|
||||
|
||||
/obj/effect/gibspawner/larva
|
||||
gibtypes = list(/obj/effect/decal/cleanable/xenoblood/xgibs/larva, /obj/effect/decal/cleanable/xenoblood/xgibs/larva, /obj/effect/decal/cleanable/xenoblood/xgibs/larva/body, /obj/effect/decal/cleanable/xenoblood/xgibs/larva/body)
|
||||
gibamounts = list(1, 1, 1, 1)
|
||||
|
||||
/obj/effect/gibspawner/larva/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 60, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST), list(), alldirs)
|
||||
..()
|
||||
|
||||
/obj/effect/gibspawner/larvabodypartless
|
||||
gibtypes = list(/obj/effect/decal/cleanable/xenoblood/xgibs/larva, /obj/effect/decal/cleanable/xenoblood/xgibs/larva, /obj/effect/decal/cleanable/xenoblood/xgibs/larva)
|
||||
gibamounts = list(1, 1, 1)
|
||||
|
||||
/obj/effect/gibspawner/larvabodypartless/New()
|
||||
playsound(src, 'sound/effects/blobattack.ogg', 60, 1)
|
||||
gibdirections = list(list(NORTH, NORTHEAST, NORTHWEST),list(SOUTH, SOUTHEAST, SOUTHWEST), list())
|
||||
..()
|
||||
|
||||
/obj/effect/gibspawner/robot
|
||||
|
||||
@@ -230,8 +230,8 @@ var/global/image/fire_overlay = image("icon" = 'icons/effects/fire.dmi', "icon_s
|
||||
user << "<span class='warning'>You burn your hand on [src]!</span>"
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart("[(user.active_hand_index % 2 == 0) ? "r" : "l" ]_arm")
|
||||
if(affecting && affecting.take_damage( 0, 5 )) // 5 burn damage
|
||||
H.update_damage_overlays(0)
|
||||
H.updatehealth()
|
||||
H.update_damage_overlays()
|
||||
|
||||
return
|
||||
else
|
||||
extinguish()
|
||||
@@ -454,11 +454,10 @@ obj/item/proc/item_action_slot_check(slot, mob/user)
|
||||
)
|
||||
if(is_human_victim)
|
||||
var/mob/living/carbon/human/U = M
|
||||
if(affecting.take_damage(7))
|
||||
U.update_damage_overlays(0)
|
||||
U.apply_damage(7, BRUTE, affecting)
|
||||
|
||||
else
|
||||
M.take_organ_damage(7)
|
||||
M.take_bodypart_damage(7)
|
||||
|
||||
add_logs(user, M, "attacked", "[src.name]", "(INTENT: [uppertext(user.a_intent)])")
|
||||
|
||||
|
||||
@@ -640,7 +640,7 @@
|
||||
if(C.client)
|
||||
C.blur_eyes(3)
|
||||
C.blind_eyes(1)
|
||||
if(C.check_eye_prot() <= 0) // no eye protection? ARGH IT BURNS.
|
||||
if(C.get_eye_protection() <= 0) // no eye protection? ARGH IT BURNS.
|
||||
C.confused = max(C.confused, 3)
|
||||
C.Weaken(3)
|
||||
if(ishuman(C) && actually_paints)
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
return
|
||||
|
||||
if(M == user) //they're using it on themselves
|
||||
if(M.flash_eyes(visual = 1))
|
||||
if(M.flash_act(visual = 1))
|
||||
M.visible_message("[M] directs [src] to \his eyes.", \
|
||||
"<span class='notice'>You wave the light in front of your eyes! Trippy!</span>")
|
||||
else
|
||||
@@ -77,7 +77,7 @@
|
||||
else if(C.dna.check_mutation(XRAY)) //mob has X-RAY vision
|
||||
user << "<span class='danger'>[C] pupils give an eerie glow!</span>"
|
||||
else //they're okay!
|
||||
if(C.flash_eyes(visual = 1))
|
||||
if(C.flash_act(visual = 1))
|
||||
user << "<span class='notice'>[C]'s pupils narrow.</span>"
|
||||
else
|
||||
return ..()
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
severity = 0
|
||||
|
||||
//20% chance to actually hit the eyes
|
||||
if(prob(effectchance * diode.rating) && C.flash_eyes(severity))
|
||||
if(prob(effectchance * diode.rating) && C.flash_act(severity))
|
||||
outmsg = "<span class='notice'>You blind [C] by shining [src] in their eyes.</span>"
|
||||
if(C.weakeyes)
|
||||
C.Stun(1)
|
||||
@@ -110,7 +110,7 @@
|
||||
var/mob/living/silicon/S = target
|
||||
//20% chance to actually hit the sensors
|
||||
if(prob(effectchance * diode.rating))
|
||||
S.flash_eyes(affect_silicon = 1)
|
||||
S.flash_act(affect_silicon = 1)
|
||||
S.Weaken(rand(5,10))
|
||||
S << "<span class='danger'>Your sensors were overloaded by a laser!</span>"
|
||||
outmsg = "<span class='notice'>You overload [S] by shining [src] at their sensors.</span>"
|
||||
|
||||
@@ -114,7 +114,7 @@ MASS SPECTROMETER
|
||||
|
||||
// Used by the PDA medical scanner too
|
||||
/proc/healthscan(mob/living/user, mob/living/M, mode = 1)
|
||||
if(user.stat || user.eye_blind)
|
||||
if(user.incapacitated() || user.eye_blind)
|
||||
return
|
||||
//Damage specifics
|
||||
var/oxy_loss = M.getOxyLoss()
|
||||
@@ -156,9 +156,9 @@ MASS SPECTROMETER
|
||||
user << "\t<span class='alert'>Brain damage detected. Subject may have had a concussion.</span>"
|
||||
|
||||
// Organ damage report
|
||||
if(istype(M, /mob/living/carbon/human) && mode == 1)
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/list/damaged = H.get_damaged_bodyparts(1,1)
|
||||
if(iscarbon(M) && mode == 1)
|
||||
var/mob/living/carbon/C = M
|
||||
var/list/damaged = C.get_damaged_bodyparts(1,1)
|
||||
if(length(damaged)>0 || oxy_loss>0 || tox_loss>0 || fire_loss>0)
|
||||
user << "<span class='info'>\tDamage: <span class='info'><font color='red'>Brute</font></span>-<font color='#FF8000'>Burn</font>-<font color='green'>Toxin</font>-<font color='blue'>Suffocation</font>\n\t\tSpecifics: <font color='red'>[brute_loss]</font>-<font color='#FF8000'>[fire_loss]</font>-<font color='green'>[tox_loss]</font>-<font color='blue'>[oxy_loss]</font></span>"
|
||||
for(var/obj/item/bodypart/org in damaged)
|
||||
|
||||
@@ -294,14 +294,10 @@
|
||||
user.visible_message("<font color='red' size='2'>[user] blares out a near-deafening siren from its speakers!</font>", \
|
||||
"<span class='userdanger'>The siren pierces your hearing and confuses you!</span>", \
|
||||
"<span class='danger'>The siren pierces your hearing!</span>")
|
||||
for(var/mob/living/M in get_hearers_in_view(9, user))
|
||||
if(iscarbon(M))
|
||||
if(istype(M, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(istype(H.ears, /obj/item/clothing/ears/earmuffs))
|
||||
continue
|
||||
for(var/mob/living/carbon/M in get_hearers_in_view(9, user))
|
||||
if(M.get_ear_protection() == 0)
|
||||
M.confused += 6
|
||||
M << "<font color='red' size='7'>HUMAN HARM</font>"
|
||||
audible_message("<font color='red' size='7'>HUMAN HARM</font>")
|
||||
playsound(get_turf(src), 'sound/AI/harmalarm.ogg', 70, 3)
|
||||
cooldown = world.time + 200
|
||||
log_game("[user.ckey]([user]) used a Cyborg Harm Alarm in ([user.x],[user.y],[user.z])")
|
||||
@@ -312,35 +308,20 @@
|
||||
return
|
||||
|
||||
if(safety == 0)
|
||||
for(var/mob/living/M in get_hearers_in_view(9, user))
|
||||
if(iscarbon(M))
|
||||
var/earsafety = 0
|
||||
if(istype(M, /mob/living/carbon/alien))
|
||||
continue
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/S = M
|
||||
if(istype(S.ears, /obj/item/clothing/ears/earmuffs))
|
||||
continue
|
||||
if(S.check_ear_prot())
|
||||
earsafety = 1
|
||||
if(earsafety)
|
||||
M.confused += 5
|
||||
M.stuttering += 10
|
||||
M.adjustEarDamage(0, 5)
|
||||
M.Jitter(10)
|
||||
user.visible_message("<font color='red' size='3'>[user] blares out a sonic screech from its speakers!</font>", \
|
||||
"<span class='userdanger'>You hear a sharp screech, before your thoughts are interrupted and you find yourself extremely disorientated.</span>", \
|
||||
"<span class='danger'>You hear a sonic screech and suddenly can't seem to walk straight!")
|
||||
else
|
||||
M.Weaken(2)
|
||||
M.confused += 10
|
||||
M.stuttering += 15
|
||||
M.adjustEarDamage(0, 20)
|
||||
M.Jitter(25)
|
||||
user.visible_message("<font color='red' size='3'>[user] blares out a sonic screech from its speakers!</font>", \
|
||||
"<span class='userdanger'>You hear a sharp screech before your thoughts are interrupted and you collapse, your ears ringing!</span>", \
|
||||
"<span class='danger'>You hear a sonic screech and collapse, your ears riniging!")
|
||||
M << "<font color='red' size='7'>BZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZT</font>"
|
||||
for(var/mob/living/carbon/C in get_hearers_in_view(9, user))
|
||||
var/bang_effect = C.soundbang_act(2, 0, 0, 5)
|
||||
switch(bang_effect)
|
||||
if(1)
|
||||
C.confused += 5
|
||||
C.stuttering += 10
|
||||
C.Jitter(10)
|
||||
if(2)
|
||||
C.Weaken(2)
|
||||
C.confused += 10
|
||||
C.stuttering += 15
|
||||
C.Jitter(25)
|
||||
|
||||
user.audible_message("<font color='red' size='7'>BZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZT</font>")
|
||||
playsound(get_turf(src), 'sound/machines/warning-buzzer.ogg', 130, 3)
|
||||
cooldown = world.time + 600
|
||||
log_game("[user.ckey]([user]) used an emagged Cyborg Harm Alarm in ([user.x],[user.y],[user.z])")
|
||||
|
||||
@@ -1,68 +1,19 @@
|
||||
/obj/item/robot_parts
|
||||
name = "robot parts"
|
||||
icon = 'icons/obj/robot_parts.dmi'
|
||||
force = 4
|
||||
throwforce = 4
|
||||
item_state = "buildpipe"
|
||||
icon_state = "blank"
|
||||
flags = CONDUCT
|
||||
slot_flags = SLOT_BELT
|
||||
var/body_zone
|
||||
|
||||
/obj/item/robot_parts/l_arm
|
||||
name = "cyborg left arm"
|
||||
desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case."
|
||||
attack_verb = list("slapped", "punched")
|
||||
icon_state = "l_arm"
|
||||
body_zone = "l_arm"
|
||||
|
||||
/obj/item/robot_parts/r_arm
|
||||
name = "cyborg right arm"
|
||||
desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case."
|
||||
attack_verb = list("slapped", "punched")
|
||||
icon_state = "r_arm"
|
||||
body_zone = "r_arm"
|
||||
//The robot bodyparts have been moved to code/module/surgery/bodyparts/robot_bodyparts.dm
|
||||
|
||||
/obj/item/robot_parts/l_leg
|
||||
name = "cyborg left leg"
|
||||
desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case."
|
||||
attack_verb = list("kicked", "stomped")
|
||||
icon_state = "l_leg"
|
||||
body_zone = "l_leg"
|
||||
|
||||
/obj/item/robot_parts/r_leg
|
||||
name = "cyborg right leg"
|
||||
desc = "A skeletal limb wrapped in pseudomuscles, with a low-conductivity case."
|
||||
attack_verb = list("kicked", "stomped")
|
||||
icon_state = "r_leg"
|
||||
body_zone = "r_leg"
|
||||
|
||||
/obj/item/robot_parts/chest
|
||||
name = "cyborg torso"
|
||||
desc = "A heavily reinforced case containing cyborg logic boards, with space for a standard power cell."
|
||||
icon_state = "chest"
|
||||
body_zone = "chest"
|
||||
var/wired = 0
|
||||
var/obj/item/weapon/stock_parts/cell/cell = null
|
||||
|
||||
/obj/item/robot_parts/head
|
||||
name = "cyborg head"
|
||||
desc = "A standard reinforced braincase, with spine-plugged neural socket and sensor gimbals."
|
||||
icon_state = "head"
|
||||
body_zone = "head"
|
||||
var/obj/item/device/assembly/flash/handheld/flash1 = null
|
||||
var/obj/item/device/assembly/flash/handheld/flash2 = null
|
||||
|
||||
/obj/item/robot_parts/robot_suit
|
||||
/obj/item/robot_suit
|
||||
name = "cyborg endoskeleton"
|
||||
desc = "A complex metal backbone with standard limb sockets and pseudomuscle anchors."
|
||||
icon = 'icons/obj/robot_parts.dmi'
|
||||
icon_state = "robo_suit"
|
||||
var/obj/item/robot_parts/l_arm/l_arm = null
|
||||
var/obj/item/robot_parts/r_arm/r_arm = null
|
||||
var/obj/item/robot_parts/l_leg/l_leg = null
|
||||
var/obj/item/robot_parts/r_leg/r_leg = null
|
||||
var/obj/item/robot_parts/chest/chest = null
|
||||
var/obj/item/robot_parts/head/head = null
|
||||
var/obj/item/bodypart/l_arm/robot/l_arm = null
|
||||
var/obj/item/bodypart/r_arm/robot/r_arm = null
|
||||
var/obj/item/bodypart/l_leg/robot/l_leg = null
|
||||
var/obj/item/bodypart/r_leg/robot/r_leg = null
|
||||
var/obj/item/bodypart/chest/robot/chest = null
|
||||
var/obj/item/bodypart/head/robot/head = null
|
||||
|
||||
var/created_name = ""
|
||||
var/mob/living/silicon/ai/forced_ai
|
||||
@@ -71,11 +22,11 @@
|
||||
var/aisync = 1
|
||||
var/panel_locked = 1
|
||||
|
||||
/obj/item/robot_parts/robot_suit/New()
|
||||
/obj/item/robot_suit/New()
|
||||
..()
|
||||
src.updateicon()
|
||||
|
||||
/obj/item/robot_parts/robot_suit/proc/updateicon()
|
||||
/obj/item/robot_suit/proc/updateicon()
|
||||
src.cut_overlays()
|
||||
if(src.l_arm)
|
||||
src.add_overlay("l_arm+o")
|
||||
@@ -90,7 +41,7 @@
|
||||
if(src.head)
|
||||
src.add_overlay("head+o")
|
||||
|
||||
/obj/item/robot_parts/robot_suit/proc/check_completion()
|
||||
/obj/item/robot_suit/proc/check_completion()
|
||||
if(src.l_arm && src.r_arm)
|
||||
if(src.l_leg && src.r_leg)
|
||||
if(src.chest && src.head)
|
||||
@@ -98,7 +49,7 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/robot_parts/robot_suit/attackby(obj/item/W, mob/user, params)
|
||||
/obj/item/robot_suit/attackby(obj/item/W, mob/user, params)
|
||||
|
||||
if(istype(W, /obj/item/stack/sheet/metal))
|
||||
var/obj/item/stack/sheet/metal/M = W
|
||||
@@ -114,64 +65,82 @@
|
||||
else
|
||||
user << "<span class='warning'>You need one sheet of metal to start building ED-209!</span>"
|
||||
return
|
||||
else if(istype(W, /obj/item/robot_parts/l_leg))
|
||||
else if(istype(W, /obj/item/bodypart/l_leg/robot))
|
||||
if(src.l_leg)
|
||||
return
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
W.icon_state = initial(W.icon_state)
|
||||
W.cut_overlays()
|
||||
src.l_leg = W
|
||||
src.updateicon()
|
||||
|
||||
else if(istype(W, /obj/item/robot_parts/r_leg))
|
||||
else if(istype(W, /obj/item/bodypart/r_leg/robot))
|
||||
if(src.r_leg)
|
||||
return
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
W.icon_state = initial(W.icon_state)
|
||||
W.cut_overlays()
|
||||
src.r_leg = W
|
||||
src.updateicon()
|
||||
|
||||
else if(istype(W, /obj/item/robot_parts/l_arm))
|
||||
else if(istype(W, /obj/item/bodypart/l_arm/robot))
|
||||
if(src.l_arm)
|
||||
return
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
W.icon_state = initial(W.icon_state)
|
||||
W.cut_overlays()
|
||||
src.l_arm = W
|
||||
src.updateicon()
|
||||
|
||||
else if(istype(W, /obj/item/robot_parts/r_arm))
|
||||
else if(istype(W, /obj/item/bodypart/r_arm/robot))
|
||||
if(src.r_arm)
|
||||
return
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
W.loc = src
|
||||
W.forceMove(src)
|
||||
W.icon_state = initial(W.icon_state)//in case it is a dismembered robotic limb
|
||||
W.cut_overlays()
|
||||
src.r_arm = W
|
||||
src.updateicon()
|
||||
|
||||
else if(istype(W, /obj/item/robot_parts/chest))
|
||||
else if(istype(W, /obj/item/bodypart/chest/robot))
|
||||
var/obj/item/bodypart/chest/robot/CH = W
|
||||
if(src.chest)
|
||||
return
|
||||
if(W:wired && W:cell)
|
||||
if(!user.unEquip(W))
|
||||
if(CH.wired && CH.cell)
|
||||
if(!user.unEquip(CH))
|
||||
return
|
||||
W.loc = src
|
||||
src.chest = W
|
||||
CH.forceMove(src)
|
||||
CH.icon_state = initial(CH.icon_state) //in case it is a dismembered robotic limb
|
||||
CH.cut_overlays()
|
||||
src.chest = CH
|
||||
src.updateicon()
|
||||
else if(!W:wired)
|
||||
else if(!CH.wired)
|
||||
user << "<span class='warning'>You need to attach wires to it first!</span>"
|
||||
else
|
||||
user << "<span class='warning'>You need to attach a cell to it first!</span>"
|
||||
|
||||
else if(istype(W, /obj/item/robot_parts/head))
|
||||
else if(istype(W, /obj/item/bodypart/head/robot))
|
||||
var/obj/item/bodypart/head/robot/HD = W
|
||||
for(var/X in HD.contents)
|
||||
if(istype(X, /obj/item/organ))
|
||||
user << "<span class='warning'>There are organs inside [HD]!</span>"
|
||||
return
|
||||
if(src.head)
|
||||
return
|
||||
if(W:flash2 && W:flash1)
|
||||
if(!user.unEquip(W))
|
||||
if(HD.flash2 && HD.flash1)
|
||||
if(!user.unEquip(HD))
|
||||
return
|
||||
W.loc = src
|
||||
src.head = W
|
||||
HD.loc = src
|
||||
HD.icon_state = initial(HD.icon_state)//in case it is a dismembered robotic limb
|
||||
HD.cut_overlays()
|
||||
src.head = HD
|
||||
src.updateicon()
|
||||
else
|
||||
user << "<span class='warning'>You need to attach a flash to it first!</span>"
|
||||
@@ -192,7 +161,7 @@
|
||||
user << "<span class='warning'>Sticking an empty MMI into the frame would sort of defeat the purpose!</span>"
|
||||
return
|
||||
|
||||
var/mob/living/carbon/brain/BM = M.brainmob
|
||||
var/mob/living/brain/BM = M.brainmob
|
||||
if(!BM.key || !BM.mind)
|
||||
user << "<span class='warning'>The mmi indicates that their mind is completely unresponsive; there's no point!</span>"
|
||||
return
|
||||
@@ -283,7 +252,7 @@
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/robot_parts/robot_suit/proc/Interact(mob/user)
|
||||
/obj/item/robot_suit/proc/Interact(mob/user)
|
||||
var/t1 = text("Designation: <A href='?src=\ref[];Name=1'>[(created_name ? "[created_name]" : "Default Cyborg")]</a><br>\n",src)
|
||||
t1 += text("Master AI: <A href='?src=\ref[];Master=1'>[(forced_ai ? "[forced_ai.name]" : "Automatic")]</a><br><br>\n",src)
|
||||
|
||||
@@ -295,8 +264,8 @@
|
||||
popup.set_content(t1)
|
||||
popup.open()
|
||||
|
||||
/obj/item/robot_parts/robot_suit/Topic(href, href_list)
|
||||
if(usr.lying || usr.stat || usr.stunned || !Adjacent(usr))
|
||||
/obj/item/robot_suit/Topic(href, href_list)
|
||||
if(usr.incapacitated() || !Adjacent(usr))
|
||||
return
|
||||
|
||||
var/mob/living/living_user = usr
|
||||
@@ -330,50 +299,4 @@
|
||||
|
||||
add_fingerprint(usr)
|
||||
Interact(usr)
|
||||
return
|
||||
|
||||
/obj/item/robot_parts/chest/attackby(obj/item/W, mob/user, params)
|
||||
if(istype(W, /obj/item/weapon/stock_parts/cell))
|
||||
if(src.cell)
|
||||
user << "<span class='warning'>You have already inserted a cell!</span>"
|
||||
return
|
||||
else
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
W.loc = src
|
||||
src.cell = W
|
||||
user << "<span class='notice'>You insert the cell.</span>"
|
||||
else if(istype(W, /obj/item/stack/cable_coil))
|
||||
if(src.wired)
|
||||
user << "<span class='warning'>You have already inserted wire!</span>"
|
||||
return
|
||||
var/obj/item/stack/cable_coil/coil = W
|
||||
if (coil.use(1))
|
||||
src.wired = 1
|
||||
user << "<span class='notice'>You insert the wire.</span>"
|
||||
else
|
||||
user << "<span class='warning'>You need one length of coil to wire it!</span>"
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/robot_parts/head/attackby(obj/item/W, mob/user, params)
|
||||
if(istype(W, /obj/item/device/assembly/flash/handheld))
|
||||
var/obj/item/device/assembly/flash/handheld/F = W
|
||||
if(src.flash1 && src.flash2)
|
||||
user << "<span class='warning'>You have already inserted the eyes!</span>"
|
||||
return
|
||||
else if(F.crit_fail)
|
||||
user << "<span class='warning'>You can't use a broken flash!</span>"
|
||||
return
|
||||
else
|
||||
if(!user.unEquip(W))
|
||||
return
|
||||
F.loc = src
|
||||
if(src.flash1)
|
||||
src.flash2 = F
|
||||
else
|
||||
src.flash1 = F
|
||||
user << "<span class='notice'>You insert the flash into the eye socket.</span>"
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -30,19 +30,21 @@
|
||||
return 1
|
||||
|
||||
var/obj/item/bodypart/affecting
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
affecting = H.get_bodypart(check_zone(user.zone_selected))
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
affecting = C.get_bodypart(check_zone(user.zone_selected))
|
||||
if(!affecting) //Missing limb?
|
||||
user << "<span class='warning'>[H] doesn't have \a [parse_zone(user.zone_selected)]!</span>"
|
||||
user << "<span class='warning'>[C] doesn't have \a [parse_zone(user.zone_selected)]!</span>"
|
||||
return
|
||||
if(stop_bleeding)
|
||||
if(H.bleedsuppress)
|
||||
user << "<span class='warning'>[H]'s bleeding is already bandaged!</span>"
|
||||
return
|
||||
else if(!H.bleed_rate)
|
||||
user << "<span class='warning'>[H] isn't bleeding!</span>"
|
||||
return
|
||||
if(ishuman(C))
|
||||
var/mob/living/carbon/human/H = C
|
||||
if(stop_bleeding)
|
||||
if(H.bleedsuppress)
|
||||
user << "<span class='warning'>[H]'s bleeding is already bandaged!</span>"
|
||||
return
|
||||
else if(!H.bleed_rate)
|
||||
user << "<span class='warning'>[H] isn't bleeding!</span>"
|
||||
return
|
||||
|
||||
|
||||
if(isliving(M))
|
||||
@@ -75,25 +77,24 @@
|
||||
user.visible_message("<span class='green'>[user] applies [src] on [t_himself].</span>", "<span class='green'>You apply [src] on yourself.</span>")
|
||||
|
||||
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
affecting = H.get_bodypart(check_zone(user.zone_selected))
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
affecting = C.get_bodypart(check_zone(user.zone_selected))
|
||||
if(!affecting) //Missing limb?
|
||||
user << "<span class='warning'>[H] doesn't have \a [parse_zone(user.zone_selected)]!</span>"
|
||||
user << "<span class='warning'>[C] doesn't have \a [parse_zone(user.zone_selected)]!</span>"
|
||||
return
|
||||
if(stop_bleeding)
|
||||
if(!H.bleedsuppress) //so you can't stack bleed suppression
|
||||
H.suppress_bloodloss(stop_bleeding)
|
||||
if(affecting.status == ORGAN_ORGANIC) //Limb must be organic to be healed - RR
|
||||
if(affecting.heal_damage(src.heal_brute, src.heal_burn, 0))
|
||||
H.update_damage_overlays(0)
|
||||
|
||||
M.updatehealth()
|
||||
if(ishuman(C))
|
||||
var/mob/living/carbon/human/H = C
|
||||
if(stop_bleeding)
|
||||
if(!H.bleedsuppress) //so you can't stack bleed suppression
|
||||
H.suppress_bloodloss(stop_bleeding)
|
||||
if(affecting.status == BODYPART_ORGANIC) //Limb must be organic to be healed - RR
|
||||
if(affecting.heal_damage(heal_brute, heal_burn))
|
||||
C.update_damage_overlays()
|
||||
else
|
||||
user << "<span class='notice'>Medicine won't work on a robotic limb!</span>"
|
||||
else
|
||||
M.heal_organ_damage((src.heal_brute/2), (src.heal_burn/2))
|
||||
|
||||
M.heal_bodypart_damage((src.heal_brute/2), (src.heal_burn/2))
|
||||
|
||||
use(1)
|
||||
|
||||
|
||||
@@ -311,19 +311,16 @@
|
||||
return
|
||||
if(istype(A, /obj/item/weapon/storage))
|
||||
return
|
||||
|
||||
var/hit_hand = ((user.active_hand_index % 2 == 0) ? "r_" : "l_") + "arm"
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(!H.gloves && !(PIERCEIMMUNE in H.dna.species.specflags)) // golems, etc
|
||||
H << "<span class='warning'>[src] cuts into your hand!</span>"
|
||||
var/organ = ((H.active_hand_index % 2 == 0) ? "r_" : "l_") + "arm"
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart(organ)
|
||||
if(affecting && affecting.take_damage(force / 2))
|
||||
H.update_damage_overlays(0)
|
||||
H.apply_damage(force*0.5, BRUTE, hit_hand)
|
||||
else if(ismonkey(user))
|
||||
var/mob/living/carbon/monkey/M = user
|
||||
M << "<span class='warning'>[src] cuts into your hand!</span>"
|
||||
M.adjustBruteLoss(force / 2)
|
||||
M.apply_damage(force*0.5, BRUTE, hit_hand)
|
||||
|
||||
|
||||
/obj/item/weapon/shard/attackby(obj/item/I, mob/user, params)
|
||||
|
||||
@@ -22,8 +22,6 @@
|
||||
M.show_message("<span class='warning'>BANG</span>", 2)
|
||||
playsound(loc, 'sound/weapons/flashbang.ogg', 100, 1)
|
||||
|
||||
//Checking for protection
|
||||
var/ear_safety = M.check_ear_prot()
|
||||
var/distance = max(1,get_dist(src,T))
|
||||
|
||||
//Flash
|
||||
@@ -34,24 +32,12 @@
|
||||
M.Stun(15)
|
||||
M.adjust_eye_damage(8)
|
||||
|
||||
if(M.flash_eyes(affect_silicon = 1))
|
||||
if(M.flash_act(affect_silicon = 1))
|
||||
M.Stun(max(10/distance, 3))
|
||||
M.Weaken(max(10/distance, 3))
|
||||
|
||||
//Bang
|
||||
if((loc == M) || loc == M.loc)//Holding on person or being exactly where lies is significantly more dangerous and voids protection
|
||||
M.Stun(10)
|
||||
M.Weaken(10)
|
||||
if(!ear_safety)
|
||||
M << sound('sound/weapons/flash_ring.ogg',0,1,0,100)
|
||||
M.Stun(max(10/distance, 3))
|
||||
M.Weaken(max(10/distance, 3))
|
||||
M.setEarDamage(M.ear_damage + rand(0, 5), max(M.ear_deaf,15))
|
||||
if (M.ear_damage >= 15)
|
||||
M << "<span class='warning'>Your ears start to ring badly!</span>"
|
||||
if(prob(M.ear_damage - 10 + 5))
|
||||
M << "<span class='warning'>You can't hear anything!</span>"
|
||||
M.disabilities |= DEAF
|
||||
else
|
||||
if (M.ear_damage >= 5)
|
||||
M << "<span class='warning'>Your ears start to ring!</span>"
|
||||
M.soundbang_act(1, 10, rand(5, 10))
|
||||
else
|
||||
M.soundbang_act(1, max(10/distance, 3), rand(0, 5))
|
||||
|
||||
@@ -108,7 +108,7 @@
|
||||
target = user
|
||||
sleep(10)
|
||||
prime()
|
||||
user.gib(no_brain = 1)
|
||||
user.gib(1, 1, 1)
|
||||
|
||||
/obj/item/weapon/grenade/plastic/update_icon()
|
||||
if(nadeassembly)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
var/turf/T = get_turf(src)
|
||||
playsound(T, 'sound/effects/phasein.ogg', 100, 1)
|
||||
for(var/mob/living/carbon/C in viewers(T, null))
|
||||
C.flash_eyes()
|
||||
C.flash_act()
|
||||
|
||||
for(var/i=1, i<=deliveryamt, i++)
|
||||
var/atom/movable/x = new spawner_type
|
||||
|
||||
@@ -30,12 +30,12 @@
|
||||
return
|
||||
|
||||
if(!C.handcuffed)
|
||||
if(C.get_num_arms() >= 2)
|
||||
if(C.get_num_arms() >= 2 || C.get_arm_ignore())
|
||||
C.visible_message("<span class='danger'>[user] is trying to put [src.name] on [C]!</span>", \
|
||||
"<span class='userdanger'>[user] is trying to put [src.name] on [C]!</span>")
|
||||
|
||||
playsound(loc, cuffsound, 30, 1, -2)
|
||||
if(do_mob(user, C, 30) && C.get_num_arms() >= 2)
|
||||
if(do_mob(user, C, 30) && (C.get_num_arms() >= 2 || C.get_arm_ignore()))
|
||||
apply_cuffs(C,user)
|
||||
user << "<span class='notice'>You handcuff [C].</span>"
|
||||
if(istype(src, /obj/item/weapon/restraints/handcuffs/cable))
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
/obj/item/weapon/melee/energy/attack_self(mob/living/carbon/user)
|
||||
if(user.disabilities & CLUMSY && prob(50))
|
||||
user << "<span class='warning'>You accidentally cut yourself with [src], like a doofus!</span>"
|
||||
user.take_organ_damage(5,5)
|
||||
user.take_bodypart_damage(5,5)
|
||||
active = !active
|
||||
if (active)
|
||||
force = force_on
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.apply_damage(2*force, BRUTE, "head")
|
||||
else
|
||||
user.take_organ_damage(2*force)
|
||||
user.take_bodypart_damage(2*force)
|
||||
return
|
||||
if(isrobot(target))
|
||||
..()
|
||||
@@ -124,7 +124,7 @@
|
||||
if (B && !qdeleted(B))
|
||||
H.internal_organs -= B
|
||||
qdel(B)
|
||||
gibs(H.loc, H.viruses, H.dna)
|
||||
new /obj/effect/gibspawner/generic(H.loc, H.viruses, H.dna)
|
||||
return (BRUTELOSS)
|
||||
|
||||
/obj/item/weapon/melee/classic_baton/telescopic/attack_self(mob/user)
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
/obj/item/weapon/shield/energy/attack_self(mob/living/carbon/human/user)
|
||||
if(user.disabilities & CLUMSY && prob(50))
|
||||
user << "<span class='warning'>You beat yourself in the head with [src].</span>"
|
||||
user.take_organ_damage(5)
|
||||
user.take_bodypart_damage(5)
|
||||
active = !active
|
||||
icon_state = "eshield[active]"
|
||||
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
charged = 0
|
||||
if(istype(A, /mob/living/))
|
||||
var/mob/living/Z = A
|
||||
Z.take_organ_damage(20,0)
|
||||
Z.take_bodypart_damage(20,0)
|
||||
playsound(user, 'sound/weapons/marauder.ogg', 50, 1)
|
||||
var/turf/target = get_turf(A)
|
||||
vortex(target,user)
|
||||
|
||||
@@ -114,15 +114,27 @@ var/global/list/bibleitemstates = list("bible", "koran", "scrapbook", "bible", "
|
||||
|
||||
usr << browse(null, "window=editicon") // Close window
|
||||
|
||||
/obj/item/weapon/storage/book/bible/proc/bless(mob/living/carbon/M)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/heal_amt = 10
|
||||
for(var/obj/item/bodypart/affecting in H.bodyparts)
|
||||
if(affecting.status == ORGAN_ORGANIC) //No Bible can heal a robotic arm!
|
||||
if(affecting.heal_damage(heal_amt, heal_amt, 0))
|
||||
H.update_damage_overlays(0)
|
||||
return
|
||||
/obj/item/weapon/storage/book/bible/proc/bless(mob/living/carbon/human/H, mob/living/user)
|
||||
for(var/X in H.bodyparts)
|
||||
var/obj/item/bodypart/BP = X
|
||||
if(BP.status == BODYPART_ROBOTIC)
|
||||
user << "<span class='warning'>[src.deity_name] refuses to heal this metallic taint!</span>"
|
||||
return 0
|
||||
|
||||
var/heal_amt = 10
|
||||
var/list/hurt_limbs = H.get_damaged_bodyparts(1, 1)
|
||||
|
||||
if(hurt_limbs.len)
|
||||
for(var/X in hurt_limbs)
|
||||
var/obj/item/bodypart/affecting = X
|
||||
if(affecting.heal_damage(heal_amt, heal_amt))
|
||||
H.update_damage_overlays()
|
||||
H.visible_message("<span class='notice'>[user] heals [H] with the power of [deity_name]!</span>")
|
||||
H << "<span class='boldnotice'>May the power of [deity_name] compel you to be healed!</span>"
|
||||
playsound(src.loc, "punch", 25, 1, -1)
|
||||
return 1
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/storage/book/bible/attack(mob/living/M, mob/living/carbon/human/user)
|
||||
|
||||
@@ -137,51 +149,40 @@ var/global/list/bibleitemstates = list("bible", "koran", "scrapbook", "bible", "
|
||||
return
|
||||
if(!chaplain)
|
||||
user << "<span class='danger'>The book sizzles in your hands.</span>"
|
||||
user.take_organ_damage(0,10)
|
||||
user.take_bodypart_damage(0,10)
|
||||
return
|
||||
|
||||
if (user.disabilities & CLUMSY && prob(50))
|
||||
user << "<span class='danger'>The [src] slips out of your hand and hits your head.</span>"
|
||||
user.take_organ_damage(10)
|
||||
user.take_bodypart_damage(10)
|
||||
user.Paralyse(20)
|
||||
return
|
||||
|
||||
if (M.stat !=2)
|
||||
if(M.mind && (M.mind.assigned_role == "Chaplain"))
|
||||
var/smack = 1
|
||||
|
||||
if (M.stat != DEAD)
|
||||
if(chaplain && user == M)
|
||||
user << "<span class='warning'>You can't heal yourself!</span>"
|
||||
return
|
||||
if ((istype(M, /mob/living/carbon/human) && prob(60)))
|
||||
bless(M)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/message_halt = 0
|
||||
for(var/obj/item/bodypart/affecting in H.bodyparts)
|
||||
if(affecting.status == ORGAN_ORGANIC)
|
||||
if(message_halt == 0)
|
||||
M.visible_message("<span class='notice'>[user] heals [M] with the power of [src.deity_name]!</span>")
|
||||
M << "<span class='boldnotice'>May the power of [src.deity_name] compel you to be healed!</span>"
|
||||
playsound(src.loc, "punch", 25, 1, -1)
|
||||
message_halt = 1
|
||||
else
|
||||
user << "<span class='warning'>[src.deity_name] refuses to heal this metallic taint!</span>"
|
||||
return
|
||||
|
||||
if(ishuman(M) && prob(60) && bless(M, user))
|
||||
smack = 0
|
||||
else if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
if(!istype(C.head, /obj/item/clothing/head/helmet))
|
||||
C.adjustBrainLoss(10)
|
||||
C << "<span class='danger'>You feel dumber.</span>"
|
||||
|
||||
|
||||
|
||||
else
|
||||
if(ishuman(M) && !istype(M:head, /obj/item/clothing/head/helmet))
|
||||
M.adjustBrainLoss(10)
|
||||
M << "<span class='danger'>You feel dumber.</span>"
|
||||
if(smack)
|
||||
M.visible_message("<span class='danger'>[user] beats [M] over the head with [src]!</span>", \
|
||||
"<span class='userdanger'>[user] beats [M] over the head with [src]!</span>")
|
||||
playsound(src.loc, "punch", 25, 1, -1)
|
||||
add_logs(user, M, "attacked", src)
|
||||
|
||||
else if(M.stat == 2)
|
||||
else
|
||||
M.visible_message("<span class='danger'>[user] smacks [M]'s lifeless corpse with [src].</span>")
|
||||
playsound(src.loc, "punch", 25, 1, -1)
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/storage/book/bible/afterattack(atom/A, mob/user, proximity)
|
||||
if(!proximity)
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
H.hair_style = "Bald"
|
||||
H.update_hair()
|
||||
H.bleed_rate = 5
|
||||
gibs(H.loc, H.viruses, H.dna)
|
||||
new /obj/effect/gibspawner/generic(H.loc, H.viruses, H.dna)
|
||||
H.adjustBruteLoss(1000) //to make the body super-bloody
|
||||
|
||||
return (BRUTELOSS)
|
||||
|
||||
@@ -298,7 +298,7 @@
|
||||
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart(check_zone(user.zone_selected))
|
||||
|
||||
if(affecting && affecting.status == ORGAN_ROBOTIC && user.a_intent != "harm")
|
||||
if(affecting && affecting.status == BODYPART_ROBOTIC && user.a_intent != "harm")
|
||||
if(src.remove_fuel(1))
|
||||
playsound(loc, 'sound/items/Welder.ogg', 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] starts to fix some of the dents on [H]'s [affecting.name].</span>", "<span class='notice'>You start fixing some of the dents on [H]'s [affecting.name].</span>")
|
||||
@@ -347,7 +347,7 @@
|
||||
reagents.remove_reagent("welding_fuel", amount)
|
||||
check_fuel()
|
||||
if(M)
|
||||
M.flash_eyes(light_intensity)
|
||||
M.flash_act(light_intensity)
|
||||
return TRUE
|
||||
else
|
||||
if(M)
|
||||
|
||||
@@ -256,7 +256,7 @@
|
||||
/obj/item/weapon/twohanded/dualsaber/proc/impale(mob/living/user)
|
||||
user << "<span class='warning'>You twirl around a bit before losing your balance and impaling yourself on \the [src].</span>"
|
||||
if (force_wielded)
|
||||
user.take_organ_damage(20,25)
|
||||
user.take_bodypart_damage(20,25)
|
||||
else
|
||||
user.adjustStaminaLoss(25)
|
||||
|
||||
|
||||
@@ -26,7 +26,8 @@
|
||||
organ.implant(C)
|
||||
|
||||
if("drop organ/implant", "remove organ/implant")
|
||||
for(var/obj/item/organ/I in C.internal_organs)
|
||||
for(var/X in C.internal_organs)
|
||||
var/obj/item/organ/I = X
|
||||
organs["[I.name] ([I.type])"] = I
|
||||
|
||||
for(var/obj/item/weapon/implant/I in C)
|
||||
|
||||
@@ -441,7 +441,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
|
||||
var/datum/round_event/ion_storm/ion = new(0, announce_ion_laws, input)
|
||||
ion.start()
|
||||
|
||||
|
||||
feedback_add_details("admin_verb","IONC") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/cmd_admin_rejuvenate(mob/living/M in mob_list)
|
||||
@@ -595,7 +595,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
message_admins("[key_name_admin(usr)] has gibbed [key_name_admin(M)]")
|
||||
|
||||
if(istype(M, /mob/dead/observer))
|
||||
gibs(M.loc, M.viruses)
|
||||
new /obj/effect/gibspawner/generic(M.loc, M.viruses)
|
||||
return
|
||||
if(confirm == "Yes")
|
||||
M.gib()
|
||||
@@ -612,7 +612,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
log_admin("[key_name(usr)] used gibself.")
|
||||
message_admins("<span class='adminnotice'>[key_name_admin(usr)] used gibself.</span>")
|
||||
feedback_add_details("admin_verb","GIBS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
mob.gib(1, 1)
|
||||
mob.gib(1, 1, 1)
|
||||
|
||||
/client/proc/cmd_admin_check_contents(mob/living/M in mob_list)
|
||||
set category = "Special Verbs"
|
||||
@@ -1152,4 +1152,4 @@ var/list/datum/outfit/custom_outfits = list() //Admin created outfits
|
||||
for(var/datum/station_goal/S in ticker.mode.station_goals)
|
||||
dat += "[S.name] - <a href='?src=\ref[S];announce=1'>Announce</a> | <a href='?src=\ref[S];remove=1'>Remove</a><br>"
|
||||
dat += "<br><a href='?src=\ref[src];add_station_goal=1'>Add New Goal</a>"
|
||||
usr << browse(dat, "window=goals;size=400x400")
|
||||
usr << browse(dat, "window=goals;size=400x400")
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
if(user && targeted)
|
||||
if(M.weakeyes)
|
||||
M.Weaken(3) //quick weaken bypasses eye protection but has no eye flash
|
||||
if(M.flash_eyes(1, 1))
|
||||
if(M.flash_act(1, 1))
|
||||
M.confused += power
|
||||
terrible_conversion_proc(M, user)
|
||||
M.Stun(1)
|
||||
@@ -100,7 +100,7 @@
|
||||
user << "<span class='warning'>You fail to blind [M] with the flash!</span>"
|
||||
M << "<span class='danger'>[user] fails to blind you with the flash!</span>"
|
||||
else
|
||||
if(M.flash_eyes())
|
||||
if(M.flash_act())
|
||||
M.confused += power
|
||||
|
||||
/obj/item/device/assembly/flash/attack(mob/living/M, mob/user)
|
||||
@@ -117,7 +117,7 @@
|
||||
update_icon(1)
|
||||
M.Weaken(6)
|
||||
R.confused += 5
|
||||
R.flash_eyes(affect_silicon = 1)
|
||||
R.flash_act(affect_silicon = 1)
|
||||
user.visible_message("<span class='disarm'>[user] overloads [R]'s sensors with the flash!</span>", "<span class='danger'>You overload [R]'s sensors with the flash!</span>")
|
||||
return 1
|
||||
|
||||
|
||||
@@ -60,8 +60,7 @@
|
||||
H.Stun(3)
|
||||
if(affecting)
|
||||
if(affecting.take_damage(1, 0))
|
||||
H.update_damage_overlays(0)
|
||||
H.updatehealth()
|
||||
H.update_damage_overlays()
|
||||
else if(ismouse(target))
|
||||
var/mob/living/simple_animal/mouse/M = target
|
||||
visible_message("<span class='boldannounce'>SPLAT!</span>")
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
adjustOxyLoss(max(200 - getToxLoss() - getFireLoss() - getBruteLoss() - getOxyLoss(), 0))
|
||||
death(0)
|
||||
|
||||
/mob/living/carbon/brain/verb/suicide()
|
||||
/mob/living/brain/verb/suicide()
|
||||
set hidden = 1
|
||||
if(!canSuicide())
|
||||
return
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
if(!(H.disabilities & BLIND))
|
||||
if(H.glasses == src)
|
||||
H << "<span class='danger'>The [src] overloads and blinds you!</span>"
|
||||
H.flash_eyes(visual = 1)
|
||||
H.flash_act(visual = 1)
|
||||
H.blind_eyes(3)
|
||||
H.blur_eyes(5)
|
||||
H.adjust_eye_damage(5)
|
||||
|
||||
@@ -94,17 +94,17 @@
|
||||
/datum/crafting_recipe/ed209
|
||||
name = "ED209"
|
||||
result = /mob/living/simple_animal/bot/ed209
|
||||
reqs = list(/obj/item/robot_parts/robot_suit = 1,
|
||||
reqs = list(/obj/item/robot_suit = 1,
|
||||
/obj/item/clothing/head/helmet = 1,
|
||||
/obj/item/clothing/suit/armor/vest = 1,
|
||||
/obj/item/robot_parts/l_leg = 1,
|
||||
/obj/item/robot_parts/r_leg = 1,
|
||||
/obj/item/bodypart/l_leg/robot = 1,
|
||||
/obj/item/bodypart/r_leg/robot = 1,
|
||||
/obj/item/stack/sheet/metal = 5,
|
||||
/obj/item/stack/cable_coil = 5,
|
||||
/obj/item/weapon/gun/energy/gun/advtaser = 1,
|
||||
/obj/item/weapon/stock_parts/cell = 1,
|
||||
/obj/item/device/assembly/prox_sensor = 1,
|
||||
/obj/item/robot_parts/r_arm = 1)
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
tools = list(/obj/item/weapon/weldingtool, /obj/item/weapon/screwdriver)
|
||||
time = 60
|
||||
category = CAT_ROBOT
|
||||
@@ -116,7 +116,7 @@
|
||||
/obj/item/clothing/head/helmet/sec = 1,
|
||||
/obj/item/weapon/melee/baton = 1,
|
||||
/obj/item/device/assembly/prox_sensor = 1,
|
||||
/obj/item/robot_parts/r_arm = 1)
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
tools = list(/obj/item/weapon/weldingtool)
|
||||
time = 60
|
||||
category = CAT_ROBOT
|
||||
@@ -126,7 +126,7 @@
|
||||
result = /mob/living/simple_animal/bot/cleanbot
|
||||
reqs = list(/obj/item/weapon/reagent_containers/glass/bucket = 1,
|
||||
/obj/item/device/assembly/prox_sensor = 1,
|
||||
/obj/item/robot_parts/r_arm = 1)
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
time = 40
|
||||
category = CAT_ROBOT
|
||||
|
||||
@@ -136,7 +136,7 @@
|
||||
reqs = list(/obj/item/weapon/storage/toolbox/mechanical = 1,
|
||||
/obj/item/stack/tile/plasteel = 1,
|
||||
/obj/item/device/assembly/prox_sensor = 1,
|
||||
/obj/item/robot_parts/r_arm = 1)
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
time = 40
|
||||
category = CAT_ROBOT
|
||||
|
||||
@@ -146,7 +146,7 @@
|
||||
reqs = list(/obj/item/device/healthanalyzer = 1,
|
||||
/obj/item/weapon/storage/firstaid = 1,
|
||||
/obj/item/device/assembly/prox_sensor = 1,
|
||||
/obj/item/robot_parts/r_arm = 1)
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
time = 40
|
||||
category = CAT_ROBOT
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
var/list/flashers = list()
|
||||
for(var/mob/living/carbon/C in viewers(TO, null))
|
||||
if(C.flash_eyes())
|
||||
if(C.flash_act())
|
||||
flashers += C
|
||||
|
||||
var/y_distance = TO.y - FROM.y
|
||||
|
||||
@@ -51,16 +51,13 @@
|
||||
if(!iscarbon(user))
|
||||
return 0
|
||||
var/mob/living/carbon/C = user
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = C
|
||||
if(H.gloves)
|
||||
return 0
|
||||
var/organ = (H.held_index_to_dir(H.active_hand_index) == "l" ? "l_":"r_") + "arm"
|
||||
var/obj/item/bodypart/affecting = H.get_bodypart(organ)
|
||||
if(affecting && affecting.take_damage(0, force))
|
||||
H.update_damage_overlays(0)
|
||||
else
|
||||
C.take_organ_damage(0,force)
|
||||
if(C.gloves)
|
||||
return 0
|
||||
var/hit_zone = (C.held_index_to_dir(C.active_hand_index) == "l" ? "l_":"r_") + "arm"
|
||||
var/obj/item/bodypart/affecting = C.get_bodypart(hit_zone)
|
||||
if(affecting)
|
||||
if(affecting.take_damage(0, force))
|
||||
C.update_damage_overlays()
|
||||
C << "<span class='userdanger'>The nettle burns your bare hand!</span>"
|
||||
return 1
|
||||
|
||||
|
||||
@@ -507,7 +507,7 @@
|
||||
range = 6
|
||||
var/obj/item/weapon/twohanded/required/mining_hammer/hammer_synced = null
|
||||
|
||||
/obj/item/projectile/destabilizer/on_hit(atom/target, blocked = 0, hit_zone)
|
||||
/obj/item/projectile/destabilizer/on_hit(atom/target, blocked = 0)
|
||||
if(hammer_synced)
|
||||
if(hammer_synced.mark == target)
|
||||
return ..()
|
||||
|
||||
@@ -137,13 +137,14 @@
|
||||
retal = 1
|
||||
retal_target = user
|
||||
|
||||
/mob/living/carbon/human/interactive/bullet_act(var/obj/item/projectile/P)
|
||||
/mob/living/carbon/human/interactive/bullet_act(obj/item/projectile/P, def_zone)
|
||||
var/potentialAssault = locate(/mob/living) in view(2,P.starting)
|
||||
if(potentialAssault)
|
||||
retal = 1
|
||||
retal_target = potentialAssault
|
||||
..()
|
||||
|
||||
|
||||
/client/proc/resetSNPC(var/mob/A in SSnpc.botPool_l)
|
||||
set name = "Reset SNPC"
|
||||
set desc = "Reset the SNPC"
|
||||
@@ -296,9 +297,9 @@
|
||||
for(var/X in bodyparts)
|
||||
var/obj/item/bodypart/BP = X
|
||||
if(prob((FUZZY_CHANCE_LOW+FUZZY_CHANCE_HIGH)/4))
|
||||
BP.change_bodypart_status(ORGAN_ROBOTIC)
|
||||
BP.change_bodypart_status(BODYPART_ROBOTIC)
|
||||
update_icons()
|
||||
update_damage_overlays(0)
|
||||
update_damage_overlays()
|
||||
functions = list("nearbyscan","combat","shitcurity","chatter") // stop customize adding multiple copies of a function
|
||||
//job specific favours
|
||||
switch(myjob.title)
|
||||
@@ -422,10 +423,6 @@
|
||||
if(C)
|
||||
retalTarget(C)
|
||||
|
||||
/mob/living/carbon/human/interactive/bullet_act(obj/item/projectile/P, def_zone)
|
||||
..(P,def_zone)
|
||||
retalTarget(P.firer)
|
||||
|
||||
/mob/living/carbon/human/interactive/attack_hand(mob/living/carbon/human/M)
|
||||
..(M)
|
||||
retalTarget(M)
|
||||
|
||||
+197
-198
@@ -1,198 +1,197 @@
|
||||
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:32
|
||||
|
||||
/obj/item/device/mmi
|
||||
name = "Man-Machine Interface"
|
||||
desc = "The Warrior's bland acronym, MMI, obscures the true horror of this monstrosity, that nevertheless has become standard-issue on Nanotrasen stations."
|
||||
icon = 'icons/obj/assemblies.dmi'
|
||||
icon_state = "mmi_empty"
|
||||
w_class = 3
|
||||
origin_tech = "biotech=2;programming=3;engineering=2"
|
||||
var/braintype = "Cyborg"
|
||||
var/obj/item/device/radio/radio = null //Let's give it a radio.
|
||||
var/hacked = 0 //Whether or not this is a Syndicate MMI
|
||||
var/mob/living/carbon/brain/brainmob = null //The current occupant.
|
||||
var/mob/living/silicon/robot = null //Appears unused.
|
||||
var/obj/mecha = null //This does not appear to be used outside of reference in mecha.dm.
|
||||
var/obj/item/organ/brain/brain = null //The actual brain
|
||||
var/clockwork = FALSE //If this is a soul vessel
|
||||
|
||||
/obj/item/device/mmi/update_icon()
|
||||
if(brain)
|
||||
if(istype(brain,/obj/item/organ/brain/alien))
|
||||
if(brainmob && brainmob.stat == DEAD)
|
||||
icon_state = "mmi_alien_dead"
|
||||
else
|
||||
icon_state = "mmi_alien"
|
||||
braintype = "Xenoborg" //HISS....Beep.
|
||||
else
|
||||
if(brainmob && brainmob.stat == DEAD)
|
||||
icon_state = "mmi_dead"
|
||||
else
|
||||
icon_state = "mmi_full"
|
||||
braintype = "Cyborg"
|
||||
else
|
||||
icon_state = "mmi_empty"
|
||||
|
||||
/obj/item/device/mmi/New()
|
||||
..()
|
||||
radio = new(src) //Spawns a radio inside the MMI.
|
||||
radio.broadcasting = 0 //researching radio mmis turned the robofabs into radios because this didnt start as 0.
|
||||
|
||||
|
||||
|
||||
/obj/item/device/mmi/attackby(obj/item/O, mob/user, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
if(istype(O,/obj/item/organ/brain)) //Time to stick a brain in it --NEO
|
||||
var/obj/item/organ/brain/newbrain = O
|
||||
if(brain)
|
||||
user << "<span class='warning'>There's already a brain in the MMI!</span>"
|
||||
return
|
||||
if(!newbrain.brainmob)
|
||||
user << "<span class='warning'>You aren't sure where this brain came from, but you're pretty sure it's a useless brain!</span>"
|
||||
return
|
||||
|
||||
if(!user.unEquip(O))
|
||||
return
|
||||
var/mob/living/carbon/brain/B = newbrain.brainmob
|
||||
if(!B.key)
|
||||
B.notify_ghost_cloning("Someone has put your brain in a MMI!", source = src)
|
||||
visible_message("[user] sticks \a [newbrain] into \the [src].")
|
||||
|
||||
brainmob = newbrain.brainmob
|
||||
newbrain.brainmob = null
|
||||
brainmob.loc = src
|
||||
brainmob.container = src
|
||||
if(!newbrain.damaged_brain) // the brain organ hasn't been beaten to death.
|
||||
brainmob.stat = CONSCIOUS //we manually revive the brain mob
|
||||
dead_mob_list -= brainmob
|
||||
living_mob_list += brainmob
|
||||
|
||||
brainmob.reset_perspective()
|
||||
if(clockwork)
|
||||
add_servant_of_ratvar(brainmob, TRUE)
|
||||
newbrain.loc = src //P-put your brain in it
|
||||
brain = newbrain
|
||||
|
||||
name = "Man-Machine Interface: [brainmob.real_name]"
|
||||
update_icon()
|
||||
|
||||
feedback_inc("cyborg_mmis_filled",1)
|
||||
|
||||
return
|
||||
|
||||
else if(brainmob)
|
||||
O.attack(brainmob, user) //Oh noooeeeee
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/device/mmi/attack_self(mob/user)
|
||||
if(!brain)
|
||||
radio.on = !radio.on
|
||||
user << "<span class='notice'>You toggle the MMI's radio system [radio.on==1 ? "on" : "off"].</span>"
|
||||
else
|
||||
user << "<span class='notice'>You unlock and upend the MMI, spilling the brain onto the floor.</span>"
|
||||
|
||||
brainmob.container = null //Reset brainmob mmi var.
|
||||
brainmob.loc = brain //Throw mob into brain.
|
||||
brainmob.stat = DEAD
|
||||
brainmob.emp_damage = 0
|
||||
brainmob.reset_perspective() //so the brainmob follows the brain organ instead of the mmi. And to update our vision
|
||||
living_mob_list -= brainmob //Get outta here
|
||||
dead_mob_list += brainmob
|
||||
brain.brainmob = brainmob //Set the brain to use the brainmob
|
||||
brainmob = null //Set mmi brainmob var to null
|
||||
|
||||
user.put_in_hands(brain) //puts brain in the user's hand or otherwise drops it on the user's turf
|
||||
brain = null //No more brain in here
|
||||
|
||||
update_icon()
|
||||
name = "Man-Machine Interface"
|
||||
|
||||
/obj/item/device/mmi/proc/transfer_identity(mob/living/L) //Same deal as the regular brain proc. Used for human-->robot people.
|
||||
if(!brainmob)
|
||||
brainmob = new(src)
|
||||
brainmob.name = L.real_name
|
||||
brainmob.real_name = L.real_name
|
||||
if(L.has_dna())
|
||||
var/mob/living/carbon/C = L
|
||||
if(!brainmob.dna)
|
||||
brainmob.dna = new /datum/dna(brainmob)
|
||||
C.dna.copy_dna(brainmob.dna)
|
||||
brainmob.container = src
|
||||
|
||||
if(ishuman(L))
|
||||
var/mob/living/carbon/human/H = L
|
||||
var/obj/item/organ/brain/newbrain = H.getorgan(/obj/item/organ/brain)
|
||||
newbrain.loc = src
|
||||
brain = newbrain
|
||||
else if(!brain)
|
||||
brain = new(src)
|
||||
brain.name = "[L.real_name]'s brain"
|
||||
|
||||
name = "Man-Machine Interface: [brainmob.real_name]"
|
||||
update_icon()
|
||||
return
|
||||
|
||||
|
||||
/obj/item/device/mmi/verb/Toggle_Listening()
|
||||
set name = "Toggle Listening"
|
||||
set desc = "Toggle listening channel on or off."
|
||||
set category = "MMI"
|
||||
set src = usr.loc
|
||||
set popup_menu = 0
|
||||
|
||||
if(brainmob.stat)
|
||||
brainmob << "<span class='warning'>Can't do that while incapacitated or dead!</span>"
|
||||
if(!radio.on)
|
||||
brainmob << "<span class='warning'>Your radio is disabled!</span>"
|
||||
return
|
||||
|
||||
radio.listening = radio.listening==1 ? 0 : 1
|
||||
brainmob << "<span class='notice'>Radio is [radio.listening==1 ? "now" : "no longer"] receiving broadcast.</span>"
|
||||
|
||||
/obj/item/device/mmi/emp_act(severity)
|
||||
if(!brainmob)
|
||||
return
|
||||
else
|
||||
switch(severity)
|
||||
if(1)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(20,30), 30)
|
||||
if(2)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(10,20), 30)
|
||||
if(3)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(0,10), 30)
|
||||
brainmob.emote("alarm")
|
||||
..()
|
||||
|
||||
/obj/item/device/mmi/Destroy()
|
||||
if(isrobot(loc))
|
||||
var/mob/living/silicon/robot/borg = loc
|
||||
borg.mmi = null
|
||||
if(brainmob)
|
||||
qdel(brainmob)
|
||||
brainmob = null
|
||||
return ..()
|
||||
|
||||
/obj/item/device/mmi/examine(mob/user)
|
||||
..()
|
||||
if(brainmob)
|
||||
var/mob/living/carbon/brain/B = brainmob
|
||||
if(!B.key || !B.mind || B.stat == DEAD)
|
||||
user << "<span class='warning'>The MMI indicates the brain is completely unresponsive.</span>"
|
||||
|
||||
else if(!B.client)
|
||||
user << "<span class='warning'>The MMI indicates the brain is currently inactive; it might change.</span>"
|
||||
|
||||
else
|
||||
user << "<span class='notice'>The MMI indicates the brain is active.</span>"
|
||||
|
||||
|
||||
/obj/item/device/mmi/syndie
|
||||
name = "Syndicate Man-Machine Interface"
|
||||
desc = "Syndicate's own brand of MMI. It enforces laws designed to help Syndicate agents achieve their goals upon cyborgs created with it, but doesn't fit in Nanotrasen AI cores."
|
||||
origin_tech = "biotech=4;programming=4;syndicate=2"
|
||||
hacked = 1
|
||||
|
||||
/obj/item/device/mmi/syndie/New()
|
||||
..()
|
||||
radio.on = 0
|
||||
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:32
|
||||
|
||||
/obj/item/device/mmi
|
||||
name = "Man-Machine Interface"
|
||||
desc = "The Warrior's bland acronym, MMI, obscures the true horror of this monstrosity, that nevertheless has become standard-issue on Nanotrasen stations."
|
||||
icon = 'icons/obj/assemblies.dmi'
|
||||
icon_state = "mmi_empty"
|
||||
w_class = 3
|
||||
origin_tech = "biotech=2;programming=3;engineering=2"
|
||||
var/braintype = "Cyborg"
|
||||
var/obj/item/device/radio/radio = null //Let's give it a radio.
|
||||
var/hacked = 0 //Whether or not this is a Syndicate MMI
|
||||
var/mob/living/brain/brainmob = null //The current occupant.
|
||||
var/mob/living/silicon/robot = null //Appears unused.
|
||||
var/obj/mecha = null //This does not appear to be used outside of reference in mecha.dm.
|
||||
var/obj/item/organ/brain/brain = null //The actual brain
|
||||
var/clockwork = FALSE //If this is a soul vessel
|
||||
|
||||
/obj/item/device/mmi/update_icon()
|
||||
if(brain)
|
||||
if(istype(brain,/obj/item/organ/brain/alien))
|
||||
if(brainmob && brainmob.stat == DEAD)
|
||||
icon_state = "mmi_alien_dead"
|
||||
else
|
||||
icon_state = "mmi_alien"
|
||||
braintype = "Xenoborg" //HISS....Beep.
|
||||
else
|
||||
if(brainmob && brainmob.stat == DEAD)
|
||||
icon_state = "mmi_dead"
|
||||
else
|
||||
icon_state = "mmi_full"
|
||||
braintype = "Cyborg"
|
||||
else
|
||||
icon_state = "mmi_empty"
|
||||
|
||||
/obj/item/device/mmi/New()
|
||||
..()
|
||||
radio = new(src) //Spawns a radio inside the MMI.
|
||||
radio.broadcasting = 0 //researching radio mmis turned the robofabs into radios because this didnt start as 0.
|
||||
|
||||
|
||||
|
||||
/obj/item/device/mmi/attackby(obj/item/O, mob/user, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
if(istype(O,/obj/item/organ/brain)) //Time to stick a brain in it --NEO
|
||||
var/obj/item/organ/brain/newbrain = O
|
||||
if(brain)
|
||||
user << "<span class='warning'>There's already a brain in the MMI!</span>"
|
||||
return
|
||||
if(!newbrain.brainmob)
|
||||
user << "<span class='warning'>You aren't sure where this brain came from, but you're pretty sure it's a useless brain!</span>"
|
||||
return
|
||||
|
||||
if(!user.unEquip(O))
|
||||
return
|
||||
var/mob/living/brain/B = newbrain.brainmob
|
||||
if(!B.key)
|
||||
B.notify_ghost_cloning("Someone has put your brain in a MMI!", source = src)
|
||||
visible_message("[user] sticks \a [newbrain] into \the [src].")
|
||||
|
||||
brainmob = newbrain.brainmob
|
||||
newbrain.brainmob = null
|
||||
brainmob.loc = src
|
||||
brainmob.container = src
|
||||
if(!newbrain.damaged_brain) // the brain organ hasn't been beaten to death.
|
||||
brainmob.stat = CONSCIOUS //we manually revive the brain mob
|
||||
dead_mob_list -= brainmob
|
||||
living_mob_list += brainmob
|
||||
|
||||
brainmob.reset_perspective()
|
||||
if(clockwork)
|
||||
add_servant_of_ratvar(brainmob, TRUE)
|
||||
newbrain.loc = src //P-put your brain in it
|
||||
brain = newbrain
|
||||
|
||||
name = "Man-Machine Interface: [brainmob.real_name]"
|
||||
update_icon()
|
||||
|
||||
feedback_inc("cyborg_mmis_filled",1)
|
||||
|
||||
else if(brainmob)
|
||||
O.attack(brainmob, user) //Oh noooeeeee
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/item/device/mmi/attack_self(mob/user)
|
||||
if(!brain)
|
||||
radio.on = !radio.on
|
||||
user << "<span class='notice'>You toggle the MMI's radio system [radio.on==1 ? "on" : "off"].</span>"
|
||||
else
|
||||
user << "<span class='notice'>You unlock and upend the MMI, spilling the brain onto the floor.</span>"
|
||||
|
||||
brainmob.container = null //Reset brainmob mmi var.
|
||||
brainmob.loc = brain //Throw mob into brain.
|
||||
brainmob.stat = DEAD
|
||||
brainmob.emp_damage = 0
|
||||
brainmob.reset_perspective() //so the brainmob follows the brain organ instead of the mmi. And to update our vision
|
||||
living_mob_list -= brainmob //Get outta here
|
||||
dead_mob_list += brainmob
|
||||
brain.brainmob = brainmob //Set the brain to use the brainmob
|
||||
brainmob = null //Set mmi brainmob var to null
|
||||
|
||||
user.put_in_hands(brain) //puts brain in the user's hand or otherwise drops it on the user's turf
|
||||
brain = null //No more brain in here
|
||||
|
||||
update_icon()
|
||||
name = "Man-Machine Interface"
|
||||
|
||||
/obj/item/device/mmi/proc/transfer_identity(mob/living/L) //Same deal as the regular brain proc. Used for human-->robot people.
|
||||
if(!brainmob)
|
||||
brainmob = new(src)
|
||||
brainmob.name = L.real_name
|
||||
brainmob.real_name = L.real_name
|
||||
if(L.has_dna())
|
||||
var/mob/living/carbon/C = L
|
||||
if(!brainmob.stored_dna)
|
||||
brainmob.stored_dna = new /datum/dna/stored(brainmob)
|
||||
C.dna.copy_dna(brainmob.stored_dna)
|
||||
brainmob.container = src
|
||||
|
||||
if(ishuman(L))
|
||||
var/mob/living/carbon/human/H = L
|
||||
var/obj/item/organ/brain/newbrain = H.getorgan(/obj/item/organ/brain)
|
||||
newbrain.loc = src
|
||||
brain = newbrain
|
||||
else if(!brain)
|
||||
brain = new(src)
|
||||
brain.name = "[L.real_name]'s brain"
|
||||
|
||||
name = "Man-Machine Interface: [brainmob.real_name]"
|
||||
update_icon()
|
||||
return
|
||||
|
||||
|
||||
/obj/item/device/mmi/verb/Toggle_Listening()
|
||||
set name = "Toggle Listening"
|
||||
set desc = "Toggle listening channel on or off."
|
||||
set category = "MMI"
|
||||
set src = usr.loc
|
||||
set popup_menu = 0
|
||||
|
||||
if(brainmob.stat)
|
||||
brainmob << "<span class='warning'>Can't do that while incapacitated or dead!</span>"
|
||||
if(!radio.on)
|
||||
brainmob << "<span class='warning'>Your radio is disabled!</span>"
|
||||
return
|
||||
|
||||
radio.listening = radio.listening==1 ? 0 : 1
|
||||
brainmob << "<span class='notice'>Radio is [radio.listening==1 ? "now" : "no longer"] receiving broadcast.</span>"
|
||||
|
||||
/obj/item/device/mmi/emp_act(severity)
|
||||
if(!brainmob)
|
||||
return
|
||||
else
|
||||
switch(severity)
|
||||
if(1)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(20,30), 30)
|
||||
if(2)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(10,20), 30)
|
||||
if(3)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(0,10), 30)
|
||||
brainmob.emote("alarm")
|
||||
..()
|
||||
|
||||
/obj/item/device/mmi/Destroy()
|
||||
if(isrobot(loc))
|
||||
var/mob/living/silicon/robot/borg = loc
|
||||
borg.mmi = null
|
||||
if(brainmob)
|
||||
qdel(brainmob)
|
||||
brainmob = null
|
||||
return ..()
|
||||
|
||||
/obj/item/device/mmi/examine(mob/user)
|
||||
..()
|
||||
if(brainmob)
|
||||
var/mob/living/brain/B = brainmob
|
||||
if(!B.key || !B.mind || B.stat == DEAD)
|
||||
user << "<span class='warning'>The MMI indicates the brain is completely unresponsive.</span>"
|
||||
|
||||
else if(!B.client)
|
||||
user << "<span class='warning'>The MMI indicates the brain is currently inactive; it might change.</span>"
|
||||
|
||||
else
|
||||
user << "<span class='notice'>The MMI indicates the brain is active.</span>"
|
||||
|
||||
|
||||
/obj/item/device/mmi/syndie
|
||||
name = "Syndicate Man-Machine Interface"
|
||||
desc = "Syndicate's own brand of MMI. It enforces laws designed to help Syndicate agents achieve their goals upon cyborgs created with it, but doesn't fit in Nanotrasen AI cores."
|
||||
origin_tech = "biotech=4;programming=4;syndicate=2"
|
||||
hacked = 1
|
||||
|
||||
/obj/item/device/mmi/syndie/New()
|
||||
..()
|
||||
radio.on = 0
|
||||
+67
-63
@@ -1,63 +1,67 @@
|
||||
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:32
|
||||
|
||||
/mob/living/carbon/brain
|
||||
languages_spoken = HUMAN
|
||||
languages_understood = HUMAN
|
||||
var/obj/item/device/mmi/container = null
|
||||
var/timeofhostdeath = 0
|
||||
var/emp_damage = 0//Handles a type of MMI damage
|
||||
has_limbs = 0
|
||||
stat = DEAD //we start dead by default
|
||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
||||
|
||||
/mob/living/carbon/brain/New(loc)
|
||||
..()
|
||||
if(isturf(loc)) //not spawned in an MMI or brain organ (most likely adminspawned)
|
||||
var/obj/item/organ/brain/OB = new(loc) //we create a new brain organ for it.
|
||||
src.loc = OB
|
||||
OB.brainmob = src
|
||||
|
||||
|
||||
/mob/living/carbon/brain/Destroy()
|
||||
if(key) //If there is a mob connected to this thing. Have to check key twice to avoid false death reporting.
|
||||
if(stat!=DEAD) //If not dead.
|
||||
death(1) //Brains can die again. AND THEY SHOULD AHA HA HA HA HA HA
|
||||
ghostize() //Ghostize checks for key so nothing else is necessary.
|
||||
container = null
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/brain/update_canmove()
|
||||
if(in_contents_of(/obj/mecha))
|
||||
canmove = 1
|
||||
else
|
||||
canmove = 0
|
||||
return canmove
|
||||
|
||||
/mob/living/carbon/brain/toggle_throw_mode()
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/blob_act(obj/effect/blob/B)
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/UnarmedAttack(atom/A)//Stops runtimes due to attack_animal being the default
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/check_ear_prot()
|
||||
return 1
|
||||
|
||||
/mob/living/carbon/brain/flash_eyes(intensity = 1, override_blindness_check = 0, affect_silicon = 0)
|
||||
return // no eyes, no flashing
|
||||
|
||||
/mob/living/carbon/brain/update_damage_hud()
|
||||
return //no red circles for brain
|
||||
|
||||
/mob/living/carbon/brain/can_be_revived()
|
||||
. = 1
|
||||
if(!container || health <= HEALTH_THRESHOLD_DEAD)
|
||||
return 0
|
||||
|
||||
/mob/living/carbon/brain/update_sight()
|
||||
return
|
||||
//This file was auto-corrected by findeclaration.exe on 25.5.2012 20:42:32
|
||||
|
||||
/mob/living/brain
|
||||
languages_spoken = HUMAN
|
||||
languages_understood = HUMAN
|
||||
var/obj/item/device/mmi/container = null
|
||||
var/timeofhostdeath = 0
|
||||
var/emp_damage = 0//Handles a type of MMI damage
|
||||
var/datum/dna/stored/stored_dna // dna var for brain. Used to store dna, brain dna is not considered like actual dna, brain.has_dna() returns FALSE.
|
||||
stat = DEAD //we start dead by default
|
||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
||||
|
||||
/mob/living/brain/New(loc)
|
||||
..()
|
||||
create_dna(src)
|
||||
stored_dna.initialize_dna(random_blood_type())
|
||||
if(isturf(loc)) //not spawned in an MMI or brain organ (most likely adminspawned)
|
||||
var/obj/item/organ/brain/OB = new(loc) //we create a new brain organ for it.
|
||||
src.loc = OB
|
||||
OB.brainmob = src
|
||||
|
||||
|
||||
/mob/living/brain/proc/create_dna()
|
||||
stored_dna = new /datum/dna/stored(src)
|
||||
if(!stored_dna.species)
|
||||
var/rando_race = pick(config.roundstart_races)
|
||||
stored_dna.species = new rando_race()
|
||||
|
||||
/mob/living/brain/Destroy()
|
||||
if(key) //If there is a mob connected to this thing. Have to check key twice to avoid false death reporting.
|
||||
if(stat!=DEAD) //If not dead.
|
||||
death(1) //Brains can die again. AND THEY SHOULD AHA HA HA HA HA HA
|
||||
ghostize() //Ghostize checks for key so nothing else is necessary.
|
||||
container = null
|
||||
return ..()
|
||||
|
||||
/mob/living/brain/update_canmove()
|
||||
if(in_contents_of(/obj/mecha))
|
||||
canmove = 1
|
||||
else
|
||||
canmove = 0
|
||||
return canmove
|
||||
|
||||
/mob/living/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
|
||||
return
|
||||
|
||||
/mob/living/brain/blob_act(obj/effect/blob/B)
|
||||
return
|
||||
|
||||
/mob/living/brain/get_eye_protection()//no eyes
|
||||
return 2
|
||||
|
||||
/mob/living/brain/get_ear_protection()//no ears
|
||||
return 2
|
||||
|
||||
/mob/living/brain/flash_act(intensity = 1, override_blindness_check = 0, affect_silicon = 0)
|
||||
return // no eyes, no flashing
|
||||
|
||||
/mob/living/brain/can_be_revived()
|
||||
. = 1
|
||||
if(!container || health <= HEALTH_THRESHOLD_DEAD)
|
||||
return 0
|
||||
|
||||
/mob/living/brain/fully_replace_character_name(oldname,newname)
|
||||
..()
|
||||
if(stored_dna)
|
||||
stored_dna.real_name = real_name
|
||||
+122
-127
@@ -1,127 +1,122 @@
|
||||
/obj/item/organ/brain
|
||||
name = "brain"
|
||||
desc = "A piece of juicy meat found in a person's head."
|
||||
icon_state = "brain"
|
||||
throw_speed = 3
|
||||
throw_range = 5
|
||||
layer = ABOVE_MOB_LAYER
|
||||
zone = "head"
|
||||
slot = "brain"
|
||||
vital = 1
|
||||
origin_tech = "biotech=5"
|
||||
attack_verb = list("attacked", "slapped", "whacked")
|
||||
var/mob/living/carbon/brain/brainmob = null
|
||||
var/damaged_brain = 0 //whether the brain organ is damaged.
|
||||
|
||||
/obj/item/organ/brain/Insert(mob/living/carbon/M, special = 0)
|
||||
..()
|
||||
name = "brain"
|
||||
if(brainmob)
|
||||
if(M.key)
|
||||
M.ghostize()
|
||||
|
||||
if(brainmob.mind)
|
||||
brainmob.mind.transfer_to(M)
|
||||
else
|
||||
M.key = brainmob.key
|
||||
|
||||
qdel(brainmob)
|
||||
|
||||
//Update the body's icon so it doesnt appear debrained anymore
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_hair(0)
|
||||
|
||||
/obj/item/organ/brain/Remove(mob/living/carbon/M, special = 0)
|
||||
..()
|
||||
if(!special)
|
||||
transfer_identity(M)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_hair(0)
|
||||
|
||||
/obj/item/organ/brain/prepare_eat()
|
||||
return // Too important to eat.
|
||||
|
||||
/obj/item/organ/brain/proc/transfer_identity(mob/living/L)
|
||||
name = "[L.name]'s brain"
|
||||
brainmob = new(src)
|
||||
brainmob.name = L.real_name
|
||||
brainmob.real_name = L.real_name
|
||||
brainmob.timeofhostdeath = L.timeofdeath
|
||||
if(L.has_dna())
|
||||
var/mob/living/carbon/C = L
|
||||
if(!brainmob.dna)
|
||||
brainmob.dna = new /datum/dna(brainmob)
|
||||
C.dna.copy_dna(brainmob.dna)
|
||||
if(L.mind && L.mind.current && (L.mind.current.stat == DEAD))
|
||||
L.mind.transfer_to(brainmob)
|
||||
brainmob << "<span class='notice'>You feel slightly disoriented. That's normal when you're just a brain.</span>"
|
||||
|
||||
/obj/item/organ/brain/attackby(obj/item/O, mob/user, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
if(brainmob)
|
||||
O.attack(brainmob, user) //Oh noooeeeee
|
||||
|
||||
/obj/item/organ/brain/examine(mob/user)
|
||||
..()
|
||||
|
||||
if(brainmob)
|
||||
if(brainmob.client)
|
||||
if(brainmob.health <= HEALTH_THRESHOLD_DEAD)
|
||||
user << "It's lifeless and severely damaged."
|
||||
else
|
||||
user << "You can feel the small spark of life still left in this one."
|
||||
else
|
||||
user << "This one seems particularly lifeless. Perhaps it will regain some of its luster later."
|
||||
else
|
||||
user << "This one is completely devoid of life."
|
||||
|
||||
/obj/item/organ/brain/attack(mob/living/carbon/M, mob/user)
|
||||
if(!istype(M))
|
||||
return ..()
|
||||
|
||||
add_fingerprint(user)
|
||||
|
||||
if(user.zone_selected != "head")
|
||||
return ..()
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(istype(H) && ((H.head && H.head.flags_cover & HEADCOVERSEYES) || (H.wear_mask && H.wear_mask.flags_cover & MASKCOVERSEYES) || (H.glasses && H.glasses.flags & GLASSESCOVERSEYES)))
|
||||
user << "<span class='warning'>You're going to need to remove their head cover first!</span>"
|
||||
return
|
||||
|
||||
//since these people will be dead M != usr
|
||||
|
||||
if(!M.getorgan(/obj/item/organ/brain))
|
||||
if(istype(H) && !H.get_bodypart("head"))
|
||||
return
|
||||
user.drop_item()
|
||||
var/msg = "[M] has [src] inserted into \his head by [user]."
|
||||
if(M == user)
|
||||
msg = "[user] inserts [src] into \his head!"
|
||||
|
||||
M.visible_message("<span class='danger'>[msg]</span>",
|
||||
"<span class='userdanger'>[msg]</span>")
|
||||
|
||||
if(M != user)
|
||||
M << "<span class='notice'>[user] inserts [src] into your head.</span>"
|
||||
user << "<span class='notice'>You insert [src] into [M]'s head.</span>"
|
||||
else
|
||||
user << "<span class='notice'>You insert [src] into your head.</span>" //LOL
|
||||
|
||||
Insert(M)
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/item/organ/brain/Destroy() //copypasted from MMIs.
|
||||
if(brainmob)
|
||||
qdel(brainmob)
|
||||
brainmob = null
|
||||
return ..()
|
||||
|
||||
/obj/item/organ/brain/alien
|
||||
name = "alien brain"
|
||||
desc = "We barely understand the brains of terrestial animals. Who knows what we may find in the brain of such an advanced species?"
|
||||
icon_state = "brain-x"
|
||||
origin_tech = "biotech=6"
|
||||
/obj/item/organ/brain
|
||||
name = "brain"
|
||||
desc = "A piece of juicy meat found in a person's head."
|
||||
icon_state = "brain"
|
||||
throw_speed = 3
|
||||
throw_range = 5
|
||||
layer = ABOVE_MOB_LAYER
|
||||
zone = "head"
|
||||
slot = "brain"
|
||||
vital = 1
|
||||
origin_tech = "biotech=5"
|
||||
attack_verb = list("attacked", "slapped", "whacked")
|
||||
var/mob/living/brain/brainmob = null
|
||||
var/damaged_brain = 0 //whether the brain organ is damaged.
|
||||
|
||||
/obj/item/organ/brain/Insert(mob/living/carbon/C, special = 0)
|
||||
..()
|
||||
name = "brain"
|
||||
if(brainmob)
|
||||
if(C.key)
|
||||
C.ghostize()
|
||||
|
||||
if(brainmob.mind)
|
||||
brainmob.mind.transfer_to(C)
|
||||
else
|
||||
C.key = brainmob.key
|
||||
|
||||
qdel(brainmob)
|
||||
|
||||
//Update the body's icon so it doesnt appear debrained anymore
|
||||
C.update_hair()
|
||||
|
||||
/obj/item/organ/brain/Remove(mob/living/carbon/C, special = 0)
|
||||
..()
|
||||
if(!special)
|
||||
transfer_identity(C)
|
||||
C.update_hair()
|
||||
|
||||
/obj/item/organ/brain/prepare_eat()
|
||||
return // Too important to eat.
|
||||
|
||||
/obj/item/organ/brain/proc/transfer_identity(mob/living/L)
|
||||
name = "[L.name]'s brain"
|
||||
brainmob = new(src)
|
||||
brainmob.name = L.real_name
|
||||
brainmob.real_name = L.real_name
|
||||
brainmob.timeofhostdeath = L.timeofdeath
|
||||
if(L.has_dna())
|
||||
var/mob/living/carbon/C = L
|
||||
if(!brainmob.stored_dna)
|
||||
brainmob.stored_dna = new /datum/dna/stored(brainmob)
|
||||
C.dna.copy_dna(brainmob.stored_dna)
|
||||
if(L.mind && L.mind.current && (L.mind.current.stat == DEAD))
|
||||
L.mind.transfer_to(brainmob)
|
||||
brainmob << "<span class='notice'>You feel slightly disoriented. That's normal when you're just a brain.</span>"
|
||||
|
||||
/obj/item/organ/brain/attackby(obj/item/O, mob/user, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
if(brainmob)
|
||||
O.attack(brainmob, user) //Oh noooeeeee
|
||||
|
||||
/obj/item/organ/brain/examine(mob/user)
|
||||
..()
|
||||
|
||||
if(brainmob)
|
||||
if(brainmob.client)
|
||||
if(brainmob.health <= HEALTH_THRESHOLD_DEAD)
|
||||
user << "It's lifeless and severely damaged."
|
||||
else
|
||||
user << "You can feel the small spark of life still left in this one."
|
||||
else
|
||||
user << "This one seems particularly lifeless. Perhaps it will regain some of its luster later."
|
||||
else
|
||||
user << "This one is completely devoid of life."
|
||||
|
||||
/obj/item/organ/brain/attack(mob/living/carbon/C, mob/user)
|
||||
if(!istype(C))
|
||||
return ..()
|
||||
|
||||
add_fingerprint(user)
|
||||
|
||||
if(user.zone_selected != "head")
|
||||
return ..()
|
||||
|
||||
if((C.head && (C.head.flags_cover & HEADCOVERSEYES)) || (C.wear_mask && (C.wear_mask.flags_cover & MASKCOVERSEYES)) || (C.glasses && (C.glasses.flags & GLASSESCOVERSEYES)))
|
||||
user << "<span class='warning'>You're going to need to remove their head cover first!</span>"
|
||||
return
|
||||
|
||||
//since these people will be dead M != usr
|
||||
|
||||
if(!C.getorgan(/obj/item/organ/brain))
|
||||
if(!C.get_bodypart("head"))
|
||||
return
|
||||
user.drop_item()
|
||||
var/msg = "[C] has [src] inserted into \his head by [user]."
|
||||
if(C == user)
|
||||
msg = "[user] inserts [src] into \his head!"
|
||||
|
||||
C.visible_message("<span class='danger'>[msg]</span>",
|
||||
"<span class='userdanger'>[msg]</span>")
|
||||
|
||||
if(C != user)
|
||||
C << "<span class='notice'>[user] inserts [src] into your head.</span>"
|
||||
user << "<span class='notice'>You insert [src] into [C]'s head.</span>"
|
||||
else
|
||||
user << "<span class='notice'>You insert [src] into your head.</span>" //LOL
|
||||
|
||||
Insert(C)
|
||||
else
|
||||
..()
|
||||
|
||||
/obj/item/organ/brain/Destroy() //copypasted from MMIs.
|
||||
if(brainmob)
|
||||
qdel(brainmob)
|
||||
brainmob = null
|
||||
return ..()
|
||||
|
||||
/obj/item/organ/brain/alien
|
||||
name = "alien brain"
|
||||
desc = "We barely understand the brains of terrestial animals. Who knows what we may find in the brain of such an advanced species?"
|
||||
icon_state = "brain-x"
|
||||
origin_tech = "biotech=6"
|
||||
+19
-19
@@ -1,20 +1,20 @@
|
||||
/mob/living/carbon/brain/death(gibbed)
|
||||
if(stat == DEAD)
|
||||
return
|
||||
stat = DEAD
|
||||
|
||||
if(!gibbed && container)//If not gibbed but in a container.
|
||||
var/obj/item/device/mmi = container
|
||||
mmi.visible_message("<span class='warning'>[src]'s MMI flatlines!</span>", \
|
||||
"<span class='italics'>You hear something flatline.</span>")
|
||||
mmi.update_icon()
|
||||
|
||||
return ..()
|
||||
|
||||
/mob/living/carbon/brain/gib()
|
||||
if(container)
|
||||
qdel(container)//Gets rid of the MMI if there is one
|
||||
if(loc)
|
||||
if(istype(loc,/obj/item/organ/brain))
|
||||
qdel(loc)//Gets rid of the brain item
|
||||
/mob/living/brain/death(gibbed)
|
||||
if(stat == DEAD)
|
||||
return
|
||||
stat = DEAD
|
||||
|
||||
if(!gibbed && container)//If not gibbed but in a container.
|
||||
var/obj/item/device/mmi = container
|
||||
mmi.visible_message("<span class='warning'>[src]'s MMI flatlines!</span>", \
|
||||
"<span class='italics'>You hear something flatline.</span>")
|
||||
mmi.update_icon()
|
||||
|
||||
return ..()
|
||||
|
||||
/mob/living/brain/gib()
|
||||
if(container)
|
||||
qdel(container)//Gets rid of the MMI if there is one
|
||||
if(loc)
|
||||
if(istype(loc,/obj/item/organ/brain))
|
||||
qdel(loc)//Gets rid of the brain item
|
||||
..()
|
||||
+70
-70
@@ -1,71 +1,71 @@
|
||||
/mob/living/carbon/brain/emote(act,m_type=1,message = null)
|
||||
if(!(container && istype(container, /obj/item/device/mmi)))//No MMI, no emotes
|
||||
return
|
||||
|
||||
if (findtext(act, "-", 1, null))
|
||||
var/t1 = findtext(act, "-", 1, null)
|
||||
act = copytext(act, 1, t1)
|
||||
|
||||
|
||||
if(src.stat == DEAD)
|
||||
return
|
||||
switch(act)
|
||||
if ("alarm")
|
||||
src << "You sound an alarm."
|
||||
message = "<B>[src]</B> sounds an alarm."
|
||||
m_type = 2
|
||||
|
||||
if ("alert")
|
||||
src << "You let out a distressed noise."
|
||||
message = "<B>[src]</B> lets out a distressed noise."
|
||||
m_type = 2
|
||||
|
||||
if ("beep","beeps")
|
||||
src << "You beep."
|
||||
message = "<B>[src]</B> beeps."
|
||||
m_type = 2
|
||||
|
||||
if ("blink","blinks")
|
||||
message = "<B>[src]</B> blinks."
|
||||
m_type = 1
|
||||
|
||||
if ("boop","boops")
|
||||
src << "You boop."
|
||||
message = "<B>[src]</B> boops."
|
||||
m_type = 2
|
||||
|
||||
if ("flash")
|
||||
message = "The lights on <B>[src]</B> flash quickly."
|
||||
m_type = 1
|
||||
|
||||
if ("notice")
|
||||
src << "You play a loud tone."
|
||||
message = "<B>[src]</B> plays a loud tone."
|
||||
m_type = 2
|
||||
|
||||
if ("whistle","whistles")
|
||||
src << "You whistle."
|
||||
message = "<B>[src]</B> whistles."
|
||||
m_type = 2
|
||||
|
||||
if ("help")
|
||||
src << "Help for MMI emotes. You can use these emotes with say \"*emote\":\nalarm, alert, beep, blink, boop, flash, notice, whistle"
|
||||
|
||||
else
|
||||
src << "<span class='notice'>Unusable emote '[act]'. Say *help for a list.</span>"
|
||||
return
|
||||
|
||||
if (message)
|
||||
log_emote("[name]/[key] : [message]")
|
||||
|
||||
for(var/mob/M in dead_mob_list)
|
||||
if (!M.client || istype(M, /mob/new_player))
|
||||
continue //skip monkeys, leavers, and new_players
|
||||
if(M.stat == DEAD && (M.client && (M.client.prefs.chat_toggles & CHAT_GHOSTSIGHT)) && !(M in viewers(src,null)))
|
||||
M.show_message(message)
|
||||
|
||||
|
||||
if (m_type & 1)
|
||||
visible_message(message)
|
||||
else if (m_type & 2)
|
||||
/mob/living/brain/emote(act,m_type=1,message = null)
|
||||
if(!(container && istype(container, /obj/item/device/mmi)))//No MMI, no emotes
|
||||
return
|
||||
|
||||
if (findtext(act, "-", 1, null))
|
||||
var/t1 = findtext(act, "-", 1, null)
|
||||
act = copytext(act, 1, t1)
|
||||
|
||||
|
||||
if(src.stat == DEAD)
|
||||
return
|
||||
switch(act)
|
||||
if ("alarm")
|
||||
src << "You sound an alarm."
|
||||
message = "<B>[src]</B> sounds an alarm."
|
||||
m_type = 2
|
||||
|
||||
if ("alert")
|
||||
src << "You let out a distressed noise."
|
||||
message = "<B>[src]</B> lets out a distressed noise."
|
||||
m_type = 2
|
||||
|
||||
if ("beep","beeps")
|
||||
src << "You beep."
|
||||
message = "<B>[src]</B> beeps."
|
||||
m_type = 2
|
||||
|
||||
if ("blink","blinks")
|
||||
message = "<B>[src]</B> blinks."
|
||||
m_type = 1
|
||||
|
||||
if ("boop","boops")
|
||||
src << "You boop."
|
||||
message = "<B>[src]</B> boops."
|
||||
m_type = 2
|
||||
|
||||
if ("flash")
|
||||
message = "The lights on <B>[src]</B> flash quickly."
|
||||
m_type = 1
|
||||
|
||||
if ("notice")
|
||||
src << "You play a loud tone."
|
||||
message = "<B>[src]</B> plays a loud tone."
|
||||
m_type = 2
|
||||
|
||||
if ("whistle","whistles")
|
||||
src << "You whistle."
|
||||
message = "<B>[src]</B> whistles."
|
||||
m_type = 2
|
||||
|
||||
if ("help")
|
||||
src << "Help for MMI emotes. You can use these emotes with say \"*emote\":\nalarm, alert, beep, blink, boop, flash, notice, whistle"
|
||||
|
||||
else
|
||||
src << "<span class='notice'>Unusable emote '[act]'. Say *help for a list.</span>"
|
||||
return
|
||||
|
||||
if (message)
|
||||
log_emote("[name]/[key] : [message]")
|
||||
|
||||
for(var/mob/M in dead_mob_list)
|
||||
if (!M.client || istype(M, /mob/new_player))
|
||||
continue //skip monkeys, leavers, and new_players
|
||||
if(M.stat == DEAD && (M.client && (M.client.prefs.chat_toggles & CHAT_GHOSTSIGHT)) && !(M in viewers(src,null)))
|
||||
M.show_message(message)
|
||||
|
||||
|
||||
if (m_type & 1)
|
||||
visible_message(message)
|
||||
else if (m_type & 2)
|
||||
audible_message(message)
|
||||
+49
-60
@@ -1,60 +1,49 @@
|
||||
|
||||
/mob/living/carbon/brain/Life()
|
||||
set invisibility = 0
|
||||
set background = BACKGROUND_ENABLED
|
||||
|
||||
if (notransform)
|
||||
return
|
||||
if(!loc)
|
||||
return
|
||||
. = ..()
|
||||
handle_emp_damage()
|
||||
|
||||
/mob/living/carbon/brain/handle_breathing()
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/handle_mutations_and_radiation()
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/handle_environment(datum/gas_mixture/environment)
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/update_stat()
|
||||
if(status_flags & GODMODE)
|
||||
return
|
||||
if(health <= HEALTH_THRESHOLD_DEAD)
|
||||
if(stat != DEAD)
|
||||
death()
|
||||
var/obj/item/organ/brain/BR
|
||||
if(container && container.brain)
|
||||
BR = container.brain
|
||||
else if(istype(loc, /obj/item/organ/brain))
|
||||
BR = loc
|
||||
if(BR)
|
||||
BR.damaged_brain = 1 //beaten to a pulp
|
||||
|
||||
/* //currently unused feature, since brain outside a mmi is always dead.
|
||||
/mob/living/carbon/brain/proc/handle_brain_revival_life()
|
||||
if(stat != DEAD)
|
||||
if(config.revival_brain_life != -1)
|
||||
if( !container && (world.time - timeofhostdeath) > config.revival_brain_life)
|
||||
death()
|
||||
*/
|
||||
|
||||
/mob/living/carbon/brain/proc/handle_emp_damage()
|
||||
if(emp_damage)
|
||||
if(stat == DEAD)
|
||||
emp_damage = 0
|
||||
else
|
||||
emp_damage = max(emp_damage-1, 0)
|
||||
|
||||
/mob/living/carbon/brain/handle_status_effects()
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/handle_disabilities()
|
||||
return
|
||||
|
||||
/mob/living/carbon/brain/handle_changeling()
|
||||
return
|
||||
|
||||
|
||||
|
||||
/mob/living/brain/Life()
|
||||
set invisibility = 0
|
||||
set background = BACKGROUND_ENABLED
|
||||
|
||||
if (notransform)
|
||||
return
|
||||
if(!loc)
|
||||
return
|
||||
. = ..()
|
||||
handle_emp_damage()
|
||||
|
||||
/mob/living/brain/update_stat()
|
||||
if(status_flags & GODMODE)
|
||||
return
|
||||
if(health <= HEALTH_THRESHOLD_DEAD)
|
||||
if(stat != DEAD)
|
||||
death()
|
||||
var/obj/item/organ/brain/BR
|
||||
if(container && container.brain)
|
||||
BR = container.brain
|
||||
else if(istype(loc, /obj/item/organ/brain))
|
||||
BR = loc
|
||||
if(BR)
|
||||
BR.damaged_brain = 1 //beaten to a pulp
|
||||
|
||||
/* //currently unused feature, since brain outside a mmi is always dead.
|
||||
/mob/living/brain/proc/handle_brain_revival_life()
|
||||
if(stat != DEAD)
|
||||
if(config.revival_brain_life != -1)
|
||||
if( !container && (world.time - timeofhostdeath) > config.revival_brain_life)
|
||||
death()
|
||||
*/
|
||||
|
||||
/mob/living/brain/proc/handle_emp_damage()
|
||||
if(emp_damage)
|
||||
if(stat == DEAD)
|
||||
emp_damage = 0
|
||||
else
|
||||
emp_damage = max(emp_damage-1, 0)
|
||||
|
||||
/mob/living/brain/handle_status_effects()
|
||||
return
|
||||
|
||||
/mob/living/brain/handle_disabilities()
|
||||
return
|
||||
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user