please do not end your paths with /

This commit is contained in:
SandPoot
2024-03-13 14:43:40 -03:00
parent f68671320b
commit 8516b07eee
20 changed files with 35 additions and 43 deletions
+1 -1
View File
@@ -167,5 +167,5 @@
/atom/proc/Beam(atom/BeamTarget,icon_state="b_beam",icon='icons/effects/beam.dmi',time=50, maxdistance=10,beam_type=/obj/effect/ebeam,beam_sleep_time = 3)
var/datum/beam/newbeam = new(src,BeamTarget,icon,icon_state,time,maxdistance,beam_type,beam_sleep_time)
INVOKE_ASYNC(newbeam, TYPE_PROC_REF(/datum/beam/, Start))
INVOKE_ASYNC(newbeam, TYPE_PROC_REF(/datum/beam, Start))
return newbeam
+9 -17
View File
@@ -5,10 +5,10 @@
* ## USAGE
*
* ```
* var/datum/callback/C = new(object|null, /proc/type/path|"procstring", arg1, arg2, ... argn)
* var/datum/callback/C = new(object|null, PROC_REF(procname), arg1, arg2, ... argn)
* var/timerid = addtimer(C, time, timertype)
* you can also use the compiler define shorthand
* var/timerid = addtimer(CALLBACK(object|null, PROC_REF(type/path|procstring), arg1, arg2, ... argn), time, timertype)
* var/timerid = addtimer(CALLBACK(object|null, PROC_REF(procname), arg1, arg2, ... argn), time, timertype)
* ```
*
* Note: proc strings can only be given for datum proc calls, global procs must be proc paths
@@ -26,27 +26,19 @@
* ## PROC TYPEPATH SHORTCUTS
* (these operate on paths, not types, so to these shortcuts, datum is NOT a parent of atom, etc...)
*
* ### global proc while in another global proc:
* .procname
*
* `CALLBACK(GLOBAL_PROC, .some_proc_here)`
*
* ### proc defined on current(src) object (when in a /proc/ and not an override) OR overridden at src or any of it's parents:
* .procname
*
* `CALLBACK(src, .some_proc_here)`
*
* ### when the above doesn't apply:
*PROC_REF(procname)
* ### proc defined on current(src) object OR overridden at src or any of it's parents:
* PROC_REF(procname)
*
* `CALLBACK(src, PROC_REF(some_proc_here))`
*
* ### global proc
* GLOBAL_PROC_REF(procname)
*
* proc defined on a parent of a some type
* `CALLBACK(src, GLOBAL_PROC_REF(some_proc_here))`
*
* `TYPE_PROC_REF(/some/type/, some_proc_here)`
*
* Otherwise you must always provide the full typepath of the proc (/type/of/thing/proc/procname)
* ### proc defined on some type
* TYPE_PROC_REF(/some/type/, some_proc_here)
*/
/datum/callback
+2 -2
View File
@@ -73,8 +73,8 @@
RegisterSignal(shooter, COMSIG_MOB_CLIENT_LOGOUT, PROC_REF(autofire_off))
if(!QDELETED(shooter))
UnregisterSignal(shooter, COMSIG_MOB_CLIENT_LOGIN)
parent.RegisterSignal(src, COMSIG_AUTOFIRE_ONMOUSEDOWN, TYPE_PROC_REF(/obj/item/gun/, autofire_bypass_check))
parent.RegisterSignal(parent, COMSIG_AUTOFIRE_SHOT, TYPE_PROC_REF(/obj/item/gun/, do_autofire))
parent.RegisterSignal(src, COMSIG_AUTOFIRE_ONMOUSEDOWN, TYPE_PROC_REF(/obj/item/gun, autofire_bypass_check))
parent.RegisterSignal(parent, COMSIG_AUTOFIRE_SHOT, TYPE_PROC_REF(/obj/item/gun, do_autofire))
/datum/component/automatic_fire/proc/autofire_off(datum/source)
+1 -1
View File
@@ -57,7 +57,7 @@
strip_menu = new(source, src)
LAZYSET(strip_menus, source, strip_menu)
INVOKE_ASYNC(strip_menu, TYPE_PROC_REF(/datum/, ui_interact), user)
INVOKE_ASYNC(strip_menu, TYPE_PROC_REF(/datum, ui_interact), user)
/// A representation of an item that can be stripped down
/datum/strippable_item
+3 -3
View File
@@ -1291,9 +1291,9 @@ GLOBAL_LIST_EMPTY(possible_sabotages)
var/payout_bonus = 0
var/area/dropoff = null
var/static/list/blacklisted_areas = typecacheof(list(/area/ai_monitored/turret_protected,
/area/solars/,
/area/ruin/, //thank you station space ruins
/area/science/test_area/,
/area/solars,
/area/ruin, //thank you station space ruins
/area/science/test_area,
/area/shuttle/))
/datum/objective/contract/proc/generate_dropoff() // Generate a random valid area on the station that the dropoff will happen.
@@ -66,7 +66,7 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \
new/datum/stack_recipe("wall girders", /obj/structure/girder, 2, time = 40, one_per_turf = TRUE, on_floor = TRUE, trait_booster = TRAIT_QUICK_BUILD, trait_modifier = 0.75), \
null, \
new/datum/stack_recipe("computer frame", /obj/structure/frame/computer, 5, time = 25, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("modular console", /obj/machinery/modular_computer/console/buildable/, 10, time = 25, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("modular console", /obj/machinery/modular_computer/console/buildable, 10, time = 25, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("machine frame", /obj/structure/frame/machine, 5, time = 25, one_per_turf = TRUE, on_floor = TRUE), \
null, \
new /datum/stack_recipe_list("airlock assemblies", list( \
@@ -257,7 +257,7 @@ GLOBAL_LIST_INIT(wood_recipes, list ( \
new/datum/stack_recipe("wooden buckler", /obj/item/shield/riot/buckler, 20, time = 40), \
new/datum/stack_recipe("baseball bat", /obj/item/melee/baseball_bat, 5, time = 15),\
null, \
new/datum/stack_recipe("wooden chair", /obj/structure/chair/wood/, 3, time = 10, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("wooden chair", /obj/structure/chair/wood, 3, time = 10, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("winged wooden chair", /obj/structure/chair/wood/wings, 3, time = 10, one_per_turf = TRUE, on_floor = TRUE), \
new/datum/stack_recipe("plywood chair", /obj/structure/chair/comfy/plywood, 4, time = 10, one_per_turf = TRUE, on_floor = TRUE), \
null, \
+1 -1
View File
@@ -387,7 +387,7 @@
/obj/item/hypospray/mkii,
/obj/item/sensor_device,
/obj/item/radio,
/obj/item/clothing/gloves/,
/obj/item/clothing/gloves,
/obj/item/lazarus_injector,
/obj/item/bikehorn/rubberducky,
/obj/item/clothing/mask/surgical,
+1 -1
View File
@@ -153,7 +153,7 @@
/obj/item/hypospray/mkii,
/obj/item/sensor_device,
/obj/item/radio,
/obj/item/clothing/gloves/,
/obj/item/clothing/gloves,
/obj/item/lazarus_injector,
/obj/item/bikehorn/rubberducky,
/obj/item/clothing/mask/surgical,
+1 -1
View File
@@ -1094,7 +1094,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301
/obj/item/melee/flyswatter/Initialize(mapload)
. = ..()
strong_against = typecacheof(list(
/mob/living/simple_animal/hostile/poison/bees/,
/mob/living/simple_animal/hostile/poison/bees,
/mob/living/simple_animal/butterfly,
/mob/living/simple_animal/cockroach,
/obj/item/queen_bee,
@@ -24,7 +24,7 @@
return
H.add_atom_colour("#FF0000", ADMIN_COLOUR_PRIORITY)
var/obj/effect/mine/pickup/bloodbath/B = new(H)
INVOKE_ASYNC(B, TYPE_PROC_REF(/obj/effect/mine/pickup/bloodbath/, mineEffect), H) //could use moving out from the mine
INVOKE_ASYNC(B, TYPE_PROC_REF(/obj/effect/mine/pickup/bloodbath, mineEffect), H) //could use moving out from the mine
for(var/mob/living/carbon/human/P in GLOB.player_list)
if(P == H || HAS_TRAIT(P, TRAIT_NO_MIDROUND_ANTAG))
@@ -201,7 +201,7 @@
name = "Rite of the Vessel" //The name of the rite
desc = "This rite is used to summon a soul vessel, a special posibrain that makes whoever has their brain put into it loyal to the Justiciar.,\
When put into a cyborg shell, the created cyborg will automatically be a servant of Ratvar."
required_ingredients = list(/obj/item/stack/cable_coil, /obj/item/stock_parts/cell/, /obj/item/organ/cyberimp)
required_ingredients = list(/obj/item/stack/cable_coil, /obj/item/stock_parts/cell, /obj/item/organ/cyberimp)
power_cost = 2500 //These things are pretty strong, I won't lie
requires_full_power = TRUE
cast_time = 50
@@ -796,7 +796,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
for(var/obj/machinery/light/L in GLOB.machines)
if(is_station_level(L.z))
L.no_emergency = TRUE
INVOKE_ASYNC(L, TYPE_PROC_REF(/obj/machinery/light/, update), FALSE)
INVOKE_ASYNC(L, TYPE_PROC_REF(/obj/machinery/light, update), FALSE)
CHECK_TICK
to_chat(owner, "<span class='notice'>Emergency light connections severed.</span>")
owner.playsound_local(owner, 'sound/effects/light_flicker.ogg', 50, FALSE)
@@ -24,7 +24,7 @@
var/contract_rep = 0
var/list/hub_items = list()
var/list/purchased_items = list()
var/static/list/contractor_items = typecacheof(/datum/contractor_item/, TRUE)
var/static/list/contractor_items = typecacheof(/datum/contractor_item, TRUE)
var/datum/syndicate_contract/current_contract
var/list/datum/syndicate_contract/assigned_contracts = list()
+2 -2
View File
@@ -235,8 +235,8 @@
name = "Medipen Variety-Pak"
desc = "Contains eight different medipens in three different varieties, to assist in quickly treating seriously injured patients."
cost = 2000
contains = list(/obj/item/reagent_containers/hypospray/medipen/,
/obj/item/reagent_containers/hypospray/medipen/,
contains = list(/obj/item/reagent_containers/hypospray/medipen,
/obj/item/reagent_containers/hypospray/medipen,
/obj/item/reagent_containers/hypospray/medipen/ekit,
/obj/item/reagent_containers/hypospray/medipen/ekit,
/obj/item/reagent_containers/hypospray/medipen/ekit,
+3 -3
View File
@@ -46,9 +46,9 @@
// cost = CARGO_CRATE_VALUE * 3
cost = 1500
contains = list(/obj/item/book/codex_gigas,
/obj/item/book/manual/random/,
/obj/item/book/manual/random/,
/obj/item/book/manual/random/,
/obj/item/book/manual/random,
/obj/item/book/manual/random,
/obj/item/book/manual/random,
/obj/item/book/random,
/obj/item/book/random,
/obj/item/book/random)
+1 -1
View File
@@ -379,7 +379,7 @@
event.announce_to_ghosts(SV)
START_PROCESSING(SSobj, src)
vine_mutations_list = list()
init_subtypes(/datum/spacevine_mutation/, vine_mutations_list)
init_subtypes(/datum/spacevine_mutation, vine_mutations_list)
if(potency != null)
mutativeness = potency / 10
if(production != null)
@@ -47,7 +47,7 @@
AddElement(/datum/element/flavor_text/carbon, _name = "Flavor Text", _save_key = "flavor_text")
AddElement(/datum/element/flavor_text/carbon/temporary, "", "Set Pose (Temporary Flavor Text)", "This should be used only for things pertaining to the current round!", _save_key = null)
AddElement(/datum/element/flavor_text, _name = "OOC Notes", _addendum = "Put information on ERP/vore/lewd-related preferences here. THIS SHOULD NOT CONTAIN REGULAR FLAVORTEXT!!", _always_show = TRUE, _save_key = "ooc_notes", _examine_no_preview = TRUE)
AddElement(/datum/element/strippable, GLOB.strippable_human_items, TYPE_PROC_REF(/mob/living/carbon/human/, should_strip))
AddElement(/datum/element/strippable, GLOB.strippable_human_items, TYPE_PROC_REF(/mob/living/carbon/human, should_strip))
/mob/living/carbon/human/Destroy()
QDEL_NULL(physiology)
@@ -42,7 +42,7 @@
animal_species = /mob/living/simple_animal/hostile/asteroid/gutlunch
childtype = list(/mob/living/simple_animal/hostile/asteroid/gutlunch/gubbuck = 45, /mob/living/simple_animal/hostile/asteroid/gutlunch/guthen = 55)
wanted_objects = list(/obj/effect/decal/cleanable/blood/gibs/xeno, /obj/effect/decal/cleanable/blood/gibs/, /obj/item/bodypart, /obj/item/organ/appendix, /obj/item/organ/ears, /obj/item/organ/eyes, /obj/item/organ/heart, /obj/item/organ/liver, \
wanted_objects = list(/obj/effect/decal/cleanable/blood/gibs/xeno, /obj/effect/decal/cleanable/blood/gibs, /obj/item/bodypart, /obj/item/organ/appendix, /obj/item/organ/ears, /obj/item/organ/eyes, /obj/item/organ/heart, /obj/item/organ/liver, \
/obj/item/organ/lungs, /obj/item/organ/stomach, /obj/item/organ/tongue) // So we dont eat implants or brains. Still can eat robotic stuff thats subtyped of base line but thats a issue for another day.
var/obj/item/udder/gutlunch/udder = null
+1 -1
View File
@@ -1163,7 +1163,7 @@
for(var/obj/machinery/light/L in area)
if(!initial(L.no_emergency)) //If there was an override set on creation, keep that override
L.no_emergency = emergency_lights
INVOKE_ASYNC(L, TYPE_PROC_REF(/obj/machinery/light/, update), FALSE)
INVOKE_ASYNC(L, TYPE_PROC_REF(/obj/machinery/light, update), FALSE)
CHECK_TICK
return TRUE
@@ -54,7 +54,7 @@
var/sturdy = list(
/turf/closed,
/obj/vehicle/sealed/mecha,
/obj/machinery/door/,
/obj/machinery/door,
/obj/machinery/door/poddoor/shutters
)