Reagent Addictions (#17498)

* Addictions

* improvements to addiction code

* some small revamps

* some polishing to reagent code

* some more fixes

* wiki updated for addiction

* proper addiction sync on respawn

* final cleanup, config

* coffee handle addiction proc

* fixed global var

* Addictions and

Gives alcohol special effects
Disables the harder addictions
Gives nicotine an a special effect

* remove >0

* safety

* Update medicine.dm

* Update medicine.dm

* Update food_drinks.dm

* update lazydefines

* disable alcohol addiction on virgo

* use lazylen, proper addiction end messages

* cure message bugfix

* use right args

* proper macro

---------

Co-authored-by: C.L. <killer65311@gmail.com>
This commit is contained in:
Will
2025-05-15 10:57:41 -07:00
committed by GitHub
co-authored by C.L.
parent 45470701a0
commit c213dbcd21
30 changed files with 580 additions and 9 deletions
@@ -13,6 +13,9 @@
integer = FALSE
default = 1.0
/datum/config_entry/flag/can_addict_during_round
default = FALSE
// FIXME: Unused
///datum/config_entry/flag/revival_pod_plants
// default = TRUE
+5 -5
View File
@@ -1092,10 +1092,10 @@ SUBSYSTEM_DEF(internal_wiki)
SSinternal_wiki.add_icon(data, initial(beaker_path.icon), initial(beaker_path.icon_state), R.color)
// Get internal data
data["description"] = R.description
/* Downstream features
data["addictive"] = 0
if(R.id in addictives)
data["addictive"] = (R.id in fast_addictives) ? 2 : 1
if(R.id in get_addictive_reagents(ADDICT_ALL))
data["addictive"] = TRUE
/* Downstream features
data["industrial_use"] = R.industrial_use
data["supply_points"] = R.supply_conversion_value ? R.supply_conversion_value : 0
var/value = R.supply_conversion_value * REAGENTS_PER_SHEET * SSsupply.points_per_money
@@ -1111,9 +1111,9 @@ SUBSYSTEM_DEF(internal_wiki)
/datum/internal_wiki/page/chemical/get_print()
var/body = ""
body += "<b>Description: </b>[data["description"]]<br>"
/* Downstream features
if(data["addictive"])
body += "<b>DANGER, [data["addictive"] > 1 ? "highly " : ""]addictive.</b><br>"
body += "<b>DANGER, addictive.</b><br>"
/* Downstream features
if(data["industrial_use"])
body += "<b>Industrial Use: </b>[data["industrial_use"]]<br>"
var/tank_size = CARGOTANKER_VOLUME