From a43afbd7e87fbf70d30b738f3a509ef49bd4b99d Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 12 Dec 2022 02:10:27 +0100 Subject: [PATCH] [MIRROR] [FUCK] Linters work again, V3 [MDB IGNORE] (#17950) * [FUCK] Linters work again, V3 * i don't think these are all of them * heehhooo there go the fucking m aps! Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com> Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> Co-authored-by: Jolly-66 <70232195+Jolly-66@users.noreply.github.com> --- _maps/map_files/VoidRaptor/VoidRaptor.dmm | 28 +++---------------- _maps/shuttles/ert_bounty.dmm | 6 +--- _maps/shuttles/skyrat/cargo_delta_skyrat.dmm | 3 +- _maps/shuttles/skyrat/emergency_skyrat.dmm | 5 +--- _maps/shuttles/skyrat/ferry_skyrat.dmm | 6 +--- _maps/shuttles/skyrat/goldeneye_cruiser.dmm | 5 +--- _maps/shuttles/skyrat/labour_skyrat.dmm | 5 +--- .../shuttles/skyrat/mining_common_skyrat.dmm | 5 +--- _maps/shuttles/skyrat/mining_large_skyrat.dmm | 5 +--- _maps/shuttles/skyrat/mining_skyrat.dmm | 5 +--- _maps/shuttles/skyrat/pirate_nri_raider.dmm | 6 +--- _maps/shuttles/skyrat/prison_transport.dmm | 5 +--- .../skyrat/ruin_blackmarket_chevvy.dmm | 5 +--- .../shuttles/skyrat/ruin_tarkon_driverdc2.dmm | 4 +-- .../shuttles/skyrat/ruin_tarkon_driverdc3.dmm | 4 +-- .../skyrat/ruin_tarkon_driverdc54.dmm | 4 +-- _maps/shuttles/skyrat/slaver_syndie.dmm | 5 +--- _maps/templates/ferry_skyrat.dmm | 6 +--- code/datums/components/echolocation.dm | 4 +-- .../dna_infuser/organ_sets/carp_organs.dm | 6 ++-- code/game/machinery/iv_drip.dm | 2 +- .../food_and_drinks/machinery/coffeemaker.dm | 12 ++++---- .../religion/honorbound/honorbound_rites.dm | 2 +- code/modules/unit_tests/monkey_business.dm | 1 - code/modules/unit_tests/spawn_humans.dm | 2 +- tools/ci/check_grep.sh | 22 ++++++++------- 26 files changed, 47 insertions(+), 116 deletions(-) diff --git a/_maps/map_files/VoidRaptor/VoidRaptor.dmm b/_maps/map_files/VoidRaptor/VoidRaptor.dmm index 35d49413342..43045de744d 100644 --- a/_maps/map_files/VoidRaptor/VoidRaptor.dmm +++ b/_maps/map_files/VoidRaptor/VoidRaptor.dmm @@ -44164,11 +44164,8 @@ "mzu" = ( /obj/docking_port/stationary{ dir = 4; - dwidth = 11; - height = 18; name = "DeltaStation emergency evac bay"; - shuttle_id = "emergency_home"; - width = 30 + shuttle_id = "emergency_home" }, /turf/open/space/basic, /area/space/nearstation) @@ -50125,11 +50122,8 @@ "oaQ" = ( /obj/docking_port/stationary{ dir = 8; - dwidth = 1; - height = 13; name = "arrivals"; - shuttle_id = "arrivals_stationary"; - width = 5 + shuttle_id = "arrivals_stationary" }, /turf/open/space/basic, /area/space/nearstation) @@ -56929,11 +56923,8 @@ "pXt" = ( /obj/docking_port/stationary{ dir = 4; - dwidth = 4; - height = 7; name = "Cargo Bay"; - shuttle_id = "cargo_home"; - width = 12 + shuttle_id = "cargo_home" }, /turf/open/space/basic, /area/space/nearstation) @@ -73652,17 +73643,6 @@ /obj/effect/turf_decal/bot, /turf/open/floor/iron/white, /area/station/medical/storage) -"uwC" = ( -/obj/docking_port/mobile/emergency{ - dwidth = 40; - height = 43; - movement_force = list("KNOCKDOWN"=3,"THROW"=6); - name = "\proper a monastery with engines strapped to it"; - port_direction = 1; - width = 80 - }, -/turf/closed/mineral, -/area/space/nearstation) "uwN" = ( /obj/machinery/recharge_station, /obj/effect/landmark/start/cyborg, @@ -138711,7 +138691,7 @@ ttw ttw ttw qtL -uwC +qtL qyC byw qyC diff --git a/_maps/shuttles/ert_bounty.dmm b/_maps/shuttles/ert_bounty.dmm index 92b3628f97f..7d0dfc055ba 100644 --- a/_maps/shuttles/ert_bounty.dmm +++ b/_maps/shuttles/ert_bounty.dmm @@ -183,14 +183,10 @@ width = 17 }, /obj/docking_port/mobile{ - dheight = 3; - dwidth = 3; - height = 13; movement_force = list("KNOCKDOWN" = 0, "THROW" = 0); name = "hunter shuttle"; rechargeTime = 1800; - shuttle_id = "huntership"; - width = 15 + shuttle_id = "huntership" }, /obj/structure/fans/tiny, /turf/open/floor/plating, diff --git a/_maps/shuttles/skyrat/cargo_delta_skyrat.dmm b/_maps/shuttles/skyrat/cargo_delta_skyrat.dmm index 6cb3fc72913..daf106a3b3e 100644 --- a/_maps/shuttles/skyrat/cargo_delta_skyrat.dmm +++ b/_maps/shuttles/skyrat/cargo_delta_skyrat.dmm @@ -44,8 +44,7 @@ /area/shuttle/supply) "lb" = ( /obj/docking_port/mobile/supply{ - dir = 4; - dwidth = 4 + dir = 4 }, /obj/machinery/door/airlock/grunge{ name = "Supply Shuttle Airlock"; diff --git a/_maps/shuttles/skyrat/emergency_skyrat.dmm b/_maps/shuttles/skyrat/emergency_skyrat.dmm index a988e85a362..5283484b575 100644 --- a/_maps/shuttles/skyrat/emergency_skyrat.dmm +++ b/_maps/shuttles/skyrat/emergency_skyrat.dmm @@ -378,10 +378,7 @@ "zw" = ( /obj/machinery/door/airlock/external/glass, /obj/docking_port/mobile/emergency{ - dwidth = 10; - height = 15; - name = "Emergency Shuttle"; - width = 27 + name = "Emergency Shuttle" }, /obj/effect/turf_decal/delivery/white, /turf/open/floor/iron/dark/textured_large, diff --git a/_maps/shuttles/skyrat/ferry_skyrat.dmm b/_maps/shuttles/skyrat/ferry_skyrat.dmm index 85995412c28..0748d48afda 100644 --- a/_maps/shuttles/skyrat/ferry_skyrat.dmm +++ b/_maps/shuttles/skyrat/ferry_skyrat.dmm @@ -577,14 +577,10 @@ dir = 8 }, /obj/docking_port/mobile{ - dheight = 3; dir = 8; - dwidth = 8; - height = 11; shuttle_id = "ferry"; name = "ferry shuttle"; - port_direction = 4; - width = 20 + port_direction = 4 }, /obj/machinery/door/airlock/grunge, /turf/open/floor/iron/shuttle/ferry{ diff --git a/_maps/shuttles/skyrat/goldeneye_cruiser.dmm b/_maps/shuttles/skyrat/goldeneye_cruiser.dmm index 0df9d5995c3..24c4498b105 100644 --- a/_maps/shuttles/skyrat/goldeneye_cruiser.dmm +++ b/_maps/shuttles/skyrat/goldeneye_cruiser.dmm @@ -1003,14 +1003,11 @@ "vo" = ( /obj/docking_port/mobile{ dir = 8; - dwidth = 7; - height = 21; hidden = 1; shuttle_id = "goldeneye_cruiser"; movement_force = list("KNOCKDOWN"=0,"THROW"=0); name = "goldeneye cruiser"; - port_direction = 4; - width = 31 + port_direction = 4 }, /obj/structure/fans/tiny, /obj/effect/turf_decal/delivery/white, diff --git a/_maps/shuttles/skyrat/labour_skyrat.dmm b/_maps/shuttles/skyrat/labour_skyrat.dmm index e1c09dbba69..97272c63ca3 100644 --- a/_maps/shuttles/skyrat/labour_skyrat.dmm +++ b/_maps/shuttles/skyrat/labour_skyrat.dmm @@ -10,12 +10,9 @@ "g" = ( /obj/docking_port/mobile{ dir = 8; - dwidth = 2; - height = 5; shuttle_id = "laborcamp"; name = "labor camp shuttle"; - port_direction = 4; - width = 9 + port_direction = 4 }, /obj/machinery/door/airlock/grunge{ id_tag = "prisonshuttle"; diff --git a/_maps/shuttles/skyrat/mining_common_skyrat.dmm b/_maps/shuttles/skyrat/mining_common_skyrat.dmm index f18c16c2a32..4c8becc60f4 100644 --- a/_maps/shuttles/skyrat/mining_common_skyrat.dmm +++ b/_maps/shuttles/skyrat/mining_common_skyrat.dmm @@ -56,12 +56,9 @@ "B" = ( /obj/docking_port/mobile{ dir = 8; - dwidth = 3; - height = 5; shuttle_id = "mining_common"; name = "lavaland shuttle"; - port_direction = 4; - width = 7 + port_direction = 4 }, /obj/machinery/door/airlock/grunge{ name = "Public Shuttle Airlock" diff --git a/_maps/shuttles/skyrat/mining_large_skyrat.dmm b/_maps/shuttles/skyrat/mining_large_skyrat.dmm index 49303d3d877..ec8b7ace90a 100644 --- a/_maps/shuttles/skyrat/mining_large_skyrat.dmm +++ b/_maps/shuttles/skyrat/mining_large_skyrat.dmm @@ -126,12 +126,9 @@ dir = 1 }, /obj/docking_port/mobile{ - dwidth = 3; - height = 10; shuttle_id = "mining"; name = "mining shuttle"; - port_direction = 2; - width = 7 + port_direction = 2 }, /turf/open/floor/iron/shuttle/exploration/flat, /area/shuttle/mining/large/advanced) diff --git a/_maps/shuttles/skyrat/mining_skyrat.dmm b/_maps/shuttles/skyrat/mining_skyrat.dmm index 0ac1899d01b..a8b24c04cd0 100644 --- a/_maps/shuttles/skyrat/mining_skyrat.dmm +++ b/_maps/shuttles/skyrat/mining_skyrat.dmm @@ -140,12 +140,9 @@ }, /obj/docking_port/mobile{ dir = 8; - dwidth = 3; - height = 5; shuttle_id = "mining"; name = "mining shuttle"; - port_direction = 4; - width = 7 + port_direction = 4 }, /turf/open/floor/iron/shuttle/exploration/textured_flat{ dir = 4 diff --git a/_maps/shuttles/skyrat/pirate_nri_raider.dmm b/_maps/shuttles/skyrat/pirate_nri_raider.dmm index 3cdc955351f..7d05806b8bc 100644 --- a/_maps/shuttles/skyrat/pirate_nri_raider.dmm +++ b/_maps/shuttles/skyrat/pirate_nri_raider.dmm @@ -240,11 +240,7 @@ /obj/effect/mapping_helpers/airlock/autoname, /obj/docking_port/mobile/pirate/nri_raider{ dir = 1; - height = 15; - launch_status = 0; - width = 29; - dwidth = 15; - dheight = 18 + launch_status = 0 }, /turf/open/floor/plating, /area/shuttle/pirate/nri) diff --git a/_maps/shuttles/skyrat/prison_transport.dmm b/_maps/shuttles/skyrat/prison_transport.dmm index 80caedee166..0210875169e 100644 --- a/_maps/shuttles/skyrat/prison_transport.dmm +++ b/_maps/shuttles/skyrat/prison_transport.dmm @@ -622,14 +622,11 @@ }, /obj/docking_port/mobile{ callTime = 250; - dwidth = 10; - height = 10; shuttle_id = "prison_transport"; launch_status = 0; movement_force = list("KNOCKDOWN"=0,"THROW"=0); name = "Prison Transporter NSS-74"; - preferred_direction = 4; - width = 10 + preferred_direction = 4 }, /turf/open/floor/iron/dark/smooth_large, /area/shuttle/prison_transport) diff --git a/_maps/shuttles/skyrat/ruin_blackmarket_chevvy.dmm b/_maps/shuttles/skyrat/ruin_blackmarket_chevvy.dmm index 284e5d00ab3..0b1abf8b5bb 100644 --- a/_maps/shuttles/skyrat/ruin_blackmarket_chevvy.dmm +++ b/_maps/shuttles/skyrat/ruin_blackmarket_chevvy.dmm @@ -347,14 +347,11 @@ /area/shuttle/blackmarket_chevvy) "ZW" = ( /obj/docking_port/mobile{ - dwidth = 5; - height = 7; shuttle_id = "blackmarket_chevvy"; launch_status = 0; name = "Chevvy"; port_direction = 8; - preferred_direction = 4; - width = 11 + preferred_direction = 4 }, /obj/machinery/door/airlock/external{ id_tag = "skiffexts" diff --git a/_maps/shuttles/skyrat/ruin_tarkon_driverdc2.dmm b/_maps/shuttles/skyrat/ruin_tarkon_driverdc2.dmm index 6fc57572dec..df678803cb5 100644 --- a/_maps/shuttles/skyrat/ruin_tarkon_driverdc2.dmm +++ b/_maps/shuttles/skyrat/ruin_tarkon_driverdc2.dmm @@ -127,12 +127,10 @@ "zR" = ( /obj/machinery/door/airlock/titanium, /obj/docking_port/mobile{ - height = 16; shuttle_id = "tarkon_driver"; name = "Tarkon Driver"; port_direction = 2; - preferred_direction = 8; - width = 12 + preferred_direction = 8 }, /obj/structure/fans/tiny/invisible, /obj/effect/mapping_helpers/airlock/access/all/tarkon/general, diff --git a/_maps/shuttles/skyrat/ruin_tarkon_driverdc3.dmm b/_maps/shuttles/skyrat/ruin_tarkon_driverdc3.dmm index 61c77270f89..389956b3867 100644 --- a/_maps/shuttles/skyrat/ruin_tarkon_driverdc3.dmm +++ b/_maps/shuttles/skyrat/ruin_tarkon_driverdc3.dmm @@ -90,12 +90,10 @@ "q" = ( /obj/machinery/door/airlock/titanium, /obj/docking_port/mobile{ - height = 16; shuttle_id = "tarkon_driver"; name = "Tarkon Driver"; port_direction = 2; - preferred_direction = 8; - width = 12 + preferred_direction = 8 }, /obj/structure/fans/tiny/invisible, /obj/effect/mapping_helpers/airlock/access/all/tarkon/general, diff --git a/_maps/shuttles/skyrat/ruin_tarkon_driverdc54.dmm b/_maps/shuttles/skyrat/ruin_tarkon_driverdc54.dmm index 81b0990ac00..9d029591040 100644 --- a/_maps/shuttles/skyrat/ruin_tarkon_driverdc54.dmm +++ b/_maps/shuttles/skyrat/ruin_tarkon_driverdc54.dmm @@ -86,12 +86,10 @@ "q" = ( /obj/machinery/door/airlock/titanium, /obj/docking_port/mobile{ - height = 16; shuttle_id = "tarkon_driver"; name = "Tarkon Driver"; port_direction = 2; - preferred_direction = 8; - width = 12 + preferred_direction = 8 }, /obj/structure/fans/tiny/invisible, /obj/effect/mapping_helpers/airlock/access/all/tarkon/general, diff --git a/_maps/shuttles/skyrat/slaver_syndie.dmm b/_maps/shuttles/skyrat/slaver_syndie.dmm index e1416c15e05..871bc585576 100644 --- a/_maps/shuttles/skyrat/slaver_syndie.dmm +++ b/_maps/shuttles/skyrat/slaver_syndie.dmm @@ -1101,13 +1101,10 @@ /obj/effect/mapping_helpers/airlock/cutaiwire, /obj/docking_port/mobile/pirate{ dir = 8; - dwidth = 5; - height = 17; launch_status = 0; movement_force = list("KNOCKDOWN"=0,"THROW"=0); name = "Slaver Ship"; - port_direction = 8; - width = 19 + port_direction = 8 }, /obj/structure/fans/tiny, /turf/open/floor/pod/dark{ diff --git a/_maps/templates/ferry_skyrat.dmm b/_maps/templates/ferry_skyrat.dmm index 6d03ea44ea7..bc78d4ef00a 100644 --- a/_maps/templates/ferry_skyrat.dmm +++ b/_maps/templates/ferry_skyrat.dmm @@ -344,15 +344,11 @@ /area/shuttle/transport) "Gy" = ( /obj/docking_port/mobile{ - dheight = 7; dir = 2; - dwidth = 8; - height = 11; shuttle_id = "ferry"; name = "ferry shuttle"; port_direction = 8; - preferred_direction = 8; - width = 20 + preferred_direction = 8 }, /obj/structure/fans/tiny/forcefield, /obj/machinery/door/airlock/grunge, diff --git a/code/datums/components/echolocation.dm b/code/datums/components/echolocation.dm index 735fbcbb861..3c7ed05d667 100644 --- a/code/datums/components/echolocation.dm +++ b/code/datums/components/echolocation.dm @@ -104,7 +104,7 @@ receivers[current_time] += viewer for(var/atom/filtered_atom as anything in filtered) show_image(saved_appearances["[filtered_atom.icon]-[filtered_atom.icon_state]"] || generate_appearance(filtered_atom), filtered_atom, current_time) - addtimer(CALLBACK(src, .proc/fade_images, current_time), image_expiry_time) + addtimer(CALLBACK(src, PROC_REF(fade_images), current_time), image_expiry_time) /datum/component/echolocation/proc/show_image(image/input_appearance, atom/input, current_time) var/image/final_image = image(input_appearance) @@ -149,7 +149,7 @@ /datum/component/echolocation/proc/fade_images(from_when) for(var/image_echo in images[from_when]) animate(image_echo, alpha = 0, time = fade_out_time) - addtimer(CALLBACK(src, .proc/delete_images, from_when), fade_out_time) + addtimer(CALLBACK(src, PROC_REF(delete_images), from_when), fade_out_time) /datum/component/echolocation/proc/delete_images(from_when) for(var/mob/living/echolocate_receiver as anything in receivers[from_when]) diff --git a/code/game/machinery/dna_infuser/organ_sets/carp_organs.dm b/code/game/machinery/dna_infuser/organ_sets/carp_organs.dm index 5068f3b01fd..048c0d6ff16 100644 --- a/code/game/machinery/dna_infuser/organ_sets/carp_organs.dm +++ b/code/game/machinery/dna_infuser/organ_sets/carp_organs.dm @@ -111,8 +111,8 @@ /obj/item/organ/internal/brain/carp/Insert(mob/living/carbon/brain_owner, special, drop_if_replaced, no_id_transfer) . = ..() - cooldown_timer = addtimer(CALLBACK(src, PROC_REF(unsatisfied_nomad)), cooldown_time, TIMER_STOPPABLE|TIMER_OVERRIDE) - RegisterSignal(brain_owner, COMSIG_MOVABLE_Z_CHANGED, .proc/satisfied_nomad) + cooldown_timer = addtimer(CALLBACK(src, PROC_REF(unsatisfied_nomad)), cooldown_time, TIMER_STOPPABLE|TIMER_OVERRIDE|TIMER_UNIQUE) + RegisterSignal(brain_owner, COMSIG_MOVABLE_Z_CHANGED, PROC_REF(satisfied_nomad)) //technically you could get around the mood issue by extracting and reimplanting the brain but it will be far easier to just go one z there and back /obj/item/organ/internal/brain/carp/Remove(mob/living/carbon/brain_owner, special, no_id_transfer) @@ -129,7 +129,7 @@ /obj/item/organ/internal/brain/carp/proc/satisfied_nomad() SIGNAL_HANDLER owner.clear_mood_event("nomad") - cooldown_timer = addtimer(CALLBACK(src, PROC_REF(unsatisfied_nomad)), cooldown_time, TIMER_STOPPABLE|TIMER_OVERRIDE) + cooldown_timer = addtimer(CALLBACK(src, PROC_REF(unsatisfied_nomad)), cooldown_time, TIMER_STOPPABLE|TIMER_OVERRIDE|TIMER_UNIQUE) /// makes you cold resistant, but heat-weak. /obj/item/organ/internal/heart/carp diff --git a/code/game/machinery/iv_drip.dm b/code/game/machinery/iv_drip.dm index a6687dd3077..66071418127 100644 --- a/code/game/machinery/iv_drip.dm +++ b/code/game/machinery/iv_drip.dm @@ -110,7 +110,7 @@ return TRUE /// Sets the transfer rate to the provided value -/obj/machinery/iv_drip/proc/set_transfer_rate(var/new_rate) +/obj/machinery/iv_drip/proc/set_transfer_rate(new_rate) if(!use_internal_storage && !reagent_container) return if(!attached) diff --git a/code/modules/food_and_drinks/machinery/coffeemaker.dm b/code/modules/food_and_drinks/machinery/coffeemaker.dm index bad405b375e..e618314d2eb 100644 --- a/code/modules/food_and_drinks/machinery/coffeemaker.dm +++ b/code/modules/food_and_drinks/machinery/coffeemaker.dm @@ -272,19 +272,19 @@ /obj/machinery/coffeemaker/proc/try_brew() if(!cartridge) - balloon_alert("no coffee cartidge inserted!") + balloon_alert(usr, "no coffee cartidge inserted!") return FALSE if(cartridge.charges < 1) - balloon_alert("coffee cartidge empty!") + balloon_alert(usr, "coffee cartidge empty!") return FALSE if(!coffeepot) - balloon_alert("no coffeepot inside!") + balloon_alert(usr, "no coffeepot inside!") return FALSE if(machine_stat & (NOPOWER|BROKEN)) - balloon_alert("machine unpowered!") + balloon_alert(usr, "machine unpowered!") return FALSE if(coffeepot.reagents.total_volume >= coffeepot.reagents.maximum_volume) - balloon_alert("the coffeepot is already full!") + balloon_alert(usr, "the coffeepot is already full!") return FALSE return TRUE @@ -711,7 +711,7 @@ /obj/machinery/coffeemaker/impressa/take_cup(mob/user) if(!coffee_cups) //shouldn't happen, but we all know how stuff manages to break - balloon_alert("no cups left!") + balloon_alert(user, "no cups left!") return balloon_alert_to_viewers("took cup") var/obj/item/reagent_containers/cup/glass/coffee/no_lid/new_cup = new(get_turf(src)) diff --git a/code/modules/religion/honorbound/honorbound_rites.dm b/code/modules/religion/honorbound/honorbound_rites.dm index 2546c8a0b5b..ad3a826a734 100644 --- a/code/modules/religion/honorbound/honorbound_rites.dm +++ b/code/modules/religion/honorbound/honorbound_rites.dm @@ -37,7 +37,7 @@ to_chat(user, span_warning("Wait for them to decide on whether to join or not!")) return FALSE if(!(possible_crusader in sect.possible_crusaders)) - INVOKE_ASYNC(sect, /datum/religion_sect/honorbound.proc/invite_crusader, possible_crusader) + INVOKE_ASYNC(sect, TYPE_PROC_REF(/datum/religion_sect/honorbound, invite_crusader), possible_crusader) to_chat(user, span_notice("They have been given the option to consider joining the crusade against evil. Wait for them to decide and try again.")) return FALSE new_crusader = possible_crusader diff --git a/code/modules/unit_tests/monkey_business.dm b/code/modules/unit_tests/monkey_business.dm index 9817795696e..7c8e4ddcf74 100644 --- a/code/modules/unit_tests/monkey_business.dm +++ b/code/modules/unit_tests/monkey_business.dm @@ -13,7 +13,6 @@ var/monkey_angry_nth = 5 // every nth monkey will be angry /datum/unit_test/monkey_business/Run() - var/start_runtimes = GLOB.total_runtimes for(var/monkey_id in 1 to length(GLOB.the_station_areas)) var/mob/living/carbon/human/monkey = allocate(/mob/living/carbon/human/consistent, get_first_open_turf_in_area(GLOB.the_station_areas[monkey_id])) monkey.set_species(/datum/species/monkey) diff --git a/code/modules/unit_tests/spawn_humans.dm b/code/modules/unit_tests/spawn_humans.dm index 71b67ced106..8f4517b36ab 100644 --- a/code/modules/unit_tests/spawn_humans.dm +++ b/code/modules/unit_tests/spawn_humans.dm @@ -2,6 +2,6 @@ var/locs = block(run_loc_floor_bottom_left, run_loc_floor_top_right) for(var/I in 1 to 5) - new /mob/living/carbon/human(pick(locs)) + new /mob/living/carbon/human/consistent(pick(locs)) sleep(5 SECONDS) diff --git a/tools/ci/check_grep.sh b/tools/ci/check_grep.sh index 82fc75776d1..4aea696c041 100644 --- a/tools/ci/check_grep.sh +++ b/tools/ci/check_grep.sh @@ -2,7 +2,7 @@ set -euo pipefail #nb: must be bash to support shopt globstar -shopt -s globstar +shopt -s globstar extglob #ANSI Escape Codes for colors to increase contrast of errors RED="\033[0;31m" @@ -19,15 +19,15 @@ if command -v rg >/dev/null 2>&1; then if [ ! rg -P '' >/dev/null 2>&1 ] ; then pcre2_support=0 fi - code_files="-g *.dm" - map_files="-g *.dmm" - ignore_515_proc_marker='-g !__byond_version_compat.dm' + code_files="code/**/**.dm" + map_files="_maps/**/**.dmm" + code_x_515="code/**/!(__byond_version_compat).dm" else pcre2_support=0 grep=grep - code_files="-r --include=*.dm" - map_files="-r --include=*.dmm" - ignore_515_proc_marker="--exclude=__byond_version_compat.dm" + code_files="-r --include=code/**/**.dm" + map_files="-r --include=_maps/**/**.dmm" + code_x_515="-r --include=code/**/!(__byond_version_compat).dm" fi echo -e "${BLUE}Using grep provider at $(which $grep)${NC}" @@ -247,7 +247,9 @@ fi; section "unit tests" part "mob/living/carbon/human usage" -if $grep 'mob/living/carbon/human[, (){}]' $code_files; then +if $grep 'allocate\(/mob/living/carbon/human[,\)]' code/modules/unit_tests/**/**.dm || + $grep 'new /mob/living/carbon/human\s?\(' || + $grep 'var/mob/living/carbon/human/\w+\s?=\s?new' ; then echo echo -e "${RED}ERROR: Usage of mob/living/carbon/human detected in a unit test, please use mob/living/carbon/human/consistent.${NC}" st=1 @@ -267,7 +269,7 @@ if $grep '^/[\w/]\S+\(.*(var/|, ?var/.*).*\)' $code_files; then st=1 fi; part "balloon_alert sanity" -if $grep 'balloon_alert\(".+"\)' $code_files; then +if $grep 'balloon_alert\(".*"\)' $code_files; then echo echo -e "${RED}ERROR: Found a balloon alert with improper arguments.${NC}" st=1 @@ -312,7 +314,7 @@ done section "515 Proc Syntax" part "proc ref syntax" -if $grep '\.proc/' $code_files $ignore_515_proc_marker; then +if $grep '\.proc/' $code_x_515 ; then echo echo -e "${RED}ERROR: Outdated proc reference use detected in code, please use proc reference helpers.${NC}" st=1