mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 16:18:01 +01:00
Grep for proc(var/bad) (#54848)
This commit is contained in:
@@ -138,7 +138,7 @@ GLOBAL_VAR_INIT(cmp_field, "name")
|
||||
* This prevents any reagent_containers from being consumed before the reagents they contain, which can
|
||||
* lead to runtimes and item duplication when it happens.
|
||||
*/
|
||||
/proc/cmp_crafting_req_priority(var/A, var/B)
|
||||
/proc/cmp_crafting_req_priority(A, B)
|
||||
var/lhs
|
||||
var/rhs
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
var/perlin_zoom = 65
|
||||
|
||||
///Seeds the rust-g perlin noise with a random number.
|
||||
/datum/map_generator/jungle_generator/generate_terrain(var/list/turfs)
|
||||
/datum/map_generator/jungle_generator/generate_terrain(list/turfs)
|
||||
. = ..()
|
||||
var/height_seed = rand(0, 50000)
|
||||
var/humidity_seed = rand(0, 50000)
|
||||
|
||||
@@ -2,5 +2,5 @@
|
||||
/datum/map_generator
|
||||
|
||||
///This proc will be ran by areas on Initialize, and provides the areas turfs as argument to allow for generation.
|
||||
/datum/map_generator/proc/generate_terrain(var/list/turfs)
|
||||
/datum/map_generator/proc/generate_terrain(list/turfs)
|
||||
return
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
var/list/fauna_types = list()
|
||||
|
||||
///This proc handles the creation of a turf of a specific biome type
|
||||
/datum/biome/proc/generate_turf(var/turf/gen_turf)
|
||||
/datum/biome/proc/generate_turf(turf/gen_turf)
|
||||
gen_turf.ChangeTurf(turf_type, null, CHANGETURF_DEFER_CHANGE)
|
||||
if(length(fauna_types) && prob(fauna_density))
|
||||
var/mob/fauna = pick(fauna_types)
|
||||
|
||||
@@ -83,7 +83,7 @@
|
||||
* * user - The user of the proc
|
||||
* * where - The mechpad that the connected mechpad will try to send a supply pod to
|
||||
*/
|
||||
/obj/machinery/computer/mechpad/proc/try_launch(var/mob/user, var/obj/machinery/mechpad/where)
|
||||
/obj/machinery/computer/mechpad/proc/try_launch(mob/user, obj/machinery/mechpad/where)
|
||||
if(!connected_mechpad)
|
||||
to_chat(user, "<span class='warning'>[src] has no connected pad!</span>")
|
||||
return
|
||||
|
||||
@@ -271,7 +271,7 @@ GLOBAL_LIST_EMPTY(tcgcard_radial_choices)
|
||||
* *User: The person doing the shuffling, used in visable message and closing UI.
|
||||
* *Visible: Will anyone need to hear the visable message about the shuffling?
|
||||
*/
|
||||
/obj/item/tcgcard_deck/proc/shuffle_deck(mob/user, var/visable = TRUE)
|
||||
/obj/item/tcgcard_deck/proc/shuffle_deck(mob/user, visable = TRUE)
|
||||
if(!contents)
|
||||
return
|
||||
contents = shuffle(contents)
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
return list(turn(dir, 180), dir)
|
||||
|
||||
///Used by binary devices to set what the offset will be for each layer
|
||||
/obj/machinery/atmospherics/components/binary/proc/set_overlay_offset(var/pipe_layer)
|
||||
/obj/machinery/atmospherics/components/binary/proc/set_overlay_offset(pipe_layer)
|
||||
switch(pipe_layer)
|
||||
if(1, 3, 5)
|
||||
return 1
|
||||
|
||||
@@ -47,7 +47,7 @@ Housekeeping and pipe network stuff
|
||||
|
||||
return list(node1_connect, node2_connect, node3_connect)
|
||||
|
||||
/obj/machinery/atmospherics/components/trinary/proc/set_overlay_offset(var/pipe_layer)
|
||||
/obj/machinery/atmospherics/components/trinary/proc/set_overlay_offset(pipe_layer)
|
||||
switch(pipe_layer)
|
||||
if(1)
|
||||
return 1
|
||||
|
||||
@@ -548,7 +548,7 @@
|
||||
var/turf/drop = locate(coords_list[1], coords_list[2], coords_list[3])
|
||||
setupView(RANGE_TURFS(3, drop))
|
||||
|
||||
/datum/centcom_podlauncher/proc/setupView(var/list/visible_turfs)
|
||||
/datum/centcom_podlauncher/proc/setupView(list/visible_turfs)
|
||||
var/list/bbox = get_bbox_of_atoms(visible_turfs)
|
||||
var/size_x = bbox[3] - bbox[1] + 1
|
||||
var/size_y = bbox[4] - bbox[2] + 1
|
||||
@@ -557,7 +557,7 @@
|
||||
cam_background.icon_state = "clear"
|
||||
cam_background.fill_rect(1, 1, size_x, size_y)
|
||||
|
||||
/datum/centcom_podlauncher/proc/updateCursor(var/forceClear = FALSE) //Update the mouse of the user
|
||||
/datum/centcom_podlauncher/proc/updateCursor(forceClear = FALSE) //Update the mouse of the user
|
||||
if (!holder) //Can't update the mouse icon if the client doesnt exist!
|
||||
return
|
||||
if (!forceClear && (launcherActivated || picking_dropoff_turf)) //If the launching param is true, we give the user new mouse icons.
|
||||
@@ -795,7 +795,7 @@
|
||||
for (var/mob/living/M in whoDyin)
|
||||
admin_ticket_log(M, "[key_name_admin(usr)] [msg]")
|
||||
|
||||
/datum/centcom_podlauncher/proc/loadData(var/list/dataToLoad)
|
||||
/datum/centcom_podlauncher/proc/loadData(list/dataToLoad)
|
||||
bayNumber = dataToLoad["bayNumber"]
|
||||
customDropoff = dataToLoad["customDropoff"]
|
||||
renderLighting = dataToLoad["renderLighting"]
|
||||
|
||||
@@ -511,7 +511,7 @@
|
||||
* * bite: /atom the reagents to expel
|
||||
* * amount: int The amount of reagent
|
||||
*/
|
||||
/mob/living/carbon/proc/expel_ingested(var/atom/bite, amount)
|
||||
/mob/living/carbon/proc/expel_ingested(atom/bite, amount)
|
||||
visible_message("<span class='danger'>[src] throws up all over [p_them()]self!</span>", \
|
||||
"<span class='userdanger'>You are unable to keep the [bite] down without a stomach!</span>")
|
||||
|
||||
|
||||
@@ -1107,7 +1107,7 @@
|
||||
* Arguments:
|
||||
* arg1: a string containing the message to log.
|
||||
*/
|
||||
/mob/living/silicon/robot/proc/logevent(var/string = "")
|
||||
/mob/living/silicon/robot/proc/logevent(string = "")
|
||||
if(!string)
|
||||
return
|
||||
if(stat == DEAD) //Dead borgs log no longer
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
*transfer, if TRUE and access_to_check is null, will tell this proc to use the program's transfer_access in place of access_to_check
|
||||
*access can contain a list of access numbers to check against. If access is not empty, it will be used istead of checking any inserted ID.
|
||||
*/
|
||||
/datum/computer_file/program/proc/can_run(mob/user, loud = FALSE, access_to_check, transfer = FALSE, var/list/access)
|
||||
/datum/computer_file/program/proc/can_run(mob/user, loud = FALSE, access_to_check, transfer = FALSE, list/access)
|
||||
// Defaults to required_access
|
||||
if(!access_to_check)
|
||||
if(transfer && transfer_access)
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
/datum/computer_file/program/budgetorders/proc/get_export_categories()
|
||||
. = EXPORT_CARGO
|
||||
|
||||
/datum/computer_file/program/budgetorders/proc/is_visible_pack(mob/user, paccess_to_check, var/list/access, var/contraband)
|
||||
/datum/computer_file/program/budgetorders/proc/is_visible_pack(mob/user, paccess_to_check, list/access, contraband)
|
||||
if(issilicon(user)) //Borgs can't buy things.
|
||||
return FALSE
|
||||
if(computer.obj_flags & EMAGGED)
|
||||
|
||||
@@ -10,7 +10,8 @@
|
||||
WARNING("Invalid boost information for node \[[id]\]: [message]")
|
||||
SSresearch.invalid_node_boost[id] = message
|
||||
|
||||
/proc/techweb_item_boost_check(obj/item/I) //Returns an associative list of techweb node datums with values of the boost it gives. var/list/returned = list()
|
||||
///Returns an associative list of techweb node datums with values of the boost it gives. var/list/returned = list()
|
||||
/proc/techweb_item_boost_check(obj/item/I)
|
||||
if(SSresearch.techweb_boost_items[I.type])
|
||||
return SSresearch.techweb_boost_items[I.type] //It should already be formatted in node datum = list(point type = value)
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
var/mutable_appearance/overlay2 = mutable_appearance(icon, "petri_dish_overlay2")
|
||||
. += overlay2
|
||||
|
||||
/obj/item/petri_dish/proc/deposit_sample(user, var/datum/biological_sample/deposited_sample)
|
||||
/obj/item/petri_dish/proc/deposit_sample(user, datum/biological_sample/deposited_sample)
|
||||
sample = deposited_sample
|
||||
to_chat(user, "<span class='notice'>You deposit a sample into [src].</span>")
|
||||
update_icon()
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
var/list/resulting_atoms = list()
|
||||
|
||||
///Handles growth of the micro_organism. This only runs if the micro organism is in the growing vat. Reagents is the growing vats reagents
|
||||
/datum/micro_organism/cell_line/proc/handle_growth(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/micro_organism/cell_line/proc/handle_growth(obj/machinery/plumbing/growing_vat/vat)
|
||||
if(!try_eat(vat.reagents))
|
||||
return FALSE
|
||||
growth = max(growth, growth + calculate_growth(vat.reagents, vat.biological_sample)) //Prevent you from having minus growth.
|
||||
@@ -36,7 +36,7 @@
|
||||
return TRUE
|
||||
|
||||
///Tries to consume the required reagents. Can only do this if all of them are available. Reagents is the growing vats reagents
|
||||
/datum/micro_organism/cell_line/proc/try_eat(var/datum/reagents/reagents)
|
||||
/datum/micro_organism/cell_line/proc/try_eat(datum/reagents/reagents)
|
||||
for(var/i in required_reagents)
|
||||
if(!reagents.has_reagent(i))
|
||||
return FALSE
|
||||
@@ -45,7 +45,7 @@
|
||||
return TRUE
|
||||
|
||||
///Apply modifiers on growth_rate based on supplementary and supressive reagents. Reagents is the growing vats reagents
|
||||
/datum/micro_organism/cell_line/proc/calculate_growth(var/datum/reagents/reagents, var/datum/biological_sample/biological_sample)
|
||||
/datum/micro_organism/cell_line/proc/calculate_growth(datum/reagents/reagents, datum/biological_sample/biological_sample)
|
||||
. = growth_rate
|
||||
|
||||
//Handle growth based on supplementary reagents here.
|
||||
@@ -70,7 +70,7 @@
|
||||
. -= virus_suspectibility
|
||||
|
||||
///Called once a cell line reaches 100 growth. Then we check if any cell_line is too far so we can perform an epic fail roll
|
||||
/datum/micro_organism/cell_line/proc/finish_growing(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/micro_organism/cell_line/proc/finish_growing(obj/machinery/plumbing/growing_vat/vat)
|
||||
var/risk = 0 //Penalty for failure, goes up based on how much growth the other cell_lines have
|
||||
|
||||
for(var/datum/micro_organism/cell_line/cell_line in vat.biological_sample.micro_organisms)
|
||||
@@ -85,14 +85,14 @@
|
||||
succeed_growing(vat)
|
||||
return TRUE
|
||||
|
||||
/datum/micro_organism/cell_line/proc/fuck_up_growing(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/micro_organism/cell_line/proc/fuck_up_growing(obj/machinery/plumbing/growing_vat/vat)
|
||||
vat.visible_message("<span class='warning'>The biological sample in [vat] seems to have dissipated!</span>")
|
||||
QDEL_NULL(vat.biological_sample) //Kill off the sample, we're done
|
||||
if(prob(50))
|
||||
new /obj/effect/gibspawner/generic(get_turf(vat)) //Spawn some gibs.
|
||||
|
||||
|
||||
/datum/micro_organism/cell_line/proc/succeed_growing(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/micro_organism/cell_line/proc/succeed_growing(obj/machinery/plumbing/growing_vat/vat)
|
||||
var/datum/effect_system/smoke_spread/smoke = new
|
||||
smoke.set_up(0, vat.loc)
|
||||
smoke.start()
|
||||
@@ -112,7 +112,7 @@
|
||||
. += return_reagent_text("It hates:", suppressive_reagents)
|
||||
|
||||
///Return a nice list of all the reagents in a specific category with a specific prefix. This needs to be reworked because the formatting sucks ass.
|
||||
/datum/micro_organism/cell_line/proc/return_reagent_text(var/prefix_text = "It requires:", var/list/reagentlist)
|
||||
/datum/micro_organism/cell_line/proc/return_reagent_text(prefix_text = "It requires:", list/reagentlist)
|
||||
if(!reagentlist.len)
|
||||
return
|
||||
var/all_reagents_text
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
micro_organisms += new chosen_type
|
||||
|
||||
///Takes another sample and merges it into use. This can cause one very big sample but we limit it to 3 layers.
|
||||
/datum/biological_sample/proc/Merge(var/datum/biological_sample/other_sample)
|
||||
/datum/biological_sample/proc/Merge(datum/biological_sample/other_sample)
|
||||
if(sample_layers >= 3)//No more than 3 layers, at that point you're entering danger zone.
|
||||
return FALSE
|
||||
micro_organisms += other_sample.micro_organisms
|
||||
@@ -31,6 +31,6 @@
|
||||
return TRUE
|
||||
|
||||
///Call handle_growth on all our microorganisms.
|
||||
/datum/biological_sample/proc/handle_growth(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/biological_sample/proc/handle_growth(obj/machinery/plumbing/growing_vat/vat)
|
||||
for(var/datum/micro_organism/cell_line/organism in micro_organisms) //Types because we don't grow viruses.
|
||||
organism.handle_growth(vat)
|
||||
|
||||
@@ -403,7 +403,7 @@
|
||||
resulting_atoms[random_result] = 1
|
||||
return ..()
|
||||
|
||||
/datum/micro_organism/cell_line/clown/fuck_up_growing(var/obj/machinery/plumbing/growing_vat/vat)
|
||||
/datum/micro_organism/cell_line/clown/fuck_up_growing(obj/machinery/plumbing/growing_vat/vat)
|
||||
vat.visible_message("<span class='warning'>The biological sample in [vat] seems to have created something horrific!</span>")
|
||||
QDEL_NULL(vat.biological_sample) //Kill off the sample, we're done
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
. = ..()
|
||||
AddComponent(/datum/component/swabbing, TRUE, TRUE, FALSE, null, CALLBACK(src, .proc/update_swab_icon), max_items = 1)
|
||||
|
||||
/obj/item/swab/proc/update_swab_icon(overlays, var/list/swabbed_items)
|
||||
/obj/item/swab/proc/update_swab_icon(overlays, list/swabbed_items)
|
||||
if(LAZYLEN(swabbed_items))
|
||||
var/datum/biological_sample/sample = LAZYACCESS(swabbed_items, 1) //Use the first one as our target
|
||||
var/mutable_appearance/swab_overlay = mutable_appearance(icon, "swab_[sample.sample_color]")
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
deposit_sample(user, petri)
|
||||
|
||||
///Creates a clone of the supplied sample and puts it in the vat
|
||||
/obj/machinery/plumbing/growing_vat/proc/deposit_sample(mob/user, var/obj/item/petri_dish/petri)
|
||||
/obj/machinery/plumbing/growing_vat/proc/deposit_sample(mob/user, obj/item/petri_dish/petri)
|
||||
biological_sample = new
|
||||
for(var/datum/micro_organism/m in petri.sample.micro_organisms)
|
||||
biological_sample.micro_organisms += new m.type()
|
||||
|
||||
@@ -53,6 +53,10 @@ while read f; do
|
||||
st=1
|
||||
fi;
|
||||
done < <(find . -type f -name '*.dm')
|
||||
if grep -P '^/[\w/]\S+\(.*(var/|, ?var/.*).*\)' code/**/*.dm; then
|
||||
echo "changed files contains proc argument starting with 'var'"
|
||||
st=1
|
||||
fi;
|
||||
if grep -i 'centcomm' code/**/*.dm; then
|
||||
echo "ERROR: Misspelling(s) of CENTCOM detected in code, please remove the extra M(s)."
|
||||
st=1
|
||||
|
||||
Reference in New Issue
Block a user