Master got fixed while I was at work!
This commit is contained in:
@@ -303,7 +303,7 @@ GLOBAL_DATUM_INIT(sdql2_vv_statobj, /obj/effect/statclick/SDQL2_VV_all, new(null
|
||||
//These three are weird. For best performance, they are only a number when they're not being changed by the SDQL searching/execution code. They only become numbers when they finish changing.
|
||||
var/list/obj_count_all
|
||||
var/list/obj_count_eligible
|
||||
var/list/obj_count_finished
|
||||
var/obj_count_finished
|
||||
|
||||
//Statclick
|
||||
var/obj/effect/statclick/SDQL2_delete/delete_click
|
||||
@@ -682,7 +682,7 @@ GLOBAL_DATUM_INIT(sdql2_vv_statobj, /obj/effect/statclick/SDQL2_VV_all, new(null
|
||||
SDQL2_TICK_CHECK
|
||||
SDQL2_HALT_CHECK
|
||||
if(islist(obj_count_finished))
|
||||
obj_count_finished = obj_count_finished.len
|
||||
obj_count_finished = length(obj_count_finished)
|
||||
state = SDQL2_STATE_SWITCHING
|
||||
|
||||
/datum/SDQL2_query/proc/SDQL_print(object, list/text_list, print_nulls = TRUE)
|
||||
|
||||
@@ -487,7 +487,7 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention)
|
||||
if(alert("This mob is being controlled by [M.key]. Are you sure you wish to assume control of it? [M.key] will be made a ghost.",,"Yes","No") != "Yes")
|
||||
return
|
||||
else
|
||||
var/mob/dead/observer/ghost = new/mob/dead/observer(M,1)
|
||||
var/mob/dead/observer/ghost = new/mob/dead/observer(get_turf(M), M)
|
||||
ghost.ckey = M.ckey
|
||||
message_admins("<span class='adminnotice'>[key_name_admin(usr)] assumed direct control of [M].</span>")
|
||||
log_admin("[key_name(usr)] assumed direct control of [M].")
|
||||
|
||||
@@ -135,7 +135,7 @@ GLOBAL_LIST_EMPTY(dirty_vars)
|
||||
if(!(locate(/obj/structure/grille) in T))
|
||||
var/window_check = 0
|
||||
for(var/obj/structure/window/W in T)
|
||||
if (W.dir == turn(C1.dir,180) || W.dir in list(5,6,9,10) )
|
||||
if(W.dir == turn(C1.dir,180) || (W.dir in list(5,6,9,10)))
|
||||
window_check = 1
|
||||
break
|
||||
if(!window_check)
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
continue
|
||||
if(ishostile(L))
|
||||
var/mob/living/simple_animal/hostile/H = L
|
||||
if(("ratvar" in H.faction) || (!H.mind && "neutral" in H.faction))
|
||||
if(("ratvar" in H.faction) || (!H.mind && ("neutral" in H.faction)))
|
||||
continue
|
||||
if(ismegafauna(H) || (!H.mind && H.AIStatus == AI_OFF))
|
||||
continue
|
||||
|
||||
@@ -36,6 +36,8 @@
|
||||
var/price = 0
|
||||
for(var/x in ex.total_amount)
|
||||
price += ex.total_value[x]
|
||||
for(var/x in ex.reagents_value)
|
||||
price += ex.reagents_value[x]
|
||||
|
||||
if(price)
|
||||
to_chat(user, "<span class='notice'>Scanned [O], value: <b>[price]</b> credits[O.contents.len ? " (contents included)" : ""].</span>")
|
||||
|
||||
@@ -49,13 +49,13 @@ Credit dupes that require a lot of manual work shouldn't be removed, unless they
|
||||
sold = E.sell_object(thing, report, dry_run, allowed_categories , apply_elastic)
|
||||
report.exported_atoms += " [thing.name]"
|
||||
break
|
||||
if(thing.reagents)
|
||||
if(thing.reagents?.value_multiplier)
|
||||
for(var/A in thing.reagents.reagent_list)
|
||||
var/datum/reagent/R = A
|
||||
if(!R.value)
|
||||
continue
|
||||
report.reagents_volume[R.name] += R.volume
|
||||
report.reagents_value[R.name] += R.volume * R.value
|
||||
report.reagents_value[R.name] += round(R.volume * R.value * thing.reagents.value_multiplier)
|
||||
if(!dry_run && (sold || delete_unsold))
|
||||
if(ismob(thing))
|
||||
thing.investigate_log("deleted through cargo export",INVESTIGATE_CARGO)
|
||||
|
||||
@@ -65,6 +65,9 @@ GLOBAL_LIST_INIT(hallucination_list, list(
|
||||
|
||||
//Returns a random turf in a ring around the target mob, useful for sound hallucinations
|
||||
/datum/hallucination/proc/random_far_turf()
|
||||
var/turf/target_T = get_turf(target)
|
||||
if(!target_T)
|
||||
return
|
||||
var/x_based = prob(50)
|
||||
var/first_offset = pick(-8,-7,-6,-5,5,6,7,8)
|
||||
var/second_offset = rand(-8,8)
|
||||
@@ -76,7 +79,7 @@ GLOBAL_LIST_INIT(hallucination_list, list(
|
||||
else
|
||||
y_off = first_offset
|
||||
x_off = second_offset
|
||||
var/turf/T = locate(target.x + x_off, target.y + y_off, target.z)
|
||||
var/turf/T = locate(target_T.x + x_off, target_T.y + y_off, target_T.z)
|
||||
return T
|
||||
|
||||
/obj/effect/hallucination
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
lefthand_file = 'icons/mob/inhands/misc/food_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/misc/food_righthand.dmi'
|
||||
reagent_flags = OPENCONTAINER
|
||||
reagent_value = DEFAULT_REAGENTS_VALUE
|
||||
var/gulp_size = 5 //This is now officially broken ... need to think of a nice way to fix it.
|
||||
possible_transfer_amounts = list(5,10,15,20,25,30,50)
|
||||
volume = 50
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
possible_transfer_amounts = list()
|
||||
volume = 50 //Sets the default container amount for all food items.
|
||||
reagent_flags = INJECTABLE
|
||||
reagent_value = NO_REAGENTS_VALUE
|
||||
resistance_flags = FLAMMABLE
|
||||
var/foodtype = NONE
|
||||
var/last_check_time
|
||||
|
||||
@@ -71,10 +71,11 @@ All foods are distributed among various categories. Use common sense.
|
||||
if(!eater)
|
||||
return
|
||||
if(!reagents.total_volume)
|
||||
var/obj/item/trash_item = generate_trash(eater)
|
||||
var/mob/living/location = loc
|
||||
var/obj/item/trash_item = generate_trash(location)
|
||||
qdel(src)
|
||||
eater.put_in_hands(trash_item)
|
||||
|
||||
if(istype(location))
|
||||
location.put_in_hands(trash_item)
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/attack_self(mob/user)
|
||||
return
|
||||
@@ -245,7 +246,7 @@ All foods are distributed among various categories. Use common sense.
|
||||
return TRUE
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/proc/initialize_slice(obj/item/reagent_containers/food/snacks/slice, reagents_per_slice)
|
||||
slice.create_reagents(slice.volume)
|
||||
slice.create_reagents(slice.volume, reagent_flags, reagent_value)
|
||||
reagents.trans_to(slice,reagents_per_slice)
|
||||
if(name != initial(name))
|
||||
slice.name = "slice of [name]"
|
||||
@@ -279,7 +280,7 @@ All foods are distributed among various categories. Use common sense.
|
||||
|
||||
// initialize_cooked_food() is called when microwaving the food
|
||||
/obj/item/reagent_containers/food/snacks/proc/initialize_cooked_food(obj/item/reagent_containers/food/snacks/S, cooking_efficiency = 1)
|
||||
S.create_reagents(S.volume)
|
||||
S.create_reagents(S.volume, reagent_flags, reagent_value)
|
||||
if(reagents)
|
||||
reagents.trans_to(S, reagents.total_volume)
|
||||
if(S.bonus_reagents && S.bonus_reagents.len)
|
||||
|
||||
@@ -212,7 +212,7 @@
|
||||
meatslab.throw_at(pick(nearby_turfs),i,3)
|
||||
for (var/turfs=1 to meat_produced)
|
||||
var/turf/gibturf = pick(nearby_turfs)
|
||||
if (!gibturf.density && src in view(gibturf))
|
||||
if (!gibturf.density && (src in view(gibturf)))
|
||||
new gibtype(gibturf,i,diseases)
|
||||
|
||||
pixel_x = initial(pixel_x) //return to its spot after shaking
|
||||
|
||||
@@ -220,7 +220,7 @@
|
||||
unprocess()
|
||||
qdel(src)
|
||||
if(!bomb_active || bomb_defused)
|
||||
if(bomb_defused && bomb in src)
|
||||
if(bomb_defused && (bomb in src))
|
||||
bomb.defuse()
|
||||
bomb_active = FALSE
|
||||
unprocess()
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
// Saves us from having to define each stupid grown's dried_type as itself.
|
||||
// If you don't want a plant to be driable (watermelons) set this to null in the time definition.
|
||||
resistance_flags = FLAMMABLE
|
||||
reagent_value = HARVEST_REAGENTS_VALUE
|
||||
var/dry_grind = FALSE //If TRUE, this object needs to be dry to be ground up
|
||||
var/can_distill = TRUE //If FALSE, this object cannot be distilled into an alcohol.
|
||||
var/distill_reagent //If NULL and this object can be distilled, it uses a generic fruit_wine reagent and adjusts its variables.
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
/obj/item/grown/Initialize(newloc, obj/item/seeds/new_seed)
|
||||
. = ..()
|
||||
create_reagents(50)
|
||||
create_reagents(50, NONE, HARVEST_REAGENTS_VALUE)
|
||||
|
||||
if(new_seed)
|
||||
seed = new_seed.Copy()
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
write_data_to_pin(new_data)
|
||||
|
||||
/datum/integrated_io/dir/write_data_to_pin(var/new_data)
|
||||
if(isnull(new_data) || new_data in list(NORTH, SOUTH, EAST, WEST, NORTHEAST, NORTHWEST, SOUTHEAST, SOUTHWEST)/* + list(UP, DOWN)*/)
|
||||
if(isnull(new_data) || (new_data in GLOB.alldirs/* + list(UP, DOWN)*/))
|
||||
data = new_data
|
||||
holder.on_data_written()
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ GLOBAL_PROTECT(exp_to_update)
|
||||
return exp_type
|
||||
|
||||
/proc/job_is_xp_locked(jobtitle)
|
||||
if(!CONFIG_GET(flag/use_exp_restrictions_heads) && jobtitle in (GLOB.command_positions | list("AI")))
|
||||
if(!CONFIG_GET(flag/use_exp_restrictions_heads) && (jobtitle in (GLOB.command_positions | list("AI"))))
|
||||
return FALSE
|
||||
if(!CONFIG_GET(flag/use_exp_restrictions_other) && !(jobtitle in (GLOB.command_positions | list("AI"))))
|
||||
return FALSE
|
||||
|
||||
@@ -55,7 +55,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
var/deadchat_name
|
||||
var/datum/spawners_menu/spawners_menu
|
||||
|
||||
/mob/dead/observer/Initialize()
|
||||
/mob/dead/observer/Initialize(mapload, mob/body)
|
||||
set_invisibility(GLOB.observer_default_invisibility)
|
||||
|
||||
verbs += list(
|
||||
@@ -76,11 +76,7 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
|
||||
updateallghostimages()
|
||||
|
||||
var/turf/T
|
||||
var/mob/body = loc
|
||||
if(ismob(body))
|
||||
T = get_turf(body) //Where is the body located?
|
||||
|
||||
if(body)
|
||||
gender = body.gender
|
||||
if(body.mind && body.mind.name)
|
||||
name = body.mind.name
|
||||
@@ -105,14 +101,15 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
|
||||
update_icon()
|
||||
|
||||
if(!T)
|
||||
if(!isturf(loc))
|
||||
var/turf/T
|
||||
var/list/turfs = get_area_turfs(/area/shuttle/arrival)
|
||||
if(turfs.len)
|
||||
T = pick(turfs)
|
||||
else
|
||||
T = SSmapping.get_station_center()
|
||||
|
||||
forceMove(T)
|
||||
forceMove(T)
|
||||
|
||||
if(!name) //To prevent nameless ghosts
|
||||
name = random_unique_name(gender)
|
||||
@@ -196,13 +193,13 @@ GLOBAL_VAR_INIT(observer_default_invisibility, INVISIBILITY_OBSERVER)
|
||||
else
|
||||
ghostimage_default.icon_state = new_form
|
||||
|
||||
if(ghost_accs >= GHOST_ACCS_DIR && icon_state in GLOB.ghost_forms_with_directions_list) //if this icon has dirs AND the client wants to show them, we make sure we update the dir on movement
|
||||
if(ghost_accs >= GHOST_ACCS_DIR && (icon_state in GLOB.ghost_forms_with_directions_list)) //if this icon has dirs AND the client wants to show them, we make sure we update the dir on movement
|
||||
updatedir = 1
|
||||
else
|
||||
updatedir = 0 //stop updating the dir in case we want to show accessories with dirs on a ghost sprite without dirs
|
||||
setDir(2 )//reset the dir to its default so the sprites all properly align up
|
||||
|
||||
if(ghost_accs == GHOST_ACCS_FULL && icon_state in GLOB.ghost_forms_with_accessories_list) //check if this form supports accessories and if the client wants to show them
|
||||
if(ghost_accs == GHOST_ACCS_FULL && (icon_state in GLOB.ghost_forms_with_accessories_list)) //check if this form supports accessories and if the client wants to show them
|
||||
var/datum/sprite_accessory/S
|
||||
if(facial_hair_style)
|
||||
S = GLOB.facial_hair_styles_list[facial_hair_style]
|
||||
@@ -268,7 +265,7 @@ Works together with spawning an observer, noted above.
|
||||
if(!key || key[1] == "@" || (SEND_SIGNAL(src, COMSIG_MOB_GHOSTIZE, can_reenter_corpse, special, penalize) & COMPONENT_BLOCK_GHOSTING))
|
||||
return //mob has no key, is an aghost or some component hijacked.
|
||||
stop_sound_channel(CHANNEL_HEARTBEAT) //Stop heartbeat sounds because You Are A Ghost Now
|
||||
var/mob/dead/observer/ghost = new(src) // Transfer safety to observer spawning proc.
|
||||
var/mob/dead/observer/ghost = new(get_turf(src), src) // Transfer safety to observer spawning proc.
|
||||
SStgui.on_transfer(src, ghost) // Transfer NanoUIs.
|
||||
ghost.can_reenter_corpse = can_reenter_corpse
|
||||
if (client && client.prefs && client.prefs.auto_ooc)
|
||||
@@ -310,8 +307,9 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
var/obj/machinery/cryopod/C = loc
|
||||
C.despawn_occupant()
|
||||
else
|
||||
ghostize(0, penalize = TRUE, voluntary = TRUE) //0 parameter is so we can never re-enter our body, "Charlie, you can never come baaaack~" :3
|
||||
suicide_log(TRUE)
|
||||
ghostize(FALSE, penalize = TRUE, voluntary = TRUE) //FALSE parameter is so we can never re-enter our body, "Charlie, you can never come baaaack~" :3
|
||||
|
||||
|
||||
/mob/camera/verb/ghost()
|
||||
set category = "OOC"
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
/mob/living/carbon/Initialize()
|
||||
. = ..()
|
||||
create_reagents(1000)
|
||||
create_reagents(1000, NONE, NO_REAGENTS_VALUE)
|
||||
update_body_parts() //to update the carbon's new bodyparts appearance
|
||||
GLOB.carbon_list += src
|
||||
blood_volume = (BLOOD_VOLUME_NORMAL * blood_ratio)
|
||||
|
||||
@@ -362,7 +362,7 @@
|
||||
return
|
||||
|
||||
// Also no decay if corpse chilled or not organic/undead
|
||||
if(bodytemperature <= T0C-10 || (!(MOB_ORGANIC in mob_biotypes) && !(MOB_UNDEAD in mob_biotypes)))
|
||||
if((bodytemperature <= T0C-10) || !(mob_biotypes & (MOB_ORGANIC|MOB_UNDEAD)))
|
||||
return
|
||||
|
||||
// Wait a bit before decaying
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
/mob/living/proc/spawn_gibs(with_bodyparts, atom/loc_override)
|
||||
var/location = loc_override ? loc_override.drop_location() : drop_location()
|
||||
if(MOB_ROBOTIC in mob_biotypes)
|
||||
if((MOB_ROBOTIC) in (mob_biotypes))
|
||||
new /obj/effect/gibspawner/robot(location, src, get_static_viruses())
|
||||
else
|
||||
new /obj/effect/gibspawner/generic(location, src, get_static_viruses())
|
||||
|
||||
@@ -258,7 +258,7 @@ GLOBAL_LIST_INIT(department_radio_keys, list(
|
||||
if(M.stat != DEAD) //not dead, not important
|
||||
if(yellareas) //CIT CHANGE - see above. makes yelling penetrate walls
|
||||
var/area/A = get_area(M) //CIT CHANGE - ditto
|
||||
if(istype(A) && A.ambientsounds != SPACE && A in yellareas) //CIT CHANGE - ditto
|
||||
if(istype(A) && A.ambientsounds != SPACE && (A in yellareas)) //CIT CHANGE - ditto
|
||||
listening |= M //CIT CHANGE - ditto
|
||||
continue
|
||||
if(!M.client || !client) //client is so that ghosts don't have to listen to mice
|
||||
@@ -368,7 +368,7 @@ GLOBAL_LIST_INIT(department_radio_keys, list(
|
||||
if(message_mode == MODE_HEADSET)
|
||||
imp.radio.talk_into(src, message, , spans, language)
|
||||
return ITALICS | REDUCE_RANGE
|
||||
if(message_mode == MODE_DEPARTMENT || message_mode in GLOB.radiochannels)
|
||||
if(message_mode == MODE_DEPARTMENT || (message_mode in GLOB.radiochannels))
|
||||
imp.radio.talk_into(src, message, message_mode, spans, language)
|
||||
return ITALICS | REDUCE_RANGE
|
||||
|
||||
|
||||
@@ -8,9 +8,9 @@
|
||||
var/list/states = icon_states(icon)
|
||||
icon_state = ""
|
||||
if(resting) //The next line is some bullshit but I can make it worse if you want and make it a single line instead of four.. :)
|
||||
if(dynamic_chassis_sit && ("sit") in states)
|
||||
if(dynamic_chassis_sit && ("sit" in states))
|
||||
icon_state = "sit"
|
||||
else if(dynamic_chassis_bellyup && ("bellyup") in states)
|
||||
else if(dynamic_chassis_bellyup && ("bellyup" in states))
|
||||
icon_state = "bellyup"
|
||||
else if("rest" in states)
|
||||
icon_state = "rest"
|
||||
|
||||
@@ -340,7 +340,7 @@
|
||||
/obj/item/robot_module/medical/be_transformed_to(obj/item/robot_module/old_module)
|
||||
var/mob/living/silicon/robot/R = loc
|
||||
var/medmodels = list("Default", "Heavy", "Sleek", "Marina", "Droid", "Eyebot", "Medihound", "Medihound Dark", "Vale")
|
||||
if(R.client && R.client.ckey in list("nezuli"))
|
||||
if(R.client && (R.client.ckey in list("nezuli")))
|
||||
medmodels += "Alina"
|
||||
var/borg_icon = input(R, "Select an icon!", "Robot Icon", null) as null|anything in medmodels
|
||||
if(!borg_icon)
|
||||
@@ -437,7 +437,7 @@
|
||||
/obj/item/robot_module/engineering/be_transformed_to(obj/item/robot_module/old_module)
|
||||
var/mob/living/silicon/robot/R = loc
|
||||
var/list/engymodels = list("Default", "Default - Treads", "Heavy", "Sleek", "Marina", "Can", "Spider", "Loader","Handy", "Pup Dozer", "Vale")
|
||||
if(R.client && R.client.ckey in list("nezuli"))
|
||||
if(R.client && (R.client.ckey in list("nezuli")))
|
||||
engymodels += "Alina"
|
||||
var/borg_icon = input(R, "Select an icon!", "Robot Icon", null) as null|anything in engymodels
|
||||
if(!borg_icon)
|
||||
@@ -515,7 +515,7 @@
|
||||
/obj/item/robot_module/security/be_transformed_to(obj/item/robot_module/old_module)
|
||||
var/mob/living/silicon/robot/R = loc
|
||||
var/list/secmodels = list("Default", "Default - Treads", "Heavy", "Sleek", "Can", "Marina", "Spider", "K9", "K9 Dark", "Vale")
|
||||
if(R.client && R.client.ckey in list("nezuli"))
|
||||
if(R.client && (R.client.ckey in list("nezuli")))
|
||||
secmodels += "Alina"
|
||||
var/borg_icon = input(R, "Select an icon!", "Robot Icon", null) as null|anything in secmodels
|
||||
if(!borg_icon)
|
||||
|
||||
@@ -454,7 +454,7 @@
|
||||
name = "udder"
|
||||
|
||||
/obj/item/udder/Initialize()
|
||||
create_reagents(50)
|
||||
create_reagents(50, NONE, NO_REAGENTS_VALUE)
|
||||
reagents.add_reagent(/datum/reagent/consumable/milk, 20)
|
||||
. = ..()
|
||||
|
||||
|
||||
@@ -191,7 +191,7 @@
|
||||
/obj/effect/proc_holder/spell/aoe_turf/blindness/cast(list/targets,mob/user = usr)
|
||||
for(var/mob/living/L in GLOB.alive_mob_list)
|
||||
var/turf/T = get_turf(L.loc)
|
||||
if(T && T in targets)
|
||||
if(T && (T in targets))
|
||||
L.blind_eyes(4)
|
||||
return
|
||||
|
||||
|
||||
@@ -467,11 +467,11 @@
|
||||
return
|
||||
return
|
||||
|
||||
if(parrot_interest && parrot_interest in view(src))
|
||||
if(parrot_interest && (parrot_interest in view(src)))
|
||||
parrot_state = PARROT_SWOOP | PARROT_STEAL
|
||||
return
|
||||
|
||||
if(parrot_perch && parrot_perch in view(src))
|
||||
if(parrot_perch && (parrot_perch in view(src)))
|
||||
parrot_state = PARROT_SWOOP | PARROT_RETURN
|
||||
return
|
||||
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
else
|
||||
var/datum/action/innate/slime/evolve/E = new
|
||||
E.Grant(src)
|
||||
create_reagents(100)
|
||||
create_reagents(100, NONE, NO_REAGENTS_VALUE)
|
||||
set_colour(new_colour)
|
||||
. = ..()
|
||||
nutrition = 700
|
||||
|
||||
@@ -320,10 +320,10 @@
|
||||
if(C.setting == counter_setting)
|
||||
return BULLET_ACT_BLOCK
|
||||
|
||||
var/mob/living/L = target
|
||||
if(!istype(target))
|
||||
if(!isliving(target))
|
||||
return BULLET_ACT_BLOCK
|
||||
|
||||
var/mob/living/L = target
|
||||
switch(hugbox)
|
||||
if(DUEL_HUGBOX_NONE)
|
||||
var/obj/item/bodypart/B = L.get_bodypart(BODY_ZONE_HEAD)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
/obj/item/projectile/bullet/dart/Initialize()
|
||||
. = ..()
|
||||
create_reagents(50, NO_REACT)
|
||||
create_reagents(50, NO_REACT, NO_REAGENTS_VALUE)
|
||||
|
||||
/obj/item/projectile/bullet/dart/on_hit(atom/target, blocked = FALSE, skip = FALSE)
|
||||
if(iscarbon(target))
|
||||
|
||||
@@ -61,8 +61,9 @@
|
||||
var/reactedVol = 0 //how much of the reagent is reacted during a fermireaction
|
||||
var/fermiIsReacting = FALSE //that prevents multiple reactions from occurring (i.e. add_reagent calls to process_reactions(), this stops any extra reactions.)
|
||||
var/fermiReactID //instance of the chem reaction used during a fermireaction, kept here so it's cache isn't lost between loops/procs.
|
||||
var/value_multiplier = DEFAULT_REAGENTS_VALUE //used for cargo reagents selling.
|
||||
|
||||
/datum/reagents/New(maximum=100, new_flags)
|
||||
/datum/reagents/New(maximum=100, new_flags = NONE, new_value = DEFAULT_REAGENTS_VALUE)
|
||||
maximum_volume = maximum
|
||||
|
||||
//I dislike having these here but map-objects are initialised before world/New() is called. >_>
|
||||
@@ -72,6 +73,7 @@
|
||||
build_chemical_reactions_list()
|
||||
|
||||
reagents_holder_flags = new_flags
|
||||
value_multiplier = new_value
|
||||
|
||||
/datum/reagents/Destroy()
|
||||
. = ..()
|
||||
@@ -1147,10 +1149,10 @@
|
||||
|
||||
// Convenience proc to create a reagents holder for an atom
|
||||
// Max vol is maximum volume of holder
|
||||
/atom/proc/create_reagents(max_vol, flags)
|
||||
/atom/proc/create_reagents(max_vol, flags, new_value)
|
||||
if(reagents)
|
||||
qdel(reagents)
|
||||
reagents = new/datum/reagents(max_vol, flags)
|
||||
reagents = new/datum/reagents(max_vol, flags, new_value)
|
||||
reagents.my_atom = src
|
||||
|
||||
/proc/get_random_reagent_id() // Returns a random reagent type minus blacklisted reagents
|
||||
|
||||
@@ -270,7 +270,7 @@
|
||||
if(!is_operational() || recording_recipe)
|
||||
return
|
||||
var/amount = text2num(params["amount"])
|
||||
if(beaker && amount in beaker.possible_transfer_amounts)
|
||||
if(beaker && (amount in beaker.possible_transfer_amounts))
|
||||
beaker.reagents.remove_all(amount)
|
||||
work_animation()
|
||||
. = TRUE
|
||||
|
||||
@@ -551,7 +551,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
value = 1
|
||||
|
||||
/datum/reagent/consumable/ethanol/screwdrivercocktail/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind && M.mind.assigned_role in list("Station Engineer", "Atmospheric Technician", "Chief Engineer")) //Engineers lose radiation poisoning at a massive rate.
|
||||
if(M.mind && (M.mind.assigned_role in list("Station Engineer", "Atmospheric Technician", "Chief Engineer"))) //Engineers lose radiation poisoning at a massive rate.
|
||||
M.radiation = max(M.radiation - 25, 0)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -338,8 +338,8 @@
|
||||
|
||||
/datum/reagent/water/holywater/on_mob_life(mob/living/carbon/M)
|
||||
if(!data)
|
||||
data = 1
|
||||
data++
|
||||
data = list("misc" = 1)
|
||||
data["misc"]++
|
||||
M.jitteriness = min(M.jitteriness+4,10)
|
||||
if(iscultist(M))
|
||||
for(var/datum/action/innate/cult/blood_magic/BM in M.actions)
|
||||
@@ -348,7 +348,7 @@
|
||||
to_chat(M, "<span class='cultlarge'>Your blood rites falter as holy water scours your body!</span>")
|
||||
for(var/datum/action/innate/cult/blood_spell/BS in BM.spells)
|
||||
qdel(BS)
|
||||
if(data >= 25) // 10 units, 45 seconds @ metabolism 0.4 units & tick rate 1.8 sec
|
||||
if(data["misc"] >= 25) // 10 units, 45 seconds @ metabolism 0.4 units & tick rate 1.8 sec
|
||||
if(!M.stuttering)
|
||||
M.stuttering = 1
|
||||
M.stuttering = min(M.stuttering+4, 10)
|
||||
@@ -369,7 +369,7 @@
|
||||
"You can't save him. Nothing can save him now", "It seems that Nar'Sie will triumph after all")].</span>")
|
||||
if("emote")
|
||||
M.visible_message("<span class='warning'>[M] [pick("whimpers quietly", "shivers as though cold", "glances around in paranoia")].</span>")
|
||||
if(data >= 60) // 30 units, 135 seconds
|
||||
if(data["misc"] >= 60) // 30 units, 135 seconds
|
||||
if(iscultist(M) || is_servant_of_ratvar(M))
|
||||
if(iscultist(M))
|
||||
SSticker.mode.remove_cultist(M.mind, FALSE, TRUE)
|
||||
|
||||
@@ -7,7 +7,8 @@
|
||||
var/amount_per_transfer_from_this = 5
|
||||
var/list/possible_transfer_amounts = list(5,10,15,20,25,30)
|
||||
var/volume = 30
|
||||
var/reagent_flags //used to determine the reagent holder flags on add_initial_reagents()
|
||||
var/reagent_flags = NONE //used to determine the reagent holder flags on add_initial_reagents()
|
||||
var/reagent_value = DEFAULT_REAGENTS_VALUE //same as above but for the holder value multiplier.
|
||||
var/list/list_reagents = null
|
||||
var/spawned_disease = null
|
||||
var/disease_amount = 20
|
||||
@@ -22,7 +23,7 @@
|
||||
volume = vol
|
||||
if(container_flags & APTFT_VERB && length(possible_transfer_amounts))
|
||||
verbs += /obj/item/reagent_containers/proc/set_APTFT
|
||||
create_reagents(volume, reagent_flags)
|
||||
create_reagents(volume, reagent_flags, reagent_value)
|
||||
if(spawned_disease)
|
||||
var/datum/disease/F = new spawned_disease()
|
||||
var/list/data = list("blood_DNA" = "UNKNOWN DNA", "blood_type" = "SY","viruses"= list(F))
|
||||
|
||||
@@ -19,6 +19,7 @@ Borg Hypospray
|
||||
amount_per_transfer_from_this = 5
|
||||
volume = 30
|
||||
possible_transfer_amounts = list()
|
||||
reagent_value = NO_REAGENTS_VALUE
|
||||
var/mode = 1
|
||||
var/charge_cost = 50
|
||||
var/charge_tick = 0
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
if(safe_thing)
|
||||
if(!safe_thing.reagents)
|
||||
safe_thing.create_reagents(100)
|
||||
safe_thing.create_reagents(100, NONE, NO_REAGENTS_VALUE)
|
||||
|
||||
reagents.reaction(safe_thing, TOUCH, fraction)
|
||||
trans = reagents.trans_to(safe_thing, amount_per_transfer_from_this)
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
container_flags = APTFT_VERB
|
||||
volume = 5
|
||||
spillable = FALSE
|
||||
reagent_value = NO_REAGENTS_VALUE
|
||||
var/wipe_sound
|
||||
var/soak_efficiency = 1
|
||||
var/extinguish_efficiency = 0
|
||||
@@ -26,7 +27,7 @@
|
||||
if(reagents.total_volume)
|
||||
. += "<span class='notice'>It's soaked. Alt-Click to squeeze it dry, and perhaps gather the liquids into another held open container.</span>"
|
||||
|
||||
/obj/item/reagent_containers/rag/afterattack(atom/A as obj|turf|area, mob/user,proximity)
|
||||
/obj/item/reagent_containers/rag/afterattack(atom/A, mob/user,proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
@@ -45,7 +46,7 @@
|
||||
C.visible_message("<span class='notice'>[user] has touched \the [C] with \the [src].</span>")
|
||||
log_combat(user, C, "touched", log_object)
|
||||
|
||||
else if(istype(A) && src in user)
|
||||
else if(istype(A) && (src in user))
|
||||
user.visible_message("[user] starts to wipe down [A] with [src]!", "<span class='notice'>You start to wipe down [A] with [src]...</span>")
|
||||
if(do_after(user, action_speed, target = A))
|
||||
user.visible_message("[user] finishes wiping off [A]!", "<span class='notice'>You finish wiping off [A].</span>")
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
/obj/item/reagent_containers/spray/proc/spray(atom/A)
|
||||
var/range = CLAMP(get_dist(src, A), 1, current_range)
|
||||
var/obj/effect/decal/chempuff/D = new /obj/effect/decal/chempuff(get_turf(src))
|
||||
D.create_reagents(amount_per_transfer_from_this)
|
||||
D.create_reagents(amount_per_transfer_from_this, NONE, NO_REAGENTS_VALUE)
|
||||
var/puff_reagent_left = range //how many turf, mob or dense objet we can react with before we consider the chem puff consumed
|
||||
if(stream_mode)
|
||||
reagents.trans_to(D, amount_per_transfer_from_this)
|
||||
|
||||
@@ -168,7 +168,7 @@ GLOBAL_LIST_INIT(cargo_shuttle_leave_behind_typecache, typecacheof(list(
|
||||
|
||||
for(var/chem in ex.reagents_value)
|
||||
var/value = ex.reagents_value[chem]
|
||||
msg += "[value] credits: received [ex.reagents_volume[chem]]u of [chem].\n"
|
||||
msg += "[value > 0 ? "+" : ""][value] credits: received [ex.reagents_volume[chem]]u of [chem].\n"
|
||||
SSshuttle.points += value
|
||||
|
||||
msg = copytext_char(msg, 1, MAX_MESSAGE_LEN)
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
else
|
||||
message = "<span class='notice'>You must hold the desired item in your hands to mark it for recall.</span>"
|
||||
|
||||
else if(marked_item && marked_item in hand_items) //unlinking item to the spell
|
||||
else if(marked_item && (marked_item in hand_items)) //unlinking item to the spell
|
||||
message = "<span class='notice'>You remove the mark on [marked_item] to use elsewhere.</span>"
|
||||
name = "Instant Summons"
|
||||
marked_item = null
|
||||
@@ -78,7 +78,7 @@
|
||||
|
||||
if(iscarbon(M)) //Edge case housekeeping
|
||||
var/mob/living/carbon/C = M
|
||||
if(C.stomach_contents && item_to_retrieve in C.stomach_contents)
|
||||
if(C.stomach_contents && (item_to_retrieve in C.stomach_contents))
|
||||
C.stomach_contents -= item_to_retrieve
|
||||
for(var/X in C.bodyparts)
|
||||
var/obj/item/bodypart/part = X
|
||||
|
||||
@@ -190,7 +190,7 @@
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
var/sound/eating = GLOB.pred_vore_sounds[vore_sound]
|
||||
SEND_SOUND(H,eating)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H?.client && (H in contents))
|
||||
var/sound/eating = GLOB.prey_vore_sounds[vore_sound]
|
||||
SEND_SOUND(H,eating)
|
||||
recent_sound = TRUE
|
||||
@@ -246,7 +246,7 @@
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
var/sound/releasement = GLOB.pred_release_sounds[release_sound]
|
||||
H.playsound_local(owner.loc, releasement, vol = 75, vary = 1, falloff = VORE_SOUND_FALLOFF)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H?.client && (H in contents))
|
||||
var/sound/releasement = GLOB.prey_release_sounds[release_sound]
|
||||
SEND_SOUND(H,releasement)
|
||||
recent_sound = TRUE
|
||||
@@ -302,7 +302,7 @@
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
var/sound/releasement = GLOB.pred_release_sounds[release_sound]
|
||||
H.playsound_local(owner.loc, releasement, vol = 75, vary = 1, falloff = VORE_SOUND_FALLOFF)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H?.client && (H in contents))
|
||||
var/sound/releasement = GLOB.prey_release_sounds[release_sound]
|
||||
SEND_SOUND(H,releasement)
|
||||
recent_sound = TRUE
|
||||
@@ -364,7 +364,7 @@
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
var/sound/eating = GLOB.pred_vore_sounds[vore_sound]
|
||||
H.playsound_local(owner.loc, eating, vol = 75, vary = 1, falloff = VORE_SOUND_FALLOFF)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H?.client && (H in contents))
|
||||
var/sound/eating = GLOB.prey_vore_sounds[vore_sound]
|
||||
SEND_SOUND(H,eating)
|
||||
recent_sound = TRUE
|
||||
@@ -586,7 +586,7 @@
|
||||
for(var/mob/living/H in hearing_mobs)
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
H.playsound_local(owner.loc, pred_struggle_snuggle, vol = 75, vary = 1, falloff = VORE_SOUND_FALLOFF)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H && H.client && (H in contents))
|
||||
SEND_SOUND(H,prey_struggle_snuggle)
|
||||
|
||||
else
|
||||
|
||||
@@ -195,7 +195,7 @@
|
||||
for(var/mob/living/H in hearing_mobs)
|
||||
if(H && H.client && (isturf(H.loc) || (H.loc != src.contents)))
|
||||
SEND_SOUND(H,pred_digest)
|
||||
else if(H && H in contents && H.client)
|
||||
else if(H?.client && (H in contents))
|
||||
SEND_SOUND(H,prey_digest)
|
||||
|
||||
//No digestion protection for megafauna.
|
||||
|
||||
Reference in New Issue
Block a user