Skip to content

Commit d8d54b9

Browse files
Merge branch 'dev' of github.com:NebulaSS13/Nebula into pyrelight
2 parents 56c9d39 + 778373e commit d8d54b9

File tree

402 files changed

+2053
-1697
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

402 files changed

+2053
-1697
lines changed

code/__defines/chemistry.dm

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,30 @@
7878
#define HANDLE_REACTIONS(_reagents) if(!QDELETED(_reagents)) { SSmaterials.active_holders[_reagents] = TRUE; }
7979
#define UNQUEUE_REACTIONS(_reagents) SSmaterials.active_holders -= _reagents
8080

81-
#define REAGENT_LIST(R) (R.reagents?.get_reagents() || "No reagent holder")
81+
#define REAGENT_LIST(R) ((istype(R, /datum/reagents) && R:get_reagents()) || "No reagent holder")
82+
83+
#define REAGENT_TOTAL_VOLUME(R) (UNLINT((istype(R, /datum/reagents) && R:total_volume) || 0))
84+
#define REAGENT_TOTAL_LIQUID_VOLUME(R) (UNLINT((istype(R, /datum/reagents) && R:total_liquid_volume) || 0))
85+
86+
#define REAGENT_MAXIMUM_VOLUME(R) (UNLINT((istype(R, /datum/reagents) && R:maximum_volume) || 0))
87+
#define REAGENTS_FREE_SPACE(R) (UNLINT(istype(R, /datum/reagents) ? (R.maximum_volume - R.total_volume) : 0))
88+
89+
#define REAGENT_VOLUMES(R) ( (istype(R, /datum/reagents) && UNLINT(R:reagent_volumes)) || null )
90+
#define REAGENT_SOLID_VOLUMES(R) ( (istype(R, /datum/reagents) && UNLINT(R:solid_volumes)) || null )
91+
#define REAGENT_LIQUID_VOLUMES(R) ( (istype(R, /datum/reagents) && UNLINT(R:liquid_volumes)) || null )
92+
#define REAGENT_GET_MAX_VOL(R) ( (istype(R, /datum/reagents) && UNLINT(R:maximum_volume)) || 0 )
93+
#define REAGENT_GET_ATOM(R) ( (istype(R, /datum/reagents) && UNLINT(R:my_atom)) || null )
94+
95+
#define REAGENT_VOLUME(R, M) ( istype(R, /datum/reagents) && UNLINT(R:reagent_volumes && R:reagent_volumes[RESOLVE_TO_DECL(M)]) )
96+
#define LIQUID_VOLUME(R, M) ( istype(R, /datum/reagents) && UNLINT(R:liquid_volumes && R:liquid_volumes[RESOLVE_TO_DECL(M)]) )
97+
#define SOLID_VOLUME(R, M) ( istype(R, /datum/reagents) && UNLINT(R:solid_volumes && R:solid_volumes[RESOLVE_TO_DECL(M)]) )
98+
#define REAGENT_DATA(R, M) ( istype(R, /datum/reagents) && UNLINT(R:reagent_data && R:reagent_data[RESOLVE_TO_DECL(M)]) )
99+
100+
#define REAGENT_SET_MAX_VOL(R, V) if(istype(R, /datum/reagents)) { UNLINT(R:maximum_volume = V) }
101+
#define REAGENT_ADD_MAX_VOL(R, V) if(istype(R, /datum/reagents)) { UNLINT(R:maximum_volume += V) }
102+
#define REAGENT_SET_ATOM(R, A) if(istype(R, /datum/reagents)) { UNLINT(R:my_atom = A) }
103+
#define REAGENT_SET_DATA(R, M, D) if(istype(R, /datum/reagents)) { LAZYSET(UNLINT(R:reagent_data), M, D) }
82104

83-
#define REAGENTS_FREE_SPACE(R) (R?.maximum_volume - R?.total_volume)
84-
#define REAGENT_VOLUME(REAGENT_HOLDER, REAGENT_TYPE) (REAGENT_HOLDER?.reagent_volumes && REAGENT_HOLDER.reagent_volumes[RESOLVE_TO_DECL(REAGENT_TYPE)])
85-
#define LIQUID_VOLUME(REAGENT_HOLDER, REAGENT_TYPE) (REAGENT_HOLDER?.liquid_volumes && REAGENT_HOLDER.liquid_volumes[RESOLVE_TO_DECL(REAGENT_TYPE)])
86-
#define SOLID_VOLUME(REAGENT_HOLDER, REAGENT_TYPE) (REAGENT_HOLDER?.solid_volumes && REAGENT_HOLDER.solid_volumes[RESOLVE_TO_DECL(REAGENT_TYPE)])
87-
#define REAGENT_DATA(REAGENT_HOLDER, REAGENT_TYPE) (REAGENT_HOLDER?.reagent_data && REAGENT_HOLDER.reagent_data[RESOLVE_TO_DECL(REAGENT_TYPE)])
88105

