mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
DNA2 EPISODE 2: Revenge of the Bugs
Made after DNA2 hit /vg/'s main server after no one tested anything. * Gene activation/deactivation made modular, refactors domutcheck. * Standardized genetics disks and injectors a bit in response to buffer corruption issues. (Untested) * Lots of major bug fixes. * Skin tones fixed. Still needs further testing. All I did was mess around with monkeys.
This commit is contained in:
@@ -179,8 +179,13 @@
|
|||||||
#include "code\game\area\areas.dm"
|
#include "code\game\area\areas.dm"
|
||||||
#include "code\game\area\Space Station 13 areas.dm"
|
#include "code\game\area\Space Station 13 areas.dm"
|
||||||
#include "code\game\dna\dna2.dm"
|
#include "code\game\dna\dna2.dm"
|
||||||
|
#include "code\game\dna\dna2_domutcheck.dm"
|
||||||
#include "code\game\dna\dna2_helpers.dm"
|
#include "code\game\dna\dna2_helpers.dm"
|
||||||
#include "code\game\dna\dna_modifier.dm"
|
#include "code\game\dna\dna_modifier.dm"
|
||||||
|
#include "code\game\dna\genes\disabilities.dm"
|
||||||
|
#include "code\game\dna\genes\gene.dm"
|
||||||
|
#include "code\game\dna\genes\monkey.dm"
|
||||||
|
#include "code\game\dna\genes\powers.dm"
|
||||||
#include "code\game\gamemodes\events.dm"
|
#include "code\game\gamemodes\events.dm"
|
||||||
#include "code\game\gamemodes\factions.dm"
|
#include "code\game\gamemodes\factions.dm"
|
||||||
#include "code\game\gamemodes\game_mode.dm"
|
#include "code\game\gamemodes\game_mode.dm"
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
// BEGIN_INTERNALS
|
// BEGIN_INTERNALS
|
||||||
/*
|
/*
|
||||||
MAP_ICON_TYPE: 0
|
MAP_ICON_TYPE: 0
|
||||||
|
WINDOW: code\__HELPERS\unsorted.dm;code\game\dna\dna2.dm;code\game\dna\dna2_domutcheck.dm;code\game\dna\dna2_helpers.dm;code\game\dna\dna_modifier.dm;code\game\machinery\cloning.dm;code\game\objects\items\weapons\dna_injector.dm;code\game\dna\genes\disabilities.dm;code\game\gamemodes\setupgame.dm;code\setup.dm;code\global.dm
|
||||||
|
LAST_COMPILE_VERSION: 501.1217
|
||||||
|
DIR: code code\game code\game\dna code\game\dna\genes code\game\gamemodes code\game\objects code\game\objects\items code\game\objects\items\weapons
|
||||||
|
FILE: code\game\objects\items\weapons\dna_injector.dm
|
||||||
|
LAST_COMPILE_TIME: 1387468589
|
||||||
AUTO_FILE_DIR: OFF
|
AUTO_FILE_DIR: OFF
|
||||||
*/
|
*/
|
||||||
// END_INTERNALS
|
// END_INTERNALS
|
||||||
|
|||||||
@@ -107,13 +107,13 @@
|
|||||||
var/datum/data/record/L = new()
|
var/datum/data/record/L = new()
|
||||||
L.fields["id"] = md5("[H.real_name][H.mind.assigned_role]")
|
L.fields["id"] = md5("[H.real_name][H.mind.assigned_role]")
|
||||||
L.fields["name"] = H.real_name
|
L.fields["name"] = H.real_name
|
||||||
L.fields["rank"] = H.mind.assigned_role
|
L.fields["rank"] = H.mind.assigned_role
|
||||||
L.fields["age"] = H.age
|
L.fields["age"] = H.age
|
||||||
L.fields["sex"] = H.gender
|
L.fields["sex"] = H.gender
|
||||||
L.fields["b_type"] = H.b_type
|
L.fields["b_type"] = H.b_type
|
||||||
L.fields["b_dna"] = H.dna.unique_enzymes
|
L.fields["b_dna"] = H.dna.unique_enzymes
|
||||||
L.fields["enzymes"] = H.dna.SE
|
L.fields["enzymes"] = H.dna.SE // Used in respawning
|
||||||
L.fields["identity"] = H.dna.UI
|
L.fields["identity"] = H.dna.UI // "
|
||||||
L.fields["image"] = getFlatIcon(H,0) //This is god-awful
|
L.fields["image"] = getFlatIcon(H,0) //This is god-awful
|
||||||
locked += L
|
locked += L
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -25,6 +25,8 @@ var/global/list/dna_activity_bounds[STRUCDNASIZE]
|
|||||||
// Used to determine what each block means (admin hax and species stuff on /vg/, mostly)
|
// Used to determine what each block means (admin hax and species stuff on /vg/, mostly)
|
||||||
var/global/list/assigned_blocks[STRUCDNASIZE]
|
var/global/list/assigned_blocks[STRUCDNASIZE]
|
||||||
|
|
||||||
|
var/global/list/datum/dna/gene/dna_genes[0]
|
||||||
|
|
||||||
// UI Indices (can change to mutblock style, if desired)
|
// UI Indices (can change to mutblock style, if desired)
|
||||||
#define DNA_UI_HAIR_R 1
|
#define DNA_UI_HAIR_R 1
|
||||||
#define DNA_UI_HAIR_G 2
|
#define DNA_UI_HAIR_G 2
|
||||||
@@ -41,6 +43,13 @@ var/global/list/assigned_blocks[STRUCDNASIZE]
|
|||||||
#define DNA_UI_HAIR_STYLE 13
|
#define DNA_UI_HAIR_STYLE 13
|
||||||
#define DNA_UI_LENGTH 13 // Update this when you add something, or you WILL break shit.
|
#define DNA_UI_LENGTH 13 // Update this when you add something, or you WILL break shit.
|
||||||
|
|
||||||
|
/////////////////
|
||||||
|
// GENE DEFINES
|
||||||
|
/////////////////
|
||||||
|
|
||||||
|
// Skip checking if it's already active.
|
||||||
|
// Used for genes that check for value rather than a binary on/off.
|
||||||
|
#define GENE_ALWAYS_ACTIVATE 1
|
||||||
|
|
||||||
/* Note RE: unassigned blocks
|
/* Note RE: unassigned blocks
|
||||||
|
|
||||||
@@ -77,6 +86,10 @@ var/global/list/assigned_blocks[STRUCDNASIZE]
|
|||||||
var/b_type = "A+" // Should probably change to an integer => string map but I'm lazy.
|
var/b_type = "A+" // Should probably change to an integer => string map but I'm lazy.
|
||||||
var/mutantrace = null // The type of mutant race the player is, if applicable (i.e. potato-man)
|
var/mutantrace = null // The type of mutant race the player is, if applicable (i.e. potato-man)
|
||||||
var/real_name // Stores the real name of the person who originally got this dna datum. Used primarily for changelings,
|
var/real_name // Stores the real name of the person who originally got this dna datum. Used primarily for changelings,
|
||||||
|
|
||||||
|
// New stuff
|
||||||
|
var/species = "Human"
|
||||||
|
|
||||||
///////////////////////////////////////
|
///////////////////////////////////////
|
||||||
// UNIQUE IDENTITY
|
// UNIQUE IDENTITY
|
||||||
///////////////////////////////////////
|
///////////////////////////////////////
|
||||||
@@ -84,7 +97,11 @@ var/global/list/assigned_blocks[STRUCDNASIZE]
|
|||||||
// Create random UI.
|
// Create random UI.
|
||||||
/datum/dna/proc/ResetUI(var/defer=0)
|
/datum/dna/proc/ResetUI(var/defer=0)
|
||||||
for(var/i=1,i<=DNA_UI_LENGTH,i++)
|
for(var/i=1,i<=DNA_UI_LENGTH,i++)
|
||||||
UI[i]=rand(0,4095)
|
switch(i)
|
||||||
|
if(DNA_UI_SKIN_TONE)
|
||||||
|
SetUIValueRange(DNA_UI_SKIN_TONE,rand(1,220),220,1) // Otherwise, it gets fucked
|
||||||
|
else
|
||||||
|
UI[i]=rand(0,4095)
|
||||||
if(!defer)
|
if(!defer)
|
||||||
UpdateUI()
|
UpdateUI()
|
||||||
|
|
||||||
@@ -114,7 +131,7 @@ var/global/list/assigned_blocks[STRUCDNASIZE]
|
|||||||
SetUIValueRange(DNA_UI_BEARD_G, character.g_eyes, 255, 1)
|
SetUIValueRange(DNA_UI_BEARD_G, character.g_eyes, 255, 1)
|
||||||
SetUIValueRange(DNA_UI_BEARD_B, character.b_eyes, 255, 1)
|
SetUIValueRange(DNA_UI_BEARD_B, character.b_eyes, 255, 1)
|
||||||
|
|
||||||
SetUIValueRange(DNA_UI_SKIN_TONE, character.s_tone, 220, 1)
|
SetUIValueRange(DNA_UI_SKIN_TONE, 35-character.s_tone, 220, 1) // Value can be negative.
|
||||||
|
|
||||||
SetUIState(DNA_UI_GENDER, character.gender!=MALE, 1)
|
SetUIState(DNA_UI_GENDER, character.gender!=MALE, 1)
|
||||||
|
|
||||||
@@ -234,6 +251,12 @@ var/global/list/assigned_blocks[STRUCDNASIZE]
|
|||||||
if(value)
|
if(value)
|
||||||
SetSEValue(block, value * range - rand(1,range-1))
|
SetSEValue(block, value * range - rand(1,range-1))
|
||||||
|
|
||||||
|
// Getter version of above.
|
||||||
|
/datum/dna/proc/GetSEValueRange(var/block,var/maxvalue)
|
||||||
|
if (block<=0) return 0
|
||||||
|
var/value = GetSEValue(block)
|
||||||
|
return round(1 +(value / 4096)*maxvalue)
|
||||||
|
|
||||||
// Is the block "on" (1) or "off" (0)? (Un-assigned genes are always off.)
|
// Is the block "on" (1) or "off" (0)? (Un-assigned genes are always off.)
|
||||||
/datum/dna/proc/GetSEState(var/block)
|
/datum/dna/proc/GetSEState(var/block)
|
||||||
if (block<=0) return 0
|
if (block<=0) return 0
|
||||||
|
|||||||
355
code/game/dna/dna2_domutcheck.dm
Normal file
355
code/game/dna/dna2_domutcheck.dm
Normal file
@@ -0,0 +1,355 @@
|
|||||||
|
// (Re-)Apply mutations.
|
||||||
|
// TODO: Turn into a /mob proc, change inj to a bitflag for various forms of differing behavior.
|
||||||
|
// M: Mob to mess with
|
||||||
|
// connected: Machine we're in, type unchecked so I doubt it's used beyond monkeying
|
||||||
|
// flags: See below, bitfield.
|
||||||
|
#define MUTCHK_FORCED 1
|
||||||
|
/proc/domutcheck(var/mob/living/M, var/connected=null, var/flags=0)
|
||||||
|
for(var/datum/dna/gene/gene in dna_genes)
|
||||||
|
if(!M)
|
||||||
|
return
|
||||||
|
if(!gene.block)
|
||||||
|
continue
|
||||||
|
|
||||||
|
// Sanity checks, don't skip.
|
||||||
|
if(!gene.can_activate(M,flags))
|
||||||
|
//testing("[M] - Failed to activate [gene.name] (can_activate fail).")
|
||||||
|
continue
|
||||||
|
|
||||||
|
// Current state
|
||||||
|
var/gene_active = (gene.flags & GENE_ALWAYS_ACTIVATE)
|
||||||
|
if(!gene_active)
|
||||||
|
gene_active = M.dna.GetSEState(gene.block)
|
||||||
|
|
||||||
|
// Prior state
|
||||||
|
var/gene_prior_status = (gene.type in M.active_genes)
|
||||||
|
|
||||||
|
if((gene_active && !gene_prior_status) || (gene.flags & GENE_ALWAYS_ACTIVATE))
|
||||||
|
//testing("[gene.name] activated!")
|
||||||
|
gene.activate(M,connected,flags)
|
||||||
|
if(M)
|
||||||
|
if(!(gene.flags & GENE_ALWAYS_ACTIVATE))
|
||||||
|
M.active_genes |= gene.type
|
||||||
|
M.update_icon=1
|
||||||
|
else if(!gene_active && gene_prior_status)
|
||||||
|
//testing("[gene.name] deactivated!")
|
||||||
|
gene.deactivate(M,connected,flags)
|
||||||
|
if(M)
|
||||||
|
M.active_genes -= gene.type
|
||||||
|
M.update_icon = 1
|
||||||
|
//else
|
||||||
|
// testing("[M] - Failed to activate [gene.name] - [gene_active?"+":"-"]active, [gene_prior_status?"+":"-"]prior")
|
||||||
|
|
||||||
|
/* Old, inflexibile
|
||||||
|
/proc/domutcheck(var/mob/living/M, var/connected, var/flags)
|
||||||
|
if (!M) return
|
||||||
|
|
||||||
|
M.dna.check_integrity()
|
||||||
|
|
||||||
|
M.disabilities = 0
|
||||||
|
M.sdisabilities = 0
|
||||||
|
var/old_mutations = M.mutations
|
||||||
|
M.mutations = list()
|
||||||
|
M.pass_flags = 0
|
||||||
|
// M.see_in_dark = 2
|
||||||
|
// M.see_invisible = 0
|
||||||
|
|
||||||
|
if(PLANT in old_mutations)
|
||||||
|
M.mutations.Add(PLANT)
|
||||||
|
if(SKELETON in old_mutations)
|
||||||
|
M.mutations.Add(SKELETON)
|
||||||
|
if(FAT in old_mutations)
|
||||||
|
M.mutations.Add(FAT)
|
||||||
|
if(HUSK in old_mutations)
|
||||||
|
M.mutations.Add(HUSK)
|
||||||
|
|
||||||
|
var/inj = (flags & MUTCHK_FROM_INJECTOR) == MUTCHK_FROM_INJECTOR
|
||||||
|
var/forced = (flags & MUTCHK_FORCED) == MUTCHK_FORCED
|
||||||
|
|
||||||
|
if(M.dna.GetSEState(NOBREATHBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mNobreath in old_mutations))
|
||||||
|
M << "\blue You feel no need to breathe."
|
||||||
|
M.mutations.Add(mNobreath)
|
||||||
|
if(M.dna.GetSEState(REMOTEVIEWBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mRemote in old_mutations))
|
||||||
|
M << "\blue Your mind expands"
|
||||||
|
M.mutations.Add(mRemote)
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/remoteobserve
|
||||||
|
if(M.dna.GetSEState(REGENERATEBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mRegen in old_mutations))
|
||||||
|
M << "\blue You feel better"
|
||||||
|
M.mutations.Add(mRegen)
|
||||||
|
if(M.dna.GetSEState(INCREASERUNBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mRun in old_mutations))
|
||||||
|
M << "\blue Your leg muscles pulsate."
|
||||||
|
M.mutations.Add(mRun)
|
||||||
|
if(M.dna.GetSEState(REMOTETALKBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mRemotetalk in old_mutations))
|
||||||
|
M << "\blue You expand your mind outwards"
|
||||||
|
M.mutations.Add(mRemotetalk)
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/remotesay
|
||||||
|
if(M.dna.GetSEState(MORPHBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mMorph in old_mutations))
|
||||||
|
M.mutations.Add(mMorph)
|
||||||
|
M << "\blue Your skin feels strange"
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/morph
|
||||||
|
if(M.dna.GetSEState(COLDBLOCK))
|
||||||
|
if(!(COLD_RESISTANCE in old_mutations))
|
||||||
|
if(forced || probinj(15,inj) || (mHeatres in old_mutations))
|
||||||
|
M.mutations.Add(mHeatres)
|
||||||
|
M << "\blue Your skin is icy to the touch"
|
||||||
|
else
|
||||||
|
if(forced || probinj(5,inj) || (mHeatres in old_mutations))
|
||||||
|
M.mutations.Add(mHeatres)
|
||||||
|
M << "\blue Your skin is icy to the touch"
|
||||||
|
if(M.dna.GetSEState(HALLUCINATIONBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mHallucination in old_mutations))
|
||||||
|
M.mutations.Add(mHallucination)
|
||||||
|
M << "\red Your mind says 'Hello'"
|
||||||
|
if(M.dna.GetSEState(NOPRINTSBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mFingerprints in old_mutations))
|
||||||
|
M.mutations.Add(mFingerprints)
|
||||||
|
M << "\blue Your fingers feel numb"
|
||||||
|
if(M.dna.GetSEState(SHOCKIMMUNITYBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mShock in old_mutations))
|
||||||
|
M.mutations.Add(mShock)
|
||||||
|
M << "\blue Your skin feels strange"
|
||||||
|
if(M.dna.GetSEState(SMALLSIZEBLOCK))
|
||||||
|
if(forced || probinj(45,inj) || (mSmallsize in old_mutations))
|
||||||
|
M << "\blue Your skin feels rubbery"
|
||||||
|
M.mutations.Add(mSmallsize)
|
||||||
|
M.pass_flags |= 1
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if (M.dna.GetSEState(HULKBLOCK))
|
||||||
|
if(forced || probinj(5,inj) || (HULK in old_mutations))
|
||||||
|
M << "\blue Your muscles hurt."
|
||||||
|
M.mutations.Add(HULK)
|
||||||
|
if (M.dna.GetSEState(HEADACHEBLOCK))
|
||||||
|
M.disabilities |= EPILEPSY
|
||||||
|
M << "\red You get a headache."
|
||||||
|
if (M.dna.GetSEState(FAKEBLOCK))
|
||||||
|
M << "\red You feel strange."
|
||||||
|
if (prob(95))
|
||||||
|
if(prob(50))
|
||||||
|
randmutb(M)
|
||||||
|
else
|
||||||
|
randmuti(M)
|
||||||
|
else
|
||||||
|
randmutg(M)
|
||||||
|
if (M.dna.GetSEState(COUGHBLOCK))
|
||||||
|
M.disabilities |= COUGHING
|
||||||
|
M << "\red You start coughing."
|
||||||
|
if (M.dna.GetSEState(CLUMSYBLOCK))
|
||||||
|
M << "\red You feel lightheaded."
|
||||||
|
M.mutations.Add(CLUMSY)
|
||||||
|
if (M.dna.GetSEState(TWITCHBLOCK))
|
||||||
|
M.disabilities |= TOURETTES
|
||||||
|
M << "\red You twitch."
|
||||||
|
if (M.dna.GetSEState(XRAYBLOCK))
|
||||||
|
if(forced || probinj(30,inj) || (XRAY in old_mutations))
|
||||||
|
M << "\blue The walls suddenly disappear."
|
||||||
|
// M.sight |= (SEE_MOBS|SEE_OBJS|SEE_TURFS)
|
||||||
|
// M.see_in_dark = 8
|
||||||
|
// M.see_invisible = 2
|
||||||
|
M.mutations.Add(XRAY)
|
||||||
|
if (M.dna.GetSEState(NERVOUSBLOCK))
|
||||||
|
M.disabilities |= NERVOUS
|
||||||
|
M << "\red You feel nervous."
|
||||||
|
if (M.dna.GetSEState(FIREBLOCK))
|
||||||
|
if(!(mHeatres in old_mutations))
|
||||||
|
if(forced || probinj(30,inj) || (COLD_RESISTANCE in old_mutations))
|
||||||
|
M << "\blue Your body feels warm."
|
||||||
|
M.mutations.Add(COLD_RESISTANCE)
|
||||||
|
else
|
||||||
|
if(forced || probinj(5,inj) || (COLD_RESISTANCE in old_mutations))
|
||||||
|
M << "\blue Your body feels warm."
|
||||||
|
M.mutations.Add(COLD_RESISTANCE)
|
||||||
|
if (M.dna.GetSEState(BLINDBLOCK))
|
||||||
|
M.sdisabilities |= BLIND
|
||||||
|
M << "\red You can't seem to see anything."
|
||||||
|
if (M.dna.GetSEState(TELEBLOCK))
|
||||||
|
if(forced || probinj(15,inj) || (TK in old_mutations))
|
||||||
|
M << "\blue You feel smarter."
|
||||||
|
M.mutations.Add(TK)
|
||||||
|
if (M.dna.GetSEState(DEAFBLOCK))
|
||||||
|
M.sdisabilities |= DEAF
|
||||||
|
M.ear_deaf = 1
|
||||||
|
M << "\red Its kinda quiet.."
|
||||||
|
if (M.dna.GetSEState(GLASSESBLOCK))
|
||||||
|
M.disabilities |= NEARSIGHTED
|
||||||
|
M << "Your eyes feel weird..."
|
||||||
|
|
||||||
|
/* If you want the new mutations to work, UNCOMMENT THIS.
|
||||||
|
if(istype(M, /mob/living/carbon))
|
||||||
|
for (var/datum/mutations/mut in global_mutations)
|
||||||
|
mut.check_mutation(M)
|
||||||
|
*/
|
||||||
|
|
||||||
|
//////////////////////////////////////////////////////////// Monkey Block
|
||||||
|
if (M.dna.GetSEState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human))
|
||||||
|
// human > monkey
|
||||||
|
var/mob/living/carbon/human/H = M
|
||||||
|
H.monkeyizing = 1
|
||||||
|
var/list/implants = list() //Try to preserve implants.
|
||||||
|
for(var/obj/item/weapon/implant/W in H)
|
||||||
|
implants += W
|
||||||
|
W.loc = null
|
||||||
|
|
||||||
|
if(!connected)
|
||||||
|
for(var/obj/item/W in (H.contents-implants))
|
||||||
|
if (W==H.w_uniform) // will be teared
|
||||||
|
continue
|
||||||
|
H.drop_from_inventory(W)
|
||||||
|
M.monkeyizing = 1
|
||||||
|
M.canmove = 0
|
||||||
|
M.icon = null
|
||||||
|
M.invisibility = 101
|
||||||
|
var/atom/movable/overlay/animation = new( M.loc )
|
||||||
|
animation.icon_state = "blank"
|
||||||
|
animation.icon = 'icons/mob/mob.dmi'
|
||||||
|
animation.master = src
|
||||||
|
flick("h2monkey", animation)
|
||||||
|
sleep(48)
|
||||||
|
del(animation)
|
||||||
|
|
||||||
|
|
||||||
|
var/mob/living/carbon/monkey/O = null
|
||||||
|
if(H.species.primitive)
|
||||||
|
O = new H.species.primitive(src)
|
||||||
|
else
|
||||||
|
H.gib() //Trying to change the species of a creature with no primitive var set is messy.
|
||||||
|
return
|
||||||
|
|
||||||
|
if(M)
|
||||||
|
if (M.dna)
|
||||||
|
O.dna = M.dna
|
||||||
|
M.dna = null
|
||||||
|
|
||||||
|
if (M.suiciding)
|
||||||
|
O.suiciding = M.suiciding
|
||||||
|
M.suiciding = null
|
||||||
|
|
||||||
|
|
||||||
|
for(var/datum/disease/D in M.viruses)
|
||||||
|
O.viruses += D
|
||||||
|
D.affected_mob = O
|
||||||
|
M.viruses -= D
|
||||||
|
|
||||||
|
|
||||||
|
for(var/obj/T in (M.contents-implants))
|
||||||
|
del(T)
|
||||||
|
|
||||||
|
O.loc = M.loc
|
||||||
|
|
||||||
|
if(M.mind)
|
||||||
|
M.mind.transfer_to(O) //transfer our mind to the cute little monkey
|
||||||
|
|
||||||
|
if (connected) //inside dna thing
|
||||||
|
var/obj/machinery/dna_scannernew/C = connected
|
||||||
|
O.loc = C
|
||||||
|
C.occupant = O
|
||||||
|
connected = null
|
||||||
|
O.real_name = text("monkey ([])",copytext(md5(M.real_name), 2, 6))
|
||||||
|
O.take_overall_damage(M.getBruteLoss() + 40, M.getFireLoss())
|
||||||
|
O.adjustToxLoss(M.getToxLoss() + 20)
|
||||||
|
O.adjustOxyLoss(M.getOxyLoss())
|
||||||
|
O.stat = M.stat
|
||||||
|
O.a_intent = "hurt"
|
||||||
|
for (var/obj/item/weapon/implant/I in implants)
|
||||||
|
I.loc = O
|
||||||
|
I.implanted = O
|
||||||
|
// O.update_icon = 1 //queue a full icon update at next life() call
|
||||||
|
del(M)
|
||||||
|
return
|
||||||
|
|
||||||
|
if (!M.dna.GetSEState(MONKEYBLOCK) && !istype(M, /mob/living/carbon/human))
|
||||||
|
// monkey > human,
|
||||||
|
var/mob/living/carbon/monkey/Mo = M
|
||||||
|
Mo.monkeyizing = 1
|
||||||
|
var/list/implants = list() //Still preserving implants
|
||||||
|
for(var/obj/item/weapon/implant/W in Mo)
|
||||||
|
implants += W
|
||||||
|
W.loc = null
|
||||||
|
if(!connected)
|
||||||
|
for(var/obj/item/W in (Mo.contents-implants))
|
||||||
|
Mo.drop_from_inventory(W)
|
||||||
|
M.monkeyizing = 1
|
||||||
|
M.canmove = 0
|
||||||
|
M.icon = null
|
||||||
|
M.invisibility = 101
|
||||||
|
var/atom/movable/overlay/animation = new( M.loc )
|
||||||
|
animation.icon_state = "blank"
|
||||||
|
animation.icon = 'icons/mob/mob.dmi'
|
||||||
|
animation.master = src
|
||||||
|
flick("monkey2h", animation)
|
||||||
|
sleep(48)
|
||||||
|
del(animation)
|
||||||
|
|
||||||
|
var/mob/living/carbon/human/O = new( src )
|
||||||
|
if(Mo.greaterform)
|
||||||
|
O.set_species(Mo.greaterform)
|
||||||
|
|
||||||
|
if (M.dna.GetUIState(DNA_UI_GENDER))
|
||||||
|
O.gender = FEMALE
|
||||||
|
else
|
||||||
|
O.gender = MALE
|
||||||
|
|
||||||
|
if (M)
|
||||||
|
if (M.dna)
|
||||||
|
O.dna = M.dna
|
||||||
|
M.dna = null
|
||||||
|
|
||||||
|
if (M.suiciding)
|
||||||
|
O.suiciding = M.suiciding
|
||||||
|
M.suiciding = null
|
||||||
|
|
||||||
|
for(var/datum/disease/D in M.viruses)
|
||||||
|
O.viruses += D
|
||||||
|
D.affected_mob = O
|
||||||
|
M.viruses -= D
|
||||||
|
|
||||||
|
//for(var/obj/T in M)
|
||||||
|
// del(T)
|
||||||
|
|
||||||
|
O.loc = M.loc
|
||||||
|
|
||||||
|
if(M.mind)
|
||||||
|
M.mind.transfer_to(O) //transfer our mind to the human
|
||||||
|
|
||||||
|
if (connected) //inside dna thing
|
||||||
|
var/obj/machinery/dna_scannernew/C = connected
|
||||||
|
O.loc = C
|
||||||
|
C.occupant = O
|
||||||
|
connected = null
|
||||||
|
|
||||||
|
var/i
|
||||||
|
while (!i)
|
||||||
|
var/randomname
|
||||||
|
if (O.gender == MALE)
|
||||||
|
randomname = capitalize(pick(first_names_male) + " " + capitalize(pick(last_names)))
|
||||||
|
else
|
||||||
|
randomname = capitalize(pick(first_names_female) + " " + capitalize(pick(last_names)))
|
||||||
|
if (findname(randomname))
|
||||||
|
continue
|
||||||
|
else
|
||||||
|
O.real_name = randomname
|
||||||
|
i++
|
||||||
|
O.UpdateAppearance()
|
||||||
|
O.take_overall_damage(M.getBruteLoss(), M.getFireLoss())
|
||||||
|
O.adjustToxLoss(M.getToxLoss())
|
||||||
|
O.adjustOxyLoss(M.getOxyLoss())
|
||||||
|
O.stat = M.stat
|
||||||
|
for (var/obj/item/weapon/implant/I in implants)
|
||||||
|
I.loc = O
|
||||||
|
I.implanted = O
|
||||||
|
// O.update_icon = 1 //queue a full icon update at next life() call
|
||||||
|
del(M)
|
||||||
|
return
|
||||||
|
//////////////////////////////////////////////////////////// Monkey Block
|
||||||
|
if(M)
|
||||||
|
M.update_icon = 1 //queue a full icon update at next life() call
|
||||||
|
return null
|
||||||
|
/////////////////////////// DNA MISC-PROCS
|
||||||
|
*/
|
||||||
@@ -143,7 +143,7 @@
|
|||||||
H.g_eyes = dna.GetUIValueRange(DNA_UI_EYES_G, 255)
|
H.g_eyes = dna.GetUIValueRange(DNA_UI_EYES_G, 255)
|
||||||
H.b_eyes = dna.GetUIValueRange(DNA_UI_EYES_B, 255)
|
H.b_eyes = dna.GetUIValueRange(DNA_UI_EYES_B, 255)
|
||||||
|
|
||||||
H.s_tone = dna.GetUIValueRange(DNA_UI_SKIN_TONE, 220)
|
H.s_tone = 35 - dna.GetUIValueRange(DNA_UI_SKIN_TONE, 220) // Value can be negative.
|
||||||
|
|
||||||
if (dna.GetUIState(DNA_UI_GENDER))
|
if (dna.GetUIState(DNA_UI_GENDER))
|
||||||
H.gender = FEMALE
|
H.gender = FEMALE
|
||||||
@@ -170,309 +170,3 @@
|
|||||||
// Used below, simple injection modifier.
|
// Used below, simple injection modifier.
|
||||||
/proc/probinj(var/pr, var/inj)
|
/proc/probinj(var/pr, var/inj)
|
||||||
return prob(pr+inj*pr)
|
return prob(pr+inj*pr)
|
||||||
|
|
||||||
// (Re-)Apply mutations.
|
|
||||||
// TODO: Turn into a /mob proc, change inj to a bitflag for various forms of differing behavior.
|
|
||||||
// M: Mob to mess with
|
|
||||||
// connected: Machine we're in, type unchecked so I doubt it's used beyond monkeying
|
|
||||||
// inj: 1 for if we're checking this from an injector, screws with manifestation probability calc.
|
|
||||||
/proc/domutcheck(mob/living/M as mob, connected, inj)
|
|
||||||
if (!M) return
|
|
||||||
|
|
||||||
M.dna.check_integrity()
|
|
||||||
|
|
||||||
M.disabilities = 0
|
|
||||||
M.sdisabilities = 0
|
|
||||||
var/old_mutations = M.mutations
|
|
||||||
M.mutations = list()
|
|
||||||
M.pass_flags = 0
|
|
||||||
// M.see_in_dark = 2
|
|
||||||
// M.see_invisible = 0
|
|
||||||
|
|
||||||
if(PLANT in old_mutations)
|
|
||||||
M.mutations.Add(PLANT)
|
|
||||||
if(SKELETON in old_mutations)
|
|
||||||
M.mutations.Add(SKELETON)
|
|
||||||
if(FAT in old_mutations)
|
|
||||||
M.mutations.Add(FAT)
|
|
||||||
if(HUSK in old_mutations)
|
|
||||||
M.mutations.Add(HUSK)
|
|
||||||
|
|
||||||
/////////////////////////////////////
|
|
||||||
// IMPORTANT REMINDER
|
|
||||||
// IF A BLOCK IS SET TO 0 (unused)
|
|
||||||
// GetSEState(block) WILL RETURN 0
|
|
||||||
/////////////////////////////////////
|
|
||||||
|
|
||||||
if(M.dna.GetSEState(NOBREATHBLOCK))
|
|
||||||
if(probinj(45,inj) || (mNobreath in old_mutations))
|
|
||||||
M << "\blue You feel no need to breathe."
|
|
||||||
M.mutations.Add(mNobreath)
|
|
||||||
if(M.dna.GetSEState(REMOTEVIEWBLOCK))
|
|
||||||
if(probinj(45,inj) || (mRemote in old_mutations))
|
|
||||||
M << "\blue Your mind expands"
|
|
||||||
M.mutations.Add(mRemote)
|
|
||||||
M.verbs += /mob/living/carbon/human/proc/remoteobserve
|
|
||||||
if(M.dna.GetSEState(REGENERATEBLOCK))
|
|
||||||
if(probinj(45,inj) || (mRegen in old_mutations))
|
|
||||||
M << "\blue You feel better"
|
|
||||||
M.mutations.Add(mRegen)
|
|
||||||
if(M.dna.GetSEState(INCREASERUNBLOCK))
|
|
||||||
if(probinj(45,inj) || (mRun in old_mutations))
|
|
||||||
M << "\blue Your leg muscles pulsate."
|
|
||||||
M.mutations.Add(mRun)
|
|
||||||
if(M.dna.GetSEState(REMOTETALKBLOCK))
|
|
||||||
if(probinj(45,inj) || (mRemotetalk in old_mutations))
|
|
||||||
M << "\blue You expand your mind outwards"
|
|
||||||
M.mutations.Add(mRemotetalk)
|
|
||||||
M.verbs += /mob/living/carbon/human/proc/remotesay
|
|
||||||
if(M.dna.GetSEState(MORPHBLOCK))
|
|
||||||
if(probinj(45,inj) || (mMorph in old_mutations))
|
|
||||||
M.mutations.Add(mMorph)
|
|
||||||
M << "\blue Your skin feels strange"
|
|
||||||
M.verbs += /mob/living/carbon/human/proc/morph
|
|
||||||
if(M.dna.GetSEState(HALLUCINATIONBLOCK))
|
|
||||||
if(probinj(45,inj) || (mHallucination in old_mutations))
|
|
||||||
M.mutations.Add(mHallucination)
|
|
||||||
M << "\red Your mind says 'Hello'"
|
|
||||||
if(M.dna.GetSEState(NOPRINTSBLOCK))
|
|
||||||
if(probinj(45,inj) || (mFingerprints in old_mutations))
|
|
||||||
M.mutations.Add(mFingerprints)
|
|
||||||
M << "\blue Your fingers feel numb"
|
|
||||||
if(M.dna.GetSEState(SHOCKIMMUNITYBLOCK))
|
|
||||||
if(probinj(45,inj) || (mShock in old_mutations))
|
|
||||||
M.mutations.Add(mShock)
|
|
||||||
M << "\blue Your skin feels strange"
|
|
||||||
if(M.dna.GetSEState(SMALLSIZEBLOCK))
|
|
||||||
if(probinj(45,inj) || (mSmallsize in old_mutations))
|
|
||||||
M << "\blue Your skin feels rubbery"
|
|
||||||
M.mutations.Add(mSmallsize)
|
|
||||||
M.pass_flags |= 1
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (M.dna.GetSEState(HULKBLOCK))
|
|
||||||
if(probinj(5,inj) || (HULK in old_mutations))
|
|
||||||
M << "\blue Your muscles hurt."
|
|
||||||
M.mutations.Add(HULK)
|
|
||||||
if (M.dna.GetSEState(HEADACHEBLOCK))
|
|
||||||
M.disabilities |= EPILEPSY
|
|
||||||
M << "\red You get a headache."
|
|
||||||
if (M.dna.GetSEState(FAKEBLOCK))
|
|
||||||
M << "\red You feel strange."
|
|
||||||
if (prob(95))
|
|
||||||
if(prob(50))
|
|
||||||
randmutb(M)
|
|
||||||
else
|
|
||||||
randmuti(M)
|
|
||||||
else
|
|
||||||
randmutg(M)
|
|
||||||
if (M.dna.GetSEState(COUGHBLOCK))
|
|
||||||
M.disabilities |= COUGHING
|
|
||||||
M << "\red You start coughing."
|
|
||||||
if (M.dna.GetSEState(CLUMSYBLOCK))
|
|
||||||
M << "\red You feel lightheaded."
|
|
||||||
M.mutations.Add(CLUMSY)
|
|
||||||
if (M.dna.GetSEState(TWITCHBLOCK))
|
|
||||||
M.disabilities |= TOURETTES
|
|
||||||
M << "\red You twitch."
|
|
||||||
if (M.dna.GetSEState(XRAYBLOCK))
|
|
||||||
if(probinj(30,inj) || (XRAY in old_mutations))
|
|
||||||
M << "\blue The walls suddenly disappear."
|
|
||||||
// M.sight |= (SEE_MOBS|SEE_OBJS|SEE_TURFS)
|
|
||||||
// M.see_in_dark = 8
|
|
||||||
// M.see_invisible = 2
|
|
||||||
M.mutations.Add(XRAY)
|
|
||||||
if (M.dna.GetSEState(NERVOUSBLOCK))
|
|
||||||
M.disabilities |= NERVOUS
|
|
||||||
M << "\red You feel nervous."
|
|
||||||
if (M.dna.GetSEState(FIREBLOCK))
|
|
||||||
if(probinj(30,inj) || (COLD_RESISTANCE in old_mutations))
|
|
||||||
M << "\blue Your body feels warm."
|
|
||||||
M.mutations.Add(COLD_RESISTANCE)
|
|
||||||
if (M.dna.GetSEState(BLINDBLOCK))
|
|
||||||
M.sdisabilities |= BLIND
|
|
||||||
M << "\red You can't seem to see anything."
|
|
||||||
if (M.dna.GetSEState(TELEBLOCK))
|
|
||||||
if(probinj(15,inj) || (TK in old_mutations))
|
|
||||||
M << "\blue You feel smarter."
|
|
||||||
M.mutations.Add(TK)
|
|
||||||
if (M.dna.GetSEState(DEAFBLOCK))
|
|
||||||
M.sdisabilities |= DEAF
|
|
||||||
M.ear_deaf = 1
|
|
||||||
M << "\red Its kinda quiet.."
|
|
||||||
if (M.dna.GetSEState(GLASSESBLOCK))
|
|
||||||
M.disabilities |= NEARSIGHTED
|
|
||||||
M << "Your eyes feel weird..."
|
|
||||||
|
|
||||||
/* If you want the new mutations to work, UNCOMMENT THIS.
|
|
||||||
if(istype(M, /mob/living/carbon))
|
|
||||||
for (var/datum/mutations/mut in global_mutations)
|
|
||||||
mut.check_mutation(M)
|
|
||||||
*/
|
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////// Monkey Block
|
|
||||||
if (M.dna.GetSEState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human))
|
|
||||||
// human > monkey
|
|
||||||
var/mob/living/carbon/human/H = M
|
|
||||||
H.monkeyizing = 1
|
|
||||||
var/list/implants = list() //Try to preserve implants.
|
|
||||||
for(var/obj/item/weapon/implant/W in H)
|
|
||||||
implants += W
|
|
||||||
W.loc = null
|
|
||||||
|
|
||||||
if(!connected)
|
|
||||||
for(var/obj/item/W in (H.contents-implants))
|
|
||||||
if (W==H.w_uniform) // will be teared
|
|
||||||
continue
|
|
||||||
H.drop_from_inventory(W)
|
|
||||||
M.monkeyizing = 1
|
|
||||||
M.canmove = 0
|
|
||||||
M.icon = null
|
|
||||||
M.invisibility = 101
|
|
||||||
var/atom/movable/overlay/animation = new( M.loc )
|
|
||||||
animation.icon_state = "blank"
|
|
||||||
animation.icon = 'icons/mob/mob.dmi'
|
|
||||||
animation.master = src
|
|
||||||
flick("h2monkey", animation)
|
|
||||||
sleep(48)
|
|
||||||
del(animation)
|
|
||||||
|
|
||||||
|
|
||||||
var/mob/living/carbon/monkey/O = null
|
|
||||||
if(H.species.primitive)
|
|
||||||
O = new H.species.primitive(src)
|
|
||||||
else
|
|
||||||
H.gib() //Trying to change the species of a creature with no primitive var set is messy.
|
|
||||||
return
|
|
||||||
|
|
||||||
if(M)
|
|
||||||
if (M.dna)
|
|
||||||
O.dna = M.dna
|
|
||||||
M.dna = null
|
|
||||||
|
|
||||||
if (M.suiciding)
|
|
||||||
O.suiciding = M.suiciding
|
|
||||||
M.suiciding = null
|
|
||||||
|
|
||||||
|
|
||||||
for(var/datum/disease/D in M.viruses)
|
|
||||||
O.viruses += D
|
|
||||||
D.affected_mob = O
|
|
||||||
M.viruses -= D
|
|
||||||
|
|
||||||
|
|
||||||
for(var/obj/T in (M.contents-implants))
|
|
||||||
del(T)
|
|
||||||
|
|
||||||
O.loc = M.loc
|
|
||||||
|
|
||||||
if(M.mind)
|
|
||||||
M.mind.transfer_to(O) //transfer our mind to the cute little monkey
|
|
||||||
|
|
||||||
if (connected) //inside dna thing
|
|
||||||
var/obj/machinery/dna_scannernew/C = connected
|
|
||||||
O.loc = C
|
|
||||||
C.occupant = O
|
|
||||||
connected = null
|
|
||||||
O.real_name = text("monkey ([])",copytext(md5(M.real_name), 2, 6))
|
|
||||||
O.take_overall_damage(M.getBruteLoss() + 40, M.getFireLoss())
|
|
||||||
O.adjustToxLoss(M.getToxLoss() + 20)
|
|
||||||
O.adjustOxyLoss(M.getOxyLoss())
|
|
||||||
O.stat = M.stat
|
|
||||||
O.a_intent = "hurt"
|
|
||||||
for (var/obj/item/weapon/implant/I in implants)
|
|
||||||
I.loc = O
|
|
||||||
I.implanted = O
|
|
||||||
// O.update_icon = 1 //queue a full icon update at next life() call
|
|
||||||
del(M)
|
|
||||||
return
|
|
||||||
|
|
||||||
if (!M.dna.GetSEState(MONKEYBLOCK) && !istype(M, /mob/living/carbon/human))
|
|
||||||
// monkey > human,
|
|
||||||
var/mob/living/carbon/monkey/Mo = M
|
|
||||||
Mo.monkeyizing = 1
|
|
||||||
var/list/implants = list() //Still preserving implants
|
|
||||||
for(var/obj/item/weapon/implant/W in Mo)
|
|
||||||
implants += W
|
|
||||||
W.loc = null
|
|
||||||
if(!connected)
|
|
||||||
for(var/obj/item/W in (Mo.contents-implants))
|
|
||||||
Mo.drop_from_inventory(W)
|
|
||||||
M.monkeyizing = 1
|
|
||||||
M.canmove = 0
|
|
||||||
M.icon = null
|
|
||||||
M.invisibility = 101
|
|
||||||
var/atom/movable/overlay/animation = new( M.loc )
|
|
||||||
animation.icon_state = "blank"
|
|
||||||
animation.icon = 'icons/mob/mob.dmi'
|
|
||||||
animation.master = src
|
|
||||||
flick("monkey2h", animation)
|
|
||||||
sleep(48)
|
|
||||||
del(animation)
|
|
||||||
|
|
||||||
var/mob/living/carbon/human/O = new( src )
|
|
||||||
if(Mo.greaterform)
|
|
||||||
O.set_species(Mo.greaterform)
|
|
||||||
|
|
||||||
if (M.dna.GetUIState(DNA_UI_GENDER))
|
|
||||||
O.gender = FEMALE
|
|
||||||
else
|
|
||||||
O.gender = MALE
|
|
||||||
|
|
||||||
if (M)
|
|
||||||
if (M.dna)
|
|
||||||
O.dna = M.dna
|
|
||||||
M.dna = null
|
|
||||||
|
|
||||||
if (M.suiciding)
|
|
||||||
O.suiciding = M.suiciding
|
|
||||||
M.suiciding = null
|
|
||||||
|
|
||||||
for(var/datum/disease/D in M.viruses)
|
|
||||||
O.viruses += D
|
|
||||||
D.affected_mob = O
|
|
||||||
M.viruses -= D
|
|
||||||
|
|
||||||
//for(var/obj/T in M)
|
|
||||||
// del(T)
|
|
||||||
|
|
||||||
O.loc = M.loc
|
|
||||||
|
|
||||||
if(M.mind)
|
|
||||||
M.mind.transfer_to(O) //transfer our mind to the human
|
|
||||||
|
|
||||||
if (connected) //inside dna thing
|
|
||||||
var/obj/machinery/dna_scannernew/C = connected
|
|
||||||
O.loc = C
|
|
||||||
C.occupant = O
|
|
||||||
connected = null
|
|
||||||
|
|
||||||
var/i
|
|
||||||
while (!i)
|
|
||||||
var/randomname
|
|
||||||
if (O.gender == MALE)
|
|
||||||
randomname = capitalize(pick(first_names_male) + " " + capitalize(pick(last_names)))
|
|
||||||
else
|
|
||||||
randomname = capitalize(pick(first_names_female) + " " + capitalize(pick(last_names)))
|
|
||||||
if (findname(randomname))
|
|
||||||
continue
|
|
||||||
else
|
|
||||||
O.real_name = randomname
|
|
||||||
i++
|
|
||||||
O.UpdateAppearance()
|
|
||||||
O.take_overall_damage(M.getBruteLoss(), M.getFireLoss())
|
|
||||||
O.adjustToxLoss(M.getToxLoss())
|
|
||||||
O.adjustOxyLoss(M.getOxyLoss())
|
|
||||||
O.stat = M.stat
|
|
||||||
for (var/obj/item/weapon/implant/I in implants)
|
|
||||||
I.loc = O
|
|
||||||
I.implanted = O
|
|
||||||
// O.update_icon = 1 //queue a full icon update at next life() call
|
|
||||||
del(M)
|
|
||||||
return
|
|
||||||
//////////////////////////////////////////////////////////// Monkey Block
|
|
||||||
if(M)
|
|
||||||
M.update_icon = 1 //queue a full icon update at next life() call
|
|
||||||
return null
|
|
||||||
/////////////////////////// DNA MISC-PROCS
|
|
||||||
@@ -1,5 +1,37 @@
|
|||||||
#define DNA_BLOCK_SIZE 3
|
#define DNA_BLOCK_SIZE 3
|
||||||
|
|
||||||
|
// Buffer datatype flags.
|
||||||
|
#define DNA2_BUF_UI 1
|
||||||
|
#define DNA2_BUF_UE 2
|
||||||
|
#define DNA2_BUF_SE 4
|
||||||
|
|
||||||
|
//list("data" = null, "owner" = null, "label" = null, "type" = null, "ue" = 0),
|
||||||
|
/datum/dna2/record
|
||||||
|
var/datum/dna/dna = null
|
||||||
|
var/types=0
|
||||||
|
var/name="Empty"
|
||||||
|
|
||||||
|
// Stuff for cloners
|
||||||
|
var/id=null
|
||||||
|
var/implant=null
|
||||||
|
var/ckey=null
|
||||||
|
var/mind=null
|
||||||
|
|
||||||
|
/datum/dna2/record/proc/GetData()
|
||||||
|
var/list/ser=list("data" = null, "owner" = null, "label" = null, "type" = null, "ue" = 0)
|
||||||
|
ser["ue"] = (types & DNA2_BUF_UE) == DNA2_BUF_UE
|
||||||
|
if(types & DNA2_BUF_SE)
|
||||||
|
ser["data"] = dna.SE
|
||||||
|
else
|
||||||
|
ser["data"] = dna.UI
|
||||||
|
ser["owner"] = src.dna.real_name
|
||||||
|
ser["label"] = name
|
||||||
|
if(types & DNA2_BUF_UI)
|
||||||
|
ser["type"] = "ui"
|
||||||
|
else
|
||||||
|
ser["type"] = "se"
|
||||||
|
return ser
|
||||||
|
|
||||||
/////////////////////////// DNA MACHINES
|
/////////////////////////// DNA MACHINES
|
||||||
/obj/machinery/dna_scannernew
|
/obj/machinery/dna_scannernew
|
||||||
name = "\improper DNA modifier"
|
name = "\improper DNA modifier"
|
||||||
@@ -14,6 +46,7 @@
|
|||||||
var/locked = 0
|
var/locked = 0
|
||||||
var/mob/living/carbon/occupant = null
|
var/mob/living/carbon/occupant = null
|
||||||
var/obj/item/weapon/reagent_containers/glass/beaker = null
|
var/obj/item/weapon/reagent_containers/glass/beaker = null
|
||||||
|
var/opened = 0
|
||||||
|
|
||||||
/obj/machinery/dna_scannernew/New()
|
/obj/machinery/dna_scannernew/New()
|
||||||
..()
|
..()
|
||||||
@@ -80,12 +113,6 @@
|
|||||||
usr.loc = src
|
usr.loc = src
|
||||||
src.occupant = usr
|
src.occupant = usr
|
||||||
src.icon_state = "scanner_1"
|
src.icon_state = "scanner_1"
|
||||||
/*
|
|
||||||
for(var/obj/O in src) // THIS IS P. STUPID -- LOVE, DOOHL
|
|
||||||
//O = null
|
|
||||||
del(O)
|
|
||||||
//Foreach goto(124)
|
|
||||||
*/
|
|
||||||
src.add_fingerprint(usr)
|
src.add_fingerprint(usr)
|
||||||
return
|
return
|
||||||
|
|
||||||
@@ -111,7 +138,12 @@
|
|||||||
if (G.affecting.abiotic())
|
if (G.affecting.abiotic())
|
||||||
user << "\blue <B>Subject cannot have abiotic items on.</B>"
|
user << "\blue <B>Subject cannot have abiotic items on.</B>"
|
||||||
return
|
return
|
||||||
var/mob/M = G.affecting
|
put_in(G.affecting)
|
||||||
|
src.add_fingerprint(user)
|
||||||
|
del(G)
|
||||||
|
return
|
||||||
|
|
||||||
|
/obj/machinery/dna_scannernew/proc/put_in(var/mob/M)
|
||||||
if(M.client)
|
if(M.client)
|
||||||
M.client.perspective = EYE_PERSPECTIVE
|
M.client.perspective = EYE_PERSPECTIVE
|
||||||
M.client.eye = src
|
M.client.eye = src
|
||||||
@@ -119,8 +151,6 @@
|
|||||||
src.occupant = M
|
src.occupant = M
|
||||||
src.icon_state = "scanner_1"
|
src.icon_state = "scanner_1"
|
||||||
|
|
||||||
src.add_fingerprint(user)
|
|
||||||
|
|
||||||
// search for ghosts, if the corpse is empty and the scanner is connected to a cloner
|
// search for ghosts, if the corpse is empty and the scanner is connected to a cloner
|
||||||
if(locate(/obj/machinery/computer/cloning, get_step(src, NORTH)) \
|
if(locate(/obj/machinery/computer/cloning, get_step(src, NORTH)) \
|
||||||
|| locate(/obj/machinery/computer/cloning, get_step(src, SOUTH)) \
|
|| locate(/obj/machinery/computer/cloning, get_step(src, SOUTH)) \
|
||||||
@@ -132,19 +162,11 @@
|
|||||||
if(ghost.mind == M.mind)
|
if(ghost.mind == M.mind)
|
||||||
ghost << "<b><font color = #330033><font size = 3>Your corpse has been placed into a cloning scanner. Return to your body if you want to be resurrected/cloned!</b> (Verbs -> Ghost -> Re-enter corpse)</font color>"
|
ghost << "<b><font color = #330033><font size = 3>Your corpse has been placed into a cloning scanner. Return to your body if you want to be resurrected/cloned!</b> (Verbs -> Ghost -> Re-enter corpse)</font color>"
|
||||||
break
|
break
|
||||||
del(G)
|
|
||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/dna_scannernew/proc/go_out()
|
/obj/machinery/dna_scannernew/proc/go_out()
|
||||||
if ((!( src.occupant ) || src.locked))
|
if ((!( src.occupant ) || src.locked))
|
||||||
return
|
return
|
||||||
/*
|
|
||||||
// it's like this was -just- here to break constructed dna scanners -Pete
|
|
||||||
// if that's not the case, slap my shit and uncomment this.
|
|
||||||
// for(var/obj/O in src)
|
|
||||||
// O.loc = src.loc
|
|
||||||
*/
|
|
||||||
//Foreach goto(30)
|
|
||||||
if (src.occupant.client)
|
if (src.occupant.client)
|
||||||
src.occupant.client.eye = src.occupant.client.mob
|
src.occupant.client.eye = src.occupant.client.mob
|
||||||
src.occupant.client.perspective = MOB_PERSPECTIVE
|
src.occupant.client.perspective = MOB_PERSPECTIVE
|
||||||
@@ -205,11 +227,7 @@
|
|||||||
var/selected_ui_target_hex = 1
|
var/selected_ui_target_hex = 1
|
||||||
var/radiation_duration = 2.0
|
var/radiation_duration = 2.0
|
||||||
var/radiation_intensity = 1.0
|
var/radiation_intensity = 1.0
|
||||||
var/list/buffers = list(
|
var/list/datum/dna2/record/buffers[3]
|
||||||
list("data" = null, "owner" = null, "label" = null, "type" = null, "ue" = 0),
|
|
||||||
list("data" = null, "owner" = null, "label" = null, "type" = null, "ue" = 0),
|
|
||||||
list("data" = null, "owner" = null, "label" = null, "type" = null, "ue" = 0)
|
|
||||||
)
|
|
||||||
var/irradiating = 0
|
var/irradiating = 0
|
||||||
var/injector_ready = 0 //Quick fix for issue 286 (screwdriver the screen twice to restore injector) -Pete
|
var/injector_ready = 0 //Quick fix for issue 286 (screwdriver the screen twice to restore injector) -Pete
|
||||||
var/obj/machinery/dna_scannernew/connected = null
|
var/obj/machinery/dna_scannernew/connected = null
|
||||||
@@ -219,6 +237,7 @@
|
|||||||
use_power = 1
|
use_power = 1
|
||||||
idle_power_usage = 10
|
idle_power_usage = 10
|
||||||
active_power_usage = 400
|
active_power_usage = 400
|
||||||
|
var/waiting_for_user_input=0 // Fix for #274 (Mash create block injector without answering dialog to make unlimited injectors) - N3X
|
||||||
|
|
||||||
/obj/machinery/computer/scan_consolenew/attackby(obj/item/I as obj, mob/user as mob)
|
/obj/machinery/computer/scan_consolenew/attackby(obj/item/I as obj, mob/user as mob)
|
||||||
if(istype(I, /obj/item/weapon/screwdriver))
|
if(istype(I, /obj/item/weapon/screwdriver))
|
||||||
@@ -308,13 +327,13 @@
|
|||||||
arr += "[i]:[EncodeDNABlock(buffer[i])]"
|
arr += "[i]:[EncodeDNABlock(buffer[i])]"
|
||||||
return arr
|
return arr
|
||||||
|
|
||||||
/obj/machinery/computer/scan_consolenew/proc/setInjectorBlock(var/obj/item/weapon/dnainjector/I, var/blk, var/list/buffer)
|
/obj/machinery/computer/scan_consolenew/proc/setInjectorBlock(var/obj/item/weapon/dnainjector/I, var/blk, var/datum/dna2/record/buffer)
|
||||||
var/pos = findtext(blk,":")
|
var/pos = findtext(blk,":")
|
||||||
if(!pos) return 0
|
if(!pos) return 0
|
||||||
var/id = text2num(copytext(blk,1,pos))
|
var/id = text2num(copytext(blk,1,pos))
|
||||||
if(!id) return 0
|
if(!id) return 0
|
||||||
I.block = id
|
I.block = id
|
||||||
I.dna = list(buffer[id])
|
I.buf = buffer
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
/obj/machinery/computer/scan_consolenew/attackby(obj/item/W as obj, mob/user as mob)
|
/obj/machinery/computer/scan_consolenew/attackby(obj/item/W as obj, mob/user as mob)
|
||||||
@@ -336,6 +355,7 @@
|
|||||||
ui_interact(user)
|
ui_interact(user)
|
||||||
|
|
||||||
/obj/machinery/computer/scan_consolenew/attack_ai(user as mob)
|
/obj/machinery/computer/scan_consolenew/attack_ai(user as mob)
|
||||||
|
src.add_hiddenprint(user)
|
||||||
ui_interact(user)
|
ui_interact(user)
|
||||||
|
|
||||||
/obj/machinery/computer/scan_consolenew/attack_hand(user as mob)
|
/obj/machinery/computer/scan_consolenew/attack_hand(user as mob)
|
||||||
@@ -369,21 +389,20 @@
|
|||||||
data["hasDisk"] = disk ? 1 : 0
|
data["hasDisk"] = disk ? 1 : 0
|
||||||
|
|
||||||
var/diskData[0]
|
var/diskData[0]
|
||||||
if (!disk)
|
if (!disk || !disk.buf)
|
||||||
diskData["data"] = null
|
diskData["data"] = null
|
||||||
diskData["owner"] = null
|
diskData["owner"] = null
|
||||||
diskData["label"] = null
|
diskData["label"] = null
|
||||||
diskData["type"] = null
|
diskData["type"] = null
|
||||||
diskData["ue"] = null
|
diskData["ue"] = null
|
||||||
else
|
else
|
||||||
diskData["data"] = disk.data
|
diskData = disk.buf.GetData()
|
||||||
diskData["owner"] = disk.owner
|
|
||||||
diskData["label"] = disk.name
|
|
||||||
diskData["type"] = disk.data_type
|
|
||||||
diskData["ue"] = disk.ue
|
|
||||||
data["disk"] = diskData
|
data["disk"] = diskData
|
||||||
|
|
||||||
data["buffers"] = buffers
|
var/list/new_buffers = list()
|
||||||
|
for(var/datum/dna2/record/buf in buffers)
|
||||||
|
new_buffers.Add(buf.GetData())
|
||||||
|
data["buffers"]=new_buffers
|
||||||
|
|
||||||
data["radiationIntensity"] = radiation_intensity
|
data["radiationIntensity"] = radiation_intensity
|
||||||
data["radiationDuration"] = radiation_duration
|
data["radiationDuration"] = radiation_duration
|
||||||
@@ -624,10 +643,13 @@
|
|||||||
src.selected_se_block = select_block
|
src.selected_se_block = select_block
|
||||||
if ((select_subblock <= DNA_BLOCK_SIZE) && (select_subblock >= 1))
|
if ((select_subblock <= DNA_BLOCK_SIZE) && (select_subblock >= 1))
|
||||||
src.selected_se_subblock = select_subblock
|
src.selected_se_subblock = select_subblock
|
||||||
|
//testing("User selected block [selected_se_block] (sent [select_block]), subblock [selected_se_subblock] (sent [select_block]).")
|
||||||
return 1 // return 1 forces an update to all Nano uis attached to src
|
return 1 // return 1 forces an update to all Nano uis attached to src
|
||||||
|
|
||||||
if (href_list["pulseSERadiation"])
|
if (href_list["pulseSERadiation"])
|
||||||
var/block = src.connected.occupant.dna.GetSESubBlock(src.selected_se_block,src.selected_se_subblock)
|
var/block = src.connected.occupant.dna.GetSESubBlock(src.selected_se_block,src.selected_se_subblock)
|
||||||
|
//var/original_block=block
|
||||||
|
//testing("Irradiating SE block [src.selected_se_block]:[src.selected_se_subblock] ([block])...")
|
||||||
|
|
||||||
irradiating = src.radiation_duration
|
irradiating = src.radiation_duration
|
||||||
var/lock_state = src.connected.locked
|
var/lock_state = src.connected.locked
|
||||||
@@ -650,23 +672,27 @@
|
|||||||
else if (src.selected_se_block > STRUCDNASIZE/2 && src.selected_se_block < STRUCDNASIZE)
|
else if (src.selected_se_block > STRUCDNASIZE/2 && src.selected_se_block < STRUCDNASIZE)
|
||||||
real_SE_block--
|
real_SE_block--
|
||||||
|
|
||||||
|
//testing("Irradiated SE block [real_SE_block]:[src.selected_se_subblock] ([original_block] now [block]) [(real_SE_block!=selected_se_block) ? "(SHIFTED)":""]!")
|
||||||
connected.occupant.dna.SetSESubBlock(real_SE_block,selected_se_subblock,block)
|
connected.occupant.dna.SetSESubBlock(real_SE_block,selected_se_subblock,block)
|
||||||
domutcheck(src.connected.occupant,src.connected)
|
|
||||||
src.connected.occupant.radiation += (src.radiation_intensity+src.radiation_duration)
|
src.connected.occupant.radiation += (src.radiation_intensity+src.radiation_duration)
|
||||||
|
domutcheck(src.connected.occupant,src.connected)
|
||||||
else
|
else
|
||||||
|
src.connected.occupant.radiation += ((src.radiation_intensity*2)+src.radiation_duration)
|
||||||
if (prob(80-src.radiation_duration))
|
if (prob(80-src.radiation_duration))
|
||||||
|
//testing("Random bad mut!")
|
||||||
randmutb(src.connected.occupant)
|
randmutb(src.connected.occupant)
|
||||||
domutcheck(src.connected.occupant,src.connected)
|
domutcheck(src.connected.occupant,src.connected)
|
||||||
else
|
else
|
||||||
randmuti(src.connected.occupant)
|
randmuti(src.connected.occupant)
|
||||||
|
//testing("Random identity mut!")
|
||||||
src.connected.occupant.UpdateAppearance()
|
src.connected.occupant.UpdateAppearance()
|
||||||
src.connected.occupant.radiation += ((src.radiation_intensity*2)+src.radiation_duration)
|
|
||||||
src.connected.locked = lock_state
|
src.connected.locked = lock_state
|
||||||
return 1 // return 1 forces an update to all Nano uis attached to src
|
return 1 // return 1 forces an update to all Nano uis attached to src
|
||||||
|
|
||||||
if(href_list["ejectBeaker"])
|
if(href_list["ejectBeaker"])
|
||||||
if(connected.beaker)
|
if(connected.beaker)
|
||||||
connected.beaker.loc = connected.loc
|
var/obj/item/weapon/reagent_containers/glass/B = connected.beaker
|
||||||
|
B.loc = connected.loc
|
||||||
connected.beaker = null
|
connected.beaker = null
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
@@ -684,11 +710,7 @@
|
|||||||
//src.temphtml = "Invalid disk. Please try again."
|
//src.temphtml = "Invalid disk. Please try again."
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
src.disk.data = null
|
src.disk.buf=null
|
||||||
src.disk.data_type = null
|
|
||||||
src.disk.ue = null
|
|
||||||
src.disk.owner = null
|
|
||||||
src.disk.name = null
|
|
||||||
//src.temphtml = "Data saved."
|
//src.temphtml = "Data saved."
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
@@ -710,50 +732,40 @@
|
|||||||
|
|
||||||
if (bufferOption == "saveUI")
|
if (bufferOption == "saveUI")
|
||||||
if(src.connected.occupant && src.connected.occupant.dna)
|
if(src.connected.occupant && src.connected.occupant.dna)
|
||||||
src.buffers[bufferId]["ue"] = 0
|
var/datum/dna2/record/databuf=new
|
||||||
src.buffers[bufferId]["data"] = src.connected.occupant.dna.UI
|
databuf.types = DNA2_BUF_UE
|
||||||
if (!istype(src.connected.occupant,/mob/living/carbon/human))
|
databuf.dna = src.connected.occupant.dna
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.name
|
databuf.name = "Unique Identifier"
|
||||||
else
|
src.buffers[bufferId] = databuf
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.real_name
|
|
||||||
src.buffers[bufferId]["label"] = "Unique Identifier"
|
|
||||||
src.buffers[bufferId]["type"] = "ui"
|
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "saveUIAndUE")
|
if (bufferOption == "saveUIAndUE")
|
||||||
if(src.connected.occupant && src.connected.occupant.dna)
|
if(src.connected.occupant && src.connected.occupant.dna)
|
||||||
src.buffers[bufferId]["data"] = src.connected.occupant.dna.UI
|
var/datum/dna2/record/databuf=new
|
||||||
if (!istype(src.connected.occupant,/mob/living/carbon/human))
|
databuf.types = DNA2_BUF_UI|DNA2_BUF_UE
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.name
|
databuf.dna = src.connected.occupant.dna
|
||||||
else
|
databuf.name = "Unique Identifier + Unique Enzymes"
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.real_name
|
src.buffers[bufferId] = databuf
|
||||||
src.buffers[bufferId]["label"] = "Unique Identifier + Unique Enzymes"
|
|
||||||
src.buffers[bufferId]["type"] = "ui"
|
|
||||||
src.buffers[bufferId]["ue"] = 1
|
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "saveSE")
|
if (bufferOption == "saveSE")
|
||||||
if(src.connected.occupant && src.connected.occupant.dna)
|
if(src.connected.occupant && src.connected.occupant.dna)
|
||||||
src.buffers[bufferId]["ue"] = 0
|
var/datum/dna2/record/databuf=new
|
||||||
src.buffers[bufferId]["data"] = src.connected.occupant.dna.SE
|
databuf.types = DNA2_BUF_SE
|
||||||
if (!istype(src.connected.occupant,/mob/living/carbon/human))
|
databuf.dna = src.connected.occupant.dna
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.name
|
databuf.name = "Structural Enzymes"
|
||||||
else
|
src.buffers[bufferId] = databuf
|
||||||
src.buffers[bufferId]["owner"] = src.connected.occupant.real_name
|
|
||||||
src.buffers[bufferId]["label"] = "Structural Enzymes"
|
|
||||||
src.buffers[bufferId]["type"] = "se"
|
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "clear")
|
if (bufferOption == "clear")
|
||||||
src.buffers[bufferId]["data"] = null
|
src.buffers[bufferId]=null
|
||||||
src.buffers[bufferId]["owner"] = null
|
|
||||||
src.buffers[bufferId]["label"] = null
|
|
||||||
src.buffers[bufferId]["ue"] = null
|
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "changeLabel")
|
if (bufferOption == "changeLabel")
|
||||||
var/label = src.buffers[bufferId]["label"] ? src.buffers[bufferId]["label"] : "New Label"
|
var/datum/dna2/record/buf = src.buffers[bufferId]
|
||||||
src.buffers[bufferId]["label"] = sanitize(input("New Label:", "Edit Label", label))
|
buf.name = buf.name ? src.buffers[bufferId]["label"] : "New Label"
|
||||||
|
buf.name = sanitize(input("New Label:", "Edit Label", buf.name))
|
||||||
|
src.buffers[bufferId] = buf
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "transfer")
|
if (bufferOption == "transfer")
|
||||||
@@ -770,32 +782,36 @@
|
|||||||
irradiating = 0
|
irradiating = 0
|
||||||
src.connected.locked = lock_state
|
src.connected.locked = lock_state
|
||||||
|
|
||||||
if (src.buffers[bufferId]["type"] == "ui")
|
var/datum/dna2/record/buf = src.buffers[bufferId]
|
||||||
if (src.buffers[bufferId]["ue"])
|
|
||||||
src.connected.occupant.real_name = src.buffers[bufferId]["owner"]
|
if ((buf.types & DNA2_BUF_UI))
|
||||||
src.connected.occupant.name = src.buffers[bufferId]["owner"]
|
if ((buf.types & DNA2_BUF_UE))
|
||||||
src.connected.occupant.UpdateAppearance(src.buffers[bufferId]["data"])
|
src.connected.occupant.real_name = buf.dna.real_name
|
||||||
else if (src.buffers[bufferId]["type"] == "se")
|
src.connected.occupant.name = buf.dna.real_name
|
||||||
src.connected.occupant.dna.SE = src.buffers[bufferId]["data"]
|
src.connected.occupant.UpdateAppearance(buf.dna.UI)
|
||||||
|
else if (buf.types & DNA2_BUF_SE)
|
||||||
|
src.connected.occupant.dna.SE = buf.dna.SE
|
||||||
src.connected.occupant.dna.UpdateSE()
|
src.connected.occupant.dna.UpdateSE()
|
||||||
domutcheck(src.connected.occupant,src.connected)
|
domutcheck(src.connected.occupant,src.connected)
|
||||||
src.connected.occupant.radiation += rand(20,50)
|
src.connected.occupant.radiation += rand(20,50)
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "createInjector")
|
if (bufferOption == "createInjector")
|
||||||
if (src.injector_ready)
|
if (src.injector_ready || waiting_for_user_input)
|
||||||
|
|
||||||
var/success = 1
|
var/success = 1
|
||||||
var/obj/item/weapon/dnainjector/I = new /obj/item/weapon/dnainjector
|
var/obj/item/weapon/dnainjector/I = new /obj/item/weapon/dnainjector
|
||||||
I.dnatype = src.buffers[bufferId]["type"]
|
var/datum/dna2/record/buf = src.buffers[bufferId]
|
||||||
if(href_list["createBlockInjector"])
|
if(href_list["createBlockInjector"])
|
||||||
var/blk = input(usr,"Select Block","Block") in all_dna_blocks(src.buffers[bufferId]["data"])
|
waiting_for_user_input=1
|
||||||
success = setInjectorBlock(I,blk,src.buffers[bufferId]["data"])
|
var/blk = input(usr,"Select Block","Block") in all_dna_blocks(buf.GetData())
|
||||||
|
success = setInjectorBlock(I,blk,buf)
|
||||||
else
|
else
|
||||||
I.dna = src.buffers[bufferId]["data"]
|
I.buf = buf
|
||||||
|
waiting_for_user_input=0
|
||||||
if(success)
|
if(success)
|
||||||
I.loc = src.loc
|
I.loc = src.loc
|
||||||
I.name += " ([src.buffers[bufferId]["label"]])"
|
I.name += " ([buf.name])"
|
||||||
if (src.buffers[bufferId]["ue"]) I.ue = src.buffers[bufferId]["owner"] //lazy haw haw
|
|
||||||
//src.temphtml = "Injector created."
|
//src.temphtml = "Injector created."
|
||||||
src.injector_ready = 0
|
src.injector_ready = 0
|
||||||
spawn(300)
|
spawn(300)
|
||||||
@@ -807,14 +823,11 @@
|
|||||||
return 1
|
return 1
|
||||||
|
|
||||||
if (bufferOption == "loadDisk")
|
if (bufferOption == "loadDisk")
|
||||||
if ((isnull(src.disk)) || (!src.disk.data) || (src.disk.data == ""))
|
if ((isnull(src.disk)) || (!src.disk.buf))
|
||||||
//src.temphtml = "Invalid disk. Please try again."
|
//src.temphtml = "Invalid disk. Please try again."
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
src.buffers[bufferId]["data"] = src.disk.data
|
src.buffers[bufferId]=src.disk.buf
|
||||||
src.buffers[bufferId]["type"] = src.disk.data_type
|
|
||||||
src.buffers[bufferId]["ue"] = src.disk.ue
|
|
||||||
src.buffers[bufferId]["owner"] = src.disk.owner
|
|
||||||
//src.temphtml = "Data loaded."
|
//src.temphtml = "Data loaded."
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
@@ -823,11 +836,10 @@
|
|||||||
//src.temphtml = "Invalid disk. Please try again."
|
//src.temphtml = "Invalid disk. Please try again."
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
src.disk.data = buffers[bufferId]["data"]
|
var/datum/dna2/record/buf = src.buffers[bufferId]
|
||||||
src.disk.data_type = src.buffers[bufferId]["type"]
|
|
||||||
src.disk.ue = src.buffers[bufferId]["ue"]
|
src.disk.buf = buf
|
||||||
src.disk.owner = src.buffers[bufferId]["owner"]
|
src.disk.name = "data disk - '[buf.dna.real_name]'"
|
||||||
src.disk.name = "data disk - '[src.buffers[bufferId]["owner"]]'"
|
|
||||||
//src.temphtml = "Data saved."
|
//src.temphtml = "Data saved."
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
|
|||||||
125
code/game/dna/genes/disabilities.dm
Normal file
125
code/game/dna/genes/disabilities.dm
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
/////////////////////
|
||||||
|
// DISABILITY GENES
|
||||||
|
//
|
||||||
|
// These activate either a mutation, disability, or sdisability.
|
||||||
|
//
|
||||||
|
// Gene is always activated.
|
||||||
|
/////////////////////
|
||||||
|
|
||||||
|
/datum/dna/gene/disability
|
||||||
|
name="DISABILITY"
|
||||||
|
|
||||||
|
// Mutation to give (or 0)
|
||||||
|
var/mutation=0
|
||||||
|
|
||||||
|
// Disability to give (or 0)
|
||||||
|
var/disability=0
|
||||||
|
|
||||||
|
// SDisability to give (or 0)
|
||||||
|
var/sdisability=0
|
||||||
|
|
||||||
|
// Activation message
|
||||||
|
var/activation_message=""
|
||||||
|
|
||||||
|
// Yay, you're no longer growing 3 arms
|
||||||
|
var/deactivation_message=""
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/can_activate(var/mob/M,var/flags)
|
||||||
|
return 1 // Always set!
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/activate(var/mob/M, var/connected, var/flags)
|
||||||
|
if(mutation && !(mutation in M.mutations))
|
||||||
|
M.mutations.Add(mutation)
|
||||||
|
if(disability)
|
||||||
|
M.disabilities|=disability
|
||||||
|
if(mutation)
|
||||||
|
M.sdisabilities|=sdisability
|
||||||
|
if(activation_message)
|
||||||
|
M << "\red [activation_message]"
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/deactivate(var/mob/M, var/connected, var/flags)
|
||||||
|
if(mutation && (mutation in M.mutations))
|
||||||
|
M.mutations.Remove(mutation)
|
||||||
|
if(disability)
|
||||||
|
M.disabilities-=disability
|
||||||
|
if(mutation)
|
||||||
|
M.sdisabilities-=sdisability
|
||||||
|
if(deactivation_message)
|
||||||
|
M << "\red [deactivation_message]"
|
||||||
|
|
||||||
|
// Note: Doesn't seem to do squat, at the moment.
|
||||||
|
/datum/dna/gene/disability/hallucinate
|
||||||
|
name="Hallucinate"
|
||||||
|
activation_message="Your mind says 'Hello'."
|
||||||
|
mutation=mHallucination
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=HALLUCINATIONBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/epilepsy
|
||||||
|
name="Epilepsy"
|
||||||
|
activation_message="You get a headache."
|
||||||
|
disability=EPILEPSY
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=HEADACHEBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/cough
|
||||||
|
name="Coughing"
|
||||||
|
activation_message="You start coughing."
|
||||||
|
disability=COUGHING
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=COUGHBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/clumsy
|
||||||
|
name="Clumsiness"
|
||||||
|
activation_message="You feel lightheaded."
|
||||||
|
mutation=CLUMSY
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=CLUMSYBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/tourettes
|
||||||
|
name="Tourettes"
|
||||||
|
activation_message="You twitch."
|
||||||
|
disability=TOURETTES
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=TWITCHBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/nervousness
|
||||||
|
name="Nervousness"
|
||||||
|
activation_message="You feel nervous."
|
||||||
|
disability=NERVOUS
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=NERVOUSBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/blindness
|
||||||
|
name="Blindness"
|
||||||
|
activation_message="You can't seem to see anything."
|
||||||
|
sdisability=BLIND
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=BLINDBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/deaf
|
||||||
|
name="Deafness"
|
||||||
|
activation_message="It's kinda quiet."
|
||||||
|
sdisability=DEAF
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=DEAFBLOCK
|
||||||
|
|
||||||
|
activate(var/mob/M, var/connected, var/flags)
|
||||||
|
..(M,connected,flags)
|
||||||
|
M.ear_deaf = 1
|
||||||
|
|
||||||
|
/datum/dna/gene/disability/nearsighted
|
||||||
|
name="Nearsightedness"
|
||||||
|
activation_message="Your eyes feel weird..."
|
||||||
|
disability=NEARSIGHTED
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=GLASSESBLOCK
|
||||||
88
code/game/dna/genes/gene.dm
Normal file
88
code/game/dna/genes/gene.dm
Normal file
@@ -0,0 +1,88 @@
|
|||||||
|
/**
|
||||||
|
* Gene Datum
|
||||||
|
*
|
||||||
|
* domutcheck was getting pretty hairy. This is the solution.
|
||||||
|
*
|
||||||
|
* All genes are stored in a global variable to cut down on memory
|
||||||
|
* usage.
|
||||||
|
*
|
||||||
|
* @author N3X15 <nexisentertainment@gmail.com>
|
||||||
|
*/
|
||||||
|
|
||||||
|
/datum/dna/gene
|
||||||
|
// Display name
|
||||||
|
var/name="BASE GENE"
|
||||||
|
|
||||||
|
// Probably won't get used but why the fuck not
|
||||||
|
var/desc="Oh god who knows what this does."
|
||||||
|
|
||||||
|
// Set in initialize()!
|
||||||
|
// What gene activates this?
|
||||||
|
var/block=0
|
||||||
|
|
||||||
|
// Any of a number of GENE_ flags.
|
||||||
|
var/flags=0
|
||||||
|
|
||||||
|
// Return 1 if we can activate.
|
||||||
|
// HANDLE MUTCHK_FORCED HERE!
|
||||||
|
/datum/dna/gene/proc/can_activate(var/mob/M, var/flags)
|
||||||
|
return 0
|
||||||
|
|
||||||
|
// Called when the gene activates. Do your magic here.
|
||||||
|
/datum/dna/gene/proc/activate(var/mob/M, var/connected, var/flags)
|
||||||
|
return
|
||||||
|
|
||||||
|
// Called when the gene deactivates. Undo your magic here.
|
||||||
|
// Only called when the block is deactivated.
|
||||||
|
/datum/dna/gene/proc/deactivate(var/mob/M, var/connected, var/flags)
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
/////////////////////
|
||||||
|
// BASIC GENES
|
||||||
|
//
|
||||||
|
// These just chuck in a mutation and display a message.
|
||||||
|
//
|
||||||
|
// Gene is activated:
|
||||||
|
// 1. If mutation already exists in mob
|
||||||
|
// 2. If the probability roll succeeds
|
||||||
|
// 3. Activation is forced (done in domutcheck)
|
||||||
|
/////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
/datum/dna/gene/basic
|
||||||
|
name="BASIC GENE"
|
||||||
|
|
||||||
|
// Mutation to give
|
||||||
|
var/mutation=0
|
||||||
|
|
||||||
|
// Activation probability
|
||||||
|
var/activation_prob=45
|
||||||
|
|
||||||
|
// Possible activation messages
|
||||||
|
var/list/activation_messages=list()
|
||||||
|
|
||||||
|
// Possible deactivation messages
|
||||||
|
var/list/deactivation_messages=list()
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/can_activate(var/mob/M,var/flags)
|
||||||
|
if(mutation==0)
|
||||||
|
return 0
|
||||||
|
|
||||||
|
// Probability check
|
||||||
|
if(flags & MUTCHK_FORCED || probinj(activation_prob,(flags&MUTCHK_FORCED)))
|
||||||
|
return 1
|
||||||
|
|
||||||
|
return 0
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/activate(var/mob/M)
|
||||||
|
M.mutations.Add(mutation)
|
||||||
|
if(activation_messages.len)
|
||||||
|
var/msg = pick(activation_messages)
|
||||||
|
M << "\blue [msg]"
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/deactivate(var/mob/M)
|
||||||
|
M.mutations.Remove(mutation)
|
||||||
|
if(deactivation_messages.len)
|
||||||
|
var/msg = pick(deactivation_messages)
|
||||||
|
M << "\red [msg]"
|
||||||
170
code/game/dna/genes/monkey.dm
Normal file
170
code/game/dna/genes/monkey.dm
Normal file
@@ -0,0 +1,170 @@
|
|||||||
|
/datum/dna/gene/monkey
|
||||||
|
name="Monkey"
|
||||||
|
|
||||||
|
/datum/dna/gene/monkey/New()
|
||||||
|
block=MONKEYBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/monkey/can_activate(var/mob/M,var/flags)
|
||||||
|
return istype(M, /mob/living/carbon/human) || istype(M,/mob/living/carbon/monkey)
|
||||||
|
|
||||||
|
/datum/dna/gene/monkey/activate(var/mob/living/M, var/connected, var/flags)
|
||||||
|
if(!istype(M,/mob/living/carbon/human))
|
||||||
|
return
|
||||||
|
var/mob/living/carbon/human/H = M
|
||||||
|
H.monkeyizing = 1
|
||||||
|
var/list/implants = list() //Try to preserve implants.
|
||||||
|
for(var/obj/item/weapon/implant/W in H)
|
||||||
|
implants += W
|
||||||
|
W.loc = null
|
||||||
|
|
||||||
|
if(!connected)
|
||||||
|
for(var/obj/item/W in (H.contents-implants))
|
||||||
|
if (W==H.w_uniform) // will be teared
|
||||||
|
continue
|
||||||
|
H.drop_from_inventory(W)
|
||||||
|
M.monkeyizing = 1
|
||||||
|
M.canmove = 0
|
||||||
|
M.icon = null
|
||||||
|
M.invisibility = 101
|
||||||
|
var/atom/movable/overlay/animation = new( M.loc )
|
||||||
|
animation.icon_state = "blank"
|
||||||
|
animation.icon = 'icons/mob/mob.dmi'
|
||||||
|
animation.master = src
|
||||||
|
flick("h2monkey", animation)
|
||||||
|
sleep(48)
|
||||||
|
del(animation)
|
||||||
|
|
||||||
|
|
||||||
|
var/mob/living/carbon/monkey/O = null
|
||||||
|
if(H.species.primitive)
|
||||||
|
O = new H.species.primitive(src)
|
||||||
|
else
|
||||||
|
H.gib() //Trying to change the species of a creature with no primitive var set is messy.
|
||||||
|
return
|
||||||
|
|
||||||
|
if(M)
|
||||||
|
if (M.dna)
|
||||||
|
O.dna = M.dna
|
||||||
|
M.dna = null
|
||||||
|
|
||||||
|
if (M.suiciding)
|
||||||
|
O.suiciding = M.suiciding
|
||||||
|
M.suiciding = null
|
||||||
|
|
||||||
|
|
||||||
|
for(var/datum/disease/D in M.viruses)
|
||||||
|
O.viruses += D
|
||||||
|
D.affected_mob = O
|
||||||
|
M.viruses -= D
|
||||||
|
|
||||||
|
|
||||||
|
for(var/obj/T in (M.contents-implants))
|
||||||
|
del(T)
|
||||||
|
|
||||||
|
O.loc = M.loc
|
||||||
|
|
||||||
|
if(M.mind)
|
||||||
|
M.mind.transfer_to(O) //transfer our mind to the cute little monkey
|
||||||
|
|
||||||
|
if (connected) //inside dna thing
|
||||||
|
var/obj/machinery/dna_scannernew/C = connected
|
||||||
|
O.loc = C
|
||||||
|
C.occupant = O
|
||||||
|
connected = null
|
||||||
|
O.real_name = text("monkey ([])",copytext(md5(M.real_name), 2, 6))
|
||||||
|
O.take_overall_damage(M.getBruteLoss() + 40, M.getFireLoss())
|
||||||
|
O.adjustToxLoss(M.getToxLoss() + 20)
|
||||||
|
O.adjustOxyLoss(M.getOxyLoss())
|
||||||
|
O.stat = M.stat
|
||||||
|
O.a_intent = "hurt"
|
||||||
|
for (var/obj/item/weapon/implant/I in implants)
|
||||||
|
I.loc = O
|
||||||
|
I.implanted = O
|
||||||
|
// O.update_icon = 1 //queue a full icon update at next life() call
|
||||||
|
del(M)
|
||||||
|
return
|
||||||
|
|
||||||
|
/datum/dna/gene/monkey/deactivate(var/mob/living/M, var/connected, var/flags)
|
||||||
|
if(!istype(M,/mob/living/carbon/monkey))
|
||||||
|
return
|
||||||
|
var/mob/living/carbon/monkey/Mo = M
|
||||||
|
Mo.monkeyizing = 1
|
||||||
|
var/list/implants = list() //Still preserving implants
|
||||||
|
for(var/obj/item/weapon/implant/W in Mo)
|
||||||
|
implants += W
|
||||||
|
W.loc = null
|
||||||
|
if(!connected)
|
||||||
|
for(var/obj/item/W in (Mo.contents-implants))
|
||||||
|
Mo.drop_from_inventory(W)
|
||||||
|
M.monkeyizing = 1
|
||||||
|
M.canmove = 0
|
||||||
|
M.icon = null
|
||||||
|
M.invisibility = 101
|
||||||
|
var/atom/movable/overlay/animation = new( M.loc )
|
||||||
|
animation.icon_state = "blank"
|
||||||
|
animation.icon = 'icons/mob/mob.dmi'
|
||||||
|
animation.master = src
|
||||||
|
flick("monkey2h", animation)
|
||||||
|
sleep(48)
|
||||||
|
del(animation)
|
||||||
|
|
||||||
|
var/mob/living/carbon/human/O = new( src )
|
||||||
|
if(Mo.greaterform)
|
||||||
|
O.set_species(Mo.greaterform)
|
||||||
|
|
||||||
|
if (M.dna.GetUIState(DNA_UI_GENDER))
|
||||||
|
O.gender = FEMALE
|
||||||
|
else
|
||||||
|
O.gender = MALE
|
||||||
|
|
||||||
|
if (M)
|
||||||
|
if (M.dna)
|
||||||
|
O.dna = M.dna
|
||||||
|
M.dna = null
|
||||||
|
|
||||||
|
if (M.suiciding)
|
||||||
|
O.suiciding = M.suiciding
|
||||||
|
M.suiciding = null
|
||||||
|
|
||||||
|
for(var/datum/disease/D in M.viruses)
|
||||||
|
O.viruses += D
|
||||||
|
D.affected_mob = O
|
||||||
|
M.viruses -= D
|
||||||
|
|
||||||
|
//for(var/obj/T in M)
|
||||||
|
// del(T)
|
||||||
|
|
||||||
|
O.loc = M.loc
|
||||||
|
|
||||||
|
if(M.mind)
|
||||||
|
M.mind.transfer_to(O) //transfer our mind to the human
|
||||||
|
|
||||||
|
if (connected) //inside dna thing
|
||||||
|
var/obj/machinery/dna_scannernew/C = connected
|
||||||
|
O.loc = C
|
||||||
|
C.occupant = O
|
||||||
|
connected = null
|
||||||
|
|
||||||
|
var/i
|
||||||
|
while (!i)
|
||||||
|
var/randomname
|
||||||
|
if (O.gender == MALE)
|
||||||
|
randomname = capitalize(pick(first_names_male) + " " + capitalize(pick(last_names)))
|
||||||
|
else
|
||||||
|
randomname = capitalize(pick(first_names_female) + " " + capitalize(pick(last_names)))
|
||||||
|
if (findname(randomname))
|
||||||
|
continue
|
||||||
|
else
|
||||||
|
O.real_name = randomname
|
||||||
|
i++
|
||||||
|
O.UpdateAppearance()
|
||||||
|
O.take_overall_damage(M.getBruteLoss(), M.getFireLoss())
|
||||||
|
O.adjustToxLoss(M.getToxLoss())
|
||||||
|
O.adjustOxyLoss(M.getOxyLoss())
|
||||||
|
O.stat = M.stat
|
||||||
|
for (var/obj/item/weapon/implant/I in implants)
|
||||||
|
I.loc = O
|
||||||
|
I.implanted = O
|
||||||
|
// O.update_icon = 1 //queue a full icon update at next life() call
|
||||||
|
del(M)
|
||||||
|
return
|
||||||
163
code/game/dna/genes/powers.dm
Normal file
163
code/game/dna/genes/powers.dm
Normal file
@@ -0,0 +1,163 @@
|
|||||||
|
///////////////////////////////////
|
||||||
|
// POWERS
|
||||||
|
///////////////////////////////////
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/nobreath
|
||||||
|
name="No Breathing"
|
||||||
|
activation_messages=list("You feel no need to breathe.")
|
||||||
|
mutation=mNobreath
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=NOBREATHBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/remoteview
|
||||||
|
name="Remote Viewing"
|
||||||
|
activation_messages=list("Your mind expands.")
|
||||||
|
mutation=mRemote
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=REMOTEVIEWBLOCK
|
||||||
|
|
||||||
|
activate(var/mob/M, var/connected, var/flags)
|
||||||
|
..(M,connected,flags)
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/remoteobserve
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/regenerate
|
||||||
|
name="Regenerate"
|
||||||
|
activation_messages=list("You feel better.")
|
||||||
|
mutation=mRegen
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=REGENERATEBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/increaserun
|
||||||
|
name="Super Speed"
|
||||||
|
activation_messages=list("Your leg muscles pulsate.")
|
||||||
|
mutation=mRun
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=INCREASERUNBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/remotetalk
|
||||||
|
name="Telepathy"
|
||||||
|
activation_messages=list("You expand your mind outwards.")
|
||||||
|
mutation=mRemotetalk
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=REMOTETALKBLOCK
|
||||||
|
|
||||||
|
activate(var/mob/M, var/connected, var/flags)
|
||||||
|
..(M,connected,flags)
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/remotesay
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/morph
|
||||||
|
name="Morph"
|
||||||
|
activation_messages=list("Your skin feels strange.")
|
||||||
|
mutation=mMorph
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=MORPHBLOCK
|
||||||
|
|
||||||
|
activate(var/mob/M)
|
||||||
|
..(M)
|
||||||
|
M.verbs += /mob/living/carbon/human/proc/morph
|
||||||
|
|
||||||
|
/* Not used on bay
|
||||||
|
/datum/dna/gene/basic/heat_resist
|
||||||
|
name="Heat Resistance"
|
||||||
|
activation_messages=list("Your skin is icy to the touch.")
|
||||||
|
mutation=mHeatres
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=COLDBLOCK
|
||||||
|
|
||||||
|
can_activate(var/mob/M,var/flags)
|
||||||
|
// Probability check
|
||||||
|
var/_prob = 15
|
||||||
|
if(COLD_RESISTANCE in M.mutations)
|
||||||
|
_prob=5
|
||||||
|
if(probinj(_prob,(flags&MUTCHK_FORCED)))
|
||||||
|
return 1
|
||||||
|
*/
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/cold_resist
|
||||||
|
name="Cold Resistance"
|
||||||
|
activation_messages=list("Your body is filled with warmth.")
|
||||||
|
mutation=COLD_RESISTANCE
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=FIREBLOCK
|
||||||
|
|
||||||
|
can_activate(var/mob/M,var/flags)
|
||||||
|
|
||||||
|
// Probability check
|
||||||
|
var/_prob=30
|
||||||
|
//if(mHeatres in M.mutations)
|
||||||
|
// _prob=5
|
||||||
|
if(probinj(_prob,(flags&MUTCHK_FORCED)))
|
||||||
|
return 1
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/noprints
|
||||||
|
name="No Prints"
|
||||||
|
activation_messages=list("Your fingers feel numb.")
|
||||||
|
mutation=mFingerprints
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=NOPRINTSBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/noshock
|
||||||
|
name="Shock Immunity"
|
||||||
|
activation_messages=list("Your skin feels strange.")
|
||||||
|
mutation=mShock
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=SHOCKIMMUNITYBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/midget
|
||||||
|
name="Midget"
|
||||||
|
activation_messages=list("Your skin feels rubbery.")
|
||||||
|
mutation=mSmallsize
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=SMALLSIZEBLOCK
|
||||||
|
|
||||||
|
can_activate(var/mob/M,var/flags)
|
||||||
|
// Can't be big and small.
|
||||||
|
if(HULK in M.mutations)
|
||||||
|
return 0
|
||||||
|
return ..(M,flags)
|
||||||
|
|
||||||
|
activate(var/mob/M, var/connected, var/flags)
|
||||||
|
..(M,connected,flags)
|
||||||
|
M.pass_flags |= 1
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/hulk
|
||||||
|
name="Hulk"
|
||||||
|
activation_messages=list("Your muscles hurt.")
|
||||||
|
mutation=HULK
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=HULKBLOCK
|
||||||
|
|
||||||
|
can_activate(var/mob/M,var/flags)
|
||||||
|
// Can't be big and small.
|
||||||
|
if(mSmallsize in M.mutations)
|
||||||
|
return 0
|
||||||
|
return ..(M,flags)
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/xray
|
||||||
|
name="X-Ray Vision"
|
||||||
|
activation_messages=list("The walls suddenly disappear.")
|
||||||
|
mutation=XRAY
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=XRAYBLOCK
|
||||||
|
|
||||||
|
/datum/dna/gene/basic/tk
|
||||||
|
name="Telekenesis"
|
||||||
|
activation_messages=list("You feel smarter.")
|
||||||
|
mutation=TK
|
||||||
|
activation_prob=15
|
||||||
|
|
||||||
|
New()
|
||||||
|
block=TELEBLOCK
|
||||||
@@ -96,8 +96,20 @@
|
|||||||
//SHOCKIMMUNITYBLOCK = getAssignedBlock("SHOCKIMMUNITY", numsToAssign)
|
//SHOCKIMMUNITYBLOCK = getAssignedBlock("SHOCKIMMUNITY", numsToAssign)
|
||||||
//SMALLSIZEBLOCK = getAssignedBlock("SMALLSIZE", numsToAssign, DNA_HARD_BOUNDS)
|
//SMALLSIZEBLOCK = getAssignedBlock("SMALLSIZE", numsToAssign, DNA_HARD_BOUNDS)
|
||||||
|
|
||||||
|
// And the genes that actually do the work. (domutcheck improvements)
|
||||||
|
var/list/blocks_assigned[STRUCDNASIZE]
|
||||||
|
for(var/gene_type in typesof(/datum/dna/gene))
|
||||||
|
var/datum/dna/gene/G = new gene_type
|
||||||
|
if(G.block)
|
||||||
|
if(G.block in blocks_assigned)
|
||||||
|
warning("DNA2: Gene [G.name] trying to use already-assigned block [G.block] (used by [english_list(blocks_assigned[G.block])])")
|
||||||
|
dna_genes.Add(G)
|
||||||
|
var/list/assignedToBlock[0]
|
||||||
|
if(blocks_assigned[G.block])
|
||||||
|
assignedToBlock=blocks_assigned[G.block]
|
||||||
|
assignedToBlock.Add(G.name)
|
||||||
|
blocks_assigned[G.block]=assignedToBlock
|
||||||
|
testing("DNA2: Gene [G.name] assigned to block [G.block].")
|
||||||
|
|
||||||
// HIDDEN MUTATIONS / SUPERPOWERS INITIALIZTION
|
// HIDDEN MUTATIONS / SUPERPOWERS INITIALIZTION
|
||||||
|
|
||||||
|
|||||||
@@ -30,25 +30,42 @@
|
|||||||
icon_state = "datadisk0" //Gosh I hope syndies don't mistake them for the nuke disk.
|
icon_state = "datadisk0" //Gosh I hope syndies don't mistake them for the nuke disk.
|
||||||
item_state = "card-id"
|
item_state = "card-id"
|
||||||
w_class = 1.0
|
w_class = 1.0
|
||||||
var/data = ""
|
var/datum/dna2/record/buf=null
|
||||||
var/ue = 0
|
|
||||||
var/data_type = "ui" //ui|se
|
|
||||||
var/owner = "God Emperor of Mankind"
|
|
||||||
var/read_only = 0 //Well,it's still a floppy disk
|
var/read_only = 0 //Well,it's still a floppy disk
|
||||||
|
|
||||||
|
/obj/item/weapon/disk/data/proc/Initialize()
|
||||||
|
buf = new
|
||||||
|
buf.dna=new
|
||||||
|
|
||||||
/obj/item/weapon/disk/data/demo
|
/obj/item/weapon/disk/data/demo
|
||||||
name = "data disk - 'God Emperor of Mankind'"
|
name = "data disk - 'God Emperor of Mankind'"
|
||||||
data = "066000033000000000AF00330660FF4DB002690"
|
|
||||||
//data = "0C80C80C80C80C80C8000000000000161FBDDEF" - Farmer Jeff
|
|
||||||
ue = 1
|
|
||||||
read_only = 1
|
read_only = 1
|
||||||
|
|
||||||
|
New()
|
||||||
|
Initialize()
|
||||||
|
buf.types=DNA2_BUF_UE|DNA2_BUF_UI
|
||||||
|
//data = "066000033000000000AF00330660FF4DB002690"
|
||||||
|
//data = "0C80C80C80C80C80C8000000000000161FBDDEF" - Farmer Jeff
|
||||||
|
buf.dna.real_name="God Emperor of Mankind"
|
||||||
|
buf.dna.unique_enzymes = md5(buf.dna.real_name)
|
||||||
|
buf.dna.UI=list(0x066,0x000,0x033,0x000,0x000,0x000,0xAF0,0x033,0x066,0x0FF,0x4DB,0x002,0x690)
|
||||||
|
//buf.dna.UI=list(0x0C8,0x0C8,0x0C8,0x0C8,0x0C8,0x0C8,0x000,0x000,0x000,0x000,0x161,0xFBD,0xDEF) // Farmer Jeff
|
||||||
|
buf.dna.UpdateUI()
|
||||||
|
|
||||||
/obj/item/weapon/disk/data/monkey
|
/obj/item/weapon/disk/data/monkey
|
||||||
name = "data disk - 'Mr. Muggles'"
|
name = "data disk - 'Mr. Muggles'"
|
||||||
data_type = "se"
|
|
||||||
data = "0983E840344C39F4B059D5145FC5785DC6406A4FFF"
|
|
||||||
read_only = 1
|
read_only = 1
|
||||||
|
|
||||||
|
New()
|
||||||
|
Initialize()
|
||||||
|
buf.types=DNA2_BUF_SE
|
||||||
|
var/list/new_SE=list(0x098,0x3E8,0x403,0x44C,0x39F,0x4B0,0x59D,0x514,0x5FC,0x578,0x5DC,0x640,0x6A4)
|
||||||
|
for(var/i=new_SE.len;i<=STRUCDNASIZE;i++)
|
||||||
|
new_SE += rand(1,1024)
|
||||||
|
buf.dna.SE=new_SE
|
||||||
|
buf.dna.SetSEValue(MONKEYBLOCK,0xFFF)
|
||||||
|
|
||||||
|
|
||||||
//Find a dead mob with a brain and client.
|
//Find a dead mob with a brain and client.
|
||||||
/proc/find_dead_player(var/find_key)
|
/proc/find_dead_player(var/find_key)
|
||||||
if (isnull(find_key))
|
if (isnull(find_key))
|
||||||
@@ -102,6 +119,7 @@
|
|||||||
return src.healthstring
|
return src.healthstring
|
||||||
|
|
||||||
/obj/machinery/clonepod/attack_ai(mob/user as mob)
|
/obj/machinery/clonepod/attack_ai(mob/user as mob)
|
||||||
|
src.add_hiddenprint(user)
|
||||||
return attack_hand(user)
|
return attack_hand(user)
|
||||||
/obj/machinery/clonepod/attack_paw(mob/user as mob)
|
/obj/machinery/clonepod/attack_paw(mob/user as mob)
|
||||||
return attack_hand(user)
|
return attack_hand(user)
|
||||||
@@ -116,20 +134,20 @@
|
|||||||
//Clonepod
|
//Clonepod
|
||||||
|
|
||||||
//Start growing a human clone in the pod!
|
//Start growing a human clone in the pod!
|
||||||
/obj/machinery/clonepod/proc/growclone(var/ckey, var/clonename, var/list/ui, var/list/se, var/mindref, var/datum/species/mrace, var/languages)
|
/obj/machinery/clonepod/proc/growclone(var/datum/dna2/record/R)
|
||||||
if(mess || attempting)
|
if(mess || attempting)
|
||||||
return 0
|
return 0
|
||||||
var/datum/mind/clonemind = locate(mindref)
|
var/datum/mind/clonemind = locate(R.mind)
|
||||||
if(!istype(clonemind,/datum/mind)) //not a mind
|
if(!istype(clonemind,/datum/mind)) //not a mind
|
||||||
return 0
|
return 0
|
||||||
if( clonemind.current && clonemind.current.stat != DEAD ) //mind is associated with a non-dead body
|
if( clonemind.current && clonemind.current.stat != DEAD ) //mind is associated with a non-dead body
|
||||||
return 0
|
return 0
|
||||||
if(clonemind.active) //somebody is using that mind
|
if(clonemind.active) //somebody is using that mind
|
||||||
if( ckey(clonemind.key)!=ckey )
|
if( ckey(clonemind.key)!=R.ckey )
|
||||||
return 0
|
return 0
|
||||||
else
|
else
|
||||||
for(var/mob/dead/observer/G in player_list)
|
for(var/mob/dead/observer/G in player_list)
|
||||||
if(G.ckey == ckey)
|
if(G.ckey == R.ckey)
|
||||||
if(G.can_reenter_corpse)
|
if(G.can_reenter_corpse)
|
||||||
break
|
break
|
||||||
else
|
else
|
||||||
@@ -147,9 +165,9 @@
|
|||||||
var/mob/living/carbon/human/H = new /mob/living/carbon/human(src)
|
var/mob/living/carbon/human/H = new /mob/living/carbon/human(src)
|
||||||
occupant = H
|
occupant = H
|
||||||
|
|
||||||
if(!clonename) //to prevent null names
|
if(!R.dna.real_name) //to prevent null names
|
||||||
clonename = "clone ([rand(0,999)])"
|
R.dna.real_name = "clone ([rand(0,999)])"
|
||||||
H.real_name = clonename
|
H.real_name = R.dna.real_name
|
||||||
|
|
||||||
src.icon_state = "pod_1"
|
src.icon_state = "pod_1"
|
||||||
//Get the clone body ready
|
//Get the clone body ready
|
||||||
@@ -161,7 +179,7 @@
|
|||||||
H.updatehealth()
|
H.updatehealth()
|
||||||
|
|
||||||
clonemind.transfer_to(H)
|
clonemind.transfer_to(H)
|
||||||
H.ckey = ckey
|
H.ckey = R.ckey
|
||||||
H << "<span class='notice'><b>Consciousness slowly creeps over you as your body regenerates.</b><br><i>So this is what cloning feels like?</i></span>"
|
H << "<span class='notice'><b>Consciousness slowly creeps over you as your body regenerates.</b><br><i>So this is what cloning feels like?</i></span>"
|
||||||
|
|
||||||
// -- Mode/mind specific stuff goes here
|
// -- Mode/mind specific stuff goes here
|
||||||
@@ -180,24 +198,24 @@
|
|||||||
|
|
||||||
// -- End mode specific stuff
|
// -- End mode specific stuff
|
||||||
|
|
||||||
if(!H.dna)
|
if(!R.dna)
|
||||||
H.dna = new /datum/dna()
|
H.dna = new /datum/dna()
|
||||||
H.dna.real_name = H.real_name
|
H.dna.real_name = H.real_name
|
||||||
if(ui)
|
else
|
||||||
H.UpdateAppearance(ui)
|
H.dna=R.dna
|
||||||
if(se)
|
H.UpdateAppearance()
|
||||||
H.dna.SE = se
|
randmutb(H) //Sometimes the clones come out wrong.
|
||||||
H.dna.UpdateSE()
|
H.dna.UpdateSE()
|
||||||
randmutb(H) //Sometimes the clones come out wrong.
|
H.dna.UpdateUI()
|
||||||
|
|
||||||
H.f_style = "Shaved"
|
H.f_style = "Shaved"
|
||||||
if(mrace.name == "Human") //no more xenos losing ears/tentacles
|
if(R.dna.species == "Human") //no more xenos losing ears/tentacles
|
||||||
H.h_style = pick("Bedhead", "Bedhead 2", "Bedhead 3")
|
H.h_style = pick("Bedhead", "Bedhead 2", "Bedhead 3")
|
||||||
|
|
||||||
H.species = mrace
|
H.set_species(R.dna.species)
|
||||||
for(var/datum/language/L in languages)
|
|
||||||
H.add_language(L.name)
|
//for(var/datum/language/L in languages)
|
||||||
H.update_mutantrace()
|
// H.add_language(L.name)
|
||||||
H.suiciding = 0
|
H.suiciding = 0
|
||||||
src.attempting = 0
|
src.attempting = 0
|
||||||
return 1
|
return 1
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
var/scantemp = "Scanner unoccupied"
|
var/scantemp = "Scanner unoccupied"
|
||||||
var/menu = 1 //Which menu screen to display
|
var/menu = 1 //Which menu screen to display
|
||||||
var/list/records = list()
|
var/list/records = list()
|
||||||
var/datum/data/record/active_record = null
|
var/datum/dna2/record/active_record = null
|
||||||
var/obj/item/weapon/disk/data/diskette = null //Mostly so the geneticist can steal everything.
|
var/obj/item/weapon/disk/data/diskette = null //Mostly so the geneticist can steal everything.
|
||||||
var/loading = 0 // Nice loading text
|
var/loading = 0 // Nice loading text
|
||||||
|
|
||||||
@@ -136,8 +136,8 @@
|
|||||||
if(2)
|
if(2)
|
||||||
dat += "<h4>Current records</h4>"
|
dat += "<h4>Current records</h4>"
|
||||||
dat += "<a href='byond://?src=\ref[src];menu=1'>Back</a><br><br>"
|
dat += "<a href='byond://?src=\ref[src];menu=1'>Back</a><br><br>"
|
||||||
for(var/datum/data/record/R in src.records)
|
for(var/datum/dna2/record/R in src.records)
|
||||||
dat += "<a href='byond://?src=\ref[src];view_rec=\ref[R]'>[R.fields["id"]]-[R.fields["name"]]</a><br>"
|
dat += "<li><a href='byond://?src=\ref[src];view_rec=\ref[R]'>[R.dna.real_name]</a><li>"
|
||||||
|
|
||||||
if(3)
|
if(3)
|
||||||
dat += "<h4>Selected Record</h4>"
|
dat += "<h4>Selected Record</h4>"
|
||||||
@@ -146,10 +146,11 @@
|
|||||||
if (!src.active_record)
|
if (!src.active_record)
|
||||||
dat += "<font color=red>ERROR: Record not found.</font>"
|
dat += "<font color=red>ERROR: Record not found.</font>"
|
||||||
else
|
else
|
||||||
dat += "<br><font size=1><a href='byond://?src=\ref[src];del_rec=1'>Delete Record</a></font><br>"
|
dat += {"<br><font size=1><a href='byond://?src=\ref[src];del_rec=1'>Delete Record</a></font><br>
|
||||||
dat += "<b>Name:</b> [src.active_record.fields["name"]]<br>"
|
<b>Name:</b> [src.active_record.dna.real_name]<br>"}
|
||||||
|
var/obj/item/weapon/implant/health/H = null
|
||||||
var/obj/item/weapon/implant/health/H = locate(src.active_record.fields["imp"])
|
if(src.active_record.implant)
|
||||||
|
H=locate(src.active_record.implant)
|
||||||
|
|
||||||
if ((H) && (istype(H)))
|
if ((H) && (istype(H)))
|
||||||
dat += "<b>Health:</b> [H.sensehealth()] | OXY-BURN-TOX-BRUTE<br>"
|
dat += "<b>Health:</b> [H.sensehealth()] | OXY-BURN-TOX-BRUTE<br>"
|
||||||
@@ -166,13 +167,13 @@
|
|||||||
else
|
else
|
||||||
dat += "<br>" //Keeping a line empty for appearances I guess.
|
dat += "<br>" //Keeping a line empty for appearances I guess.
|
||||||
|
|
||||||
dat += {"<b>UI:</b> [src.active_record.fields["UI"]]<br>
|
dat += {"<b>UI:</b> [src.active_record.dna.uni_identity]<br>
|
||||||
<b>SE:</b> [src.active_record.fields["SE"]]<br><br>"}
|
<b>SE:</b> [src.active_record.dna.struc_enzymes]<br><br>"}
|
||||||
|
|
||||||
if(pod1 && pod1.biomass >= CLONE_BIOMASS)
|
if(pod1 && pod1.biomass >= CLONE_BIOMASS)
|
||||||
dat += {"<a href='byond://?src=\ref[src];clone=\ref[src.active_record]'>Clone</a><br>"}
|
dat += {"<a href='byond://?src=\ref[src];clone=\ref[src.active_record]'>Clone</a><br>"}
|
||||||
else
|
else
|
||||||
dat += {"<b>Unsufficient biomass</b><br>"}
|
dat += {"<b>Insufficient biomass</b><br>"}
|
||||||
|
|
||||||
if(4)
|
if(4)
|
||||||
if (!src.active_record)
|
if (!src.active_record)
|
||||||
@@ -217,8 +218,8 @@
|
|||||||
|
|
||||||
else if (href_list["view_rec"])
|
else if (href_list["view_rec"])
|
||||||
src.active_record = locate(href_list["view_rec"])
|
src.active_record = locate(href_list["view_rec"])
|
||||||
if(istype(src.active_record,/datum/data/record))
|
if(istype(src.active_record,/datum/dna2/record))
|
||||||
if ((isnull(src.active_record.fields["ckey"])) || (src.active_record.fields["ckey"] == ""))
|
if ((isnull(src.active_record.ckey)))
|
||||||
del(src.active_record)
|
del(src.active_record)
|
||||||
src.temp = "ERROR: Record Corrupt"
|
src.temp = "ERROR: Record Corrupt"
|
||||||
else
|
else
|
||||||
@@ -248,7 +249,7 @@
|
|||||||
else if (href_list["disk"]) //Load or eject.
|
else if (href_list["disk"]) //Load or eject.
|
||||||
switch(href_list["disk"])
|
switch(href_list["disk"])
|
||||||
if("load")
|
if("load")
|
||||||
if ((isnull(src.diskette)) || (src.diskette.data == ""))
|
if ((isnull(src.diskette)) || isnull(src.diskette.buf))
|
||||||
src.temp = "Load error."
|
src.temp = "Load error."
|
||||||
src.updateUsrDialog()
|
src.updateUsrDialog()
|
||||||
return
|
return
|
||||||
@@ -258,12 +259,7 @@
|
|||||||
src.updateUsrDialog()
|
src.updateUsrDialog()
|
||||||
return
|
return
|
||||||
|
|
||||||
if (src.diskette.data_type == "ui")
|
src.active_record = src.diskette.buf
|
||||||
src.active_record.fields["UI"] = src.diskette.data
|
|
||||||
if (src.diskette.ue)
|
|
||||||
src.active_record.fields["name"] = src.diskette.owner
|
|
||||||
else if (src.diskette.data_type == "se")
|
|
||||||
src.active_record.fields["SE"] = src.diskette.data
|
|
||||||
|
|
||||||
src.temp = "Load successful."
|
src.temp = "Load successful."
|
||||||
if("eject")
|
if("eject")
|
||||||
@@ -277,28 +273,24 @@
|
|||||||
src.updateUsrDialog()
|
src.updateUsrDialog()
|
||||||
return
|
return
|
||||||
|
|
||||||
|
// DNA2 makes things a little simpler.
|
||||||
|
src.diskette.buf=src.active_record
|
||||||
|
src.diskette.buf.types=0
|
||||||
switch(href_list["save_disk"]) //Save as Ui/Ui+Ue/Se
|
switch(href_list["save_disk"]) //Save as Ui/Ui+Ue/Se
|
||||||
if("ui")
|
if("ui")
|
||||||
src.diskette.data = src.active_record.fields["UI"]
|
src.diskette.buf.types=DNA2_BUF_UI
|
||||||
src.diskette.ue = 0
|
|
||||||
src.diskette.data_type = "ui"
|
|
||||||
if("ue")
|
if("ue")
|
||||||
src.diskette.data = src.active_record.fields["UI"]
|
src.diskette.buf.types=DNA2_BUF_UI|DNA2_BUF_UE
|
||||||
src.diskette.ue = 1
|
|
||||||
src.diskette.data_type = "ui"
|
|
||||||
if("se")
|
if("se")
|
||||||
src.diskette.data = src.active_record.fields["SE"]
|
src.diskette.buf.types=DNA2_BUF_SE
|
||||||
src.diskette.ue = 0
|
src.diskette.name = "data disk - '[src.active_record.dna.real_name]'"
|
||||||
src.diskette.data_type = "se"
|
|
||||||
src.diskette.owner = src.active_record.fields["name"]
|
|
||||||
src.diskette.name = "data disk - '[src.diskette.owner]'"
|
|
||||||
src.temp = "Save \[[href_list["save_disk"]]\] successful."
|
src.temp = "Save \[[href_list["save_disk"]]\] successful."
|
||||||
|
|
||||||
else if (href_list["refresh"])
|
else if (href_list["refresh"])
|
||||||
src.updateUsrDialog()
|
src.updateUsrDialog()
|
||||||
|
|
||||||
else if (href_list["clone"])
|
else if (href_list["clone"])
|
||||||
var/datum/data/record/C = locate(href_list["clone"])
|
var/datum/dna2/record/C = locate(href_list["clone"])
|
||||||
//Look for that player! They better be dead!
|
//Look for that player! They better be dead!
|
||||||
if(istype(C))
|
if(istype(C))
|
||||||
//Can't clone without someone to clone. Or a pod. Or if the pod is busy. Or full of gibs.
|
//Can't clone without someone to clone. Or a pod. Or if the pod is busy. Or full of gibs.
|
||||||
@@ -313,17 +305,17 @@
|
|||||||
else if(!config.revival_cloning)
|
else if(!config.revival_cloning)
|
||||||
temp = "Error: Unable to initiate cloning cycle."
|
temp = "Error: Unable to initiate cloning cycle."
|
||||||
|
|
||||||
else if(pod1.growclone(C.fields["ckey"], C.fields["name"], C.fields["UI"], C.fields["SE"], C.fields["mind"], C.fields["mrace"], C.fields["languages"]))
|
else if(pod1.growclone(C))
|
||||||
temp = "Initiating cloning cycle..."
|
temp = "Initiating cloning cycle..."
|
||||||
records.Remove(C)
|
records.Remove(C)
|
||||||
del(C)
|
del(C)
|
||||||
menu = 1
|
menu = 1
|
||||||
else
|
else
|
||||||
|
|
||||||
var/mob/selected = find_dead_player("[C.fields["ckey"]]")
|
var/mob/selected = find_dead_player("[C.ckey]")
|
||||||
selected << 'sound/machines/chime.ogg' //probably not the best sound but I think it's reasonable
|
selected << 'sound/machines/chime.ogg' //probably not the best sound but I think it's reasonable
|
||||||
var/answer = alert(selected,"Do you want to return to life?","Cloning","Yes","No")
|
var/answer = alert(selected,"Do you want to return to life?","Cloning","Yes","No")
|
||||||
if(answer != "No" && pod1.growclone(C.fields["ckey"], C.fields["name"], C.fields["UI"], C.fields["SE"], C.fields["mind"], C.fields["mrace"], C.fields["languages"], C.fields["interface"]))
|
if(answer != "No" && pod1.growclone(C))
|
||||||
temp = "Initiating cloning cycle..."
|
temp = "Initiating cloning cycle..."
|
||||||
records.Remove(C)
|
records.Remove(C)
|
||||||
del(C)
|
del(C)
|
||||||
@@ -363,27 +355,25 @@
|
|||||||
|
|
||||||
subject.dna.check_integrity()
|
subject.dna.check_integrity()
|
||||||
|
|
||||||
var/datum/data/record/R = new /datum/data/record( )
|
var/datum/dna2/record/R = new /datum/dna2/record()
|
||||||
R.fields["mrace"] = subject.species
|
R.dna=subject.dna
|
||||||
R.fields["ckey"] = subject.ckey
|
R.ckey = subject.ckey
|
||||||
R.fields["name"] = subject.real_name
|
R.id= copytext(md5(subject.real_name), 2, 6)
|
||||||
R.fields["id"] = copytext(md5(subject.real_name), 2, 6)
|
R.name=R.dna.real_name
|
||||||
R.fields["UI"] = subject.dna.UI
|
R.types=DNA2_BUF_UI|DNA2_BUF_UE|DNA2_BUF_SE
|
||||||
R.fields["SE"] = subject.dna.SE
|
|
||||||
R.fields["languages"] = subject.languages
|
|
||||||
|
|
||||||
//Add an implant if needed
|
//Add an implant if needed
|
||||||
var/obj/item/weapon/implant/health/imp = locate(/obj/item/weapon/implant/health, subject)
|
var/obj/item/weapon/implant/health/imp = locate(/obj/item/weapon/implant/health, subject)
|
||||||
if (isnull(imp))
|
if (isnull(imp))
|
||||||
imp = new /obj/item/weapon/implant/health(subject)
|
imp = new /obj/item/weapon/implant/health(subject)
|
||||||
imp.implanted = subject
|
imp.implanted = subject
|
||||||
R.fields["imp"] = "\ref[imp]"
|
R.implant = "\ref[imp]"
|
||||||
//Update it if needed
|
//Update it if needed
|
||||||
else
|
else
|
||||||
R.fields["imp"] = "\ref[imp]"
|
R.implant = "\ref[imp]"
|
||||||
|
|
||||||
if (!isnull(subject.mind)) //Save that mind so traitors can continue traitoring after cloning.
|
if (!isnull(subject.mind)) //Save that mind so traitors can continue traitoring after cloning.
|
||||||
R.fields["mind"] = "\ref[subject.mind]"
|
R.mind = "\ref[subject.mind]"
|
||||||
|
|
||||||
src.records += R
|
src.records += R
|
||||||
scantemp = "Subject successfully scanned."
|
scantemp = "Subject successfully scanned."
|
||||||
@@ -391,8 +381,8 @@
|
|||||||
//Find a specific record by key.
|
//Find a specific record by key.
|
||||||
/obj/machinery/computer/cloning/proc/find_record(var/find_key)
|
/obj/machinery/computer/cloning/proc/find_record(var/find_key)
|
||||||
var/selected_record = null
|
var/selected_record = null
|
||||||
for(var/datum/data/record/R in src.records)
|
for(var/datum/dna2/record/R in src.records)
|
||||||
if (R.fields["ckey"] == find_key)
|
if (R.ckey == find_key)
|
||||||
selected_record = R
|
selected_record = R
|
||||||
break
|
break
|
||||||
return selected_record
|
return selected_record
|
||||||
|
|||||||
@@ -3,11 +3,8 @@
|
|||||||
desc = "This injects the person with DNA."
|
desc = "This injects the person with DNA."
|
||||||
icon = 'icons/obj/items.dmi'
|
icon = 'icons/obj/items.dmi'
|
||||||
icon_state = "dnainjector"
|
icon_state = "dnainjector"
|
||||||
var/dnatype = null
|
var/block=0
|
||||||
var/list/dna = null
|
var/datum/dna2/record/buf=null
|
||||||
var/block = null
|
|
||||||
var/owner = null
|
|
||||||
var/ue = null
|
|
||||||
var/s_time = 10.0
|
var/s_time = 10.0
|
||||||
throw_speed = 1
|
throw_speed = 1
|
||||||
throw_range = 5
|
throw_range = 5
|
||||||
@@ -17,57 +14,76 @@
|
|||||||
var/is_bullet = 0
|
var/is_bullet = 0
|
||||||
var/inuse = 0
|
var/inuse = 0
|
||||||
|
|
||||||
|
// USE ONLY IN PREMADE SYRINGES. WILL NOT WORK OTHERWISE.
|
||||||
|
var/datatype=0
|
||||||
|
var/value=0
|
||||||
|
|
||||||
|
/obj/item/weapon/dnainjector/New()
|
||||||
|
if(datatype && block)
|
||||||
|
buf=new
|
||||||
|
buf.dna=new
|
||||||
|
buf.types = datatype
|
||||||
|
buf.dna.ResetSE()
|
||||||
|
//testing("[name]: DNA2 SE blocks prior to SetValue: [english_list(buf.dna.SE)]")
|
||||||
|
SetValue(src.value)
|
||||||
|
//testing("[name]: DNA2 SE blocks after SetValue: [english_list(buf.dna.SE)]")
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/attack_paw(mob/user as mob)
|
/obj/item/weapon/dnainjector/attack_paw(mob/user as mob)
|
||||||
return attack_hand(user)
|
return attack_hand(user)
|
||||||
|
|
||||||
|
/obj/item/weapon/dnainjector/proc/GetRealBlock(var/selblock)
|
||||||
|
if(selblock==0)
|
||||||
|
return block
|
||||||
|
else
|
||||||
|
return selblock
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/proc/GetState(var/selblock=0)
|
/obj/item/weapon/dnainjector/proc/GetState(var/selblock=0)
|
||||||
var/real_block
|
var/real_block=GetRealBlock(selblock)
|
||||||
if(!selblock)
|
if(buf.types&DNA2_BUF_SE)
|
||||||
real_block=block
|
return buf.dna.GetSEState(real_block)
|
||||||
selblock=1
|
|
||||||
else
|
else
|
||||||
real_block=selblock
|
return buf.dna.GetUIState(real_block)
|
||||||
var/list/BOUNDS = GetDNABounds(real_block)
|
|
||||||
return dna[selblock] > BOUNDS[DNA_ON_LOWERBOUND]
|
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/proc/SetState(var/on, var/selblock=0)
|
/obj/item/weapon/dnainjector/proc/SetState(var/on, var/selblock=0)
|
||||||
var/real_block
|
var/real_block=GetRealBlock(selblock)
|
||||||
if(!selblock)
|
if(buf.types&DNA2_BUF_SE)
|
||||||
real_block=block
|
return buf.dna.SetSEState(real_block,on)
|
||||||
selblock=1
|
|
||||||
else
|
else
|
||||||
real_block=selblock
|
return buf.dna.SetUIState(real_block,on)
|
||||||
var/list/BOUNDS=GetDNABounds(real_block)
|
|
||||||
var/val
|
|
||||||
if(on)
|
|
||||||
val=rand(BOUNDS[DNA_ON_LOWERBOUND],BOUNDS[DNA_ON_UPPERBOUND])
|
|
||||||
else
|
|
||||||
val=rand(BOUNDS[DNA_OFF_LOWERBOUND],BOUNDS[DNA_OFF_UPPERBOUND])
|
|
||||||
dna[selblock]=val
|
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/proc/GetValue(var/block=1)
|
/obj/item/weapon/dnainjector/proc/GetValue(var/selblock=0)
|
||||||
return dna[block]
|
var/real_block=GetRealBlock(selblock)
|
||||||
|
if(buf.types&DNA2_BUF_SE)
|
||||||
|
return buf.dna.GetSEValue(real_block)
|
||||||
|
else
|
||||||
|
return buf.dna.GetUIValue(real_block)
|
||||||
|
|
||||||
|
/obj/item/weapon/dnainjector/proc/SetValue(var/val,var/selblock=0)
|
||||||
|
var/real_block=GetRealBlock(selblock)
|
||||||
|
if(buf.types&DNA2_BUF_SE)
|
||||||
|
return buf.dna.SetSEValue(real_block,val)
|
||||||
|
else
|
||||||
|
return buf.dna.SetUIValue(real_block,val)
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/proc/inject(mob/M as mob, mob/user as mob)
|
/obj/item/weapon/dnainjector/proc/inject(mob/M as mob, mob/user as mob)
|
||||||
if(istype(M,/mob/living))
|
if(istype(M,/mob/living))
|
||||||
M.radiation += rand(5,20)
|
M.radiation += rand(5,20)
|
||||||
|
|
||||||
if (!(NOCLONE in M.mutations)) // prevents drained people from having their DNA changed
|
if (!(NOCLONE in M.mutations)) // prevents drained people from having their DNA changed
|
||||||
if (dnatype == "ui")
|
if (buf.types & DNA2_BUF_UI)
|
||||||
if (!block) //isolated block?
|
if (!block) //isolated block?
|
||||||
M.UpdateAppearance(dna)
|
M.UpdateAppearance(buf.dna)
|
||||||
if (ue) //unique enzymes? yes
|
if (buf.types & DNA2_BUF_UE) //unique enzymes? yes
|
||||||
M.real_name = ue
|
M.real_name = buf.dna.real_name
|
||||||
M.name = ue
|
M.name = buf.dna.real_name
|
||||||
uses--
|
uses--
|
||||||
else
|
else
|
||||||
M.dna.SetUIValue(block,src.GetValue())
|
M.dna.SetUIValue(block,src.GetValue())
|
||||||
M.UpdateAppearance()
|
M.UpdateAppearance()
|
||||||
uses--
|
uses--
|
||||||
if (dnatype == "se")
|
if (buf.types & DNA2_BUF_SE)
|
||||||
if (!block) //isolated block?
|
if (!block) //isolated block?
|
||||||
M.dna.SE = dna
|
M.dna.SE = buf.dna.SE
|
||||||
M.dna.UpdateSE()
|
M.dna.UpdateSE()
|
||||||
else
|
else
|
||||||
M.dna.SetSEValue(block,src.GetValue())
|
M.dna.SetSEValue(block,src.GetValue())
|
||||||
@@ -107,15 +123,24 @@
|
|||||||
spawn(50) // Not the best fix. There should be an failure proc, for /effect/equip_e/, which is called when the first initital checks fail
|
spawn(50) // Not the best fix. There should be an failure proc, for /effect/equip_e/, which is called when the first initital checks fail
|
||||||
inuse = 0
|
inuse = 0
|
||||||
M.requests += O
|
M.requests += O
|
||||||
if (dnatype == "se")
|
if (buf.types & DNA2_BUF_SE)
|
||||||
// So you're checking for 14, and yet MONKEYBLOCK is 27 in globals.dm,
|
if(block)// Isolated injector
|
||||||
// and domutcheck checks MONKEYBLOCK...? wat. - N3X
|
testing("Isolated block [block] injector with contents: [GetValue()]")
|
||||||
//if (isblockon(getblock(dna, 14,3),14) && istype(M, /mob/living/carbon/human))
|
if (GetState() && block == MONKEYBLOCK && istype(M, /mob/living/carbon/human) )
|
||||||
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human) )
|
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||||
msg_admin_attack("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY) (<A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[user.x];Y=[user.y];Z=[user.z]'>JMP</a>)")
|
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||||
|
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||||
|
else
|
||||||
|
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||||
else
|
else
|
||||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
testing("DNA injector with contents: [english_list(buf.dna.SE)]")
|
||||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human) )
|
||||||
|
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||||
|
log_attack("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||||
|
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||||
|
else
|
||||||
|
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||||
|
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||||
else
|
else
|
||||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||||
@@ -132,15 +157,24 @@
|
|||||||
if (!(istype(M, /mob/living/carbon/human) || istype(M, /mob/living/carbon/monkey)))
|
if (!(istype(M, /mob/living/carbon/human) || istype(M, /mob/living/carbon/monkey)))
|
||||||
user << "\red Apparently it didn't work."
|
user << "\red Apparently it didn't work."
|
||||||
return
|
return
|
||||||
if (dnatype == "se")
|
|
||||||
// And again... ?
|
if (buf.types & DNA2_BUF_SE)
|
||||||
//if (isblockon(getblock(dna, 14,3),14) && istype(M, /mob/living/carbon/human))
|
if(block)// Isolated injector
|
||||||
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human))
|
testing("Isolated block [block] injector with contents: [GetValue()]")
|
||||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
if (GetState() && block == MONKEYBLOCK && istype(M, /mob/living/carbon/human) )
|
||||||
log_game("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||||
|
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||||
|
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||||
|
else
|
||||||
|
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||||
else
|
else
|
||||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
testing("DNA injector with contents: [english_list(buf.dna.SE)]")
|
||||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human))
|
||||||
|
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||||
|
log_game("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||||
|
else
|
||||||
|
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||||
|
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||||
else
|
else
|
||||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||||
@@ -165,460 +199,462 @@
|
|||||||
/obj/item/weapon/dnainjector/hulkmut
|
/obj/item/weapon/dnainjector/hulkmut
|
||||||
name = "DNA-Injector (Hulk)"
|
name = "DNA-Injector (Hulk)"
|
||||||
desc = "This will make you big and strong, but give you a bad skin condition."
|
desc = "This will make you big and strong, but give you a bad skin condition."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HULKBLOCK
|
block = HULKBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antihulk
|
/obj/item/weapon/dnainjector/antihulk
|
||||||
name = "DNA-Injector (Anti-Hulk)"
|
name = "DNA-Injector (Anti-Hulk)"
|
||||||
desc = "Cures green skin."
|
desc = "Cures green skin."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HULKBLOCK
|
block = HULKBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/xraymut
|
/obj/item/weapon/dnainjector/xraymut
|
||||||
name = "DNA-Injector (Xray)"
|
name = "DNA-Injector (Xray)"
|
||||||
desc = "Finally you can see what the Captain does."
|
desc = "Finally you can see what the Captain does."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 8
|
//block = 8
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = XRAYBLOCK
|
block = XRAYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antixray
|
/obj/item/weapon/dnainjector/antixray
|
||||||
name = "DNA-Injector (Anti-Xray)"
|
name = "DNA-Injector (Anti-Xray)"
|
||||||
desc = "It will make you see harder."
|
desc = "It will make you see harder."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 8
|
//block = 8
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = XRAYBLOCK
|
block = XRAYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/firemut
|
/obj/item/weapon/dnainjector/firemut
|
||||||
name = "DNA-Injector (Fire)"
|
name = "DNA-Injector (Fire)"
|
||||||
desc = "Gives you fire."
|
desc = "Gives you fire."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 10
|
//block = 10
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = FIREBLOCK
|
block = FIREBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antifire
|
/obj/item/weapon/dnainjector/antifire
|
||||||
name = "DNA-Injector (Anti-Fire)"
|
name = "DNA-Injector (Anti-Fire)"
|
||||||
desc = "Cures fire."
|
desc = "Cures fire."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 10
|
//block = 10
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = FIREBLOCK
|
block = FIREBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/telemut
|
/obj/item/weapon/dnainjector/telemut
|
||||||
name = "DNA-Injector (Tele.)"
|
name = "DNA-Injector (Tele.)"
|
||||||
desc = "Super brain man!"
|
desc = "Super brain man!"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 12
|
//block = 12
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = TELEBLOCK
|
block = TELEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antitele
|
/obj/item/weapon/dnainjector/antitele
|
||||||
name = "DNA-Injector (Anti-Tele.)"
|
name = "DNA-Injector (Anti-Tele.)"
|
||||||
desc = "Will make you not able to control your mind."
|
desc = "Will make you not able to control your mind."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 12
|
//block = 12
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = TELEBLOCK
|
block = TELEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/nobreath
|
/obj/item/weapon/dnainjector/nobreath
|
||||||
name = "DNA-Injector (No Breath)"
|
name = "DNA-Injector (No Breath)"
|
||||||
desc = "Hold your breath and count to infinity."
|
desc = "Hold your breath and count to infinity."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NOBREATHBLOCK
|
block = NOBREATHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antinobreath
|
/obj/item/weapon/dnainjector/antinobreath
|
||||||
name = "DNA-Injector (Anti-No Breath)"
|
name = "DNA-Injector (Anti-No Breath)"
|
||||||
desc = "Hold your breath and count to 100."
|
desc = "Hold your breath and count to 100."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NOBREATHBLOCK
|
block = NOBREATHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/remoteview
|
/obj/item/weapon/dnainjector/remoteview
|
||||||
name = "DNA-Injector (Remote View)"
|
name = "DNA-Injector (Remote View)"
|
||||||
desc = "Stare into the distance for a reason."
|
desc = "Stare into the distance for a reason."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = REMOTEVIEWBLOCK
|
block = REMOTEVIEWBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antiremoteview
|
/obj/item/weapon/dnainjector/antiremoteview
|
||||||
name = "DNA-Injector (Anti-Remote View)"
|
name = "DNA-Injector (Anti-Remote View)"
|
||||||
desc = "Cures green skin."
|
desc = "Cures green skin."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = REMOTEVIEWBLOCK
|
block = REMOTEVIEWBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/regenerate
|
/obj/item/weapon/dnainjector/regenerate
|
||||||
name = "DNA-Injector (Regeneration)"
|
name = "DNA-Injector (Regeneration)"
|
||||||
desc = "Healthy but hungry."
|
desc = "Healthy but hungry."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = REGENERATEBLOCK
|
block = REGENERATEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antiregenerate
|
/obj/item/weapon/dnainjector/antiregenerate
|
||||||
name = "DNA-Injector (Anti-Regeneration)"
|
name = "DNA-Injector (Anti-Regeneration)"
|
||||||
desc = "Sickly but sated."
|
desc = "Sickly but sated."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = REGENERATEBLOCK
|
block = REGENERATEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/runfast
|
/obj/item/weapon/dnainjector/runfast
|
||||||
name = "DNA-Injector (Increase Run)"
|
name = "DNA-Injector (Increase Run)"
|
||||||
desc = "Running Man."
|
desc = "Running Man."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = INCREASERUNBLOCK
|
block = INCREASERUNBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antirunfast
|
/obj/item/weapon/dnainjector/antirunfast
|
||||||
name = "DNA-Injector (Anti-Increase Run)"
|
name = "DNA-Injector (Anti-Increase Run)"
|
||||||
desc = "Walking Man."
|
desc = "Walking Man."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = INCREASERUNBLOCK
|
block = INCREASERUNBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/morph
|
/obj/item/weapon/dnainjector/morph
|
||||||
name = "DNA-Injector (Morph)"
|
name = "DNA-Injector (Morph)"
|
||||||
desc = "A total makeover."
|
desc = "A total makeover."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = MORPHBLOCK
|
block = MORPHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antimorph
|
/obj/item/weapon/dnainjector/antimorph
|
||||||
name = "DNA-Injector (Anti-Morph)"
|
name = "DNA-Injector (Anti-Morph)"
|
||||||
desc = "Cures identity crisis."
|
desc = "Cures identity crisis."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = MORPHBLOCK
|
block = MORPHBLOCK
|
||||||
/*
|
..()
|
||||||
|
|
||||||
|
/* No COLDBLOCK on bay
|
||||||
/obj/item/weapon/dnainjector/cold
|
/obj/item/weapon/dnainjector/cold
|
||||||
name = "DNA-Injector (Cold)"
|
name = "DNA-Injector (Cold)"
|
||||||
desc = "Feels a bit chilly."
|
desc = "Feels a bit chilly."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = COLDBLOCK
|
block = COLDBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/anticold
|
/obj/item/weapon/dnainjector/anticold
|
||||||
name = "DNA-Injector (Anti-Cold)"
|
name = "DNA-Injector (Anti-Cold)"
|
||||||
desc = "Feels room-temperature."
|
desc = "Feels room-temperature."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = COLDBLOCK
|
block = COLDBLOCK
|
||||||
|
..()
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/noprints
|
/obj/item/weapon/dnainjector/noprints
|
||||||
name = "DNA-Injector (No Prints)"
|
name = "DNA-Injector (No Prints)"
|
||||||
desc = "Better than a pair of budget insulated gloves."
|
desc = "Better than a pair of budget insulated gloves."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NOPRINTSBLOCK
|
block = NOPRINTSBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antinoprints
|
/obj/item/weapon/dnainjector/antinoprints
|
||||||
name = "DNA-Injector (Anti-No Prints)"
|
name = "DNA-Injector (Anti-No Prints)"
|
||||||
desc = "Not quite as good as a pair of budget insulated gloves."
|
desc = "Not quite as good as a pair of budget insulated gloves."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NOPRINTSBLOCK
|
block = NOPRINTSBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/insulation
|
/obj/item/weapon/dnainjector/insulation
|
||||||
name = "DNA-Injector (Shock Immunity)"
|
name = "DNA-Injector (Shock Immunity)"
|
||||||
desc = "Better than a pair of real insulated gloves."
|
desc = "Better than a pair of real insulated gloves."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = SHOCKIMMUNITYBLOCK
|
block = SHOCKIMMUNITYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antiinsulation
|
/obj/item/weapon/dnainjector/antiinsulation
|
||||||
name = "DNA-Injector (Anti-Shock Immunity)"
|
name = "DNA-Injector (Anti-Shock Immunity)"
|
||||||
desc = "Not quite as good as a pair of real insulated gloves."
|
desc = "Not quite as good as a pair of real insulated gloves."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = SHOCKIMMUNITYBLOCK
|
block = SHOCKIMMUNITYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/midgit
|
/obj/item/weapon/dnainjector/midgit
|
||||||
name = "DNA-Injector (Small Size)"
|
name = "DNA-Injector (Small Size)"
|
||||||
desc = "Makes you shrink."
|
desc = "Makes you shrink."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = SMALLSIZEBLOCK
|
block = SMALLSIZEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antimidgit
|
/obj/item/weapon/dnainjector/antimidgit
|
||||||
name = "DNA-Injector (Anti-Small Size)"
|
name = "DNA-Injector (Anti-Small Size)"
|
||||||
desc = "Makes you grow. But not too much."
|
desc = "Makes you grow. But not too much."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = SMALLSIZEBLOCK
|
block = SMALLSIZEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/////////////////////////////////////
|
/////////////////////////////////////
|
||||||
/obj/item/weapon/dnainjector/antiglasses
|
/obj/item/weapon/dnainjector/antiglasses
|
||||||
name = "DNA-Injector (Anti-Glasses)"
|
name = "DNA-Injector (Anti-Glasses)"
|
||||||
desc = "Toss away those glasses!"
|
desc = "Toss away those glasses!"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 1
|
//block = 1
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = GLASSESBLOCK
|
block = GLASSESBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/glassesmut
|
/obj/item/weapon/dnainjector/glassesmut
|
||||||
name = "DNA-Injector (Glasses)"
|
name = "DNA-Injector (Glasses)"
|
||||||
desc = "Will make you need dorkish glasses."
|
desc = "Will make you need dorkish glasses."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 1
|
//block = 1
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = GLASSESBLOCK
|
block = GLASSESBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/epimut
|
/obj/item/weapon/dnainjector/epimut
|
||||||
name = "DNA-Injector (Epi.)"
|
name = "DNA-Injector (Epi.)"
|
||||||
desc = "Shake shake shake the room!"
|
desc = "Shake shake shake the room!"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 3
|
//block = 3
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HEADACHEBLOCK
|
block = HEADACHEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antiepi
|
/obj/item/weapon/dnainjector/antiepi
|
||||||
name = "DNA-Injector (Anti-Epi.)"
|
name = "DNA-Injector (Anti-Epi.)"
|
||||||
desc = "Will fix you up from shaking the room."
|
desc = "Will fix you up from shaking the room."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 3
|
//block = 3
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HEADACHEBLOCK
|
block = HEADACHEBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/anticough
|
/obj/item/weapon/dnainjector/anticough
|
||||||
name = "DNA-Injector (Anti-Cough)"
|
name = "DNA-Injector (Anti-Cough)"
|
||||||
desc = "Will stop that awful noise."
|
desc = "Will stop that awful noise."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 5
|
//block = 5
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = COUGHBLOCK
|
block = COUGHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/coughmut
|
/obj/item/weapon/dnainjector/coughmut
|
||||||
name = "DNA-Injector (Cough)"
|
name = "DNA-Injector (Cough)"
|
||||||
desc = "Will bring forth a sound of horror from your throat."
|
desc = "Will bring forth a sound of horror from your throat."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 5
|
//block = 5
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = COUGHBLOCK
|
block = COUGHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/clumsymut
|
/obj/item/weapon/dnainjector/clumsymut
|
||||||
name = "DNA-Injector (Clumsy)"
|
name = "DNA-Injector (Clumsy)"
|
||||||
desc = "Makes clumsy minions."
|
desc = "Makes clumsy minions."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 6
|
//block = 6
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = CLUMSYBLOCK
|
block = CLUMSYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/anticlumsy
|
/obj/item/weapon/dnainjector/anticlumsy
|
||||||
name = "DNA-Injector (Anti-Clumy)"
|
name = "DNA-Injector (Anti-Clumy)"
|
||||||
desc = "Cleans up confusion."
|
desc = "Cleans up confusion."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 6
|
//block = 6
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = CLUMSYBLOCK
|
block = CLUMSYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antitour
|
/obj/item/weapon/dnainjector/antitour
|
||||||
name = "DNA-Injector (Anti-Tour.)"
|
name = "DNA-Injector (Anti-Tour.)"
|
||||||
desc = "Will cure tourrets."
|
desc = "Will cure tourrets."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 7
|
//block = 7
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = TWITCHBLOCK
|
block = TWITCHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/tourmut
|
/obj/item/weapon/dnainjector/tourmut
|
||||||
name = "DNA-Injector (Tour.)"
|
name = "DNA-Injector (Tour.)"
|
||||||
desc = "Gives you a nasty case off tourrets."
|
desc = "Gives you a nasty case off tourrets."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 7
|
//block = 7
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = TWITCHBLOCK
|
block = TWITCHBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/stuttmut
|
/obj/item/weapon/dnainjector/stuttmut
|
||||||
name = "DNA-Injector (Stutt.)"
|
name = "DNA-Injector (Stutt.)"
|
||||||
desc = "Makes you s-s-stuttterrr"
|
desc = "Makes you s-s-stuttterrr"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 9
|
//block = 9
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NERVOUSBLOCK
|
block = NERVOUSBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antistutt
|
/obj/item/weapon/dnainjector/antistutt
|
||||||
name = "DNA-Injector (Anti-Stutt.)"
|
name = "DNA-Injector (Anti-Stutt.)"
|
||||||
desc = "Fixes that speaking impairment."
|
desc = "Fixes that speaking impairment."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 9
|
//block = 9
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = NERVOUSBLOCK
|
block = NERVOUSBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/blindmut
|
/obj/item/weapon/dnainjector/blindmut
|
||||||
name = "DNA-Injector (Blind)"
|
name = "DNA-Injector (Blind)"
|
||||||
desc = "Makes you not see anything."
|
desc = "Makes you not see anything."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 11
|
//block = 11
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = BLINDBLOCK
|
block = BLINDBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antiblind
|
/obj/item/weapon/dnainjector/antiblind
|
||||||
name = "DNA-Injector (Anti-Blind)"
|
name = "DNA-Injector (Anti-Blind)"
|
||||||
desc = "ITS A MIRACLE!!!"
|
desc = "ITS A MIRACLE!!!"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 11
|
//block = 11
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = BLINDBLOCK
|
block = BLINDBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/deafmut
|
/obj/item/weapon/dnainjector/deafmut
|
||||||
name = "DNA-Injector (Deaf)"
|
name = "DNA-Injector (Deaf)"
|
||||||
desc = "Sorry, what did you say?"
|
desc = "Sorry, what did you say?"
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 13
|
//block = 13
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = DEAFBLOCK
|
block = DEAFBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antideaf
|
/obj/item/weapon/dnainjector/antideaf
|
||||||
name = "DNA-Injector (Anti-Deaf)"
|
name = "DNA-Injector (Anti-Deaf)"
|
||||||
desc = "Will make you hear once more."
|
desc = "Will make you hear once more."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 13
|
//block = 13
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = DEAFBLOCK
|
block = DEAFBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/hallucination
|
/obj/item/weapon/dnainjector/hallucination
|
||||||
name = "DNA-Injector (Halluctination)"
|
name = "DNA-Injector (Halluctination)"
|
||||||
desc = "What you see isn't always what you get."
|
desc = "What you see isn't always what you get."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HALLUCINATIONBLOCK
|
block = HALLUCINATIONBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/antihallucination
|
/obj/item/weapon/dnainjector/antihallucination
|
||||||
name = "DNA-Injector (Anti-Hallucination)"
|
name = "DNA-Injector (Anti-Hallucination)"
|
||||||
desc = "What you see is what you get."
|
desc = "What you see is what you get."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 2
|
//block = 2
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = HALLUCINATIONBLOCK
|
block = HALLUCINATIONBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/h2m
|
/obj/item/weapon/dnainjector/h2m
|
||||||
name = "DNA-Injector (Human > Monkey)"
|
name = "DNA-Injector (Human > Monkey)"
|
||||||
desc = "Will make you a flea bag."
|
desc = "Will make you a flea bag."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(4090)
|
value = 0xFFF
|
||||||
//block = 14
|
//block = 14
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = MONKEYBLOCK
|
block = MONKEYBLOCK
|
||||||
|
..()
|
||||||
|
|
||||||
/obj/item/weapon/dnainjector/m2h
|
/obj/item/weapon/dnainjector/m2h
|
||||||
name = "DNA-Injector (Monkey > Human)"
|
name = "DNA-Injector (Monkey > Human)"
|
||||||
desc = "Will make you...less hairy."
|
desc = "Will make you...less hairy."
|
||||||
dnatype = "se"
|
datatype = DNA2_BUF_SE
|
||||||
dna = list(1)
|
value = 0x001
|
||||||
//block = 14
|
//block = 14
|
||||||
New()
|
New()
|
||||||
..()
|
|
||||||
block = MONKEYBLOCK
|
block = MONKEYBLOCK
|
||||||
|
..()
|
||||||
@@ -34,10 +34,10 @@
|
|||||||
H.apply_effect((rand(40,70)),IRRADIATE,0)
|
H.apply_effect((rand(40,70)),IRRADIATE,0)
|
||||||
if (prob(75))
|
if (prob(75))
|
||||||
randmutb(H) // Applies bad mutation
|
randmutb(H) // Applies bad mutation
|
||||||
domutcheck(H,null,1)
|
domutcheck(H,null,MUTCHK_FORCED)
|
||||||
else
|
else
|
||||||
randmutg(H) // Applies good mutation
|
randmutg(H) // Applies good mutation
|
||||||
domutcheck(H,null,1)
|
domutcheck(H,null,MUTCHK_FORCED)
|
||||||
|
|
||||||
|
|
||||||
for(var/mob/living/carbon/monkey/M in living_mob_list)
|
for(var/mob/living/carbon/monkey/M in living_mob_list)
|
||||||
|
|||||||
@@ -13,6 +13,9 @@
|
|||||||
set invisibility = 0
|
set invisibility = 0
|
||||||
set background = 1
|
set background = 1
|
||||||
if (monkeyizing) return
|
if (monkeyizing) return
|
||||||
|
if (update_muts)
|
||||||
|
update_muts=0
|
||||||
|
domutcheck(src,null,MUTCHK_FORCED)
|
||||||
..()
|
..()
|
||||||
|
|
||||||
var/datum/gas_mixture/environment // Added to prevent null location errors-- TLE
|
var/datum/gas_mixture/environment // Added to prevent null location errors-- TLE
|
||||||
|
|||||||
@@ -10,28 +10,31 @@
|
|||||||
|
|
||||||
var/obj/item/weapon/card/id/wear_id = null // Fix for station bounced radios -- Skie
|
var/obj/item/weapon/card/id/wear_id = null // Fix for station bounced radios -- Skie
|
||||||
var/greaterform = "Human" // Used when humanizing a monkey.
|
var/greaterform = "Human" // Used when humanizing a monkey.
|
||||||
var/uni_append = "12C4E2" // Small appearance modifier for different species.
|
icon_state = "monkey1"
|
||||||
|
//var/uni_append = "12C4E2" // Small appearance modifier for different species.
|
||||||
|
var/list/uni_append = list(0x12C,0x4E2) // Same as above for DNA2.
|
||||||
|
var/update_muts = 1 // Monkey gene must be set at start.
|
||||||
|
|
||||||
/mob/living/carbon/monkey/tajara
|
/mob/living/carbon/monkey/tajara
|
||||||
name = "farwa"
|
name = "farwa"
|
||||||
voice_name = "farwa"
|
voice_name = "farwa"
|
||||||
speak_emote = list("mews")
|
speak_emote = list("mews")
|
||||||
icon_state = "tajkey1"
|
icon_state = "tajkey1"
|
||||||
uni_append = "0A0E00"
|
uni_append = list(0x0A0,0xE00) // 0A0E00
|
||||||
|
|
||||||
/mob/living/carbon/monkey/skrell
|
/mob/living/carbon/monkey/skrell
|
||||||
name = "neaera"
|
name = "neaera"
|
||||||
voice_name = "neaera"
|
voice_name = "neaera"
|
||||||
speak_emote = list("squicks")
|
speak_emote = list("squicks")
|
||||||
icon_state = "skrellkey1"
|
icon_state = "skrellkey1"
|
||||||
uni_append = "01CC92"
|
uni_append = list(0x01C,0xC92) // 01CC92
|
||||||
|
|
||||||
/mob/living/carbon/monkey/unathi
|
/mob/living/carbon/monkey/unathi
|
||||||
name = "stok"
|
name = "stok"
|
||||||
voice_name = "stok"
|
voice_name = "stok"
|
||||||
speak_emote = list("hisses")
|
speak_emote = list("hisses")
|
||||||
icon_state = "stokkey1"
|
icon_state = "stokkey1"
|
||||||
uni_append = "044C5D"
|
uni_append = list(0x044,0xC5D) // 044C5D
|
||||||
|
|
||||||
/mob/living/carbon/monkey/New()
|
/mob/living/carbon/monkey/New()
|
||||||
var/datum/reagents/R = new/datum/reagents(1000)
|
var/datum/reagents/R = new/datum/reagents(1000)
|
||||||
@@ -52,13 +55,20 @@
|
|||||||
//dna.uni_identity = "00600200A00E0110148FC01300B009"
|
//dna.uni_identity = "00600200A00E0110148FC01300B009"
|
||||||
//dna.struc_enzymes = "43359156756131E13763334D1C369012032164D4FE4CD61544B6C03F251B6C60A42821D26BA3B0FD6"
|
//dna.struc_enzymes = "43359156756131E13763334D1C369012032164D4FE4CD61544B6C03F251B6C60A42821D26BA3B0FD6"
|
||||||
dna.unique_enzymes = md5(name)
|
dna.unique_enzymes = md5(name)
|
||||||
//////////blah
|
|
||||||
var/gendervar
|
// We're a monkey
|
||||||
if (gender == MALE)
|
dna.SetSEState(MONKEYBLOCK, 1)
|
||||||
gendervar = add_zero2(num2hex((rand(1,2049)),1), 3)
|
// Fix gender
|
||||||
else
|
dna.SetUIState(DNA_UI_GENDER, gender != MALE, 1)
|
||||||
gendervar = add_zero2(num2hex((rand(2051,4094)),1), 3)
|
|
||||||
dna.uni_identity += "[gendervar][uni_append]"
|
// Set the blocks to uni_append, if needed.
|
||||||
|
if(uni_append.len>0)
|
||||||
|
for(var/b=1;b<=uni_append.len;b++)
|
||||||
|
dna.SetUIValue(DNA_UI_LENGTH-(uni_append.len-b),uni_append[b], 1)
|
||||||
|
dna.UpdateUI()
|
||||||
|
|
||||||
|
update_muts=1
|
||||||
|
|
||||||
..()
|
..()
|
||||||
update_icons()
|
update_icons()
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -216,3 +216,5 @@
|
|||||||
var/immune_to_ssd = 0
|
var/immune_to_ssd = 0
|
||||||
|
|
||||||
var/turf/listed_turf = null //the current turf being examined in the stat panel
|
var/turf/listed_turf = null //the current turf being examined in the stat panel
|
||||||
|
|
||||||
|
var/list/active_genes=list()
|
||||||
|
|||||||
Reference in New Issue
Block a user