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

Nabbers & Backend #8913

Open
wants to merge 20 commits into
base: master
Choose a base branch
from
Open

Conversation

Mechoid
Copy link
Contributor

@Mechoid Mechoid commented Jan 31, 2023

Adds Serpentids and Serpentid Monarchs as event species & subspecies, similar to old vox. "Whitelisted" as character setup for events (and maybe raiders?) is easier with the menu than the edit-character menu in game.

Backend: Icon generation for clothing is now updated to allow larger species that use offsets to determine where base 'human' clothing icons will go if allowed. Example: Nabbers use most human headgear pixelshifted up.

Species may have larger icons, and still be centered properly on the tile using offsets from the datum.

Species may have unique armor values inherent to them, applied to their limbs. If a limb is transplanted, it keeps its armor value!

Serpentids:
Large armored invertebrates.

Two sets of arms, swapped by the pull-punches verb. One set is for manipulation of objects, the other hunting and threat displays. Hunting arms

Their respiration requires multiple organs, and their blood contains acetone and phoron to manage it.

When suffering respiratory malfunction (gasping), their body will catalyze Dexalin in an attempt to mitigate it, costing nutrition.

Lore pending continued discussion.

@Mechoid Mechoid added Feature The PR adds new functionality in some way. Lore This change affects the server's lore and setting. labels Jan 31, 2023
var/icon/standing_icon
var/mob/living/carbon/human/H = wearer
if(ishuman(wearer) && H.species.get_offset_overlay_image(iconnodefault, icon2use, state2use, slot = slot_name))
standing_icon = H.species.get_offset_overlay_image(iconnodefault, icon2use, state2use, slot = slot_name)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should cast this before the if so you aren't running the proc and associated cache lookup twice.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if(ishuman(wearer))
	var/mob/living/carbon/human/H = wearer
	standing_icon = H.species.get_offset_overlay_image(iconnodefault, icon2use, state2use, slot = slot_name) || icon(icon = icon2use, icon_state = state2use)
else
	standing_icon = icon(icon = icon2use, icon_state = state2use)

would also work.

One issue noted - standing_icon is an image if returned by get_offset_overlay_image() but an icon otherwise.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your changes are still replicating a redundant typecheck on the human mob.

@Mechoid
Copy link
Contributor Author

Mechoid commented Jan 31, 2023

I.. also can't find the qdel in New()

@@ -7,6 +7,12 @@
siemens_coefficient = 0.9
body_parts_covered = 0