89106
#define CHEM_DOSE(M, R) LAZYACCESS(M._chem_doses, RESOLVE_TO_DECL(R))
90107

code/__defines/mobs.dm

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -150,30 +150,15 @@
150150
#define BP_EYES "eyes"
151151
#define BP_HEART "heart"
152152
#define BP_LUNGS "lungs"
153-
#define BP_TRACH "tracheae"
154153
#define BP_BRAIN "brain"
155154
#define BP_LIVER "liver"
156155
#define BP_KIDNEYS "kidneys"
157156
#define BP_STOMACH "stomach"
158-
#define BP_PLASMA "plasma vessel"
159157
#define BP_APPENDIX "appendix"
160158
#define BP_CELL "cell"
161-
#define BP_HIVE "hive node"
162-
#define BP_NUTRIENT "nutrient vessel"
163-
#define BP_ACID "acid gland"
164-
#define BP_EGG "egg sac"
165-
#define BP_RESIN "resin spinner"
166-
#define BP_STRATA "neural strata"
167-
#define BP_RESPONSE "response node"
168-
#define BP_GBLADDER "gas bladder"
169-
#define BP_POLYP "polyp segment"
170-
#define BP_ANCHOR "anchoring ligament"
171-
#define BP_ACETONE "acetone reactor"
172159

173160
// Robo Organs.
174161
#define BP_VOICE "vocal synthesiser"
175-
#define BP_STACK "stack"
176-
#define BP_OPTICS "optics"
177162

