mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 15:47:15 +01:00
Add investigate logs for crafting (#63178)
This commit is contained in:
@@ -1,22 +1,23 @@
|
||||
//Investigate logging defines
|
||||
#define INVESTIGATE_ACCESSCHANGES "id_card_changes"
|
||||
#define INVESTIGATE_ATMOS "atmos"
|
||||
#define INVESTIGATE_BOTANY "botany"
|
||||
#define INVESTIGATE_CARGO "cargo"
|
||||
#define INVESTIGATE_CRAFTING "crafting"
|
||||
#define INVESTIGATE_EXONET "exonet"
|
||||
#define INVESTIGATE_EXPERIMENTOR "experimentor"
|
||||
#define INVESTIGATE_GRAVITY "gravity"
|
||||
#define INVESTIGATE_HALLUCINATIONS "hallucinations"
|
||||
#define INVESTIGATE_HYPERTORUS "hypertorus"
|
||||
#define INVESTIGATE_PORTAL "portals"
|
||||
#define INVESTIGATE_PRESENTS "presents"
|
||||
#define INVESTIGATE_RADIATION "radiation"
|
||||
#define INVESTIGATE_RECORDS "records"
|
||||
#define INVESTIGATE_RESEARCH "research"
|
||||
#define INVESTIGATE_SINGULO "singulo"
|
||||
#define INVESTIGATE_SUPERMATTER "supermatter"
|
||||
#define INVESTIGATE_TELESCI "telesci"
|
||||
#define INVESTIGATE_WIRES "wires"
|
||||
#define INVESTIGATE_PORTAL "portals"
|
||||
#define INVESTIGATE_RESEARCH "research"
|
||||
#define INVESTIGATE_HALLUCINATIONS "hallucinations"
|
||||
#define INVESTIGATE_RADIATION "radiation"
|
||||
#define INVESTIGATE_EXONET "exonet"
|
||||
#define INVESTIGATE_PRESENTS "presents"
|
||||
#define INVESTIGATE_HYPERTORUS "hypertorus"
|
||||
#define INVESTIGATE_ACCESSCHANGES "id_card_changes"
|
||||
|
||||
// Logging types for log_message()
|
||||
#define LOG_ATTACK (1 << 0)
|
||||
|
||||
@@ -436,17 +436,18 @@
|
||||
switch(action)
|
||||
if("make")
|
||||
var/mob/user = usr
|
||||
var/datum/crafting_recipe/TR = locate(params["recipe"]) in GLOB.crafting_recipes
|
||||
var/datum/crafting_recipe/crafting_recipe = locate(params["recipe"]) in GLOB.crafting_recipes
|
||||
busy = TRUE
|
||||
ui_interact(user)
|
||||
var/atom/movable/result = construct_item(user, TR)
|
||||
var/atom/movable/result = construct_item(user, crafting_recipe)
|
||||
if(!istext(result)) //We made an item and didn't get a fail message
|
||||
if(ismob(user) && isitem(result)) //In case the user is actually possessing a non mob like a machine
|
||||
user.put_in_hands(result)
|
||||
else
|
||||
result.forceMove(user.drop_location())
|
||||
to_chat(user, span_notice("[TR.name] constructed."))
|
||||
TR.on_craft_completion(user, result)
|
||||
to_chat(user, span_notice("[crafting_recipe.name] constructed."))
|
||||
user.investigate_log("[key_name(user)] crafted [crafting_recipe]", INVESTIGATE_CRAFTING)
|
||||
crafting_recipe.on_craft_completion(user, result)
|
||||
else
|
||||
to_chat(user, span_warning("Construction failed[result]"))
|
||||
busy = FALSE
|
||||
|
||||
@@ -10,7 +10,27 @@
|
||||
if(!holder)
|
||||
return
|
||||
|
||||
var/list/investigates = list(INVESTIGATE_RESEARCH, INVESTIGATE_EXONET, INVESTIGATE_PORTAL, INVESTIGATE_SINGULO, INVESTIGATE_WIRES, INVESTIGATE_TELESCI, INVESTIGATE_GRAVITY, INVESTIGATE_RECORDS, INVESTIGATE_CARGO, INVESTIGATE_SUPERMATTER, INVESTIGATE_ATMOS, INVESTIGATE_EXPERIMENTOR, INVESTIGATE_BOTANY, INVESTIGATE_HALLUCINATIONS, INVESTIGATE_RADIATION, INVESTIGATE_PRESENTS, INVESTIGATE_HYPERTORUS, INVESTIGATE_ACCESSCHANGES)
|
||||
var/list/investigates = list(
|
||||
INVESTIGATE_ACCESSCHANGES,
|
||||
INVESTIGATE_ATMOS,
|
||||
INVESTIGATE_BOTANY,
|
||||
INVESTIGATE_CARGO,
|
||||
INVESTIGATE_CRAFTING,
|
||||
INVESTIGATE_EXONET,
|
||||
INVESTIGATE_EXPERIMENTOR,
|
||||
INVESTIGATE_GRAVITY,
|
||||
INVESTIGATE_HALLUCINATIONS,
|
||||
INVESTIGATE_HYPERTORUS,
|
||||
INVESTIGATE_PORTAL,
|
||||
INVESTIGATE_PRESENTS,
|
||||
INVESTIGATE_RADIATION,
|
||||
INVESTIGATE_RECORDS,
|
||||
INVESTIGATE_RESEARCH,
|
||||
INVESTIGATE_SINGULO,
|
||||
INVESTIGATE_SUPERMATTER,
|
||||
INVESTIGATE_TELESCI,
|
||||
INVESTIGATE_WIRES,
|
||||
)
|
||||
|
||||
var/list/logs_present = list("notes, memos, watchlist")
|
||||
var/list/logs_missing = list("---")
|
||||
|
||||
Reference in New Issue
Block a user