Skip to content

Commit

Permalink
Assorted fixes from staging-sierra
Browse files Browse the repository at this point in the history
  • Loading branch information
UEDCommander committed Mar 24, 2024
1 parent 9a3a26a commit 3b931df
Show file tree
Hide file tree
Showing 15 changed files with 174 additions and 41 deletions.
59 changes: 50 additions & 9 deletions code/modules/mob/living/carbon/human/human.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1576,26 +1576,67 @@
set category = "IC"
species.toggle_stance(src)

// [SIERRA-ADD] - RESOMI
#define PULSE_NUMBER_NONE 0
#define PULSE_NUMBER_SLOW 50
#define PULSE_NUMBER_NORM 75
#define PULSE_NUMBER_FAST 105
#define PULSE_NUMBER_2FAST 140
#define PULSE_NUMBER_THREADY PULSE_MAX_BPM
// [/SIERRA-ADD]

// Similar to get_pulse, but returns only integer numbers instead of text.
/mob/living/carbon/human/proc/get_pulse_as_number() // IMPORTANT TO KNOW THIS PROC IS FULLY OVERRIDED IN RESOMI MODULE.
/mob/living/carbon/human/proc/get_pulse_as_number()
var/obj/item/organ/internal/heart/heart_organ = internal_organs_by_name[BP_HEART]

// [SIERRA-EDIT] - RESOMI

//if(!heart_organ) // SIERRA-EDIT - ORIGINAL
// return 0 // SIERRA-EDIT - ORIGINAL
//switch(pulse()) // SIERRA-EDIT - ORIGINAL
// if(PULSE_NONE) // SIERRA-EDIT - ORIGINAL
// return 0 // SIERRA-EDIT - ORIGINAL
// if(PULSE_SLOW) // SIERRA-EDIT - ORIGINAL
// return rand(40, 60) // SIERRA-EDIT - ORIGINAL
// if(PULSE_NORM) // SIERRA-EDIT - ORIGINAL
// return rand(60, 90) // SIERRA-EDIT - ORIGINAL
// if(PULSE_FAST) // SIERRA-EDIT - ORIGINAL
// return rand(90, 120) // SIERRA-EDIT - ORIGINAL
// if(PULSE_2FAST) // SIERRA-EDIT - ORIGINAL
// return rand(120, 160) // SIERRA-EDIT - ORIGINAL
// if(PULSE_THREADY) // SIERRA-EDIT - ORIGINAL
// return PULSE_MAX_BPM // SIERRA-EDIT - ORIGINAL
//return 0 // SIERRA-EDIT - ORIGINAL

if(!heart_organ)
return 0
return PULSE_NUMBER_NONE

var/raw_pulse_number
switch(pulse())
if(PULSE_NONE)
return 0
return PULSE_NUMBER_NONE
if(PULSE_SLOW)
return rand(40, 60)
raw_pulse_number = PULSE_NUMBER_SLOW
if(PULSE_NORM)
return rand(60, 90)
raw_pulse_number = PULSE_NUMBER_NORM
if(PULSE_FAST)
return rand(90, 120)
raw_pulse_number = PULSE_NUMBER_FAST
if(PULSE_2FAST)
return rand(120, 160)
raw_pulse_number = PULSE_NUMBER_2FAST
if(PULSE_THREADY)
return PULSE_MAX_BPM
return 0
return PULSE_NUMBER_THREADY
return ((raw_pulse_number * (2 - species.blood_volume / SPECIES_BLOOD_DEFAULT)) + (raw_pulse_number * rand(-0.2, 0.2)))

// [/SIERRA-EDIT]

// [SIERRA-ADD] - RESOMI
#undef PULSE_NUMBER_NONE
#undef PULSE_NUMBER_SLOW
#undef PULSE_NUMBER_NORM
#undef PULSE_NUMBER_FAST
#undef PULSE_NUMBER_2FAST
#undef PULSE_NUMBER_THREADY
// [/SIERRA-ADD]

//generates realistic-ish pulse output based on preset levels as text
/mob/living/carbon/human/proc/get_pulse(method) //method 0 is for hands, 1 is for machines, more accurate
Expand Down
45 changes: 38 additions & 7 deletions mods/resomi/README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@

#### Список PRов:

- `Отсутствуют`
- https://github.com/SierraBay/SierraBay12/pull/2047
<!--
Ссылки на PRы, связанные с модом:
- Создание
- Большие изменения
-->

<!-- Название мода. Не важно на русском или на английском. -->
## Мод-пример
## Резоми

ID мода: RESOMI
<!--
Expand All @@ -19,15 +19,22 @@ ID мода: RESOMI

### Описание мода

Резоми
Ря!
- Портирует расу резоми с Infinity.
<!--
Что он делает, что добавляет: что, куда, зачем и почему - всё здесь.
А также любая полезная информация.
-->

### Изменения *кор кода*

- `Отсутствуют`
- `code/modules/client/preference_setup/loadout/lists/misc.dm`
- `/datum/gear/plush_toy/New()`
- `code/modules/organs/external/_external_icons.dm`
- `/obj/item/organ/external/on_update_icon()`
- `mods/resomi/code/overrides.dm`
- `/mob/living/carbon/human/get_pulse_as_number()`

<!--
Если вы редактировали какие-либо процедуры или переменные в кор коде,
они должны быть указаны здесь.
Expand All @@ -49,7 +56,29 @@ ID мода: RESOMI