178163
//Augmetations
179164
#define BP_AUGMENT_R_ARM "right arm augment"
@@ -351,6 +336,7 @@ var/global/list/dexterity_levels = list(
351336
// Additional pronoun sets.
352337
#define NEUTER_ANIMATE "animate singular neutral"
353338
#define SECOND_PERSON_SINGULAR "second person singular"
339+
#define PSEUDOPLURAL "pseudoplural"
354340

355341
// Equipment Overlays Indices //
356342
#define HO_CONDITION_LAYER 1

code/_helpers/lists.dm

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,17 @@
2727
input -= thing
2828
var/thing_string = isatom(thing) ? thing.name : "\proper [thing]"
2929
thing_count[thing_string] += 1
30-
thing_gender[thing_string] = isatom(thing) ? thing.gender : NEUTER
30+
if(ismob(thing))
31+
var/mob/mob_thing = thing
32+
thing_gender[thing_string] = mob_thing.get_gender()
33+
else
34+
thing_gender[thing_string] = isatom(thing) ? thing.gender : NEUTER
3135
input = list()
3236
for(var/thing_string in thing_count)
3337
if(thing_count[thing_string] == 1)
3438
input += "\the [thing_string]"
3539
else
36-
input += "[thing_count[thing_string]] [thing_string][thing_gender[thing_string] == PLURAL ? "" : "s"]"
40+
input += "[thing_count[thing_string]] [thing_gender[thing_string] == PLURAL ? text_make_plural(thing_string) : thing_string]"
3741

3842
switch(length(input))
3943
if(1)
@@ -172,7 +176,7 @@
172176

173177
//Checks for specific types in specifically structured (Assoc "type" = TRUE) lists ('typecaches')
174178
/proc/is_type_in_typecache(atom/A, list/cache)
175-
if(!cache || !cache.len || !A)
179+
if(!LAZYLEN(cache) || !A)
176180
return 0
177181
return cache[A.type]
178182

code/_helpers/medical_scans.dm

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,14 @@
4242
.["immune_system"] = get_immunity()
4343
.["reagents"] = list()
4444

45-
if(reagents?.total_volume)
46-
for(var/decl/material/reagent as anything in reagents.liquid_volumes)
45+
if(REAGENT_TOTAL_VOLUME(reagents))
46+
for(var/decl/material/reagent as anything in REAGENT_LIQUID_VOLUMES(reagents))
4747
var/list/reagent_data = list()
4848
reagent_data["name"] = reagent.get_reagent_name(reagents, MAT_PHASE_LIQUID)
4949
reagent_data["quantity"] = round(REAGENT_VOLUME(reagents, reagent),1)
5050
reagent_data["scannable"] = reagent.scannable
5151
.["reagents"] += list(reagent_data)
52-
53-
for(var/decl/material/reagent as anything in reagents.solid_volumes)
52+
for(var/decl/material/reagent as anything in REAGENT_SOLID_VOLUMES(reagents))
5453
var/list/reagent_data = list()
5554
reagent_data["name"] = reagent.get_reagent_name(reagents, MAT_PHASE_SOLID)
5655
reagent_data["quantity"] = round(REAGENT_VOLUME(reagents, reagent),1)
@@ -98,8 +97,8 @@
9897
.["blood_pressure"] = get_blood_pressure()
9998
.["blood_o2"] = get_blood_oxygenation()
10099
if(vessel)
101-
.["blood_volume"] = vessel.total_volume
102-
.["blood_volume_max"] = vessel.maximum_volume
100+
.["blood_volume"] = REAGENT_TOTAL_VOLUME(vessel)
101+
.["blood_volume_max"] = REAGENT_MAXIMUM_VOLUME(vessel)
103102

104103
/proc/display_medical_data_header(var/list/scan, skill_level = SKILL_DEFAULT)
105104
//In case of problems, abort.

code/_helpers/text.dm

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,11 +366,22 @@ var/global/regex/starts_lowercase_regex = regex(@"^[a-z]")
366366
return trim_left(trim_right(text))
367367

368368
//Returns a string with the first element of the string capitalized.
369+
// NOTE: This will not work if there are any HTML tags.
369370
/proc/capitalize(text)
370371
if(text)
371372
text = uppertext(text[1]) + copytext(text, 1 + length(text[1]))
372373
return text
373374

375+
// Returns a string with the first alphabetical element of the string capitalized, skipping HTML tags.
376+
/proc/capitalize_proper_html(text)
377+
var/static/regex/split_html_regex = regex(@"(^<[^>]*>)([A-Za-z])(.+)$")
378+
if(!text)
379+
return text
380+
if(!split_html_regex.Find(text))
381+
return capitalize(text)
382+
split_html_regex.group[2] = uppertext(split_html_regex.group[2])
383+
return JOINTEXT(split_html_regex.group)
384+
374385
//Returns a string with the first element of the every word of the string capitalized.
375386
/proc/capitalize_words(text)
376387
var/list/S = splittext(text, " ")
@@ -784,6 +795,48 @@ var/global/list/plural_words_unchanged = list(
784795
word = "[jointext(splited, " ", 1, length(splited))] [word]"
785796
return word
786797

798+
var/global/list/copula_verbs = list("is" = TRUE, "am" = TRUE, "are" = TRUE)
799+
var/global/list/has_verbs = list("has" = TRUE, "have" = TRUE)
800+
var/global/list/does_verbs = list("does" = TRUE, "do" = TRUE)
801+
var/global/list/agreement_exception_verbs = list("can" = TRUE, "cannot" = TRUE, "can't" = TRUE, "will" = TRUE, "won't" = TRUE, "shall" = TRUE, "shan't" = TRUE, "may" = TRUE, "must" = TRUE, "ought" = TRUE, "could" = TRUE, "would" = TRUE, "should" = TRUE)
802+
/proc/verb_agree_with_pronouns(var/use_verb, var/decl/pronouns/use_pronouns, is_after_pronoun = TRUE)
803+
// deal with compound verb phrases here!
804+
// basically, skip all our adverbs, inflect only the first non-adverb word we find (which is hopefully a verb) and then keep everything after unchanged
805+
// this will properly handle "successfully finish doing" and "properly manage to do"
806+
// but not "somehow finish doing" which will get turned into "somehows finish doing" :(
807+
// todo: fix that
808+
var/list/words = splittext(use_verb, " ")
809+
if(length(words) > 1)
810+
var/last_adverb = 1
811+
for(var/word_index in 1 to length(words))
812+
if(text_ends_with(words[word_index], "ly"))
813+
last_adverb = max(word_index, last_adverb)
814+
use_verb = words[last_adverb]
815+
// This overengineered nonsense ensures that we shouldn't end up with any doubled or missing spaces.
816+
return jointext_no_nulls(list(jointext(words.Copy(1, last_adverb), " "), verb_agree_with_pronouns(use_verb, use_pronouns, is_after_pronoun = is_after_pronoun), jointext(words.Copy(last_adverb + 1, length(words) + 1), " ")), " ")
817+
if(!is_after_pronoun && use_pronouns.pluralize_verb == /decl/pronouns::PLURALIZE_PSEUDO)
818+
return use_verb // do not inflect pseudoplural unless after a pronoun
819+
if(global.copula_verbs[use_verb])
820+
return use_pronouns.is
821+
else if(global.has_verbs[use_verb])
822+
return use_pronouns.has
823+
else if(global.does_verbs[use_verb])
824+
return use_pronouns.does
825+
else if(global.agreement_exception_verbs[use_verb])
826+
return use_verb
827+
// text_make_plural is intended for nouns, but should hopefully work for "fly" -> "flies" and similar.
828+
switch(use_pronouns.pluralize_verb)
829+
if(/decl/pronouns::PLURALIZE_NONE)
830+
return use_verb
831+
if(/decl/pronouns::PLURALIZE_PSEUDO)
832+
// technically only the plural side can get hit here
833+
// but better safe than sorry
834+
return is_after_pronoun ? text_make_plural(use_verb) : use_verb
835+
if(/decl/pronouns::PLURALIZE_ALL)
836+
return text_make_plural(use_verb)
837+
else
838+
CRASH("Invalid value [use_pronouns.pluralize_verb] for [use_pronouns]!")
839+
787840
// Surely we have this defined somewhere already??
788841
/proc/repeatstring(str, num)
789842
. = list()

code/controllers/subsystems/event.dm

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,11 @@ SUBSYSTEM_DEF(event)
2828
/datum/controller/subsystem/event/Initialize()
2929

3030
if(!event_containers)
31+
// Order must conform to EVENT_LEVEL_MUNDANE, EVENT_LEVEL_MODERATE, EVENT_LEVEL_MAJOR.
3132
event_containers = list(
32-
EVENT_LEVEL_MUNDANE = new global.using_map.event_container_mundane,
33-
EVENT_LEVEL_MODERATE = new global.using_map.event_container_moderate,
34-
EVENT_LEVEL_MAJOR = new global.using_map.event_container_major
33+
new global.using_map.event_container_mundane,
34+
new global.using_map.event_container_moderate,
35+
new global.using_map.event_container_major
3536
)
3637
all_events = null
3738

code/controllers/subsystems/fluids.dm

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ SUBSYSTEM_DEF(fluids)
100100
i++
101101
current_fluid_holder = processing_fluids[i]
102102

103-
if(QDELETED(current_fluid_holder) || !current_fluid_holder.reagents?.total_volume)
103+
if(QDELETED(current_fluid_holder) || !REAGENT_TOTAL_VOLUME(current_fluid_holder.reagents))
104104
REMOVE_ACTIVE_FLUID(current_fluid_holder)
105105
continue
106106

@@ -110,7 +110,7 @@ SUBSYSTEM_DEF(fluids)
110110

111111
reagent_holder = current_fluid_holder.reagents
112112
UPDATE_FLUID_BLOCKED_DIRS(current_fluid_holder)
113-
current_depth = reagent_holder?.total_volume || 0
113+
current_depth = REAGENT_TOTAL_VOLUME(reagent_holder)
114114

115115
// How is this happening
116116
if(QDELETED(reagent_holder) || current_depth == -1.#IND || current_depth == 1.#IND)
@@ -123,7 +123,7 @@ SUBSYSTEM_DEF(fluids)
123123
current_depth = current_fluid_holder.get_fluid_depth()
124124

125125
// Mimimum liquid depth for creation of slurries. Do this after evaporation since it may change the total depth.
126-
if(reagent_holder?.total_liquid_volume < FLUID_SLURRY)
126+
if(REAGENT_TOTAL_LIQUID_VOLUME(reagent_holder) < FLUID_SLURRY)
127127
current_fluid_holder.dump_solid_reagents()
128128
current_depth = current_fluid_holder.get_fluid_depth()
129129

@@ -135,7 +135,7 @@ SUBSYSTEM_DEF(fluids)
135135
// Wash our turf.
136136
current_fluid_holder.fluid_act(reagent_holder)
137137

138-
if(isspaceturf(current_fluid_holder) || (istype(current_fluid_holder, /turf/floor) && (current_fluid_holder.turf_flags & TURF_FLAG_ABSORB_LIQUID) && (current_fluid_holder.reagents?.total_volume + current_fluid_holder.get_physical_height()) > 0))
138+
if(isspaceturf(current_fluid_holder) || (istype(current_fluid_holder, /turf/floor) && (current_fluid_holder.turf_flags & TURF_FLAG_ABSORB_LIQUID) && (REAGENT_TOTAL_VOLUME(current_fluid_holder.reagents) + current_fluid_holder.get_physical_height()) > 0))
139139
removing = round(current_depth * 0.5)
140140
if(removing > 0)
141141
current_fluid_holder.remove_fluids(removing, defer_update = TRUE)
@@ -154,8 +154,9 @@ SUBSYSTEM_DEF(fluids)
154154
if(other_fluid_holder)
155155
UPDATE_FLUID_BLOCKED_DIRS(other_fluid_holder)
156156
if(!(other_fluid_holder.fluid_blocked_dirs & UP) && other_fluid_holder.CanFluidPass(UP))
157-
if(!QDELETED(other_fluid_holder) && other_fluid_holder.reagents?.total_volume < FLUID_MAX_DEPTH)
158-
current_fluid_holder.transfer_fluids_to(other_fluid_holder, min(floor(current_depth*0.5), FLUID_MAX_DEPTH - other_fluid_holder.reagents?.total_volume))
157+
var/other_volume = REAGENT_TOTAL_VOLUME(other_fluid_holder.reagents)
158+
if(!QDELETED(other_fluid_holder) && other_volume < FLUID_MAX_DEPTH)
159+
current_fluid_holder.transfer_fluids_to(other_fluid_holder, min(floor(current_depth*0.5), FLUID_MAX_DEPTH - other_volume))
159160
current_depth = current_fluid_holder.get_fluid_depth()
160161

161162
// Flow into the lowest level neighbor.
@@ -173,7 +174,7 @@ SUBSYSTEM_DEF(fluids)
173174
if((neighbor.fluid_blocked_dirs & coming_from) || !neighbor.CanFluidPass(coming_from) || neighbor.is_flooded(absolute = TRUE) || !neighbor.CanFluidPass(global.reverse_dir[spread_dir]))
174175
continue
175176
other_fluid_holder = neighbor
176-
neighbor_depth = (other_fluid_holder?.reagents?.total_volume || 0) + neighbor.get_physical_height()
177+
neighbor_depth = (REAGENT_TOTAL_VOLUME(other_fluid_holder.reagents)) + neighbor.get_physical_height()
177178
flow_amount = round((current_turf_depth - neighbor_depth)*0.5)
178179
// TODO: multiply flow amount or minimum transfer amount by some
179180
// viscosity calculation to allow for piles of jelly vs piles of water.
@@ -235,7 +236,7 @@ SUBSYSTEM_DEF(fluids)
235236
if(current_fluid_holder.last_flow_strength >= 10)
236237
// Catwalks mean items will be above the turf; subtract the turf height from our volume.
237238
// TODO: somehow handle stuff that is on a catwalk or on the turf within the same turf.
238-
var/effective_volume = current_fluid_holder.reagents?.total_volume
239+
var/effective_volume = REAGENT_TOTAL_VOLUME(current_fluid_holder.reagents)
239240
if(current_fluid_holder.get_supporting_platform())
240241
// Depth is negative height, hence +=. TODO: positive heights? No idea how to handle that.
241242
effective_volume += current_fluid_holder.get_physical_height()

code/datums/extensions/abilities/ability_decl.dm

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@
173173

174174
if(!prepare_to_cast(user, target, metadata, handler))
175175
if(fail_cast_1p_str)
176-
to_chat(user, SPAN_WARNING(capitalize(emote_replace_user_tokens(fail_cast_1p_str, user))))
176+
to_chat(user, SPAN_WARNING(capitalize_proper_html(emote_replace_user_tokens(fail_cast_1p_str, user))))
177177
return
178178

179179
if(projectile_type)
@@ -209,25 +209,25 @@
209209
/decl/ability/proc/show_cast_channel_msg(mob/user, atom/target, list/metadata)
210210
if(prepare_message_3p_str && prepare_message_1p_str)
211211
user.visible_message(
212-
SPAN_NOTICE(capitalize(emote_replace_target_tokens(emote_replace_user_tokens(prepare_message_3p_str, user), target))),
213-
SPAN_NOTICE(capitalize(emote_replace_target_tokens(prepare_message_1p_str, target)))
212+
SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(emote_replace_user_tokens(prepare_message_3p_str, user), target))),
213+
SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(prepare_message_1p_str, target)))
214214
)
215215
else if(prepare_message_1p_str)
216-
user.visible_message(SPAN_NOTICE(capitalize(emote_replace_target_tokens(prepare_message_1p_str, target))))
216+
user.visible_message(SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(prepare_message_1p_str, target))))
217217
else if(prepare_message_3p_str)
218-
user.visible_message(SPAN_NOTICE(capitalize(emote_replace_target_tokens(emote_replace_user_tokens(prepare_message_3p_str, user), target))))
218+
user.visible_message(SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(emote_replace_user_tokens(prepare_message_3p_str, user), target))))
219219

