mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
Runtime sanity
This commit is contained in:
@@ -96,7 +96,9 @@
|
||||
internal_removed.temperature = final_temperature
|
||||
internal.merge(internal_removed)
|
||||
|
||||
parent.network.update = 1
|
||||
|
||||
if(parent && parent.network)
|
||||
parent.network.update = 1
|
||||
|
||||
/obj/machinery/atmospherics/pipe/simple/heat_exchanging/proc/radiate()
|
||||
var/datum/gas_mixture/internal = return_air()
|
||||
|
||||
@@ -84,7 +84,7 @@ var/global/list/facial_hair_styles_female_list = list()
|
||||
facial_hair_styles_male_list += H.name
|
||||
facial_hair_styles_female_list += H.name
|
||||
return
|
||||
|
||||
|
||||
/////////////////
|
||||
// GENE DEFINES
|
||||
/////////////////
|
||||
@@ -362,6 +362,8 @@ var/global/list/facial_hair_styles_female_list = list()
|
||||
|
||||
|
||||
/proc/EncodeDNABlock(var/value)
|
||||
if(!isnum(value))
|
||||
WARNING("Expected a number, got [value]")
|
||||
return add_zero2(num2hex(value,1), 3)
|
||||
|
||||
/datum/dna/proc/UpdateUI()
|
||||
|
||||
@@ -16,7 +16,8 @@
|
||||
..()
|
||||
if(src.z != map.zMainStation)
|
||||
var/area/A = src.areaMaster
|
||||
|
||||
if(!A)
|
||||
A = get_area(src)
|
||||
name = "[A.general_area_name] Alert Computer"
|
||||
general_area_name = A.general_area_name
|
||||
|
||||
|
||||
@@ -48,14 +48,14 @@
|
||||
..()
|
||||
|
||||
/obj/machinery/atmospherics/unary/cryo_cell/MouseDrop_T(atom/movable/O as mob|obj, mob/user as mob)
|
||||
if(!ismob(O)) //humans only
|
||||
return
|
||||
if(O.loc == user) //no you can't pull things out of your ass
|
||||
return
|
||||
if(user.restrained() || user.stat || user.weakened || user.stunned || user.paralysis || user.resting) //are you cuffed, dying, lying, stunned or other
|
||||
return
|
||||
if(O.anchored || get_dist(user, src) > 1 || get_dist(user, O) > 1 || user.contents.Find(src)) // is the mob anchored, too far away from you, or are you too far away from the source
|
||||
return
|
||||
if(!ismob(O)) //humans only
|
||||
return
|
||||
if(istype(O, /mob/living/simple_animal) || istype(O, /mob/living/silicon)) //animals and robutts dont fit
|
||||
return
|
||||
if(!ishuman(user) && !isrobot(user)) //No ghosts or mice putting people into the sleeper
|
||||
|
||||
@@ -28,8 +28,7 @@
|
||||
/obj/machinery/detector/proc/assess_perp(mob/living/carbon/human/perp as mob)
|
||||
var/threatcount = 0
|
||||
if(!(istype(perp, /mob/living/carbon)))
|
||||
return
|
||||
if(src.emagged == 2) return 10
|
||||
return -1
|
||||
|
||||
if(!src.allowed(perp))
|
||||
|
||||
@@ -95,10 +94,6 @@
|
||||
&& !istype(things, /obj/item/weapon/gun/energy/laser/practice))
|
||||
threatcount += 2
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if(idmode)
|
||||
//
|
||||
if(!perp.wear_id)
|
||||
@@ -109,24 +104,16 @@
|
||||
if(!perp.wear_id)
|
||||
threatcount += 2
|
||||
|
||||
|
||||
if(istype(perp.wear_suit, /obj/item/clothing/suit/wizrobe))
|
||||
threatcount += 2
|
||||
|
||||
if(perp.dna && perp.dna.mutantrace && perp.dna.mutantrace != "none")
|
||||
threatcount += 2
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//Agent cards lower threatlevel.
|
||||
//if(perp.wear_id && istype(perp:wear_id.GetID(), /obj/item/weapon/card/id/syndicate)) ///////////////nah, i dont think so
|
||||
// threatcount -= 2
|
||||
|
||||
|
||||
|
||||
|
||||
var/passperpname = ""
|
||||
for (var/datum/data/record/E in data_core.general)
|
||||
var/perpname = perp.name
|
||||
@@ -146,7 +133,8 @@
|
||||
break
|
||||
|
||||
var/list/retlist = list(threatcount, passperpname)
|
||||
|
||||
if(emagged)
|
||||
retlist[1] = 10
|
||||
return retlist
|
||||
|
||||
|
||||
@@ -273,6 +261,8 @@
|
||||
if (get_dist(src, O) > src.range)
|
||||
continue
|
||||
var/list/ourretlist = src.assess_perp(O)
|
||||
if(!istype(ourretlist) || !ourretlist.len)
|
||||
return
|
||||
var/dudesthreat = ourretlist[1]
|
||||
var/dudesname = ourretlist[2]
|
||||
|
||||
|
||||
@@ -386,7 +386,7 @@ var/list/obj/machinery/requests_console/allConsoles = list()
|
||||
msgVerified = "<font color='green'><b>Verified by [ID.registered_name] ([ID.assignment])</b></font>"
|
||||
updateUsrDialog()
|
||||
if(screen == 10)
|
||||
var/obj/item/weapon/card/id/ID = O
|
||||
var/obj/item/weapon/card/id/ID = O.GetID()
|
||||
if (access_RC_announce in ID.access)
|
||||
announceAuth = 1
|
||||
else
|
||||
|
||||
@@ -330,6 +330,25 @@ var/const/MAX_SAVE_SLOTS = 8
|
||||
else
|
||||
dat += "[copytext(flavor_text, 1, 37)]...<br>"
|
||||
|
||||
|
||||
if(!isnum(r_hair))
|
||||
WARNING("R_HAIR Expected a number")
|
||||
if(!isnum(g_hair))
|
||||
WARNING("G_HAIR Expected a number")
|
||||
if(!isnum(b_hair))
|
||||
WARNING("B_HAIR Expected a number")
|
||||
if(!isnum(r_facial))
|
||||
WARNING("R_FACIAL Expected a number")
|
||||
if(!isnum(g_facial))
|
||||
WARNING("G_FACIAL Expected a number")
|
||||
if(!isnum(b_facial))
|
||||
WARNING("B_FACIAL Expected a number")
|
||||
if(!isnum(r_eyes))
|
||||
WARNING("R_EYES Expected a number")
|
||||
if(!isnum(g_eyes))
|
||||
WARNING("G_EYES Expected a number")
|
||||
if(!isnum(b_eyes))
|
||||
WARNING("B_EYES Expected a number")
|
||||
// AUTOFIXED BY fix_string_idiocy.py
|
||||
// C:\Users\Rob\Documents\Projects\vgstation13\code\modules\client\preferences.dm:335: dat += "<br>"
|
||||
dat += {"<br>
|
||||
|
||||
@@ -376,7 +376,7 @@ var/global/ingredientLimit = 10
|
||||
sleep(src.cookTime/3)
|
||||
if(src.ingredient) src.ingredient.color = "#C28566"
|
||||
sleep(src.cookTime/3)
|
||||
src.ingredient.color = "#A34719"
|
||||
if(src.ingredient) src.ingredient.color = "#A34719"
|
||||
sleep(src.cookTime/3)
|
||||
src.icon_state = initial(src.icon_state)
|
||||
src.active = 0
|
||||
|
||||
@@ -401,7 +401,10 @@
|
||||
eye_blurry = 0
|
||||
ear_deaf = 0
|
||||
ear_damage = 0
|
||||
reagents.clear_reagents()
|
||||
if(!reagents)
|
||||
create_reagents(1000)
|
||||
else
|
||||
reagents.clear_reagents()
|
||||
heal_overall_damage(1000, 1000)
|
||||
ExtinguishMob()
|
||||
fire_stacks = 0
|
||||
|
||||
@@ -124,6 +124,9 @@ json_reader
|
||||
|
||||
var/json_token/S = get_token()
|
||||
check_type(/json_token/symbol)
|
||||
if(!S)
|
||||
die()
|
||||
return
|
||||
switch(S.value)
|
||||
if(",")
|
||||
next_token()
|
||||
|
||||
@@ -95,7 +95,7 @@ datum
|
||||
return the_id
|
||||
|
||||
trans_to(var/obj/target, var/amount=1, var/multiplier=1, var/preserve_data=1)//if preserve_data=0, the reagents data will be lost. Usefull if you use data for some strange stuff and don't want it to be transferred.
|
||||
if (!target )
|
||||
if (!target)
|
||||
return
|
||||
if (!target.reagents || src.total_volume<=0)
|
||||
return
|
||||
|
||||
@@ -199,11 +199,13 @@
|
||||
|
||||
for(var/i=1;i<=research_queue.len;i++)
|
||||
var/datum/design/mechanic_design/research_item = research_queue[i]
|
||||
todo_queue.Add(list(list("name" = research_item.name, "command1" = list("research" = i), "command2" = list("remove_tosearch" = i))))
|
||||
if(istype(research_item, /datum/design/mechanic_design))
|
||||
todo_queue.Add(list(list("name" = research_item.name, "command1" = list("research" = i), "command2" = list("remove_tosearch" = i))))
|
||||
|
||||
for(var/i=1;i<=ready_queue.len;i++)
|
||||
var/datum/design/mechanic_design/ready_item = ready_queue[i]
|
||||
done_queue.Add(list(list("name" = ready_item.name, "command1" = list("print_design" = i), "command2" = list("nanoprint_design" = i), "command3" = list("remove_researched" = i))))
|
||||
if(istype(ready_item,/datum/design/mechanic_design))
|
||||
done_queue.Add(list(list("name" = ready_item.name, "command1" = list("print_design" = i), "command2" = list("nanoprint_design" = i), "command3" = list("remove_researched" = i))))
|
||||
|
||||
data["research_queue"] = todo_queue
|
||||
data["ready_queue"] = done_queue
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
if(L.len >= pos && !(pos > L.len))
|
||||
return L[pos]
|
||||
else
|
||||
if(L.len >= pos)
|
||||
if(L.len >= pos && !(pos > L.len))
|
||||
L[pos] = value
|
||||
else if(istext(pos))
|
||||
if(!value)
|
||||
|
||||
Reference in New Issue
Block a user