mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-12 00:27:31 +01:00
Fixes for boulder processing machines (#96033)
## About The Pull Request - Opening the panel of a boulder refiner machine or un-wrenching it now turns off its environment light - The boulder refiner machine has reagent holder of type `/datum/reagents/plumbing` which fixes rounding errors & has other plumbing optimized features - The boulder refiner machine now only takes in booster reagents & only outputs waste reagent. This means even if you have a tank with random reagents attached to it, it will only take in booster reagents if present & exclude the rest thus saving you time & space from taking in other reagents - booster reagents is now a static list shared by all machines thus saving memory - Removed `supply_offset` & `demand_offset` vars from core plumbing component. These vars were making the pipes extend outside the tile causing it to overlap with adjacent tile machine pipes making everything ugly. Now the pipes are perpendicular to the conveyer belt sprite and will only take in boulders from the conveyer belt direction https://github.com/user-attachments/assets/5583a790-32b6-40df-a414-1602dd84fefd - Map edited smelters so the conveyer belt is in the direction of the refiner ## Changelog 🆑 fix: opening panel of boulder refinery with screwdriver or un-wrenching it turns of its light fix: boulder refinery only takes in booster reagents and excludes others and only outputs waste chemicals as intended fix: boulder refinery machines outputs waste reagents without rounding errors in them qol: removed conveyer sprite from boulder smelter & pixel shifts the refiner so you can see it's plumbing pipes properly sprite: smelters will now only take in boulders in the direction of its conveyer belt. It's plumbing pipes are perpendicular to its conveyer belt /🆑
This commit is contained in:
@@ -22,10 +22,6 @@
|
||||
var/points_held = 0
|
||||
///The action verb to display to players
|
||||
var/action = "processing"
|
||||
|
||||
|
||||
/// What list of reagents should we look at when we boost the effectiveness of this machinery? Assign a value to a chem as well, eg: /datum/reagent/water = 1 is a 10% boost
|
||||
var/list/booster_list = list()
|
||||
/// What reagent should be produced when a boost chemical is replaced by the booster_reagent?
|
||||
var/datum/reagent/waste_chemical = /datum/reagent/water
|
||||
|
||||
@@ -107,6 +103,7 @@
|
||||
/obj/machinery/bouldertech/examine_more(mob/user)
|
||||
. = ..()
|
||||
|
||||
var/list/datum/reagents/booster_list = get_booster_reagents()
|
||||
if(length(booster_list))
|
||||
. += span_notice("This machine's output is boosted by <b>chemical intake:</b><br>")
|
||||
for(var/datum/reagent/increment as anything in booster_list)
|
||||
@@ -121,7 +118,7 @@
|
||||
icon_state ="[base_icon_state][suffix]"
|
||||
|
||||
/obj/machinery/bouldertech/CanAllowThrough(atom/movable/mover, border_dir)
|
||||
if(!anchored)
|
||||
if(!anchored || !(dir == border_dir || dir == REVERSE_DIR(border_dir)))
|
||||
return FALSE
|
||||
if(istype(mover, /obj/item/stack/sheet))
|
||||
return TRUE
|
||||
@@ -254,6 +251,12 @@
|
||||
|
||||
refining_efficiency = initial(refining_efficiency) //Reset refining efficiency to 100%.
|
||||
|
||||
///Returns a map of reagent -> boost amount to increase this machines efficiency
|
||||
/obj/machinery/bouldertech/proc/get_booster_reagents()
|
||||
RETURN_TYPE(/list/datum/reagents)
|
||||
|
||||
return list()
|
||||
|
||||
/**
|
||||
* Checks if this machine can process this material
|
||||
* Arguments
|
||||
@@ -380,7 +383,7 @@
|
||||
if(istype(chosen_boulder, /obj/item/boulder/artifact))
|
||||
points_held = round((points_held + MINER_POINT_MULTIPLIER)) /// Artifacts give bonus points!
|
||||
chosen_boulder.break_apart()
|
||||
return//We've processed all the materials in the boulder, so we can just destroy it in break_apart.
|
||||
return //We've processed all the materials in the boulder, so we can just destroy it in break_apart.
|
||||
|
||||
chosen_boulder.processed_by = src
|
||||
|
||||
|
||||
Reference in New Issue
Block a user