220220
/decl/ability/proc/show_ability_cast_msg(mob/user, list/targets, list/metadata)
221221
var/atom/target = targets[1]
222222
if(cast_message_3p_str && cast_message_1p_str)
223223
user.visible_message(
224-
SPAN_NOTICE(capitalize(emote_replace_target_tokens(emote_replace_user_tokens(cast_message_3p_str, user), target))),
225-
SPAN_NOTICE(capitalize(emote_replace_target_tokens(cast_message_1p_str, target)))
224+
SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(emote_replace_user_tokens(cast_message_3p_str, user), target))),
225+
SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(cast_message_1p_str, target)))
226226
)
227227
else if(cast_message_1p_str)
228-
user.visible_message(SPAN_NOTICE(capitalize(emote_replace_target_tokens(cast_message_1p_str, target))))
228+
user.visible_message(SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(cast_message_1p_str, target))))
229229
else if(cast_message_3p_str)
230-
user.visible_message(SPAN_NOTICE(capitalize(emote_replace_target_tokens(emote_replace_user_tokens(cast_message_3p_str, user), target))))
230+
user.visible_message(SPAN_NOTICE(capitalize_proper_html(emote_replace_target_tokens(emote_replace_user_tokens(cast_message_3p_str, user), target))))
231231

232232
/decl/ability/proc/prepare_to_cast(mob/user, atom/target, list/metadata, datum/ability_handler/handler)
233233
var/use_cooldown_time = get_cooldown_time(metadata)