### Дефайны

- `Отсутствуют`
- `code/__defines/~mods/~master_defines.dm`:
- `SPECIES_RESOMI`
- `LANGUAGE_RESOMI`
- `mods/resomi/code/datum/_defines.dm`:
- `CULTURE_RESOMI_EREMUS`
- `CULTURE_RESOMI_ASRANDA`
- `CULTURE_RESOMI_REFUGEE`
- `CULTURE_RESOMI_NEWGENERATION`
- `CULTURE_RESOMI_LOSTCOLONYRICH`
- `CULTURE_RESOMI_LOSTCOLONYPOOR`
- `HOME_SYSTEM_RESOMI_BIRDCAGE`
- `HOME_SYSTEM_RESOMI_EREMUS`
- `HOME_SYSTEM_RESOMI_ASRANDA`
- `HOME_SYSTEM_RESOMI_SAVEEL`
- `HOME_SYSTEM_RESOMI_LOST_COLONY`
- `HOME_SYSTEM_RESOMI_REFUGEE_COLONY`
- `HOME_SYSTEM_RESOMI_HOMELESS`
- `HOME_SYSTEM_RESOMI_IMPER_COLONY`
- `HOME_SYSTEM_RESOMI_RESOBALAK`
- `RELIGION_RESOMI_CHOSEN`
- `RELIGION_RESOMI_EMPEROR`
- `RELIGION_RESOMI_MOUNTAIN`
- `RELIGION_RESOMI_SKIES`
<!--
Если требовалось добавить какие-либо дефайны, укажи файлы,
в которые ты их добавил, а также перечисли имена.
Expand All @@ -70,8 +99,10 @@ ID мода: RESOMI

### Авторы:

LordNest (Code)
SurEugene (Code)
LordNest
SurEugene
Daeberdir
UEDHighCommand
<!--
Здесь находится твой никнейм
Если работал совместно - никнеймы тех, кто помогал.
Expand Down
2 changes: 1 addition & 1 deletion mods/resomi/_resomi.dme
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
#define MODPACK_RESOMI

#include "_resomi.dm"
#include "code/overrides.dm"
#include "code/unit_tests.dm"
#include "code/body/abilities.dm"
#include "code/body/emotes.dm"
#include "code/body/organs.dm"
#include "code/clothing/void/rigs.dm"
#include "code/clothing/clothing.dm"
#include "code/clothing/glasses.dm"
#include "code/clothing/misc.dm"
Expand Down
5 changes: 2 additions & 3 deletions mods/resomi/code/body/organs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,5 @@
parent_organ = BP_CHEST

/obj/item/organ/internal/eyes/resomi
icon = 'packs/infinity/icons/mob/human_races/species/resomi/eyes.dmi'
eye_icon = 'packs/infinity/icons/mob/human_races/species/resomi/eyes.dmi'
icon_state = "eyes_resomi"
icon = 'mods/resomi/icons/human_races/eyes.dmi'
eye_icon = 'mods/resomi/icons/human_races/eyes.dmi'
23 changes: 23 additions & 0 deletions mods/resomi/code/clothing/void/rigs.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
/obj/item/clothing/head/helmet/space/rig/industrial/New()
. = ..()
species_restricted |= list(SPECIES_RESOMI)
sprite_sheets[SPECIES_RESOMI] = 'mods/resomi/icons/clothing/onmob_head_resomi.dmi'

/obj/item/clothing/suit/space/rig/industrial/New()
. = ..()
species_restricted |= list(SPECIES_RESOMI)
sprite_sheets[SPECIES_RESOMI] = 'mods/resomi/icons/clothing/onmob_suit_resomi.dmi'

/obj/item/clothing/shoes/magboots/rig/industrial/New()
. = ..()
species_restricted |= list(SPECIES_RESOMI)
sprite_sheets[SPECIES_RESOMI] = 'mods/resomi/icons/clothing/onmob_feet_resomi.dmi'

/obj/item/clothing/gloves/rig/industrial/New()
. = ..()
species_restricted |= list(SPECIES_RESOMI)
sprite_sheets[SPECIES_RESOMI] = 'mods/resomi/icons/clothing/onmob_hands_resomi.dmi'

/obj/item/rig/industrial/New()
. = ..()
sprite_sheets[SPECIES_RESOMI] = 'mods/resomi/icons/clothing/onmob_rig_back_resomi.dmi'
1 change: 1 addition & 0 deletions mods/resomi/code/datum/_defines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#define HOME_SYSTEM_RESOMI_REFUGEE_COLONY "Unknown Independent Refugee Colony"
#define HOME_SYSTEM_RESOMI_HOMELESS "None"
#define HOME_SYSTEM_RESOMI_IMPER_COLONY "Unknown Imperial colony"
#define HOME_SYSTEM_RESOMI_RESOBALAK "Skrellian Empire"

#define RELIGION_RESOMI_CHOSEN "Faith of the Chosen"
#define RELIGION_RESOMI_EMPEROR "Cult of the Emperor"
Expand Down
1 change: 1 addition & 0 deletions mods/resomi/code/datum/language.dm
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"ci", "ri", "mi", "si", "ni", "ti", "li", "shi", "schi", "i", "i"
)
shorthand = "SCH"
has_written_form = TRUE


/datum/language/resomi/get_random_name(gender)
Expand Down
Loading

0 comments on commit 3b931df

Please sign in to comment.