Skip to content
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

[PORT] Moon Heretic #1698

Merged
merged 25 commits into from
May 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
657ff9b
FUCKING HUGE COMMIT
ancient-engineer Apr 19, 2024
477a1bc
Fixes
ancient-engineer Apr 19, 2024
c6e73c5
Fixes
ancient-engineer Apr 19, 2024
5b4523e
Fixes
ancient-engineer Apr 19, 2024
22ec466
Merge branch 'master' into MoonHeretic
ancient-engineer Apr 19, 2024
99ae5df
Merge branch 'master' into MoonHeretic
ancient-engineer Apr 20, 2024
50a5b8e
Merge branch 'master' into MoonHeretic
ancient-engineer Apr 23, 2024
64c2566
Temp change for testmerging
ancient-engineer Apr 23, 2024
370f037
Fix
ancient-engineer Apr 23, 2024
9933858
Fix
ancient-engineer Apr 24, 2024
3ee2154
Adds custom moon ascend sound from https://github.com/flleeppyy
ancient-engineer Apr 24, 2024
d6e54ca
Fix
ancient-engineer Apr 26, 2024
f07c9e5
Removes https://github.com/tgstation/tgstation/pull/76204
ancient-engineer Apr 27, 2024
5455fe8
Fix
ancient-engineer Apr 27, 2024
7271121
Merge branch 'master' into MoonHeretic
ancient-engineer Apr 27, 2024
47ed8fb
Fixes
ancient-engineer Apr 27, 2024
e0a0684
Fix
ancient-engineer Apr 27, 2024
4716023
Fix
ancient-engineer Apr 27, 2024
d7d582f
Adds sidepath points to moon_lore.dm
ancient-engineer Apr 29, 2024
9881eef
Merge branch 'master' into MoonHeretic
ancient-engineer May 9, 2024
1fc3ade
Merge branch 'master' into MoonHeretic
ancient-engineer May 13, 2024
5546397
Reverts https://github.com/Monkestation/Monkestation2.0/pull/1698/com…
ancient-engineer May 22, 2024
2711eb1
Merge branch 'master' into MoonHeretic
ancient-engineer May 22, 2024
a9281fa
Merge branch 'master' into MoonHeretic
ancient-engineer May 28, 2024
de16a7e
Merge branch 'master' into MoonHeretic
ancient-engineer May 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions code/__DEFINES/achievements.dm
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
#define MEDAL_BLADE_ASCENSION "Blade"
#define MEDAL_COSMOS_ASCENSION "Cosmos"
#define MEDAL_KNOCK_ASCENSION "Knock"
#define MEDAL_MOON_ASCENSION "Moon"
#define MEDAL_TOOLBOX_SOUL "Toolsoul"
#define MEDAL_CHEM_TUT "Beginner Chemist"
#define MEDAL_HOT_DAMN "Hot Damn!"
Expand Down
7 changes: 5 additions & 2 deletions code/__DEFINES/antagonists.dm
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@
#define PATH_BLADE "Blade Path"
#define PATH_COSMIC "Cosmic Path"
#define PATH_KNOCK "Knock Path"
#define PATH_MOON "Moon Path"

