Skip to content

BugfixesGaloreV2 #5750

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 3, 2025
Merged

Conversation

MissClassyPineapple
Copy link
Collaborator

About The Pull Request

V2 of bugfixes galore.

Why It's Good For The Game

oops all bugfixes

Changelog

Adds the Coffee addiction datum to all alcoholic beverages containing coffee or coffee liqueur. And to Thirteen Loko.

🆑
add: Adds the Coffee addiction datum to all alcoholic beverages containing coffee or coffee liqueur. And to Thirteen Loko.
/:cl:

@MissClassyPineapple MissClassyPineapple changed the title Coffee in the alcohol. BugfixesGaloreV2 Mar 2, 2025
@LikeLakers2 LikeLakers2 added the Feature: Feature The creature feature. featuring: the creature. label Mar 3, 2025
Copy link
Collaborator

@LikeLakers2 LikeLakers2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you're touching DM files outside the monkestation/ directory, and those changes aren't mirrored over at tgstation, then please mark your changes. Doing so eases future porting and bugfix efforts, so we know what changes were made from what tgstation had.

@@ -147,6 +147,7 @@
boozepwr = 45
ph = 6
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/coffee = 4)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 4)
addiction_types = list(/datum/addiction/coffee = 4) //MONKESTATION EDIT: Add coffee addiction

@@ -196,6 +197,7 @@
overdose_threshold = 60
taste_description = "jitters and death"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(,/datum/addiction/coffee = 5)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(,/datum/addiction/coffee = 5)
addiction_types = list(/datum/addiction/coffee = 5) //MONKESTATION EDIT: Add coffee addiction

@@ -628,6 +630,7 @@
glass_price = DRINK_PRICE_EASY
metabolized_traits = list(TRAIT_FEARLESS, TRAIT_ANALGESIA)
var/tough_text
addiction_types = list(/datum/addiction/coffee = 1)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 1)
addiction_types = list(/datum/addiction/coffee = 1) //MONKESTATION EDIT: Add coffee addiction

@@ -792,6 +795,7 @@
taste_description = "angry and irish"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
glass_price = DRINK_PRICE_EASY
addiction_types = list(/datum/addiction/coffee = 3)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 3)
addiction_types = list(/datum/addiction/coffee = 3) //MONKESTATION EDIT: Add coffee addiction

@@ -805,6 +809,7 @@
quality = DRINK_NICE
taste_description = "giving up on the day"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/coffee = 4)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 4)
addiction_types = list(/datum/addiction/coffee = 4) //MONKESTATION EDIT: Add coffee addiction

@@ -2162,6 +2171,7 @@
taste_description = "fiery, with an aftertaste of burnt flesh"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
bypass_restriction = TRUE
addiction_types = list(/datum/addiction/coffee = 1)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 1)
addiction_types = list(/datum/addiction/coffee = 1) //MONKESTATION EDIT: Add coffee addiction

@@ -2285,6 +2295,7 @@
quality = DRINK_GOOD
taste_description = "strikes and gutters"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/coffee = 1)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 1)
addiction_types = list(/datum/addiction/coffee = 1) //MONKESTATION EDIT: Add coffee addiction

@@ -2786,6 +2797,7 @@
quality = DRINK_NICE
taste_description = "COCONUT"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/coffee = 1)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 1)
addiction_types = list(/datum/addiction/coffee = 1) //MONKESTATION EDIT: Add coffee addiction

@@ -2813,6 +2825,7 @@
quality = DRINK_NICE
taste_description = "coconut coffee"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/coffee = 4)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
addiction_types = list(/datum/addiction/coffee = 4)
addiction_types = list(/datum/addiction/coffee = 4) //MONKESTATION EDIT: Add coffee addiction

@@ -47,7 +47,7 @@
name = "Natural " + name
if(data["boozepwr"])
boozepwr = data["boozepwr"]
addiction_types = list(/datum/addiction/alcohol = 0.05 * boozepwr)
addiction_types += list(/datum/addiction/alcohol = 0.05 * boozepwr)
Copy link
Collaborator

@LikeLakers2 LikeLakers2 Mar 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addiction_types is null by default, so:

Suggested change
addiction_types += list(/datum/addiction/alcohol = 0.05 * boozepwr)
LAZYSET(addiction_types, /datum/addiction/alcohol, 0.05 * boozepwr) //MONKESTATION EDIT: Don't override the existing list

@ThePooba ThePooba merged commit 5e13e9c into Monkestation:master Mar 3, 2025
28 checks passed
github-actions bot added a commit that referenced this pull request Mar 3, 2025
LikeLakers2 added a commit to LikeLakers2/Monkestation2.0 that referenced this pull request Mar 3, 2025
LikeLakers2 added a commit to LikeLakers2/Monkestation2.0 that referenced this pull request Mar 3, 2025
Absolucy pushed a commit that referenced this pull request Mar 6, 2025
## About The Pull Request
This PR adds comments to
`code\modules\reagents\chemistry\reagents\drinks\alcohol_reagents.dm`,
to mark lines that were added/removed/changed from the tgstation
version. Specifically, this targets lines that were changed/added in
#5750, as for one reason or another, the PR was merged without these
comments.

