diff --git a/code/defines/mob/mob.dm b/code/defines/mob/mob.dm index 828db621342..d498b149e23 100644 --- a/code/defines/mob/mob.dm +++ b/code/defines/mob/mob.dm @@ -174,6 +174,7 @@ var/radiation = 0.0//Carbon var/mutations = 0//Carbon + var/mutations2 = 0//Carbon //telekinesis = 1 //firemut = 2 //xray = 4 @@ -251,6 +252,8 @@ the mob is also allowed to move without any sort of restriction. For instance, i var/list/atom/hallucinations = list() var/halloss = 0 var/hallucination = 0 +//Singularity wants you! + var/grav_delay = 0 /mob/proc/contract_disease(var/datum/disease/virus, var/skip_this = 0, var/force_species_check=1) // world << "Contract_disease called by [src] with virus [virus]" diff --git a/code/game/atom_procs.dm b/code/game/atom_procs.dm index 411a5e19c22..99498f7e924 100644 --- a/code/game/atom_procs.dm +++ b/code/game/atom_procs.dm @@ -85,7 +85,7 @@ return if (ishuman(M)) add_fibers(M) - if (M.mutations & mFingerprints) + if (M.mutations2 & mFingerprints) if(src.fingerprintslast != M.key) src.fingerprintshidden += "(Has no fingerprints) Real name: [M.real_name], Key: [M.key]" src.fingerprintslast = M.key diff --git a/code/game/dna.dm b/code/game/dna.dm index 38a15fbf1d7..771c1d1409f 100644 --- a/code/game/dna.dm +++ b/code/game/dna.dm @@ -9,10 +9,74 @@ var/original_name = "Unknown" var/b_type = "A+" -/datum/dna/proc/check_integrity() - //Lazy. - if(length(uni_identity) != 39) uni_identity = "00600200A00E0110148FC01300B0095BD7FD3F4" - if(length(struc_enzymes)!= 81) struc_enzymes = "43359156756131E13763334D1C369012032164D4FE4CD61544B6C03F251B6C60A42821D26BA3B02D6" +/datum/dna/proc/check_integrity(var/mob/living/carbon/human/character) + if(character) + if(length(uni_identity) != 39) + //Lazy. + var/temp + var/hair + var/beard + + // determine DNA fragment from hairstyle + // :wtc: + + var/list/styles = typesof(/datum/sprite_accessory/hair) - /datum/sprite_accessory/hair + var/hrange = round(4095 / styles.len) + + var/style = styles.Find(character.hair_style.type) + if(style) + hair = style * hrange - rand(1,hrange-1) + else + hair = 0 + + // Beard dna code - mostly copypasted from hair code to allow for more dynamic facial hair style additions + var/list/face_styles = typesof(/datum/sprite_accessory/facial_hair) - /datum/sprite_accessory/facial_hair + var/f_hrange = round(4095 / face_styles.len) + + var/f_style = face_styles.Find(character.facial_hair_style.type) + if(f_style) + beard = f_style * f_hrange - rand(1,f_hrange-1) + else + beard = 0 + + temp = add_zero2(num2hex((character.r_hair),1), 3) + temp += add_zero2(num2hex((character.b_hair),1), 3) + temp += add_zero2(num2hex((character.g_hair),1), 3) + temp += add_zero2(num2hex((character.r_facial),1), 3) + temp += add_zero2(num2hex((character.b_facial),1), 3) + temp += add_zero2(num2hex((character.g_facial),1), 3) + temp += add_zero2(num2hex(((character.s_tone + 220) * 16),1), 3) + temp += add_zero2(num2hex((character.r_eyes),1), 3) + temp += add_zero2(num2hex((character.g_eyes),1), 3) + temp += add_zero2(num2hex((character.b_eyes),1), 3) + + var/gender + + if (character.gender == MALE) + gender = add_zero2(num2hex((rand(1,(2050+BLOCKADD))),1), 3) + else + gender = add_zero2(num2hex((rand((2051+BLOCKADD),4094)),1), 3) + + temp += gender + temp += add_zero2(num2hex((beard),1), 3) + temp += add_zero2(num2hex((hair),1), 3) + + uni_identity = temp + if(length(struc_enzymes)!= 81) + var/mutstring = "" + for(var/i = 1, i <= 26, i++) + mutstring += add_zero2(num2hex(rand(1,1024)),3) + + struc_enzymes = mutstring + if(length(unique_enzymes) != 32) + unique_enzymes = md5(character.real_name) + if(original_name == "Unknown") + original_name = character.real_name + else + if(length(uni_identity) != 39) uni_identity = "00600200A00E0110148FC01300B0095BD7FD3F4" + if(length(struc_enzymes)!= 81) struc_enzymes = "43359156756131E13763334D1C369012032164D4FE4CD61544B6C03F251B6C60A42821D26BA3B02D6" + +// reg_dna[unique_enzymes] = character.real_name /datum/dna/proc/ready_dna(mob/living/carbon/human/character) @@ -291,10 +355,12 @@ mRemotetalk =(1<<13) mMorph =(1<<14) mBlend =(1<<15) - mHallucination =(1<<16) - mFingerprints =(1<<17) - mShock =(1<<18) - mSmallsize =(1<<19) + + mutations2: + mHallucination =(1<<0) + mFingerprints =(1<<1) + mShock =(1<<2) + mSmallsize =(1<<3) */ //disabilities @@ -311,6 +377,7 @@ M.disabilities = 0 M.mutations = 0 + M.mutations2 = 0 M.see_in_dark = 2 M.see_invisible = 0 @@ -345,20 +412,20 @@ M << "\blue You feel alone" if(ismuton(HALLUCINATIONBLOCK,M)) if(prob(50)) - M.mutations |= mHallucination + M.mutations2 |= mHallucination M << "\blue Your mind says 'Hello'" if(ismuton(NOPRINTSBLOCK,M)) if(prob(50)) - M.mutations |= mFingerprints + M.mutations2 |= mFingerprints M << "\blue Your fingers feel numb" if(ismuton(SHOCKIMMUNITYBLOCK,M)) if(prob(50)) - M.mutations |= mShock + M.mutations2 |= mShock M << "\blue You feel strange" if(ismuton(SMALLSIZEBLOCK,M)) if(prob(50)) M << "\blue Your skin feels rubbery" - M.mutations |= mSmallsize + M.mutations2 |= mSmallsize diff --git a/code/game/objects/devices/geneanalyzer.dm b/code/game/objects/devices/geneanalyzer.dm index 467e93586a3..fd63380955d 100644 --- a/code/game/objects/devices/geneanalyzer.dm +++ b/code/game/objects/devices/geneanalyzer.dm @@ -18,9 +18,10 @@ user.show_message(text("\blue \t Deaf: [isblockon(getblock(M.dna.struc_enzymes, DEAFBLOCK,3),DEAFBLOCK) ? "Yes" : "No"]"), 1) user.show_message(text("\blue \t Requires Glasses: [isblockon(getblock(M.dna.struc_enzymes, GLASSESBLOCK,3),GLASSESBLOCK) ? "Yes" : "No"]"), 1) +/* var/unknow = 0 var/list/unknowns = list(HULKBLOCK,TELEBLOCK,FIREBLOCK,XRAYBLOCK,NOBREATHBLOCK,REMOTEVIEWBLOCK,REGENERATEBLOCK,INCREASERUNBLOCK,REMOTETALKBLOCK,MORPHBLOCK,BLENDBLOCK,HALLUCINATIONBLOCK,NOPRINTSBLOCK,SHOCKIMMUNITYBLOCK,SMALLSIZEBLOCK) for(var/unknown in unknowns) if(isblockon(getblock(M.dna.struc_enzymes, unknown,3),unknown)) unknow += 1 - user.show_message(text("\blue \t Unknown Anomalies: [unknow]")) \ No newline at end of file + user.show_message(text("\blue \t Unknown Anomalies: [unknow]"))*/ \ No newline at end of file diff --git a/code/game/objects/tables_racks.dm b/code/game/objects/tables_racks.dm index 945752a3c5d..1e8d879c5eb 100644 --- a/code/game/objects/tables_racks.dm +++ b/code/game/objects/tables_racks.dm @@ -92,13 +92,16 @@ TABLE AND RACK OBJECT INTERATIONS new /obj/item/weapon/table_parts( src.loc ) src.density = 0 del(src) - if (usr.mutations & mSmallsize) +/* if (user.mutations2 & mSmallsize) step(user, get_dir(user, src)) if (user.loc == src.loc) user.layer = TURF_LAYER + user.update_clothing() for(var/mob/M in viewers(user, null)) M.show_message("[user] hides under the table!", 1) //Foreach goto(69) + */ +//Googol never tested this shit. return diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 25542971d90..f2a9d4a073d 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -867,6 +867,7 @@ M.update_body() M.update_face() M.update_clothing() + M.check_dna(M) /client/proc/radioalert() diff --git a/code/modules/mob/living/carbon/alien/humanoid/life.dm b/code/modules/mob/living/carbon/alien/humanoid/life.dm index 6228ec167a0..9d1f29246f5 100644 --- a/code/modules/mob/living/carbon/alien/humanoid/life.dm +++ b/code/modules/mob/living/carbon/alien/humanoid/life.dm @@ -549,7 +549,7 @@ if (src.stat != 2) if (src.machine) if (!( src.machine.check_eye(src) )) - src.reset_view(null) + reset_view(null) else if(!client.adminobs) reset_view(null) diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 65275acb8a9..e58e97d1ae0 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -775,8 +775,8 @@ // lol var/fat = "" - /*if (mutations & FAT) - fat = "fat"*/ + if (mutations & FAT) + fat = "fat" if (mutations & HULK) overlays += image("icon" = 'genetics.dmi', "icon_state" = "hulk[fat][!lying ? "_s" : "_l"]") @@ -879,10 +879,10 @@ var/t1 = w_uniform.color if (!t1) t1 = icon_state - /*if (mutations & FAT) + if (mutations & FAT) overlays += image("icon" = 'uniform_fat.dmi', "icon_state" = "[t1][!lying ? "_s" : "_l"]", "layer" = MOB_LAYER) - else*/ - overlays += image("icon" = 'uniform.dmi', "icon_state" = text("[][]",t1, (!(lying) ? "_s" : "_l")), "layer" = MOB_LAYER) + else + overlays += image("icon" = 'uniform.dmi', "icon_state" = text("[][]",t1, (!(lying) ? "_s" : "_l")), "layer" = MOB_LAYER) if (w_uniform.blood_DNA.len) var/icon/stain_icon = icon('blood.dmi', "uniformblood[!lying ? "" : "2"]") overlays += image("icon" = stain_icon, "layer" = MOB_LAYER) @@ -1289,7 +1289,7 @@ lying_icon = new /icon('human.dmi', "torso_l") var/husk = (mutations & HUSK) - //var/obese = (mutations & FAT) + var/obese = (mutations & FAT) stand_icon.Blend(new /icon('human.dmi', "chest_[g]_s"), ICON_OVERLAY) lying_icon.Blend(new /icon('human.dmi', "chest_[g]_l"), ICON_OVERLAY) @@ -1326,9 +1326,9 @@ stand_icon.Blend(husk_s, ICON_OVERLAY) lying_icon.Blend(husk_l, ICON_OVERLAY) - /*else if(obese) + else if(obese) stand_icon.Blend(new /icon('human.dmi', "fatbody_s"), ICON_OVERLAY) - lying_icon.Blend(new /icon('human.dmi', "fatbody_l"), ICON_OVERLAY)*/ + lying_icon.Blend(new /icon('human.dmi', "fatbody_l"), ICON_OVERLAY) // Skin tone if (s_tone >= 0) @@ -2524,6 +2524,7 @@ It can still be worn/put on as normal. update_body() update_face() update_clothing() + check_dna() for(var/mob/M in view()) M.show_message("[src.name] just morphed!") @@ -2543,35 +2544,43 @@ It can still be worn/put on as normal. if(target.mutations & mRemotetalk) target.show_message("\blue You hear [src.real_name]'s voice: [say]") else - target.show_message("\blue You hear a voice: [say]") + target.show_message("\blue You hear a voice that seems to echo around the room: [say]") + target << "\red This ain't an admin message, this is IC. Act like it. If someone's abusing it, pretending to be us, adminhelp it." usr.show_message("\blue You project your mind into [target.real_name]: [say]") for(var/mob/dead/observer/G in world) G.show_message("Telepathic message from [src] to [target]: [say]") +/mob/living/carbon/human + var/mob/remoteobserve /mob/living/carbon/human/proc/remoteobserve() set name = "Remote View" set category = "Superpower" if(!(src.mutations & mRemote)) - client.eye = client.mob + reset_view(0) + remoteobserve = null src.verbs -= /mob/living/carbon/human/proc/remoteobserve return if(client.eye != client.mob) - client.eye = client.mob + reset_view(0) + remoteobserve = null return var/list/mob/creatures = list() for(var/mob/living/carbon/h in world) creatures += h - client.perspective = EYE_PERSPECTIVE - - var/mob/target = input ("Who do you want to project your mind to ?") as mob in creatures if (target) - client.eye = target + reset_view(target) + remoteobserve = target else - client.eye = client.mob + reset_view(0) + remoteobserve = null + +/mob/living/carbon/human/proc/check_dna() + dna.check_integrity(src) + return \ No newline at end of file diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index 39944cb0f95..52a8cb07aa3 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -130,6 +130,10 @@ var/pr = 50 if(prob(pr)) adjustToxLoss(1) + else + if(!lying) + lying = 1 //Seriously, stay down :x + update_clothing() clamp_values() @@ -154,7 +158,7 @@ handle_disabilities() - if (mutations & mHallucination) + if(mutations2 & mHallucination) hallucination = 100 halloss = 0 @@ -175,13 +179,12 @@ for(var/atom/a in hallucinations) del a - - if(mutations & mSmallsize) - if(!(flags & PASSTABLE)) - flags |= PASSTABLE + if(mutations2 & mSmallsize) + if(!(pass_flags & PASSTABLE)) + pass_flags |= PASSTABLE else - if(flags & PASSTABLE) - flags &= ~PASSTABLE + if(pass_flags & PASSTABLE) + pass_flags &= ~PASSTABLE @@ -209,7 +212,7 @@ src.verbs += /mob/living/carbon/human/proc/remoteobserve else if(!(mutations & mRemote)) - src.verbs += /mob/living/carbon/human/proc/remoteobserve + src.verbs -= /mob/living/carbon/human/proc/remoteobserve if(!(/mob/living/carbon/human/proc/remotesay in src.verbs)) if(mutations & mRemotetalk) @@ -250,8 +253,8 @@ pixel_x = old_x pixel_y = old_y if (disabilities & 16) - if (prob(20))//Instant Chad Ore! - stuttering = max(10, stuttering) + if (prob(40))//Instant Chad Ore! + stuttering = max(5, stuttering) if (brainloss >= 60 && stat != 2) if (prob(7)) @@ -312,6 +315,8 @@ emote("gasp") updatehealth() + //As close as I could find to where to put it + grav_delay = max(grav_delay-3,0) breathe() @@ -1147,9 +1152,10 @@ if (machine) if (!( machine.check_eye(src) )) reset_view(null) - else - if(!client.adminobs) - reset_view(null) + else if(!(mutations & mRemote) && !client.adminobs) + reset_view(null) + if(remoteobserve) + remoteobserve = null return 1 diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 861541ac003..32b88c92135 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -17,7 +17,7 @@ //sort of a legacy burn method for /electrocute, /shock, and the e_chair /mob/living/proc/burn_skin(burn_amount) if(istype(src, /mob/living/carbon/human)) - if(src.mutations & mShock) + if(src.mutations2 & mShock) return 0 //world << "DEBUG: burn_skin(), mutations=[mutations]" if (src.mutations & COLD_RESISTANCE) //fireproof diff --git a/code/modules/mob/mob_movement.dm b/code/modules/mob/mob_movement.dm index bf083644a13..098ca75e562 100644 --- a/code/modules/mob/mob_movement.dm +++ b/code/modules/mob/mob_movement.dm @@ -185,6 +185,7 @@ // move_delay += mob.organStructure.legs.moveWalkDelay move_delay += 5 move_delay += mob.movement_delay() + move_delay += mob.grav_delay //We are now going to move moving = 1 diff --git a/code/modules/power/singularity/singularity.dm b/code/modules/power/singularity/singularity.dm index 50035fd7608..dc23896f9eb 100644 --- a/code/modules/power/singularity/singularity.dm +++ b/code/modules/power/singularity/singularity.dm @@ -2,7 +2,6 @@ var/global/list/uneatable = list( /turf/space, /obj/effect, /obj/effect/overlay, - /obj/effect/decal/cleanable, /obj/effect/rune ) @@ -212,15 +211,19 @@ var/global/list/uneatable = list( consume(X) for(var/atom/movable/X in orange(grav_pull,src)) if(is_type_in_list(X, uneatable)) continue - if(((X) &&(!X:anchored) && (!istype(X,/mob/living/carbon/human)))|| (src.current_size >= 9)) - step_towards(X,src) + if((((X) && (!X:anchored)) || (src.current_size >= 9)) && (!istype(X,/mob/living/carbon/human))) + spawn(rand(0,15)) + step_towards(X,src) else if(istype(X,/mob/living/carbon/human)) var/mob/living/carbon/human/H = X - if(istype(H.shoes,/obj/item/clothing/shoes/magboots)) + H << "\red The singularity has you in it's gravitational pull! It's hard to break free!" + H.grav_delay = 20 //No running this time! + if(istype(H.shoes,/obj/item/clothing/shoes/magboots) && !(src.current_size >= 9)) var/obj/item/clothing/shoes/magboots/M = H.shoes if(M.magpulse) continue - step_towards(H,src) + spawn(rand(0,15)) + step_towards(H,src) if(defer_powernet_rebuild != 2) defer_powernet_rebuild = 0 return @@ -236,7 +239,8 @@ var/global/list/uneatable = list( gain = 100 spawn() A:gib() - sleep(1) +//Sleep being called in process() :| +// sleep(1) else if(istype(A,/obj/)) if (istype(A,/obj/item/weapon/storage/backpack/holding)) @@ -258,8 +262,8 @@ var/global/list/uneatable = list( O.y = 2 O.z = 2 else - A:ex_act(1.0) - if(A) del(A) + spawn(rand(0,10)) //Spreading shit out + del(A) gain = 2 else if(isturf(A)) var/turf/T = A @@ -271,6 +275,9 @@ var/global/list/uneatable = list( src.consume(O) A:ReplaceWithSpace() gain = 2 + else + spawn(rand(0,10)) //Spreading shit out + del(A) src.energy += gain return diff --git a/code/setup.dm b/code/setup.dm index 2269e987090..5e7369fbb9a 100644 --- a/code/setup.dm +++ b/code/setup.dm @@ -155,7 +155,7 @@ var/const XRAY =(1<<2) HULK =(1<<3) CLUMSY =(1<<4) - //FAT =(1<<5) + FAT =(1<<5) HUSK =(1<<6) LASER =(1<<7) HEAL =(1<<8) @@ -166,10 +166,11 @@ var/const mRemotetalk =(1<<13) mMorph =(1<<14) mBlend =(1<<15) - mHallucination =(1<<16) - mFingerprints =(1<<17) - mShock =(1<<18) - mSmallsize =(1<<19) +//the "&" operator cannot go higher than (2^16)-1 + mHallucination =(1<<0) + mFingerprints =(1<<1) + mShock =(1<<2) + mSmallsize =(1<<3) //mob/var/stat things var/const