Skip to content

Commit

Permalink
Maintenance God Glow Up (#2347)
Browse files Browse the repository at this point in the history
* Ritual for Maint God

* Update maint_god.dm

* Update tgstation.dme

* Update maint_god.dm

* granter

* Easier rat cubes, and new rituals.

* Wow, maintenance addiction shouldn't be that bad.

* Update MaintenanceEncyclopedia.dm

* Update maint_god.dm

* Update biogenerator_designs.dm

* Update maint_god.dm

* Rename MaintenanceEncyclopedia.dm to maintenanceencyclopedia.dm

Git decided to be yucky and ignore my earlier change.

* Expands pallet a bit more.

* Flavor

* Revert "Merge remote-tracking branch 'upstream/master' into MaintGod"

This reverts commit b1ce833, reversing
changes made to e44493e.

* Reapply "Merge remote-tracking branch 'upstream/master' into MaintGod"

This reverts commit cccdb02.

* Apply suggestions from code review

Co-authored-by: wraith-54321 <[email protected]>

* Update biogenerator_designs.dm

* turf thing, spacing, modularization

* Update maintenance_loot.dm

---------

Co-authored-by: wraith-54321 <[email protected]>
  • Loading branch information
Uristthedorf and wraith-54321 authored Aug 12, 2024
1 parent 44df7f4 commit 74f4934
Show file tree
Hide file tree
Showing 7 changed files with 129 additions and 6 deletions.
7 changes: 7 additions & 0 deletions code/_globalvars/lists/maintenance_loot.dm
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,13 @@ GLOBAL_LIST_INIT(maintenance_loot, list(
GLOB.maint_fauna = maint_fauna_weight,
))

//Monke, loot pool of uncommon or better loot, used in maint god rituals
GLOBAL_LIST_INIT(good_maintenance_loot, list(
GLOB.uncommon_loot = maint_uncommon_weight,
GLOB.rarity_loot = maint_rarity_weight,
GLOB.oddity_loot = maint_oddity_weight,
))

GLOBAL_LIST_INIT(ratking_trash, list(//Garbage: used by the regal rat mob when spawning garbage.
/obj/item/cigbutt,
/obj/item/trash/candy,
Expand Down
6 changes: 3 additions & 3 deletions code/modules/reagents/withdrawal/generic_addictions.dm
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@

/datum/addiction/maintenance_drugs/withdrawal_enters_stage_1(mob/living/carbon/affected_carbon)
. = ..()
affected_carbon.apply_status_effect(/datum/status_effect/grouped/screwy_hud/fake_healthy, type)
// affected_carbon.apply_status_effect(/datum/status_effect/grouped/screwy_hud/fake_healthy, type) // Monke disable, this has nothing to do with maintenance.

/datum/addiction/maintenance_drugs/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
Expand All @@ -113,8 +113,8 @@
affected_human.update_body_parts()
//Only like gross food
affected_human.dna?.species.liked_food = GROSS
affected_human.dna?.species.disliked_food = NONE
affected_human.dna?.species.toxic_food = ~GROSS
affected_human.dna?.species.disliked_food = TOXIC // Toxic food won't kill you, but it doesn't taste good still.
affected_human.dna?.species.toxic_food = ~(GROSS | RAW | GORE | MEAT | BUGS | TOXIC | ALCOHOL) // Monke, you can eat raw rats and whatnot.

/datum/addiction/maintenance_drugs/withdrawal_enters_stage_3(mob/living/carbon/affected_carbon)
. = ..()
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/obj/item/book/granter/crafting_recipe/maintgodgranter
name = "maintenance encyclopedia"
icon_state = "book1"
desc = "A burnt and damaged tome? Where did this come from?"
crafting_recipe_types = list(
/datum/crafting_recipe/pipegun_prime,
/datum/crafting_recipe/laser_musket_prime,
/datum/crafting_recipe/smoothbore_disabler_prime,
/datum/crafting_recipe/trash_cannon,
/datum/crafting_recipe/trashball,
)
remarks = list(
"I never knew assistants could be this creative.",
"You can make that with what?",
"Why would I make these when I can just buy a gun from cargo?", // Maybe needs more.
)

/obj/item/book/granter/crafting_recipe/maintgodgranter/recoil(mob/living/user)
to_chat(user, span_warning("The book turns to dust in your hands."))
qdel(src)
87 changes: 87 additions & 0 deletions monkestation/code/modules/religion/maint_god.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
/datum/religion_sect/maintenance
rites_list = list(/datum/religion_rites/maint_adaptation, /datum/religion_rites/shadowascension, /datum/religion_rites/maint_loot, /datum/religion_rites/adapted_food, /datum/religion_rites/weapon_granter, /datum/religion_rites/ritual_totem)

/datum/religion_rites/weapon_granter
name = "Maintenance Knowledge"
desc = "Creates a tome teaching you how to make improved improvised weapons."
favor_cost = 100 //You still have to make the weapon afterwards, might want to change this though.
invoke_msg = "Grant me your ingenuity!"
ritual_length = 5 SECONDS

/datum/religion_rites/weapon_granter/invoke_effect(mob/living/user, atom/movable/religious_tool)
..()
new /obj/item/book/granter/crafting_recipe/maintgodgranter(get_turf(religious_tool))
return TRUE

/datum/religion_rites/shadowascension
name = "Shadow Descent"
desc = "Descends a maintenance adapted being into a shadowperson. Buckle a human to convert them, otherwise it will convert you." // Quite a bit copied from android conversion.
ritual_length = 15 SECONDS
invoke_msg = "I no longer want to see the light!"
favor_cost = 300

/datum/religion_rites/shadowascension/perform_rite(mob/living/user, atom/religious_tool)
if(!ismovable(religious_tool))
to_chat(user, span_warning("This rite requires a religious device that individuals can be buckled to."))
return FALSE

if(!HAS_TRAIT_FROM(user, TRAIT_HOPELESSLY_ADDICTED, "maint_adaptation"))
to_chat(user, span_warning("You need to adapt to maintenance first."))
return FALSE
var/atom/movable/movable_reltool = religious_tool

if(!movable_reltool)
return FALSE

if(LAZYLEN(movable_reltool.buckled_mobs))
to_chat(user, span_warning("You're going to convert the one buckled on [movable_reltool]."))
else
if(!movable_reltool.can_buckle) //yes, if you have somehow managed to have someone buckled to something that now cannot buckle, we will still let you perform the rite!
to_chat(user, span_warning("This rite requires a religious device that individuals can be buckled to."))
return FALSE
if((is_species(user, /datum/species/shadow))) // There is no isshadow() helper
to_chat(user, span_warning("You've already converted yourself. To convert others, they must be buckled to [movable_reltool]."))
return FALSE
to_chat(user, span_warning("You're going to convert yourself with this ritual."))
return ..()

/datum/religion_rites/shadowascension/invoke_effect(mob/living/user, atom/religious_tool)
..()
if(!ismovable(religious_tool))
CRASH("[name]'s perform_rite had a movable atom that has somehow turned into a non-movable!")
var/atom/movable/movable_reltool = religious_tool
var/mob/living/carbon/human/rite_target

if(!length(movable_reltool.buckled_mobs))
rite_target = user
else
for(var/buckled in movable_reltool.buckled_mobs)
if(ishuman(buckled))
rite_target = buckled
break

if(!rite_target)
return FALSE
rite_target.set_species(/datum/species/shadow)
rite_target.visible_message(span_notice("[rite_target] has been converted by the rite of [name]!"))
return TRUE

/datum/religion_rites/maint_loot //Useful for when maintenance has been picked clean of anything interesting.
name = "Maintenance apparition"
desc = "Summons a pile of loot from the depths of maintenance."
ritual_length = 5 SECONDS
ritual_invocations =list( "The tunnels are an infinite bounty.",
"They nourish us.")
invoke_msg = "Let us reap the harvest!"
favor_cost = 50
var/amount = 5

/datum/religion_rites/maint_loot/invoke_effect(mob/living/user, atom/movable/religious_tool)
..()
var/altar_turf = get_turf(religious_tool) // Like an assistant, I steal code from other functions.
for(var/i in 1 to amount)
var/lootspawn = pick_weight(GLOB.good_maintenance_loot)
while(islist(lootspawn))
lootspawn = pick_weight(lootspawn)
new lootspawn(altar_turf)
return TRUE
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/datum/design/rat_cube // Monkestation, useful for chaplain and pathologist.
name = "Mouse Cube"
id = "rcube" // R for Rat
build_type = BIOGENERATOR
materials = list(/datum/material/biomass = SMALL_MATERIAL_AMOUNT * 0.4)
build_path = /obj/item/food/monkeycube/mouse
category = list(RND_CATEGORY_INITIAL, RND_CATEGORY_BIO_FOOD)
5 changes: 2 additions & 3 deletions monkestation/code/modules/virology/cargo/pathology.dm
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
/datum/supply_pack/medical/rat_cubes
name = "Crate of Rat Cube Boxes"
desc = "A pack of 5 boxes of rat-cubes"
cost = CARGO_CRATE_VALUE * 5
access = ACCESS_VIROLOGY
cost = CARGO_CRATE_VALUE * 4
contains = list(
/obj/item/storage/box/monkeycubes/mousecubes,
/obj/item/storage/box/monkeycubes/mousecubes,
Expand All @@ -26,4 +25,4 @@
/obj/item/storage/box/monkeycubes/mousecubes,
)
crate_name = "rat cube crates"
crate_type = /obj/structure/closet/crate/secure/science
crate_type = /obj/structure/closet/crate
3 changes: 3 additions & 0 deletions tgstation.dme
Original file line number Diff line number Diff line change
Expand Up @@ -5903,6 +5903,7 @@
#include "monkestation\code\game\objects\items\food\snacks.dm"
#include "monkestation\code\game\objects\items\food\spaghetti.dm"
#include "monkestation\code\game\objects\items\granters\elance.dm"
#include "monkestation\code\game\objects\items\granters\maintenanceencyclopedia.dm"
#include "monkestation\code\game\objects\items\grenades\monkey_barrel.dm"
#include "monkestation\code\game\objects\items\guns\crank_guns.dm"
#include "monkestation\code\game\objects\items\guns\shotguns.dm"
Expand Down Expand Up @@ -7376,8 +7377,10 @@
#include "monkestation\code\modules\reagents\reagent_containers\cups\glassbottle.dm"
#include "monkestation\code\modules\reagents\recipes\fun.dm"
#include "monkestation\code\modules\reagents\recipes\medical.dm"
#include "monkestation\code\modules\religion\maint_god.dm"
#include "monkestation\code\modules\replays\hooks\generic_hooks.dm"
#include "monkestation\code\modules\replays\subsystem\replay.dm"
#include "monkestation\code\modules\research\designs\biogenerator_designs.dm"
#include "monkestation\code\modules\research\designs\computer_designs.dm"
#include "monkestation\code\modules\research\designs\electronic_designs.dm"
#include "monkestation\code\modules\research\designs\machine_designs.dm"
Expand Down

0 comments on commit 74f4934

Please sign in to comment.