This commit is contained in:
Verkister
2017-06-07 12:12:16 +03:00
165 changed files with 5875 additions and 1919 deletions
+2 -2
View File
@@ -480,7 +480,7 @@
M.equip_to_slot_or_del(new /obj/item/clothing/head/det(M), slot_head)
M.equip_to_slot_or_del(new /obj/item/weapon/gun/projectile/revolver(M), slot_r_hand)
M.equip_to_slot_or_del(new /obj/item/ammo_magazine/a357(M), slot_l_store)
M.equip_to_slot_or_del(new /obj/item/ammo_magazine/s357(M), slot_l_store)
if ("tournament chef") //Steven Seagal FTW
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/chef(M), slot_w_uniform)
@@ -592,7 +592,7 @@
sec_briefcase.contents += new /obj/item/weapon/spacecash/c1000
sec_briefcase.contents += new /obj/item/weapon/gun/energy/crossbow
sec_briefcase.contents += new /obj/item/weapon/gun/projectile/revolver/mateba
sec_briefcase.contents += new /obj/item/ammo_magazine/a357
sec_briefcase.contents += new /obj/item/ammo_magazine/s357
sec_briefcase.contents += new /obj/item/weapon/plastique
M.equip_to_slot_or_del(sec_briefcase, slot_l_hand)
+27 -27
View File
@@ -185,35 +185,35 @@
var/new_ammo = pick( // Copied from Random.dm
prob(5);/obj/item/weapon/storage/box/shotgunammo,\
prob(5);/obj/item/weapon/storage/box/shotgunshells,\
prob(5);/obj/item/ammo_magazine/a357,\
prob(5);/obj/item/ammo_magazine/clip/a762,\
prob(5);/obj/item/ammo_magazine/c45m,\
prob(5);/obj/item/ammo_magazine/c45m/rubber,\
prob(5);/obj/item/ammo_magazine/c38,\
prob(5);/obj/item/ammo_magazine/c38/rubber,\
prob(5);/obj/item/ammo_magazine/m357,\
prob(5);/obj/item/ammo_magazine/clip/c762,\
prob(5);/obj/item/ammo_magazine/m45,\
prob(5);/obj/item/ammo_magazine/m45/rubber,\
prob(5);/obj/item/ammo_magazine/s38,\
prob(5);/obj/item/ammo_magazine/s38/rubber,\
prob(5);/obj/item/weapon/storage/box/flashbangs,\
prob(5);/obj/item/ammo_magazine/c556,\
prob(4);/obj/item/ammo_magazine/clip/a556,\
prob(5);/obj/item/ammo_magazine/m556,\
prob(4);/obj/item/ammo_magazine/clip/c556,\
prob(4);/obj/item/ammo_magazine/clip/c45,\
prob(4);/obj/item/ammo_magazine/clip/c9mm,\
prob(4);/obj/item/ammo_magazine/c45uzi,\
prob(4);/obj/item/ammo_magazine/c556/ext,\
prob(4);/obj/item/ammo_magazine/mc9mm,\
prob(4);/obj/item/ammo_magazine/mc9mml,\
prob(4);/obj/item/ammo_magazine/mc9mmt,\
prob(4);/obj/item/ammo_magazine/mc9mmt/rubber,\
prob(4);/obj/item/ammo_magazine/a10mm,\
prob(4);/obj/item/ammo_magazine/p90,\
prob(4);/obj/item/ammo_magazine/m45uzi,\
prob(4);/obj/item/ammo_magazine/m556/ext,\
prob(4);/obj/item/ammo_magazine/m9mm,\
prob(4);/obj/item/ammo_magazine/m9mml,\
prob(4);/obj/item/ammo_magazine/m9mmt,\
prob(4);/obj/item/ammo_magazine/m9mmt/rubber,\
prob(4);/obj/item/ammo_magazine/m10mm,\
prob(4);/obj/item/ammo_magazine/m9mmp90,\
/* prob(4);/obj/item/ammo_magazine/m14,\
prob(4);/obj/item/ammo_magazine/m14/large,\ */
prob(4);/obj/item/ammo_magazine/c556/ext,\
prob(4);/obj/item/ammo_magazine/s762,\
prob(4);/obj/item/ammo_magazine/c556/ext,\
prob(3);/obj/item/ammo_magazine/clip/a10mm,\
prob(3);/obj/item/ammo_magazine/clip/a50,\
prob(3);/obj/item/ammo_magazine/c556,\
prob(2);/obj/item/ammo_magazine/a50,\
prob(2);/obj/item/ammo_magazine/a556,\
prob(4);/obj/item/ammo_magazine/m556/ext,\
prob(4);/obj/item/ammo_magazine/m762,\
prob(4);/obj/item/ammo_magazine/m556/ext,\
prob(3);/obj/item/ammo_magazine/clip/c10mm,\
prob(3);/obj/item/ammo_magazine/clip/c50,\
prob(3);/obj/item/ammo_magazine/m556,\
prob(2);/obj/item/ammo_magazine/m50,\
prob(2);/obj/item/ammo_magazine/m556,\
prob(1);/obj/item/weapon/storage/box/frags,\
/* prob(1);/obj/item/ammo_magazine/battlerifle,\ */
prob(1);/obj/item/ammo_casing/rocket,\
@@ -223,9 +223,9 @@
prob(1);/obj/item/weapon/storage/box/practiceshells,\
prob(1);/obj/item/weapon/storage/box/stunshells,\
prob(1);/obj/item/weapon/storage/box/blanks,\
prob(1);/obj/item/ammo_magazine/stg,\
prob(1);/obj/item/ammo_magazine/tommydrum,\
prob(1);/obj/item/ammo_magazine/tommymag)
prob(1);/obj/item/ammo_magazine/mtg,\
prob(1);/obj/item/ammo_magazine/m45tommydrum,\
prob(1);/obj/item/ammo_magazine/m45tommy)
new new_ammo(C)
if("spacesuit")
var/obj/structure/closet/syndicate/C = new(src.loc)
@@ -77,6 +77,38 @@
display_name = "flats, black"
path = /obj/item/clothing/shoes/flats
/datum/gear/shoes/hitops/
display_name = "high-top, white"
path = /obj/item/clothing/shoes/hitops/
/datum/gear/shoes/hitops/red
display_name = "high-top, red"
path = /obj/item/clothing/shoes/hitops/red
/datum/gear/shoes/hitops/black
display_name = "high-top, black"
path = /obj/item/clothing/shoes/hitops/black
/datum/gear/shoes/hitops/orange
display_name = "high-top, orange"
path = /obj/item/clothing/shoes/hitops/orange
/datum/gear/shoes/hitops/blue
display_name = "high-top, blue"
path = /obj/item/clothing/shoes/hitops/blue
/datum/gear/shoes/hitops/green
display_name = "high-top, green"
path = /obj/item/clothing/shoes/hitops/green
/datum/gear/shoes/hitops/purple
display_name = "high-top, purple"
path = /obj/item/clothing/shoes/hitops/purple
/datum/gear/shoes/hitops/yellow
display_name = "high-top, yellow"
path = /obj/item/clothing/shoes/hitops/yellow
/datum/gear/shoes/flats/blue
display_name = "flats, blue"
path = /obj/item/clothing/shoes/flats/blue
@@ -196,10 +196,10 @@
picklist = positive_traits.Copy() - pref.pos_traits
mylist = pref.pos_traits
if(NEUTRAL_MODE)
picklist = neutral_traits.Copy() - pref.pos_traits
picklist = neutral_traits.Copy() - pref.neu_traits
mylist = pref.neu_traits
if(NEGATIVE_MODE)
picklist = negative_traits.Copy() - pref.pos_traits
picklist = negative_traits.Copy() - pref.neg_traits
mylist = pref.neg_traits
else
@@ -224,7 +224,9 @@
var/done = FALSE
while(!done)
var/message = "\[Remaining: [points_left] points, [traits_left] traits\] Select a trait to read the description and see the cost."
trait_choice = input(message,"Positive Traits") in nicelist
trait_choice = input(message,"Trait List") as null|anything in nicelist
if(!trait_choice)
done = TRUE
if(trait_choice in nicelist)
var/datum/trait/path = nicelist[trait_choice]
var/choice = alert("\[Cost:[initial(path.cost)]\] [initial(path.desc)]",initial(path.name),"Take Trait","Cancel","Go Back")
@@ -241,6 +243,9 @@
var/conflict = FALSE
if(trait_choice in pref.pos_traits + pref.neu_traits + pref.neg_traits)
conflict = instance.name
varconflict:
for(var/P in pref.pos_traits + pref.neu_traits + pref.neg_traits)
var/datum/trait/instance_test = all_traits[P]
@@ -0,0 +1,45 @@
//Pretty small file, mostly just for storage.
/datum/preferences
var/obj/item/device/nif/nif_path
var/nif_durability
// Definition of the stuff for NIFs
/datum/category_item/player_setup_item/vore/nif
name = "NIF Data"
sort_order = 8
/datum/category_item/player_setup_item/vore/nif/load_character(var/savefile/S)
S["nif_path"] >> pref.nif_path
S["nif_durability"] >> pref.nif_durability
/datum/category_item/player_setup_item/vore/nif/save_character(var/savefile/S)
S["nif_path"] << pref.nif_path
S["nif_durability"] << pref.nif_durability
/datum/category_item/player_setup_item/vore/nif/sanitize_character()
if(pref.nif_path && !ispath(pref.nif_path)) //We have at least a text string that should be a path.
pref.nif_path = text2path(pref.nif_path) //Try to convert it to a hard path.
if(!pref.nif_path) //If we couldn't, kill it.
pref.nif_path = null //Kill!
WARNING("Loaded a NIF but it was an invalid path, [pref.real_name]")
if(ispath(pref.nif_path) && !pref.nif_durability) //How'd you lose this?
pref.nif_durability = initial(pref.nif_path.durability) //Well, have a new one, my bad.
WARNING("Loaded a NIF but with no durability, [pref.real_name]")
/datum/category_item/player_setup_item/vore/nif/copy_to_mob(var/mob/living/carbon/human/character)
//If you had a NIF...
if((character.type == /mob/living/carbon/human) && ispath(pref.nif_path) && pref.nif_durability)
new pref.nif_path(character,pref.nif_durability)
//And now here's the trick. We wipe these so that if they die, they lose the NIF.
//Backup implants will start saving this again periodically, and so will cryo'ing out.
pref.nif_path = null
pref.nif_durability = null
var/savefile/S = new /savefile(pref.path)
if(!S) WARNING ("Couldn't load NIF save savefile? [pref.real_name]")
S.cd = "/character[pref.default_slot]"
save_character(S)
/datum/category_item/player_setup_item/vore/nif/content(var/mob/user)
. += "<b>NIF:</b> [ispath(pref.nif_path) ? "Present" : "None"]"
+18 -18
View File
@@ -123,39 +123,39 @@
if (istype(H, /obj/item/weapon/handcuffs))
attach_cuffs(H, user)
/obj/item/clothing/shoes/hightops
name = "white high tops"
/obj/item/clothing/shoes/hitops
name = "white high-tops"
desc = "A pair of shoes that extends past the ankle. Based on a centuries-old, timeless design."
icon_state = "whitehi"
/obj/item/clothing/shoes/hightops/red
name = "red high tops"
/obj/item/clothing/shoes/hitops/red
name = "red high-tops"
icon_state = "redhi"
/obj/item/clothing/shoes/hightops/brown
name = "brown high tops"
/obj/item/clothing/shoes/hitops/brown
name = "brown high-tops"
icon_state = "brownhi"
/obj/item/clothing/shoes/hightops/black
name = "black high tops"
/obj/item/clothing/shoes/hitops/black
name = "black high-tops"
icon_state = "blackhi"
/obj/item/clothing/shoes/hightops/orange
name = "orange high tops"
/obj/item/clothing/shoes/hitops/orange
name = "orange high-tops"
icon_state = "orangehi"
/obj/item/clothing/shoes/hightops/blue
name = "blue high tops"
/obj/item/clothing/shoes/hitops/blue
name = "blue high-tops"
icon_state = "bluehi"
/obj/item/clothing/shoes/hightops/green
name = "green high tops"
/obj/item/clothing/shoes/hitops/green
name = "green high-tops"
icon_state = "greenhi"
/obj/item/clothing/shoes/hightops/purple
name = "purple high tops"
/obj/item/clothing/shoes/hitops/purple
name = "purple high-tops"
icon_state = "purplehi"
/obj/item/clothing/shoes/hightops/yellow
name = "yellow high tops"
/obj/item/clothing/shoes/hitops/yellow
name = "yellow high-tops"
icon_state = "yellowhi"
+1 -1
View File
@@ -199,7 +199,7 @@
if(!piece) continue
piece.icon_state = "[initial(icon_state)]"
if(airtight)
piece.item_flags &= ~(STOPPRESSUREDAMAGE|AIRTIGHT|PHORONGUARD) //VOREStation edit
piece.item_flags &= ~(STOPPRESSUREDAMAGE|AIRTIGHT)
update_icon(1)
/obj/item/weapon/rig/proc/toggle_seals(var/mob/living/carbon/human/M,var/instant)
@@ -322,4 +322,13 @@
update_icon()
return 1
else
return 1
return 1
/obj/item/clothing/head/helmet/space/rig
phoronproof = 1
/obj/item/clothing/gloves/gauntlets/rig
phoronproof = 1
/obj/item/clothing/shoes/magboots/rig
phoronproof = 1
/obj/item/clothing/suit/space/rig
phoronproof = 1
+5 -1
View File
@@ -102,6 +102,10 @@
if(do_after(user,30))
user.visible_message("\The [user] finishes wiping off the [A]!")
A.clean_blood()
if(istype(A, /turf) || istype(A, /obj/effect/decal/cleanable) || istype(A, /obj/effect/overlay) || istype(A, /obj/effect/rune)) //VOREStation Edit - "Allows rags to clean dirt from turfs"
var/turf/T = get_turf(A)
if(T)
T.clean(src, user) //VOREStation Edit End
/obj/item/weapon/reagent_containers/glass/rag/attack(atom/target as obj|turf|area, mob/user as mob , flag)
if(isliving(target))
@@ -132,7 +136,7 @@
if(!proximity)
return
if(istype(A, /obj/structure/reagent_dispensers))
if(istype(A, /obj/structure/reagent_dispensers) || istype(A, /obj/item/weapon/reagent_containers/glass/bucket) || istype(A, /obj/structure/mopbucket)) //VOREStation Edit - "Allows rags to be used on buckets and mopbuckets"
if(!reagents.get_free_space())
user << "<span class='warning'>\The [src] is already soaked.</span>"
return
+6 -8
View File
@@ -2,7 +2,7 @@
var/const/enterBelt = 30
var/const/radIntervall = 5 // Enough time between enter/leave belt for 10 hits, as per original implementation
var/const/leaveBelt = 80
var/const/revokeAccess = 135
var/const/revokeAccess = 165
startWhen = 2
announceWhen = 1
endWhen = revokeAccess
@@ -27,23 +27,21 @@
radiate()
else if(activeFor == leaveBelt)
command_announcement.Announce("The station has passed the radiation belt. Please report to medbay if you experience any unusual symptoms. Maintenance will lose all access again shortly.", "Anomaly Alert")
command_announcement.Announce("The station has passed the radiation belt. Please allow for up to one minute while radiation levels dissipate, and report to medbay if you experience any unusual symptoms. Maintenance will lose all access again shortly.", "Anomaly Alert")
/datum/event/radiation_storm/proc/radiate()
var/radiation_level = rand(15, 35)
for(var/z in using_map.station_levels)
radiation_repository.z_radiate(locate(1, 1, z), radiation_level, 1)
for(var/mob/living/carbon/C in living_mob_list)
var/area/A = get_area(C)
if(!A)
continue
if(!(A.z in using_map.station_levels))
continue
if(A.flags & RAD_SHIELDED)
continue
if(istype(C,/mob/living/carbon/human))
var/mob/living/carbon/human/H = C
H.apply_effect((rand(15,35)),IRRADIATE,0)
if(prob(5))
H.apply_effect((rand(40,70)),IRRADIATE,0)
if (prob(75))
randmutb(H) // Applies bad mutation
domutcheck(H,null,MUTCHK_FORCED)
+2 -2
View File
@@ -27,6 +27,7 @@
radiate()
/datum/event/solar_storm/proc/radiate()
// Note: Too complicated to be worth trying to use the radiation system for this. Its only in space anyway, so we make an exception in this case.
for(var/mob/living/L in living_mob_list)
var/turf/T = get_turf(L)
if(!T)
@@ -36,8 +37,7 @@
continue
//Todo: Apply some burn damage from the heat of the sun. Until then, enjoy some moderate radiation.
L.apply_effect((rand(15,30)),IRRADIATE,blocked = L.getarmor(null, "rad"))
L.rad_act(rand(15, 30))
/datum/event/solar_storm/end()
command_announcement.Announce("The solar storm has passed the station. It is now safe to resume EVA activities. Please report to medbay if you experience any unusual symptoms. ", "Anomaly Alert")
+1 -1
View File
@@ -332,7 +332,7 @@ proc/check_panel(mob/M)
qdel(O)
return
var/list/non_fakeattack_weapons = list(/obj/item/weapon/gun/projectile, /obj/item/ammo_magazine/a357,\
var/list/non_fakeattack_weapons = list(/obj/item/weapon/gun/projectile, /obj/item/ammo_magazine/s357,\
/obj/item/weapon/gun/energy/crossbow, /obj/item/weapon/melee/energy/sword,\
/obj/item/weapon/storage/box/syndicate, /obj/item/weapon/storage/box/emps,\
/obj/item/weapon/cartridge/syndicate, /obj/item/clothing/under/chameleon,\
+21
View File
@@ -93,3 +93,24 @@
/obj/item/weapon/reagent_containers/food/snacks/meat
)
result = /obj/item/weapon/reagent_containers/food/snacks/generalschicken
/datum/recipe/chocroizegg
items = list(
/obj/item/weapon/reagent_containers/food/snacks/chocolatebar,
/obj/item/weapon/reagent_containers/food/snacks/egg/roiz
)
result = /obj/item/weapon/reagent_containers/food/snacks/chocolateegg/roiz
/datum/recipe/friedroizegg
reagents = list("sodiumchloride" = 1, "blackpepper" = 1)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/egg/roiz
)
result = /obj/item/weapon/reagent_containers/food/snacks/friedegg/roiz
/datum/recipe/boiledroizegg
reagents = list("water" = 5)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/egg/roiz
)
result = /obj/item/weapon/reagent_containers/food/snacks/boiledegg/roiz
+1 -1
View File
@@ -482,7 +482,7 @@ var/list/mining_overlay_cache = list()
M.flash_eyes()
if(prob(50))
M.Stun(5)
M.apply_effect(25, IRRADIATE)
radiation_repository.flat_radiate(src, 25, 200)
if(prob(25))
excavate_find(prob(5), finds[1])
else if(rand(1,500) == 1)
@@ -22,6 +22,13 @@
else
//Okay, we can breathe, now check if we can get air
breath = get_breath_from_internal() //First, check for air from internals
//VOREStation Add - Respirocytes as a NIF implant
if(!breath && ishuman(src))
var/mob/living/carbon/human/H = src
if(H.nif && H.nif.flag_check(NIF_H_SPAREBREATH,NIF_FLAGS_HEALTH))
var/datum/nifsoft/spare_breath/SB = H.nif.imp_check(NIF_SPAREBREATH)
breath = SB.resp_breath()
//VOREStation Add End
if(!breath)
breath = get_breath_from_environment() //No breath from internals so let's try to get air from our location
if(!breath)
+1
View File
@@ -254,6 +254,7 @@
src.sleeping = max(0,src.sleeping-5)
if(src.sleeping == 0)
src.resting = 0
if(H) H.in_stasis = 0 //VOREStation Add - Just In Case
M.visible_message("<span class='notice'>[M] shakes [src] trying to wake [t_him] up!</span>", \
"<span class='notice'>You shake [src] trying to wake [t_him] up!</span>")
else
@@ -114,15 +114,23 @@
//For OmniHUD records access for appropriate models
/proc/hasHUD_vr(mob/living/carbon/human/H, hudtype)
if(!(istype(H.glasses, /obj/item/clothing/glasses/omnihud)))
return 0 //Not wearing omnis, don't care.
if(H.nif)
switch(hudtype)
if("security")
if(H.nif.flag_check(NIF_V_AR_SECURITY,NIF_FLAGS_VISION))
return TRUE
if("medical")
if(H.nif.flag_check(NIF_V_AR_MEDICAL,NIF_FLAGS_VISION))
return TRUE
var/obj/item/clothing/glasses/omnihud/omni = H.glasses
if(istype(H.glasses, /obj/item/clothing/glasses/omnihud))
var/obj/item/clothing/glasses/omnihud/omni = H.glasses
switch(hudtype)
if("security")
if(omni.mode == "sec" || omni.mode == "best")
return TRUE
if("medical")
if(omni.mode == "med" || omni.mode == "best")
return TRUE
switch(hudtype)
if("security")
return omni.mode == "sec" || omni.mode == "best"
if("medical")
return omni.mode == "med" || omni.mode == "best"
else
return 0
return FALSE
@@ -1037,7 +1037,8 @@
gunshot_residue = null
if(clean_feet && !shoes && istype(feet_blood_DNA, /list) && feet_blood_DNA.len)
feet_blood_color = null
qdel(feet_blood_DNA)
feet_blood_DNA.Cut()
feet_blood_DNA = null
update_inv_shoes(1)
return 1
@@ -1,5 +1,6 @@
/mob/living/carbon/human/proc/get_unarmed_attack(var/mob/living/carbon/human/target, var/hit_zone)
// VOREStation Edit - Begin
if(nif && nif.flag_check(NIF_C_HARDCLAWS,NIF_FLAGS_COMBAT)){return unarmed_hardclaws}
if(src.default_attack && src.default_attack.is_usable(src, target, hit_zone))
if(pulling_punches)
var/datum/unarmed_attack/soft_type = src.default_attack.get_sparring_variant()
@@ -104,6 +104,7 @@
amount *= M.incoming_damage_percent
if(!isnull(M.incoming_brute_damage_percent))
amount *= M.incoming_brute_damage_percent
if(nif && nif.flag_check(NIF_C_BRUTEARMOR,NIF_FLAGS_COMBAT)){amount *= 0.7} //VOREStation Edit - NIF mod for damage resistance for this type of damage
take_overall_damage(amount, 0)
else
for(var/datum/modifier/M in modifiers)
@@ -120,6 +121,7 @@
amount *= M.incoming_damage_percent
if(!isnull(M.incoming_fire_damage_percent))
amount *= M.incoming_fire_damage_percent
if(nif && nif.flag_check(NIF_C_BURNARMOR,NIF_FLAGS_COMBAT)){amount *= 0.7} //VOREStation Edit - NIF mod for damage resistance for this type of damage
take_overall_damage(0, amount)
else
for(var/datum/modifier/M in modifiers)
@@ -139,6 +141,7 @@
amount *= M.incoming_damage_percent
if(!isnull(M.incoming_brute_damage_percent))
amount *= M.incoming_brute_damage_percent
if(nif && nif.flag_check(NIF_C_BRUTEARMOR,NIF_FLAGS_COMBAT)){amount *= 0.7} //VOREStation Edit - NIF mod for damage resistance for this type of damage
O.take_damage(amount, 0, sharp=is_sharp(damage_source), edge=has_edge(damage_source), used_weapon=damage_source)
else
for(var/datum/modifier/M in modifiers)
@@ -160,6 +163,7 @@
amount *= M.incoming_damage_percent
if(!isnull(M.incoming_fire_damage_percent))
amount *= M.incoming_fire_damage_percent
if(nif && nif.flag_check(NIF_C_BURNARMOR,NIF_FLAGS_COMBAT)){amount *= 0.7} //VOREStation Edit - NIF mod for damage resistance for this type of damage
O.take_damage(0, amount, sharp=is_sharp(damage_source), edge=has_edge(damage_source), used_weapon=damage_source)
else
for(var/datum/modifier/M in modifiers)
@@ -94,7 +94,7 @@ emp_act
var/obj/item/organ/external/organ = organs_by_name[organ_name]
if(organ)
var/weight = organ_rel_size[organ_name]
armorval += getarmor_organ(organ, type) * weight
armorval += (getarmor_organ(organ, type) * weight)
total += weight
return (armorval/max(total, 1))
@@ -32,7 +32,7 @@
if(force_process)
bad_external_organs.Cut()
for(var/obj/item/organ/external/Ex in organs)
bad_external_organs |= Ex
bad_external_organs += Ex //VOREStation Edit - Silly and slow to |= this
//processing internal organs is pretty cheap, do that first.
for(var/obj/item/organ/I in internal_organs)
@@ -44,6 +44,7 @@
if(!force_process && !bad_external_organs.len)
return
number_wounds = 0 //VOREStation Add - You have to reduce this at some point...
for(var/obj/item/organ/external/E in bad_external_organs)
if(!E)
continue
+9 -6
View File
@@ -82,7 +82,7 @@
handle_medical_side_effects()
handle_heartbeat()
handle_nif() //VOREStation Add
if(!client)
species.handle_npc(src)
@@ -666,7 +666,8 @@
pressure_alert = -1
else
if( !(COLD_RESISTANCE in mutations))
take_overall_damage(brute=LOW_PRESSURE_DAMAGE, used_weapon = "Low Pressure")
if(!isSynthetic() || !nif || !nif.flag_check(NIF_O_PRESSURESEAL,NIF_FLAGS_OTHER)) //VOREStation Edit - NIF pressure seals
take_overall_damage(brute=LOW_PRESSURE_DAMAGE, used_weapon = "Low Pressure")
if(getOxyLoss() < 55) // 11 OxyLoss per 4 ticks when wearing internals; unconsciousness in 16 ticks, roughly half a minute
adjustOxyLoss(4) // 16 OxyLoss per 4 ticks when no internals present; unconsciousness in 13 ticks, roughly twenty seconds
pressure_alert = -2
@@ -703,7 +704,8 @@
// FBPs will overheat, prosthetic limbs are fine.
if(robobody_count)
bodytemperature += round(robobody_count*1.75)
if(!nif || !nif.flag_check(NIF_O_HEATSINKS,NIF_FLAGS_OTHER)) //VOREStation Edit - NIF heatsinks
bodytemperature += round(robobody_count*1.75)
var/body_temperature_difference = species.body_temperature - bodytemperature
@@ -1267,7 +1269,7 @@
var/obj/item/clothing/glasses/G = glasses
if(!G.prescription)
set_fullscreen(disabilities & NEARSIGHTED, "impaired", /obj/screen/fullscreen/impaired, 1)
else
else if (!nif || !nif.flag_check(NIF_V_CORRECTIVE,NIF_FLAGS_VISION)) //VOREStation Edit - NIF
set_fullscreen(disabilities & NEARSIGHTED, "impaired", /obj/screen/fullscreen/impaired, 1)
set_fullscreen(eye_blurry, "blurry", /obj/screen/fullscreen/blurry)
@@ -1282,6 +1284,7 @@
var/obj/item/clothing/glasses/welding/O = glasses
if(!O.up)
found_welder = 1
if(!found_welder && nif && nif.flag_check(NIF_V_UVFILTER,NIF_FLAGS_VISION)) found_welder = 1 //VOREStation Add - NIF
if(!found_welder && istype(head, /obj/item/clothing/head/welding))
var/obj/item/clothing/head/welding/O = head
if(!O.up)
@@ -1336,10 +1339,10 @@
var/obj/item/clothing/glasses/omnihud/S = G
O = S.hud
//VOREStation Add End
if(istype(G, /obj/item/clothing/glasses/sunglasses/sechud))
else if(istype(G, /obj/item/clothing/glasses/sunglasses/sechud)) //VOREStation Edit - Added else
var/obj/item/clothing/glasses/sunglasses/sechud/S = G
O = S.hud
if(istype(G, /obj/item/clothing/glasses/sunglasses/medhud))
else if(istype(G, /obj/item/clothing/glasses/sunglasses/medhud)) //VOREStation Edit - Added else
var/obj/item/clothing/glasses/sunglasses/medhud/M = G
O = M.hud
if(istype(O))
@@ -43,3 +43,10 @@
vantag.icon_state = vantag_pref
else
vantag.icon_state = "hudblank"
//Our call for the NIF to do whatever
/mob/living/carbon/human/proc/handle_nif()
if(!nif) return
//Process regular life stuff
nif.life()
@@ -17,13 +17,13 @@
return
if(C.stat == DEAD) //Uh oh, you died!
if(C.reagents.has_reagent("nutriment")) //Let's hope you have nutriment in you.... If not
if(C.hasnutriment()) //Let's hope you have nutriment in you.... If not
var/time = (500+1/((nutrition_used/100+1)/1300))
C.weakened = 10000 //Since it takes 1 tick to lose one weaken. Due to prior rounding errors, you'd sometimes unweaken before regenning. This fixes that.
C.reviving = 1
C.canmove = 0 //Make them unable to move. In case they somehow get up before the delay.
C << "You begin to reconstruct your form. You will not be able to move during this time. It should take aproximately [round(time)] seconds."
C.in_stasis = 1
C.does_not_breathe = 1 //effectively makes them spaceworthy while regenning
spawn(time SECONDS)
if(C) //Runtime prevention.
@@ -42,7 +42,7 @@
C.reviving = 1
C.canmove = 0 //Make them unable to move. In case they somehow get up before the delay.
C << "You begin to reconstruct your form. You will not be able to move during this time. It should take aproximately [round(time)] seconds."
C.in_stasis = 1
C.does_not_breathe = 1 //effectively makes them spaceworthy while regenning
spawn(time SECONDS)
if(C.stat != DEAD) //If they're still alive after regenning.
@@ -50,11 +50,12 @@
C.verbs += /mob/living/carbon/human/proc/hatch
return
else if(C.stat == DEAD)
if(C.reagents.has_reagent("nutriment")) //Let's hope you have nutriment in you.... If not
if(C.hasnutriment()) //Let's hope you have nutriment in you.... If not
C << "<span class='notice'>Consciousness begins to stir as your new body awakens, ready to hatch..</span>"
C.verbs += /mob/living/carbon/human/proc/hatch
else //Dead until nutrition injected.
C << "Your body was unable to regenerate, what few living cells remain require additional nutrients to complete the process."
C.reviving = 0 // so they can try again when they're given a kickstart
return
else
return //Something went wrong
@@ -63,6 +64,14 @@
/mob/living/carbon/human/proc/hasnutriment()
if (src.bloodstr.has_reagent("nutriment", 30) || src.bloodstr.has_reagent("protein", 15)) //protein needs half as much. For reference, a steak contains 9u protein.
return 1
else if (src.ingested.has_reagent("nutriment", 60) || src.ingested.has_reagent("protein", 30)) //try forcefeeding them, why not. Less effective.
return 1
else return 0
/mob/living/carbon/human/proc/hatch()
set name = "Hatch"
set category = "Abilities"
@@ -85,7 +94,7 @@
var/T = get_turf(src)
new /obj/effect/gibspawner/human/scree(T)
var/braindamage = C.brainloss/2 //If you have 100 brainloss, it gives you 50.
C.in_stasis = 0
C.does_not_breathe = 0 //start breathing again
C.revive() // I did have special snowflake code, but this is easier.
C.weakened = 2 //Not going to let you get up immediately. 2 ticks before you get up. Overrides the above 10000 weaken.
C.nutrition = old_nutrition
@@ -119,7 +128,7 @@
C.drop_from_inventory(W)
spawn(3600 SECONDS) //1 hour wait until you can revive again.
C.reviving = 0
C.in_stasis = 0
C.does_not_breathe = 0 //start breathing again
C.verbs -= /mob/living/carbon/human/proc/hatch
return
else
@@ -73,7 +73,7 @@
H.feral = min(150-H.nutrition, H.feral+1) //Feralness increases while this hungry, capped at 50-150 depending on hunger.
// If they're hurt, chance of snapping. Not if they're straight-up KO'd though.
if (H.stat == CONSCIOUS && H.traumatic_shock >=36 && H.in_stasis == 0) //30 brute/burn, or 18 halloss.
if (H.stat == CONSCIOUS && H.traumatic_shock >=36) //30 brute/burn, or 18 halloss.
if (2.5*H.halloss >= H.traumatic_shock) //If the majority of their shock is due to halloss, greater chance of snapping.
if(prob(min(10,(0.2 * H.traumatic_shock))))
if(H.feral == 0)
@@ -111,6 +111,8 @@
if(H.feral > 0) //do the following if feral, otherwise no effects.
var/light_amount = H.getlightlevel() //how much light there is in the place
H.shock_stage = max(H.shock_stage-(H.feral/20), 0) //if they lose enough health to hit softcrit, handle_shock() will keep resetting this. Otherwise, pissed off critters will lose shock faster than they gain it.
for(var/mob/living/M in viewers(H))
if(M != H) // someone in view
if(prob(0.5)) // 1 in 200 chance of doing something so as not to interrupt scenes
@@ -160,28 +162,25 @@
var/pressure2 = environment.return_pressure()
var/adjusted_pressure2 = H.calculate_affecting_pressure(pressure2)
if(adjusted_pressure2 <= 20 && H.in_stasis == 1) //If they're in a enviroment with no pressure and are in stasis (See: regenerating), don't kill them.
if(adjusted_pressure2 <= 20 && H.does_not_breathe) //If they're in a enviroment with no pressure and are not breathing (See: regenerating), don't kill them.
//This is just to prevent them from taking damage if they're in stasis.
else if(adjusted_pressure2 <= 20) //If they're in an enviroment with no pressure and are NOT in stasis, damage them.
H.take_overall_damage(brute=LOW_PRESSURE_DAMAGE, used_weapon = "Low Pressure")
if(H.bodytemperature <= 260 && H.in_stasis == 1) //If they're in stasis, don't give them them the negative cold effects
if(H.bodytemperature <= 260 && H.does_not_breathe) //If they're regenerating, don't give them them the negative cold effects
//This is just here to prevent them from getting cold effects
else if(H.bodytemperature <= 260) //If they're not in stasis and are cold. Don't really have to add in an exception to cryo cells, as the effects aren't anything /too/ horrible.
var/colddamage = 0
var/coldshock = 0
if(H.bodytemperature <= 260 && H.bodytemperature >= 200) //Chilly.
colddamage = 4 //This will begin to knock them out until they run out of oxygen and suffocate or until someone finds them.
coldshock = 4 //This will begin to knock them out until they run out of oxygen and suffocate or until someone finds them.
H.eye_blurry = 5 //Blurry vision in the cold.
if(H.bodytemperature <= 199 && H.bodytemperature >= 100) //Extremely cold. Even in somewhere like the server room it takes a while for bodytemp to drop this low.
colddamage = 8
coldshock = 8
H.eye_blurry = 5
if(H.bodytemperature <= 99) //Insanely cold.
colddamage = 20
coldshock = 16
H.eye_blurry = 5
if(H.paralysis) //stops weaken spam from being repeatedly taken over max halloss when already KO'd.
H.halloss = min(H.halloss+colddamage, H.species.total_health - 1) //if already stunned, only take them up to the point of restunning
else
H.halloss += colddamage //Harsh punishment for staying in space, and it'll take them a while to fully thaw out when they get retrieved.
H.shock_stage = min(H.shock_stage + coldshock, 160) //cold hurts and gives them pain messages, eventually weakening and paralysing, but doesn't damage or trigger feral.
return
@@ -56,6 +56,18 @@
cost = -2
var_changes = list("burn_mod" = 1.30)
/datum/trait/conductive
name = "Conductive"
desc = "Increases your susceptibility to electric shocks by a small amount."
cost = -1
var_changes = list("siemens_coefficient" = 1.15)
/datum/trait/conductive_plus
name = "Conductive (Plus)"
desc = "Increases your susceptibility to electric shocks by a moderate amount."
cost = -2
var_changes = list("siemens_coefficient" = 1.3)
/datum/trait/photosensitive
name = "Photosensitive"
desc = "Increases stun duration from flashes and other light-based stuns."
@@ -32,6 +32,18 @@
..(S,H)
H.setMaxHealth(S.total_health)
/datum/trait/nonconductive
name = "Non-Conductive"
desc = "Decreases your susceptibility to electric shocks by a small amount."
cost = 1
var_changes = list("siemens_coefficient" = 0.85)
/datum/trait/nonconductive_plus
name = "Non-Conductive (Plus)"
desc = "Decreases your susceptibility to electric shocks by a moderate amount."
cost = 2
var_changes = list("siemens_coefficient" = 0.7)
/datum/trait/darksight
name = "Darksight"
desc = "Allows you to see a short distance in the dark."
@@ -352,6 +352,7 @@ var/global/list/robot_modules = list(
src.modules += new /obj/item/device/pipe_painter(src)
src.modules += new /obj/item/device/floor_painter(src)
src.modules += new /obj/item/weapon/gripper/no_use/loader(src)
src.modules += new /obj/item/device/geiger(src)
var/datum/matter_synth/metal = new /datum/matter_synth/metal()
var/datum/matter_synth/plasteel = new /datum/matter_synth/plasteel()
@@ -396,6 +397,7 @@ var/global/list/robot_modules = list(
src.modules += new /obj/item/device/pipe_painter(src)
src.modules += new /obj/item/device/floor_painter(src)
src.emag = new /obj/item/weapon/melee/baton/robot/arm(src)
src.modules += new /obj/item/device/geiger(src)
var/datum/matter_synth/metal = new /datum/matter_synth/metal(40000)
var/datum/matter_synth/glass = new /datum/matter_synth/glass(40000)
@@ -56,7 +56,7 @@
melee_damage_lower = 5
melee_damage_upper = 10
poison_per_bite = 7
poison_type = "stoxin"
poison_type = "spidertoxin" // VOREStation edit, original is stoxin. (sleep toxins)
var/fed = 0
var/atom/cocoon_target
@@ -627,7 +627,6 @@
/datum/sprite_accessory/facial_hair
icon = 'icons/mob/Human_face.dmi'
gender = MALE
shaved
name = "Shaved"
@@ -1309,4 +1308,4 @@
name = "Default skrell skin"
icon_state = "default"
icon = 'icons/mob/human_races/r_skrell.dmi'
species_allowed = list("Skrell")
species_allowed = list("Skrell")
+38
View File
@@ -164,6 +164,14 @@
/obj/effect/decal/cleanable/can_fall()
return TRUE
// These didn't fall anyways but better to nip this now just incase.
/atom/movable/lighting_overlay/can_fall()
return FALSE
// Mechas are anchored, so we need to override.
/obj/mecha/can_fall()
return TRUE
/obj/item/pipe/can_fall()
. = ..()
@@ -291,3 +299,33 @@
apply_damage(rand(0, damage), BRUTE, BP_R_ARM)
Weaken(4)
updatehealth()
/obj/mecha/handle_fall(var/turf/landing)
// First things first, break any lattice
var/obj/structure/lattice/lattice = locate(/obj/structure/lattice, loc)
if(lattice)
// Lattices seem a bit too flimsy to hold up a massive exosuit.
lattice.visible_message("<span class='danger'>\The [lattice] collapses under the weight of \the [src]!</span>")
qdel(lattice)
// Then call parent to have us actually fall
return ..()
/obj/mecha/fall_impact(var/atom/hit_atom)
// Tell the pilot that they just dropped down with a superheavy mecha.
if(occupant)
to_chat(occupant, "<span class='warning'>\The [src] crashed down onto \the [hit_atom]!</span>")
// Anything on the same tile as the landing tile is gonna have a bad day.
for(var/mob/living/L in hit_atom.contents)
L.visible_message("<span class='danger'>\The [src] crushes \the [L] as it lands on them!</span>")
L.adjustBruteLoss(rand(70, 100))
L.Weaken(8)
// Now to hurt the mech.
take_damage(rand(15, 30))
// And hurt the floor.
if(istype(hit_atom, /turf/simulated/floor))
var/turf/simulated/floor/ground = hit_atom
ground.break_tile()
+7 -1
View File
@@ -94,7 +94,7 @@
// VOREStation Edit End
// get objects (not mobs, they are handled by /obj/zshadow)
var/image/o_img = list()
var/list/o_img = list()
for(var/obj/O in below)
if(O.invisibility) continue // Ignore objects that have any form of invisibility
if(O.loc != below) continue // Ignore multi-turf objects not directly below
@@ -104,7 +104,13 @@
temp2.overlays += O.overlays
// TODO Is pixelx/y needed?
o_img += temp2
var/overlays_pre = overlays.len
overlays += o_img
var/overlays_post = overlays.len
if(overlays_post != (overlays_pre + o_img.len)) //Here we go!
world.log << "Corrupted openspace turf at [x],[y],[z] being replaced. Pre: [overlays_pre], Post: [overlays_post]"
new /turf/simulated/open(src)
return //Let's get out of here.
if(!below_is_open)
overlays += over_OS_darkness
+21 -1
View File
@@ -1,7 +1,7 @@
/*
This state checks that the src_object is on the user's glasses slot.
*/
/var/global/datum/topic_state/inventory_state/glasses_state = new()
/var/global/datum/topic_state/glasses_state/glasses_state = new()
/datum/topic_state/glasses_state/can_use_topic(var/src_object, var/mob/user)
if(ishuman(user))
@@ -10,3 +10,23 @@
return user.shared_nano_interaction()
return STATUS_CLOSE
/var/global/datum/topic_state/nif_state/nif_state = new()
/datum/topic_state/nif_state/can_use_topic(var/src_object, var/mob/user)
if(ishuman(user))
var/mob/living/carbon/human/H = user
if(H.nif && H.nif.stat == NIF_WORKING && src_object == H.nif)
return user.shared_nano_interaction()
return STATUS_CLOSE
/var/global/datum/topic_state/commlink_state/commlink_state = new()
/datum/topic_state/commlink_state/can_use_topic(var/src_object, var/mob/user)
if(ishuman(user))
var/mob/living/carbon/human/H = user
if(H.nif && H.nif.stat == NIF_WORKING && H.nif.comm == src_object)
return user.shared_nano_interaction()
return STATUS_CLOSE
+560
View File
@@ -0,0 +1,560 @@
//Holder on humans to prevent having to 'find' it every time
/mob/living/carbon/human/var/obj/item/device/nif/nif
//Nanotech Implant Foundation
/obj/item/device/nif
name = "nanite implant framework"
desc = "A somewhat diminished knockoff of a Kitsuhana nano working surface, in a box. Can print new \
implants inside living hosts on the fly based on software uploads. Must be surgically \
implanted in the head to work. May eventually wear out and break."
icon = 'icons/obj/device_alt.dmi'
icon_state = "nif_0"
w_class = ITEMSIZE_TINY
var/durability = 100 // Durability remaining
var/bioadap = FALSE // If it'll work in fancy species
var/tmp/power_usage = 0 // Nifsoft adds to this
var/tmp/mob/living/carbon/human/human // Our owner!
var/tmp/list/nifsofts[TOTAL_NIF_SOFTWARE] // All our nifsofts
var/tmp/list/nifsofts_life = list() // Ones that want to be talked to on life()
var/owner // Owner character name
var/tmp/vision_flags = 0 // Flags implants set for faster lookups
var/tmp/health_flags = 0
var/tmp/combat_flags = 0
var/tmp/other_flags = 0
var/tmp/stat = NIF_PREINSTALL // Status of the NIF
var/tmp/install_done // Time when install will finish
var/tmp/open = FALSE // If it's open for maintenance (1-3)
var/obj/item/clothing/glasses/hud/nif_hud/nif_hud // The AR ones require this
var/obj/item/device/communicator/commlink/comm // The commlink requires this
var/global/icon/big_icon
var/global/click_sound = 'sound/items/nif_click.ogg'
var/global/bad_sound = 'sound/items/nif_tone_bad.ogg'
var/global/good_sound = 'sound/items/nif_tone_good.ogg'
var/global/list/look_messages = list(
"flicks their eyes around",
"looks at something unseen",
"reads some invisible text",
"seems to be daydreaming",
"focuses elsewhere for a moment")
//Constructor comes with a free AR HUD
/obj/item/device/nif/New(var/newloc,var/wear)
..(newloc)
//Required for AR stuff.
nif_hud = new(src)
//First one to spawn in the game, make a big icon
if(!big_icon)
big_icon = new(icon,icon_state = "nif_full")
//If given a human on spawn (probably from persistence)
if(ishuman(newloc))
var/mob/living/carbon/human/H = newloc
if(!quick_implant(H))
WARNING("NIF spawned in [H] failed to implant")
spawn(0)
qdel(src)
return FALSE
else
//Free commlink for return customers
new /datum/nifsoft/commlink(src)
//Free civilian AR included
new /datum/nifsoft/ar_civ(src)
//If given wear (like when spawned) then done
if(wear)
durability = wear
wear(0) //Just make it update.
//Draw me yo.
update_icon()
//Destructor cleans up references
/obj/item/device/nif/Destroy()
if(human)
human.nif = null
human = null
for(var/S in nifsofts)
if(S)
qdel(S)
if(nif_hud)
qdel(nif_hud)
if(comm)
qdel(comm)
nifsofts.Cut()
..()
//Being implanted in some mob
/obj/item/device/nif/proc/implant(var/mob/living/carbon/human/H)
if(istype(H) && !H.nif && H.species && (loc == H.get_organ(BP_HEAD)))
if(!bioadap && (H.species.flags & NO_SCAN)) //NO_SCAN is the default 'too complicated' flag
return FALSE
human = H
human.nif = src
stat = NIF_INSTALLING
return TRUE
return FALSE
//For debug or antag purposes
/obj/item/device/nif/proc/quick_implant(var/mob/living/carbon/human/H)
if(istype(H))
var/obj/item/organ/external/head = H.get_organ(BP_HEAD)
if(!head)
return FALSE
src.forceMove(head)
head.implants += src
spawn(0) //Let the character finish spawning yo.
owner = H.mind.name
implant(H)
return TRUE
return FALSE
//Being removed from some mob
/obj/item/device/nif/proc/unimplant(var/mob/living/carbon/human/H)
human = null
stat = NIF_PREINSTALL
install_done = null
if(istype(H))
H.nif = null
update_icon()
//EMP adds wear and disables all nifsoft
/obj/item/device/nif/emp_act(var/severity)
notify("Danger! Significant electromagnetic interference!",TRUE)
for(var/nifsoft in nifsofts)
if(nifsoft)
var/datum/nifsoft/NS = nifsoft
NS.deactivate()
switch (severity)
if (1)
wear(rand(30,40))
if (2)
wear(rand(15,25))
if (3)
wear(rand(8,15))
if (4)
wear(rand(1,8))
//Wear update/check proc
/obj/item/device/nif/proc/wear(var/wear = 0)
wear *= (rand(85,115) / 100) //Apparently rand() only takes integers.
durability -= wear
if(durability <= 0)
notify("Danger! General system insta#^!($",TRUE)
to_chat(human,"<span class='danger'>Your NIF vision overlays disappear and your head suddenly seems very quiet...</span>")
stat = NIF_TEMPFAIL
update_icon()
//Attackby proc, for maintenance
/obj/item/device/nif/attackby(obj/item/weapon/W, mob/user as mob)
if(open == 0 && istype(W,/obj/item/weapon/screwdriver))
if(do_after(user, 4 SECONDS, src) && open == 0)
user.visible_message("[user] unscrews and pries open \the [src].","<span class='notice'>You unscrew and pry open \the [src].</span>")
playsound(user, 'sound/items/Screwdriver.ogg', 50, 1)
open = 1
update_icon()
else if(open == 1 && istype(W,/obj/item/stack/cable_coil))
var/obj/item/stack/cable_coil/C = W
if(C.get_amount() < 3)
to_chat(user,"<span class='warning'>You need at least three coils of wire to add them to \the [src].</span>")
return
if(do_after(user, 6 SECONDS, src) && open == 1 && C.use(3))
user.visible_message("[user] replaces some wiring in \the [src].","<span class='notice'>You replace any burned out wiring in \the [src].</span>")
playsound(user, 'sound/items/Deconstruct.ogg', 50, 1)
open = 2
update_icon()
else if(open == 2 && istype(W,/obj/item/device/multitool))
if(do_after(user, 8 SECONDS, src) && open == 2)
user.visible_message("[user] resets several circuits in \the [src].","<span class='notice'>You find and repair any faulty circuits in \the [src].</span>")
open = 3
update_icon()
else if(open == 3 && istype(W,/obj/item/weapon/screwdriver))
if(do_after(user, 3 SECONDS, src) && open == 3)
user.visible_message("[user] closes up \the [src].","<span class='notice'>You re-seal \the [src] for use once more.</span>")
playsound(user, 'sound/items/Screwdriver.ogg', 50, 1)
open = FALSE
durability = initial(durability)
stat = NIF_PREINSTALL
update_icon()
//Icon updating
/obj/item/device/nif/update_icon()
if(open)
icon_state = "nif_open[open]"
else
switch(stat)
if(NIF_PREINSTALL)
icon_state = "nif_1"
if(NIF_INSTALLING)
icon_state = "nif_0"
if(NIF_WORKING)
icon_state = "nif_0"
if(NIF_TEMPFAIL)
icon_state = "nif_2"
else
icon_state = "nif_2"
//The (dramatic) install process
/obj/item/device/nif/proc/handle_install()
if(human.stat || !human.mind) //No stuff while KO or not sleeved
return FALSE
//Firsties
if(!install_done)
if(human.mind.name == owner)
install_done = world.time + 1 MINUTE
notify("Welcome back, [owner]! Performing quick-calibration...")
else if(!owner)
install_done = world.time + 30 MINUTES
notify("Adapting to new user...")
sleep(5 SECONDS)
notify("Adjoining optic [human.isSynthetic() ? "interface" : "nerve"], please be patient.",TRUE)
else
notify("You are not an authorized user for this device. Please contact [owner].",TRUE)
unimplant()
stat = NIF_TEMPFAIL
return FALSE
var/percent_done = (world.time - (install_done - (30 MINUTES))) / (30 MINUTES)
human.client.screen.Add(global_hud.whitense) //This is the camera static
switch(percent_done) //This is 0.0 to 1.0 kinda percent.
//Connecting to optical nerves
if(0.0 to 0.1)
human.eye_blind = 5
//Mapping brain
if(0.2 to 0.9)
if(prob(99)) return TRUE
var/incident = rand(1,3)
switch(incident)
if(1)
var/message = pick(list(
"Your head throbs around your new implant.",
"The skin around your recent surgery itches.",
"A wave of nausea overtakes you as the world seems to spin.",
"The floor suddenly seems to come up at you.",
"There's a throbbing lump of ice behind your eyes.",
"A wave of pain shoots down your neck."
))
to_chat(human,"<span class='danger'>[message]</span>")
if(2)
human.Weaken(5)
to_chat(human,"<span class='danger'>A wave of weakness rolls over you.</span>")
if(3)
human.Sleeping(5)
to_chat(human,"<span class='danger'>You suddenly black out!</span>")
//Finishing up
if(1.0 to INFINITY)
stat = NIF_WORKING
owner = human.mind.name
name = initial(name) + " ([owner])"
notify("Calibration complete! User data stored!")
//Called each life() tick on the mob
/obj/item/device/nif/proc/life()
if(!human || loc != human.get_organ(BP_HEAD))
unimplant(human)
return FALSE
switch(stat)
if(NIF_WORKING)
//Perform our passive drain
if(!use_charge(power_usage))
stat = NIF_POWFAIL
notify("Insufficient energy!",TRUE)
return FALSE
//HUD update!
nif_hud.process_hud(human,1)
//Process all the ones that want that
for(var/S in nifsofts_life)
var/datum/nifsoft/nifsoft = S
nifsoft.life(human)
if(NIF_POWFAIL)
if(human && human.nutrition < 100)
return FALSE
else
stat = NIF_WORKING
notify("System Reboot Complete.")
if(NIF_TEMPFAIL)
//Something else has to take us out of tempfail
return FALSE
if(NIF_INSTALLING)
handle_install()
return FALSE
//Prints 'AR' messages to the user
/obj/item/device/nif/proc/notify(var/message,var/alert = 0)
if(!human || stat == NIF_TEMPFAIL) return
to_chat(human,"<b>\[\icon[src.big_icon]NIF\]</b> displays, \"<span class='[alert ? "danger" : "notice"]'>[message]</span>\"")
if(prob(1)) human.visible_message("<span class='notice'>\The [human] [pick(look_messages)].</span>")
if(alert)
human << bad_sound
else
human << good_sound
//Called to spend nutrition, returns 1 if it was able to
/obj/item/device/nif/proc/use_charge(var/use_charge)
if(stat != NIF_WORKING) return FALSE
//You don't want us to take any? Well okay.
if(!use_charge)
return TRUE
//Not enough nutrition/charge left.
if(!human || human.nutrition < use_charge)
return FALSE
//Was enough, reduce and return.
human.nutrition -= use_charge
return TRUE
//Install a piece of software
/obj/item/device/nif/proc/install(var/datum/nifsoft/new_soft)
if(stat == NIF_TEMPFAIL) return FALSE
if(nifsofts[new_soft.list_pos])
return FALSE
if(human)
var/applies_to = new_soft.applies_to
var/synth = human.isSynthetic()
if(synth && !(applies_to & NIF_SYNTHETIC))
notify("The software \"[new_soft]\" is not supported on your chassis type.",TRUE)
return FALSE
if(!synth && !(applies_to & NIF_ORGANIC))
notify("The software \"[new_soft]\" is not supported in organic life.",TRUE)
return FALSE
wear(new_soft.wear)
nifsofts[new_soft.list_pos] = new_soft
power_usage += new_soft.p_drain
if(new_soft.tick_flags == NIF_ALWAYSTICK)
nifsofts_life += new_soft
if(new_soft.vision_flags)
vision_flags |= new_soft.vision_flags
if(new_soft.health_flags)
health_flags |= new_soft.health_flags
if(new_soft.combat_flags)
combat_flags |= new_soft.combat_flags
if(new_soft.other_flags)
other_flags |= new_soft.other_flags
return TRUE
//Uninstall a piece of software
/obj/item/device/nif/proc/uninstall(var/datum/nifsoft/old_soft)
var/datum/nifsoft/NS = nifsofts[old_soft.list_pos]
if(!NS || NS != old_soft)
return FALSE //what??
nifsofts[old_soft.list_pos] = null
power_usage -= old_soft.p_drain
if(old_soft.tick_flags == NIF_ALWAYSTICK)
nifsofts_life -= old_soft
if(old_soft.active)
power_usage -= old_soft.a_drain
if(old_soft.tick_flags == NIF_ACTIVETICK)
nifsofts_life -= old_soft
if(old_soft.vision_flags)
vision_flags &= ~old_soft.vision_flags
if(old_soft.health_flags)
health_flags &= ~old_soft.health_flags
if(old_soft.combat_flags)
combat_flags &= ~old_soft.combat_flags
if(old_soft.other_flags)
other_flags &= ~old_soft.other_flags
return TRUE
//Activate a nifsoft
/obj/item/device/nif/proc/activate(var/datum/nifsoft/soft)
if(stat != NIF_WORKING) return FALSE
if(human)
if(prob(5)) human.visible_message("<span class='notice'>\The [human] [pick(look_messages)].</span>")
var/applies_to = soft.applies_to
var/synth = human.isSynthetic()
if(synth && !(applies_to & NIF_SYNTHETIC))
notify("The software \"[soft]\" is not supported on your chassis type and will be uninstalled.",TRUE)
uninstall(soft)
return FALSE
if(!synth && !(applies_to & NIF_ORGANIC))
notify("The software \"[soft]\" is not supported in organic life and will be uninstalled.",TRUE)
uninstall(soft)
return FALSE
if(!use_charge(soft.a_drain))
notify("Not enough power to activate \"[soft]\" NIFsoft!",TRUE)
return FALSE
if(soft.tick_flags == NIF_ACTIVETICK)
nifsofts_life += soft
power_usage += soft.a_drain
human << click_sound
return TRUE
//Deactivate a nifsoft
/obj/item/device/nif/proc/deactivate(var/datum/nifsoft/soft)
if(human)
if(prob(5)) human.visible_message("<span class='notice'>\The [human] [pick(look_messages)].</span>")
if(soft.tick_flags == NIF_ACTIVETICK)
nifsofts_life -= soft
power_usage -= soft.a_drain
human << click_sound
return TRUE
//Deactivate several nifsofts
/obj/item/device/nif/proc/deactivate_these(var/list/turn_off)
for(var/N in turn_off)
var/datum/nifsoft/NS = nifsofts[N]
if(NS)
NS.deactivate()
//Add a flag to one of the holders
/obj/item/device/nif/proc/set_flag(var/flag,var/hint)
ASSERT(flag && hint)
switch(hint)
if(NIF_FLAGS_VISION)
vision_flags |= flag
if(NIF_FLAGS_HEALTH)
health_flags |= flag
if(NIF_FLAGS_COMBAT)
combat_flags |= flag
if(NIF_FLAGS_OTHER)
other_flags |= flag
else
CRASH("Not a valid NIF flag hint: [hint]")
//Clear a flag from one of the holders
/obj/item/device/nif/proc/clear_flag(var/flag,var/hint)
ASSERT(flag && hint)
switch(hint)
if(NIF_FLAGS_VISION)
vision_flags &= ~flag
if(NIF_FLAGS_HEALTH)
health_flags &= ~flag
if(NIF_FLAGS_COMBAT)
combat_flags &= ~flag
if(NIF_FLAGS_OTHER)
other_flags &= ~flag
else
CRASH("Not a valid NIF flag hint: [hint]")
//Check for an installed implant
/obj/item/device/nif/proc/imp_check(var/soft)
if(stat != NIF_WORKING) return FALSE
ASSERT(soft)
if(ispath(soft))
var/datum/nifsoft/path = soft
soft = initial(path.list_pos)
var/entry = nifsofts[soft]
if(entry)
return entry
//Check for a set flag
/obj/item/device/nif/proc/flag_check(var/flag,var/hint)
if(stat != NIF_WORKING) return FALSE
ASSERT(flag && hint)
var/result = FALSE
switch(hint)
if(NIF_FLAGS_VISION)
if(flag & vision_flags) result = TRUE
if(NIF_FLAGS_HEALTH)
if(flag & health_flags) result = TRUE
if(NIF_FLAGS_COMBAT)
if(flag & combat_flags) result = TRUE
if(NIF_FLAGS_OTHER)
if(flag & other_flags) result = TRUE
else
CRASH("Not a valid NIF flag hint: [hint]")
return result
///////////////////////////////////////////////////////////////////////////////////////
//NIF HUD object becasue HUD handling is trash and should be rewritten
/obj/item/clothing/glasses/hud/nif_hud/var/obj/item/device/nif/nif
/obj/item/clothing/glasses/hud/nif_hud/New(var/newloc)
..(newloc)
nif = newloc
/obj/item/clothing/glasses/hud/nif_hud/Destroy()
if(nif)
nif.nif_hud = null
nif = null
..()
/obj/item/clothing/glasses/hud/nif_hud/process_hud(M,var/thing)
//Faster checking with local var, and this is called often so I want fast.
var/visflags = nif.vision_flags
if(NIF_V_AR_OMNI & visflags)
process_omni_hud(nif.human, "best")
else if(NIF_V_AR_SECURITY & visflags)
process_omni_hud(nif.human, "sec")
else if(NIF_V_AR_MEDICAL & visflags)
process_omni_hud(nif.human, "med")
else if(NIF_V_AR_ENGINE & visflags)
process_omni_hud(nif.human, "eng")
else if(NIF_V_AR_SCIENCE & visflags)
process_omni_hud(nif.human, "sci")
else if(NIF_V_AR_CIVILIAN & visflags)
process_omni_hud(nif.human, "civ")
// Alternate NIFs
/obj/item/device/nif/bad
name = "second-hand NIF"
desc = "A copy of a copy of a copy of a copy of... this can't be any good, right? Surely?"
durability = 10
/obj/item/device/nif/authentic
name = "\improper Kitsuhana NIF"
desc = "An actual Kitsuhana working surface, in a box. From a society slightly less afraid \
of self-replicating nanotechnology. Basically just a high-endurance NIF."
durability = 1000
/obj/item/device/nif/bioadap
name = "bioadaptive NIF"
desc = "A NIF that goes out of it's way to accomidate strange body types. \
Will function in species where it normally wouldn't."
durability = 25
bioadap = TRUE
+183
View File
@@ -0,0 +1,183 @@
//Custom vendors
/obj/machinery/vending/nifsoft_shop
name = "NIFSoft Shop"
desc = "For all your mindware and mindware accessories."
product_ads = "Let us get into your head!;Looking for an upgrade?;Surpass Humanity!;Why be normal when you can be SUPERnormal?;Jack in with NIFSoft!"
icon_state = "nifsoft"
icon_vend = "nifsoft-purchase"
icon_deny = "nifsoft-problem"
products = list()
contraband = list()
premium = list()
var/global/list/starting_legal_nifsoft
var/global/list/starting_illegal_nifsoft
// Special Treatment!
/obj/machinery/vending/nifsoft_shop/build_inventory()
//Firsties
if(!starting_legal_nifsoft)
starting_legal_nifsoft = list()
starting_illegal_nifsoft = list()
for(var/P in subtypesof(/datum/nifsoft) - /datum/nifsoft/package)
var/datum/nifsoft/NS = P
if(initial(NS.vended))
switch(initial(NS.illegal))
if(TRUE)
starting_illegal_nifsoft += NS
if(FALSE)
starting_legal_nifsoft += NS
products = starting_legal_nifsoft.Copy()
contraband = starting_illegal_nifsoft.Copy()
var/list/all_products = list(
list(products, CAT_NORMAL),
list(contraband, CAT_HIDDEN),
list(premium, CAT_COIN))
for(var/current_list in all_products)
var/category = current_list[2]
for(var/entry in current_list[1])
var/datum/nifsoft/NS = entry
var/applies_to = initial(NS.applies_to)
var/context = ""
if(!(applies_to & NIF_SYNTHETIC))
context = " (Org Only)"
else if(!(applies_to & NIF_ORGANIC))
context = " (Syn Only)"
var/name = "[initial(NS.name)][context]"
var/datum/stored_item/vending_product/product = new/datum/stored_item/vending_product(src, entry, name)
product.price = initial(NS.cost)
product.amount = 10
product.category = category
product_records.Add(product)
/obj/machinery/vending/nifsoft_shop/allowed(mob/user)
if(!ishuman(user))
return FALSE
var/mob/living/carbon/human/H = user
if(!H.nif || !H.nif.stat == NIF_WORKING)
to_chat(H,"<span class='warning'>[src] seems unable to connect to your NIF...</span>")
flick(icon_deny,src)
return FALSE
return ..()
//Had to override this too
/obj/machinery/vending/nifsoft_shop/Topic(href, href_list)
if(stat & (BROKEN|NOPOWER))
return
if(usr.stat || usr.restrained())
return
if(href_list["remove_coin"] && !istype(usr,/mob/living/silicon))
if(!coin)
usr << "There is no coin in this machine."
return
coin.forceMove(src.loc)
if(!usr.get_active_hand())
usr.put_in_hands(coin)
usr << "<span class='notice'>You remove \the [coin] from \the [src]</span>"
coin = null
categories &= ~CAT_COIN
if((usr.contents.Find(src) || (in_range(src, usr) && istype(src.loc, /turf))))
if((href_list["vend"]) && (vend_ready) && (!currently_vending))
if((!allowed(usr)) && !emagged && scan_id) //For SECURE VENDING MACHINES YEAH
usr << "<span class='warning'>Access denied.</span>" //Unless emagged of course
flick(icon_deny,src)
return
var/key = text2num(href_list["vend"])
var/datum/stored_item/vending_product/R = product_records[key]
// This should not happen unless the request from NanoUI was bad
if(!(R.category & categories))
return
//Specific soft access checking
var/datum/nifsoft/path = R.item_path
if(initial(path.access))
var/list/soft_access = list(initial(path.access))
var/list/usr_access = usr.GetAccess()
if(!has_access(soft_access, list(), usr_access) && !emagged)
usr << "<span class='warning'>You aren't authorized to buy [initial(path.name)].</span>"
flick(icon_deny,src)
return
if(R.price <= 0)
vend(R, usr)
else if(istype(usr,/mob/living/silicon)) //If the item is not free, provide feedback if a synth is trying to buy something.
usr << "<span class='danger'>Artificial unit recognized. Artificial units cannot complete this transaction. Purchase canceled.</span>"
return
else
currently_vending = R
if(!vendor_account || vendor_account.suspended)
status_message = "This machine is currently unable to process payments due to problems with the associated account."
status_error = 1
else
status_message = "[initial(path.desc)]<br><br><b>Please swipe a card or insert cash to pay for the item.</b>"
status_error = 0
else if(href_list["cancelpurchase"])
currently_vending = null
else if((href_list["togglevoice"]) && (panel_open))
shut_up = !shut_up
add_fingerprint(usr)
nanomanager.update_uis(src)
// Also special treatment!
/obj/machinery/vending/nifsoft_shop/vend(datum/stored_item/vending_product/R, mob/user)
var/mob/living/carbon/human/H = user
if((!allowed(usr)) && !emagged && scan_id && istype(H)) //For SECURE VENDING MACHINES YEAH
usr << "<span class='warning'>Purchase not allowed.</span>" //Unless emagged of course
flick(icon_deny,src)
return
vend_ready = 0 //One thing at a time!!
status_message = "Installing..."
status_error = 0
nanomanager.update_uis(src)
if(R.category & CAT_COIN)
if(!coin)
user << "<span class='notice'>You need to insert a coin to get this item.</span>"
return
if(coin.string_attached)
if(prob(50))
user << "<span class='notice'>You successfully pull the coin out before \the [src] could swallow it.</span>"
else
user << "<span class='notice'>You weren't able to pull the coin out fast enough, the machine ate it, string and all.</span>"
qdel(coin)
coin = null
categories &= ~CAT_COIN
else
qdel(coin)
coin = null
categories &= ~CAT_COIN
if(((last_reply + (vend_delay + 200)) <= world.time) && vend_reply)
spawn(0)
speak(vend_reply)
last_reply = world.time
use_power(vend_power_usage) //actuators and stuff
spawn(vend_delay)
R.amount--
new R.item_path(H.nif)
flick(icon_vend,src)
if(has_logs)
do_logging(R, user, 1)
status_message = ""
status_error = 0
vend_ready = 1
currently_vending = null
nanomanager.update_uis(src)
return 1
+74
View File
@@ -0,0 +1,74 @@
/mob/living/carbon/human/Stat()
. = ..()
if(nif && statpanel("NIF"))
SetupNifStat()
/mob/living/carbon/human/proc/SetupNifStat()
var/nif_status = ""
switch(nif.stat)
if(NIF_WORKING)
nif_status = "Operating Normally"
if(NIF_POWFAIL)
nif_status = "Insufficient Energy!"
if(NIF_TEMPFAIL)
nif_status = "Needs Maintenance!"
if(NIF_INSTALLING)
nif_status = "Adapting To User"
else
nif_status = "Unknown - Error"
nif_status += " ([round((nif.durability/initial(nif.durability))*100)]%)"
stat("NIF Status", nif_status)
if(nif.stat == NIF_WORKING)
stat("- Modules -", "LMB: Toggle, Shift+LMB: Info/Uninstall")
for(var/nifsoft in nif.nifsofts)
if(!nifsoft) continue
var/datum/nifsoft/NS = nifsoft
var/obj/effect/nif_stat/stat_line = NS.stat_line
stat("[stat_line.nifsoft_name]",stat_line.atom_button_text())
///////////////////
// Stat Line Object
/obj/effect/nif_stat
name = ""
var/nifsoft_name //Prevents deeper lookups, and the name won't change
var/datum/nifsoft/nifsoft //Reference to our nifsoft
var/toggleable = FALSE //Won't change, prevents looking it up deeper
/obj/effect/nif_stat/New(var/datum/nifsoft/new_soft)
..()
nifsoft = new_soft
nifsoft_name = new_soft.name
name = new_soft.name
/obj/effect/nif_stat/Destroy()
nifsoft = null
..()
/obj/effect/nif_stat/proc/atom_button_text()
name = nifsoft.stat_text()
return src
/obj/effect/nif_stat/Click(var/location, var/control, var/params)
if(usr != nifsoft.nif.human) return
var/list/clickprops = params2list(params)
var/opts = clickprops["shift"]
if(opts)
var/choice = alert("Select an option","[nifsoft_name]","Display Info","Cancel","Uninstall")
switch(choice)
if("Display Info")
nifsoft.nif.notify("[nifsoft_name]: [nifsoft.desc] - It consumes [nifsoft.p_drain] energy units \
while installed, and [nifsoft.a_drain] additionally while active. It is [nifsoft.illegal ? "NOT " : ""]\
a legal software package. The MSRP of the package is [nifsoft.cost] Thalers. The difficulty to construct \
the associated implant is Rating [nifsoft.wear].")
if("Uninstall")
var/confirm = alert("Really uninstall [nifsoft_name]?","Are you sure?","Cancel","Uninstall","Cancel")
if(confirm == "Uninstall")
nifsoft.uninstall()
else if(nifsoft.activates)
if(nifsoft.active)
nifsoft.deactivate()
else
nifsoft.activate()
+185
View File
@@ -0,0 +1,185 @@
//A single piece of NIF software
/datum/nifsoft
var/name = "Prototype"
var/desc = "Contact a dev!"
var/obj/item/device/nif/nif //The NIF that the software is stored in
var/list_pos // List position in the nifsoft list
var/cost = 1000 // Cost in cash of buying this software from a terminal
var/vended = TRUE // This is available in NIFSoft Shops at the start of the game
var/wear = 1 // The wear (+/- 10% when applied) that this causes to the NIF
var/access // What access they need to buy it, can only set one for ~reasons~
var/illegal = FALSE // If this is a black-market nifsoft (emag option)
var/active = FALSE // Whether the active mode of this implant is on
var/p_drain = 0 // Passive power drain, can be used in various ways from the software
var/a_drain = 0 // Active power drain, same purpose as above, software can treat however
var/activates = TRUE // Whether or not this has an active power consumption mode
var/tick_flags = 0 // Flags to tell when we'd like to be ticked
var/empable = TRUE // If the implant can be destroyed via EMP attack
var/expiring = FALSE // Trial software! Or self-deleting illegal ones!
var/expires_at // World.time for when they expire
var/applies_to = (NIF_ORGANIC|NIF_SYNTHETIC) // Who this software is useful for
var/vision_flags = 0 // Various flags for fast lookups that are settable on the NIF
var/health_flags = 0 // These are added as soon as the implant is installed
var/combat_flags = 0 // Otherwise use set_flag on the nif in your activate/deactivate
var/other_flags = 0
var/obj/effect/nif_stat/stat_line
//Constructor accepts the NIF it's being loaded into
/datum/nifsoft/New(var/obj/item/device/nif/nif_load)
ASSERT(nif_load)
nif = nif_load
stat_line = new(src)
if(!install(nif))
qdel(src)
//Destructor cleans up the software and nif reference
/datum/nifsoft/Destroy()
if(nif)
uninstall(nif)
nif = null
qdel(stat_line)
stat_line = null
..()
//Called when the software is installed in the NIF
/datum/nifsoft/proc/install()
return nif.install(src)
//Called when the software is removed from the NIF
/datum/nifsoft/proc/uninstall()
if(active)
deactivate()
if(nif)
. = nif.uninstall(src)
nif = null
qdel(src)
//Called every life() tick on a mob on active implants
/datum/nifsoft/proc/life(var/mob/living/carbon/human/human)
return TRUE
//Called when attempting to activate an implant (could be a 'pulse' activation or toggling it on)
/datum/nifsoft/proc/activate()
if(active)
return
var/nif_result = nif.activate(src)
if(nif_result)
active = TRUE
return nif_result
//Called when attempting to deactivate an implant
/datum/nifsoft/proc/deactivate()
if(!active)
return
var/nif_result = nif.deactivate(src)
if(nif_result)
active = FALSE
return nif_result
//Called when an implant expires
/datum/nifsoft/proc/expire()
uninstall()
return
//Called when installed from a disk
/datum/nifsoft/proc/disk_install(var/mob/living/carbon/human/target,var/mob/living/carbon/human/user)
return TRUE
//Stat-line clickable text
/datum/nifsoft/proc/stat_text()
if(activates)
return "[active ? "Active" : "Disabled"]"
return "Always On"
//////////////////////
//A package of NIF software
/datum/nifsoft/package
var/list/software = list()
wear = 0 //Packages don't cause wear themselves, the software does
//Constructor accepts a NIF and loads all the software
/datum/nifsoft/package/New(var/obj/item/device/nif/nif_load)
ASSERT(nif_load)
for(var/P in software)
new P(nif_load)
qdel(src)
//Clean self up
/datum/nifsoft/package/Destroy()
software.Cut()
software = null
..()
/////////////////
// A NIFSoft Disk
/obj/item/weapon/disk/nifsoft
name = "NIFSoft Disk"
desc = "It has a small label: \n\
\"Portable NIFSoft Disk. \n\
Insert directly into brain.\""
icon = 'icons/obj/cloning.dmi'
icon_state = "datadisk2"
item_state = "card-id"
w_class = ITEMSIZE_SMALL
var/datum/nifsoft/stored = null
var/laws = ""
/obj/item/weapon/disk/nifsoft/afterattack(var/A, mob/user, flag, params)
if(!in_range(user, A))
return
if(!ishuman(user) || !ishuman(A))
return
var/mob/living/carbon/human/Ht = A
var/mob/living/carbon/human/Hu = user
if(!Ht.nif || Ht.nif.stat != NIF_WORKING)
to_chat(user,"<span class='warning'>Either they don't have a NIF, or the disk can't connect.</span>")
return
Ht.visible_message("<span class='warning'>[Hu] begins uploading new NIFSoft into [Ht]!</span>","<span class='danger'>[Hu] is uploading new NIFSoft into you!</span>")
if(do_after(Hu,10 SECONDS,Ht))
var/extra = extra_params()
new stored(Ht.nif,extra)
qdel(src)
//So disks can pass fancier stuff.
/obj/item/weapon/disk/nifsoft/proc/extra_params()
return null
/obj/item/weapon/disk/nifsoft/compliance
name = "NIFSoft Disk (Compliance)"
desc = "Wow, adding laws to people? That seems illegal. It probably is. Okay, it really is."
stored = /datum/nifsoft/compliance
/obj/item/weapon/disk/nifsoft/compliance/afterattack(var/A, mob/user, flag, params)
if(!laws)
to_chat(user,"<span class='warning'>You haven't set any laws yet. Use the disk in-hand first.</span>")
return
..(A,user,flag,params)
/obj/item/weapon/disk/nifsoft/compliance/attack_self(mob/user)
var/newlaws = input(user,"Please Input Laws","Compliance Laws",laws) as message
newlaws = sanitize(newlaws,2048)
if(newlaws)
to_chat(user,"You set the laws to: <br><span class='notice'>[newlaws]</span>")
laws = newlaws
/obj/item/weapon/disk/nifsoft/compliance/extra_params()
return laws
+249
View File
@@ -0,0 +1,249 @@
//////////////////
// AR HUD Overlays
/datum/nifsoft/ar_civ
name = "AR Overlay (Civ)"
desc = "Provides a general identification and health status overlay on your vision with no frills."
list_pos = NIF_CIVILIAN_AR
cost = 500
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_MEDICAL_AR,NIF_SECURITY_AR,NIF_ENGINE_AR,NIF_SCIENCE_AR,NIF_OMNI_AR)
nif.set_flag(NIF_V_AR_CIVILIAN,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_CIVILIAN,NIF_FLAGS_VISION)
/datum/nifsoft/ar_med
name = "AR Overlay (Med)"
desc = "Like the civilian model, but provides medical records access and virus database lookup."
list_pos = NIF_MEDICAL_AR
cost = 750
access = access_medical
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_CIVILIAN_AR,NIF_SECURITY_AR,NIF_ENGINE_AR,NIF_SCIENCE_AR,NIF_OMNI_AR)
nif.set_flag(NIF_V_AR_MEDICAL,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_MEDICAL,NIF_FLAGS_VISION)
/datum/nifsoft/ar_sec
name = "AR Overlay (Sec)"
desc = "Like the civilian model, but provides access to arrest status and security records."
list_pos = NIF_SECURITY_AR
cost = 750
access = access_security
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_CIVILIAN_AR,NIF_MEDICAL_AR,NIF_ENGINE_AR,NIF_SCIENCE_AR,NIF_OMNI_AR)
nif.set_flag(NIF_V_AR_SECURITY,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_SECURITY,NIF_FLAGS_VISION)
/datum/nifsoft/ar_eng
name = "AR Overlay (Eng)"
desc = "Like the civilian model, but provides station alert notices."
list_pos = NIF_ENGINE_AR
cost = 750
access = access_engine
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_CIVILIAN_AR,NIF_MEDICAL_AR,NIF_SECURITY_AR,NIF_SCIENCE_AR,NIF_OMNI_AR)
nif.set_flag(NIF_V_AR_ENGINE,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_ENGINE,NIF_FLAGS_VISION)
/datum/nifsoft/ar_science
name = "AR Overlay (Sci)"
desc = "Like the civilian model, but provides ... well, nothing. For now."
list_pos = NIF_SCIENCE_AR
cost = 750
access = access_research
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_CIVILIAN_AR,NIF_MEDICAL_AR,NIF_SECURITY_AR,NIF_ENGINE_AR,NIF_OMNI_AR)
nif.set_flag(NIF_V_AR_SCIENCE,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_SCIENCE,NIF_FLAGS_VISION)
/datum/nifsoft/ar_omni
name = "AR Overlay (Omni)"
desc = "Like the civilian model, but provides most of the features of the medical and security overlays as well."
list_pos = NIF_OMNI_AR
cost = 750
access = access_captain
a_drain = 0.05
activate()
if((. = ..()))
nif.deactivate_these(NIF_CIVILIAN_AR,NIF_MEDICAL_AR,NIF_SECURITY_AR,NIF_ENGINE_AR,NIF_SCIENCE_AR)
nif.set_flag(NIF_V_AR_OMNI,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_AR_OMNI,NIF_FLAGS_VISION)
//////////////
// Misc Vision
/datum/nifsoft/corrective
name = "Corrective AR"
desc = "Subtly alters perception to compensate for cataracts and retinal misalignment, among other common disabilities."
list_pos = NIF_CORRECTIVE_GLASS
cost = 200
a_drain = 0.025
activate()
if((. = ..()))
nif.set_flag(NIF_V_CORRECTIVE,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_CORRECTIVE,NIF_FLAGS_VISION)
/datum/nifsoft/uvblocker
name = "Nictating Membrane"
desc = "A synthetic nictating membrane (aka 'third eyelid') that protects the eyes from UV or hostile atmospheres. Does not protect from photonic stun weapons."
list_pos = NIF_UVFILTER
cost = 450
a_drain = 0.2
activate()
if((. = ..()))
nif.set_flag(NIF_V_UVFILTER,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_UVFILTER,NIF_FLAGS_VISION)
/datum/nifsoft/flashprot
name = "Responsive Filter"
desc = "Enables a high-speed shielding response to intense light, such as flashes, to block them."
list_pos = NIF_FLASHPROT
cost = 600
access = access_security
a_drain = 0.05
activate()
if((. = ..()))
nif.set_flag(NIF_V_FLASHPROT,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_FLASHPROT,NIF_FLAGS_VISION)
////////////////
// Goggle-alikes
/datum/nifsoft/mesons
name = "Meson Scanner"
desc = "Similar to the worn Optical Meson Scanner Goggles, these allow you to see the base structure and terrain through walls."
list_pos = NIF_MESONS
cost = 1000
a_drain = 0.1
access = access_engine
tick_flags = NIF_ACTIVETICK
activate()
if((. = ..()))
nif.deactivate_these(NIF_MATERIAL,NIF_THERMALS,NIF_NIGHTVIS)
nif.set_flag(NIF_V_MESONS,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_MESONS,NIF_FLAGS_VISION)
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
H.client.screen |= global_hud.meson
H.sight |= SEE_TURFS
/datum/nifsoft/material
name = "Material Scanner"
desc = "Similar to the worn Optical Material Scanner Goggles, these allow you to see objects through walls."
list_pos = NIF_MATERIAL
cost = 1000
a_drain = 0.1
access = access_research
tick_flags = NIF_ACTIVETICK
activate()
if((. = ..()))
nif.deactivate_these(NIF_MESONS,NIF_THERMALS,NIF_NIGHTVIS)
nif.set_flag(NIF_V_MATERIAL,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_MATERIAL,NIF_FLAGS_VISION)
life()
if((. = ..()))
nif.human.sight |= SEE_OBJS
/datum/nifsoft/thermals
name = "Thermal Scanner"
desc = "Similar to the worn Thermal Goggles, these allow you to see heat-emitting creatures through walls."
list_pos = NIF_THERMALS
cost = 1000
a_drain = 0.1
access = access_captain
tick_flags = NIF_ACTIVETICK
activate()
if((. = ..()))
nif.deactivate_these(NIF_MESONS,NIF_MATERIAL,NIF_NIGHTVIS)
nif.set_flag(NIF_V_THERMALS,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_THERMALS,NIF_FLAGS_VISION)
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
H.sight |= SEE_MOBS
H.client.screen |= global_hud.thermal
H.see_invisible = SEE_INVISIBLE_NOLIGHTING
/datum/nifsoft/nightvis
name = "Low-Light Amp"
desc = "Similar to the worn Night Vision Goggles, these allow you to see in complete darkness."
list_pos = NIF_NIGHTVIS
cost = 1000
a_drain = 0.1
access = access_security
tick_flags = NIF_ACTIVETICK
activate()
if((. = ..()))
nif.deactivate_these(NIF_MESONS,NIF_MATERIAL,NIF_THERMALS)
nif.set_flag(NIF_V_NIGHTVIS,NIF_FLAGS_VISION)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_V_NIGHTVIS,NIF_FLAGS_VISION)
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
H.see_in_dark += 7
H.client.screen |= global_hud.nvg
H.see_invisible = SEE_INVISIBLE_NOLIGHTING
+212
View File
@@ -0,0 +1,212 @@
/datum/nifsoft/crewmonitor
name = "Crew Monitor"
desc = "A link to the local crew monitor sensors. Useful for finding people in trouble."
list_pos = NIF_CREWMONITOR
access = access_medical
cost = 1250
p_drain = 0.025
var/datum/nano_module/crew_monitor/arscreen
New()
..()
arscreen = new(nif)
Destroy()
qdel(arscreen)
..()
activate()
if((. = ..()))
arscreen.ui_interact(nif.human,"main",null,1,nif_state)
return TRUE
deactivate()
if((. = ..()))
return TRUE
stat_text()
return "Show Monitor"
/datum/nifsoft/medichines_org
name = "Medichines"
desc = "An internal swarm of nanites to make sure you stay in good shape and to promote healing, or to preserve you if you are critically injured."
list_pos = NIF_ORGANIC_HEAL
cost = 2500
p_drain = 0.05
a_drain = 0.1 //This is messed with manually below.
wear = 2
activates = FALSE //It is automatic in emergencies, not manually controllable.
tick_flags = NIF_ALWAYSTICK
applies_to = NIF_ORGANIC
var/mode = 0
//These self-activate on their own, these aren't user-settable to on/off.
activate()
if((. = ..()))
nif.set_flag(NIF_H_ORGREPAIR,NIF_FLAGS_HEALTH)
mode = 1
deactivate()
if((. = ..()))
nif.clear_flag(NIF_H_ORGREPAIR,NIF_FLAGS_HEALTH)
a_drain = initial(a_drain)
mode = initial(mode)
nif.human.Stasis(0)
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
var/HP_percent = H.health/H.getMaxHealth()
//Mode changing state machine
if(HP_percent >= 0.9)
if(mode)
nif.notify("User Status: NORMAL. Medichines deactivating.")
deactivate()
return TRUE
else if(!mode && HP_percent < 0.8)
nif.notify("User Status: INJURED. Commencing medichine routines.",TRUE)
activate()
else if(mode == 1 && HP_percent < 0.2)
nif.notify("User Status: DANGER. Seek medical attention!",TRUE)
mode = 2
else if(mode == 2 && HP_percent < -0.4)
nif.notify("User Status: CRITICAL. Notifying medical, and starting emergency stasis!",TRUE)
mode = 3
if(!ishuman(H.loc)) //Not notified in case of vore, for gameplay purposes.
var/turf/T = get_turf(H)
var/obj/item/device/radio/headset/a = new /obj/item/device/radio/headset/heads/captain(null)
a.autosay("[H.real_name] has been put in emergency stasis, located at ([T.x],[T.y],[T.z])!", "[H.real_name]'s NIF", "Medical")
qdel(a)
//Handle the actions in each mode
//Injured but not critical
if(mode)
H.adjustToxLoss(-0.1 * mode)
H.adjustBruteLoss(-0.1 * mode)
H.adjustFireLoss(-0.1 * mode)
if(mode >= 2)
nif.use_charge(a_drain) //A second drain if we're in level 2+
//Patient critical - emergency stasis
if(mode >= 3)
if(HP_percent <= 0)
H.Stasis(3)
if(HP_percent > 0.2)
H.Stasis(0)
nif.notify("Ending emergency stasis.",TRUE)
mode = 2
return TRUE
/datum/nifsoft/medichines_syn
name = "Medichines"
desc = "A swarm of mechanical repair nanites, able to repair relatively minor damage to synthetic bodies. Large repairs must still be performed manually."
list_pos = NIF_SYNTH_HEAL
cost = 2500
p_drain = 0.05
a_drain = 0.00 //This is manually drained below.
wear = 2
activates = FALSE //It is automatic in emergencies, not manually controllable.
tick_flags = NIF_ALWAYSTICK
applies_to = NIF_SYNTHETIC
var/mode = 0
//These self-activate on their own, these aren't user-settable to on/off.
activate()
if((. = ..()))
nif.set_flag(NIF_H_SYNTHREPAIR,NIF_FLAGS_HEALTH)
mode = 1
deactivate()
if((. = ..()))
nif.clear_flag(NIF_H_SYNTHREPAIR,NIF_FLAGS_HEALTH)
mode = 0
life()
if((. = ..()))
//We're good!
if(!nif.human.bad_external_organs.len)
if(mode || active)
nif.notify("User Status: NORMAL. Medichines deactivating.")
deactivate()
return TRUE
if(!mode && !active)
nif.notify("User Status: DAMAGED. Medichines performing minor repairs.",TRUE)
activate()
for(var/eo in nif.human.bad_external_organs)
var/obj/item/organ/external/EO = eo
for(var/w in EO.wounds)
var/datum/wound/W = w
if(W.damage <= 5)
W.heal_damage(0.1)
EO.update_damages()
if(EO.update_icon())
nif.human.UpdateDamageIcon(1)
nif.use_charge(0.1)
return TRUE //Return entirely, we only heal one at a time.
else if(mode == 1)
mode = 2
nif.notify("Medichines unable to repair all damage. Perform manual repairs.",TRUE)
return TRUE
/datum/nifsoft/spare_breath
name = "Respirocytes"
desc = "Nanites simulating red blood cells will filter and recycle oxygen for a short time, preventing suffocation in hostile environments. NOTE: Only capable of supplying OXYGEN."
list_pos = NIF_SPAREBREATH
cost = 650
p_drain = 0.05
a_drain = 0.1
wear = 2
tick_flags = NIF_ALWAYSTICK
applies_to = NIF_ORGANIC
var/filled = 100 //Tracks the internal tank 'refilling', which still uses power
activate()
if(!(filled > 50))
nif.notify("Respirocytes not saturated!",TRUE)
return FALSE
if((. = ..()))
nif.set_flag(NIF_H_SPAREBREATH,NIF_FLAGS_HEALTH)
nif.notify("Now taking air from reserves.")
deactivate()
if((. = ..()))
nif.clear_flag(NIF_H_SPAREBREATH,NIF_FLAGS_HEALTH)
nif.notify("Now taking air from environment and refilling reserves.")
life()
if((. = ..()))
if(active) //Supplying air, not recharging it
switch(filled) //Text warnings
if(75)
nif.notify("Respirocytes at 75% saturation.",TRUE)
if(50)
nif.notify("Respirocytes at 50% saturation!",TRUE)
if(25)
nif.notify("Respirocytes at 25% saturation, seek a habitable environment!",TRUE)
if(5)
nif.notify("Respirocytes at 5% saturation! Failure imminent!",TRUE)
if(filled == 0) //Ran out
deactivate()
else //Drain a little
filled--
else //Recharging air, not supplying it
if(filled == 100)
return TRUE
else if(nif.use_charge(0.1) && ++filled == 100)
nif.notify("Respirocytes now fully saturated.")
proc/resp_breath()
if(!active) return null
var/datum/gas_mixture/breath = new()
breath.adjust_gas("oxygen", 300)
breath.temperature = T20C
return breath
+136
View File
@@ -0,0 +1,136 @@
/datum/nifsoft/brute_armor
name = "Bullhide Mod"
desc = "A difficult-to-produce thickening of the dermis and skeletal structure, allowing a user to absorb more external trauma from physical sources."
list_pos = NIF_BRUTEARMOR
cost = 3200
p_drain = 0.05
illegal = TRUE
wear = 3
access = 999 //Prevents anyone from buying it without an emag.
activates = FALSE //It's armor.
install()
if((. = ..()))
nif.set_flag(NIF_C_BRUTEARMOR,NIF_FLAGS_COMBAT)
uninstall()
. = ..()
nif.clear_flag(NIF_C_BRUTEARMOR,NIF_FLAGS_COMBAT)
/datum/nifsoft/burn_armor
name = "Dragon's Skin"
desc = "A thin layer of material under the skin provides heat disappation for burns, reducing the trauma from lasers and fire. Not effective against ongoing environmental heat."
list_pos = NIF_BURNARMOR
cost = 3200
p_drain = 0.05
illegal = TRUE
wear = 3
access = 999 //Prevents anyone from buying it without an emag.
activates = FALSE //It's armor.
install()
if((. = ..()))
nif.set_flag(NIF_C_BURNARMOR,NIF_FLAGS_COMBAT)
uninstall()
. = ..()
nif.clear_flag(NIF_C_BURNARMOR,NIF_FLAGS_COMBAT)
/datum/nifsoft/painkillers
name = "Nova Shock"
desc = "A constant stream of high-grade painkillers numb the user's body to all pain. Generally results in extreme addiction or overdose."
list_pos = NIF_PAINKILLERS
cost = 2600
a_drain = 1 //Gotta produce them drugs, yo.
illegal = TRUE
wear = 2
access = 999 //Prevents anyone from buying it without an emag.
tick_flags = NIF_ACTIVETICK
activate()
if((. = ..()))
nif.set_flag(NIF_C_PAINKILLERS,NIF_FLAGS_COMBAT)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_C_PAINKILLERS,NIF_FLAGS_COMBAT)
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
H.bloodstr.add_reagent("numbenzyme",0.5)
/datum/nifsoft/hardclaws
name = "Bloodletters"
desc = "Generates monofilament wires from one's fingertips, allowing one to slash through almost any armor with relative ease. The monofilaments need to be replaced constantly, though, which does use power."
list_pos = NIF_HARDCLAWS
cost = 2200
a_drain = 0.5
illegal = TRUE
wear = 4
access = 999 //Prevents anyone from buying it without an emag.
activate()
if((. = ..()))
nif.set_flag(NIF_C_HARDCLAWS,NIF_FLAGS_COMBAT)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_C_HARDCLAWS,NIF_FLAGS_COMBAT)
// The unarmed attack to go with the hardclaws
var/global/datum/unarmed_attack/hardclaws/unarmed_hardclaws = new()
/datum/unarmed_attack/hardclaws
attack_verb = list("claws")
attack_noun = list("talons")
damage = 15
attack_sound = "punch"
miss_sound = 'sound/weapons/punchmiss.ogg'
sharp = 1
edge = 1
sparring_variant_type = /datum/unarmed_attack/hardclaws
/datum/nifsoft/hidelaser
name = "Dazzle"
desc = "Fabricates a 2-shot holdout laser inside your body, which can be deployed (somewhat painfully) on demand. Only enough materials to generate one."
list_pos = NIF_HIDDENLASER
cost = 2200
//a_drain = 50 //Done manually below.
illegal = TRUE
wear = 6
access = 999 //Prevents anyone from buying it without an emag.
var/used = FALSE
activate()
if((. = ..()))
nif.set_flag(NIF_C_HIDELASER,NIF_FLAGS_COMBAT)
if(used)
nif.notify("You do not have a hidden weapon to deploy anymore!",TRUE)
deactivate()
return FALSE
if(!nif.use_charge(50))
nif.notify("Insufficient energy to deploy weapon!",TRUE)
deactivate()
return FALSE
var/mob/living/carbon/human/H = nif.human
H.adjustHalLoss(30)
var/obj/item/weapon/gun/energy/gun/martin/dazzle/dgun = new(get_turf(H))
H.put_in_hands(dgun)
nif.notify("Weapon deployed!",TRUE)
used = TRUE
spawn(0)
uninstall()
deactivate()
if((. = ..()))
nif.clear_flag(NIF_C_HIDELASER,NIF_FLAGS_COMBAT)
//The gun to go with this implant
/obj/item/weapon/gun/energy/gun/martin/dazzle
name = "Microlaser"
desc = "A tiny nanofabricated laser."
icon = 'icons/obj/gun_vr.dmi'
icon_state = "PDW"
item_state = "gun"
@@ -0,0 +1,132 @@
///////////
// Commlink - Has a bunch of extra stuff due to communicator defines.
/datum/nifsoft/commlink
name = "Commlink"
desc = "An internal communicator for keeping in touch with people."
list_pos = NIF_COMMLINK
cost = 500
wear = 0
p_drain = 0.01
install()
if((. = ..()))
nif.comm = new(nif,src)
activate()
if((. = ..()))
nif.set_flag(NIF_O_COMMLINK,NIF_FLAGS_OTHER)
nif.comm.initialize_exonet(nif.human)
nif.comm.ui_interact(nif.human,key_state = commlink_state)
spawn(0)
deactivate()
deactivate()
if((. = ..()))
nif.clear_flag(NIF_O_COMMLINK,NIF_FLAGS_OTHER)
stat_text()
return "Show Commlink"
/datum/nifsoft/commlink/Topic(href, href_list)
if(href_list["open"])
activate()
/obj/item/device/communicator/commlink
name = "commlink"
desc = "An internal communicator, basically."
occupation = "\[Commlink\]"
var/obj/item/device/nif/nif
var/datum/nifsoft/commlink/nifsoft
New(var/newloc,var/soft)
..()
nif = newloc
nifsoft = soft
register_device(nif.human)
qdel(camera) //Not supported on internal one.
Destroy()
if(nif)
nif.comm = null
nif = null
..()
//So that only the owner's chat is relayed to others.
/obj/item/device/communicator/commlink/hear_talk(mob/living/M, text, verb, datum/language/speaking)
if(M != nif.human) return
for(var/obj/item/device/communicator/comm in communicating)
var/turf/T = get_turf(comm)
if(!T) return
var/icon_object = src
var/list/mobs_to_relay
if(istype(comm,/obj/item/device/communicator/commlink))
var/obj/item/device/communicator/commlink/CL = comm
mobs_to_relay = list(CL.nif.human)
icon_object = CL.nif.big_icon
else
var/list/in_range = get_mobs_and_objs_in_view_fast(T,world.view,0)
mobs_to_relay = in_range["mobs"]
for(var/mob/mob in mobs_to_relay)
//Can whoever is hearing us understand?
if(!mob.say_understands(M, speaking))
if(speaking)
text = speaking.scramble(text)
else
text = stars(text)
var/name_used = M.GetVoice()
var/rendered = null
if(speaking) //Language being used
rendered = "<span class='game say'>\icon[icon_object] <span class='name'>[name_used]</span> [speaking.format_message(text, verb)]</span>"
else
rendered = "<span class='game say'>\icon[icon_object] <span class='name'>[name_used]</span> [verb], <span class='message'>\"[text]\"</span></span>"
mob.show_message(rendered, 2)
//Not supported by the internal one
/obj/item/device/communicator/commlink/show_message(msg, type, alt, alt_type)
return
//The silent treatment
/obj/item/device/communicator/commlink/request(var/atom/candidate)
if(candidate in voice_requests)
return
var/who = null
if(isobserver(candidate))
who = candidate.name
else if(istype(candidate, /obj/item/device/communicator))
var/obj/item/device/communicator/comm = candidate
who = comm.owner
comm.voice_invites |= src
if(!who)
return
voice_requests |= candidate
if(ringer && nif.human)
nif.notify("New commlink call from [who]. (<a href='?src=\ref[nifsoft];open=1'>Open</a>)")
//Similar reason
/obj/item/device/communicator/commlink/request_im(var/atom/candidate, var/origin_address, var/text)
var/who = null
if(isobserver(candidate))
var/mob/observer/dead/ghost = candidate
who = ghost
im_list += list(list("address" = origin_address, "to_address" = exonet.address, "im" = text))
else if(istype(candidate, /obj/item/device/communicator))
var/obj/item/device/communicator/comm = candidate
who = comm.owner
comm.im_contacts |= src
im_list += list(list("address" = origin_address, "to_address" = exonet.address, "im" = text))
else return
im_contacts |= candidate
if(!who)
return
if(ringer && nif.human)
nif.notify("Commlink message from [who]: \"[text]\" (<a href='?src=\ref[nifsoft];open=1'>Open</a>)")
+182
View File
@@ -0,0 +1,182 @@
/datum/nifsoft/apc_recharge
name = "APC Connector"
desc = "A small attachment that allows synthmorphs to recharge themselves from APCs."
list_pos = NIF_APCCHARGE
cost = 1250
wear = 2
applies_to = NIF_SYNTHETIC
tick_flags = NIF_ACTIVETICK
var/obj/machinery/power/apc/apc
activate()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
nif.set_flag(NIF_O_APCCHARGE,NIF_FLAGS_OTHER)
apc = locate(/obj/machinery/power/apc) in get_step(H,H.dir)
if(!apc)
apc = locate(/obj/machinery/power/apc) in get_step(H,0)
if(!apc)
nif.notify("You must be facing an APC to connect to.",TRUE)
spawn(0)
deactivate()
return FALSE
H.visible_message("<span class='warning'>Thin snakelike tendrils grow from [H] and connect to \the [apc].</span>","<span class='notice'>Thin snakelike tendrils grow from you and connect to \the [apc].</span>")
deactivate()
if((. = ..()))
nif.clear_flag(NIF_O_APCCHARGE,NIF_FLAGS_OTHER)
apc = null
life()
if((. = ..()))
var/mob/living/carbon/human/H = nif.human
if(apc && (get_dist(H,apc) <= 1) && H.nutrition < 450)
H.nutrition = min(H.nutrition+10, 450)
apc.drain_power(7000/450*10) //This is from the large rechargers. No idea what the math is.
return TRUE
else
nif.notify("APC charging has ended.")
H.visible_message("<span class='warning'>[H]'s snakelike tendrils whip back into their body from \the [apc].</span>","<span class='notice'>The APC connector tendrils return to your body.</span>")
deactivate()
return FALSE
/datum/nifsoft/pressure
name = "Pressure Seals"
desc = "Creates pressure seals around important synthetic components to protect them from vacuum. Almost impossible on organics."
list_pos = NIF_PRESSURE
cost = 1750
a_drain = 0.5
wear = 3
applies_to = NIF_SYNTHETIC
activate()
if((. = ..()))
nif.set_flag(NIF_O_PRESSURESEAL,NIF_FLAGS_OTHER)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_O_PRESSURESEAL,NIF_FLAGS_OTHER)
/datum/nifsoft/heatsinks
name = "Heat Sinks"
desc = "Advanced heat sinks for internal heat storage of heat on a synth until able to vent it in atmosphere."
list_pos = NIF_HEATSINK
cost = 1450
a_drain = 0.25
wear = 3
var/used = 0
tick_flags = NIF_ALWAYSTICK
applies_to = NIF_SYNTHETIC
activate()
if((. = ..()))
if(used >= 50)
nif.notify("Heat sinks not safe to operate again yet!",TRUE)
spawn(0)
deactivate()
return FALSE
nif.set_flag(NIF_O_HEATSINKS,NIF_FLAGS_OTHER)
deactivate()
if((. = ..()))
nif.clear_flag(NIF_O_HEATSINKS,NIF_FLAGS_OTHER)
life()
if((. = ..()))
//Not being used, all clean.
if(!active && !used)
return TRUE
//Being used, and running out.
else if(active && ++used == 100)
nif.notify("Heat sinks overloaded! Shutting down!",TRUE)
deactivate()
//Being cleaned, and finishing empty.
else if(!active && --used == 0)
nif.notify("Heat sinks re-chilled.")
/datum/nifsoft/compliance
name = "Compliance Module"
desc = "A system that allows one to apply 'laws' to sapient life. Extremely illegal, of course."
list_pos = NIF_COMPLIANCE
cost = 8200
wear = 4
illegal = TRUE
vended = FALSE
access = 999 //Prevents anyone from buying it without an emag.
var/laws = "Be nice to people!"
New(var/newloc,var/newlaws)
laws = newlaws //Sanitize before this (the disk does)
..(newloc)
activate()
if((. = ..()))
to_chat(nif.human,"<span class='danger'>You are compelled to follow these rules: </span>\n<span class='notify'>[laws]</span>")
install()
if((. = ..()))
to_chat(nif.human,"<span class='danger'>You feel suddenly compelled to follow these rules: </span>\n<span class='notify'>[laws]</span>")
uninstall()
nif.notify("ERROR! Unable to comply!",TRUE)
return FALSE //NOPE.
stat_text()
return "Show Laws"
/datum/nifsoft/sizechange
name = "Mass Alteration"
desc = "A system that allows one to change their size, through drastic mass rearrangement. Causes significant wear when installed."
list_pos = NIF_SIZECHANGE
cost = 750
wear = 6
activate()
if((. = ..()))
var/choice = alert(nif.human,"Change which way?","Mass Alteration","Size Up","Cancel", "Size Down")
if(choice == "Cancel")
spawn(0) deactivate()
return FALSE
if(!nif.use_charge(100))
nif.notify("Insufficient energy to resize!",TRUE)
spawn(0) deactivate()
return FALSE
if(choice == "Size Up")
switch(nif.human.size_multiplier)
if(RESIZE_BIG to RESIZE_HUGE)
nif.human.resize(RESIZE_HUGE)
if(RESIZE_NORMAL to RESIZE_BIG)
nif.human.resize(RESIZE_BIG)
if(RESIZE_SMALL to RESIZE_NORMAL)
nif.human.resize(RESIZE_NORMAL)
if((0 - INFINITY) to RESIZE_TINY)
nif.human.resize(RESIZE_SMALL)
else if(choice == "Size Down")
switch(nif.human.size_multiplier)
if(RESIZE_HUGE to INFINITY)
nif.human.resize(RESIZE_BIG)
if(RESIZE_BIG to RESIZE_HUGE)
nif.human.resize(RESIZE_NORMAL)
if(RESIZE_NORMAL to RESIZE_BIG)
nif.human.resize(RESIZE_SMALL)
if((0 - INFINITY) to RESIZE_NORMAL)
nif.human.resize(RESIZE_TINY)
nif.human.visible_message("<span class='warning'>Swirling grey mist envelops [nif.human] as they change size!</span>","<span class='notice'>Swirling streams of nanites wrap around you as you change size!</span>")
nif.human.update_icons()
spawn(0)
deactivate()
deactivate()
if((. = ..()))
return TRUE
stat_text()
return "Change Size"
+4 -2
View File
@@ -98,6 +98,8 @@
while(null in owner.organs)
owner.organs -= null
implants.Cut() //VOREStation Add - Remove these too!
return ..()
/obj/item/organ/external/emp_act(severity)
@@ -448,7 +450,7 @@ This function completely restores a damaged organ to perfect condition.
// remove embedded objects and drop them on the floor
for(var/obj/implanted_object in implants)
if(!istype(implanted_object,/obj/item/weapon/implant)) // We don't want to remove REAL implants. Just shrapnel etc.
if(!istype(implanted_object,/obj/item/weapon/implant) && !istype(implanted_object,/obj/item/device/nif)) // We don't want to remove REAL implants. Just shrapnel etc. //VOREStation Edit - NIFs pls
implanted_object.loc = get_turf(src)
implants -= implanted_object
@@ -546,7 +548,7 @@ This function completely restores a damaged organ to perfect condition.
/obj/item/organ/external/proc/need_process()
if(status & (ORGAN_CUT_AWAY|ORGAN_BLEEDING|ORGAN_BROKEN|ORGAN_DESTROYED|ORGAN_DEAD|ORGAN_MUTATED))
return 1
if((brute_dam || burn_dam) && (robotic < ORGAN_ROBOT)) //Robot limbs don't autoheal and thus don't need to process when damaged
if(brute_dam || burn_dam)//VOREStation Edit - But they do for medichines! ---&& (robotic < ORGAN_ROBOT)) //Robot limbs don't autoheal and thus don't need to process when damaged
return 1
if(last_dam != brute_dam + burn_dam) // Process when we are fully healed up.
last_dam = brute_dam + burn_dam
+1 -2
View File
@@ -44,7 +44,7 @@
var/damage_type = CUT
// whether this wound needs a bandage/salve to heal at all
// the maximum amount of damage that this wound can have and still autoheal
var/autoheal_cutoff = 15
var/autoheal_cutoff = 10
@@ -336,7 +336,6 @@ datum/wound/puncture/massive
"moderate bruise" = 20, "small bruise" = 10, "tiny bruise" = 5)
bleed_threshold = 20
max_bleeding_stage = 2 //only huge bruise and above can bleed.
autoheal_cutoff = 30
damage_type = BRUISE
/** BURNS **/
+2 -2
View File
@@ -526,9 +526,9 @@ obj/structure/cable/proc/cableColor(var/colorC)
if(!S || S.robotic < ORGAN_ROBOT || S.open == 3)
return ..()
var/use_amt = min(src.amount, ceil(S.burn_dam/3), 5)
var/use_amt = min(src.amount, ceil(S.burn_dam/5), 5)
if(can_use(use_amt))
if(S.robo_repair(3*use_amt, BURN, "some damaged wiring", src, user))
if(S.robo_repair(5*use_amt, BURN, "some damaged wiring", src, user))
src.use(use_amt)
else
+2 -6
View File
@@ -396,17 +396,13 @@
/obj/machinery/power/port_gen/pacman/super/UseFuel()
//produces a tiny amount of radiation when in use
if (prob(2*power_output))
for (var/mob/living/L in range(src, 5))
L.apply_effect(1, IRRADIATE) //should amount to ~5 rads per minute at max safe power
radiation_repository.radiate(src, 4)
..()
/obj/machinery/power/port_gen/pacman/super/explode()
//a nice burst of radiation
var/rads = 50 + (sheets + sheet_left)*1.5
for (var/mob/living/L in range(src, 10))
//should really fall with the square of the distance, but that makes the rads value drop too fast
//I dunno, maybe physics works different when you live in 2D -- SM radiation also works like this, apparently
L.apply_effect(max(20, round(rads/get_dist(L,src))), IRRADIATE)
radiation_repository.radiate(src, (max(20, rads)))
explosion(src.loc, 3, 3, 5, 3)
qdel(src)
@@ -31,6 +31,11 @@ var/global/list/rad_collectors = list()
last_power_new = 0
if(P && active)
var/rads = radiation_repository.get_rads_at_turf(get_turf(src))
if(rads)
receive_pulse(rads * 5) //Maths is hard
if(P)
if(P.air_contents.gas["phoron"] == 0)
investigate_log("<font color='red'>out of fuel</font>.","singulo")
@@ -406,15 +406,13 @@
var/toxrange = 10
var/toxdamage = 4
var/radiation = 15
var/radiationmin = 3
if (src.energy>200)
toxdamage = round(((src.energy-150)/50)*4,1)
radiation = round(((src.energy-150)/50)*5,1)
radiationmin = round((radiation/5),1)//
radiation_repository.radiate(src, radiation) //Always radiate at max, so a decent dose of radiation is applied
for(var/mob/living/M in view(toxrange, src.loc))
if(M.status_flags & GODMODE)
continue
M.apply_effect(rand(radiationmin,radiation), IRRADIATE)
toxdamage = (toxdamage - (toxdamage*M.getarmor(null, "rad")))
M.apply_effect(toxdamage, TOX)
return
@@ -448,13 +446,13 @@
/obj/singularity/proc/smwave()
for(var/mob/living/M in view(10, src.loc))
if(prob(67))
M.apply_effect(rand(energy), IRRADIATE)
M << "<span class=\"warning\">You hear an uneartly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.</span>"
M << "<span class=\"notice\">Miraculously, it fails to kill you.</span>"
to_chat(M, "<span class=\"warning\">You hear an uneartly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.</span>")
to_chat(M, "<span class=\"notice\">Miraculously, it fails to kill you.</span>")
else
M << "<span class=\"danger\">You hear an uneartly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.</span>"
M << "<span class=\"danger\">You don't even have a moment to react as you are reduced to ashes by the intense radiation.</span>"
M.dust()
radiation_repository.radiate(src, rand(energy))
return
/obj/singularity/proc/pulse()
@@ -1,291 +1,323 @@
/obj/item/ammo_casing/a357
desc = "A .357 bullet casing."
caliber = "357"
projectile_type = /obj/item/projectile/bullet/pistol/strong
/obj/item/ammo_casing/a50
desc = "A .50AE bullet casing."
caliber = ".50"
projectile_type = /obj/item/projectile/bullet/pistol/strong
/obj/item/ammo_casing/a75
desc = "A .75 gyrojet rocket sheathe."
caliber = "75"
projectile_type = /obj/item/projectile/bullet/gyro
/obj/item/ammo_casing/c38
desc = "A .38 bullet casing."
caliber = "38"
projectile_type = /obj/item/projectile/bullet/pistol
/obj/item/ammo_casing/c38r
desc = "A .38 rubber bullet casing."
caliber = "38"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/c38/emp
name = ".38 haywire round"
desc = "A .38 bullet casing fitted with a single-use ion pulse generator."
icon_state = "empcasing"
projectile_type = /obj/item/projectile/ion/small
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/*
* 9mm
*/
/obj/item/ammo_casing/c9mm
desc = "A 9mm bullet casing."
caliber = "9mm"
projectile_type = /obj/item/projectile/bullet/pistol
/obj/item/ammo_casing/c9mm/ap
desc = "A 9mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/pistol/ap
/obj/item/ammo_casing/c9mmf
desc = "A 9mm flash shell casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/energy/flash
/obj/item/ammo_casing/c9mmr
desc = "A 9mm rubber bullet casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/c9mmp
desc = "A 9mm practice bullet casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/practice
/*
/obj/item/ammo_casing/c5mm
desc = "A 5mm bullet casing."
caliber = "5mm"
projectile_type = /obj/item/projectile/bullet/pistol/ap
*/
/*
* 45 ammo
*/
/obj/item/ammo_casing/c45
desc = "A .45 bullet casing."
caliber = ".45"
projectile_type = /obj/item/projectile/bullet/pistol/medium
/obj/item/ammo_casing/c45ap
desc = "A .45 Armor-Piercing bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/medium/ap
/obj/item/ammo_casing/c45p
desc = "A .45 practice bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/practice
/obj/item/ammo_casing/c45r
desc = "A .45 rubber bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/c45f
desc = "A .45 flash shell casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/energy/flash
/obj/item/ammo_casing/c45/emp
name = ".45 haywire round"
desc = "A .45 bullet casing fitted with a single-use ion pulse generator."
projectile_type = /obj/item/projectile/ion/small
icon_state = "empcasing"
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/obj/item/ammo_casing/c45/hp
desc = "A .45 hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/pistol/medium/hollow
/*
* 10mm
*/
/obj/item/ammo_casing/a10mm
desc = "A 10mm bullet casing."
caliber = "10mm"
projectile_type = /obj/item/projectile/bullet/pistol/medium
/obj/item/ammo_casing/a10mm/emp
name = "10mm haywire round"
desc = "A 10mm bullet casing fitted with a single-use ion pulse generator."
projectile_type = /obj/item/projectile/ion/small
icon_state = "empcasing"
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/*
* Shotguns
*/
/obj/item/ammo_casing/shotgun
name = "shotgun slug"
desc = "A 12 gauge slug."
icon_state = "slshell"
caliber = "shotgun"
projectile_type = /obj/item/projectile/bullet/shotgun
matter = list(DEFAULT_WALL_MATERIAL = 360)
/obj/item/ammo_casing/shotgun/pellet
name = "shotgun shell"
desc = "A 12 gauge shell."
icon_state = "gshell"
projectile_type = /obj/item/projectile/bullet/pellet/shotgun
matter = list(DEFAULT_WALL_MATERIAL = 360)
/obj/item/ammo_casing/shotgun/blank
name = "shotgun shell"
desc = "A blank shell."
icon_state = "blshell"
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/shotgun/practice
name = "shotgun shell"
desc = "A practice shell."
icon_state = "pshell"
projectile_type = /obj/item/projectile/bullet/shotgun/practice
matter = list("metal" = 90)
/obj/item/ammo_casing/shotgun/beanbag
name = "beanbag shell"
desc = "A beanbag shell."
icon_state = "bshell"
projectile_type = /obj/item/projectile/bullet/shotgun/beanbag
matter = list(DEFAULT_WALL_MATERIAL = 180)
//Can stun in one hit if aimed at the head, but
//is blocked by clothing that stops tasers and is vulnerable to EMP
/obj/item/ammo_casing/shotgun/stunshell
name = "stun shell"
desc = "A 12 gauge taser cartridge."
icon_state = "stunshell"
projectile_type = /obj/item/projectile/energy/electrode/stunshot
matter = list(DEFAULT_WALL_MATERIAL = 360, "glass" = 720)
/obj/item/ammo_casing/shotgun/stunshell/emp_act(severity)
if(prob(100/severity)) BB = null
update_icon()
//Does not stun, only blinds, but has area of effect.
/obj/item/ammo_casing/shotgun/flash
name = "flash shell"
desc = "A chemical shell used to signal distress or provide illumination."
icon_state = "fshell"
projectile_type = /obj/item/projectile/energy/flash/flare
matter = list(DEFAULT_WALL_MATERIAL = 90, "glass" = 90)
/obj/item/ammo_casing/shotgun/emp
name = "ion shell"
desc = "An advanced shotgun round that creates a small EMP when it strikes a target."
icon_state = "empshell"
projectile_type = /obj/item/projectile/ion
// projectile_type = /obj/item/projectile/bullet/shotgun/ion
matter = list(DEFAULT_WALL_MATERIAL = 360, "uranium" = 240)
/*
* 762mm
*/
/obj/item/ammo_casing/a762
desc = "A 7.62mm bullet casing."
caliber = "a762"
icon_state = "rifle-casing"
projectile_type = /obj/item/projectile/bullet/rifle/a762
/obj/item/ammo_casing/a762/ap
desc = "A 7.62mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a762/ap
/obj/item/ammo_casing/a762p
desc = "A 7.62mm practice bullet casing."
caliber = "a762"
icon_state = "rifle-casing" // Need to make an icon for these
projectile_type = /obj/item/projectile/bullet/rifle/practice
/obj/item/ammo_casing/a762/blank
desc = "A blank 7.62mm bullet casing."
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/a762/hp
desc = "A 7.62mm hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a762/hollow
//145mm
/obj/item/ammo_casing/a145
desc = "A 14.5mm shell."
icon_state = "lcasing"
caliber = "14.5mm"
projectile_type = /obj/item/projectile/bullet/rifle/a145
matter = list(DEFAULT_WALL_MATERIAL = 1250)
/*
* 556mm
*/
/obj/item/ammo_casing/a556
desc = "A 5.56mm bullet casing."
caliber = "a556"
icon_state = "rifle-casing"
projectile_type = /obj/item/projectile/bullet/rifle/a556
/obj/item/ammo_casing/a556/ap
desc = "A 5.56mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a556/ap
/obj/item/ammo_casing/a556p
desc = "A 5.56mm practice bullet casing."
caliber = "a556"
icon_state = "rifle-casing" // Need to make an icon for these
projectile_type = /obj/item/projectile/bullet/rifle/practice
/obj/item/ammo_casing/a556/blank
desc = "A blank 5.56mm bullet casing."
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/a556/hp
desc = "A 5.56mm hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a556/hollow
/*
* Misc
*/
/obj/item/ammo_casing/rocket
name = "rocket shell"
desc = "A high explosive designed to be fired from a launcher."
icon_state = "rocketshell"
projectile_type = /obj/item/missile
caliber = "rocket"
/obj/item/ammo_casing/cap
name = "cap"
desc = "A cap for children toys."
caliber = "caps"
icon_state = "r-casing"
color = "#FF0000"
projectile_type = /obj/item/projectile/bullet/pistol/cap
/obj/item/ammo_casing/spent // For simple hostile mobs only, so they don't cough up usable bullets when firing. This is for literally nothing else.
icon_state = "s-casing-spent"
BB = null
/************************************************************************/
/*
# An explaination of the naming format for guns and ammo:
#
# a = Ammo, as in individual rounds of ammunition.
# b = Box, intended to have ammo taken out one at a time by hand.
# c = Clips, intended to reload magazines or guns quickly.
# m = Magazine, intended to hold rounds of ammo.
# s = Speedloaders, intended to reload guns quickly.
#
# Use this format, followed by the caliber. For example, a shotgun's caliber
# variable is "12g" as a result. Ergo, a shotgun round's path would have "a12g",
# or a magazine with shotgun shells would be "m12g" instead. To avoid confusion
# for developers and in-game admins spawning these items, stick to this format.
# Likewise, when creating new rounds, the caliber variable should match whatever
# the name says.
#
# This comment is copied in magazines.dm as well.
*/
/************************************************************************/
/*
* .357
*/
/obj/item/ammo_casing/a357
desc = "A .357 bullet casing."
caliber = "357"
projectile_type = /obj/item/projectile/bullet/pistol/strong
/*
* .38
*/
/obj/item/ammo_casing/a38
desc = "A .38 bullet casing."
caliber = ".38"
projectile_type = /obj/item/projectile/bullet/pistol
/obj/item/ammo_casing/a38r
desc = "A .38 rubber bullet casing."
caliber = ".38"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/a38/emp
name = ".38 haywire round"
desc = "A .38 bullet casing fitted with a single-use ion pulse generator."
icon_state = "empcasing"
projectile_type = /obj/item/projectile/ion/small
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/*
* .50 Action Express
*/
/obj/item/ammo_casing/a50ae
desc = "A .50AE bullet casing."
caliber = ".50AE"
projectile_type = /obj/item/projectile/bullet/pistol/strong
/*
* .75 (aka Gyrojet Rockets, aka admin abuse)
*/
/obj/item/ammo_casing/a75
desc = "A .75 gyrojet rocket sheathe."
caliber = ".75"
projectile_type = /obj/item/projectile/bullet/gyro
/*
* 9mm
*/
/obj/item/ammo_casing/a9mm
desc = "A 9mm bullet casing."
caliber = "9mm"
projectile_type = /obj/item/projectile/bullet/pistol
/obj/item/ammo_casing/a9mm/ap
desc = "A 9mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/pistol/ap
/obj/item/ammo_casing/a9mmf
desc = "A 9mm flash shell casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/energy/flash
/obj/item/ammo_casing/a9mmr
desc = "A 9mm rubber bullet casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/a9mmp
desc = "A 9mm practice bullet casing."
caliber = "9mm"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/practice
/*
* .45
*/
/obj/item/ammo_casing/a45
desc = "A .45 bullet casing."
caliber = ".45"
projectile_type = /obj/item/projectile/bullet/pistol/medium
/obj/item/ammo_casing/a45ap
desc = "A .45 Armor-Piercing bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/medium/ap
/obj/item/ammo_casing/a45p
desc = "A .45 practice bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/practice
/obj/item/ammo_casing/a45r
desc = "A .45 rubber bullet casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/bullet/pistol/rubber
/obj/item/ammo_casing/a45f
desc = "A .45 flash shell casing."
caliber = ".45"
icon_state = "r-casing"
projectile_type = /obj/item/projectile/energy/flash
/obj/item/ammo_casing/a45/emp
name = ".45 haywire round"
desc = "A .45 bullet casing fitted with a single-use ion pulse generator."
projectile_type = /obj/item/projectile/ion/small
icon_state = "empcasing"
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/obj/item/ammo_casing/a45/hp
desc = "A .45 hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/pistol/medium/hollow
/*
* 10mm
*/
/obj/item/ammo_casing/a10mm
desc = "A 10mm bullet casing."
caliber = "10mm"
projectile_type = /obj/item/projectile/bullet/pistol/medium
/obj/item/ammo_casing/a10mm/emp
name = "10mm haywire round"
desc = "A 10mm bullet casing fitted with a single-use ion pulse generator."
projectile_type = /obj/item/projectile/ion/small
icon_state = "empcasing"
matter = list(DEFAULT_WALL_MATERIAL = 130, "uranium" = 100)
/*
* 12g (aka shotgun ammo)
*/
/obj/item/ammo_casing/a12g
name = "shotgun slug"
desc = "A 12 gauge slug."
icon_state = "slshell"
caliber = "12g"
projectile_type = /obj/item/projectile/bullet/shotgun
matter = list(DEFAULT_WALL_MATERIAL = 360)
/obj/item/ammo_casing/a12g/pellet
name = "shotgun shell"
desc = "A 12 gauge shell."
icon_state = "gshell"
projectile_type = /obj/item/projectile/bullet/pellet/shotgun
matter = list(DEFAULT_WALL_MATERIAL = 360)
/obj/item/ammo_casing/a12g/blank
name = "shotgun shell"
desc = "A blank shell."
icon_state = "blshell"
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/a12g/practice
name = "shotgun shell"
desc = "A practice shell."
icon_state = "pshell"
projectile_type = /obj/item/projectile/bullet/shotgun/practice
matter = list("metal" = 90)
/obj/item/ammo_casing/a12g/beanbag
name = "beanbag shell"
desc = "A beanbag shell."
icon_state = "bshell"
projectile_type = /obj/item/projectile/bullet/shotgun/beanbag
matter = list(DEFAULT_WALL_MATERIAL = 180)
//Can stun in one hit if aimed at the head, but
//is blocked by clothing that stops tasers and is vulnerable to EMP
/obj/item/ammo_casing/a12g/stunshell
name = "stun shell"
desc = "A 12 gauge taser cartridge."
icon_state = "stunshell"
projectile_type = /obj/item/projectile/energy/electrode/stunshot
matter = list(DEFAULT_WALL_MATERIAL = 360, "glass" = 720)
/obj/item/ammo_casing/a12g/stunshell/emp_act(severity)
if(prob(100/severity)) BB = null
update_icon()
//Does not stun, only blinds, but has area of effect.
/obj/item/ammo_casing/a12g/flash
name = "flash shell"
desc = "A chemical shell used to signal distress or provide illumination."
icon_state = "fshell"
projectile_type = /obj/item/projectile/energy/flash/flare
matter = list(DEFAULT_WALL_MATERIAL = 90, "glass" = 90)
/obj/item/ammo_casing/a12g/emp
name = "ion shell"
desc = "An advanced shotgun round that creates a small EMP when it strikes a target."
icon_state = "empshell"
projectile_type = /obj/item/projectile/ion
// projectile_type = /obj/item/projectile/bullet/shotgun/ion
matter = list(DEFAULT_WALL_MATERIAL = 360, "uranium" = 240)
/*
* 7.62mm
*/
/obj/item/ammo_casing/a762
desc = "A 7.62mm bullet casing."
caliber = "7.62mm"
icon_state = "rifle-casing"
projectile_type = /obj/item/projectile/bullet/rifle/a762
/obj/item/ammo_casing/a762/ap
desc = "A 7.62mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a762/ap
/obj/item/ammo_casing/a762p
desc = "A 7.62mm practice bullet casing."
caliber = "7.62mm"
icon_state = "rifle-casing" // Need to make an icon for these
projectile_type = /obj/item/projectile/bullet/rifle/practice
/obj/item/ammo_casing/a762/blank
desc = "A blank 7.62mm bullet casing."
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/a762/hp
desc = "A 7.62mm hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a762/hollow
/*
* 14.5mm (anti-materiel rifle round)
*/
/obj/item/ammo_casing/a145
desc = "A 14.5mm shell."
icon_state = "lcasing"
caliber = "14.5mm"
projectile_type = /obj/item/projectile/bullet/rifle/a145
matter = list(DEFAULT_WALL_MATERIAL = 1250)
/*
* 5.56mm
*/
/obj/item/ammo_casing/a556
desc = "A 5.56mm bullet casing."
caliber = "5.56mm"
icon_state = "rifle-casing"
projectile_type = /obj/item/projectile/bullet/rifle/a556
/obj/item/ammo_casing/a556/ap
desc = "A 5.56mm armor-piercing bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a556/ap
/obj/item/ammo_casing/a556p
desc = "A 5.56mm practice bullet casing."
caliber = "5.56mm"
icon_state = "rifle-casing" // Need to make an icon for these
projectile_type = /obj/item/projectile/bullet/rifle/practice
/obj/item/ammo_casing/a556/blank
desc = "A blank 5.56mm bullet casing."
projectile_type = /obj/item/projectile/bullet/blank
matter = list(DEFAULT_WALL_MATERIAL = 90)
/obj/item/ammo_casing/a556/hp
desc = "A 5.56mm hollow-point bullet casing."
projectile_type = /obj/item/projectile/bullet/rifle/a556/hollow
/*
* Misc
*/
/obj/item/ammo_casing/rocket
name = "rocket shell"
desc = "A high explosive designed to be fired from a launcher."
icon_state = "rocketshell"
projectile_type = /obj/item/missile
caliber = "rocket"
/obj/item/ammo_casing/cap
name = "cap"
desc = "A cap for children toys."
caliber = "caps"
icon_state = "r-casing"
color = "#FF0000"
projectile_type = /obj/item/projectile/bullet/pistol/cap
/obj/item/ammo_casing/spent // For simple hostile mobs only, so they don't cough up usable bullets when firing. This is for literally nothing else.
icon_state = "s-casing-spent"
BB = null
projectile_type = null
@@ -8,7 +8,7 @@
caliber = "9mm"
origin_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 2)
slot_flags = SLOT_BELT
ammo_type = /obj/item/ammo_casing/c9mm
ammo_type = /obj/item/ammo_casing/a9mm
multi_aim = 1
burst_delay = 2
@@ -33,8 +33,8 @@
slot_flags = SLOT_BELT|SLOT_BACK
fire_sound = 'sound/weapons/Gunshot_light.ogg'
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/a10mm
allowed_magazines = list(/obj/item/ammo_magazine/a10mm)
magazine_type = /obj/item/ammo_magazine/m10mm
allowed_magazines = list(/obj/item/ammo_magazine/m10mm)
auto_eject = 1
auto_eject_sound = 'sound/weapons/smg_empty_alarm.ogg'
@@ -56,12 +56,12 @@
item_state = null
w_class = ITEMSIZE_LARGE
force = 10
caliber = "a556"
caliber = "5.56mm"
origin_tech = list(TECH_COMBAT = 6, TECH_MATERIAL = 1, TECH_ILLEGAL = 4)
slot_flags = SLOT_BACK
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/c556
allowed_magazines = list(/obj/item/ammo_magazine/c556)
magazine_type = /obj/item/ammo_magazine/m556
allowed_magazines = list(/obj/item/ammo_magazine/m556)
one_handed_penalty = 4
@@ -73,8 +73,8 @@
/obj/item/weapon/gun/projectile/automatic/sts35/update_icon(var/ignore_inhands)
..()
if(istype(ammo_magazine,/obj/item/ammo_magazine/s762))
icon_state = "arifle-small"
if(istype(ammo_magazine,/obj/item/ammo_magazine/m556/small))
icon_state = "arifle-small" // If using the small magazines, use the small magazine sprite.
else
icon_state = (ammo_magazine)? "arifle" : "arifle-empty"
if(!ignore_inhands) update_held_icon()
@@ -88,11 +88,11 @@
caliber = "9mm"
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 2)
slot_flags = SLOT_BELT
ammo_type = "/obj/item/ammo_casing/c9mmr"
ammo_type = "/obj/item/ammo_casing/a9mmr"
fire_sound = 'sound/weapons/Gunshot_light.ogg'
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/mc9mmt/rubber
allowed_magazines = list(/obj/item/ammo_magazine/mc9mmt)
magazine_type = /obj/item/ammo_magazine/m9mmt/rubber
allowed_magazines = list(/obj/item/ammo_magazine/m9mmt)
/obj/item/weapon/gun/projectile/automatic/wt550/update_icon()
..()
@@ -109,14 +109,14 @@
item_state = "z8carbine"
w_class = ITEMSIZE_LARGE
force = 10
caliber = "a762"
caliber = "7.62mm"
origin_tech = list(TECH_COMBAT = 8, TECH_MATERIAL = 3)
ammo_type = "/obj/item/ammo_casing/a556" // Is this really needed anymore?
fire_sound = 'sound/weapons/Gunshot.ogg'
slot_flags = SLOT_BACK
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/c762
allowed_magazines = list(/obj/item/ammo_magazine/c762)
magazine_type = /obj/item/ammo_magazine/m762
allowed_magazines = list(/obj/item/ammo_magazine/m762)
auto_eject = 1
auto_eject_sound = 'sound/weapons/smg_empty_alarm.ogg'
@@ -181,14 +181,14 @@
force = 10
slot_flags = 0
max_shells = 50
caliber = "a556"
caliber = "5.56mm"
origin_tech = list(TECH_COMBAT = 6, TECH_MATERIAL = 1, TECH_ILLEGAL = 2)
slot_flags = SLOT_BACK
ammo_type = "/obj/item/ammo_casing/a556" // Is this really needed anymore?
fire_sound = 'sound/weapons/machinegun.ogg'
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/a556
allowed_magazines = list(/obj/item/ammo_magazine/a556, /obj/item/ammo_magazine/c556)
magazine_type = /obj/item/ammo_magazine/m556saw
allowed_magazines = list(/obj/item/ammo_magazine/m556saw, /obj/item/ammo_magazine/m556)
one_handed_penalty = 6
@@ -225,7 +225,7 @@
return ..() //once open, behave like normal
/obj/item/weapon/gun/projectile/automatic/l6_saw/update_icon()
if(istype(ammo_magazine,/obj/item/ammo_magazine/c762))
if(istype(ammo_magazine,/obj/item/ammo_magazine/m762))
icon_state = "l6[cover_open ? "open" : "closed"]mag"
item_state = icon_state
else
@@ -252,13 +252,13 @@
item_state = null
w_class = ITEMSIZE_LARGE
force = 10
caliber = "shotgun"
caliber = "12g"
fire_sound = 'sound/weapons/shotgun.ogg'
origin_tech = list(TECH_COMBAT = 6, TECH_MATERIAL = 1, TECH_ILLEGAL = 4)
slot_flags = SLOT_BACK
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/g12
allowed_magazines = list(/obj/item/ammo_magazine/g12)
magazine_type = /obj/item/ammo_magazine/m12gdrum
allowed_magazines = list(/obj/item/ammo_magazine/m12gdrum)
one_handed_penalty = 4
@@ -284,8 +284,8 @@
load_method = MAGAZINE
caliber = ".45"
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 2, TECH_ILLEGAL = 5)
magazine_type = /obj/item/ammo_magazine/c45uzi
allowed_magazines = list(/obj/item/ammo_magazine/c45uzi)
magazine_type = /obj/item/ammo_magazine/m45uzi
allowed_magazines = list(/obj/item/ammo_magazine/m45uzi)
firemodes = list(
list(mode_name="semiauto", burst=1, fire_delay=0),
@@ -310,8 +310,8 @@
slot_flags = SLOT_BELT // ToDo: Belt sprite.
fire_sound = 'sound/weapons/Gunshot_light.ogg'
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/p90
allowed_magazines = list(/obj/item/ammo_magazine/p90, /obj/item/ammo_magazine/mc9mmt) // ToDo: New sprite for the different mag.
magazine_type = /obj/item/ammo_magazine/m9mmp90
allowed_magazines = list(/obj/item/ammo_magazine/m9mmp90, /obj/item/ammo_magazine/m9mmt) // ToDo: New sprite for the different mag.
firemodes = list(
list(mode_name="semiauto", burst=1, fire_delay=0),
@@ -330,8 +330,8 @@
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 2, TECH_ILLEGAL = 5)
slot_flags = SLOT_BELT // ToDo: Belt sprite.
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/tommymag
allowed_magazines = list(/obj/item/ammo_magazine/tommymag, /obj/item/ammo_magazine/tommydrum)
magazine_type = /obj/item/ammo_magazine/m45tommy
allowed_magazines = list(/obj/item/ammo_magazine/m45tommy, /obj/item/ammo_magazine/m45tommydrum)
firemodes = list(
list(mode_name="semiauto", burst=1, fire_delay=0),
@@ -343,19 +343,19 @@
icon_state = (ammo_magazine)? "tommygun" : "tommygun-empty"
// update_held_icon()
/obj/item/weapon/gun/projectile/automatic/carbine
/obj/item/weapon/gun/projectile/automatic/carbine // Admin abuse assault rifle. ToDo: Make this less shit. Maybe remove its autofire, and make it spawn with only 10 rounds at start.
name = "assault carbine"
desc = "The bullpup configured GP3000 is a lightweight, compact, military-grade assault rifle produced by Gurov Projectile Weapons LLC. It is sold almost exclusively to standing armies. The serial number on this one has been scratched off. Uses 5.56mm rounds."
icon_state = "bullpup"
item_state = "bullpup"
w_class = ITEMSIZE_LARGE
force = 10
caliber = "a762"
caliber = "7.62mm"
origin_tech = list(TECH_COMBAT = 6, TECH_MATERIAL = 1, TECH_ILLEGAL = 4)
slot_flags = SLOT_BACK
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/c762
allowed_magazines = list(/obj/item/ammo_magazine/c762)
magazine_type = /obj/item/ammo_magazine/m762m
allowed_magazines = list(/obj/item/ammo_magazine/m762, /obj/item/ammo_magazine/m762m)
one_handed_penalty = 4
@@ -366,9 +366,9 @@
/obj/item/weapon/gun/projectile/automatic/carbine/update_icon(var/ignore_inhands)
..()
if(ammo_magazine)
icon_state = "bullpup"
if(istype(ammo_magazine,/obj/item/ammo_magazine/m762))
icon_state = "bullpup-small" // If using the smaller magazines, use the small mag sprite.
else
icon_state = "bullpup-empty"
item_state = (ammo_magazine)? "bullpup" : "bullpup-empty"
if(!ignore_inhands) update_held_icon()
if(!ignore_inhands) update_held_icon()
@@ -1,2 +1,2 @@
/obj/item/weapon/gun/projectile/automatic/wt550/lethal
magazine_type = /obj/item/ammo_magazine/mc9mmt
magazine_type = /obj/item/ammo_magazine/m9mmt
@@ -7,7 +7,7 @@
icon_state = "boltaction"
fire_sound = 'sound/weapons/rifleshot.ogg'
max_shells = 5
caliber = "a762"
caliber = "7.62mm"
origin_tech = list(TECH_COMBAT = 1)// Old as shit rifle doesn't have very good tech.
ammo_type = /obj/item/ammo_casing/a762
load_method = SINGLE_CASING|SPEEDLOADER
@@ -60,7 +60,7 @@
icon_state = "leveraction"
fire_sound = 'sound/weapons/rifleshot.ogg'
max_shells = 5
caliber = "a762"
caliber = "7.62mm"
origin_tech = list(TECH_COMBAT = 1)// Old as shit rifle doesn't have very good tech.
ammo_type = /obj/item/ammo_casing/a762
load_method = SINGLE_CASING|SPEEDLOADER
@@ -62,7 +62,7 @@
var/container_type = /obj/item/weapon/reagent_containers/glass/beaker
var/list/starting_chems = null
/obj/item/weapon/gun/projectile/dartgun/dartgun/New()
/obj/item/weapon/gun/projectile/dartgun/New() //VOREStation Edit - Think this was a typo
..()
if(starting_chems)
for(var/chem in starting_chems)
@@ -2,8 +2,8 @@
var/unique_reskin
name = ".45 pistol"
desc = "A cheap Martian knock-off of a Colt M1911. Uses .45 rounds."
magazine_type = /obj/item/ammo_magazine/c45m
allowed_magazines = list(/obj/item/ammo_magazine/c45m)
magazine_type = /obj/item/ammo_magazine/m45
allowed_magazines = list(/obj/item/ammo_magazine/m45)
icon_state = "colt"
caliber = ".45"
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
@@ -12,7 +12,7 @@
/obj/item/weapon/gun/projectile/colt/detective
desc = "A Martian recreation of an old Terran pistol. Uses .45 rounds."
magazine_type = /obj/item/ammo_magazine/c45m/rubber
magazine_type = /obj/item/ammo_magazine/m45/rubber
/obj/item/weapon/gun/projectile/colt/detective/update_icon()
if(ammo_magazine)
@@ -71,7 +71,7 @@
name = ".45 pistol"
desc = "The NT Mk58 is a cheap, ubiquitous sidearm, produced by a NanoTrasen subsidiary. Found pretty much everywhere humans are. Uses .45 rounds."
icon_state = "secguncomp"
magazine_type = /obj/item/ammo_magazine/c45m/rubber
magazine_type = /obj/item/ammo_magazine/m45/rubber
caliber = ".45"
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
fire_sound = 'sound/weapons/semiauto.ogg'
@@ -86,7 +86,7 @@
/obj/item/weapon/gun/projectile/sec/flash
name = ".45 signal pistol"
magazine_type = /obj/item/ammo_magazine/c45m/flash
magazine_type = /obj/item/ammo_magazine/m45/flash
/obj/item/weapon/gun/projectile/sec/wood
desc = "The NT Mk58 is a cheap, ubiquitous sidearm, produced by a NanoTrasen subsidiary. This one has a sweet wooden grip. Uses .45 rounds."
@@ -111,8 +111,8 @@
recoil = 0
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2, TECH_ILLEGAL = 8)
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/c45m
allowed_magazines = list(/obj/item/ammo_magazine/c45m)
magazine_type = /obj/item/ammo_magazine/m45
allowed_magazines = list(/obj/item/ammo_magazine/m45)
/obj/item/weapon/gun/projectile/deagle
name = "desert eagle"
@@ -120,11 +120,11 @@
icon_state = "deagle"
item_state = "deagle"
force = 14.0
caliber = ".50"
caliber = ".50AE"
load_method = MAGAZINE
fire_sound = 'sound/weapons/deagle.ogg'
magazine_type = /obj/item/ammo_magazine/a50
allowed_magazines = list(/obj/item/ammo_magazine/a50)
magazine_type = /obj/item/ammo_magazine/m50
allowed_magazines = list(/obj/item/ammo_magazine/m50)
/obj/item/weapon/gun/projectile/deagle/update_icon()
..()
@@ -168,13 +168,13 @@
desc = "Speak softly, and carry a big gun. Fires rare .75 caliber self-propelled exploding bolts--because fuck you and everything around you."
icon_state = "gyropistol"
max_shells = 8
caliber = "75"
caliber = ".75"
fire_sound = 'sound/weapons/rpg.ogg'
origin_tech = list(TECH_COMBAT = 3)
ammo_type = "/obj/item/ammo_casing/a75"
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/a75
allowed_magazines = list(/obj/item/ammo_magazine/a75)
magazine_type = /obj/item/ammo_magazine/m75
allowed_magazines = list(/obj/item/ammo_magazine/m75)
auto_eject = 1
auto_eject_sound = 'sound/weapons/smg_empty_alarm.ogg'
@@ -196,12 +196,12 @@
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2, TECH_ILLEGAL = 2)
fire_sound = 'sound/weapons/semiauto.ogg'
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/mc9mm
allowed_magazines = list(/obj/item/ammo_magazine/mc9mm)
magazine_type = /obj/item/ammo_magazine/m9mm
allowed_magazines = list(/obj/item/ammo_magazine/m9mm)
/obj/item/weapon/gun/projectile/pistol/flash
name = "holdout signal pistol"
magazine_type = /obj/item/ammo_magazine/mc9mm/flash
magazine_type = /obj/item/ammo_magazine/m9mm/flash
/obj/item/weapon/gun/projectile/pistol/attack_hand(mob/living/user as mob)
if(user.get_inactive_hand() == src)
@@ -256,17 +256,17 @@
var/global/list/ammo_types = list(
/obj/item/ammo_casing/a357 = ".357",
/obj/item/ammo_casing/c9mmf = "9mm",
/obj/item/ammo_casing/c45f = ".45",
/obj/item/ammo_casing/a9mmf = "9mm",
/obj/item/ammo_casing/a45f = ".45",
/obj/item/ammo_casing/a10mm = "10mm",
/obj/item/ammo_casing/shotgun = "12 gauge",
/obj/item/ammo_casing/shotgun = "12 gauge",
/obj/item/ammo_casing/shotgun/pellet = "12 gauge",
/obj/item/ammo_casing/shotgun/pellet = "12 gauge",
/obj/item/ammo_casing/shotgun/pellet = "12 gauge",
/obj/item/ammo_casing/shotgun/beanbag = "12 gauge",
/obj/item/ammo_casing/shotgun/stunshell = "12 gauge",
/obj/item/ammo_casing/shotgun/flash = "12 gauge",
/obj/item/ammo_casing/a12g = "12 gauge",
/obj/item/ammo_casing/a12g = "12 gauge",
/obj/item/ammo_casing/a12g/pellet = "12 gauge",
/obj/item/ammo_casing/a12g/pellet = "12 gauge",
/obj/item/ammo_casing/a12g/pellet = "12 gauge",
/obj/item/ammo_casing/a12g/beanbag = "12 gauge",
/obj/item/ammo_casing/a12g/stunshell = "12 gauge",
/obj/item/ammo_casing/a12g/flash = "12 gauge",
/obj/item/ammo_casing/a762 = "7.62mm",
/obj/item/ammo_casing/a556 = "5.56mm"
)
@@ -299,8 +299,8 @@
caliber = "9mm"
load_method = MAGAZINE
fire_sound = 'sound/weapons/semiauto.ogg'
magazine_type = /obj/item/ammo_magazine/mc9mm
allowed_magazines = list(/obj/item/ammo_magazine/mc9mm)
magazine_type = /obj/item/ammo_magazine/m9mm
allowed_magazines = list(/obj/item/ammo_magazine/m9mm)
/obj/item/weapon/gun/projectile/luger/update_icon()
..()
@@ -43,10 +43,10 @@
name = "revolver"
desc = "A cheap Martian knock-off of a Smith & Wesson Model 10. Uses .38-Special rounds."
icon_state = "detective"
caliber = "38"
caliber = ".38"
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
fire_sound = 'sound/weapons/Gunshot_light.ogg'
ammo_type = /obj/item/ammo_casing/c38
ammo_type = /obj/item/ammo_casing/a38
/obj/item/weapon/gun/projectile/revolver/detective/verb/rename_gun()
set name = "Name Gun"
@@ -71,13 +71,13 @@
name = "Deckard .38"
desc = "A custom-built revolver, based off the semi-popular Detective Special model."
icon_state = "deckard-empty"
caliber = "38"
caliber = ".38"
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
fire_sound = 'sound/weapons/Gunshot_light.ogg'
ammo_type = /obj/item/ammo_casing/c38
ammo_type = /obj/item/ammo_casing/a38
/obj/item/weapon/gun/projectile/revolver/deckard/emp
ammo_type = /obj/item/ammo_casing/c38/emp
ammo_type = /obj/item/ammo_casing/a38/emp
/obj/item/weapon/gun/projectile/revolver/deckard/update_icon()
@@ -107,13 +107,13 @@
name = "\"The Judge\""
desc = "A revolving hand-shotgun by Cybersun Industries that packs the power of a 12 guage in the palm of your hand (if you don't break your wrist). Uses 12 shotgun rounds."
icon_state = "judge"
caliber = "shotgun"
caliber = "12g"
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2, TECH_ILLEGAL = 4)
max_shells = 5
fire_sound = 'sound/weapons/shotgun.ogg'
recoil = 2 // ow my fucking hand
accuracy = -1 // smooth bore + short barrel = shit accuracy
ammo_type = /obj/item/ammo_casing/shotgun
ammo_type = /obj/item/ammo_casing/a12g
// ToDo: Remove accuracy debuf in exchange for slightly injuring your hand every time you fire it.
/obj/item/weapon/gun/projectile/revolver/lemat
@@ -124,11 +124,11 @@
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
handle_casings = CYCLE_CASINGS
max_shells = 9
caliber = "38"
ammo_type = /obj/item/ammo_casing/c38
caliber = ".38"
ammo_type = /obj/item/ammo_casing/a38
var/secondary_max_shells = 1
var/secondary_caliber = "shotgun"
var/secondary_ammo_type = /obj/item/ammo_casing/shotgun
var/secondary_caliber = "12g"
var/secondary_ammo_type = /obj/item/ammo_casing/a12g
var/flipped_firing = 0
var/list/secondary_loaded = list()
var/list/tertiary_loaded = list()
@@ -8,10 +8,10 @@
force = 10
flags = CONDUCT
slot_flags = SLOT_BACK
caliber = "shotgun"
caliber = "12g"
origin_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 2)
load_method = SINGLE_CASING
ammo_type = /obj/item/ammo_casing/shotgun/beanbag
ammo_type = /obj/item/ammo_casing/a12g/beanbag
handle_casings = HOLD_CASINGS
fire_sound = 'sound/weapons/shotgun.ogg'
var/recentpump = 0 // to prevent spammage
@@ -48,7 +48,7 @@
item_state = "cshotgun"
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 2)
max_shells = 7 //match the ammo box capacity, also it can hold a round in the chamber anyways, for a total of 8.
ammo_type = /obj/item/ammo_casing/shotgun
ammo_type = /obj/item/ammo_casing/a12g
/obj/item/weapon/gun/projectile/shotgun/doublebarrel
name = "double-barreled shotgun"
@@ -64,9 +64,9 @@
force = 10
flags = CONDUCT
slot_flags = SLOT_BACK
caliber = "shotgun"
caliber = "12g"
origin_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 1)
ammo_type = /obj/item/ammo_casing/shotgun/beanbag
ammo_type = /obj/item/ammo_casing/a12g/beanbag
burst_delay = 0
firemodes = list(
@@ -75,12 +75,12 @@
)
/obj/item/weapon/gun/projectile/shotgun/doublebarrel/pellet
ammo_type = /obj/item/ammo_casing/shotgun/pellet
ammo_type = /obj/item/ammo_casing/a12g/pellet
/obj/item/weapon/gun/projectile/shotgun/doublebarrel/flare
name = "signal shotgun"
desc = "A double-barreled shotgun meant to fire signal flash shells."
ammo_type = /obj/item/ammo_casing/shotgun/flash
ammo_type = /obj/item/ammo_casing/a12g/flash
/obj/item/weapon/gun/projectile/shotgun/doublebarrel/unload_ammo(user, allow_dump)
..(user, allow_dump=1)
@@ -115,6 +115,6 @@
icon_state = "sawnshotgun"
item_state = "sawnshotgun"
slot_flags = SLOT_BELT|SLOT_HOLSTER
ammo_type = /obj/item/ammo_casing/shotgun/pellet
ammo_type = /obj/item/ammo_casing/a12g/pellet
w_class = ITEMSIZE_NORMAL
force = 5
@@ -80,7 +80,7 @@
slot_flags = SLOT_BACK // Needs a sprite.
origin_tech = list(TECH_COMBAT = 8, TECH_MATERIAL = 2, TECH_ILLEGAL = 8)
recoil = 2 //extra kickback
caliber = "a762"
caliber = "7.62mm"
load_method = MAGAZINE
accuracy = -3 //shooting at the hip
scoped_accuracy = 0
@@ -88,11 +88,11 @@
one_handed_penalty = 4 // The weapon itself is heavy, and the long barrel makes it hard to hold steady with just one hand.
fire_sound = 'sound/weapons/SVD_shot.ogg'
magazine_type = /obj/item/ammo_magazine/SVD
allowed_magazines = list(/obj/item/ammo_magazine/SVD, /obj/item/ammo_magazine/c762)
allowed_magazines = list(/obj/item/ammo_magazine/SVD, /obj/item/ammo_magazine/m762)
/obj/item/weapon/gun/projectile/SVD/update_icon()
..()
// if(istype(ammo_magazine,/obj/item/ammo_magazine/c762)
// if(istype(ammo_magazine,/obj/item/ammo_magazine/m762)
// icon_state = "SVD-bigmag" //No icon for this exists yet.
if(ammo_magazine)
icon_state = "SVD"
@@ -17,12 +17,12 @@
// requires_two_hands = 1
one_handed_penalty = 4 // The weapon itself is heavy, and the long barrel makes it hard to hold steady with just one hand.
fire_sound = 'sound/weapons/SVD_shot.ogg'
magazine_type = /obj/item/ammo_magazine/s762
allowed_magazines = list(/obj/item/ammo_magazine/s762, /obj/item/ammo_magazine/c762)
magazine_type = /obj/item/ammo_magazine/m762
allowed_magazines = list(/obj/item/ammo_magazine/m762, /obj/item/ammo_magazine/m762)
/obj/item/weapon/gun/projectile/SVD/update_icon()
..()
// if(istype(ammo_magazine,/obj/item/ammo_magazine/c762)
// if(istype(ammo_magazine,/obj/item/ammo_magazine/m762)
// icon_state = "SVD-bigmag" //No icon for this exists yet.
if(ammo_magazine)
icon_state = "SVD"
+7 -7
View File
@@ -62,16 +62,16 @@ var/global/list/datum/supply_drop_loot/supply_drop
/obj/item/weapon/storage/box/emps,
/obj/item/weapon/storage/box/flashbangs,
/obj/item/weapon/gun/projectile/automatic/sts35,
/obj/item/ammo_magazine/c762/ap,
/obj/item/ammo_magazine/c762/ap,
/obj/item/ammo_magazine/m762/ap,
/obj/item/ammo_magazine/m762/ap,
/obj/item/weapon/gun/projectile/colt,
/obj/item/ammo_magazine/c45m,
/obj/item/ammo_magazine/m45,
/obj/item/weapon/material/hatchet/tacknife/combatknife)
/datum/supply_drop_loot/heavy_warfare
name = "Heavy Warfare"
container = /obj/structure/largecrate
/datum/supply_drop_loot/armour/New()
/datum/supply_drop_loot/heavy_warfare/New()
..()
contents = list(
/obj/item/clothing/head/helmet/combat,
@@ -83,8 +83,8 @@ var/global/list/datum/supply_drop_loot/supply_drop
/obj/item/clothing/accessory/storage/black_drop_pouches,
/obj/item/weapon/storage/backpack/dufflebag/sec,
/obj/item/weapon/gun/projectile/automatic/carbine,
/obj/item/ammo_magazine/c762/ap,
/obj/item/ammo_magazine/c762,
/obj/item/ammo_magazine/m762/ap,
/obj/item/ammo_magazine/m762,
/obj/item/weapon/shield/energy,
/obj/item/weapon/grenade/frag,
/obj/item/weapon/grenade/frag,
@@ -99,7 +99,7 @@ var/global/list/datum/supply_drop_loot/supply_drop
datum/supply_drop_loot/riot
name = "Riot Gear"
container = /obj/structure/largecrate
/datum/supply_drop_loot/armour/New()
/datum/supply_drop_loot/riot/New()
..()
contents = list(
/obj/item/clothing/head/helmet/riot,
@@ -34,10 +34,12 @@
data -= taste
/datum/reagent/nutriment/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
if(!injectable)
/* if(!injectable) vorestation removal
M.adjustToxLoss(0.1 * removed)
return
affect_ingest(M, alien, removed)
affect_ingest(M, alien, removed) */
if(injectable) //vorestation addition/replacement
affect_ingest(M, alien, removed)
/datum/reagent/nutriment/affect_ingest(var/mob/living/carbon/M, var/alien, var/removed)
switch(alien)
@@ -249,7 +249,7 @@
user.drop_from_inventory(src)
qdel(src)
return
else if(istype(D, /obj/item/weapon/mop))
else if(istype(D, /obj/item/weapon/mop) || istype(D, /obj/item/weapon/soap) || istype(D, /obj/item/weapon/reagent_containers/glass/rag)) //VOREStation Edit - "Allows soap and rags to be used on buckets"
if(reagents.total_volume < 1)
user << "<span class='warning'>\The [src] is empty!</span>"
else
+2 -2
View File
@@ -545,7 +545,7 @@ other types of metals and chemistry for reagents).
id = "ammo_9mm"
req_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 3)
materials = list(DEFAULT_WALL_MATERIAL = 3750, "silver" = 100)
build_path = /obj/item/ammo_magazine/c9mm
build_path = /obj/item/ammo_magazine/box/c9mm
sort_string = "TAACA"
/datum/design/item/weapon/stunshell
@@ -553,7 +553,7 @@ other types of metals and chemistry for reagents).
id = "stunshell"
req_tech = list(TECH_COMBAT = 3, TECH_MATERIAL = 3)
materials = list(DEFAULT_WALL_MATERIAL = 4000)
build_path = /obj/item/ammo_casing/shotgun/stunshell
build_path = /obj/item/ammo_casing/a12g/stunshell
sort_string = "TAACB"
/datum/design/item/weapon/chemsprayer
+8
View File
@@ -77,6 +77,14 @@
build_path = /obj/item/device/universal_translator/ear
sort_string = "HABBB"
/datum/design/item/nif
name = "nanite implant framework"
id = "nif"
req_tech = list(TECH_MAGNET = 5, TECH_BLUESPACE = 5, TECH_MATERIAL = 5, TECH_ENGINEERING = 5, TECH_DATA = 5)
materials = list(DEFAULT_WALL_MATERIAL = 5000, "glass" = 8000, "uranium" = 6000, "diamond" = 6000)
build_path = /obj/item/device/nif
sort_string = "HABBC"
// Resleeving Circuitboards
/datum/design/circuit/transhuman_clonepod
+2 -1
View File
@@ -49,7 +49,8 @@
BITSET(H.hud_updateflag, BACKUP_HUD)
//Okay we've got a mind at least
if(H == imp_in && H.mind && H.stat < DEAD)
transcore.m_backup(H.mind)
transcore.m_backup(H.mind,H.nif)
persist_nif_data(H)
spawn(attempt_delay)
backup()
+19 -1
View File
@@ -40,7 +40,7 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore
spawn(process_time)
process()
/datum/transhuman/infocore/proc/m_backup(var/datum/mind/mind)
/datum/transhuman/infocore/proc/m_backup(var/datum/mind/mind,var/obj/item/device/nif/nif)
ASSERT(mind)
if(!mind.name || core_dumped)
return 0
@@ -50,6 +50,20 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore
if(mind.name in backed_up)
MR = backed_up[mind.name]
MR.last_update = world.time
if(nif)
MR.nif_path = nif.type
MR.nif_durability = nif.durability
var/list/nifsofts = list()
for(var/N in nif.nifsofts)
if(N)
var/datum/nifsoft/nifsoft = N
nifsofts += nifsoft.type
MR.nif_software = nifsofts
else
MR.nif_path = null
MR.nif_durability = null
MR.nif_software = null
else
MR = new(mind, mind.current, 1)
@@ -114,6 +128,10 @@ var/datum/transhuman/infocore/transcore = new/datum/transhuman/infocore
var/languages
var/mind_oocnotes
var/nif_path
var/nif_durability
var/list/nif_software
/datum/transhuman/mind_record/New(var/datum/mind/mind,var/mob/living/carbon/human/M,var/obj/item/weapon/implant/backup/imp,var/add_to_db = 1)
ASSERT(mind && M && imp)
+6
View File
@@ -504,6 +504,12 @@
occupant.ooc_notes = MR.mind_oocnotes
occupant.apply_vore_prefs() //Cheap hack for now to give them SOME bellies.
//Re-supply a NIF if one was backed up with them.
if(MR.nif_path)
var/obj/item/device/nif/nif = new MR.nif_path(occupant,MR.nif_durability)
for(var/path in MR.nif_software)
new path(nif)
// If it was a custom sleeve (not owned by anyone), update namification sequences
if(!occupant.original_player)
occupant.real_name = occupant.mind.name
+15 -7
View File
@@ -23,8 +23,11 @@
#define DAMAGE_RATE_LIMIT 3 //damage rate cap at power = 300, scales linearly with power
//These would be what you would get at point blank, decreases with distance
#define DETONATION_RADS 200
// Base variants are applied to everyone on the same Z level
// Range variants are applied on per-range basis: numbers here are on point blank, it scales with the map size (assumes square shaped Z levels)
#define DETONATION_RADS 20
#define DETONATION_HALLUCINATION_BASE 300
#define DETONATION_HALLUCINATION_RANGE 300
#define DETONATION_HALLUCINATION 600
@@ -95,6 +98,11 @@
anchored = 1
grav_pulling = 1
exploded = 1
var/turf/TS = get_turf(src) // The turf supermatter is on. SM being in a locker, mecha, or other container shouldn't block it's effects that way.
if(!TS)
return
for(var/z in GetConnectedZlevels(TS.z))
radiation_repository.z_radiate(locate(1, 1, z), DETONATION_RADS, 1)
for(var/mob/living/mob in living_mob_list)
var/turf/T = get_turf(mob)
if(T && (loc.z == T.z))
@@ -102,8 +110,6 @@
//Hilariously enough, running into a closet should make you get hit the hardest.
var/mob/living/carbon/human/H = mob
H.hallucination += max(50, min(300, DETONATION_HALLUCINATION * sqrt(1 / (get_dist(mob, src) + 1)) ) )
var/rads = DETONATION_RADS * sqrt( 1 / (get_dist(mob, src) + 1) )
mob.apply_effect(rads, IRRADIATE)
spawn(pull_time)
explosion(get_turf(src), explosion_power, explosion_power * 2, explosion_power * 3, explosion_power * 4, 1)
qdel(src)
@@ -252,12 +258,15 @@
if(!istype(l.glasses, /obj/item/clothing/glasses/meson)) // VOREStation Edit - Only mesons can protect you!
l.hallucination = max(0, min(200, l.hallucination + power * config_hallucination_power * sqrt( 1 / max(1,get_dist(l, src)) ) ) )
/*
//adjusted range so that a power of 170 (pretty high) results in 9 tiles, roughly the distance from the core to the engine monitoring room.
//note that the rads given at the maximum range is a constant 0.2 - as power increases the maximum range merely increases.
for(var/mob/living/l in range(src, round(sqrt(power / 2))))
var/radius = max(get_dist(l, src), 1)
var/rads = (power / 10) * ( 1 / (radius**2) )
l.apply_effect(rads, IRRADIATE)
*/
radiation_repository.radiate(src, power * 1.5) //Better close those shutters!
power -= (power/DECAY_FACTOR)**3 //energy losses due to radiation
@@ -371,9 +380,8 @@
"<span class=\"warning\">The unearthly ringing subsides and you notice you have new radiation burns.</span>", 2)
else
l.show_message("<span class=\"warning\">You hear an uneartly ringing and notice your skin is covered in fresh radiation burns.</span>", 2)
var/rads = 500 * sqrt( 1 / (get_dist(l, src) + 1) )
l.apply_effect(rads, IRRADIATE)
var/rads = 500
radiation_repository.radiate(src, rads)
/obj/machinery/power/supermatter/proc/supermatter_pull()
//following is adapted from singulo code
+13 -11
View File
@@ -13,22 +13,22 @@
return affected && affected.open == (affected.encased ? 3 : 2) && !(affected.status & ORGAN_BLEEDING)
proc/get_max_wclass(var/obj/item/organ/external/affected)
switch (affected.name)
if ("head")
return 1
if ("upper body")
return 3
if ("lower body")
return 2
switch (affected.organ_tag)
if (BP_HEAD)
return ITEMSIZE_TINY
if (BP_TORSO)
return ITEMSIZE_NORMAL
if (BP_GROIN)
return ITEMSIZE_SMALL
return 0
proc/get_cavity(var/obj/item/organ/external/affected)
switch (affected.name)
if ("head")
switch (affected.organ_tag)
if (BP_HEAD)
return "cranial"
if ("upper body")
if (BP_TORSO)
return "thoracic"
if ("lower body")
if (BP_GROIN)
return "abdominal"
return ""
@@ -136,6 +136,7 @@
user.drop_item()
affected.implants += tool
tool.loc = affected
if(istype(tool,/obj/item/device/nif)){var/obj/item/device/nif/N = tool;N.implant(target)} //VOREStation Add - NIF support
affected.cavity = 0
//////////////////////////////////////////////////////////////////
@@ -207,6 +208,7 @@
var/obj/item/weapon/implant/imp = obj
imp.imp_in = null
imp.implanted = 0
else if(istype(tool,/obj/item/device/nif)){var/obj/item/device/nif/N = tool;N.unimplant(target)} //VOREStation Add - NIF support
else
user.visible_message("\blue [user] removes \the [tool] from [target]'s [affected.name].", \
"\blue There's something inside [target]'s [affected.name], but you just missed it this time." )
+26 -7
View File
@@ -1,5 +1,8 @@
/* SURGERY STEPS */
/obj/
var/surgery_odds = 0 // Used for tables/etc which can have surgery done of them.
/datum/surgery_step
var/priority = 0 //steps with higher priority would be attempted first
@@ -111,13 +114,29 @@
return 1
M.op_stage.in_progress += zone
S.begin_step(user, M, zone, src) //start on it
//We had proper tools! (or RNG smiled.) and user did not move or change hands.
if(prob(S.tool_quality(src)) && do_mob(user, M, rand(S.min_duration, S.max_duration)))
S.end_step(user, M, zone, src) //finish successfully
else if ((src in user.contents) && user.Adjacent(M)) //or
S.fail_step(user, M, zone, src) //malpractice~
else // This failing silently was a pain.
user << "<span class='warning'>You must remain close to your patient to conduct surgery.</span>"
var/success = TRUE
// Bad tools make it less likely to succeed.
if(!prob(S.tool_quality(src)))
success = FALSE
// Bad or no surface may mean failure as well.
var/obj/surface = M.get_surgery_surface()
if(!surface || !prob(surface.surgery_odds))
success = FALSE
// Not staying still fails you too.
if(success)
if(!do_mob(user, M, rand(S.min_duration, S.max_duration)))
success = FALSE
else
to_chat(user, "<span class='warning'>You must remain close to your patient to conduct surgery.</span>")
if(success)
S.end_step(user, M, zone, src)
else
S.fail_step(user, M, zone, src)
M.op_stage.in_progress -= zone // Clear the in-progress flag.
if (ishuman(M))
var/mob/living/carbon/human/H = M
+1
View File
@@ -10,6 +10,7 @@ var/list/table_icon_cache = list()
climbable = 1
layer = 2.8
throwpass = 1
surgery_odds = 66
var/flipped = 0
var/maxhealth = 10
var/health = 10
@@ -174,21 +174,21 @@
new /obj/item/clothing/glasses/omnihud/med/fluff/aronai(src)
//Gun and holster
new /obj/item/weapon/gun/energy/netgun(src)
new /obj/item/clothing/accessory/holster/leg(src)
new /obj/item/clothing/accessory/holster(src)
//Aerowing:Sebastian Aji
/obj/item/weapon/storage/box/fluff/sebastian_aji
name = "Sebastian's Lumoco Arms P3 Box"
has_items = list(
/obj/item/weapon/gun/projectile/pistol,
/obj/item/ammo_magazine/mc9mm/flash,
/obj/item/ammo_magazine/mc9mm/flash,
/obj/item/ammo_magazine/m9mm/flash,
/obj/item/ammo_magazine/m9mm/flash,
/obj/item/fluff/permit/sebastian_aji)
/obj/item/weapon/storage/box/fluff/briana_moore
name = "Briana's Derringer Box"
has_items = list(
/obj/item/weapon/gun/projectile/derringer,
/obj/item/weapon/gun/projectile/derringer/fluff/briana,
/obj/item/fluff/permit/briana_moore)
+52 -46
View File
@@ -67,7 +67,7 @@
item_state = "haloshotgun_i"
item_icons = null
ammo_type = /obj/item/ammo_casing/shotgun
ammo_type = /obj/item/ammo_casing/a12g
max_shells = 12
// jertheace : Jeremiah 'Ace' Acacius
@@ -75,7 +75,7 @@
name = "Ace's M45D Tactical Shotgun" // D-model holds half as many shells as the normal version so as not to be OP as shit. Better than shotgun, worse than combat shotgun.
desc = "Owned by the respected (or feared?) veteran Captain of VORE Station. Inscribed on the barrel are the words \"Speak softly, and carry a big stick.\" It has a folding stock so it can fit into bags."
w_class = ITEMSIZE_NORMAL // Because collapsable stock so it fits in backpacks.
ammo_type = /obj/item/ammo_casing/shotgun/stunshell
ammo_type = /obj/item/ammo_casing/a12g/stunshell
max_shells = 6
// bwoincognito:Tasald Corlethian
@@ -146,7 +146,7 @@
icon_state = "jury"
item_state = "gun"
accuracy = 0 // Because I know you're not an idiot who needs to be nerfed. -Ace
ammo_type = /obj/item/ammo_casing/shotgun/beanbag
ammo_type = /obj/item/ammo_casing/a12g/beanbag
// Dhaeleena : Dhaeleena M'iar
/obj/item/weapon/gun/projectile/revolver/mateba/fluff/dhael
@@ -166,8 +166,14 @@
icon_state = "model10"
fire_sound = 'sound/weapons/deagle.ogg'
origin_tech = list(TECH_COMBAT = 2, TECH_MATERIAL = 2)
ammo_type = /obj/item/ammo_casing/c38r //Rubber rounds.
ammo_type = /obj/item/ammo_casing/a38r //Rubber rounds.
// LuminescentRing : Briana Moore
/obj/item/weapon/gun/projectile/derringer/fluff/briana
name = "second-hand derringer"
desc = "It's a palm sized gun. One of the few things that won't break an angel's wrists."
caliber = "10mm"
ammo_type = /obj/item/ammo_casing/a10mm
// For general use
/obj/item/weapon/gun/projectile/automatic/stg
@@ -180,8 +186,8 @@
max_shells = 30
caliber = "kurz"
origin_tech = list(TECH_COMBAT = 4, TECH_MATERIAL = 2, TECH_ILLEGAL = 6)
magazine_type = /obj/item/ammo_magazine/stg
allowed_magazines = list(/obj/item/ammo_magazine/stg)
magazine_type = /obj/item/ammo_magazine/mtg
allowed_magazines = list(/obj/item/ammo_magazine/mtg)
load_method = MAGAZINE
/obj/item/weapon/gun/projectile/automatic/stg/update_icon(var/ignore_inhands)
@@ -238,8 +244,8 @@
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 2)
slot_flags = SLOT_BELT
load_method = MAGAZINE
magazine_type = /obj/item/ammo_magazine/mc9mml
allowed_magazines = list(/obj/item/ammo_magazine/mc9mm, /obj/item/ammo_magazine/mc9mml)
magazine_type = /obj/item/ammo_magazine/m9mml
allowed_magazines = list(/obj/item/ammo_magazine/m9mm, /obj/item/ammo_magazine/m9mml)
firemodes = list(
list(mode_name="semiauto", burst=1, fire_delay=0, move_delay=null, burst_accuracy=null, dispersion=null),
@@ -248,7 +254,7 @@
/obj/item/weapon/gun/projectile/automatic/pdw/update_icon(var/ignore_inhands)
..()
if(istype(ammo_magazine,/obj/item/ammo_magazine/mc9mm))
if(istype(ammo_magazine,/obj/item/ammo_magazine/m9mm))
icon_state = "pdw-short"
else
icon_state = (ammo_magazine)? "pdw" : "pdw-empty"
@@ -279,8 +285,8 @@
auto_eject_sound = 'sound/weapons/smg_empty_alarm.ogg'
hitsound = null
caliber = "s762"
magazine_type = /obj/item/ammo_magazine/s762
allowed_magazines = list(/obj/item/ammo_magazine/s762)
magazine_type = /obj/item/ammo_magazine/m762
allowed_magazines = list(/obj/item/ammo_magazine/m762)
/obj/item/weapon/gun/projectile/automatic/fluff/crestrose/attack_self(mob/user as mob)
on = !on
@@ -379,7 +385,7 @@
/obj/item/weapon/gun/projectile/automatic/carbine/fluff/g44/update_icon(var/ignore_inhands)
..()
// TODO - Fix this for spriting different size magazines
// TODO - Fix this for spriting different size magazines
icon_state = (ammo_magazine)? "g44" : "g44-empty"
item_state = (ammo_magazine)? "bullpup" : "bullpup-empty"
if(!ignore_inhands) update_held_icon()
@@ -462,8 +468,8 @@
icon = 'icons/obj/gun_vr.dmi'
icon_state = "khipistol"
item_state = "gun" // Placeholder
magazine_type = /obj/item/ammo_magazine/c45m/flash //Dun wanna KILL all the people.
allowed_magazines = list(/obj/item/ammo_magazine/c45m)
magazine_type = /obj/item/ammo_magazine/m45/flash //Dun wanna KILL all the people.
allowed_magazines = list(/obj/item/ammo_magazine/m45)
caliber = ".45"
handle_casings = CYCLE_CASINGS
origin_tech = list(TECH_COMBAT = 5, TECH_MATERIAL = 5)
@@ -485,8 +491,8 @@
slot_flags = SLOT_BELT
load_method = MAGAZINE
handle_casings = CYCLE_CASINGS
magazine_type = /obj/item/ammo_magazine/mc9mml
allowed_magazines = list(/obj/item/ammo_magazine/mc9mm, /obj/item/ammo_magazine/mc9mml)
magazine_type = /obj/item/ammo_magazine/m9mml
allowed_magazines = list(/obj/item/ammo_magazine/m9mm, /obj/item/ammo_magazine/m9mml)
dna_lock = 1
firemodes = list(
@@ -583,8 +589,8 @@
caliber = ".44"
ammo_type = /obj/item/ammo_casing/a44/rubber
magazine_type = /obj/item/ammo_magazine/a44/rubber
allowed_magazines = list(/obj/item/ammo_magazine/a44,/obj/item/ammo_magazine/a44/rubber)
magazine_type = /obj/item/ammo_magazine/m44/rubber
allowed_magazines = list(/obj/item/ammo_magazine/m44,/obj/item/ammo_magazine/m44/rubber)
load_method = MAGAZINE
auto_eject = 1
auto_eject_sound = 'sound/weapons/smg_empty_alarm.ogg'
@@ -610,8 +616,8 @@
caliber = ".32"
ammo_type = /obj/item/ammo_casing/a32
magazine_type = /obj/item/ammo_magazine/a32
allowed_magazines = list(/obj/item/ammo_magazine/a32)
magazine_type = /obj/item/ammo_magazine/m32
allowed_magazines = list(/obj/item/ammo_magazine/m32)
load_method = MAGAZINE
fire_delay = 0.6
accuracy = 1
@@ -639,8 +645,8 @@
caliber = ".32"
ammo_type = /obj/item/ammo_casing/a32
magazine_type = /obj/item/ammo_magazine/a32
allowed_magazines = list(/obj/item/ammo_magazine/a32)
magazine_type = /obj/item/ammo_magazine/m32
allowed_magazines = list(/obj/item/ammo_magazine/m32)
fire_delay = 1.2
load_method = MAGAZINE
accuracy = 2
@@ -699,9 +705,9 @@
slot_flags = SLOT_BELT
caliber = "9mm"
ammo_type = /obj/item/ammo_casing/c9mm
magazine_type = /obj/item/ammo_magazine/c9mm
allowed_magazines = list(/obj/item/ammo_magazine/c9mm)
ammo_type = /obj/item/ammo_casing/a9mm
magazine_type = /obj/item/ammo_magazine/m9mm
allowed_magazines = list(/obj/item/ammo_magazine/m9mm)
load_method = MAGAZINE
multi_aim = 1
burst_delay = 2
@@ -866,7 +872,7 @@
impact_type = /obj/effect/projectile/laser_omni/impact
//--------------- StG-60 ----------------
/obj/item/ammo_magazine/stg
/obj/item/ammo_magazine/mtg
name = "box mag (7.92x33mm Kurz)"
icon = 'icons/obj/ammo_vr.dmi'
icon_state = "stg_30rnd"
@@ -881,7 +887,7 @@
caliber = "kurz"
projectile_type = /obj/item/projectile/bullet/rifle/a762
/obj/item/ammo_magazine/stg/empty
/obj/item/ammo_magazine/mtg/empty
initial_ammo = 0
//------------- Battlerifle -------------
@@ -909,7 +915,7 @@
initial_ammo = 0
//---------------- PDW ------------------
/obj/item/ammo_magazine/mc9mml
/obj/item/ammo_magazine/m9mml
name = "\improper SMG magazine (9mm)"
icon = 'icons/obj/ammo_vr.dmi'
icon_state = "smg"
@@ -917,31 +923,31 @@
mag_type = MAGAZINE
matter = list(DEFAULT_WALL_MATERIAL = 1800)
caliber = "9mm"
ammo_type = /obj/item/ammo_casing/c9mm
ammo_type = /obj/item/ammo_casing/a9mm
max_ammo = 30
multiple_sprites = 1
/obj/item/ammo_magazine/mc9mml/empty
/obj/item/ammo_magazine/m9mml/empty
initial_ammo = 0
/obj/item/ammo_magazine/mc9mml/ap
/obj/item/ammo_magazine/m9mml/ap
name = "\improper SMG magazine (9mm armor-piercing)"
ammo_type = /obj/item/ammo_casing/c9mm/ap
ammo_type = /obj/item/ammo_casing/a9mm/ap
/obj/item/ammo_magazine/mc9mml/flash
/obj/item/ammo_magazine/m9mml/flash
name = "\improper SMG magazine (9mm flash)"
ammo_type = /obj/item/ammo_casing/c9mmf
ammo_type = /obj/item/ammo_casing/a9mmf
/obj/item/ammo_magazine/mc9mml/rubber
/obj/item/ammo_magazine/m9mml/rubber
name = "\improper SMG magazine (9mm rubber)"
ammo_type = /obj/item/ammo_casing/c9mmr
ammo_type = /obj/item/ammo_casing/a9mmr
/obj/item/ammo_magazine/mc9mml/practice
/obj/item/ammo_magazine/m9mml/practice
name = "\improper SMG magazine (9mm practice)"
ammo_type = /obj/item/ammo_casing/c9mmp
ammo_type = /obj/item/ammo_casing/a9mmp
//.357 special ammo
/obj/item/ammo_magazine/a357/stun
/obj/item/ammo_magazine/m357/stun
name = "speedloader (.357 stun)"
desc = "A speedloader for .357 revolvers."
icon = 'icons/obj/ammo_vr.dmi'
@@ -957,7 +963,7 @@
icon_state = "stun357"
projectile_type = /obj/item/projectile/energy/electrode/stunshot/strong
/obj/item/ammo_magazine/a357/rubber
/obj/item/ammo_magazine/m357/rubber
name = "speedloader (.357 rubber)"
desc = "A speedloader for .357 revolvers."
icon = 'icons/obj/ammo_vr.dmi'
@@ -973,7 +979,7 @@
icon_state = "rubber357"
projectile_type = /obj/item/projectile/bullet/pistol/rubber/strong
/obj/item/ammo_magazine/a357/flash
/obj/item/ammo_magazine/m357/flash
name = "speedloader (.357 flash)"
desc = "A speedloader for .357 revolvers."
icon = 'icons/obj/ammo_vr.dmi'
@@ -995,7 +1001,7 @@
caliber = ".32"
projectile_type = /obj/item/projectile/bullet/pistol
/obj/item/ammo_magazine/a32
/obj/item/ammo_magazine/m32
icon_state = "a762"
caliber = ".32"
ammo_type = /obj/item/ammo_casing/a32
@@ -1016,7 +1022,7 @@
desc = "A .44 rubber bullet casing."
projectile_type = /obj/item/projectile/bullet/pistol/rubber/strong
/obj/item/ammo_magazine/a44
/obj/item/ammo_magazine/m44
desc = "A magazine for .44 ammo."
icon = 'icons/obj/ammo_vr.dmi'
icon_state = "44lethal"
@@ -1026,13 +1032,13 @@
max_ammo = 8
mag_type = MAGAZINE
/obj/item/ammo_magazine/a44/rubber
/obj/item/ammo_magazine/m44/rubber
desc = "A magazine for .44 less-than-lethal ammo."
icon_state = "44rubber"
ammo_type = /obj/item/ammo_casing/a44/rubber
//.44 speedloaders
/obj/item/ammo_magazine/a44sl
/obj/item/ammo_magazine/m44sl
name = "speedloader (.44)"
desc = "A speedloader for .44 revolvers."
icon = 'icons/obj/ammo_vr.dmi'
@@ -1044,7 +1050,7 @@
multiple_sprites = 1
mag_type = SPEEDLOADER
/obj/item/ammo_magazine/a44sl/rubber
/obj/item/ammo_magazine/m44sl/rubber
name = "speedloader (.44 rubber)"
icon_state = "r357"
ammo_type = /obj/item/ammo_casing/a44/rubber
@@ -710,6 +710,127 @@ obj/item/weapon/material/hatchet/tacknife/combatknife/fluff/katarina/handle_shie
do_reagent_implant(usr)
//SpoopyLizz: Roiz Lizden
//I made this! Woo!
//implant
//--------------------
/obj/item/weapon/implant/reagent_generator/roiz
name = "egg laying implant"
desc = "This is an implant that allows the user to lay eggs."
generated_reagent = "egg"
usable_volume = 500
transfer_amount = 50
empty_message = list("Your lower belly feels smooth and empty. Sorry, we're out of eggs!", "The reduced pressure in your lower belly tells you there are no more eggs.")
full_message = list("Your lower belly looks swollen with irregular bumps, and it feels heavy.", "Your lower abdomen feels really heavy, making it a bit hard to walk.")
emote_descriptor = list("an egg right out of Roiz's lower belly!", "into Roiz' belly firmly, forcing him to lay an egg!", "Roiz really tight, who promptly lays an egg!")
var/verb_descriptor = list("squeezes", "pushes", "hugs")
var/self_verb_descriptor = list("squeeze", "push", "hug")
var/short_emote_descriptor = list("lays", "forces out", "pushes out")
self_emote_descriptor = list("lay", "force out", "push out")
random_emote = list("hisses softly with a blush on his face", "yelps in embarrassment", "grunts a little")
assigned_proc = /mob/living/carbon/human/proc/use_reagent_implant_roiz
/obj/item/weapon/implanter/reagent_generator/roiz
implant_type = /obj/item/weapon/implant/reagent_generator/roiz
/mob/living/carbon/human/proc/use_reagent_implant_roiz()
set name = "Lay Egg"
set desc = "Force Roiz to lay an egg by squeezing into his lower body! This makes the lizard extremely embarrassed, and it looks funny."
set category = "Object"
set src in view(1)
//do_reagent_implant(usr)
if(!isliving(usr) || !usr.canClick())
return
if(usr.incapacitated() || usr.stat > CONSCIOUS)
return
var/obj/item/weapon/implant/reagent_generator/roiz/rimplant
for(var/I in src.contents)
if(istype(I, /obj/item/weapon/implant/reagent_generator))
rimplant = I
break
if (rimplant)
if(rimplant.reagents.total_volume <= rimplant.transfer_amount)
to_chat(src, "<span class='notice'>[pick(rimplant.empty_message)]</span>")
return
new /obj/item/weapon/reagent_containers/food/snacks/egg/roiz(get_turf(src))
var/index = rand(0,3)
if (usr != src)
var/emote = rimplant.emote_descriptor[index]
var/verb_desc = rimplant.verb_descriptor[index]
var/self_verb_desc = rimplant.self_verb_descriptor[index]
usr.visible_message("<span class='notice'>[usr] [verb_desc] [emote]</span>",
"<span class='notice'>You [self_verb_desc] [emote]</span>")
else
src.visible_message("<span class='notice'>[src] [pick(rimplant.short_emote_descriptor)] an egg.</span>",
"<span class='notice'>You [pick(rimplant.self_emote_descriptor)] an egg.</span>")
if(prob(15))
src.visible_message("<span class='notice'>[src] [pick(rimplant.random_emote)].</span>") // M-mlem.
rimplant.reagents.remove_reagent(rimplant.generated_reagent, rimplant.transfer_amount)
//Egg item
//-------------
/obj/item/weapon/reagent_containers/food/snacks/egg/roiz
name = "lizard egg"
desc = "It's a large lizard egg."
icon = 'icons/vore/custom_items_vr.dmi'
icon_state = "egg_roiz"
filling_color = "#FDFFD1"
volume = 12
/obj/item/weapon/reagent_containers/food/snacks/egg/roiz/New()
..()
reagents.add_reagent("egg", 9)
bitesize = 4
/obj/item/weapon/reagent_containers/food/snacks/friedegg/roiz
name = "fried lizard egg"
desc = "A large, fried lizard egg, with a touch of salt and pepper. It looks rather chewy."
icon = 'icons/vore/custom_items_vr.dmi'
icon_state = "friedegg"
volume = 12
/obj/item/weapon/reagent_containers/food/snacks/friedegg/roiz/New()
..()
reagents.add_reagent("protein", 9)
bitesize = 4
/obj/item/weapon/reagent_containers/food/snacks/boiledegg/roiz
name = "boiled lizard egg"
desc = "A hard boiled lizard egg. Be careful, a lizard detective may hatch!"
icon = 'icons/vore/custom_items_vr.dmi'
icon_state = "egg_roiz"
volume = 12
/obj/item/weapon/reagent_containers/food/snacks/boiledegg/roiz/New()
..()
reagents.add_reagent("protein", 6)
bitesize = 4
/obj/item/weapon/reagent_containers/food/snacks/chocolateegg/roiz
name = "chocolate lizard egg"
desc = "Such huge, sweet, fattening food."
icon = 'icons/vore/custom_items_vr.dmi'
icon_state = "chocolateegg_roiz"
filling_color = "#7D5F46"
nutriment_amt = 3
nutriment_desc = list("chocolate" = 5)
volume = 18
/obj/item/weapon/reagent_containers/food/snacks/chocolateegg/roiz/New()
..()
reagents.add_reagent("sugar", 6)
reagents.add_reagent("coco", 6)
reagents.add_reagent("milk", 2)
bitesize = 6
//PontifexMinimus: Lucius/Lucia Null
/obj/item/weapon/fluff/dragor_dot
name = "supplemental battery"
@@ -1089,3 +1210,30 @@ obj/item/weapon/material/hatchet/tacknife/combatknife/fluff/katarina/handle_shie
B.internal_contents |= src
user.visible_message("<span class='warning'>[user] eats a telebeacon!</span>","You eat the the beacon!")
playsound(user, B.vore_sound, 70, 1)
//InterroLouis: Ruda Lizden
/obj/item/clothing/accessory/badge/holo/detective/ruda
name = "Hisstective's Badge"
desc = "This is Ruda Lizden's personal Detective's badge. The polish is dull, as if it's simply been huffed upon and wiped against a coat. Labeled 'Hisstective.'"
icon = 'icons/vore/custom_items_vr.dmi'
icon_state = "hisstective_badge"
//slot_flags = SLOT_TIE | SLOT_BELT
/obj/item/clothing/accessory/badge/holo/detective/ruda/attack(mob/living/carbon/human/M, mob/living/user)
if(isliving(user))
user.visible_message("<span class='danger'>[user] invades [M]'s personal space, thrusting [src] into their face with an insistent huff.</span>","<span class='danger'>You invade [M]'s personal space, thrusting [src] into their face with an insistent huff.</span>")
user.do_attack_animation(M)
user.setClickCooldown(DEFAULT_QUICK_COOLDOWN) //to prevent spam
/obj/item/clothing/accessory/badge/holo/detective/ruda/attack_self(mob/user as mob)
if(!stored_name)
user << "You huff along the front of your badge, then rub your sleeve on it to polish it up."
set_name(user.real_name)
return
if(isliving(user))
if(stored_name)
user.visible_message("<span class='notice'>[user] displays their [src.name].\nIt reads: [stored_name], [badge_string].</span>","<span class='notice'>You display your [src.name].\nIt reads: [stored_name], [badge_string].</span>")
else
user.visible_message("<span class='notice'>[user] displays their [src.name].\nIt reads: [badge_string].</span>","<span class='notice'>You display your [src.name]. It reads: [badge_string].</span>")
+82 -32
View File
@@ -35,6 +35,32 @@
persist_interround_data(Player, /datum/spawnpoint/cryo)
return 1
/**
* Prep for save: returns a preferences object if we're ready and allowed to save this mob.
*/
/proc/prep_for_persist(var/mob/persister)
ASSERT(istype(persister))
// Find out of this mob is a proper mob!
if (persister.mind && persister.mind.loaded_from_ckey)
// Okay this mob has a real loaded-from-savefile mind in it!
var/datum/preferences/prefs = preferences_datums[persister.mind.loaded_from_ckey]
if(!prefs)
WARNING("mind [persister.mind] was loaded from ckey [persister.mind.loaded_from_ckey] but no prefs datum found")
return
// Okay, lets do a few checks to see if we should really save tho!
if(!prefs.load_character(persister.mind.loaded_from_slot))
WARNING("mind [persister.mind] was loaded from slot [persister.mind.loaded_from_slot] but loading prefs failed.")
return // Failed to load character
// For now as a safety measure we will only save if the name matches.
if(prefs.real_name != persister.real_name)
log_debug("Skipping persist for [persister] becuase [persister.real_name] != [prefs.real_name]")
return
return prefs
/**
* Called when mob despawns early (via cryopod)!
*/
@@ -47,42 +73,33 @@
/proc/persist_interround_data(var/mob/occupant, var/datum/spawnpoint/new_spawn_point_type)
ASSERT(istype(occupant))
// Find out of this mob is a proper mob!
if (occupant.mind && occupant.mind.loaded_from_ckey)
// Okay this mob has a real loaded-from-savefile mind in it!
var/datum/preferences/prefs = preferences_datums[occupant.mind.loaded_from_ckey]
if(!prefs)
WARNING("mind [occupant.mind] was loaded from ckey [occupant.mind.loaded_from_ckey] but no prefs datum found")
return
var/datum/preferences/prefs = prep_for_persist(occupant)
if(!prefs)
WARNING("persist_interround_data failed to prep [occupant] for persisting")
return
// Okay, lets do a few checks to see if we should really save tho!
if(!prefs.load_character(occupant.mind.loaded_from_slot))
WARNING("mind [occupant.mind] was loaded from slot [occupant.mind.loaded_from_slot] but loading prefs failed.")
return // Failed to load character
//This one doesn't rely on persistence prefs
if(ishuman(occupant) && occupant.stat != DEAD)
persist_nif_data(occupant, prefs)
// For now as a safety measure we will only save if the name matches.
if(prefs.real_name != occupant.real_name)
log_debug("Skipping persist for [occupant] becuase [occupant.real_name] != [prefs.real_name]")
return
if(!prefs.persistence_settings)
return // Persistence disabled by preference settings
if(!prefs.persistence_settings)
return // Persistence disabled by preference settings
// Okay we can start saving the data
if(new_spawn_point_type && prefs.persistence_settings & PERSIST_SPAWN)
prefs.spawnpoint = initial(new_spawn_point_type.display_name)
if(ishuman(occupant) && occupant.stat != DEAD)
var/mob/living/carbon/human/H = occupant
testing("About to try saving stuff from [H] to [prefs] (\ref[prefs])")
if(prefs.persistence_settings & PERSIST_ORGANS)
apply_organs_to_prefs(H, prefs)
if(prefs.persistence_settings & PERSIST_MARKINGS)
apply_markings_to_prefs(H, prefs)
if(prefs.persistence_settings & PERSIST_WEIGHT)
resolve_excess_nutrition(H)
prefs.weight_vr = H.weight
// Okay we can start saving the data
if(new_spawn_point_type && prefs.persistence_settings & PERSIST_SPAWN)
prefs.spawnpoint = initial(new_spawn_point_type.display_name)
if(ishuman(occupant) && occupant.stat != DEAD)
var/mob/living/carbon/human/H = occupant
testing("About to try saving stuff from [H] to [prefs] (\ref[prefs])")
if(prefs.persistence_settings & PERSIST_ORGANS)
apply_organs_to_prefs(H, prefs)
if(prefs.persistence_settings & PERSIST_MARKINGS)
apply_markings_to_prefs(H, prefs)
if(prefs.persistence_settings & PERSIST_WEIGHT)
resolve_excess_nutrition(H)
prefs.weight_vr = H.weight
prefs.save_character()
return
prefs.save_character()
// Saves mob's current coloration state to prefs
// This basically needs to be the reverse of /datum/category_item/player_setup_item/general/body/copy_to_mob() ~Leshana
@@ -194,3 +211,36 @@
// Weight Loss!
var/loss = (MAX_NUTRITION_TO_LOSE - C.nutrition) * weight_per_nutrition * C.weight_loss/100
C.weight = max(MIN_MOB_WEIGHT, C.weight - loss)
/**
* Persist any NIF data that needs to be persisted. It's stored in a list to make it more malleable
* towards future shenanigans such as upgradable NIFs or different types or things of that nature,
* without invoking the need for a bunch of different save file variables.
*/
/proc/persist_nif_data(var/mob/living/carbon/human/H,var/datum/preferences/prefs)
if(!istype(H))
CRASH("persist_nif_data given a nonhuman: [H]")
if(!prefs)
prefs = prep_for_persist(H)
if(!prefs)
WARNING("persist_nif_data failed to prep [H] for persisting")
return
var/obj/item/device/nif/nif = H.nif
if(nif)
prefs.nif_path = nif.type
prefs.nif_durability = nif.durability
else
prefs.nif_path = null
prefs.nif_durability = null
var/datum/category_group/player_setup_category/vore_cat = prefs.player_setup.categories_by_name["VORE"]
var/datum/category_item/player_setup_item/vore/nif/nif_prefs = vore_cat.items_by_name["NIF Data"]
var/savefile/S = new /savefile(prefs.path)
if(!S) WARNING ("Couldn't load NIF save savefile? [prefs.real_name]")
S.cd = "/character[prefs.default_slot]"
nif_prefs.save_character(S)
@@ -15,16 +15,10 @@
/datum/artifact_effect/radiate/DoEffectAura()
if(holder)
var/turf/T = get_turf(holder)
for (var/mob/living/M in range(src.effectrange,T))
M.apply_effect(radiation_amount,IRRADIATE,0)
M.updatehealth()
radiation_repository.flat_radiate(holder, radiation_amount, src.effectrange)
return 1
/datum/artifact_effect/radiate/DoEffectPulse()
if(holder)
var/turf/T = get_turf(holder)
for (var/mob/living/M in range(src.effectrange,T))
M.apply_effect(radiation_amount * 25,IRRADIATE,0)
M.updatehealth()
radiation_repository.radiate(holder, ((radiation_amount * 25) * (sqrt(src.effectrange)))) //Need to get feedback on this
return 1
@@ -198,8 +198,7 @@
radiation = rand() * 15 + 85
if(!rad_shield)
//irradiate nearby mobs
for(var/mob/living/M in view(7,src))
M.apply_effect(radiation / 25, IRRADIATE, 0)
radiation_repository.radiate(src, radiation / 25)
else
t_left_radspike = pick(10,15,25)
@@ -361,4 +360,4 @@
scanned_item = null
add_fingerprint(usr)
return 1 // update UIs attached to this object
return 1 // update UIs attached to this object