code/datums/extensions/abilities/ability_handler.dm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@
226226
if(!prepared_ability)
227227
return FALSE
228228
if(prepared_ability.cancel_ability_1p_str)
229-
to_chat(owner, capitalize(emote_replace_user_tokens(prepared_ability.cancel_ability_1p_str), owner))
229+
to_chat(owner, capitalize_proper_html(emote_replace_user_tokens(prepared_ability.cancel_ability_1p_str), owner))
230230
var/obj/screen/ability/button/button = LAZYACCESS(screen_elements, prepared_ability)
231231
prepared_ability = null
232232
if(istype(button))
@@ -238,7 +238,7 @@
238238
return FALSE
239239
prepared_ability = ability
240240
if(ability.ready_ability_1p_str)
241-
to_chat(owner, capitalize(emote_replace_user_tokens(ability.ready_ability_1p_str), owner))
241+
to_chat(owner, capitalize_proper_html(emote_replace_user_tokens(ability.ready_ability_1p_str), owner))
242242
var/obj/screen/ability/button/button = LAZYACCESS(screen_elements, ability)
243243
if(istype(button))
244244
button.update_icon()

code/datums/extensions/milkable/milkable.dm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
if(critter.stat == DEAD)
7474
return FALSE
7575

76-
if(udder?.total_volume <= 0)
76+
if(REAGENT_TOTAL_VOLUME(udder) <= 0)
7777
to_chat(user, SPAN_WARNING("\The [critter]'s udder is dry. Wait a little longer."))
7878
return TRUE
7979

@@ -108,7 +108,7 @@
108108
if(critter.stat == DEAD)
109109
return FALSE
110110

111-
if(udder?.total_volume <= 0)
111+
if(REAGENT_TOTAL_VOLUME(udder) <= 0)
112112
to_chat(user, SPAN_WARNING("\The [critter]'s udder is dry. Wait a little longer."))
113113
return TRUE
114114

0 commit comments

Comments
 (0)