diff --git a/code/__DEFINES/genetics.dm b/code/__DEFINES/genetics.dm index 93cdcf133f..c9f08cdfd4 100644 --- a/code/__DEFINES/genetics.dm +++ b/code/__DEFINES/genetics.dm @@ -57,7 +57,7 @@ //DNA - Because fuck you and your magic numbers being all over the codebase. #define DNA_BLOCK_SIZE 3 -#define DNA_UNI_IDENTITY_BLOCKS 7 +#define DNA_UNI_IDENTITY_BLOCKS 18 #define DNA_HAIR_COLOR_BLOCK 1 #define DNA_FACIAL_HAIR_COLOR_BLOCK 2 #define DNA_SKIN_TONE_BLOCK 3 @@ -65,6 +65,17 @@ #define DNA_GENDER_BLOCK 5 #define DNA_FACIAL_HAIR_STYLE_BLOCK 6 #define DNA_HAIR_STYLE_BLOCK 7 +#define DNA_COLOR_ONE_BLOCK 8 +#define DNA_COLOR_TWO_BLOCK 9 +#define DNA_COLOR_THR_BLOCK 10 +#define DNA_COLOR_SWITCH_BLOCK 11 +#define DNA_COLOR_SWITCH_MAX 7 //must be (2^(n+1))-1 +#define DNA_COCK_BLOCK 12 +#define DNA_MUTANTRACE_BLOCK 13 +#define DNA_MUTANTTAIL_BLOCK 14 +#define DNA_MUTANTWING_BLOCK 15 +#define DNA_WINGCOLOR_BLOCK 16 +#define DNA_TAUR_BLOCK 17 #define DNA_STRUC_ENZYMES_BLOCKS 19 #define DNA_UNIQUE_ENZYMES_LEN 32 diff --git a/code/datums/dna.dm b/code/datums/dna.dm index 33e8cd5bd2..a7c412c348 100644 --- a/code/datums/dna.dm +++ b/code/datums/dna.dm @@ -76,6 +76,51 @@ L[DNA_FACIAL_HAIR_COLOR_BLOCK] = sanitize_hexcolor(H.facial_hair_color) L[DNA_SKIN_TONE_BLOCK] = construct_block(skin_tones.Find(H.skin_tone), skin_tones.len) L[DNA_EYE_COLOR_BLOCK] = sanitize_hexcolor(H.eye_color) + if(H.heterochromia) + L[DNA_EYE_COLOR_TWO_BLOCK] = sanitize_hexcolor(H.heterochromia) + L[DNA_EYE_COLOR_SWITCH_BLOCK] = construct_block(2,2) + else + L[DNA_EYE_COLOR_TWO_BLOCK] = sanitize_hexcolor(H.eye_color) + L[DNA_EYE_COLOR_SWITCH_BLOCK] = construct_block(1,2) + var/colour_switch=0 + if(special_color[1]) + L[DNA_COLOR_ONE_BLOCK] = sanitize_hexcolor(special_color[1]) + colour_switch+=1 + else + L[DNA_COLOR_ONE_BLOCK] = random_string(DNA_BLOCK_SIZE,hex_characters) + if(special_color[2]) + L[DNA_COLOR_TWO_BLOCK] = sanitize_hexcolor(special_color[2]) + colour_switch+=2 + else + L[DNA_COLOR_TWO_BLOCK] = random_string(DNA_BLOCK_SIZE,hex_characters) + if(special_color[3]) + L[DNA_COLOR_THR_BLOCK] = sanitize_hexcolor(special_color[3]) + colour_switch+=4 + else + L[DNA_COLOR_THR_BLOCK] = random_string(DNA_BLOCK_SIZE,hex_characters) + L[DNA_COLOR_SWITCH_BLOCK] = construct_block(colour_switch+1,DNA_COLOR_SWITCH_MAX+1) + /*if(species_list[mutantrace]) + L[DNA_MUTANTRACE_BLOCK] = construct_block(species_list.Find(mutantrace), species_list.len+1) + else + L[DNA_MUTANTRACE_BLOCK] = construct_block(species_list.len+1, species_list.len+1)*/ + L[DNA_MUTANTRACE_BLOCK] = generate_race_block() + if(mutant_tails.Find(mutanttail)) + L[DNA_MUTANTTAIL_BLOCK] = construct_block(mutant_tails.Find(mutanttail), mutant_tails.len+1) + else + L[DNA_MUTANTTAIL_BLOCK] = construct_block(mutant_tails.len+1, mutant_tails.len+1) + if(mutant_wings.Find(mutantwing)) + L[DNA_MUTANTWING_BLOCK] = construct_block(mutant_wings.Find(mutantwing), mutant_wings.len+1) + else + L[DNA_MUTANTWING_BLOCK] = construct_block(mutant_wings.len+1, mutant_wings.len+1) + L[DNA_WINGCOLOR_BLOCK] = sanitize_hexcolor(wingcolor) + L[DNA_TAUR_BLOCK] = construct_block(taur+1, 2) + + var/cock_block=0 + if(cock["has"]) + cock_block+=1 + if(vagina) + cock_block+=2 + L[DNA_COCK_BLOCK] = construct_block(cock_block+1, 4) for(var/i=1, i<=DNA_UNI_IDENTITY_BLOCKS, i++) if(L[i]) @@ -249,6 +294,49 @@ mob/living/carbon/human/updateappearance(icon_update=1, mutcolor_update=0, mutat eye_color = sanitize_hexcolor(getblock(structure, DNA_EYE_COLOR_BLOCK)) facial_hair_style = facial_hair_styles_list[deconstruct_block(getblock(structure, DNA_FACIAL_HAIR_STYLE_BLOCK), facial_hair_styles_list.len)] hair_style = hair_styles_list[deconstruct_block(getblock(structure, DNA_HAIR_STYLE_BLOCK), hair_styles_list.len)] + var/mutantrace_c = deconstruct_block(getblock(structure, DNA_MUTANTRACE_BLOCK), species_list.len+1) + if(mutantrace_c<=species_list.len && kpcode_race_restricted(species_list[mutantrace_c])!=2) + dna.species=kpcode_race_get(species_list[mutantrace_c]) + var/mutanttail_c = deconstruct_block(getblock(structure, DNA_MUTANTTAIL_BLOCK), mutant_tails.len+1) + if(mutanttail_c<=mutant_tails.len) + dna.mutanttail=mutant_tails[mutanttail_c] + else + dna.mutanttail=null + var/mutantwing_c = deconstruct_block(getblock(structure, DNA_MUTANTWING_BLOCK), mutant_wings.len+1) + if(mutantwing_c<=mutant_wings.len) + dna.mutantwing=mutant_wings[mutantwing_c] + else + dna.mutantwing=null + + dna.wingcolor = sanitize_hexcolor(getblock(structure, DNA_WINGCOLOR_BLOCK)) + var/colour_switch=deconstruct_block(getblock(structure, DNA_COLOR_SWITCH_BLOCK), DNA_COLOR_SWITCH_MAX+1) + colour_switch-=1 + if(colour_switch&1) + dna.special_color[1]=sanitize_hexcolor(getblock(structure, DNA_COLOR_ONE_BLOCK)) + else + dna.special_color[1]=null + if(colour_switch&2) + dna.special_color[2]=sanitize_hexcolor(getblock(structure, DNA_COLOR_TWO_BLOCK)) + else + dna.special_color[2]=null + if(colour_switch&4) + dna.special_color[3]=sanitize_hexcolor(getblock(structure, DNA_COLOR_THR_BLOCK)) + else + dna.special_color[3]=null + + var/cock_block=deconstruct_block(getblock(structure, DNA_COCK_BLOCK), 4) + cock_block-=1 + if(!(cock_block&1)) + dna.cock["has"]=0 + else if(!dna.cock["has"]&&(cock_block&1)) + dna.cock["has"]=1 + + if(cock_block&2) + dna.vagina=1 + else + dna.vagina=0 + + dna.taur=deconstruct_block(getblock(structure, DNA_TAUR_BLOCK), 2)-1 if(icon_update) update_body() update_hair() diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index da703aeff5..15fca32e5d 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -41,6 +41,31 @@ var/list/preferences_datums = list() var/allow_midround_antag = 1 var/preferred_map = null + //vore code + var/mutant_tail = "none" + var/mutant_wing = "none" + var/wingcolor = "FFF" + var/special_color[COLOUR_LIST_SIZE] + //var/special_color_one = null + //var/special_color_two = null + var/vore_banned_methods = 0 + var/vore_extra_bans = 65535 + var/list/vore_ability = list( + "1"=2, + "2"=0, + "4"=0, + "8"=0, + "16"=0, + "32"=0, + "64"=1, + "128"=0, + "256"=2) //BAAAAD way to do this + var/character_size="normal" + var/be_taur=0 + + var/list/p_cock=list("has"=0,"type"="human","color"="900","sheath"="FFF") + var/p_vagina=0 + //character preferences var/real_name //our character's name var/be_random_name = 0 //whether we'll have a random name every round @@ -184,14 +209,43 @@ var/list/preferences_datums = list() dat += "
| "
if(config.mutant_races)
- dat += "Species: [pref_species.name] " + dat += "Species: [pref_species.id] " + dat += "Human Tail:[mutant_tail] " + dat += "Taur:[be_taur ? "Yes" : "No"]" + if(!kpcode_cantaur(pref_species.id)) + dat += " (not available for [pref_species.id])" + dat += " " + if(special_color[1]) + dat += " Primary " + else + dat += "Primary? " + if(special_color[2]) + dat += " Secondary " + else + dat += "Secondary? " + if(special_color[3]) + dat += " Tertiary " + else + dat += "Tertiary? " else dat += "Species: Human " - dat += "Underwear: [underwear] " - dat += "Undershirt: [undershirt] " - dat += "Socks: [socks] " - dat += "Backpack: [backbag] | "
+ dat += "Size: [character_size]