These sorts of comments are incredibly useful when porting PRs from
tgstation - they help porters figure out what might need to be brought
over to the new code, without needing to spend time figuring out if
those lines ever existed on tgstation.

They're also incredibly useful when bugfixing - if I don't spot a
`//MONKESTATION` signifier in a file outside of `monkestation/`, I know
this may have been an issue on tgstation's end, and can see if they
already had a PR that fixed the bug.
san7890 pushed a commit to tgstation/tgstation that referenced this pull request Mar 13, 2025
…ypes` as a lazylist (#89801)

## About The Pull Request
Normally `addiction_types` isn't defined for any subtypes of
`/datum/reagent/consumable/ethanol`, and is instead calculated by
`/datum/reagent/consumable/ethanol/New()`.

However, the way it handles this actually overrides any previously-set
addiction types, forcing any subtypes that would want to have other
addiction types to define them in `New()` *after*
`/datum/reagent/consumable/ethanol/New()` runs.

As an example of this, take a look at
<Monkestation/Monkestation2.0#5750>. It adds a
coffee addiction to any alcoholic reagents which contain coffee - but it
had to edit `/datum/reagent/consumable/ethanol/New()` to account for the
fact that the addiction types list may not be empty.

Thing is, `addiction_types` is already sort of a lazylist - its initial
value (defined in `/datum/reagent/var/addiction_types`) is `null`, so it
was kind of asking to be used this way anyways.

So, to handle the possibility of a subtype setting other addiction
types, and additionally to make the code a little nicer by using
`addiction_types` as the lazylist it seems to want to be, I've modified
`/datum/reagent/consumable/ethanol/New()` to use `LAZYSET` when adding
the alcohol addiction.

--

I also changed it such that the alcohol addiction is only added if
`boozepwr` is any value other than `0`. This ensures that, if the
reagent in question doesn't use `boozepwr`, and has no other addiction
types, `addiction_types` will stay `null`. This saves a little bit of
memory - admittedly, not much, but still!

## Why It's Good For The Game
Subtypes of `/datum/reagent/consumable/ethanol` can now have default
addiction types other than `/datum/addiction/alcohol`.

## Changelog
No player-facing changes.
lessthnthree pushed a commit to effigy-se/effigy that referenced this pull request Mar 14, 2025
…ypes` as a lazylist (#89801)

## About The Pull Request
Normally `addiction_types` isn't defined for any subtypes of
`/datum/reagent/consumable/ethanol`, and is instead calculated by
`/datum/reagent/consumable/ethanol/New()`.

However, the way it handles this actually overrides any previously-set
addiction types, forcing any subtypes that would want to have other
addiction types to define them in `New()` *after*
`/datum/reagent/consumable/ethanol/New()` runs.

As an example of this, take a look at
<Monkestation/Monkestation2.0#5750>. It adds a
coffee addiction to any alcoholic reagents which contain coffee - but it
had to edit `/datum/reagent/consumable/ethanol/New()` to account for the
fact that the addiction types list may not be empty.

Thing is, `addiction_types` is already sort of a lazylist - its initial
value (defined in `/datum/reagent/var/addiction_types`) is `null`, so it
was kind of asking to be used this way anyways.

So, to handle the possibility of a subtype setting other addiction
types, and additionally to make the code a little nicer by using
`addiction_types` as the lazylist it seems to want to be, I've modified
`/datum/reagent/consumable/ethanol/New()` to use `LAZYSET` when adding
the alcohol addiction.

--

I also changed it such that the alcohol addiction is only added if
`boozepwr` is any value other than `0`. This ensures that, if the
reagent in question doesn't use `boozepwr`, and has no other addiction
types, `addiction_types` will stay `null`. This saves a little bit of
memory - admittedly, not much, but still!

## Why It's Good For The Game
Subtypes of `/datum/reagent/consumable/ethanol` can now have default
addiction types other than `/datum/addiction/alcohol`.

## Changelog
No player-facing changes.
vinylspiders pushed a commit to NovaSector/NovaSector that referenced this pull request Mar 17, 2025
…ypes` as a lazylist (#89801)

## About The Pull Request
Normally `addiction_types` isn't defined for any subtypes of
`/datum/reagent/consumable/ethanol`, and is instead calculated by
`/datum/reagent/consumable/ethanol/New()`.

However, the way it handles this actually overrides any previously-set
addiction types, forcing any subtypes that would want to have other
addiction types to define them in `New()` *after*
`/datum/reagent/consumable/ethanol/New()` runs.

As an example of this, take a look at
<Monkestation/Monkestation2.0#5750>. It adds a
coffee addiction to any alcoholic reagents which contain coffee - but it
had to edit `/datum/reagent/consumable/ethanol/New()` to account for the
fact that the addiction types list may not be empty.

Thing is, `addiction_types` is already sort of a lazylist - its initial
value (defined in `/datum/reagent/var/addiction_types`) is `null`, so it
was kind of asking to be used this way anyways.

So, to handle the possibility of a subtype setting other addiction
types, and additionally to make the code a little nicer by using
`addiction_types` as the lazylist it seems to want to be, I've modified
`/datum/reagent/consumable/ethanol/New()` to use `LAZYSET` when adding
the alcohol addiction.

--

I also changed it such that the alcohol addiction is only added if
`boozepwr` is any value other than `0`. This ensures that, if the
reagent in question doesn't use `boozepwr`, and has no other addiction
types, `addiction_types` will stay `null`. This saves a little bit of
memory - admittedly, not much, but still!

## Why It's Good For The Game
Subtypes of `/datum/reagent/consumable/ethanol` can now have default
addiction types other than `/datum/addiction/alcohol`.

## Changelog
No player-facing changes.
vinylspiders pushed a commit to NovaSector/NovaSector that referenced this pull request Mar 17, 2025
…ypes` as a lazylist (#89801)

## About The Pull Request
Normally `addiction_types` isn't defined for any subtypes of
`/datum/reagent/consumable/ethanol`, and is instead calculated by
`/datum/reagent/consumable/ethanol/New()`.

However, the way it handles this actually overrides any previously-set
addiction types, forcing any subtypes that would want to have other
addiction types to define them in `New()` *after*
`/datum/reagent/consumable/ethanol/New()` runs.

As an example of this, take a look at
<Monkestation/Monkestation2.0#5750>. It adds a
coffee addiction to any alcoholic reagents which contain coffee - but it
had to edit `/datum/reagent/consumable/ethanol/New()` to account for the
fact that the addiction types list may not be empty.

Thing is, `addiction_types` is already sort of a lazylist - its initial
value (defined in `/datum/reagent/var/addiction_types`) is `null`, so it
was kind of asking to be used this way anyways.

So, to handle the possibility of a subtype setting other addiction
types, and additionally to make the code a little nicer by using
`addiction_types` as the lazylist it seems to want to be, I've modified
`/datum/reagent/consumable/ethanol/New()` to use `LAZYSET` when adding
the alcohol addiction.

--

I also changed it such that the alcohol addiction is only added if
`boozepwr` is any value other than `0`. This ensures that, if the
reagent in question doesn't use `boozepwr`, and has no other addiction
types, `addiction_types` will stay `null`. This saves a little bit of
memory - admittedly, not much, but still!

## Why It's Good For The Game
Subtypes of `/datum/reagent/consumable/ethanol` can now have default
addiction types other than `/datum/addiction/alcohol`.

## Changelog
No player-facing changes.
Iajret pushed a commit to Fluffy-Frontier/FluffySTG that referenced this pull request Mar 21, 2025
…ypes` as a lazylist (#89801)

## About The Pull Request
Normally `addiction_types` isn't defined for any subtypes of
`/datum/reagent/consumable/ethanol`, and is instead calculated by
`/datum/reagent/consumable/ethanol/New()`.

However, the way it handles this actually overrides any previously-set
addiction types, forcing any subtypes that would want to have other
addiction types to define them in `New()` *after*
`/datum/reagent/consumable/ethanol/New()` runs.

As an example of this, take a look at
<Monkestation/Monkestation2.0#5750>. It adds a
coffee addiction to any alcoholic reagents which contain coffee - but it
had to edit `/datum/reagent/consumable/ethanol/New()` to account for the
fact that the addiction types list may not be empty.

Thing is, `addiction_types` is already sort of a lazylist - its initial
value (defined in `/datum/reagent/var/addiction_types`) is `null`, so it
was kind of asking to be used this way anyways.

So, to handle the possibility of a subtype setting other addiction
types, and additionally to make the code a little nicer by using
`addiction_types` as the lazylist it seems to want to be, I've modified
`/datum/reagent/consumable/ethanol/New()` to use `LAZYSET` when adding
the alcohol addiction.

--

I also changed it such that the alcohol addiction is only added if
`boozepwr` is any value other than `0`. This ensures that, if the
reagent in question doesn't use `boozepwr`, and has no other addiction
types, `addiction_types` will stay `null`. This saves a little bit of
memory - admittedly, not much, but still!

## Why It's Good For The Game
Subtypes of `/datum/reagent/consumable/ethanol` can now have default
addiction types other than `/datum/addiction/alcohol`.

## Changelog
No player-facing changes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature: Feature The creature feature. featuring: the creature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants