Merge pull request #11818 from spookydonut/patch-1

Update spacemandmm to 1.4
This commit is contained in:
Ghom
2020-04-11 23:59:31 +02:00
committed by GitHub
43 changed files with 60 additions and 98 deletions
+2
View File
@@ -0,0 +1,2 @@
[langserver]
dreamchecker = true
-2
View File
@@ -8,10 +8,8 @@
/proc/invertHTML(HTMLstring)
if(!istext(HTMLstring))
CRASH("Given non-text argument!")
return
else if(length(HTMLstring) != 7)
CRASH("Given non-HTML argument!")
return
else if(length_char(HTMLstring) != 7)
CRASH("Given non-hex symbols in argument!")
var/textr = copytext(HTMLstring, 2, 4)
-2
View File
@@ -27,13 +27,11 @@
var/hook_path = text2path("/hook/[hook]")
if(!hook_path)
CRASH("Invalid hook '/hook/[hook]' called.")
return 0
var/caller = new hook_path
var/status = 1
for(var/P in typesof("[hook_path]/proc"))
if(!call(caller, P)(arglist(args)))
CRASH("Hook '[P]' failed or runtimed.")
status = 0
return status
@@ -47,7 +47,6 @@ PROCESSING_SUBSYSTEM_DEF(weather)
break
if (!ispath(weather_datum_type, /datum/weather))
CRASH("run_weather called with invalid weather_datum_type: [weather_datum_type || "null"]")
return
if (isnull(z_levels))
z_levels = SSmapping.levels_by_trait(initial(weather_datum_type.target_trait))
@@ -55,7 +54,6 @@ PROCESSING_SUBSYSTEM_DEF(weather)
z_levels = list(z_levels)
else if (!islist(z_levels))
CRASH("run_weather called with invalid z_levels: [z_levels || "null"]")
return
var/datum/weather/W = new weather_datum_type(z_levels)
W.telegraph()
+1 -2
View File
@@ -25,7 +25,6 @@
RegisterSignal(parent, COMSIG_ITEM_ATTACK_OBJ, .proc/rad_attack)
else
CRASH("Something that wasn't an atom was given /datum/component/radioactive")
return
if(strength > RAD_MINIMUM_CONTAMINATION)
SSradiation.warn(src)
@@ -84,4 +83,4 @@
#undef RAD_AMOUNT_LOW
#undef RAD_AMOUNT_MEDIUM
#undef RAD_AMOUNT_HIGH
#undef RAD_AMOUNT_EXTREME
#undef RAD_AMOUNT_EXTREME
-1
View File
@@ -19,7 +19,6 @@
var/datum/component/wet_floor/WF = newcomp //Lets make an assumption
if(WF.gc()) //See if it's even valid, still. Also does LAZYLEN and stuff for us.
CRASH("Wet floor component tried to inherit another, but the other was able to garbage collect while being inherited! What a waste of time!")
return
for(var/i in WF.time_left_list)
add_wet(text2num(i), WF.time_left_list[i])
-2
View File
@@ -175,11 +175,9 @@
if(!islist(jsonlist))
if(!istext(jsonlist))
CRASH("Invalid JSON")
return
jsonlist = json_decode(jsonlist)
if(!islist(jsonlist))
CRASH("Invalid JSON")
return
if(!jsonlist["DATUM_TYPE"])
return
if(!ispath(jsonlist["DATUM_TYPE"]))
-1
View File
@@ -38,7 +38,6 @@
..()
if(!istype(holder, holder_type))
CRASH("Wire holder is not of the expected type!")
return
src.holder = holder
if(randomize)
-2
View File
@@ -147,7 +147,6 @@
return "health-85"
else
return "health-100"
return "0"
//HOOKS
@@ -323,7 +322,6 @@
return "crit"
else
return "dead"
return "dead"
//Sillycone hooks
/mob/living/silicon/proc/diag_hud_set_health()
-2
View File
@@ -381,14 +381,12 @@
for(var/obj/machinery/camera/C in oview(4, M))
if(C.can_use()) // check if camera disabled
return C
break
return null
/proc/near_range_camera(var/mob/M)
for(var/obj/machinery/camera/C in range(4, M))
if(C.can_use()) // check if camera disabled
return C
break
return null
+2 -2
View File
@@ -45,11 +45,11 @@
if (ismob(user) && !isliving(user)) // ghosts don't need cameras
return
if (!network)
CRASH("No camera network")
stack_trace("No camera network")
user.unset_machine()
return FALSE
if (!(islist(network)))
CRASH("Camera network is not a list")
stack_trace("Camera network is not a list")
user.unset_machine()
return FALSE
-1
View File
@@ -469,7 +469,6 @@ GLOBAL_LIST_EMPTY(allConsoles)
if(newmessagepriority < EXTREME_MESSAGE_PRIORITY)
newmessagepriority = EXTREME_MESSAGE_PRIORITY
update_icon()
if(1)
playsound(src, 'sound/machines/twobeep.ogg', 50, 1)
say(title)
messages += "<span class='bad'>!!!Extreme Priority!!!</span><BR><b>From:</b> [linkedsender]<BR>[message]"
-1
View File
@@ -223,7 +223,6 @@ obj/item/twohanded/rcl/proc/getMobhook(mob/to_hook)
continue
if(C.d1 == 0)
return C
break
return
+2 -2
View File
@@ -807,9 +807,9 @@ GLOBAL_LIST_EMPTY(PDAs)
// If it didn't reach, note that fact
if (!signal.data["done"])
to_chat(user, "<span class='notice'>ERROR: Server isn't responding.</span>")
return
if (!silent)
playsound(src, 'sound/machines/terminal_error.ogg', 15, 1)
return
var/target_text = signal.format_target()
if(allow_emojis)
@@ -998,9 +998,9 @@ GLOBAL_LIST_EMPTY(PDAs)
var/obj/item/card/id/idcard = C
if(!idcard.registered_name)
to_chat(user, "<span class='warning'>\The [src] rejects the ID!</span>")
return
if (!silent)
playsound(src, 'sound/machines/terminal_error.ogg', 15, 1)
return
if(!owner)
owner = idcard.registered_name
+2 -2
View File
@@ -692,14 +692,14 @@ Code:
return
GLOB.news_network.SubmitArticle(message,host_pda.owner,current_channel)
host_pda.Topic(null,list("choice"=num2text(host_pda.mode)))
return
playsound(src, 'sound/machines/terminal_select.ogg', 50, 1)
return
if("Newscaster Switch Channel")
current_channel = host_pda.msg_input()
host_pda.Topic(null,list("choice"=num2text(host_pda.mode)))
return
playsound(src, 'sound/machines/terminal_select.ogg', 50, 1)
return
//emoji previews
if(href_list["emoji"])
+1 -1
View File
@@ -23,8 +23,8 @@
/datum/borgpanel/New(to_user, mob/living/silicon/robot/to_borg)
if(!istype(to_borg))
CRASH("Borg panel is only available for borgs")
qdel(src)
CRASH("Borg panel is only available for borgs")
user = CLIENT_FROM_VAR(to_user)
@@ -209,7 +209,6 @@
open_machine()
SendBack(H)
return "<span class='bad'>Specimen braindead - disposed.</span>"
return "<span class='bad'>ERROR</span>"
/obj/machinery/abductor/experiment/proc/SendBack(mob/living/carbon/human/H)
@@ -84,7 +84,6 @@
/obj/machinery/atmospherics/components/proc/nullifyPipenet(datum/pipeline/reference)
if(!reference)
CRASH("nullifyPipenet(null) called by [type] on [COORD(src)]")
return
var/i = parents.Find(reference)
reference.other_airs -= airs[i]
reference.other_atmosmch -= src
@@ -168,4 +167,4 @@
/obj/machinery/atmospherics/components/analyzer_act(mob/living/user, obj/item/I)
atmosanalyzer_scan(airs, user, src)
atmosanalyzer_scan(airs, user, src)
@@ -131,7 +131,6 @@
var/datum/pipeline/P = returnPipenet(A)
if(!P)
CRASH("null.addMember() called by [type] on [COORD(src)]")
return
P.addMember(A, src)
@@ -488,7 +488,6 @@ force_open = FALSE, datum/tgui/master_ui = null, datum/ui_state/state = GLOB.adm
if (isnull(A)) //If theres no supplypod bay mapped into centcom, throw an error
to_chat(holder.mob, "No /area/centcom/supplypod/loading/one (or /two or /three or /four) in the world! You can make one yourself (then refresh) for now, but yell at a mapper to fix this, today!")
CRASH("No /area/centcom/supplypod/loading/one (or /two or /three or /four) has been mapped into the centcom z-level!")
return
orderedArea = list()
if (!isemptylist(A.contents)) //Go through the area passed into the proc, and figure out the top left and bottom right corners by calculating max and min values
var/startX = A.contents[1].x //Create the four values (we do it off a.contents[1] so they have some sort of arbitrary initial value. They should be overwritten in a few moments)
@@ -170,7 +170,6 @@
to_chat(user, "<span class='notice'>You refill the suit's built-in extinguisher, using up the cartridge.</span>")
qdel(E)
return
return
return
/obj/item/extinguisher_refill
@@ -287,7 +287,7 @@
/obj/machinery/microwave/proc/loop(type, time, wait = max(12 - 2 * efficiency, 2)) // standard wait is 10
if(stat & (NOPOWER|BROKEN))
if(MICROWAVE_PRE)
if(type == MICROWAVE_PRE)
pre_fail()
return
if(!time)
@@ -353,4 +353,4 @@
#undef MICROWAVE_NORMAL
#undef MICROWAVE_MUCK
#undef MICROWAVE_PRE
#undef MICROWAVE_PRE
@@ -18,8 +18,8 @@
var/datum/integrated_io/I = inputs[1]
set_pin_data(IC_OUTPUT, 1, null)
if(!isweakref(I.data))
return
activate_pin(3)
return
var/atom/A = I.data.resolve()
if(!A)
activate_pin(3)
-1
View File
@@ -430,7 +430,6 @@
else
dropItemToGround(I)
return
return TRUE
/mob/living/carbon/get_standard_pixel_y_offset(lying = 0)
if(lying)
@@ -893,7 +893,7 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
accessory_overlay.icon_state = "m_ears_none_[layertext]"
if(bodypart == "tail")
accessory_overlay.icon_state = "m_tail_husk_[layertext]"
if(MATRIXED)
if(S.color_src == MATRIXED)
var/list/husklist = list()
husklist += ReadRGB("#a3a3a3")
husklist += ReadRGB("#a3a3a3")
+1 -1
View File
@@ -695,7 +695,7 @@
holo_icon = client.prefs.get_filtered_holoform(HOLOFORM_FILTER_AI)
else
holo_icon = getHologramIcon(icon('icons/mob/ai.dmi', "female"))
else if("xeno queen")
if("xeno queen")
holo_icon = getHologramIcon(icon(icon_list[input],"alienq"))
else
holo_icon = getHologramIcon(icon(icon_list[input], input))
@@ -445,7 +445,6 @@ Pass the desired type path itself, declaring a temporary var beforehand is not r
return scan_result
else
return FALSE //The current element failed assessment, move on to the next.
return
/mob/living/simple_animal/bot/proc/check_bot(targ)
var/turf/T = get_turf(targ)
@@ -523,9 +523,6 @@
soft_reset()
return
reagent_id = null
return
/mob/living/simple_animal/bot/medbot/proc/check_overdose(mob/living/carbon/patient,reagent_id,injection_amount)
var/datum/reagent/R = GLOB.chemical_reagents_list[reagent_id]
if(!R.overdose_threshold) //Some chems do not have an OD threshold
@@ -92,8 +92,8 @@
return
if(hack)
if(hacked)
return
Stun(40)
return
if(clockwork)
to_chat(src, "<span class='large_brass'><b>ERROR: LAW OVERRIDE DETECTED</b></span>")
to_chat(src, "<span class='heavy_brass'>From now on, these are your laws:</span>")
@@ -20,7 +20,6 @@
. = ..()
if(!loc || !istype(loc, /obj/machinery/modular_computer))
CRASH("Inapropriate type passed to obj/item/modular_computer/processor/New()! Aborting.")
return
// Obtain reference to machinery computer
all_components = list()
idle_threads = list()
@@ -69,4 +68,4 @@
if(MC_SDD)
machinery_computer.verbs -= /obj/machinery/modular_computer/proc/eject_disk
if(MC_AI)
machinery_computer.verbs -= /obj/machinery/modular_computer/proc/eject_card
machinery_computer.verbs -= /obj/machinery/modular_computer/proc/eject_card
@@ -54,7 +54,6 @@
holder.shutdown_computer()
return TRUE
return FALSE
@@ -95,4 +94,4 @@
name = "nano battery"
desc = "A tiny power cell, commonly seen in low-end portable microcomputers."
icon_state = "cell_micro"
maxcharge = 300
maxcharge = 300
-1
View File
@@ -8,7 +8,6 @@
item_flags = NOBLUDGEON
/obj/item/paper/contract/ComponentInitialize()
return
. = ..()
AddElement(/datum/element/update_icon_blocker)
@@ -60,13 +60,12 @@
continue
vv_edit_var(v, initial(vars[v]))
vars[v] = initial(vars[v])
QDEL_NULL(chambered.BB)
QDEL_NULL(chambered.BB)
chambered.newshot()
/obj/item/gun/energy/laser/chameleon/proc/set_chameleon_ammo(obj/item/ammo_casing/AC, passthrough = TRUE, reset = FALSE)
if(!istype(AC))
CRASH("[AC] is not /obj/item/ammo_casing!")
return FALSE
for(var/V in ammo_copy_vars)
if(AC.vars.Find(V))
chameleon_ammo_vars[V] = AC.vars[V]
@@ -78,7 +77,6 @@
/obj/item/gun/energy/laser/chameleon/proc/set_chameleon_projectile(obj/item/projectile/P)
if(!istype(P))
CRASH("[P] is not /obj/item/projectile!")
return FALSE
chameleon_projectile_vars = list("name" = "practice laser", "icon" = 'icons/obj/projectiles.dmi', "icon_state" = "laser", "nodamage" = TRUE)
for(var/V in projectile_copy_vars)
if(P.vars.Find(V))
@@ -99,7 +97,6 @@
/obj/item/gun/energy/laser/chameleon/proc/set_chameleon_gun(obj/item/gun/G , passthrough = TRUE)
if(!istype(G))
CRASH("[G] is not /obj/item/gun!")
return FALSE
for(var/V in gun_copy_vars)
if(vars.Find(V) && G.vars.Find(V))
chameleon_gun_vars[V] = G.vars[V]
@@ -972,7 +972,6 @@
if(isnull(amount))
amount = 0
CRASH("null amount passed to reagent code")
return FALSE
if(!isnum(amount))
return FALSE
@@ -331,7 +331,6 @@
else
to_chat(user, "<span class='notice'>This doesn't fit in [src].</span>")
return FALSE
return FALSE
/obj/item/hypospray/mkii/AltClick(mob/user)
. = ..()
+1 -1
View File
@@ -436,7 +436,7 @@
if(!isnull(body_markings) && status == BODYPART_ORGANIC)
if(!use_digitigrade)
if(BODY_ZONE_CHEST)
if(body_zone == BODY_ZONE_CHEST)
. += image(body_markings_icon, "[body_markings]_[body_zone]_[icon_gender]", -MARKING_LAYER, image_dir)
else
. += image(body_markings_icon, "[body_markings]_[body_zone]", -MARKING_LAYER, image_dir)
-1
View File
@@ -40,7 +40,6 @@
if(ishuman(target))
var/mob/living/carbon/human/H = target
H.sec_hud_set_ID()
return 1
return TRUE
/datum/surgery_step/reshape_face/failure(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
+29 -28
View File
@@ -234,28 +234,28 @@ IF YOU MODIFY THE PRODUCTS LIST OF A MACHINE, MAKE SURE TO UPDATE ITS RESUPPLY C
if(!.)
return
var/dump_amount = 0
var/found_anything = TRUE
while (found_anything)
found_anything = FALSE
for(var/record in shuffle(product_records))
var/datum/data/vending_product/R = record
if(R.amount <= 0) //Try to use a record that actually has something to dump.
continue
var/dump_path = R.product_path
if(!dump_path)
continue
R.amount--
// busting open a vendor will destroy some of the contents
if(found_anything && prob(80))
continue
var/dump_amount = 0
var/found_anything = TRUE
while (found_anything)
found_anything = FALSE
for(var/record in shuffle(product_records))
var/datum/data/vending_product/R = record
if(R.amount <= 0) //Try to use a record that actually has something to dump.
continue
var/dump_path = R.product_path
if(!dump_path)
continue
R.amount--
// busting open a vendor will destroy some of the contents
if(found_anything && prob(80))
continue
var/obj/O = new dump_path(loc)
step(O, pick(GLOB.alldirs))
found_anything = TRUE
dump_amount++
if (dump_amount >= 16)
return
var/obj/O = new dump_path(loc)
step(O, pick(GLOB.alldirs))
found_anything = TRUE
dump_amount++
if (dump_amount >= 16)
return
GLOBAL_LIST_EMPTY(vending_products)
/**
@@ -628,14 +628,15 @@ GLOBAL_LIST_EMPTY(vending_products)
SSblackbox.record_feedback("nested tally", "vending_machine_usage", 1, list("[type]", "[R.product_path]"))
vend_ready = TRUE
return
if("takeoutcoin")
usr.put_in_hands(coin)
to_chat(usr, "<span class='notice'>You remove [coin] from [src].</span>")
coin = null
return
if("takeoutcoin")
usr.put_in_hands(coin)
to_chat(usr, "<span class='notice'>You remove [coin] from [src].</span>")
coin = null
return
else if("togglevoice" && panel_open)
shut_up = !shut_up
if("togglevoice")
if(panel_open)
shut_up = !shut_up
/obj/machinery/vending/process()
if(stat & (BROKEN|NOPOWER))
-1
View File
@@ -558,7 +558,6 @@
to_chat(R,"<span class='warning'>Your attempt to escape [lowertext(name)] has failed!</span>")
to_chat(owner,"<span class='notice'>The attempt to escape from your [lowertext(name)] has failed!</span>")
return
return
var/struggle_outer_message = pick(struggle_messages_outside)
var/struggle_user_message = pick(struggle_messages_inside)
+5 -7
View File
@@ -16,15 +16,14 @@ The proc you're attemping should return nonzero values on success.
try
if(!callon || !procname)
CRASH("attempt_vr: Invalid obj/proc: [callon]/[procname]")
return 0
var/result = call(callon,procname)(arglist(args))
return result
catch(var/exception/e)
CRASH("attempt_vr runtimed when calling [procname] on [callon].")
CRASH("attempt_vr catch: [e] on [e.file]:[e.line]")
stack_trace("attempt_vr runtimed when calling [procname] on [callon].")
stack_trace("attempt_vr catch: [e] on [e.file]:[e.line]")
return 0
/*
@@ -46,17 +45,16 @@ The hooks you're calling should return nonzero values on success.
var/hook_path = text2path("/hook/[hook]")
if(!hook_path)
CRASH("hook_vr: Invalid hook '/hook/[hook]' called.")
return 0
var/caller = new hook_path
var/status = 1
for(var/P in typesof("[hook_path]/proc"))
if(!call(caller, P)(arglist(args)))
CRASH("hook_vr: Hook '[P]' failed or runtimed.")
stack_trace("hook_vr: Hook '[P]' failed or runtimed.")
status = 0
return status
catch(var/exception/e)
CRASH("hook_vr itself failed or runtimed. Exception below.")
CRASH("hook_vr catch: [e] on [e.file]:[e.line]")
stack_trace("hook_vr itself failed or runtimed. Exception below.")
stack_trace("hook_vr catch: [e] on [e.file]:[e.line]")
+1 -1
View File
@@ -23,4 +23,4 @@ export NODE_VERSION=12
export PHP_VERSION=5.6
# SpacemanDMM git tag
export SPACEMAN_DMM_VERSION=suite-1.3
export SPACEMAN_DMM_VERSION=suite-1.4
@@ -364,11 +364,10 @@
if(ishuman(src) && dna.species.id == "human")
dna.features["genitals_use_skintone"] = TRUE
dna.species.use_skintones = TRUE
if(MUTCOLORS)
if(src.dna.species.fixed_mut_color)
dna.features["cock_color"] = "[dna.species.fixed_mut_color]"
dna.features["breasts_color"] = "[dna.species.fixed_mut_color]"
return
if(src.dna.species.fixed_mut_color)
dna.features["cock_color"] = "[dna.species.fixed_mut_color]"
dna.features["breasts_color"] = "[dna.species.fixed_mut_color]"
return
//So people who haven't set stuff up don't get rainbow surprises.
dna.features["cock_color"] = "[dna.features["mcolor"]]"
dna.features["breasts_color"] = "[dna.features["mcolor"]]"
@@ -54,7 +54,6 @@
to_chat(user, "<span class='warning'>[src] is empty!</span>")
add_fingerprint(user)
return
..()
/obj/item/fermichem/pHpaper
name = "pH indicator strip"