mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-26 01:22:03 +00:00
* [TEST-MERGE FIRST] Wound refactor number two: Full synthetic support * Wound refactor two compatability (#23618) * Delam emergency procedure moth (#23483) * safety moff * delta/whitespace/examine * icebox * moff poster * moff poster * Update DelamProcedure.tsx * Update scram.dm * sound plays during warning * remove nightshift, theres already a global proc * scrubber hint * missed that define * Apply suggestions from code review Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com> * covered by ui_interact * Update modular_skyrat/modules/delam_emergency_stop/code/scram.dm Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com> * Update modular_skyrat/modules/delam_emergency_stop/code/scram.dm --------- Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com> Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> * Automatic changelog for PR #23483 [ci skip] * Automatic changelog compile [ci skip] * [non modular] disables TG "hold up" for the foreseeable future (#23607) Update gun.dm * Automatic changelog for PR #23607 [ci skip] * [MIRROR] Desouls Hivelord [MDB IGNORE] (#23609) * Desouls Hivelord (#78213) ## About The Pull Request  Replaces the sprite of the hivelord with a new one, in my continuing quest to annihilate the old asteroid mob sprites. A (never completed) asteroid mob resprite was actually my first PR, this one is my 200th. I am also planning on fucking with basic mob versions of these mobs some time but the sprites can be atomised out. In addition to replacing the old-ass MSPaint sprites, this PR also adds a short death animation effect to the hivelord brood (from hivelords or legions) which looks nicer than them just vanishing instantly upon death. Look at this video for an example of the animation: https://www.youtube.com/watch?v=cKaskN5-y2A ## Why It's Good For The Game Looks nicer. ## Changelog 🆑 image: Hivelords have a new sprite. image: Hivelord and Legion brood have a death animation. /🆑 * Desouls Hivelord --------- Co-authored-by: Jacquerel <hnevard@gmail.com> * Automatic changelog for PR #23609 [ci skip] * [MIRROR] Updates chem factory tank sprites [MDB IGNORE] (#23608) * Updates chem factory tank sprites (#78209) Updates chem factory tank sprites. * Updates chem factory tank sprites --------- Co-authored-by: Wallem <66052067+Wallemations@users.noreply.github.com> * [MIRROR] Rice Dough can be made in a beaker [MDB IGNORE] (#23611) * Rice Dough can be made in a beaker (#78062) ## About The Pull Request Rice dough can be made in a beaker using 20u of Rice Flour and 10u of Water. 10u of Rice Flour is made from 5u of Rice and 5u of Flour. Rice dough can still be crafted manually using the crafting menu and the original recipe. ## Why It's Good For The Game Cooks can sometimes get swamped with work, especially on a high-pop shift or when there are no botanists. By making rice dough more convenient to make, cooks don't need to spend as much time in the crafting menu. Rice Flour is made from mixing equal parts Rice and Flour. Since no recipe other than Rice dough uses both Rice and Flour in it's Recipe, it should be fine to turn those regents into the intermediate reagent "Rice Flour". Fixes #77966 ## Changelog 🆑 qol: Rice Dough may be made in beaker instead of being crafted, but the rice and flour must be added first /🆑 * Rice Dough can be made in a beaker --------- Co-authored-by: blueDev2 <89804215+blueDev2@users.noreply.github.com> * Automatic changelog for PR #23608 [ci skip] * Automatic changelog for PR #23611 [ci skip] * f * awda * unused type!!! * Apply suggestions from code review Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> * oh hey unused defines! bye --------- Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com> Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com> Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: Changelogs <action@github.com> Co-authored-by: RatFromTheJungle <62520989+RatFromTheJungle@users.noreply.github.com> Co-authored-by: Jacquerel <hnevard@gmail.com> Co-authored-by: Wallem <66052067+Wallemations@users.noreply.github.com> Co-authored-by: blueDev2 <89804215+blueDev2@users.noreply.github.com> --------- Co-authored-by: nikothedude <59709059+nikothedude@users.noreply.github.com> Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com> Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com> Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> Co-authored-by: Changelogs <action@github.com> Co-authored-by: RatFromTheJungle <62520989+RatFromTheJungle@users.noreply.github.com> Co-authored-by: Jacquerel <hnevard@gmail.com> Co-authored-by: Wallem <66052067+Wallemations@users.noreply.github.com> Co-authored-by: blueDev2 <89804215+blueDev2@users.noreply.github.com>
92 lines
6.6 KiB
Plaintext
92 lines
6.6 KiB
Plaintext
/// This test is used to make sure a flesh-and-bone base human can suffer all the types of wounds, and that suffering more severe wounds removes and replaces the lesser wound. Also tests that [/mob/living/carbon/proc/fully_heal] removes all wounds
|
|
/datum/unit_test/test_human_base/Run()
|
|
var/mob/living/carbon/human/victim = allocate(/mob/living/carbon/human/consistent)
|
|
|
|
/// the limbs have no wound resistance like the chest and head do, so let's go with the r_arm
|
|
var/obj/item/bodypart/tested_part = victim.get_bodypart(BODY_ZONE_R_ARM)
|
|
/// In order of the wound types we're trying to inflict, what sharpness do we need to deal them?
|
|
var/list/sharps = list(NONE, SHARP_EDGED, SHARP_POINTY, NONE)
|
|
/// Since burn wounds need burn damage, duh
|
|
var/list/dam_types = list(BRUTE, BRUTE, BRUTE, BURN)
|
|
|
|
var/i = 1
|
|
var/list/iter_test_wound_list
|
|
|
|
for(iter_test_wound_list in list(list(/datum/wound/blunt/bone/moderate, /datum/wound/blunt/bone/severe, /datum/wound/blunt/bone/critical),\
|
|
list(/datum/wound/slash/flesh/moderate, /datum/wound/slash/flesh/severe, /datum/wound/slash/flesh/critical),\
|
|
list(/datum/wound/pierce/bleed/moderate, /datum/wound/pierce/bleed/severe, /datum/wound/pierce/bleed/critical),\
|
|
list(/datum/wound/burn/flesh/moderate, /datum/wound/burn/flesh/severe, /datum/wound/burn/flesh/critical)))
|
|
|
|
TEST_ASSERT_EQUAL(length(victim.all_wounds), 0, "Patient is somehow wounded before test")
|
|
var/datum/wound/iter_test_wound
|
|
var/datum/wound_pregen_data/iter_pregen_data = GLOB.all_wound_pregen_data[iter_test_wound]
|
|
var/threshold_penalty = 0
|
|
|
|
for(iter_test_wound in iter_test_wound_list)
|
|
var/threshold = iter_pregen_data.threshold_minimum - threshold_penalty // just enough to guarantee the next tier of wound, given the existing wound threshold penalty
|
|
if(dam_types[i] == BRUTE)
|
|
tested_part.receive_damage(WOUND_MINIMUM_DAMAGE, 0, wound_bonus = threshold, sharpness=sharps[i])
|
|
else if(dam_types[i] == BURN)
|
|
tested_part.receive_damage(0, WOUND_MINIMUM_DAMAGE, wound_bonus = threshold, sharpness=sharps[i])
|
|
|
|
TEST_ASSERT(length(victim.all_wounds), "Patient has no wounds when one wound is expected. Severity: [initial(iter_test_wound.severity)]")
|
|
TEST_ASSERT_EQUAL(length(victim.all_wounds), 1, "Patient has more than one wound when only one is expected. Severity: [initial(iter_test_wound.severity)]")
|
|
var/datum/wound/actual_wound = victim.all_wounds[1]
|
|
TEST_ASSERT_EQUAL(actual_wound.type, iter_test_wound, "Patient has wound of incorrect severity. Expected: [initial(iter_test_wound.name)] Got: [actual_wound]")
|
|
threshold_penalty = actual_wound.threshold_penalty
|
|
i++
|
|
victim.fully_heal(ADMIN_HEAL_ALL) // should clear all wounds between types
|
|
|
|
|
|
/// This test is used for making sure species with bones but no flesh (skeletons, plasmamen) can only suffer BONE_WOUNDS, and nothing tagged with FLESH_WOUND (it's possible to require both)
|
|
/datum/unit_test/test_human_bone/Run()
|
|
var/mob/living/carbon/human/victim = allocate(/mob/living/carbon/human/consistent)
|
|
|
|
/// the limbs have no wound resistance like the chest and head do, so let's go with the r_arm
|
|
var/obj/item/bodypart/tested_part = victim.get_bodypart(BODY_ZONE_R_ARM)
|
|
/// In order of the wound types we're trying to inflict, what sharpness do we need to deal them?
|
|
var/list/sharps = list(NONE, SHARP_EDGED, SHARP_POINTY, NONE)
|
|
/// Since burn wounds need burn damage, duh
|
|
var/list/dam_types = list(BRUTE, BRUTE, BRUTE, BURN)
|
|
|
|
var/i = 1
|
|
var/list/iter_test_wound_list
|
|
tested_part.biological_state &= ~BIO_FLESH // take away the base limb's flesh (ouchie!) ((not actually ouchie, this just affects their wounds and dismemberment handling))
|
|
|
|
for(iter_test_wound_list in list(list(/datum/wound/blunt/bone/moderate, /datum/wound/blunt/bone/severe, /datum/wound/blunt/bone/critical),\
|
|
list(/datum/wound/slash/flesh/moderate, /datum/wound/slash/flesh/severe, /datum/wound/slash/flesh/critical),\
|
|
list(/datum/wound/pierce/bleed/moderate, /datum/wound/pierce/bleed/severe, /datum/wound/pierce/bleed/critical),\
|
|
list(/datum/wound/burn/flesh/moderate, /datum/wound/burn/flesh/severe, /datum/wound/burn/flesh/critical)))
|
|
|
|
TEST_ASSERT_EQUAL(length(victim.all_wounds), 0, "Patient is somehow wounded before test")
|
|
var/datum/wound/iter_test_wound
|
|
var/datum/wound_pregen_data/iter_pregen_data = GLOB.all_wound_pregen_data[iter_test_wound]
|
|
var/threshold_penalty = 0
|
|
|
|
for(iter_test_wound in iter_test_wound_list)
|
|
var/threshold = iter_pregen_data.threshold_minimum - threshold_penalty // just enough to guarantee the next tier of wound, given the existing wound threshold penalty
|
|
if(dam_types[i] == BRUTE)
|
|
tested_part.receive_damage(WOUND_MINIMUM_DAMAGE, 0, wound_bonus = threshold, sharpness=sharps[i])
|
|
else if(dam_types[i] == BURN)
|
|
tested_part.receive_damage(0, WOUND_MINIMUM_DAMAGE, wound_bonus = threshold, sharpness=sharps[i])
|
|
|
|
// so if we just tried to deal a flesh wound, make sure we didn't actually suffer it. We may have suffered a bone wound instead, but we just want to make sure we don't have a flesh wound
|
|
var/datum/wound_pregen_data/pregen_data = GLOB.all_wound_pregen_data[iter_test_wound]
|
|
if (pregen_data.required_limb_biostate & BIO_FLESH)
|
|
if(!length(victim.all_wounds)) // not having a wound is good news
|
|
continue
|
|
else // we have to check that it's actually a bone wound and not the intended wound type
|
|
TEST_ASSERT_EQUAL(length(victim.all_wounds), 1, "Patient has more than one wound when only one is expected. Severity: [initial(iter_test_wound.severity)]")
|
|
var/datum/wound/actual_wound = victim.all_wounds[1]
|
|
var/datum/wound_pregen_data/actual_pregen_data = GLOB.all_wound_pregen_data[actual_wound.type]
|
|
TEST_ASSERT((actual_pregen_data.required_limb_biostate & ~BIO_FLESH), "Limb has flesh wound despite no BIO_FLESH biological_state, expected either no wound or bone wound. Offending wound: [actual_wound]")
|
|
threshold_penalty = actual_wound.threshold_penalty
|
|
else // otherwise if it's a bone wound, check that we have it per usual
|
|
TEST_ASSERT(length(victim.all_wounds), "Patient has no wounds when one wound is expected. Severity: [initial(iter_test_wound.severity)]")
|
|
TEST_ASSERT_EQUAL(length(victim.all_wounds), 1, "Patient has more than one wound when only one is expected. Severity: [initial(iter_test_wound.severity)]")
|
|
var/datum/wound/actual_wound = victim.all_wounds[1]
|
|
TEST_ASSERT_EQUAL(actual_wound.type, iter_test_wound, "Patient has wound of incorrect severity. Expected: [initial(iter_test_wound.name)] Got: [actual_wound]")
|
|
threshold_penalty = actual_wound.threshold_penalty
|
|
i++
|
|
victim.fully_heal(ADMIN_HEAL_ALL) // should clear all wounds between types
|