/// Defines are used in /proc/has_living_heart() to report if the heretic has no heart period, no living heart, or has a living heart.
#define HERETIC_NO_HEART_ORGAN -1
Expand Down Expand Up @@ -219,8 +220,10 @@ GLOBAL_LIST_INIT(ai_employers, list(
#define IS_HERETIC(mob) (mob.mind?.has_antag_datum(/datum/antagonist/heretic))
/// Check if the given mob is a heretic monster.
#define IS_HERETIC_MONSTER(mob) (mob.mind?.has_antag_datum(/datum/antagonist/heretic_monster))
/// Checks if the given mob is either a heretic or a heretic monster.
#define IS_HERETIC_OR_MONSTER(mob) (IS_HERETIC(mob) || IS_HERETIC_MONSTER(mob))
/// Check if the given mob is a lunatic
#define IS_LUNATIC(mob) (mob.mind?.has_antag_datum(/datum/antagonist/lunatic))
/// Checks if the given mob is either a heretic, heretic monster or a lunatic.
#define IS_HERETIC_OR_MONSTER(mob) (IS_HERETIC(mob) || IS_HERETIC_MONSTER(mob) || IS_LUNATIC(mob))

/// Checks if the given mob is a wizard
#define IS_WIZARD(mob) (mob?.mind?.has_antag_datum(/datum/antagonist/wizard))
Expand Down
7 changes: 7 additions & 0 deletions code/__DEFINES/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1316,6 +1316,13 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai

///trait determines if this mob can breed given by /datum/component/breeding
#define TRAIT_MOB_BREEDER "mob_breeder"

/// Trait determines if this mob has examined an eldritch painting
#define TRAIT_ELDRITCH_PAINTING_EXAMINE "eldritch_painting_examine"

/// Trait used by the /datum/brain_trauma/severe/flesh_desire trauma to change their preferences of what they eat
#define TRAIT_FLESH_DESIRE "flesh_desire"

///trait given to food that can be baked by /datum/component/bakeable
#define TRAIT_BAKEABLE "bakeable"

Expand Down
2 changes: 2 additions & 0 deletions code/_globalvars/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_LITERATE" = TRAIT_LITERATE,
"TRAIT_ILLITERATE" = TRAIT_ILLITERATE,
"TRAIT_MUTE" = TRAIT_MUTE,
"TRAIT_ELDRITCH_PAINTING_EXAMINE" = TRAIT_ELDRITCH_PAINTING_EXAMINE,
"TRAIT_FLESH_DESIRE" = TRAIT_FLESH_DESIRE,
"TRAIT_EMOTEMUTE " = TRAIT_EMOTEMUTE,
"TRAIT_DEAF" = TRAIT_DEAF,
"TRAIT_FAT" = TRAIT_FAT,
Expand Down
6 changes: 6 additions & 0 deletions code/datums/achievements/misc_achievements.dm
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@
database_id = MEDAL_COSMOS_ASCENSION
icon = "cosmicascend"

/datum/award/achievement/misc/moon_ascension
name = "The Last Act"
desc = "You managed to become the ringleader and slay the lie."
database_id = MEDAL_MOON_ASCENSION
icon = "moonascend"

/datum/award/achievement/misc/grand_ritual_finale
name = "Archmage"
desc = "Made a big impression on the station with your phenomenal cosmic power."
Expand Down
101 changes: 101 additions & 0 deletions code/datums/brain_damage/severe.dm
Original file line number Diff line number Diff line change
Expand Up @@ -319,3 +319,104 @@
/datum/brain_trauma/severe/dyslexia/on_lose()
REMOVE_TRAIT(owner, TRAIT_ILLITERATE, TRAUMA_TRAIT)
..()

/*
* Brain traumas that eldritch paintings apply
* This one is for "The Sister and He Who Wept" or /obj/structure/sign/painting/eldritch
*/
/datum/brain_trauma/severe/weeping
name = "The Weeping"
desc = "Patient hallucinates everyone as a figure called He Who Wept"
scan_desc = "H_E##%%%WEEP6%11S!!,)()"
gain_text = span_warning("HE WEEPS AND I WILL SEE HIM ONCE MORE")
lose_text = span_notice("You feel the tendrils of something slip from your mind.")
random_gain = FALSE
/// Our cooldown declare for causing hallucinations
COOLDOWN_DECLARE(weeping_hallucinations)

/datum/brain_trauma/severe/weeping/on_life(seconds_per_tick, times_fired)
if(owner.stat != CONSCIOUS || owner.IsSleeping() || owner.IsUnconscious())
return
// If they have examined a painting recently
if(HAS_TRAIT(owner, TRAIT_ELDRITCH_PAINTING_EXAMINE))
return
if(!COOLDOWN_FINISHED(src, weeping_hallucinations))
return
owner.cause_hallucination(/datum/hallucination/delusion/preset/heretic, "Caused by The Weeping brain trauma")
owner.add_mood_event("eldritch_weeping", /datum/mood_event/eldritch_painting/weeping)
COOLDOWN_START(src, weeping_hallucinations, 10 SECONDS)
..()

//This one is for "The First Desire" or /obj/structure/sign/painting/eldritch/desire
/datum/brain_trauma/severe/flesh_desire
name = "The Desire for Flesh"
desc = "Patient appears hungrier and only wishes to eat meats."
scan_desc = "H_(82882)G3E:__))9R"
gain_text = span_warning("I feel a hunger, only organs and flesh will feed it...")
lose_text = span_notice("You no longer feel the hunger for flesh...")
random_gain = FALSE
/// How much faster we loose hunger
var/hunger_rate = 15

/datum/brain_trauma/severe/flesh_desire/on_gain()
// Allows them to eat faster, mainly for flavor
ADD_TRAIT(owner, TRAIT_VORACIOUS, REF(src))
ADD_TRAIT(owner, TRAIT_FLESH_DESIRE, REF(src))
..()

/datum/brain_trauma/severe/flesh_desire/on_life(seconds_per_tick, times_fired)
// Causes them to need to eat at 10x the normal rate
owner.adjust_nutrition(-hunger_rate * HUNGER_FACTOR)
if(SPT_PROB(10, seconds_per_tick))
to_chat(owner, span_notice("You feel a ravenous hunger for flesh..."))
owner.overeatduration = max(owner.overeatduration - 200 SECONDS, 0)

/datum/brain_trauma/severe/flesh_desire/on_lose()
REMOVE_TRAIT(owner, TRAIT_VORACIOUS, REF(src))
REMOVE_TRAIT(owner, TRAIT_FLESH_DESIRE, REF(src))
return ..()

// This one is for "Lady out of gates" or /obj/item/wallframe/painting/eldritch/beauty
/datum/brain_trauma/severe/eldritch_beauty
name = "The Pursuit of Perfection"
desc = "Patient seems to furiously scratch at their body, the only way to make them cease is for them to remove their jumpsuit."
scan_desc = "I_)8(P_E##R&&F(E)C__T)"
gain_text = span_warning("I WILL RID MY FLESH FROM IMPERFECTION!! I WILL BE PERFECT WITHOUT MY SUITS!!")
lose_text = span_notice("You feel the influence of something slip your mind, and you feel content as you are.")
random_gain = FALSE
/// How much damage we deal with each scratch
var/scratch_damage = 0.5

/datum/brain_trauma/severe/eldritch_beauty/on_life(seconds_per_tick, times_fired)
// Jumpsuits ruin the "perfection" of the body
if(!owner.get_item_by_slot(ITEM_SLOT_ICLOTHING))
return

// Scratching code
var/obj/item/bodypart/bodypart = owner.get_bodypart(owner.get_random_valid_zone(even_weights = TRUE))
if(!(bodypart && IS_ORGANIC_LIMB(bodypart)) && bodypart.bodypart_flags & BODYPART_PSEUDOPART)
return
if(owner.incapacitated())
return
bodypart.receive_damage(scratch_damage)
if(SPT_PROB(33, seconds_per_tick))
to_chat(owner, span_notice("You scratch furiously at [bodypart] to ruin the cloth that hides the beauty!"))

// This one is for "Climb over the rusted mountain" or /obj/structure/sign/painting/eldritch/rust
/datum/brain_trauma/severe/rusting
name = "The Rusted Climb"
desc = "Patient seems to oxidise things around them at random, and seem to believe they are aiding a creature in climbing a mountin."
scan_desc = "C_)L(#_I_##M;B"
gain_text = span_warning("The rusted climb shall finish at the peak")
lose_text = span_notice("The rusted climb? Whats that? An odd dream to be sure.")
random_gain = FALSE

/datum/brain_trauma/severe/rusting/on_life(seconds_per_tick, times_fired)
var/atom/tile = get_turf(owner)
// Examining a painting should stop this effect to give counterplay
if(HAS_TRAIT(owner, TRAIT_ELDRITCH_PAINTING_EXAMINE))
return

if(SPT_PROB(50, seconds_per_tick))
to_chat(owner, span_notice("You feel eldritch energies pulse from your body!"))
tile.rust_heretic_act()
4 changes: 4 additions & 0 deletions code/datums/looping_sounds/projectiles.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/datum/looping_sound/moon_parade
mid_sounds = list('sound/effects/moon_parade_soundloop.ogg' = 1)
mid_length = 0
volume = 20
48 changes: 48 additions & 0 deletions code/datums/mood_events/eldritch_painting_events.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
// These mood events are related to /obj/structure/sign/painting/eldritch
// Names are based on the subtype of painting they belong to

// Mood applied for ripping the painting
/datum/mood_event/eldritch_painting
description = "YOU, I SHOULD NOT HAVE DONE THAT!!!"
mood_change = -6
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/weeping
description = "HE IS HERE, AND HE WEEPS!"
mood_change = -3
timeout = 11 SECONDS

/datum/mood_event/eldritch_painting/weeping_heretic
description = "Oh such arts! They truly inspire me!"
mood_change = 5
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/weeping_withdrawl
description = "My mind is clear from his influence."
mood_change = 1
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/desire_heretic
description = "A part gained, the manus takes and gives. What did it take from me?"
mood_change = -2
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/desire_examine
description = "A hunger kept at bay..."
mood_change = 3
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/heretic_vines
description = "Oh what a lovely flower!"
mood_change = 3
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/rust_examine
description = "The rusted climb can wait..."
mood_change = -2
timeout = 3 MINUTES

/datum/mood_event/eldritch_painting/rust_heretic_examine
description = "I must hurry the rusted climb!"
mood_change = 6
timeout = 3 MINUTES
10 changes: 10 additions & 0 deletions code/datums/mood_events/generic_negative_events.dm
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,16 @@
description = "I've been here too long! I want to go out and explore space!"
mood_change = -3

/datum/mood_event/moon_insanity
description = "THE MOON JUDGES AND FINDS ME WANTING!!!"
mood_change = -3
timeout = 5 MINUTES

/datum/mood_event/amulette_insanity
description = "I sEe THe LiGHt, It mUsT BE stOPPed"
mood_change = -6
timeout = 5 MINUTES

///Wizard cheesy grand finale - what everyone but the wizard gets
/datum/mood_event/madness_despair
description = "UNWORTHY, UNWORTHY, UNWORTHY!!!"
Expand Down
5 changes: 5 additions & 0 deletions code/datums/mood_events/generic_positive_events.dm
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,11 @@
special_screen_obj = "birthday"
special_screen_replace = FALSE

/datum/mood_event/moon_smile
description = "THE MOON SHOWS ME THE TRUTH AND ITS SMILE IS FACED TOWARDS ME!!!"
mood_change = 10
timeout = 2 MINUTES

///Wizard cheesy grand finale - what the wizard gets
/datum/mood_event/madness_elation
description = "Madness truly is the greatest of blessings..."
Expand Down
2 changes: 2 additions & 0 deletions code/modules/antagonists/heretic/heretic_antag.dm
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
PATH_BLADE = "label", // my favorite color is label
PATH_COSMIC = "purple",
PATH_KNOCK = "yellow",
PATH_MOON = "blue",
)
var/static/list/path_to_rune_color = list(
PATH_START = COLOR_LIME,
Expand All @@ -76,6 +77,7 @@
PATH_BLADE = COLOR_SILVER,
PATH_COSMIC = COLOR_PURPLE,
PATH_KNOCK = COLOR_YELLOW,
PATH_MOON = COLOR_BLUE_LIGHT,
)

/datum/antagonist/heretic/Destroy()
Expand Down
3 changes: 1 addition & 2 deletions code/modules/antagonists/heretic/heretic_knowledge.dm
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
return TRUE

/**
* Parses specific items into a more reaadble form.
* Parses specific items into a more readble form.
* Can be overriden by knoweldge subtypes.
*/
/datum/heretic_knowledge/proc/parse_required_item(atom/item_path, number_of_things)
Expand Down Expand Up @@ -185,7 +185,6 @@
continue
how_much_to_use = min(required_atoms[requirement], sac_stack.amount)
break

sac_stack.use(how_much_to_use)
continue

Expand Down
Loading
Loading