sprite_sheets = list(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You seem to be manually setting this in a lot of places, why is the base type's list not appropriate?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Icons exist for softcaps for Nabbers, but not really anything else. So using human sprites is preferred to defaulting to the grey softcap.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would argue you should make the default a blank icon in that case, to be honest. This is a lot of redundant overrides.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would the point of having the icon-shifting for headgear even be then, if nothing uses it?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The point of the offset system is so that in circumstances where no icon exists, it can offset the base icon. The default icon should not be used in cases where the offset will do the job.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's what this is doing, it's telling the icon generation that there are proper sprites for the species. If it's set on the base head clothing, it uses the greycap for everything that isn't a softcap. It's the same reason (but intended this time) that all suit- or uniform-slot things become the harness.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I apparently never replied to this - the new system only uses an icon state from the sprite file if it exists, it won't apply a default like the old system, the 'default' will be an offset version of the human onmob icon.

@@ -177,6 +177,10 @@ emp_act
return 0
var/protection = 0
var/list/protective_gear = def_zone.get_covering_clothing()

if(def_zone.species.natural_armour_values) // You have a Cool Alien Limb with armor? Congrats, you get that armor!
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should steal this for Nebula instead of doing it for the entire mob.

@@ -44,10 +44,3 @@
robotic = ORGAN_ROBOT

standard_pulse_level = PULSE_NONE

/obj/item/organ/internal/stomach/machine/handle_organ_proc_special()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated removal?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The stomach's proc is duplicated in the heart file for some reason. The proc still exists with the parent in stomach.dm

// Armor will turn attacks into less dangerous (e.g. turning cut into bruise), so keep that in mind when decided what armor value to use.
// Some levels are marked with what they intend to block in such way.

#define ARMOR_BALLISTIC_MINOR 10
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should either not port these, or port them thoroughly. Leaving every other value in the game as a bare number and using these defines just for one armour entry is pretty untidy.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are also tab indented rather than space indented which is very grody in the diff. Nitpick.

Copy link
Contributor Author

@Mechoid Mechoid Feb 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left the other values as I don't believe we have a universal value set we use for armor, and changing every piece of armor to fit the schema in a PR for an event species felt out-of-scope to me, since they probably don't fit neatly

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In that case I would suggest making a separate PR with the armour defines to normalize them, or using bare numbers in the armour set on nabbers/suits.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Armor defines slain

@@ -65,3 +65,10 @@
#define MODULAR_BODYPART_INVALID 0 // Cannot be detached or reattached.
#define MODULAR_BODYPART_PROSTHETIC 1 // Can be detached or reattached freely.
#define MODULAR_BODYPART_CYBERNETIC 2 // Can be detached or reattached to compatible parent organs.

//Blood levels. These are percentages based on the species blood_volume far.
#define BLOOD_VOLUME_FULL 100
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to armour defines, you should use these in the blood volume code more broadly than just nabbers.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Species all have their own blood levels, removed 👍

@Mechoid Mechoid changed the title Nabbers & Backend [DNM] Pending Icon System; Nabbers & Backend Feb 1, 2023
@Mechoid Mechoid changed the title [DNM] Pending Icon System; Nabbers & Backend [Pending #8920] Nabbers & Backend Feb 10, 2023
@Mechoid
Copy link
Contributor Author

Mechoid commented Jul 10, 2023

why

Copy link
Member

@Spookerton Spookerton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You merged the main branch into your feature branch instead of rebasing your feature branch on the head commit of the main branch. You'll need to undo that.

@Spookerton Spookerton added the Stale [PR] This requires additional work and appears abandoned. label Aug 23, 2023
@Spookerton Spookerton marked this pull request as draft August 23, 2023 15:16
@Mechoid Mechoid changed the title [Pending #8920] Nabbers & Backend Nabbers & Backend Sep 4, 2023
@Mechoid Mechoid force-pushed the SerpentidExistence branch 2 times, most recently from c327bde to d5d1d85 Compare September 4, 2023 12:23
@Mechoid Mechoid marked this pull request as ready for review September 4, 2023 12:24
@Spookerton Spookerton removed the Stale [PR] This requires additional work and appears abandoned. label Sep 10, 2023
Adds Nabbers as an event species, similar to old (current? they're not yet joinable to my knowledge) vox. "Whitelisted" as character setup for events (and maybe raiders?) is easier with the menu than the edit-character menu in game.

Backend: Icon generation for humanmobs is now updated to allow larger species that use offsets to determine where base 'human' icons will go if allowed. Example: Nabbers use most human headgear pixelshifted up.

Species may have larger icons, and still be centered properly on the tile.
…verride with tesh and vox in prep for icon system PR.
Monarch Amp crown sprite for base 'headgear'.
Fix Serpentids being able to use non-serpentid prosthetics.
Serpentid voiceboxes are no longer auto-robotic, meaning they cannot speak GalCom without an implant, but can understand it.
Serpentid voiceboxes no longer allow the serpentid to speak human languages by default.
Enables the GalCom implant.
Cannot utilize their wings when wearing something on their back.
Cannot see well in bright light.
No longer wear headsets on their lower shoulder.
Able to wear armor. Literally. They take the whole suit and just wear it like a tabard.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature The PR adds new functionality in some way. Lore This change affects the server's lore and setting.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants