mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 21:48:39 +01:00
Add lints for "new" override prevention feature (#49672)
* Add lints for "new" override prevention feature * bEsPoKe * i'm an idiot * arg index
This commit is contained in:
@@ -816,7 +816,9 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
// Called before use_tool if there is a delay, or by use_tool if there isn't.
|
||||
// Only ever used by welding tools and stacks, so it's not added on any other use_tool checks.
|
||||
/obj/item/proc/tool_start_check(mob/living/user, amount=0)
|
||||
return tool_use_check(user, amount)
|
||||
. = tool_use_check(user, amount)
|
||||
if(.)
|
||||
SEND_SIGNAL(src, COMSIG_TOOL_START_USE, user)
|
||||
|
||||
// A check called by tool_start_check once, and by use_tool on every tick of delay.
|
||||
/obj/item/proc/tool_use_check(mob/living/user, amount)
|
||||
@@ -837,9 +839,12 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
|
||||
|
||||
playsound(target, played_sound, volume, TRUE)
|
||||
|
||||
// Used in a callback that is passed by use_tool into do_after call. Do not override, do not call manually.
|
||||
/// Used in a callback that is passed by use_tool into do_after call. Do not override, do not call manually.
|
||||
/obj/item/proc/tool_check_callback(mob/living/user, amount, datum/callback/extra_checks)
|
||||
return tool_use_check(user, amount) && (!extra_checks || extra_checks.Invoke())
|
||||
SHOULD_NOT_OVERRIDE(TRUE)
|
||||
. = tool_use_check(user, amount) && (!extra_checks || extra_checks.Invoke())
|
||||
if(.)
|
||||
SEND_SIGNAL(src, COMSIG_TOOL_IN_USE, user)
|
||||
|
||||
// Returns a numeric value for sorting items used as parts in machines, so they can be replaced by the rped
|
||||
/obj/item/proc/get_part_rating()
|
||||
|
||||
Reference in New Issue
Block a user