Merge branch 'master' into surgery

Conflicts:
	code/WorkInProgress/surgery.dm
	code/modules/mob/living/carbon/carbon_defines.dm
This commit is contained in:
Chinsky
2013-01-15 13:42:13 +04:00
691 changed files with 46179 additions and 41058 deletions
+10 -1
View File
@@ -17,7 +17,7 @@
//If you died in the game and are a ghsot - this will remain as null.
//Note that this is not a reliable way to determine if admins started as observers, since they change mobs a lot.
universal_speak = 1
var/atom/movable/following = null
/mob/dead/observer/New(mob/body)
sight |= SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
see_invisible = SEE_INVISIBLE_OBSERVER
@@ -167,6 +167,10 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/list/L = list()
for(var/turf/T in get_area_turfs(thearea.type))
L+=T
if(!L || !L.len)
usr << "No area available."
usr.loc = pick(L)
/mob/dead/observer/verb/follow()
@@ -179,17 +183,22 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
var/input = input("Please, select a mob!", "Haunt", null, null) as null|anything in mobs
var/mob/target = mobs[input]
if(target && target != usr)
following = target
spawn(0)
var/turf/pos = get_turf(src)
while(src.loc == pos)
var/turf/T = get_turf(target)
if(!T)
break
if(following != target)
break
if(!client)
break
src.loc = T
pos = src.loc
sleep(15)
following = null
/mob/dead/observer/verb/jumptomob() //Moves the ghost instead of just changing the ghosts's eye -Nodrak
+2
View File
@@ -27,6 +27,7 @@
// l_hand.screen_loc = ui_lhand
W.equipped(src,slot_l_hand)
if(client) client.screen |= W
if(pulling == W) stop_pulling()
update_inv_l_hand()
return 1
return 0
@@ -42,6 +43,7 @@
// r_hand.screen_loc = ui_rhand
W.equipped(src,slot_r_hand)
if(client) client.screen |= W
if(pulling == W) stop_pulling()
update_inv_r_hand()
return 1
return 0
+5
View File
@@ -8,6 +8,7 @@
see_invisible = SEE_INVISIBLE_LEVEL_TWO
var/ghost_name = "Unknown"
var/creating_blob = 0
faction = "blob"
New()
@@ -251,3 +252,7 @@
B << "Check your Blob verbs and hit Create Node to build a node."
spawn(10)
del(G_found)
@@ -185,9 +185,10 @@ Des: Gives the client of the alien an image on each infected mob.
----------------------------------------*/
/mob/living/carbon/alien/proc/AddInfectionImages()
if (client)
for (var/mob/living/carbon/C in mob_list)
for (var/mob/living/C in mob_list)
if(C.status_flags & XENO_HOST)
var/I = image('icons/mob/alien.dmi', loc = C, icon_state = "infected")
var/obj/item/alien_embryo/A = locate() in C
var/I = image('icons/mob/alien.dmi', loc = C, icon_state = "infected[A.stage]")
client.images += I
return
@@ -199,11 +200,10 @@ Des: Removes all infected images from the alien.
/mob/living/carbon/alien/proc/RemoveInfectionImages()
if (client)
for(var/image/I in client.images)
if(I.icon_state == "infected")
if(dd_hasprefix_case(I.icon_state, "infected"))
del(I)
return
#undef HEAT_DAMAGE_LEVEL_1
#undef HEAT_DAMAGE_LEVEL_2
#undef HEAT_DAMAGE_LEVEL_3
@@ -137,13 +137,12 @@ Doesn't work on other aliens/AI.*/
if(!istype(T, /turf))
return
if (U == T)
usr.bullet_act(new /obj/item/projectile/neurotoxin(usr.loc), get_organ_target())
usr.bullet_act(new /obj/item/projectile/energy/neurotoxin(usr.loc), get_organ_target())
return
if(!istype(U, /turf))
return
var/obj/item/projectile/neurotoxin/A = new /obj/item/projectile/neurotoxin(usr.loc)
var/obj/item/projectile/energy/neurotoxin/A = new /obj/item/projectile/energy/neurotoxin(usr.loc)
A.current = U
A.yo = U.y - T.y
A.xo = U.x - T.x
@@ -186,4 +185,4 @@ Doesn't work on other aliens/AI.*/
M.loc = loc
//Paralyse(10)
src.visible_message("\green <B>[src] hurls out the contents of their stomach!</B>")
return
return
@@ -9,6 +9,7 @@
O.show_message("<B>[src]</B> lets out a waning guttural screech, green blood bubbling from its maw...", 1)
update_canmove()
if(client) blind.layer = 0
update_icons()
tod = worldtime2text() //weasellos time of death patch
if(mind) mind.store_memory("Time of death: [tod]", 0)
@@ -232,7 +232,7 @@
mymob.zone_sel = new /obj/screen/zone_sel()
mymob.zone_sel.icon = 'icons/mob/screen1_alien.dmi'
mymob.zone_sel.overlays = null
mymob.zone_sel.overlays.Cut()
mymob.zone_sel.overlays += image('icons/mob/zone_sel.dmi', "[mymob.zone_sel.selecting]")
mymob.client.screen = null
@@ -133,82 +133,6 @@
updatehealth()
return
/mob/living/carbon/alien/humanoid/Move(a, b, flag)
if (buckled)
return 0
if (restrained())
stop_pulling()
var/t7 = 1
if (restrained())
for(var/mob/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at __LINE__ in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (ismob(pulling))
var/mob/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [] has been pulled from []'s grip by []", G.affecting, G.assailant, src), 1)
//G = null
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
if (istype(pulling, /obj/structure/window))
if(pulling:ini_dir == NORTHWEST || pulling:ini_dir == NORTHEAST || pulling:ini_dir == SOUTHWEST || pulling:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(pulling,get_dir(pulling.loc, T)))
stop_pulling()
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
for(var/mob/living/carbon/metroid/M in view(1,src))
M.UpdateFeed(src)
return
/mob/living/carbon/alien/humanoid/hand_p(mob/M as mob)
if (!ticker)
@@ -256,7 +180,7 @@
return
/mob/living/carbon/alien/humanoid/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/carbon/alien/humanoid/attack_slime(mob/living/carbon/slime/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -271,7 +195,7 @@
var/damage = rand(1, 3)
if(istype(M, /mob/living/carbon/metroid/adult))
if(istype(M, /mob/living/carbon/slime/adult))
damage = rand(10, 40)
else
damage = rand(5, 35)
@@ -359,6 +359,8 @@
//Other
if(stunned)
AdjustStunned(-1)
if(!stunned)
update_icons()
if(weakened)
weakened = max(weakened-1,0) //before you get mad Rockdtben: I done this so update_canmove isn't called multiple times
@@ -80,7 +80,7 @@
/mob/living/carbon/alien/humanoid/queen/large/update_icons()
lying_prev = lying //so we don't update overlays for lying/standing unless our stance changes again
update_hud() //TODO: remove the need for this to be here
overlays = null
overlays.Cut()
if(lying)
if(resting) icon_state = "queen_sleep"
else icon_state = "queen_l"
@@ -13,10 +13,22 @@
/mob/living/carbon/alien/humanoid/update_icons()
lying_prev = lying //so we don't update overlays for lying/standing unless our stance changes again
update_hud() //TODO: remove the need for this to be here
overlays = null
if(lying)
if(resting) icon_state = "alien[caste]_sleep"
else icon_state = "alien[caste]_l"
overlays.Cut()
if(stat == DEAD)
//If we mostly took damage from fire
if(fireloss > 125)
icon_state = "alien[caste]_husked"
else
icon_state = "alien[caste]_dead"
for(var/image/I in overlays_lying)
overlays += I
else if(lying)
if(resting)
icon_state = "alien[caste]_sleep"
else if(stat == UNCONSCIOUS)
icon_state = "alien[caste]_unconscious"
else
icon_state = "alien[caste]_l"
for(var/image/I in overlays_lying)
overlays += I
else
@@ -2,7 +2,7 @@
if(stat == DEAD) return
if(healths) healths.icon_state = "health6"
stat = DEAD
icon_state = "larva_l"
icon_state = "larva_dead"
if(!gibbed)
update_canmove()
@@ -88,6 +88,9 @@
if("jump")
message = "<B>The [src.name]</B> jumps!"
m_type = 1
if("hiss_")
message = "<B>The [src.name]</B> hisses softly."
m_type = 1
if("collapse")
Paralyse(2)
message = text("<B>[]</B> collapses!", src)
@@ -73,7 +73,7 @@
mymob.flash.layer = 17
mymob.zone_sel = new /obj/screen/zone_sel()
mymob.zone_sel.overlays = null
mymob.zone_sel.overlays.Cut()
mymob.zone_sel.overlays += image("icon" = 'icons/mob/zone_sel.dmi', "icon_state" = text("[]", mymob.zone_sel.selecting))
mymob.client.screen = null
@@ -1,7 +1,7 @@
/mob/living/carbon/alien/larva
name = "alien larva"
real_name = "alien larva"
icon_state = "larva"
icon_state = "larva0"
pass_flags = PASSTABLE
maxHealth = 25
@@ -11,6 +11,7 @@
var/amount_grown = 0
var/max_grown = 200
var/time_of_birth
//This is fine right now, if we're adding organ specific damage this needs to be updated
/mob/living/carbon/alien/larva/New()
@@ -138,72 +139,6 @@
updatehealth()
return
/mob/living/carbon/alien/larva/Move(a, b, flag)
var/t7 = 1
if (restrained())
for(var/mob/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at __LINE__ in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (ismob(pulling))
var/mob/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [] has been pulled from []'s grip by []", G.affecting, G.assailant, src), 1)
//G = null
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
for(var/mob/living/carbon/metroid/M in view(1,src))
M.UpdateFeed(src)
return
/mob/living/carbon/alien/larva/hand_p(mob/M as mob)
if (!ticker)
@@ -270,7 +205,7 @@
return
/mob/living/carbon/alien/larva/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/carbon/alien/larva/attack_slime(mob/living/carbon/slime/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -285,7 +220,7 @@
var/damage = rand(1, 3)
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
damage = rand(20, 40)
else
damage = rand(5, 35)
@@ -55,6 +55,9 @@
for(var/obj/item/weapon/grab/G in src)
G.process()
//some kind of bug in canmove() isn't properly calling update_icons, so this is here as a placeholder
update_icons()
if(client)
handle_regular_hud_updates()
@@ -226,7 +229,7 @@ FUCK YOU MORE FAT CODE -Hawk*/
return 1
//UNCONSCIOUS. NO-ONE IS HOME
if( (getOxyLoss() > 50) || (0 > health) )
if( (getOxyLoss() > 25) || (0 > health) )
//if( health <= 20 && prob(1) )
// spawn(0)
// emote("gasp")
@@ -244,7 +247,7 @@ FUCK YOU MORE FAT CODE -Hawk*/
stat = UNCONSCIOUS
if( prob(10) && health )
spawn(0)
emote("hiss")
emote("hiss_")
//CONSCIOUS
else
stat = CONSCIOUS
@@ -28,12 +28,16 @@
if(stat != CONSCIOUS)
return
if(handcuffed || legcuffed)
src << "\red You cannot evolve when you are cuffed."
if(amount_grown >= max_grown) //TODO ~Carn
src << "\green You are growing into a beautiful alien! It is time to choose a caste."
src << "\green There are three to choose from:"
src << "\green <B>Hunters</B> are strong and agile, able to hunt away from the hive and rapidly move through ventilation shafts. Hunters generate plasma slowly and have low reserves."
src << "\green <B>Sentinels</B> are tasked with protecting the hive and are deadly up close and at a range. They are not as physically imposing nor fast as the hunters."
src << "\green <B>Drones</B> are the working class, offering the largest plasma storage and generation. They are the only caste which may evolve again, turning into the dreaded alien queen."
//green is impossible to read, so i made these blue and changed the formatting slightly
src << "\blue <b>You are growing into a beautiful alien! It is time to choose a caste.</b>"
src << "\blue There are three to choose from:"
src << "<B>Hunters</B> \blue are strong and agile, able to hunt away from the hive and rapidly move through ventilation shafts. Hunters generate plasma slowly and have low reserves."
src << "<B>Sentinels</B> \blue are tasked with protecting the hive and are deadly up close and at a range. They are not as physically imposing nor fast as the hunters."
src << "<B>Drones</B> \blue are the working class, offering the largest plasma storage and generation. They are the only caste which may evolve again, turning into the dreaded alien queen."
var/alien_caste = alert(src, "Please choose which alien caste you shall belong to.",,"Hunter","Sentinel","Drone")
var/mob/living/carbon/alien/humanoid/new_xeno
@@ -1 +1,22 @@
//No special icons processing
/mob/living/carbon/alien/larva/regenerate_icons()
overlays = list()
update_icons()
/mob/living/carbon/alien/larva/update_icons()
var/state = 0
if(amount_grown > 150)
state = 2
else if(amount_grown > 50)
state = 1
if(stat == DEAD)
icon_state = "larva[state]_dead"
else if (handcuffed || legcuffed)
icon_state = "larva[state]_cuff"
else if (stunned)
icon_state = "larva[state]_stun"
else if(lying || resting)
icon_state = "larva[state]_sleep"
else
icon_state = "larva[state]"
@@ -1,5 +1,5 @@
/mob/living/carbon/alien/verb/ventcrawl() // -- TLE
set name = "Crawl through Vent"
set name = "Crawl through vent"
set desc = "Enter an air vent and crawl through the pipe system."
set category = "Alien"
handle_ventcrawl()
@@ -0,0 +1,142 @@
// This is to replace the previous datum/disease/alien_embryo for slightly improved handling and maintainability
// It functions almost identically (see code/datums/diseases/alien_embryo.dm)
/obj/item/alien_embryo
name = "alien embryo"
desc = "All slimy and yuck."
icon = 'icons/mob/alien.dmi'
icon_state = "larva0_dead"
var/mob/living/affected_mob
var/stage = 0
/obj/item/alien_embryo/New()
if(istype(loc, /mob/living))
affected_mob = loc
processing_objects.Add(src)
spawn(0)
AddInfectionImages(affected_mob)
else
del(src)
/obj/item/alien_embryo/Del()
if(affected_mob)
affected_mob.status_flags &= ~(XENO_HOST)
spawn(0)
RemoveInfectionImages(affected_mob)
..()
/obj/item/alien_embryo/process()
if(loc != affected_mob)
affected_mob.status_flags &= ~(XENO_HOST)
processing_objects.Remove(src)
affected_mob = null
spawn(0)
RemoveInfectionImages(affected_mob)
return
if(stage < 5 && prob(3))
stage++
spawn(0)
RefreshInfectionImage(affected_mob)
switch(stage)
if(2, 3)
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(1))
affected_mob << "\red Your throat feels sore."
if(prob(1))
affected_mob << "\red Mucous runs down the back of your throat."
if(4)
if(prob(1))
affected_mob.emote("sneeze")
if(prob(1))
affected_mob.emote("cough")
if(prob(2))
affected_mob << "\red Your muscles ache."
if(prob(20))
affected_mob.take_organ_damage(1)
if(prob(2))
affected_mob << "\red Your stomach hurts."
if(prob(20))
affected_mob.adjustToxLoss(1)
affected_mob.updatehealth()
if(5)
affected_mob << "\red You feel something tearing its way out of your stomach..."
affected_mob.adjustToxLoss(10)
affected_mob.updatehealth()
if(prob(50))
AttemptGrow()
/obj/item/alien_embryo/proc/AttemptGrow(var/gib_on_success = 1)
var/list/candidates = get_alien_candidates()
var/picked = null
// To stop clientless larva, we will check that our host has a client
// if we find no ghosts to become the alien. If the host has a client
// he will become the alien but if he doesn't then we will set the stage
// to 2, so we don't do a process heavy check everytime.
if(candidates.len)
picked = pick(candidates)
else if(affected_mob.client)
picked = affected_mob.key
else
stage = 4 // Let's try again later.
return
if(affected_mob.lying)
affected_mob.overlays += image('icons/mob/alien.dmi', loc = affected_mob, icon_state = "burst_lie")
else
affected_mob.overlays += image('icons/mob/alien.dmi', loc = affected_mob, icon_state = "burst_stand")
spawn(6)
var/mob/living/carbon/alien/larva/new_xeno = new(affected_mob.loc)
new_xeno.key = picked
new_xeno << sound('sound/voice/hiss5.ogg',0,0,0,100) //To get the player's attention
if(gib_on_success)
affected_mob.gib()
del(src)
/*----------------------------------------
Proc: RefreshInfectionImage()
Des: Removes all infection images from aliens and places an infection image on all infected mobs for aliens.
----------------------------------------*/
/obj/item/alien_embryo/proc/RefreshInfectionImage()
for(var/mob/living/carbon/alien/alien in player_list)
if(alien.client)
for(var/image/I in alien.client.images)
if(dd_hasprefix_case(I.icon_state, "infected"))
del(I)
for(var/mob/living/L in mob_list)
if(iscorgi(L) || iscarbon(L))
if(L.status_flags & XENO_HOST)
var/I = image('icons/mob/alien.dmi', loc = L, icon_state = "infected[stage]")
alien.client.images += I
/*----------------------------------------
Proc: AddInfectionImages(C)
Des: Checks if the passed mob (C) is infected with the alien egg, then gives each alien client an infected image at C.
----------------------------------------*/
/obj/item/alien_embryo/proc/AddInfectionImages(var/mob/living/C)
if(C)
for(var/mob/living/carbon/alien/alien in player_list)
if(alien.client)
if(C.status_flags & XENO_HOST)
var/I = image('icons/mob/alien.dmi', loc = C, icon_state = "infected[stage]")
alien.client.images += I
/*----------------------------------------
Proc: RemoveInfectionImage(C)
Des: Removes the alien infection image from all aliens in the world located in passed mob (C).
----------------------------------------*/
/obj/item/alien_embryo/proc/RemoveInfectionImages(var/mob/living/C)
if(C)
for(var/mob/living/carbon/alien/alien in player_list)
if(alien.client)
for(var/image/I in alien.client.images)
if(I.loc == C)
if(dd_hasprefix_case(I.icon_state, "infected"))
del(I)
@@ -15,7 +15,7 @@ var/const/MAX_ACTIVE_TIME = 400
icon_state = "facehugger"
item_state = "facehugger"
w_class = 1 //note: can be picked up by aliens unlike most other items of w_class below 4
flags = FPRINT|TABLEPASS|MASKCOVERSMOUTH|MASKCOVERSEYES
flags = FPRINT | TABLEPASS | MASKCOVERSMOUTH | MASKCOVERSEYES | MASKINTERNALS
throw_range = 5
var/stat = CONSCIOUS //UNCONSCIOUS is the idle state in this case
@@ -35,7 +35,7 @@ var/const/MAX_ACTIVE_TIME = 400
return
/obj/item/clothing/mask/facehugger/attack_hand(user as mob)
if(stat == CONSCIOUS && !isalien(user))
if((stat == CONSCIOUS && !sterile) && !isalien(user))
Attach(user)
return
else
@@ -85,21 +85,31 @@ var/const/MAX_ACTIVE_TIME = 400
return
/obj/item/clothing/mask/facehugger/on_found(mob/finder as mob)
HasProximity(finder)
return 1
/obj/item/clothing/mask/facehugger/dropped()
..()
GoActive()
if(stat == CONSCIOUS)
HasProximity(finder)
return 1
return
/obj/item/clothing/mask/facehugger/HasProximity(atom/movable/AM as mob|obj)
if(CanHug(AM))
Attach(AM)
/obj/item/clothing/mask/facehugger/throw_at(atom/target, range, speed)
..()
if(stat == CONSCIOUS)
icon_state = "[initial(icon_state)]_thrown"
spawn(15)
if(icon_state == "[initial(icon_state)]_thrown")
icon_state = "[initial(icon_state)]"
/obj/item/clothing/mask/facehugger/throw_impact(atom/hit_atom)
if(prob(25))
..()
if(stat == CONSCIOUS)
icon_state = "[initial(icon_state)]"
Attach(hit_atom)
return
/obj/item/clothing/mask/facehugger/proc/Attach(M as mob)
if(!iscarbon(M) || isalien(M))
if( (!iscorgi(M) && !iscarbon(M)) || isalien(M))
return
if(attached)
return
@@ -110,67 +120,67 @@ var/const/MAX_ACTIVE_TIME = 400
var/mob/living/L = M //just so I don't need to use :
if(loc == L) return
if(stat != CONSCIOUS) return
if(!sterile) L.take_organ_damage(strength,0) //done here so that even borgs and humans in helmets take damage
var/mob/living/carbon/target = L
L.visible_message("\red \b [src] leaps at [L]'s face!")
for(var/mob/O in viewers(target, null))
O.show_message("\red \b [src] leaps at [target]'s face!", 1)
if(ishuman(target))
var/mob/living/carbon/human/H = target
if(ishuman(L))
var/mob/living/carbon/human/H = L
if(H.head && H.head.flags & HEADCOVERSMOUTH)
for(var/mob/O in viewers(H, null))
O.show_message("\red \b [src] smashes against [H]'s [H.head]!", 1)
H.visible_message("\red \b [src] smashes against [H]'s [H.head]!")
Die()
return
if(target.wear_mask)
if(prob(20)) return
var/obj/item/clothing/W = target.wear_mask
if(!W.canremove) return
target.drop_from_inventory(W)
if(iscarbon(M))
var/mob/living/carbon/target = L
for(var/mob/O in viewers(target, null))
O.show_message("\red \b [src] tears [W] off of [target]'s face!", 1)
if(target.wear_mask)
if(prob(20)) return
var/obj/item/clothing/W = target.wear_mask
if(!W.canremove) return
target.drop_from_inventory(W)
if(prob(75))
loc = target
layer = 20
target.wear_mask = src
target.update_inv_wear_mask()
target.visible_message("\red \b [src] tears [W] off of [target]'s face!")
GoIdle() //so it doesn't jump the people that tear it off
target.equip_to_slot(src, slot_wear_mask)
if(!sterile) target.Paralyse(MAX_IMPREGNATION_TIME/6) //something like 25 ticks = 20 seconds with the default settings
if(!sterile) L.Paralyse(MAX_IMPREGNATION_TIME/6) //something like 25 ticks = 20 seconds with the default settings
else if (iscorgi(M))
var/mob/living/simple_animal/corgi/C = M
src.loc = C
C.facehugger = src
C.wear_mask = src
//C.regenerate_icons()
spawn(rand(MIN_IMPREGNATION_TIME,MAX_IMPREGNATION_TIME))
Impregnate(target)
else
for(var/mob/O in viewers(target, null))
O.show_message("\red \b [src] misses [target]'s face!", 1)
GoIdle() //so it doesn't jump the people that tear it off
spawn(rand(MIN_IMPREGNATION_TIME,MAX_IMPREGNATION_TIME))
Impregnate(L)
return
/obj/item/clothing/mask/facehugger/proc/Impregnate(mob/living/carbon/target as mob)
/obj/item/clothing/mask/facehugger/proc/Impregnate(mob/living/target as mob)
if(!target || target.wear_mask != src || target.stat == DEAD) //was taken off or something
return
if(!sterile)
target.contract_disease(new /datum/disease/alien_embryo(0)) //so infection chance is same as virus infection chance
for(var/datum/disease/alien_embryo/A in target.viruses)
target.status_flags |= XENO_HOST
break
//target.contract_disease(new /datum/disease/alien_embryo(0)) //so infection chance is same as virus infection chance
new /obj/item/alien_embryo(target)
target.status_flags |= XENO_HOST
for(var/mob/O in viewers(target,null))
O.show_message("\red \b [src] falls limp after violating [target]'s face!", 1)
target.visible_message("\red \b [src] falls limp after violating [target]'s face!")
Die()
icon_state = "[initial(icon_state)]_impregnated"
if(iscorgi(target))
var/mob/living/simple_animal/corgi/C = target
src.loc = get_turf(C)
C.facehugger = null
else
for(var/mob/O in viewers(target,null))
O.show_message("\red \b [src] violates [target]'s face!", 1)
target.update_inv_wear_mask()
target.visible_message("\red \b [src] violates [target]'s face!")
return
/obj/item/clothing/mask/facehugger/proc/GoActive()
@@ -210,16 +220,15 @@ var/const/MAX_ACTIVE_TIME = 400
icon_state = "[initial(icon_state)]_dead"
stat = DEAD
for(var/mob/O in viewers(src, null))
O.show_message("\red \b[src] curls up into a ball!", 1)
src.visible_message("\red \b[src] curls up into a ball!")
return
/obj/item/clothing/mask/facehugger/HasProximity(atom/movable/AM as mob|obj)
if(CanHug(AM))
Attach(AM)
/proc/CanHug(var/mob/M)
if(iscorgi(M))
return 1
if(!iscarbon(M) || isalien(M))
return 0
var/mob/living/carbon/C = M
@@ -227,4 +236,4 @@ var/const/MAX_ACTIVE_TIME = 400
var/mob/living/carbon/human/H = C
if(H.head && H.head.flags & HEADCOVERSMOUTH)
return 0
return 1
return 1
@@ -42,7 +42,7 @@
return 1
if (istype(other, /mob/living/carbon/human))
return 1
if (istype(other, /mob/living/carbon/metroid))
if (istype(other, /mob/living/carbon/slime))
return 1
return ..()
@@ -23,7 +23,7 @@
brainmob.client.screen.len = null //clear the hud
proc
transfer_identity(var/mob/living/carbon/human/H)
transfer_identity(var/mob/living/carbon/H)
name = "[H]'s brain"
brainmob = new(src)
brainmob.name = H.real_name
@@ -32,7 +32,7 @@
brainmob.timeofhostdeath = H.timeofdeath
if(H.mind)
H.mind.transfer_to(brainmob)
brainmob << "\blue You might feel slightly disoriented. That's normal when your brain gets cut out."
brainmob << "\blue You feel slightly disoriented. That's normal when you're just a brain."
return
/obj/item/brain/examine() // -- TLE
@@ -41,10 +41,10 @@
return
usr << "This is \icon[src] \an [name]."
if(brainmob)//if thar be a brain inside... the brain.
if(brainmob && brainmob.client)//if thar be a brain inside... the brain.
usr << "You can feel the small spark of life still left in this one."
else
usr << "This one seems particularly lifeless. Perhaps it will regain some of its luster later. Probably not."
usr << "This one seems particularly lifeless. Perhaps it will regain some of its luster later.."
/obj/item/brain/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
if(!istype(M, /mob))
+7 -8
View File
@@ -59,15 +59,15 @@
return
for(var/datum/disease/D in viruses)
world << "1 [D.spread]"
if(D.spread_by_touch())
world << "1 contract"
M.contract_disease(D, 0, 1, CONTACT_HANDS)
for(var/datum/disease/D in M.viruses)
world << "2 [D.spread]"
if(D.spread_by_touch())
world << "2 contract"
contract_disease(D, 0, 1, CONTACT_HANDS)
return
@@ -151,7 +151,7 @@
swap_hand()
/mob/living/carbon/proc/help_shake_act(mob/living/carbon/M)
if (src.health > config.health_threshold_crit)
if (src.health >= config.health_threshold_crit)
if(src == M && istype(src, /mob/living/carbon/human))
var/mob/living/carbon/human/H = src
src.visible_message( \
@@ -412,10 +412,9 @@
item.throw_at(target, item.throw_range, item.throw_speed)
/mob/living/carbon/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
if(exposed_temperature > CARBON_LIFEFORM_FIRE_RESISTANCE)
adjustFireLoss(CARBON_LIFEFORM_FIRE_DAMAGE)
/mob/living/carbon/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume)
..()
bodytemperature = max(bodytemperature, BODYTEMP_HEAT_DAMAGE_LIMIT+10)
/mob/living/carbon/can_use_hands()
if(handcuffed)
@@ -1,9 +1,9 @@
/mob/living/carbon/
gender = MALE
var/list/stomach_contents = list()
var/brain_op_stage = 0.0
var/datum/disease2/disease/virus2 = null
var/list/datum/disease2/disease/resistances2 = list()
var/antibodies = 0
var/silent = null //Can't talk. Value goes down every life proc.
@@ -17,5 +17,4 @@
var/obj/item/handcuffed = null //Whether or not the mob is handcuffed
var/obj/item/legcuffed = null //Same as handcuffs but for legs. Bear traps use this.
//Surgery info
var/brain_op_stage = 0.0
var/datum/surgery_status/op_stage = new/datum/surgery_status
+14 -13
View File
@@ -191,7 +191,7 @@
msg += "<span class='warning'>[t_He] [t_is] twitching ever so slightly.</span>\n"
if(suiciding)
msg += "<span class='warning'>[t_He] [t_has] bitten off [t_his] own tongue and [t_has] suffered major bloodloss!</span>\n"
msg += "<span class='warning'>[t_He] appears to have commited suicide... there is no hope of recovery.</span>\n"
if(mSmallsize in mutations)
msg += "[t_He] [t_is] small halfling!\n"
@@ -396,23 +396,24 @@
var/criminal = "None"
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
var/obj/item/weapon/card/id/I = wear_id.GetID()
if(I)
perpname = I.registered_name
else
perpname = name
else
perpname = name
for (var/datum/data/record/E in data_core.general)
if(E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if(R.fields["id"] == E.fields["id"])
criminal = R.fields["criminal"]
if(perpname)
for (var/datum/data/record/E in data_core.general)
if(E.fields["name"] == perpname)
for (var/datum/data/record/R in data_core.security)
if(R.fields["id"] == E.fields["id"])
criminal = R.fields["criminal"]
msg += "<span class = 'deptradio'>Criminal status:</span> <a href='?src=\ref[src];criminal=1'>\[[criminal]\]</a>\n"
//msg += "\[Set Hostile Identification\]\n"
msg += "<span class = 'deptradio'>Criminal status:</span> <a href='?src=\ref[src];criminal=1'>\[[criminal]\]</a>\n"
//msg += "\[Set Hostile Identification\]\n"
if(print_flavor_text()) msg += "[print_flavor_text()]\n"
+1 -9
View File
@@ -482,7 +482,7 @@
mymob.zone_sel = new /obj/screen/zone_sel( null )
mymob.zone_sel.icon = ui_style
mymob.zone_sel.overlays = null
mymob.zone_sel.overlays.Cut()
mymob.zone_sel.overlays += image('icons/mob/zone_sel.dmi', "[mymob.zone_sel.selecting]")
mymob.client.screen = null
@@ -598,10 +598,6 @@ Radar-related things
if(M.stat == 2) continue
found_targets.Add(M)
for(var/obj/effect/critter/C in orange(max_dist, distance_ref))
if(!C.alive) continue
found_targets.Add(C)
for(var/obj/mecha/M in orange(max_dist, distance_ref))
if(!M.occupant) continue
found_targets.Add(M)
@@ -655,10 +651,6 @@ Radar-related things
blip.icon_state = "unknownblip"
blip.name = "Unknown Organism"
else if(istype(A, /obj/effect/critter))
blip.icon_state = "unknownblip"
blip.name = "Unknown Organism"
else if(istype(A, /obj/mecha))
blip.icon_state = "roboblip"
blip.name = "Robotic Organism"
+21 -114
View File
@@ -144,9 +144,9 @@
loc = tmob.loc
tmob.loc = oldloc
now_pushing = 0
for(var/mob/living/carbon/metroid/Metroid in view(1,tmob))
if(Metroid.Victim == tmob)
Metroid.UpdateFeed()
for(var/mob/living/carbon/slime/slime in view(1,tmob))
if(slime.Victim == tmob)
slime.UpdateFeed()
return
if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations))
@@ -324,110 +324,6 @@
updatehealth()
return
/mob/living/carbon/human/Move(a, b, flag)
if (buckled)
return
if (restrained())
stop_pulling()
var/t7 = 1
if (restrained())
for(var/mob/living/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at [__LINE__] in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (isliving(pulling))
var/mob/living/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [] has been pulled from []'s grip by []", G.affecting, G.assailant, src), 1)
//G = null
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
//this is the gay blood on floor shit -- Added back -- Skie
if (M.lying && (prob(M.getBruteLoss() / 6)))
var/turf/location = M.loc
if (istype(location, /turf/simulated))
location.add_blood(M)
if(ishuman(M))
var/mob/living/carbon/H = M
var/blood_volume = round(H:vessel.get_reagent_amount("blood"))
if(blood_volume > 0)
H:vessel.remove_reagent("blood",1)
if(prob(5))
M.adjustBruteLoss(1)
visible_message("\red \The [M]'s wounds open more from being dragged!")
if(M.pull_damage())
if(prob(25))
M.adjustBruteLoss(2)
visible_message("\red \The [M]'s wounds worsen terribly from being dragged!")
var/turf/location = M.loc
if (istype(location, /turf/simulated))
location.add_blood(M)
if(ishuman(M))
var/mob/living/carbon/H = M
var/blood_volume = round(H:vessel.get_reagent_amount("blood"))
if(blood_volume > 0)
H:vessel.remove_reagent("blood",1)
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
if (istype(pulling, /obj/structure/window))
if(pulling:ini_dir == NORTHWEST || pulling:ini_dir == NORTHEAST || pulling:ini_dir == SOUTHWEST || pulling:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(pulling,get_dir(pulling.loc, T)))
stop_pulling()
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
for(var/mob/living/carbon/metroid/M in view(1,src))
M.UpdateFeed(src)
return
/mob/living/carbon/human/hand_p(mob/M as mob)
var/dam_zone = pick("chest", "l_hand", "r_hand", "l_leg", "r_leg")
@@ -464,7 +360,7 @@
if(armor >= 2) return
/mob/living/carbon/human/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/carbon/human/attack_slime(mob/living/carbon/slime/M as mob)
if(M.Victim) return // can't attack while eating!
if (health > -100)
@@ -475,7 +371,7 @@
var/damage = rand(1, 3)
if(istype(M, /mob/living/carbon/metroid/adult))
if(istype(M, /mob/living/carbon/slime/adult))
damage = rand(10, 35)
else
damage = rand(5, 25)
@@ -686,15 +582,26 @@
if(istype(usr, /mob/living/carbon/human))
var/mob/living/carbon/human/H = usr
if(istype(H.glasses, /obj/item/clothing/glasses/hud/security) || istype(H.glasses, /obj/item/clothing/glasses/sunglasses/sechud))
/* // Uncomment if you want sechuds to need security access
var/allowed_access = 0
if(H.wear_id)
var/list/access = H.wear_id.GetAccess()
if(access_security in access)
allowed_access = 1
return
if(!allowed_access)
H << "<span class='warning'>ERROR: Invalid Access</span>"
return
*/
var/perpname = "wot"
var/modified = 0
if(wear_id)
if(istype(wear_id,/obj/item/weapon/card/id))
perpname = wear_id:registered_name
else if(istype(wear_id,/obj/item/device/pda))
var/obj/item/device/pda/tempPda = wear_id
perpname = tempPda.owner
var/obj/item/weapon/card/id/I = wear_id.GetID()
perpname = I.registered_name
else
perpname = src.name
@@ -57,8 +57,7 @@
switch(M.a_intent)
if("help")
if(health > config.health_threshold_crit)
diary << "\[[time2text(world.timeofday, "hh:mm.ss")]\] CPR BUGHINTING: [M] shakes [src]: health - [health], threshold - [config.health_threshold_crit]. Health details: OX [getOxyLoss()] TX [getToxLoss()] BU [getFireLoss()] BR [getBruteLoss()] Blood: [round(vessel.get_reagent_amount("blood"))] out of 560"
if(health >= config.health_threshold_crit)
help_shake_act(M)
return 1
// if(M.health < -75) return 0
@@ -35,7 +35,7 @@
var/obj/item/glasses = null
var/obj/item/head = null
var/obj/item/ears = null
var/obj/item/weapon/card/id/wear_id = null
var/obj/item/wear_id = null
var/obj/item/r_store = null
var/obj/item/l_store = null
var/obj/item/s_store = null
@@ -364,6 +364,7 @@
if("mask")
if(target.wear_mask && !target.wear_mask.canremove)
message = "\red <B>[source] fails to take off \a [target.wear_mask] from [target]'s head!</B>"
return
else
message = "\red <B>[source] is trying to take off \a [source.wear_mask] from [target]'s head!</B>"
if("l_hand")
@@ -373,26 +374,31 @@
if("gloves")
if(target.gloves && !target.gloves.canremove)
message = "\red <B>[source] fails to take off \a [target.gloves] from [target]'s hands!</B>"
return
else
message = "\red <B>[source] is trying to take off the [target.gloves] from [target]'s hands!</B>"
if("eyes")
if(target.glasses && !target.glasses.canremove)
message = "\red <B>[source] fails to take off \a [target.glasses] from [target]'s eyes!</B>"
return
else
message = "\red <B>[source] is trying to take off the [target.glasses] from [target]'s eyes!</B>"
if("ears")
if(target.ears && !target.ears.canremove)
message = "\red <B>[source] fails to take off \a [target.ears] from [target]'s ears!</B>"
return
else
message = "\red <B>[source] is trying to take off the [target.ears] from [target]'s ears!</B>"
if("head")
if(target.head && !target.head.canremove)
message = "\red <B>[source] fails to take off \a [target.head] from [target]'s head!</B>"
return
else
message = "\red <B>[source] is trying to take off the [target.head] from [target]'s head!</B>"
if("shoes")
if(target.shoes && !target.shoes.canremove)
message = "\red <B>[source] fails to take off \a [target.shoes] from [target]'s feet!</B>"
return
else
message = "\red <B>[source] is trying to take off the [target.shoes] from [target]'s feet!</B>"
if("belt")
@@ -400,6 +406,7 @@
if("suit")
if(target.wear_suit && !target.wear_suit.canremove)
message = "\red <B>[source] fails to take off \a [target.wear_suit] from [target]'s body!</B>"
return
else
message = "\red <B>[source] is trying to take off \a [target.wear_suit] from [target]'s body!</B>"
if("back")
@@ -414,6 +421,7 @@
return
if(target.w_uniform && !target.w_uniform.canremove)
message = "\red <B>[source] fails to take off \a [target.w_uniform] from [target]'s body!</B>"
return
else
message = "\red <B>[source] is trying to take off \a [target.w_uniform] from [target]'s body!</B>"
if("s_store")
@@ -466,11 +474,11 @@ It can still be worn/put on as normal.
switch(place) //here we go again...
if("mask")
slot_to_process = slot_wear_mask
if (target.wear_mask)
if (target.wear_mask && target.wear_mask.canremove)
strip_item = target.wear_mask
if("gloves")
slot_to_process = slot_gloves
if (target.gloves)
if (target.gloves && target.gloves.canremove)
strip_item = target.gloves
if("eyes")
slot_to_process = slot_glasses
@@ -486,7 +494,7 @@ It can still be worn/put on as normal.
strip_item = target.s_store
if("head")
slot_to_process = slot_head
if (target.head)
if (target.head && target.head.canremove)
strip_item = target.head
if("ears")
slot_to_process = slot_ears
@@ -494,7 +502,7 @@ It can still be worn/put on as normal.
strip_item = target.ears
if("shoes")
slot_to_process = slot_shoes
if (target.shoes)
if (target.shoes && target.shoes.canremove)
strip_item = target.shoes
if("l_hand")
if (istype(target, /obj/item/clothing/suit/straight_jacket))
@@ -510,11 +518,11 @@ It can still be worn/put on as normal.
strip_item = target.r_hand
if("uniform")
slot_to_process = slot_w_uniform
if (target.w_uniform)
if(target.w_uniform && target.w_uniform.canremove)
strip_item = target.w_uniform
if("suit")
slot_to_process = slot_wear_suit
if (target.wear_suit)
if (target.wear_suit && target.wear_suit.canremove)
strip_item = target.wear_suit
if("id")
slot_to_process = slot_wear_id
+5 -12
View File
@@ -1340,11 +1340,9 @@ var/const/BLOOD_VOLUME_SURVIVE = 122
sight &= ~(SEE_TURFS|SEE_MOBS|SEE_OBJS)
if(dna)
switch(dna.mutantrace)
if("metroid")
if("lizard","slime")
see_in_dark = 3
see_invisible = SEE_INVISIBLE_LEVEL_ONE
if("lizard")
see_in_dark = 3
if("tajaran")
see_in_dark = 4
if("shadow")
@@ -1415,15 +1413,10 @@ var/const/BLOOD_VOLUME_SURVIVE = 122
if(!druggy) see_invisible = SEE_INVISIBLE_LIVING
else if(istype(glasses, /obj/item/clothing/glasses/hud))
var/obj/item/clothing/glasses/hud/health/O = glasses
if(istype(O, /obj/item/clothing/glasses/hud/health))
O.process_hud(src)
if(!druggy) see_invisible = SEE_INVISIBLE_LIVING
else if(istype(O, /obj/item/clothing/glasses/hud/security))
O.process_hud(src)
if(!druggy) see_invisible = SEE_INVISIBLE_LIVING
var/obj/item/clothing/glasses/hud/O = glasses
O.process_hud(src)
if(!druggy)
see_invisible = SEE_INVISIBLE_LIVING
else
see_invisible = SEE_INVISIBLE_LIVING
else
+3 -3
View File
@@ -22,7 +22,7 @@
/*if(src.dna.mutantrace == "lizard") //Soghun stutterss-s-ss-sss.
if(copytext(message, 1, 2) != "*")
message = replacetext(message, "s", stutter("ss"))*/
if(src.dna.mutantrace == "metroid" && prob(5))
if(src.dna.mutantrace == "slime" && prob(5))
if(copytext(message, 1, 2) != "*")
if(copytext(message, 1, 2) == ";")
message = ";"
@@ -69,7 +69,7 @@
if(prob(25))
message += " OLE!"
if ((HULK in mutations) && health >= 25)
if ((HULK in mutations) && health >= 25 && length(message))
if(copytext(message, 1, 2) != "*")
message = "[uppertext(message)]!!" //because I don't know how to code properly in getting vars from other files -Bro
@@ -135,7 +135,7 @@
return 1
if (istype(other, /mob/living/carbon/brain))
return 1
if (istype(other, /mob/living/carbon/metroid))
if (istype(other, /mob/living/carbon/slime))
return 1
return ..()
@@ -54,7 +54,7 @@ There are several things that need to be remembered:
All of these are named after the variable they update from. They are defined at the mob/ level like
update_clothing was, so you won't cause undefined proc runtimes with usr.update_inv_wear_id() if the usr is a
metroid etc. Instead, it'll just return without doing any work. So no harm in calling it for metroids and such.
slime etc. Instead, it'll just return without doing any work. So no harm in calling it for slimes and such.
> There are also these special cases:
@@ -133,7 +133,7 @@ Please contact me on #coderbus IRC. ~Carn x
lying_prev = lying //so we don't update overlays for lying/standing unless our stance changes again
update_hud() //TODO: remove the need for this
overlays = null
overlays.Cut()
if(lying) //can't be cloaked when lying. (for now)
icon = lying_icon
@@ -448,7 +448,7 @@ proc/get_damage_icon_part(damage_state, body_part)
//BS12 EDIT
if(dna)
switch(dna.mutantrace)
if("golem","metroid","shadow")
if("lizard","golem","slime","shadow","adamantine")
overlays_lying[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_l")
overlays_standing[MUTANTRACE_LAYER] = image("icon" = 'icons/effects/genetics.dmi', "icon_state" = "[dna.mutantrace][fat]_[gender]_s")
if("lizard","tajaran","skrell")
@@ -1,12 +1,15 @@
/mob/living/carbon/metroid/death(gibbed)
/mob/living/carbon/slime/death(gibbed)
if(stat == DEAD) return
stat = DEAD
icon_state = "baby roro dead"
icon_state = "[colour] baby slime dead"
if(!gibbed)
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
ghostize()
explosion(loc, -1,-1,3,12)
var/mob/living/carbon/slime/M1 = new primarytype(loc)
M1.rabid = 1
var/mob/living/carbon/slime/M2 = new primarytype(loc)
M2.rabid = 1
if(src) del(src)
else
for(var/mob/O in viewers(src, null))
@@ -1,4 +1,4 @@
/mob/living/carbon/metroid/emote(var/act)
/mob/living/carbon/slime/emote(var/act)
if (findtext(act, "-", 1, null))
@@ -16,11 +16,6 @@
if("moan")
message = "<B>The [src.name]</B> moans."
m_type = 2
// if("roar")
// if (!muzzled)
// message = "<B>The [src.name]</B> roars." Commenting out since larva shouldn't roar /N
// m_type = 2
if("shiver")
message = "<B>The [src.name]</B> shivers."
m_type = 2
@@ -36,17 +31,11 @@
if("light")
message = "<B>The [src.name]</B> lights up for a bit, then stops."
m_type = 1
if("click")
message = "<B>The [src.name]</B> makes a clicking noise!"
if("jiggle")
message = "<B>The [src.name]</B> jiggles!"
m_type = 1
if("chatter")
message = "<B>The [src.name]</B> makes a noisy chattering sound!"
m_type = 1
if("growl")
message = "<B>The [src.name]</B> growls!"
m_type = 1
if("shriek")
message = "<B>The [src.name]</B> makes a high-pitched shriek!"
if("bounce")
message = "<B>The [src.name]</B> bounces in place."
m_type = 1
else
src << text("Invalid Emote: []", act)
@@ -1,4 +1,4 @@
/mob/living/carbon/metroid/examine()
/mob/living/carbon/slime/examine()
set src in oview()
if(!usr || !src) return
@@ -1,4 +1,4 @@
/mob/living/carbon/metroid/proc/regular_hud_updates()
/mob/living/carbon/slime/proc/regular_hud_updates()
return
+86 -46
View File
@@ -1,4 +1,4 @@
/mob/living/carbon/metroid/Life()
/mob/living/carbon/slime/Life()
set invisibility = 0
set background = 1
@@ -41,21 +41,21 @@
/mob/living/carbon/metroid
/mob/living/carbon/slime
var/AIproc = 0 // determines if the AI loop is activated
var/Atkcool = 0 // attack cooldown
var/Tempstun = 0 // temporary temperature stuns
var/Discipline = 0 // if a metroid has been hit with a freeze gun, or wrestled/attacked off a human, they become disciplined and don't attack anymore for a while
var/Discipline = 0 // if a slime has been hit with a freeze gun, or wrestled/attacked off a human, they become disciplined and don't attack anymore for a while
var/SStun = 0 // stun variable
/mob/living/carbon/metroid/proc/AIprocess() // the master AI process
/mob/living/carbon/slime/proc/AIprocess() // the master AI process
//world << "AI proc started."
if(AIproc || stat == DEAD || client) return
var/hungry = 0
var/starving = 0
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
switch(nutrition)
if(400 to 1100) hungry = 1
if(0 to 399)
@@ -84,7 +84,7 @@
if(Target)
//world << "[Target] Target Found"
for(var/mob/living/carbon/metroid/M in view(1,Target))
for(var/mob/living/carbon/slime/M in view(1,Target))
if(M.Victim == Target)
Target = null
AIproc = 0
@@ -104,7 +104,7 @@
Atkcool = 0
if(get_obstacle_ok(Target))
Target.attack_metroid(src)
Target.attack_slime(src)
//world << "retrun 1"
return
if(!Target.lying && prob(80))
@@ -117,7 +117,7 @@
Atkcool = 0
if(get_obstacle_ok(Target))
Target.attack_metroid(src)
Target.attack_slime(src)
if(prob(30))
@@ -145,12 +145,12 @@
var/sleeptime = movement_delay()
if(sleeptime <= 0) sleeptime = 1
sleep(sleeptime + 2) // this is about as fast as a player Metroid can go
sleep(sleeptime + 2) // this is about as fast as a player slime can go
AIproc = 0
//world << "AI proc ended."
/mob/living/carbon/metroid/proc/handle_environment(datum/gas_mixture/environment)
/mob/living/carbon/slime/proc/handle_environment(datum/gas_mixture/environment)
if(!environment)
adjustToxLoss(rand(10,20))
return
@@ -208,7 +208,7 @@
return //TODO: DEFERRED
/mob/living/carbon/metroid/proc/adjust_body_temperature(current, loc_temp, boost)
/mob/living/carbon/slime/proc/adjust_body_temperature(current, loc_temp, boost)
var/temperature = current
var/difference = abs(current-loc_temp) //get difference
var/increments// = difference/10 //find how many increments apart they are
@@ -225,7 +225,7 @@
temp_change = (temperature - current)
return temp_change
/mob/living/carbon/metroid/proc/handle_chemicals_in_body()
/mob/living/carbon/slime/proc/handle_chemicals_in_body()
if(reagents) reagents.metabolize(src)
@@ -235,9 +235,9 @@
return //TODO: DEFERRED
/mob/living/carbon/metroid/proc/handle_regular_status_updates()
/mob/living/carbon/slime/proc/handle_regular_status_updates()
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
health = 200 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
else
health = 150 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
@@ -315,10 +315,10 @@
return 1
/mob/living/carbon/metroid/proc/handle_nutrition()
/mob/living/carbon/slime/proc/handle_nutrition()
if(prob(20))
if(istype(src, /mob/living/carbon/metroid/adult)) nutrition-=rand(4,6)
if(istype(src, /mob/living/carbon/slime/adult)) nutrition-=rand(4,6)
else nutrition-=rand(2,3)
if(nutrition <= 0)
@@ -328,7 +328,7 @@
adjustToxLoss(rand(0,5))
else
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
if(nutrition >= 1000)
if(prob(40)) amount_grown++
@@ -336,29 +336,69 @@
if(nutrition >= 800)
if(prob(40)) amount_grown++
//lay eggs or grow
if(amount_grown >= 10 && !Victim && !Target)
if(istype(src, /mob/living/carbon/metroid/adult))
if(!client && nutrition >= 1000)
var/number = pick(1,1,1,1,1,1,2,2,2,3) //number of eggs laid
var/obj/item/weapon/reagent_containers/food/snacks/egg/roro/E
for(var/i=1,i<=number,i++)
E = new(loc)
src.nutrition -= 200
step_away(E,src)
if(istype(src, /mob/living/carbon/slime/adult))
if(!client)
for(var/i=1,i<=4,i++)
if(prob(70))
var/mob/living/carbon/slime/M = new primarytype(loc)
M.powerlevel = round(powerlevel/4)
M.Friends = Friends
M.tame = tame
M.rabid = rabid
M.Discipline = Discipline
if(i != 1) step_away(M,src)
else
var/mutations = pick("one","two","three","four")
switch(mutations)
if("one")
var/mob/living/carbon/slime/M = new mutationone(loc)
M.powerlevel = round(powerlevel/4)
M.Friends = Friends
M.tame = tame
M.rabid = rabid
M.Discipline = Discipline
if(i != 1) step_away(M,src)
if("two")
var/mob/living/carbon/slime/M = new mutationtwo(loc)
M.powerlevel = round(powerlevel/4)
M.Friends = Friends
M.tame = tame
M.rabid = rabid
M.Discipline = Discipline
if(i != 1) step_away(M,src)
if("three")
var/mob/living/carbon/slime/M = new mutationthree(loc)
M.powerlevel = round(powerlevel/4)
M.Friends = Friends
M.tame = tame
M.rabid = rabid
M.Discipline = Discipline
if(i != 1) step_away(M,src)
if("four")
var/mob/living/carbon/slime/M = new mutationfour(loc)
M.powerlevel = round(powerlevel/4)
M.Friends = Friends
M.tame = tame
M.rabid = rabid
M.Discipline = Discipline
if(i != 1) step_away(M,src)
del(src)
else
if(!client)
var/mob/living/carbon/metroid/adult/A = new/mob/living/carbon/metroid/adult(src.loc)
var/mob/living/carbon/slime/adult/A = new adulttype(src.loc)
A.nutrition = nutrition
A.nutrition += 100
// A.nutrition += 100
A.powerlevel = max(0, powerlevel-1)
A.Friends = Friends
A.tame = tame
A.rabid = rabid
del(src)
/mob/living/carbon/metroid/proc/handle_targets()
/mob/living/carbon/slime/proc/handle_targets()
if(Tempstun)
if(!Victim) // not while they're eating!
canmove = 0
@@ -393,15 +433,15 @@
if(Victim) return // if it's eating someone already, continue eating!
if(prob(5))
emote(pick("click","chatter","sway","light","vibrate","chatter","shriek"))
if(prob(1))
emote(pick("bounce","sway","light","vibrate","jiggle"))
if(AIproc && SStun) return
var/hungry = 0 // determines if the metroid is hungry
var/starving = 0 // determines if the metroid is starving-hungry
if(istype(src, /mob/living/carbon/metroid/adult)) // 1200 max nutrition
var/hungry = 0 // determines if the slime is hungry
var/starving = 0 // determines if the slime is starving-hungry
if(istype(src, /mob/living/carbon/slime/adult)) // 1200 max nutrition
switch(nutrition)
if(601 to 900)
if(prob(25)) hungry = 1//Ensures they continue eating, but aren't as aggressive at the same time
@@ -417,7 +457,7 @@
if(0 to 200) starving = 1
if(starving && !client) // if a metroid is starving, it starts losing its friends
if(starving && !client) // if a slime is starving, it starts losing its friends
if(Friends.len > 0 && prob(1))
var/mob/nofriend = pick(Friends)
Friends -= nofriend
@@ -428,42 +468,42 @@
if(hungry || starving) //Only add to the list if we need to
for(var/mob/living/L in view(7,src))
//Ignore other metroids, dead mobs and simple_animals
if(ismetroid(L) || L.stat != CONSCIOUS || isanimal(L))
//Ignore other slimes, dead mobs and simple_animals
if(isslime(L) || L.stat != CONSCIOUS || isanimal(L))
continue
if(issilicon(L))
if(!istype(src, /mob/living/carbon/metroid/adult)) //Non-starving diciplined adult metroids wont eat things
if(!istype(src, /mob/living/carbon/slime/adult)) //Non-starving diciplined adult slimes wont eat things
if(!starving && Discipline > 0)
continue
if(tame) //Tame metroids ignore electronic life
if(tame) //Tame slimes ignore electronic life
continue
targets += L //Possible target found!
else if(iscarbon(L))
if(istype(L, /mob/living/carbon/human)) //Ignore metroid(wo)men
if(istype(L, /mob/living/carbon/human)) //Ignore slime(wo)men
var/mob/living/carbon/human/H = L
if(H.dna)
if(H.dna.mutantrace == "metroid")
if(H.dna.mutantrace == "slime")
continue
if(!istype(src, /mob/living/carbon/metroid/adult)) //Non-starving diciplined adult metroids wont eat things
if(!istype(src, /mob/living/carbon/slime/adult)) //Non-starving diciplined adult slimes wont eat things
if(!starving && Discipline > 0)
continue
if(L in Friends) //No eating friends!
continue
if(tame && ishuman(L)) //Tame metroids dont eat people.
if(tame && ishuman(L)) //Tame slimes dont eat people.
continue
if(!L.canmove) //Only one metroid can latch on at a time.
if(!L.canmove) //Only one slime can latch on at a time.
var/notarget = 0
for(var/mob/living/carbon/metroid/M in view(1,L))
for(var/mob/living/carbon/slime/M in view(1,L))
if(M.Victim == L)
notarget = 1
if(notarget)
@@ -474,7 +514,7 @@
if((hungry || starving) && targets.len > 0)
if(!istype(src, /mob/living/carbon/metroid/adult))
if(!istype(src, /mob/living/carbon/slime/adult))
if(!starving)
for(var/mob/living/carbon/C in targets)
if(!Discipline && prob(5))
@@ -1,4 +1,4 @@
/mob/living/carbon/metroid/Login()
/mob/living/carbon/slime/Login()
..()
update_hud()
return
+345 -146
View File
@@ -1,7 +1,7 @@
/mob/living/carbon/metroid
name = "baby roro"
icon = 'icons/mob/mob.dmi'
icon_state = "baby roro"
/mob/living/carbon/slime
name = "baby slime"
icon = 'icons/mob/slimes.dmi'
icon_state = "grey baby slime"
pass_flags = PASSTABLE
voice_message = "skree!"
say_message = "hums"
@@ -16,34 +16,46 @@
nutrition = 700 // 1000 = max
see_in_dark = 8
update_slimes = 0
// canstun and canweaken don't affect metroids because they ignore stun and weakened variables
// canstun and canweaken don't affect slimes because they ignore stun and weakened variables
// for the sake of cleanliness, though, here they are.
status_flags = CANPARALYSE|CANPUSH
var/cores = 3 // the number of /obj/item/metroid_core's the metroid has left inside
var/cores = 1 // the number of /obj/item/slime_extract's the slime has left inside
var/powerlevel = 0 // 1-10 controls how much electricity they are generating
var/amount_grown = 0 // controls how long the metroid has been overfed, if 10, grows into an adult
var/amount_grown = 0 // controls how long the slime has been overfed, if 10, grows into an adult
// if adult: if 10: reproduces
var/mob/living/Victim = null // the person the metroid is currently feeding on
var/mob/living/Target = null // AI variable - tells the Metroid to hunt this down
var/mob/living/Victim = null // the person the slime is currently feeding on
var/mob/living/Target = null // AI variable - tells the slime to hunt this down
var/attacked = 0 // determines if it's been attacked recently. Can be any number, is a cooloff-ish variable
var/tame = 0 // if set to 1, the Metroid will not eat humans ever, or attack them
var/rabid = 0 // if set to 1, the Metroid will attack and eat anything it comes in contact with
var/tame = 0 // if set to 1, the slime will not eat humans ever, or attack them
var/rabid = 0 // if set to 1, the slime will attack and eat anything it comes in contact with
var/list/Friends = list() // A list of potential friends
var/list/FriendsWeight = list() // A list containing values respective to Friends. This determines how many times a Metroid "likes" something. If the Metroid likes it more than 2 times, it becomes a friend
var/list/FriendsWeight = list() // A list containing values respective to Friends. This determines how many times a slime "likes" something. If the slime likes it more than 2 times, it becomes a friend
// Metroids pass on genetic data, so all their offspring have the same "Friends",
// slimes pass on genetic data, so all their offspring have the same "Friends",
/mob/living/carbon/metroid/adult
name = "adult roro"
icon = 'icons/mob/mob.dmi'
icon_state = "adult roro"
///////////TIME FOR SUBSPECIES
var/colour = "grey"
var/primarytype = /mob/living/carbon/slime
var/mutationone = /mob/living/carbon/slime/orange
var/mutationtwo = /mob/living/carbon/slime/metal
var/mutationthree = /mob/living/carbon/slime/blue
var/mutationfour = /mob/living/carbon/slime/purple
var/adulttype = /mob/living/carbon/slime/adult
var/coretype = /obj/item/slime_extract/grey
/mob/living/carbon/slime/adult
name = "adult slime"
icon = 'icons/mob/slimes.dmi'
icon_state = "grey adult slime"
health = 200
gender = NEUTER
@@ -52,25 +64,25 @@
nutrition = 800 // 1200 = max
/mob/living/carbon/metroid/New()
/mob/living/carbon/slime/New()
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(name == "baby roro")
name = text("baby roro ([rand(1, 1000)])")
if(name == "baby slime")
name = text("[colour] baby slime ([rand(1, 1000)])")
else
name = text("adult roro ([rand(1,1000)])")
name = text("[colour] adult slime ([rand(1,1000)])")
real_name = name
spawn (1)
regenerate_icons()
src << "\blue Your icons have been generated!"
..()
/mob/living/carbon/metroid/adult/New()
verbs.Remove(/mob/living/carbon/metroid/verb/ventcrawl)
/mob/living/carbon/slime/adult/New()
verbs.Remove(/mob/living/carbon/slime/verb/ventcrawl)
..()
/mob/living/carbon/metroid/movement_delay()
/mob/living/carbon/slime/movement_delay()
var/tally = 0
var/health_deficiency = (100 - health)
@@ -80,22 +92,22 @@
tally += (283.222 - bodytemperature) / 10 * 1.75
if(reagents)
if(reagents.has_reagent("hyperzine")) // hyperzine slows Metroids down
if(reagents.has_reagent("hyperzine")) // hyperzine slows slimes down
tally *= 2 // moves twice as slow
if(reagents.has_reagent("frostoil")) // frostoil also makes them move VEEERRYYYYY slow
tally *= 5
if(health <= 0) // if damaged, the metroid moves twice as slow
if(health <= 0) // if damaged, the slime moves twice as slow
tally *= 2
if (bodytemperature >= 330.23) // 135 F
return -1 // Metroids become supercharged at high temperatures
return -1 // slimes become supercharged at high temperatures
return tally+config.metroid_delay
return tally+config.slime_delay
/mob/living/carbon/metroid/Bump(atom/movable/AM as mob|obj, yes)
/mob/living/carbon/slime/Bump(atom/movable/AM as mob|obj, yes)
spawn( 0 )
if ((!( yes ) || now_pushing))
return
@@ -115,9 +127,9 @@
if(istype(AM, /obj/structure/window) || istype(AM, /obj/structure/grille))
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
if(nutrition <= 600 && !Atkcool)
AM.attack_metroid(src)
AM.attack_slime(src)
spawn()
Atkcool = 1
sleep(15)
@@ -125,7 +137,7 @@
else
if(nutrition <= 500 && !Atkcool)
if(prob(5))
AM.attack_metroid(src)
AM.attack_slime(src)
spawn()
Atkcool = 1
sleep(15)
@@ -134,7 +146,7 @@
if(ismob(AM))
var/mob/tmob = AM
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
if(istype(tmob, /mob/living/carbon/human))
if(prob(90))
now_pushing = 0
@@ -162,22 +174,22 @@
return
return
/mob/living/carbon/metroid/Process_Spacemove()
/mob/living/carbon/slime/Process_Spacemove()
return 2
/mob/living/carbon/metroid/Stat()
/mob/living/carbon/slime/Stat()
..()
statpanel("Status")
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
stat(null, "Health: [round((health / 200) * 100)]%")
else
stat(null, "Health: [round((health / 150) * 100)]%")
if (client.statpanel == "Status")
if(istype(src,/mob/living/carbon/metroid/adult))
if(istype(src,/mob/living/carbon/slime/adult))
stat(null, "Nutrition: [nutrition]/1200")
if(amount_grown >= 10)
stat(null, "You can reproduce!")
@@ -189,21 +201,28 @@
stat(null,"Power Level: [powerlevel]")
/mob/living/carbon/metroid/adjustFireLoss(amount)
/mob/living/carbon/slime/adjustFireLoss(amount)
..(-abs(amount)) // Heals them
return
/mob/living/carbon/metroid/bullet_act(var/obj/item/projectile/Proj)
/mob/living/carbon/slime/bullet_act(var/obj/item/projectile/Proj)
attacked += 10
..(Proj)
return 0
/mob/living/carbon/metroid/emp_act(severity)
/mob/living/carbon/slime/emp_act(severity)
powerlevel = 0 // oh no, the power!
..()
/mob/living/carbon/metroid/ex_act(severity)
/mob/living/carbon/slime/ex_act(severity)
if (stat == 2 && client)
return
else if (stat == 2 && !client)
del(src)
return
var/b_loss = null
var/f_loss = null
@@ -227,7 +246,7 @@
updatehealth()
/mob/living/carbon/metroid/blob_act()
/mob/living/carbon/slime/blob_act()
if (stat == 2)
return
var/shielded = 0
@@ -249,14 +268,14 @@
return
/mob/living/carbon/metroid/u_equip(obj/item/W as obj)
/mob/living/carbon/slime/u_equip(obj/item/W as obj)
return
/mob/living/carbon/metroid/attack_ui(slot)
/mob/living/carbon/slime/attack_ui(slot)
return
/mob/living/carbon/metroid/meteorhit(O as obj)
/mob/living/carbon/slime/meteorhit(O as obj)
for(var/mob/M in viewers(src, null))
if ((M.client && !( M.blinded )))
M.show_message(text("\red [] has been hit by []", src, O), 1)
@@ -268,69 +287,7 @@
return
/mob/living/carbon/metroid/Move(a, b, flag)
var/t7 = 1
if (restrained())
for(var/mob/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at __LINE__ in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (ismob(pulling))
var/mob/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [] has been pulled from []'s grip by []", G.affecting, G.assailant, src), 1)
//G = null
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
return
/mob/living/carbon/metroid/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/carbon/slime/attack_slime(mob/living/carbon/slime/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -346,7 +303,7 @@
var/damage = rand(1, 3)
attacked += 5
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
damage = rand(1, 6)
else
damage = rand(1, 3)
@@ -359,7 +316,7 @@
return
/mob/living/carbon/metroid/attack_animal(mob/living/simple_animal/M as mob)
/mob/living/carbon/slime/attack_animal(mob/living/simple_animal/M as mob)
if(M.melee_damage_upper == 0)
M.emote("[M.friendly] [src]")
else
@@ -373,7 +330,7 @@
adjustBruteLoss(damage)
updatehealth()
/mob/living/carbon/metroid/attack_paw(mob/living/carbon/monkey/M as mob)
/mob/living/carbon/slime/attack_paw(mob/living/carbon/monkey/M as mob)
if(!(istype(M, /mob/living/carbon/monkey))) return//Fix for aliens receiving double messages when attacking other aliens.
if (!ticker)
@@ -394,16 +351,16 @@
return
if (health > 0)
attacked += 10
playsound(loc, 'sound/weapons/bite.ogg', 50, 1, -1)
//playsound(loc, 'sound/weapons/bite.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
O.show_message(text("\red <B>[M.name] has attacked [src]!</B>"), 1)
adjustBruteLoss(rand(1, 3))
updatehealth()
return
/mob/living/carbon/metroid/attack_hand(mob/living/carbon/human/M as mob)
/mob/living/carbon/slime/attack_hand(mob/living/carbon/human/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -459,7 +416,7 @@
if(prob(80) && !client)
Discipline++
if(!istype(src, /mob/living/carbon/metroid/adult))
if(!istype(src, /mob/living/carbon/slime/adult))
if(Discipline == 1)
attacked = 0
@@ -559,7 +516,7 @@
/mob/living/carbon/metroid/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
/mob/living/carbon/slime/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -584,7 +541,7 @@
damage = rand(20, 40)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has slashed [name]!</B>", M), 1)
O.show_message(text("\red <B>[] has attacked [name]!</B>", M), 1)
else
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
@@ -628,7 +585,7 @@
anchored = 0
if(prob(80) && !client)
Discipline++
if(!istype(src, /mob/living/carbon/metroid))
if(!istype(src, /mob/living/carbon/slime))
if(Discipline == 1)
attacked = 0
@@ -653,15 +610,15 @@
return
/mob/living/carbon/metroid/restrained()
/mob/living/carbon/slime/restrained()
return 0
mob/living/carbon/metroid/var/co2overloadtime = null
mob/living/carbon/metroid/var/temperature_resistance = T0C+75
mob/living/carbon/slime/var/co2overloadtime = null
mob/living/carbon/slime/var/temperature_resistance = T0C+75
/mob/living/carbon/metroid/show_inv(mob/user as mob)
/mob/living/carbon/slime/show_inv(mob/user as mob)
user.set_machine(src)
var/dat = {"
@@ -673,22 +630,22 @@ mob/living/carbon/metroid/var/temperature_resistance = T0C+75
onclose(user, "mob[name]")
return
/mob/living/carbon/metroid/updatehealth()
/mob/living/carbon/slime/updatehealth()
if(status_flags & GODMODE)
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
health = 200
else
health = 150
stat = CONSCIOUS
else
// metroids can't suffocate unless they suicide. They are also not harmed by fire
if(istype(src, /mob/living/carbon/metroid/adult))
// slimes can't suffocate unless they suicide. They are also not harmed by fire
if(istype(src, /mob/living/carbon/slime/adult))
health = 200 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
else
health = 150 - (getOxyLoss() + getToxLoss() + getFireLoss() + getBruteLoss() + getCloneLoss())
/mob/living/carbon/metroid/proc/get_obstacle_ok(atom/A)
/mob/living/carbon/slime/proc/get_obstacle_ok(atom/A)
var/direct = get_dir(src, A)
var/obj/item/weapon/dummy/D = new /obj/item/weapon/dummy( src.loc )
var/ok = 0
@@ -770,12 +727,251 @@ mob/living/carbon/metroid/var/temperature_resistance = T0C+75
return 1
// Basically this Metroid Core catalyzes reactions that normally wouldn't happen anywhere
/obj/item/metroid_core
name = "roro core"
desc = "A very slimy and tender part of a Rorobeast. Legends claim these to have \"magical powers\"."
icon = 'icons/obj/surgery.dmi'
icon_state = "roro core"
/obj/item/slime_extract
name = "slime extract"
desc = "Goo extracted from a slime. Legends claim these to have \"magical powers\"."
icon = 'icons/mob/slimes.dmi'
icon_state = "grey slime extract"
flags = TABLEPASS
force = 1.0
w_class = 1.0
throwforce = 1.0
throw_speed = 3
throw_range = 6
origin_tech = "biotech=4"
var/Uses = 1 // uses before it goes inert
/obj/item/slime_extract/New()
..()
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
/obj/item/slime_extract/grey
name = "grey slime extract"
icon_state = "grey slime extract"
/obj/item/slime_extract/gold
name = "gold slime extract"
icon_state = "gold slime extract"
/obj/item/slime_extract/silver
name = "silver slime extract"
icon_state = "silver slime extract"
/obj/item/slime_extract/metal
name = "metal slime extract"
icon_state = "metal slime extract"
/obj/item/slime_extract/purple
name = "purple slime extract"
icon_state = "purple slime extract"
/obj/item/slime_extract/darkpurple
name = "dark purple slime extract"
icon_state = "dark purple slime extract"
/obj/item/slime_extract/orange
name = "orange slime extract"
icon_state = "orange slime extract"
/obj/item/slime_extract/yellow
name = "yellow slime extract"
icon_state = "yellow slime extract"
/obj/item/slime_extract/red
name = "red slime extract"
icon_state = "red slime extract"
/obj/item/slime_extract/blue
name = "blue slime extract"
icon_state = "blue slime extract"
/obj/item/slime_extract/darkblue
name = "dark blue slime extract"
icon_state = "dark blue slime extract"
/obj/item/slime_extract/pink
name = "pink slime extract"
icon_state = "pink slime extract"
/obj/item/slime_extract/green
name = "green slime extract"
icon_state = "green slime extract"
/obj/item/slime_extract/lightpink
name = "light pink slime extract"
icon_state = "light pink slime extract"
/obj/item/slime_extract/black
name = "black slime extract"
icon_state = "black slime extract"
/obj/item/slime_extract/oil
name = "oil slime extract"
icon_state = "oil slime extract"
/obj/item/slime_extract/adamantine
name = "adamantine slime extract"
icon_state = "adamantine slime extract"
////Pet Slime Creation///
/obj/item/weapon/slimepotion
name = "docility potion"
desc = "A potent chemical mix that will nullify a slime's powers, causing it to become docile and tame."
icon = 'icons/obj/chemical.dmi'
icon_state = "bottle19"
attack(mob/living/carbon/slime/M as mob, mob/user as mob)
if(!istype(M, /mob/living/carbon/slime))//If target is not a slime.
user << "\red The potion only works on baby slimes!"
return ..()
if(istype(M, /mob/living/carbon/slime/adult)) //Can't tame adults
user << "\red Only baby slimes can be tamed!"
return..()
if(M.stat)
user << "\red The slime is dead!"
return..()
var/mob/living/simple_animal/slime/pet = new /mob/living/simple_animal/slime(M.loc)
pet.icon_state = "[M.colour] baby slime"
pet.icon_living = "[M.colour] baby slime"
pet.icon_dead = "[M.colour] baby slime dead"
pet.colour = "[M.colour]"
user <<"You feed the slime the potion, removing it's powers and calming it."
del (M)
var/newname = copytext(sanitize(input(user, "Would you like to give the slime a name?", "Name your new pet", "pet slime") as null|text),1,MAX_NAME_LEN)
if (!newname)
newname = "pet slime"
pet.name = newname
pet.real_name = newname
del (src)
/obj/item/weapon/slimepotion2
name = "advanced docility potion"
desc = "A potent chemical mix that will nullify a slime's powers, causing it to become docile and tame. This one is meant for adult slimes"
icon = 'icons/obj/chemical.dmi'
icon_state = "bottle19"
attack(mob/living/carbon/slime/adult/M as mob, mob/user as mob)
if(!istype(M, /mob/living/carbon/slime/adult))//If target is not a slime.
user << "\red The potion only works on adult slimes!"
return ..()
if(M.stat)
user << "\red The slime is dead!"
return..()
var/mob/living/simple_animal/adultslime/pet = new /mob/living/simple_animal/adultslime(M.loc)
pet.icon_state = "[M.colour] adult slime"
pet.icon_living = "[M.colour] adult slime"
pet.icon_dead = "[M.colour] baby slime dead"
pet.colour = "[M.colour]"
user <<"You feed the slime the potion, removing it's powers and calming it."
del (M)
var/newname = copytext(sanitize(input(user, "Would you like to give the slime a name?", "Name your new pet", "pet slime") as null|text),1,MAX_NAME_LEN)
if (!newname)
newname = "pet slime"
pet.name = newname
pet.real_name = newname
del (src)
/obj/item/weapon/slimesteroid
name = "slime steroid"
desc = "A potent chemical mix that will cause a slime to generate more extract."
icon = 'icons/obj/chemical.dmi'
icon_state = "bottle16"
attack(mob/living/carbon/slime/M as mob, mob/user as mob)
if(!istype(M, /mob/living/carbon/slime))//If target is not a slime.
user << "\red The steroid only works on baby slimes!"
return ..()
if(istype(M, /mob/living/carbon/slime/adult)) //Can't tame adults
user << "\red Only baby slimes can use the steroid!"
return..()
if(M.stat)
user << "\red The slime is dead!"
return..()
if(M.cores == 3)
user <<"\red The slime already has the maximum amount of extract!"
return..()
user <<"You feed the slime the steroid. It now has triple the amount of extract."
M.cores = 3
del (src)
////////Adamantine Golem stuff I dunno where else to put it
/obj/item/clothing/under/golem
name = "adamantine skin"
desc = "a golem's skin"
icon_state = "golem"
item_state = "golem"
color = "golem"
has_sensor = 0
armor = list(melee = 10, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)
canremove = 0
/obj/item/clothing/suit/golem
name = "adamantine shell"
desc = "a golem's thick outter shell"
icon_state = "golem"
item_state = "golem"
w_class = 4//bulky item
gas_transfer_coefficient = 0.90
permeability_coefficient = 0.50
body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
slowdown = 3.0
flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT
flags = FPRINT | TABLEPASS | ONESIZEFITSALL | STOPSPRESSUREDMAGE
heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
max_heat_protection_temperature = FIRESUIT_MAX_HEAT_PROTECITON_TEMPERATURE
cold_protection = UPPER_TORSO | LOWER_TORSO | LEGS | FEET | ARMS | HANDS
min_cold_protection_temperature = SPACE_SUIT_MIN_COLD_PROTECITON_TEMPERATURE
canremove = 0
armor = list(melee = 80, bullet = 20, laser = 20, energy = 10, bomb = 0, bio = 0, rad = 0)
/obj/item/clothing/shoes/golem
name = "golem's feet"
desc = "sturdy adamantine feet"
icon_state = "golem"
item_state = null
canremove = 0
flags = NOSLIP
slowdown = SHOES_SLOWDOWN+1
/obj/item/clothing/mask/gas/golem
name = "golem's face"
desc = "the imposing face of an adamantine golem"
icon_state = "golem"
item_state = "golem"
canremove = 0
siemens_coefficient = 0
unacidable = 1
/obj/item/clothing/gloves/golem
name = "golem's hands"
desc = "strong adamantine hands"
icon_state = "golem"
item_state = null
siemens_coefficient = 0
canremove = 0
//////////////////////////////Old shit from metroids/RoRos, and the old cores, would not take much work to re-add them////////////////////////
/*
// Basically this slime Core catalyzes reactions that normally wouldn't happen anywhere
/obj/item/slime_core
name = "slime extract"
desc = "Goo extracted from a slime. Legends claim these to have \"magical powers\"."
icon = 'icons/mob/slimes.dmi'
icon_state = "slime extract"
flags = TABLEPASS
force = 1.0
w_class = 1.0
@@ -787,7 +983,7 @@ mob/living/carbon/metroid/var/temperature_resistance = T0C+75
var/Flush = 30
var/Uses = 5 // uses before it goes inert
/obj/item/metroid_core/New()
/obj/item/slime_core/New()
..()
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
@@ -808,46 +1004,49 @@ mob/living/carbon/metroid/var/temperature_resistance = T0C+75
Flush = 30
*/
/obj/item/weapon/reagent_containers/food/snacks/egg/roro
name = "roro egg"
/obj/item/weapon/reagent_containers/food/snacks/egg/slime
name = "slime egg"
desc = "A small, gelatinous egg."
icon = 'icons/mob/mob.dmi'
icon_state = "roro egg-growing"
icon_state = "slime egg-growing"
bitesize = 12
origin_tech = "biotech=4"
var/grown = 0
/obj/item/weapon/reagent_containers/food/snacks/egg/roro/New()
/obj/item/weapon/reagent_containers/food/snacks/egg/slime/New()
..()
reagents.add_reagent("nutriment", 4)
reagents.add_reagent("rorojelly", 1)
reagents.add_reagent("slimejelly", 1)
spawn(rand(1200,1500))//the egg takes a while to "ripen"
Grow()
/obj/item/weapon/reagent_containers/food/snacks/egg/roro/proc/Grow()
/obj/item/weapon/reagent_containers/food/snacks/egg/slime/proc/Grow()
grown = 1
icon_state = "roro egg-grown"
icon_state = "slime egg-grown"
processing_objects.Add(src)
return
/obj/item/weapon/reagent_containers/food/snacks/egg/roro/proc/Hatch()
/obj/item/weapon/reagent_containers/food/snacks/egg/slime/proc/Hatch()
processing_objects.Remove(src)
var/turf/T = get_turf(src)
src.visible_message("\blue The [name] pulsates and quivers!")
spawn(rand(50,100))
src.visible_message("\blue The [name] bursts open!")
new/mob/living/carbon/metroid(T)
new/mob/living/carbon/slime(T)
del(src)
/obj/item/weapon/reagent_containers/food/snacks/egg/roro/process()
/obj/item/weapon/reagent_containers/food/snacks/egg/slime/process()
var/turf/location = get_turf(src)
var/datum/gas_mixture/environment = location.return_air()
if (environment.toxins > MOLES_PLASMA_VISIBLE)//plasma exposure causes the egg to hatch
src.Hatch()
/obj/item/weapon/reagent_containers/food/snacks/egg/roro/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/item/weapon/reagent_containers/food/snacks/egg/slime/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(istype( W, /obj/item/toy/crayon ))
return
else
..()
..()
*/
+104 -57
View File
@@ -1,5 +1,5 @@
/mob/living/carbon/metroid/verb/Feed()
set category = "Roro"
/mob/living/carbon/slime/verb/Feed()
set category = "Slime"
set desc = "This will let you feed on any valid creature in the surrounding area. This should also be used to halt the feeding process."
if(Victim)
Feedstop()
@@ -11,7 +11,7 @@
var/list/choices = list()
for(var/mob/living/C in view(1,src))
if(C!=src && !istype(C,/mob/living/carbon/metroid))
if(C!=src && !istype(C,/mob/living/carbon/slime))
choices += C
var/mob/living/carbon/M = input(src,"Who do you wish to feed on?") in null|choices
@@ -19,11 +19,11 @@
if(M in view(1, src))
if(!istype(src, /mob/living/carbon/brain))
if(!istype(M, /mob/living/carbon/metroid))
if(!istype(M, /mob/living/carbon/slime))
if(stat != 2)
if(health > -70)
for(var/mob/living/carbon/metroid/met in view())
for(var/mob/living/carbon/slime/met in view())
if(met.Victim == M && met != src)
src << "<i>The [met.name] is already feeding on this subject...</i>"
return
@@ -42,17 +42,17 @@
/mob/living/carbon/metroid/proc/Feedon(var/mob/living/carbon/M)
/mob/living/carbon/slime/proc/Feedon(var/mob/living/carbon/M)
Victim = M
src.loc = M.loc
canmove = 0
anchored = 1
var/lastnut = nutrition
//if(M.client) M << "\red You legs become paralyzed!"
if(istype(src, /mob/living/carbon/metroid/adult))
icon_state = "adult roro eat"
if(istype(src, /mob/living/carbon/slime/adult))
icon_state = "[colour] adult slime eat"
else
icon_state = "baby roro eat"
icon_state = "[colour] baby slime eat"
while(Victim && M.health > -70 && stat != 2)
// M.canmove = 0
@@ -84,9 +84,9 @@
adjustCloneLoss(-10)
if(Victim)
for(var/mob/living/carbon/metroid/Metroid in view(1,M))
if(Metroid.Victim == M && Metroid != src)
Metroid.Feedstop()
for(var/mob/living/carbon/slime/slime in view(1,M))
if(slime.Victim == M && slime != src)
slime.Feedstop()
nutrition += rand(10,25)
if(nutrition >= lastnut + 50)
@@ -96,7 +96,7 @@
if(powerlevel > 10)
powerlevel = 10
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
if(nutrition > 1200)
nutrition = 1200
else
@@ -119,97 +119,144 @@
break
if(stat == 2)
if(!istype(src, /mob/living/carbon/metroid/adult))
icon_state = "baby roro dead"
if(!istype(src, /mob/living/carbon/slime/adult))
icon_state = "[colour] baby slime dead"
else
if(istype(src, /mob/living/carbon/metroid/adult))
icon_state = "adult roro"
if(istype(src, /mob/living/carbon/slime/adult))
icon_state = "[colour] adult slime"
else
icon_state = "baby roro"
icon_state = "[colour] baby slime"
canmove = 1
anchored = 0
if(M.health <= -70)
M.canmove = 0
if(!client)
if(Victim && !rabid && !attacked)
if(Victim.LAssailant && Victim.LAssailant != Victim)
if(prob(50))
if(!(Victim.LAssailant in Friends))
Friends.Add(Victim.LAssailant) // no idea why i was using the |= operator
if(M)
if(M.health <= -70)
M.canmove = 0
if(!client)
if(Victim && !rabid && !attacked)
if(Victim.LAssailant && Victim.LAssailant != Victim)
if(prob(50))
if(!(Victim.LAssailant in Friends))
Friends.Add(Victim.LAssailant) // no idea why i was using the |= operator
if(M.client && istype(src, /mob/living/carbon/human))
if(prob(85))
rabid = 1 // UUUNNBGHHHH GONNA EAT JUUUUUU
if(M.client && istype(src, /mob/living/carbon/human))
if(prob(85))
rabid = 1 // UUUNNBGHHHH GONNA EAT JUUUUUU
if(client) src << "<i>This subject does not have a strong enough life energy anymore...</i>"
if(client) src << "<i>This subject does not have a strong enough life energy anymore...</i>"
else
M.canmove = 1
if(client) src << "<i>I have stopped feeding...</i>"
else
M.canmove = 1
if(client) src << "<i>I have stopped feeding...</i>"
Victim = null
/mob/living/carbon/metroid/proc/Feedstop()
/mob/living/carbon/slime/proc/Feedstop()
if(Victim)
if(Victim.client) Victim << "[src] has let go of your head!"
Victim = null
/mob/living/carbon/metroid/proc/UpdateFeed(var/mob/M)
/mob/living/carbon/slime/proc/UpdateFeed(var/mob/M)
if(Victim)
if(Victim == M)
loc = M.loc // simple "attach to head" effect!
/mob/living/carbon/metroid/verb/Evolve()
set category = "Roro"
set desc = "This will let you evolve from baby to adult metroid."
/mob/living/carbon/slime/verb/Evolve()
set category = "Slime"
set desc = "This will let you evolve from baby to adult slime."
if(stat)
src << "<i>I must be conscious to do this...</i>"
return
if(!istype(src, /mob/living/carbon/metroid/adult))
if(!istype(src, /mob/living/carbon/slime/adult))
if(amount_grown >= 10)
var/mob/living/carbon/metroid/adult/new_metroid = new /mob/living/carbon/metroid/adult(loc)
new_metroid.nutrition = nutrition
new_metroid.powerlevel = max(0, powerlevel-1)
new_metroid.a_intent = "hurt"
new_metroid.key = key
var/mob/living/carbon/slime/adult/new_slime = new adulttype(loc)
new_slime.nutrition = nutrition
new_slime.powerlevel = max(0, powerlevel-1)
new_slime.a_intent = "hurt"
new_slime.key = key
new_metroid << "<B>You are now an adult Metroid.</B>"
new_slime << "<B>You are now an adult slime.</B>"
del(src)
else
src << "<i>I am not ready to evolve yet...</i>"
else
src << "<i>I have already evolved...</i>"
/mob/living/carbon/metroid/verb/Reproduce()
set category = "Roro"
set desc = "This will make you lay an egg. NOTE: This decreases your nutrition."
/mob/living/carbon/slime/verb/Reproduce()
set category = "Slime"
set desc = "This will make you split into four Slimes. NOTE: this will KILL you, but you will be transferred into one of the babies."
if(stat)
src << "<i>I must be conscious to do this...</i>"
return
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
if(amount_grown >= 10)
if(src.nutrition >= 300)
new/obj/item/weapon/reagent_containers/food/snacks/egg/roro(loc)
src.nutrition -= 200
else
src << "<i>I have not fed enough...</i>"
//if(input("Are you absolutely sure you want to reproduce? Your current body will cease to be, but your consciousness will be transferred into a produced slime.") in list("Yes","No")=="Yes")
if(stat)
src << "<i>I must be conscious to do this...</i>"
return
var/list/babies = list()
var/new_nutrition = round(nutrition * 0.9)
var/new_powerlevel = round(powerlevel / 4)
for(var/i=1,i<=4,i++)
if(prob(80))
var/mob/living/carbon/slime/M = new primarytype(loc)
M.nutrition = new_nutrition
M.powerlevel = new_powerlevel
if(i != 1) step_away(M,src)
babies += M
else
var/mutations = pick("one","two","three","four")
switch(mutations)
if("one")
var/mob/living/carbon/slime/M = new mutationone(loc)
M.nutrition = new_nutrition
M.powerlevel = new_powerlevel
if(i != 1) step_away(M,src)
babies += M
if("two")
var/mob/living/carbon/slime/M = new mutationtwo(loc)
M.nutrition = new_nutrition
M.powerlevel = new_powerlevel
if(i != 1) step_away(M,src)
babies += M
if("three")
var/mob/living/carbon/slime/M = new mutationthree(loc)
M.nutrition = new_nutrition
M.powerlevel = new_powerlevel
if(i != 1) step_away(M,src)
babies += M
if("four")
var/mob/living/carbon/slime/M = new mutationfour(loc)
M.nutrition = new_nutrition
M.powerlevel = new_powerlevel
if(i != 1) step_away(M,src)
babies += M
var/mob/living/carbon/slime/new_slime = pick(babies)
new_slime.a_intent = "hurt"
new_slime.key = key
new_slime << "<B>You are now a slime!</B>"
del(src)
else
src << "<i>I am not ready to reproduce yet...</i>"
else
src << "<i>I am not old enough to lay eggs yet...</i>"
src << "<i>I am not old enough to reproduce yet...</i>"
/mob/living/carbon/metroid/verb/ventcrawl()
/mob/living/carbon/slime/verb/ventcrawl()
set name = "Crawl through Vent"
set desc = "Enter an air vent and crawl through the pipe system."
set category = "Roro"
set category = "Slime"
if(Victim) return
handle_ventcrawl()
handle_ventcrawl()
@@ -1,10 +1,10 @@
/mob/living/carbon/metroid/say(var/message)
/mob/living/carbon/slime/say(var/message)
if (silent)
return
else
return ..()
/mob/living/carbon/metroid/say_quote(var/text)
/mob/living/carbon/slime/say_quote(var/text)
var/ending = copytext(text, length(text))
if (ending == "?")
@@ -14,8 +14,8 @@
return "telepathically chirps, \"[text]\"";
/mob/living/carbon/metroid/say_understands(var/other)
if (istype(other, /mob/living/carbon/metroid))
/mob/living/carbon/slime/say_understands(var/other)
if (istype(other, /mob/living/carbon/slime))
return 1
return ..()
@@ -0,0 +1,372 @@
////////////////Tier 2
/mob/living/carbon/slime/purple
colour = "purple"
icon_state = "purple baby slime"
primarytype = /mob/living/carbon/slime/purple
mutationone = /mob/living/carbon/slime/darkpurple
mutationtwo = /mob/living/carbon/slime/darkblue
mutationthree = /mob/living/carbon/slime/green
mutationfour = /mob/living/carbon/slime/green
adulttype = /mob/living/carbon/slime/adult/purple
coretype = /obj/item/slime_extract/purple
/mob/living/carbon/slime/adult/purple
icon_state = "purple adult slime"
colour = "purple"
primarytype = /mob/living/carbon/slime/purple
mutationone = /mob/living/carbon/slime/darkpurple
mutationtwo = /mob/living/carbon/slime/darkblue
mutationthree = /mob/living/carbon/slime/green
mutationfour = /mob/living/carbon/slime/green
adulttype = /mob/living/carbon/slime/adult/purple
coretype = /obj/item/slime_extract/purple
/mob/living/carbon/slime/metal
colour = "metal"
icon_state = "metal baby slime"
primarytype = /mob/living/carbon/slime/metal
mutationone = /mob/living/carbon/slime/silver
mutationtwo = /mob/living/carbon/slime/yellow
mutationthree = /mob/living/carbon/slime/gold
mutationfour = /mob/living/carbon/slime/gold
adulttype = /mob/living/carbon/slime/adult/metal
coretype = /obj/item/slime_extract/metal
/mob/living/carbon/slime/adult/metal
icon_state = "metal adult slime"
colour = "metal"
primarytype = /mob/living/carbon/slime/metal
mutationone = /mob/living/carbon/slime/silver
mutationtwo = /mob/living/carbon/slime/yellow
mutationthree = /mob/living/carbon/slime/gold
mutationfour = /mob/living/carbon/slime/gold
adulttype = /mob/living/carbon/slime/adult/metal
coretype = /obj/item/slime_extract/metal
/mob/living/carbon/slime/orange
colour = "orange"
icon_state = "orange baby slime"
primarytype = /mob/living/carbon/slime/orange
mutationone = /mob/living/carbon/slime/red
mutationtwo = /mob/living/carbon/slime/red
mutationthree = /mob/living/carbon/slime/darkpurple
mutationfour = /mob/living/carbon/slime/yellow
adulttype = /mob/living/carbon/slime/adult/orange
coretype = /obj/item/slime_extract/orange
/mob/living/carbon/slime/adult/orange
colour = "orange"
icon_state = "orange adult slime"
primarytype = /mob/living/carbon/slime/orange
mutationone = /mob/living/carbon/slime/red
mutationtwo = /mob/living/carbon/slime/red
mutationthree = /mob/living/carbon/slime/darkpurple
mutationfour = /mob/living/carbon/slime/yellow
adulttype = /mob/living/carbon/slime/adult/orange
coretype = /obj/item/slime_extract/orange
/mob/living/carbon/slime/blue
colour = "blue"
icon_state = "blue baby slime"
primarytype = /mob/living/carbon/slime/blue
mutationone = /mob/living/carbon/slime/darkblue
mutationtwo = /mob/living/carbon/slime/pink
mutationthree = /mob/living/carbon/slime/pink
mutationfour = /mob/living/carbon/slime/silver
adulttype = /mob/living/carbon/slime/adult/blue
coretype = /obj/item/slime_extract/blue
/mob/living/carbon/slime/adult/blue
icon_state = "blue adult slime"
colour = "blue"
primarytype = /mob/living/carbon/slime/blue
mutationone = /mob/living/carbon/slime/darkblue
mutationtwo = /mob/living/carbon/slime/pink
mutationthree = /mob/living/carbon/slime/silver
mutationfour = /mob/living/carbon/slime/pink
adulttype = /mob/living/carbon/slime/adult/blue
coretype = /obj/item/slime_extract/blue
//Tier 3
/mob/living/carbon/slime/darkblue
colour = "dark blue"
icon_state = "dark blue baby slime"
primarytype = /mob/living/carbon/slime/darkblue
mutationone = /mob/living/carbon/slime/purple
mutationtwo = /mob/living/carbon/slime/purple
mutationthree = /mob/living/carbon/slime/blue
mutationfour = /mob/living/carbon/slime/blue
adulttype = /mob/living/carbon/slime/adult/darkblue
coretype = /obj/item/slime_extract/darkblue
/mob/living/carbon/slime/adult/darkblue
icon_state = "dark blue adult slime"
colour = "dark blue"
primarytype = /mob/living/carbon/slime/darkblue
mutationone = /mob/living/carbon/slime/purple
mutationtwo = /mob/living/carbon/slime/purple
mutationthree = /mob/living/carbon/slime/blue
mutationfour = /mob/living/carbon/slime/blue
adulttype = /mob/living/carbon/slime/adult/darkblue
coretype = /obj/item/slime_extract/darkblue
/mob/living/carbon/slime/darkpurple
colour = "dark purple"
icon_state = "dark purple baby slime"
primarytype = /mob/living/carbon/slime/darkpurple
mutationone = /mob/living/carbon/slime/purple
mutationtwo = /mob/living/carbon/slime/purple
mutationthree = /mob/living/carbon/slime/orange
mutationfour = /mob/living/carbon/slime/orange
adulttype = /mob/living/carbon/slime/adult/darkpurple
coretype = /obj/item/slime_extract/darkpurple
/mob/living/carbon/slime/adult/darkpurple
icon_state = "dark purple adult slime"
colour = "dark purple"
primarytype = /mob/living/carbon/slime/darkpurple
mutationone = /mob/living/carbon/slime/purple
mutationtwo = /mob/living/carbon/slime/purple
mutationthree = /mob/living/carbon/slime/orange
mutationfour = /mob/living/carbon/slime/orange
adulttype = /mob/living/carbon/slime/adult/darkpurple
coretype = /obj/item/slime_extract/darkpurple
/mob/living/carbon/slime/yellow
icon_state = "yellow baby slime"
colour = "yellow"
primarytype = /mob/living/carbon/slime/yellow
mutationone = /mob/living/carbon/slime/metal
mutationtwo = /mob/living/carbon/slime/metal
mutationthree = /mob/living/carbon/slime/orange
mutationfour = /mob/living/carbon/slime/orange
adulttype = /mob/living/carbon/slime/adult/yellow
coretype = /obj/item/slime_extract/yellow
/mob/living/carbon/slime/adult/yellow
icon_state = "yellow adult slime"
colour = "yellow"
primarytype = /mob/living/carbon/slime/yellow
mutationone = /mob/living/carbon/slime/metal
mutationtwo = /mob/living/carbon/slime/metal
mutationthree = /mob/living/carbon/slime/orange
mutationfour = /mob/living/carbon/slime/orange
adulttype = /mob/living/carbon/slime/adult/yellow
coretype = /obj/item/slime_extract/yellow
/mob/living/carbon/slime/silver
colour = "silver"
icon_state = "silver baby slime"
primarytype = /mob/living/carbon/slime/silver
mutationone = /mob/living/carbon/slime/metal
mutationtwo = /mob/living/carbon/slime/metal
mutationthree = /mob/living/carbon/slime/blue
mutationfour = /mob/living/carbon/slime/blue
adulttype = /mob/living/carbon/slime/adult/silver
coretype = /obj/item/slime_extract/silver
/mob/living/carbon/slime/adult/silver
icon_state = "silver adult slime"
colour = "silver"
primarytype = /mob/living/carbon/slime/silver
mutationone = /mob/living/carbon/slime/metal
mutationtwo = /mob/living/carbon/slime/metal
mutationthree = /mob/living/carbon/slime/blue
mutationfour = /mob/living/carbon/slime/blue
adulttype = /mob/living/carbon/slime/adult/silver
coretype = /obj/item/slime_extract/silver
/////////////Tier 4
/mob/living/carbon/slime/pink
colour = "pink"
icon_state = "pink baby slime"
primarytype = /mob/living/carbon/slime/pink
mutationone = /mob/living/carbon/slime/pink
mutationtwo = /mob/living/carbon/slime/pink
mutationthree = /mob/living/carbon/slime/lightpink
mutationfour = /mob/living/carbon/slime/lightpink
adulttype = /mob/living/carbon/slime/adult/pink
coretype = /obj/item/slime_extract/pink
/mob/living/carbon/slime/adult/pink
icon_state = "pink adult slime"
colour = "pink"
primarytype = /mob/living/carbon/slime/pink
mutationone = /mob/living/carbon/slime/pink
mutationtwo = /mob/living/carbon/slime/pink
mutationthree = /mob/living/carbon/slime/lightpink
mutationfour = /mob/living/carbon/slime/lightpink
adulttype = /mob/living/carbon/slime/adult/pink
coretype = /obj/item/slime_extract/pink
/mob/living/carbon/slime/red
colour = "red"
icon_state = "red baby slime"
primarytype = /mob/living/carbon/slime/red
mutationone = /mob/living/carbon/slime/red
mutationtwo = /mob/living/carbon/slime/red
mutationthree = /mob/living/carbon/slime/oil
mutationfour = /mob/living/carbon/slime/oil
adulttype = /mob/living/carbon/slime/adult/red
coretype = /obj/item/slime_extract/red
/mob/living/carbon/slime/adult/red
icon_state = "red adult slime"
colour = "red"
primarytype = /mob/living/carbon/slime/red
mutationone = /mob/living/carbon/slime/red
mutationtwo = /mob/living/carbon/slime/red
mutationthree = /mob/living/carbon/slime/oil
mutationfour = /mob/living/carbon/slime/oil
adulttype = /mob/living/carbon/slime/adult/red
coretype = /obj/item/slime_extract/red
/mob/living/carbon/slime/gold
colour = "gold"
icon_state = "gold baby slime"
primarytype = /mob/living/carbon/slime/gold
mutationone = /mob/living/carbon/slime/gold
mutationtwo = /mob/living/carbon/slime/gold
mutationthree = /mob/living/carbon/slime/adamantine
mutationfour = /mob/living/carbon/slime/adamantine
adulttype = /mob/living/carbon/slime/adult/gold
coretype = /obj/item/slime_extract/gold
/mob/living/carbon/slime/adult/gold
icon_state = "gold adult slime"
colour = "gold"
primarytype = /mob/living/carbon/slime/gold
mutationone = /mob/living/carbon/slime/gold
mutationtwo = /mob/living/carbon/slime/gold
mutationthree = /mob/living/carbon/slime/adamantine
mutationfour = /mob/living/carbon/slime/adamantine
adulttype = /mob/living/carbon/slime/adult/gold
coretype = /obj/item/slime_extract/gold
/mob/living/carbon/slime/green
colour = "green"
icon_state = "green baby slime"
primarytype = /mob/living/carbon/slime/green
mutationone = /mob/living/carbon/slime/green
mutationtwo = /mob/living/carbon/slime/green
mutationthree = /mob/living/carbon/slime/black
mutationfour = /mob/living/carbon/slime/black
adulttype = /mob/living/carbon/slime/adult/green
coretype = /obj/item/slime_extract/green
/mob/living/carbon/slime/adult/green
icon_state = "green adult slime"
colour = "green"
primarytype = /mob/living/carbon/slime/green
mutationone = /mob/living/carbon/slime/green
mutationtwo = /mob/living/carbon/slime/green
mutationthree = /mob/living/carbon/slime/black
mutationfour = /mob/living/carbon/slime/black
adulttype = /mob/living/carbon/slime/adult/green
coretype = /obj/item/slime_extract/green
// Tier 5
/mob/living/carbon/slime/lightpink
colour = "light pink"
icon_state = "light pink baby slime"
primarytype = /mob/living/carbon/slime/lightpink
mutationone = /mob/living/carbon/slime/lightpink
mutationtwo = /mob/living/carbon/slime/lightpink
mutationthree = /mob/living/carbon/slime/lightpink
mutationfour = /mob/living/carbon/slime/lightpink
adulttype = /mob/living/carbon/slime/adult/lightpink
coretype = /obj/item/slime_extract/lightpink
/mob/living/carbon/slime/adult/lightpink
icon_state = "light pink adult slime"
colour = "light pink"
primarytype = /mob/living/carbon/slime/lightpink
mutationone = /mob/living/carbon/slime/lightpink
mutationtwo = /mob/living/carbon/slime/lightpink
mutationthree = /mob/living/carbon/slime/lightpink
mutationfour = /mob/living/carbon/slime/lightpink
adulttype = /mob/living/carbon/slime/adult/lightpink
coretype = /obj/item/slime_extract/lightpink
/mob/living/carbon/slime/oil
icon_state = "oil baby slime"
colour = "oil"
primarytype = /mob/living/carbon/slime/oil
mutationone = /mob/living/carbon/slime/oil
mutationtwo = /mob/living/carbon/slime/oil
mutationthree = /mob/living/carbon/slime/oil
mutationfour = /mob/living/carbon/slime/oil
adulttype = /mob/living/carbon/slime/adult/oil
coretype = /obj/item/slime_extract/oil
/mob/living/carbon/slime/adult/oil
icon_state = "oil adult slime"
colour = "oil"
primarytype = /mob/living/carbon/slime/oil
mutationone = /mob/living/carbon/slime/oil
mutationtwo = /mob/living/carbon/slime/oil
mutationthree = /mob/living/carbon/slime/oil
mutationfour = /mob/living/carbon/slime/oil
adulttype = /mob/living/carbon/slime/adult/oil
coretype = /obj/item/slime_extract/oil
/mob/living/carbon/slime/black
icon_state = "black baby slime"
colour = "black"
primarytype = /mob/living/carbon/slime/black
mutationone = /mob/living/carbon/slime/black
mutationtwo = /mob/living/carbon/slime/black
mutationthree = /mob/living/carbon/slime/black
mutationfour = /mob/living/carbon/slime/black
adulttype = /mob/living/carbon/slime/adult/black
coretype = /obj/item/slime_extract/black
/mob/living/carbon/slime/adult/black
icon_state = "black adult slime"
colour = "black"
primarytype = /mob/living/carbon/slime/black
mutationone = /mob/living/carbon/slime/black
mutationtwo = /mob/living/carbon/slime/black
mutationthree = /mob/living/carbon/slime/black
mutationfour = /mob/living/carbon/slime/black
adulttype = /mob/living/carbon/slime/adult/black
coretype = /obj/item/slime_extract/black
/mob/living/carbon/slime/adamantine
icon_state = "adamantine baby slime"
colour = "adamantine"
primarytype = /mob/living/carbon/slime/adamantine
mutationone = /mob/living/carbon/slime/adamantine
mutationtwo = /mob/living/carbon/slime/adamantine
mutationthree = /mob/living/carbon/slime/adamantine
mutationfour = /mob/living/carbon/slime/adamantine
adulttype = /mob/living/carbon/slime/adult/adamantine
coretype = /obj/item/slime_extract/adamantine
/mob/living/carbon/slime/adult/adamantine
icon_state = "adamantine adult slime"
colour = "adamantine"
primarytype = /mob/living/carbon/slime/adamantine
mutationone = /mob/living/carbon/slime/adamantine
mutationtwo = /mob/living/carbon/slime/adamantine
mutationthree = /mob/living/carbon/slime/adamantine
mutationfour = /mob/living/carbon/slime/adamantine
adulttype = /mob/living/carbon/slime/adult/adamantine
coretype = /obj/item/slime_extract/adamantine
+1 -1
View File
@@ -217,7 +217,7 @@
mymob.zone_sel = new /obj/screen/zone_sel()
mymob.zone_sel.icon = ui_style
mymob.zone_sel.overlays = null
mymob.zone_sel.overlays.Cut()
mymob.zone_sel.overlays += image('icons/mob/zone_sel.dmi', "[mymob.zone_sel.selecting]")
mymob.client.screen = null
@@ -337,7 +337,7 @@
updatehealth()
/mob/living/carbon/monkey/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/carbon/monkey/attack_slime(mob/living/carbon/slime/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -352,7 +352,7 @@
var/damage = rand(1, 3)
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
damage = rand(20, 40)
else
damage = rand(5, 35)
@@ -410,57 +410,6 @@
return
/mob/living/carbon/monkey/Move()
if ((!( buckled ) || buckled.loc != loc))
buckled = null
if (buckled)
return
if (restrained())
stop_pulling()
var/t7 = 1
if (restrained())
for(var/mob/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if (t7 && (pulling && get_dist(src, pulling) <= 1))
if (pulling.anchored)
stop_pulling()
var/T = loc
. = ..()
if (!( isturf(pulling.loc) ))
stop_pulling()
return
if (!buckled)
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((ismob(pulling) && (get_dist(src, pulling) > 1 || diag)))
if (istype(pulling, type))
var/mob/M = pulling
var/atom/movable/t = M.pulling
M.stop_pulling()
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
if (istype(pulling, /obj/structure/window))
if(pulling:ini_dir == NORTHWEST || pulling:ini_dir == NORTHEAST || pulling:ini_dir == SOUTHWEST || pulling:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(pulling,get_dir(pulling.loc, T)))
stop_pulling()
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( contents.Find(s_active) )))
s_active.close(src)
for(var/mob/living/carbon/metroid/M in view(1,src))
M.UpdateFeed(src)
return
/mob/living/carbon/monkey/verb/removeinternal()
set name = "Remove Internals"
set category = "IC"
@@ -26,7 +26,7 @@
/mob/living/carbon/monkey/update_icons()
update_hud()
lying_prev = lying //so we don't update overlays for lying/standing unless our stance changes again
overlays = null
overlays.Cut()
if(lying)
icon_state = "monkey0"
for(var/image/I in overlays_lying)
+84 -1
View File
@@ -294,4 +294,87 @@
else
usr << "OOC Metadata is not supported by this server!"
return
return
/mob/living/Move(a, b, flag)
if (buckled)
return
if (restrained())
stop_pulling()
var/t7 = 1
if (restrained())
for(var/mob/living/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at [__LINE__] in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (isliving(pulling))
var/mob/living/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [] has been pulled from []'s grip by []", G.affecting, G.assailant, src), 1)
//G = null
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
//this is the gay blood on floor shit -- Added back -- Skie
if (M.lying && (prob(M.getBruteLoss() / 6)))
var/turf/location = M.loc
if (istype(location, /turf/simulated))
location.add_blood(M)
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
if (istype(pulling, /obj/structure/window))
if(pulling:ini_dir == NORTHWEST || pulling:ini_dir == NORTHEAST || pulling:ini_dir == SOUTHWEST || pulling:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(pulling,get_dir(pulling.loc, T)))
stop_pulling()
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
if(update_slimes)
for(var/mob/living/carbon/slime/M in view(1,src))
M.UpdateFeed(src)
+1 -1
View File
@@ -76,7 +76,7 @@
if(!O.fingerprintslast)
return
var/client/assailant = directory[ckey(O.fingerprintslast)]
if(assailant.mob && istype(assailant.mob,/mob))
if(assailant && assailant.mob && istype(assailant.mob,/mob))
var/mob/M = assailant.mob
src.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been hit with [O], last touched by [M.name] ([assailant.ckey])</font>")
M.attack_log += text("\[[time_stamp()]\] <font color='red'>Hit [src.name] ([src.ckey]) with [O]</font>")
+3 -2
View File
@@ -10,7 +10,7 @@
var/oxyloss = 0.0 //Oxygen depravation damage (no air in lungs)
var/toxloss = 0.0 //Toxic damage caused by being poisoned or radiated
var/fireloss = 0.0 //Burn damage caused by being way too hot, too cold or burnt.
var/cloneloss = 0 //Damage caused by being cloned or ejected from the cloner early. Metroids also deal cloneloss damage to victims
var/cloneloss = 0 //Damage caused by being cloned or ejected from the cloner early. slimes also deal cloneloss damage to victims
var/brainloss = 0 //'Retardation' damage caused by someone hitting you in the head with a bible or being infected with brainrot.
var/halloss = 0 //Hallucination damage. 'Fake' damage obtained through hallucinating or the holodeck. Sleeping should cause it to wear off.
@@ -35,4 +35,5 @@
var/cameraFollow = null
var/tod = null // Time of death
var/tod = null // Time of death
var/update_slimes = 1
+47 -50
View File
@@ -1,57 +1,54 @@
#define SAY_MINIMUM_PRESSURE 10
var/list/department_radio_keys = list(
":r" = "right hand",
":l" = "left hand",
":i" = "intercom",
":h" = "department",
":c" = "Command",
":n" = "Science",
":m" = "Medical",
":e" = "Engineering",
":s" = "Security",
":w" = "whisper",
":b" = "binary",
":a" = "alientalk",
":t" = "Syndicate",
":d" = "Mining",
":q" = "Cargo",
":g" = "changeling",
":r" = "right hand", "#r" = "right hand", ".r" = "right hand",
":l" = "left hand", "#l" = "left hand", ".l" = "left hand",
":i" = "intercom", "#i" = "intercom", ".i" = "intercom",
":h" = "department", "#h" = "department", ".h" = "department",
":c" = "Command", "#c" = "Command", ".c" = "Command",
":n" = "Science", "#n" = "Science", ".n" = "Science",
":m" = "Medical", "#m" = "Medical", ".m" = "Medical",
":e" = "Engineering", "#e" = "Engineering", ".e" = "Engineering",
":s" = "Security", "#s" = "Security", ".s" = "Security",
":w" = "whisper", "#w" = "whisper", ".w" = "whisper",
":b" = "binary", "#b" = "binary", ".b" = "binary",
":a" = "alientalk", "#a" = "alientalk", ".a" = "alientalk",
":t" = "Syndicate", "#t" = "Syndicate", ".t" = "Syndicate",
":u" = "Supply", "#u" = "Supply", ".u" = "Supply",
":g" = "changeling", "#g" = "changeling", ".g" = "changeling",
":R" = "right hand",
":L" = "left hand",
":I" = "intercom",
":H" = "department",
":C" = "Command",
":N" = "Science",
":M" = "Medical",
":E" = "Engineering",
":S" = "Security",
":W" = "whisper",
":B" = "binary",
":A" = "alientalk",
":T" = "Syndicate",
":D" = "Mining",
":Q" = "Cargo",
":G" = "changeling",
":R" = "right hand", "#R" = "right hand", ".R" = "right hand",
":L" = "left hand", "#L" = "left hand", ".L" = "left hand",
":I" = "intercom", "#I" = "intercom", ".I" = "intercom",
":H" = "department", "#H" = "department", ".H" = "department",
":C" = "Command", "#C" = "Command", ".C" = "Command",
":N" = "Science", "#N" = "Science", ".N" = "Science",
":M" = "Medical", "#M" = "Medical", ".M" = "Medical",
":E" = "Engineering", "#E" = "Engineering", ".E" = "Engineering",
":S" = "Security", "#S" = "Security", ".S" = "Security",
":W" = "whisper", "#W" = "whisper", ".W" = "whisper",
":B" = "binary", "#B" = "binary", ".B" = "binary",
":A" = "alientalk", "#A" = "alientalk", ".A" = "alientalk",
":T" = "Syndicate", "#T" = "Syndicate", ".T" = "Syndicate",
":U" = "Supply", "#U" = "Supply", ".U" = "Supply",
":G" = "changeling", "#G" = "changeling", ".G" = "changeling",
//kinda localization -- rastaf0
//same keys as above, but on russian keyboard layout. This file uses cp1251 as encoding.
":ê" = "right hand",
":ä" = "left hand",
":ø" = "intercom",
":ð" = "department",
":ñ" = "Command",
":ò" = "Science",
":ü" = "Medical",
":ó" = "Engineering",
":û" = "Security",
":ö" = "whisper",
":è" = "binary",
":ô" = "alientalk",
":å" = "Syndicate",
":â" = "Mining",
":é" = "Cargo",
":ï" = "changeling"
":ê" = "right hand", "#ê" = "right hand", ".ê" = "right hand",
":ä" = "left hand", "#ä" = "left hand", ".ä" = "left hand",
":ø" = "intercom", "#ø" = "intercom", ".ø" = "intercom",
":ð" = "department", "#ð" = "department", ".ð" = "department",
":ñ" = "Command", "#ñ" = "Command", ".ñ" = "Command",
":ò" = "Science", "#ò" = "Science", ".ò" = "Science",
":ü" = "Medical", "#ü" = "Medical", ".ü" = "Medical",
":ó" = "Engineering", "#ó" = "Engineering", ".ó" = "Engineering",
":û" = "Security", "#û" = "Security", ".û" = "Security",
":ö" = "whisper", "#ö" = "whisper", ".ö" = "whisper",
":è" = "binary", "#è" = "binary", ".è" = "binary",
":ô" = "alientalk", "#ô" = "alientalk", ".ô" = "alientalk",
":å" = "Syndicate", "#å" = "Syndicate", ".å" = "Syndicate",
":é" = "Supply", "#é" = "Supply", ".é" = "Supply",
":ï" = "changeling", "#ï" = "changeling", ".ï" = "changeling"
)
/mob/living/proc/binarycheck()
@@ -134,9 +131,9 @@ var/list/department_radio_keys = list(
//world << "channel_prefix=[channel_prefix]; message_mode=[message_mode]"
if (message_mode)
message = trim(copytext(message, 3))
if (!(ishuman(src) || isanimal(src) || isrobot(src) && (message_mode=="department" || (message_mode in radiochannels))))
if (!(ishuman(src) || istype(src, /mob/living/simple_animal/parrot) || isrobot(src) && (message_mode=="department" || (message_mode in radiochannels))))
message_mode = null //only humans can use headsets
// Check removed so parrots can use headsets!
// Check changed so that parrots can use headsets. Other simple animals do not have ears and will cause runtimes.
// And borgs -Sieve
if (!message)
@@ -103,10 +103,12 @@ var/datum/cameranet/cameranet = new()
var/turf/T = get_turf(c)
if(T)
var/x1 = max(0, T.x - 16) & ~0xf
var/y1 = max(0, T.y - 16) & ~0xf
var/x2 = min(world.maxx, T.x + 16) & ~0xf
var/y2 = min(world.maxy, T.y + 16) & ~0xf
var/x1 = max(0, T.x - 8) & ~0xf
var/y1 = max(0, T.y - 8) & ~0xf
var/x2 = min(world.maxx, T.x + 8) & ~0xf
var/y2 = min(world.maxy, T.y + 8) & ~0xf
//world << "X1: [x1] - Y1: [y1] - X2: [x2] - Y2: [y2]"
for(var/x = x1; x <= x2; x += 16)
for(var/y = y1; y <= y2; y += 16)
@@ -132,4 +134,15 @@ var/datum/cameranet/cameranet = new()
chunk.hasChanged(1) // Update now, no matter if it's visible or not.
if(chunk.visibleTurfs[position])
return 1
return 0
return 0
// Debug verb for VVing the chunk that the turf is in.
/*
/turf/verb/view_chunk()
set src in world
if(cameranet.chunkGenerated(x, y, z))
var/datum/camerachunk/chunk = cameranet.getCameraChunk(x, y, z)
usr.client.debug_variables(chunk)
*/
@@ -11,6 +11,7 @@
density = 0
status_flags = GODMODE // You can't damage it.
mouse_opacity = 0
see_in_dark = 7
// Movement code. Returns 0 to stop air movement from moving it.
/mob/aiEye/Move()
@@ -140,8 +141,10 @@
if(src.eyeobj && src.loc)
src.eyeobj.loc = src.loc
else
src << "ERROR: Eyeobj not found. Please report this to Giacom. Creating new eye..."
src << "ERROR: Eyeobj not found. Creating new eye..."
src.eyeobj = new(src.loc)
src.eyeobj.ai = src
src.eyeobj.name = "[src.name] (AI Eye)" // Give it a name
if(client && client.eye)
client.eye = src
+123 -133
View File
@@ -17,8 +17,6 @@
src << "\red ERROR: APC access disabled, hack attempt canceled."
src.malfhacking = 0
src.malfhack = null
else
if (src.health <= config.health_threshold_dead)
@@ -29,146 +27,138 @@
if (!( src.machine.check_eye(src) ))
src.reset_view(null)
//var/stage = 0
if (src.client)
//stage = 1
if (istype(src, /mob/living/silicon/ai))
var/blind = 0
//stage = 2
var/area/loc = null
if (istype(T, /turf))
//stage = 3
loc = T.loc
if (istype(loc, /area))
//stage = 4
if (!loc.master.power_equip && !istype(src.loc,/obj/item))
//stage = 5
blind = 1
// Handle power damage (oxy)
if(src:aiRestorePowerRoutine != 0)
// Lost power
adjustOxyLoss(1)
else
// Gain Power
adjustOxyLoss(-1)
if (!blind) //lol? if(!blind) #if(src.blind.layer) <--something here is clearly wrong :P
//I'll get back to this when I find out how this is -supposed- to work ~Carn //removed this shit since it was confusing as all hell --39kk9t
//stage = 4.5
src.sight |= SEE_TURFS
src.sight |= SEE_MOBS
src.sight |= SEE_OBJS
src.see_in_dark = 8
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
//stage = 1
//if (istype(src, /mob/living/silicon/ai)) // Are we not sure what we are?
var/blind = 0
//stage = 2
var/area/loc = null
if (istype(T, /turf))
//stage = 3
loc = T.loc
if (istype(loc, /area))
//stage = 4
if (!loc.master.power_equip && !istype(src.loc,/obj/item))
//stage = 5
blind = 1
var/area/home = get_area(src)
if(!home) return//something to do with malf fucking things up I guess. <-- aisat is gone. is this still necessary? ~Carn
if(home.powered(EQUIP))
home.use_power(1000, EQUIP)
if (!blind) //lol? if(!blind) #if(src.blind.layer) <--something here is clearly wrong :P
//I'll get back to this when I find out how this is -supposed- to work ~Carn //removed this shit since it was confusing as all hell --39kk9t
//stage = 4.5
src.sight |= SEE_TURFS
src.sight |= SEE_MOBS
src.sight |= SEE_OBJS
src.see_in_dark = 8
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
if (src:aiRestorePowerRoutine==2)
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
spawn(1)
while (src.getOxyLoss()>0 && stat!=2)
sleep(50)
src.adjustOxyLoss(-1)
src.oxyloss = 0
return
else if (src:aiRestorePowerRoutine==3)
src << "Alert cancelled. Power has been restored."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
spawn(1)
while (src.getOxyLoss()>0 && stat!=2)
sleep(50)
src.adjustOxyLoss(-1)
return
else
var/area/home = get_area(src)
if(!home) return//something to do with malf fucking things up I guess. <-- aisat is gone. is this still necessary? ~Carn
if(home.powered(EQUIP))
home.use_power(1000, EQUIP)
//stage = 6
src.blind.screen_loc = "1,1 to 15,15"
if (src.blind.layer!=18)
src.blind.layer = 18
src.sight = src.sight&~SEE_TURFS
src.sight = src.sight&~SEE_MOBS
src.sight = src.sight&~SEE_OBJS
src.see_in_dark = 0
src.see_invisible = SEE_INVISIBLE_LIVING
if (src:aiRestorePowerRoutine==2)
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
return
else if (src:aiRestorePowerRoutine==3)
src << "Alert cancelled. Power has been restored."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
return
else
if (((!loc.master.power_equip) || istype(T, /turf/space)) && !istype(src.loc,/obj/item) && !istype(get_area(src), /area/shuttle))
if (src:aiRestorePowerRoutine==0)
src:aiRestorePowerRoutine = 1
//stage = 6
src.blind.screen_loc = "1,1 to 15,15"
if (src.blind.layer!=18)
src.blind.layer = 18
src.sight = src.sight&~SEE_TURFS
src.sight = src.sight&~SEE_MOBS
src.sight = src.sight&~SEE_OBJS
src.see_in_dark = 0
src.see_invisible = SEE_INVISIBLE_LIVING
src << "You've lost power!"
if (((!loc.master.power_equip) || istype(T, /turf/space)) && !istype(src.loc,/obj/item))
if (src:aiRestorePowerRoutine==0)
src:aiRestorePowerRoutine = 1
src << "You've lost power!"
// world << "DEBUG CODE TIME! [loc] is the area the AI is sucking power from"
if (!is_special_character(src))
src.set_zeroth_law("")
//src.clear_supplied_laws() // Don't reset our laws.
//var/time = time2text(world.realtime,"hh:mm:ss")
//lawchanges.Add("[time] <b>:</b> [src.name]'s noncore laws have been reset due to power failure")
spawn(50)
while ((src:aiRestorePowerRoutine!=0) && stat!=2)
src.oxyloss += 2
sleep(50)
spawn(20)
src << "Backup battery online. Scanners, camera, and radio interface offline. Beginning fault-detection."
sleep(50)
if (loc.master.power_equip)
if (!istype(T, /turf/space))
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
return
src << "Fault confirmed: missing external power. Shutting down main control system to save power."
sleep(20)
src << "Emergency control system online. Verifying connection to power network."
sleep(50)
if (istype(T, /turf/space))
src << "Unable to verify! No power connection detected!"
src:aiRestorePowerRoutine = 2
return
src << "Connection verified. Searching for APC in power network."
sleep(50)
var/obj/machinery/power/apc/theAPC = null
if (!is_special_character(src))
src.set_zeroth_law("")
//src.clear_supplied_laws() // Don't reset our laws.
//var/time = time2text(world.realtime,"hh:mm:ss")
//lawchanges.Add("[time] <b>:</b> [src.name]'s noncore laws have been reset due to power failure")
spawn(20)
src << "Backup battery online. Scanners, camera, and radio interface offline. Beginning fault-detection."
sleep(50)
if (loc.master.power_equip)
if (!istype(T, /turf/space))
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0
return
src << "Fault confirmed: missing external power. Shutting down main control system to save power."
sleep(20)
src << "Emergency control system online. Verifying connection to power network."
sleep(50)
if (istype(T, /turf/space))
src << "Unable to verify! No power connection detected!"
src:aiRestorePowerRoutine = 2
return
src << "Connection verified. Searching for APC in power network."
sleep(50)
var/obj/machinery/power/apc/theAPC = null
/*
for (var/something in loc)
if (istype(something, /obj/machinery/power/apc))
if (!(something:stat & BROKEN))
theAPC = something
break
for (var/something in loc)
if (istype(something, /obj/machinery/power/apc))
if (!(something:stat & BROKEN))
theAPC = something
break
*/
var/PRP //like ERP with the code, at least this stuff is no more 4x sametext
for (PRP=1, PRP<=4, PRP++)
var/area/AIarea = get_area(src)
for(var/area/A in AIarea.master.related)
for (var/obj/machinery/power/apc/APC in A)
if (!(APC.stat & BROKEN))
theAPC = APC
break
if (!theAPC)
switch(PRP)
if (1) src << "Unable to locate APC!"
else src << "Lost connection with the APC!"
src:aiRestorePowerRoutine = 2
return
if (loc.master.power_equip)
if (!istype(T, /turf/space))
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0 //This, too, is a fix to issue 603
return
switch(PRP)
if (1) src << "APC located. Optimizing route to APC to avoid needless power waste."
if (2) src << "Best route identified. Hacking offline APC power port."
if (3) src << "Power port upload access confirmed. Loading control program into APC power port software."
if (4)
src << "Transfer complete. Forcing APC to execute program."
sleep(50)
src << "Receiving control information from APC."
sleep(2)
//bring up APC dialog
theAPC.attack_ai(src)
src:aiRestorePowerRoutine = 3
src << "Here are your current laws:"
src.show_laws()
var/PRP //like ERP with the code, at least this stuff is no more 4x sametext
for (PRP=1, PRP<=4, PRP++)
var/area/AIarea = get_area(src)
for(var/area/A in AIarea.master.related)
for (var/obj/machinery/power/apc/APC in A)
if (!(APC.stat & BROKEN))
theAPC = APC
break
if (!theAPC)
switch(PRP)
if (1) src << "Unable to locate APC!"
else src << "Lost connection with the APC!"
src:aiRestorePowerRoutine = 2
return
if (loc.master.power_equip)
if (!istype(T, /turf/space))
src << "Alert cancelled. Power has been restored without our assistance."
src:aiRestorePowerRoutine = 0
src.blind.layer = 0 //This, too, is a fix to issue 603
return
switch(PRP)
if (1) src << "APC located. Optimizing route to APC to avoid needless power waste."
if (2) src << "Best route identified. Hacking offline APC power port."
if (3) src << "Power port upload access confirmed. Loading control program into APC power port software."
if (4)
src << "Transfer complete. Forcing APC to execute program."
sleep(50)
theAPC = null
src << "Receiving control information from APC."
sleep(2)
//bring up APC dialog
theAPC.attack_ai(src)
src:aiRestorePowerRoutine = 3
src << "Here are your current laws:"
src.show_laws()
sleep(50)
theAPC = null
/mob/living/silicon/ai/updatehealth()
if(status_flags & GODMODE)
@@ -178,4 +168,4 @@
if(fire_res_on_core)
health = 100 - getOxyLoss() - getToxLoss() - getBruteLoss()
else
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
health = 100 - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss()
+1 -1
View File
@@ -35,7 +35,7 @@
var/screen // Which screen our main window displays
var/subscreen // Which specific function of the main screen is being displayed
var/obj/item/device/pda/pai/pda = null
var/obj/item/device/pda/ai/pai/pda = null
var/secHUD = 0 // Toggles whether the Security HUD is active or not
var/medHUD = 0 // Toggles whether the Medical HUD is active or not
@@ -214,4 +214,8 @@ var/datum/paiController/paiController // Global handler for pAI candidates
if(response == "Yes")
recruitWindow(C.mob)
else if (response == "Never for this round")
C.prefs.be_special &= ~BE_PAI
var/warning = alert(C, "Are you sure? This action will be undoable and you will need to wait until next round.", "You sure?", "Yes", "No")
if(warning == "Yes")
asked[C.key] = INFINITY
else
question(C)
+1 -1
View File
@@ -140,7 +140,7 @@
mymob.zone_sel = new /obj/screen/zone_sel()
mymob.zone_sel.icon = 'icons/mob/screen1_robot.dmi'
mymob.zone_sel.overlays = null
mymob.zone_sel.overlays.Cut()
mymob.zone_sel.overlays += image('icons/mob/zone_sel.dmi', "[mymob.zone_sel.selecting]")
mymob.client.screen = null
+18 -81
View File
@@ -641,7 +641,7 @@
/mob/living/silicon/robot/attack_metroid(mob/living/carbon/metroid/M as mob)
/mob/living/silicon/robot/attack_slime(mob/living/carbon/slime/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
@@ -656,7 +656,7 @@
var/damage = rand(1, 3)
if(istype(src, /mob/living/carbon/metroid/adult))
if(istype(src, /mob/living/carbon/slime/adult))
damage = rand(20, 40)
else
damage = rand(5, 35)
@@ -764,24 +764,27 @@
/mob/living/silicon/robot/proc/updateicon()
overlays = null
overlays.Cut()
if(stat == 0)
overlays += "eyes"
if(icon_state == "robot")
overlays = null
overlays.Cut()
overlays += "eyes-standard"
if(icon_state == "toiletbot")
overlays = null
overlays.Cut()
overlays += "eyes-toiletbot"
if(icon_state == "bloodhound")
overlays = null
overlays.Cut()
overlays += "eyes-bloodhound"
if(icon_state =="landmate")
overlays = null
overlays.Cut()
overlays += "eyes-landmate"
if(icon_state =="mopgearrex")
overlays = null
overlays.Cut()
overlays += "eyes-mopgearrex"
if(icon_state =="Miner")
overlays.Cut()
overlays += "eyes-Miner"
else
overlays -= "eyes"
@@ -906,73 +909,7 @@
/mob/living/silicon/robot/Move(a, b, flag)
if (buckled)
return
if (restrained())
stop_pulling()
var/t7 = 1
if (restrained())
for(var/mob/M in range(src, 1))
if ((M.pulling == src && M.stat == 0 && !( M.restrained() )))
t7 = null
if ((t7 && (pulling && ((get_dist(src, pulling) <= 1 || pulling.loc == loc) && (client && client.moving)))))
var/turf/T = loc
. = ..()
if (pulling && pulling.loc)
if(!( isturf(pulling.loc) ))
stop_pulling()
return
else
if(Debug)
diary <<"pulling disappeared? at [__LINE__] in mob.dm - pulling = [pulling]"
diary <<"REPORT THIS"
/////
if(pulling && pulling.anchored)
stop_pulling()
return
if (!restrained())
var/diag = get_dir(src, pulling)
if ((diag - 1) & diag)
else
diag = null
if ((get_dist(src, pulling) > 1 || diag))
if (ismob(pulling))
var/mob/M = pulling
var/ok = 1
if (locate(/obj/item/weapon/grab, M.grabbed_by))
if (prob(75))
var/obj/item/weapon/grab/G = pick(M.grabbed_by)
if (istype(G, /obj/item/weapon/grab))
for(var/mob/O in viewers(M, null))
O.show_message(text("\red [G.affecting] has been pulled from [G.assailant]'s grip by [src]"), 1)
del(G)
else
ok = 0
if (locate(/obj/item/weapon/grab, M.grabbed_by.len))
ok = 0
if (ok)
var/atom/movable/t = M.pulling
M.stop_pulling()
step(pulling, get_dir(pulling.loc, T))
M.start_pulling(t)
else
if (pulling)
if (istype(pulling, /obj/structure/window))
if(pulling:ini_dir == NORTHWEST || pulling:ini_dir == NORTHEAST || pulling:ini_dir == SOUTHWEST || pulling:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(pulling,get_dir(pulling.loc, T)))
stop_pulling()
if (pulling)
step(pulling, get_dir(pulling.loc, T))
else
stop_pulling()
. = ..()
if ((s_active && !( s_active in contents ) ))
s_active.close(src)
. = ..()
if(module)
if(module.type == /obj/item/weapon/robot_module/janitor)
@@ -1031,7 +968,7 @@
set name = "Reset Identity Codes"
set desc = "Scrambles your security and identification codes and resets your current buffers. Unlocks you and but permenantly severs you from your AI and the robotics console and will deactivate your camera system."
var/mob/living/silicon/robot/R = usr
var/mob/living/silicon/robot/R = src
if(R)
R.UnlinkSelf()
@@ -1043,9 +980,9 @@
set category = "IC"
set src = usr
if(module_active)
var/obj/item/W = get_active_hand()
if (W)
W.attack_self(src)
var/obj/item/W = module_active
if (W)
W.attack_self(src)
return
return
@@ -151,7 +151,7 @@
New()
..()
src.modules += new /obj/item/weapon/soap/nanotrasen(src)
src.modules += new /obj/item/weapon/trashbag(src)
src.modules += new /obj/item/weapon/storage/bag/trash(src)
src.modules += new /obj/item/weapon/mop(src)
src.modules += new /obj/item/device/lightreplacer(src)
src.emag = new /obj/item/weapon/reagent_containers/spray(src)
@@ -179,7 +179,7 @@
src.modules += new /obj/item/weapon/reagent_containers/robodropper(src)
var/obj/item/weapon/lighter/zippo/L = new /obj/item/weapon/lighter/zippo(src)
L.light_on = 1
L.lit = 1
src.modules += L
src.modules += new /obj/item/weapon/tray/robotray(src)
@@ -203,9 +203,9 @@
..()
src.modules += new /obj/item/borg/sight/meson(src)
src.emag = new /obj/item/borg/stun(src)
src.modules += new /obj/item/weapon/storage/satchel(src)
src.modules += new /obj/item/weapon/storage/bag/ore(src)
src.modules += new /obj/item/weapon/pickaxe/borgdrill(src)
src.modules += new /obj/item/weapon/sheetsnatcher/borg(src)
src.modules += new /obj/item/weapon/storage/bag/sheetsnatcher/borg(src)
// src.modules += new /obj/item/weapon/shovel(src) Uneeded due to buffed drill
return
@@ -61,10 +61,19 @@
if(src.corpseid == 1)
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card"
var/datum/job/jobdatum
for(var/jobtype in typesof(/datum/job))
var/datum/job/J = new jobtype
if(J.title == corpseidaccess)
jobdatum = J
break
if(src.corpseidicon)
W.icon_state = corpseidicon
if(src.corpseidaccess)
W.access = get_access(corpseidaccess)
if(jobdatum)
W.access = jobdatum.get_access()
else
W.access = list()
if(corpseidjob)
W.assignment = corpseidjob
W.registered_name = M.real_name
@@ -20,6 +20,7 @@
see_in_dark = 5
var/obj/item/inventory_head
var/obj/item/inventory_back
var/facehugger
/mob/living/simple_animal/corgi/Life()
..()
@@ -110,6 +111,8 @@
usr << "\red It's is already wearing something."
return
else
place_on_head(usr.get_active_hand())
var/obj/item/item_to_add = usr.get_active_hand()
if(!item_to_add)
return
@@ -156,71 +159,8 @@
return
usr.drop_item()
item_to_add.loc = src
src.inventory_head = item_to_add
regenerate_icons()
//Various hats and items (worn on his head) change Ian's behaviour. His attributes are reset when a HAT is removed.
switch(inventory_head && inventory_head.type)
if(/obj/item/clothing/head/caphat, /obj/item/clothing/head/collectable/captain)
name = "Captain [real_name]"
desc = "Probably better than the last captain."
if(/obj/item/clothing/head/kitty, /obj/item/clothing/head/collectable/kitty)
name = "Runtime"
emote_see = list("coughs up a furball", "stretches")
emote_hear = list("purrs")
speak = list("Purrr", "Meow!", "MAOOOOOW!", "HISSSSS", "MEEEEEEW")
desc = "It's a cute little kitty-cat! ... wait ... what the hell?"
if(/obj/item/clothing/head/rabbitears, /obj/item/clothing/head/collectable/rabbitears)
name = "Hoppy"
emote_see = list("twitches its nose", "hops around a bit")
desc = "This is hoppy. It's a corgi-...urmm... bunny rabbit"
if(/obj/item/clothing/head/beret, /obj/item/clothing/head/collectable/beret)
name = "Yann"
desc = "Mon dieu! C'est un chien!"
speak = list("le woof!", "le bark!", "JAPPE!!")
emote_see = list("cowers in fear", "surrenders", "plays dead","looks as though there is a wall in front of /him")
if(/obj/item/clothing/head/det_hat)
name = "Detective [real_name]"
desc = "[name] sees through your lies..."
emote_see = list("investigates the area","sniffs around for clues","searches for scooby snacks")
if(/obj/item/clothing/head/nursehat)
name = "Nurse [real_name]"
desc = "[name] needs 100cc of beef jerky...STAT!"
if(/obj/item/clothing/head/pirate, /obj/item/clothing/head/collectable/pirate)
name = "[pick("Ol'","Scurvy","Black","Rum","Gammy","Bloody","Gangrene","Death","Long-John")] [pick("kibble","leg","beard","tooth","poop-deck","Threepwood","Le Chuck","corsair","Silver","Crusoe")]"
desc = "Yaarghh!! Thar' be a scurvy dog!"
emote_see = list("hunts for treasure","stares coldly...","gnashes his tiny corgi teeth")
emote_hear = list("growls ferociously", "snarls")
speak = list("Arrrrgh!!","Grrrrrr!")
if(/obj/item/clothing/head/ushanka)
name = "[pick("Comrade","Commissar","Glorious Leader")] [real_name]"
desc = "A follower of Karl Barx."
emote_see = list("contemplates the failings of the capitalist economic model", "ponders the pros and cons of vangaurdism")
if(/obj/item/clothing/head/collectable/police)
name = "Officer [real_name]"
emote_see = list("drools","looks for donuts")
desc = "Stop right there criminal scum!"
if(/obj/item/clothing/head/wizard/fake, /obj/item/clothing/head/wizard, /obj/item/clothing/head/collectable/wizard)
name = "Grandwizard [real_name]"
speak = list("YAP", "Woof!", "Bark!", "AUUUUUU", "EI NATH!")
if(/obj/item/weapon/bedsheet)
name = "\improper Ghost"
speak = list("WoooOOOooo~","AUUUUUUUUUUUUUUUUUU")
emote_see = list("stumbles around", "shivers")
emote_hear = list("howls","groans")
desc = "Spooky!"
if(/obj/item/clothing/head/helmet/space/santahat)
name = "Rudolph the Red-Nosed Corgi"
emote_hear = list("barks christmas songs", "yaps")
desc = "He has a very shiny nose."
SetLuminosity(6)
if(/obj/item/clothing/head/soft)
name = "Corgi Tech [real_name]"
// speak = list("Needs a stamp!", "Request DENIED!", "Fill these out in triplicate!")
desc = "The reason your yellow gloves have chew-marks."
place_on_head(item_to_add)
if("back")
if(inventory_back)
@@ -252,6 +192,71 @@
else
..()
/mob/living/simple_animal/corgi/proc/place_on_head(obj/item/item_to_add)
item_to_add.loc = src
src.inventory_head = item_to_add
regenerate_icons()
//Various hats and items (worn on his head) change Ian's behaviour. His attributes are reset when a HAT is removed.
switch(inventory_head && inventory_head.type)
if(/obj/item/clothing/head/caphat, /obj/item/clothing/head/collectable/captain)
name = "Captain [real_name]"
desc = "Probably better than the last captain."
if(/obj/item/clothing/head/kitty, /obj/item/clothing/head/collectable/kitty)
name = "Runtime"
emote_see = list("coughs up a furball", "stretches")
emote_hear = list("purrs")
speak = list("Purrr", "Meow!", "MAOOOOOW!", "HISSSSS", "MEEEEEEW")
desc = "It's a cute little kitty-cat! ... wait ... what the hell?"
if(/obj/item/clothing/head/rabbitears, /obj/item/clothing/head/collectable/rabbitears)
name = "Hoppy"
emote_see = list("twitches its nose", "hops around a bit")
desc = "This is hoppy. It's a corgi-...urmm... bunny rabbit"
if(/obj/item/clothing/head/beret, /obj/item/clothing/head/collectable/beret)
name = "Yann"
desc = "Mon dieu! C'est un chien!"
speak = list("le woof!", "le bark!", "JAPPE!!")
emote_see = list("cowers in fear", "surrenders", "plays dead","looks as though there is a wall in front of him")
if(/obj/item/clothing/head/det_hat)
name = "Detective [real_name]"
desc = "[name] sees through your lies..."
emote_see = list("investigates the area","sniffs around for clues","searches for scooby snacks")
if(/obj/item/clothing/head/nursehat)
name = "Nurse [real_name]"
desc = "[name] needs 100cc of beef jerky...STAT!"
if(/obj/item/clothing/head/pirate, /obj/item/clothing/head/collectable/pirate)
name = "[pick("Ol'","Scurvy","Black","Rum","Gammy","Bloody","Gangrene","Death","Long-John")] [pick("kibble","leg","beard","tooth","poop-deck","Threepwood","Le Chuck","corsair","Silver","Crusoe")]"
desc = "Yaarghh!! Thar' be a scurvy dog!"
emote_see = list("hunts for treasure","stares coldly...","gnashes his tiny corgi teeth")
emote_hear = list("growls ferociously", "snarls")
speak = list("Arrrrgh!!","Grrrrrr!")
if(/obj/item/clothing/head/ushanka)
name = "[pick("Comrade","Commissar","Glorious Leader")] [real_name]"
desc = "A follower of Karl Barx."
emote_see = list("contemplates the failings of the capitalist economic model", "ponders the pros and cons of vangaurdism")
if(/obj/item/clothing/head/collectable/police)
name = "Officer [real_name]"
emote_see = list("drools","looks for donuts")
desc = "Stop right there criminal scum!"
if(/obj/item/clothing/head/wizard/fake, /obj/item/clothing/head/wizard, /obj/item/clothing/head/collectable/wizard)
name = "Grandwizard [real_name]"
speak = list("YAP", "Woof!", "Bark!", "AUUUUUU", "EI NATH!")
if(/obj/item/weapon/bedsheet)
name = "\improper Ghost"
speak = list("WoooOOOooo~","AUUUUUUUUUUUUUUUUUU")
emote_see = list("stumbles around", "shivers")
emote_hear = list("howls","groans")
desc = "Spooky!"
if(/obj/item/clothing/head/helmet/space/santahat)
name = "Rudolph the Red-Nosed Corgi"
emote_hear = list("barks christmas songs", "yaps")
desc = "He has a very shiny nose."
SetLuminosity(6)
if(/obj/item/clothing/head/soft)
name = "Corgi Tech [real_name]"
desc = "The reason your yellow gloves have chew-marks."
//IAN! SQUEEEEEEEEE~
/mob/living/simple_animal/corgi/Ian
name = "Ian"
@@ -302,11 +307,11 @@
else
dir = SOUTH
if(isturf(movement_target.loc) )
movement_target.attack_animal(src)
else if(ishuman(movement_target.loc) )
if(prob(20))
emote("stares at the [movement_target] that [movement_target.loc] has with a sad puppy-face")
if(isturf(movement_target.loc) )
movement_target.attack_animal(src)
else if(ishuman(movement_target.loc) )
if(prob(20))
emote("stares at the [movement_target] that [movement_target.loc] has with a sad puppy-face")
if(prob(1))
emote(pick("dances around","chases its tail"))
@@ -377,7 +382,7 @@
if(health <= 0)
head_icon_state += "2"
var/icon/head_icon = icon('icons/mob/corgi_head.dmi',head_icon_state)
var/icon/head_icon = image('icons/mob/corgi_head.dmi',head_icon_state)
if(head_icon)
overlays += head_icon
@@ -386,9 +391,16 @@
if(health <= 0)
back_icon_state += "2"
var/icon/back_icon = icon('icons/mob/corgi_back.dmi',back_icon_state)
var/icon/back_icon = image('icons/mob/corgi_back.dmi',back_icon_state)
if(back_icon)
overlays += back_icon
if(facehugger)
if(istype(src, /mob/living/simple_animal/corgi/puppy))
overlays += image('icons/mob/mask.dmi',"facehugger_corgipuppy")
else
overlays += image('icons/mob/mask.dmi',"facehugger_corgi")
return
@@ -0,0 +1,17 @@
/mob/living/simple_animal/lizard
name = "Lizard"
desc = "A cute tiny lizard."
icon = 'icons/mob/critter.dmi'
icon_state = "lizard"
icon_living = "lizard"
icon_dead = "lizard-dead"
speak_emote = list("hisses")
health = 5
maxHealth = 5
attacktext = "bites"
attacktext = "bites"
melee_damage_lower = 1
melee_damage_upper = 2
response_help = "pets"
response_disarm = "shoos"
response_harm = "stomps on"
@@ -0,0 +1,82 @@
/mob/living/simple_animal/slime
name = "pet slime"
desc = "A lovable, domesticated slime."
icon = 'icons/mob/slimes.dmi'
icon_state = "grey baby slime"
icon_living = "grey baby slime"
icon_dead = "grey baby slime dead"
speak_emote = list("chirps")
health = 100
maxHealth = 100
response_help = "pets"
response_disarm = "shoos"
response_harm = "stomps on"
emote_see = list("jiggles", "bounces in place")
var/colour = "grey"
/mob/living/simple_animal/slime/Bump(atom/movable/AM as mob|obj, yes)
spawn( 0 )
if ((!( yes ) || now_pushing))
return
now_pushing = 1
if(ismob(AM))
var/mob/tmob = AM
if(istype(tmob, /mob/living/carbon/human) && (FAT in tmob.mutations))
if(prob(70))
src << "\red <B>You fail to push [tmob]'s fat ass out of the way.</B>"
now_pushing = 0
return
if(!(tmob.status_flags & CANPUSH))
now_pushing = 0
return
tmob.LAssailant = src
now_pushing = 0
..()
if (!( istype(AM, /atom/movable) ))
return
if (!( now_pushing ))
now_pushing = 1
if (!( AM.anchored ))
var/t = get_dir(src, AM)
if (istype(AM, /obj/structure/window))
if(AM:ini_dir == NORTHWEST || AM:ini_dir == NORTHEAST || AM:ini_dir == SOUTHWEST || AM:ini_dir == SOUTHEAST)
for(var/obj/structure/window/win in get_step(AM,t))
now_pushing = 0
return
step(AM, t)
now_pushing = null
return
return
/mob/living/simple_animal/adultslime
name = "pet slime"
desc = "A lovable, domesticated slime."
icon = 'icons/mob/slimes.dmi'
health = 200
maxHealth = 200
icon_state = "grey adult slime"
icon_living = "grey adult slime"
icon_dead = "grey baby slime dead"
response_help = "pets"
response_disarm = "shoos"
response_harm = "stomps on"
emote_see = list("jiggles", "bounces in place")
var/colour = "grey"
/mob/living/simple_animal/slime/adult/Die()
..()
var/mob/living/simple_animal/slime/S1 = new /mob/living/simple_animal/slime (src.loc)
S1.icon_state = "[src.colour] baby slime"
S1.icon_state = "[src.colour] adult slime"
S1.icon_living = "[src.colour] adult slime"
S1.icon_dead = "[src.colour] adult slime dead"
S1.colour = "[src.colour]"
var/mob/living/simple_animal/slime/S2 = new /mob/living/simple_animal/slime (src.loc)
S2.icon_state = "[src.colour] baby slime"
S2.icon_state = "[src.colour] adult slime"
S2.icon_living = "[src.colour] adult slime"
S2.icon_dead = "[src.colour] adult slime dead"
S2.colour = "[src.colour]"
del(src)
@@ -12,6 +12,4 @@
response_help = "prods the"
response_disarm = "pushes aside the"
response_harm = "smacks the"
harm_intent_damage = 5
/mob/living/simple_animal/tomato
harm_intent_damage = 5
@@ -0,0 +1,93 @@
/mob/living/simple_animal/hostile/alien
name = "alien hunter"
desc = "Hiss!"
icon = 'icons/mob/alien.dmi'
icon_state = "alienh_running"
icon_living = "alienh_running"
icon_dead = "alien_l"
icon_gib = "syndicate_gib"
response_help = "pokes the"
response_disarm = "shoves the"
response_harm = "hits the"
speed = -1
meat_type = /obj/item/weapon/reagent_containers/food/snacks/xenomeat
maxHealth = 100
health = 100
harm_intent_damage = 5
melee_damage_lower = 25
melee_damage_upper = 25
attacktext = "slashes"
a_intent = "harm"
attack_sound = 'sound/weapons/bladeslice.ogg'
min_oxy = 0
max_oxy = 0
min_tox = 0
max_tox = 0
min_co2 = 0
max_co2 = 0
min_n2 = 0
max_n2 = 0
unsuitable_atoms_damage = 15
faction = "alien"
wall_smash = 1
status_flags = CANPUSH
minbodytemp = 0
heat_damage_per_tick = 20
/mob/living/simple_animal/hostile/alien/drone
name = "alien drone"
icon_state = "aliend_running"
icon_living = "aliend_running"
icon_dead = "aliend_l"
health = 60
melee_damage_lower = 15
melee_damage_upper = 15
/mob/living/simple_animal/hostile/alien/sentinel
name = "alien sentinel"
icon_state = "aliens_running"
icon_living = "aliens_running"
icon_dead = "aliens_l"
health = 120
melee_damage_lower = 15
melee_damage_upper = 15
ranged = 1
projectiletype = /obj/item/projectile/neurotox
projectilesound = 'sound/weapons/pierce.ogg'
/mob/living/simple_animal/hostile/alien/queen
name = "alien queen"
icon_state = "alienq_running"
icon_living = "alienq_running"
icon_dead = "alienq_l"
health = 250
maxHealth = 250
melee_damage_lower = 15
melee_damage_upper = 15
ranged = 1
move_to_delay = 3
projectiletype = /obj/item/projectile/neurotox
projectilesound = 'sound/weapons/pierce.ogg'
rapid = 1
status_flags = 0
/mob/living/simple_animal/hostile/alien/queen/large
name = "alien empress"
icon = 'icons/mob/alienqueen.dmi'
icon_state = "queen_s"
icon_living = "queen_s"
icon_dead = "queen_dead"
move_to_delay = 4
maxHealth = 400
health = 400
/obj/item/projectile/neurotox
damage = 30
icon_state = "toxin"
/mob/living/simple_animal/hostile/alien/Die()
..()
visible_message("[src] lets out a waning guttural screech, green blood bubbling from its maw...")
playsound(src, 'sound/voice/hiss6.ogg', 100, 1)
@@ -13,7 +13,7 @@
speak_chance = 1
turns_per_move = 5
see_in_dark = 6
meat_type = /obj/item/weapon/reagent_containers/food/snacks/meat
meat_type = /obj/item/weapon/reagent_containers/food/snacks/bearmeat
response_help = "pets the"
response_disarm = "gently pushes aside the"
response_harm = "pokes the"
@@ -0,0 +1,15 @@
/mob/living/simple_animal/hostile/creature
name = "creature"
desc = "A sanity-destroying otherthing."
icon = 'icons/mob/critter.dmi'
speak_emote = list("gibbers")
icon_state = "otherthing"
icon_living = "otherthing"
icon_dead = "otherthing-dead"
health = 80
maxHealth = 80
melee_damage_lower = 25
melee_damage_upper = 50
attacktext = "chomps"
attack_sound = 'sound/weapons/bite.ogg'
faction = "creature"
@@ -8,6 +8,8 @@
var/projectiletype
var/projectilesound
var/casingtype
var/move_to_delay = 2 //delay for the automated movement.
var/list/friends = list()
stop_automated_movement_when_pulled = 0
/mob/living/simple_animal/hostile/proc/FindTarget()
@@ -20,6 +22,8 @@
var/mob/living/L = A
if(L.faction == src.faction && !attack_same)
continue
else if(L in friends)
continue
else
if(!L.stat)
stance = HOSTILE_STANCE_ATTACK
@@ -33,7 +37,7 @@
break
return T
/mob/living/simple_animal/hostile/proc/MoveToTarget(var/step = 5)
/mob/living/simple_animal/hostile/proc/MoveToTarget()
stop_automated_movement = 1
if(!target_mob || SA_attackable(target_mob))
stance = HOSTILE_STANCE_IDLE
@@ -41,21 +45,24 @@
if(ranged)
if(get_dist(src, target_mob) <= 6)
OpenFire(target_mob)
else
walk_to(src, target_mob, 1, move_to_delay)
else
stance = HOSTILE_STANCE_ATTACKING
walk_to(src, target_mob, 1, 2)
walk_to(src, target_mob, 1, move_to_delay)
/mob/living/simple_animal/hostile/proc/AttackTarget()
stop_automated_movement = 1
if(!target_mob || SA_attackable(target_mob))
LoseTarget()
return
return 0
if(!(target_mob in ListTargets()))
LostTarget()
return
return 0
if(get_dist(src, target_mob) <= 1) //Attacking
AttackingTarget()
return 1
/mob/living/simple_animal/hostile/proc/AttackingTarget()
if(isliving(target_mob))
@@ -106,8 +113,6 @@
DestroySurroundings()
AttackTarget()
/mob/living/simple_animal/hostile/proc/OpenFire(target_mob)
var/target = target_mob
visible_message("\red <b>[src]</b> fires at [target]!", 1)
@@ -0,0 +1,197 @@
//
// Abstract Class
//
/mob/living/simple_animal/hostile/mimic
name = "crate"
desc = "A rectangular steel crate."
icon = 'icons/obj/storage.dmi'
icon_state = "crate"
icon_living = "crate"
meat_type = /obj/item/weapon/reagent_containers/food/snacks/carpmeat
response_help = "touches the"
response_disarm = "pushes the"
response_harm = "hits the"
speed = -1
maxHealth = 250
health = 250
harm_intent_damage = 5
melee_damage_lower = 8
melee_damage_upper = 12
attacktext = "attacks"
attack_sound = 'sound/weapons/bite.ogg'
min_oxy = 0
max_oxy = 0
min_tox = 0
max_tox = 0
min_co2 = 0
max_co2 = 0
min_n2 = 0
max_n2 = 0
minbodytemp = 0
faction = "mimic"
move_to_delay = 8
/mob/living/simple_animal/hostile/mimic/FindTarget()
. = ..()
if(.)
emote("growls at [.]")
/mob/living/simple_animal/hostile/mimic/Die()
..()
visible_message("\red <b>[src]</b> stops moving!")
del(src)
//
// Crate Mimic
//
// Aggro when you try to open them. Will also pickup loot when spawns and drop it when dies.
/mob/living/simple_animal/hostile/mimic/crate
attacktext = "bites"
stop_automated_movement = 1
wander = 0
var/attempt_open = 0
// Pickup loot
/mob/living/simple_animal/hostile/mimic/crate/initialize()
..()
for(var/obj/item/I in loc)
I.loc = src
/mob/living/simple_animal/hostile/mimic/crate/DestroySurroundings()
..()
if(prob(90))
icon_state = "[initial(icon_state)]open"
else
icon_state = initial(icon_state)
/mob/living/simple_animal/hostile/mimic/crate/ListTargets()
if(attempt_open)
return view(src, 10)
return view(src, 1)
/mob/living/simple_animal/hostile/mimic/crate/FindTarget()
. = ..()
if(.)
trigger()
/mob/living/simple_animal/hostile/mimic/crate/AttackingTarget()
. = ..()
if(.)
icon_state = initial(icon_state)
/mob/living/simple_animal/hostile/mimic/crate/proc/trigger()
if(!attempt_open)
visible_message("<b>[src]</b> starts to move!")
attempt_open = 1
/mob/living/simple_animal/hostile/mimic/crate/adjustBruteLoss(var/damage)
trigger()
..(damage)
/mob/living/simple_animal/hostile/mimic/crate/LoseTarget()
..()
icon_state = initial(icon_state)
/mob/living/simple_animal/hostile/mimic/crate/LostTarget()
..()
icon_state = initial(icon_state)
/mob/living/simple_animal/hostile/mimic/crate/Die()
var/obj/structure/closet/crate/C = new(get_turf(src))
// Put loot in crate
for(var/obj/O in src)
O.loc = C
..()
/mob/living/simple_animal/hostile/mimic/crate/AttackingTarget()
. =..()
var/mob/living/L = .
if(istype(L))
if(prob(15))
L.Weaken(2)
L.visible_message("<span class='danger'>\the [src] knocks down \the [L]!</span>")
//
// Copy Mimic
//
var/global/list/protected_objects = list(/obj/structure/table, /obj/structure/cable, /obj/structure/window)
/mob/living/simple_animal/hostile/mimic/copy
health = 100
maxHealth = 100
var/obj/item/staff = null // the staff that changed they, never attack the bearer of this staff
var/destroy_objects = 0
var/knockdown_people = 0
/mob/living/simple_animal/hostile/mimic/copy/New(loc, var/obj/copy, var/obj/item/staff)
..(loc)
CopyObject(copy, staff)
/mob/living/simple_animal/hostile/mimic/copy/Die()
for(var/atom/movable/M in src)
M.loc = get_turf(src)
..()
/mob/living/simple_animal/hostile/mimic/copy/ListTargets()
// Return a list of targets that isn't the holder of our staff
return view(src, 7) - get(staff, /mob)
/mob/living/simple_animal/hostile/mimic/copy/proc/CopyObject(var/obj/O, var/obj/item/staff)
if((istype(O, /obj/item) || istype(O, /obj/structure)) && !is_type_in_list(O, protected_objects))
O.loc = src
name = O.name
desc = O.desc
icon = O.icon
icon_state = O.icon_state
icon_living = icon_state
if(istype(O, /obj/structure))
health = (anchored * 50) + 50
destroy_objects = 1
if(O.density && O.anchored)
knockdown_people = 1
melee_damage_lower *= 2
melee_damage_upper *= 2
else if(istype(O, /obj/item))
var/obj/item/I = O
health = 15 * I.w_class
melee_damage_lower = 2 + I.force
melee_damage_upper = 2 + I.force
move_to_delay = 2 * I.w_class
maxHealth = health
if(staff)
src.staff = staff
faction = "\ref[staff]" // very unique
return 1
return
/mob/living/simple_animal/hostile/mimic/copy/DestroySurroundings()
if(destroy_objects)
..()
/mob/living/simple_animal/hostile/mimic/copy/AttackingTarget()
. =..()
if(knockdown_people)
var/mob/living/L = .
if(istype(L))
if(prob(15))
L.Weaken(1)
L.visible_message("<span class='danger'>\the [src] knocks down \the [L]!</span>")
@@ -136,8 +136,9 @@
/mob/living/simple_animal/hostile/viscerator
name = "viscerator"
desc = "A small, twin-bladed machine capable of inflicting very deadly lacerations."
icon_state = "viscerator"
icon_living = "viscerator"
icon = 'icons/mob/critter.dmi'
icon_state = "viscerator_attack"
icon_living = "viscerator_attack"
pass_flags = PASSTABLE
health = 15
maxHealth = 15
@@ -0,0 +1,57 @@
/mob/living/simple_animal/hostile/tree
name = "pine tree"
desc = "A pissed off tree-like alien. It seems annoyed with the festivities..."
icon = 'icons/obj/flora/pinetrees.dmi'
icon_state = "pine_1"
icon_living = "pine_1"
icon_dead = "pine_1"
icon_gib = "pine_1"
speak_chance = 0
turns_per_move = 5
meat_type = /obj/item/weapon/reagent_containers/food/snacks/carpmeat
response_help = "brushes the"
response_disarm = "pushes the"
response_harm = "hits the"
speed = -1
maxHealth = 250
health = 250
pixel_x = -16
harm_intent_damage = 5
melee_damage_lower = 8
melee_damage_upper = 12
attacktext = "bites"
attack_sound = 'sound/weapons/bite.ogg'
//Space carp aren't affected by atmos.
min_oxy = 0
max_oxy = 0
min_tox = 0
max_tox = 0
min_co2 = 0
max_co2 = 0
min_n2 = 0
max_n2 = 0
minbodytemp = 0
faction = "carp"
/mob/living/simple_animal/hostile/tree/FindTarget()
. = ..()
if(.)
emote("growls at [.]")
/mob/living/simple_animal/hostile/tree/AttackingTarget()
. =..()
var/mob/living/L = .
if(istype(L))
if(prob(15))
L.Weaken(3)
L.visible_message("<span class='danger'>\the [src] knocks down \the [L]!</span>")
/mob/living/simple_animal/hostile/tree/Die()
..()
visible_message("\red <b>[src]</b> is hacked into pieces!")
new /obj/item/stack/sheet/wood(loc)
del(src)
+21 -13
View File
@@ -53,7 +53,7 @@
var/parrot_sleep_dur = 25 //Same as above, this is the var that physically counts down
var/parrot_dam_zone = list("chest", "head", "l_arm", "l_leg", "r_arm", "r_leg") //For humans, select a bodypart to attack
var/parrot_speed = 5 //"Delay in world ticks between movement." Yeah, that's BS but it does directly affect movement. Higher number = slower.
var/parrot_speed = 5 //"Delay in world ticks between movement." according to byond. Yeah, that's BS but it does directly affect movement. Higher number = slower.
var/parrot_been_shot = 0 //Parrots get a speed bonus after being shot. This will deincrement every Life() and at 0 the parrot will return to regular speed.
var/list/speech_buffer = list()
@@ -69,14 +69,13 @@
//Parrots will generally sit on their pertch unless something catches their eye.
//These vars store their preffered perch and if they dont have one, what they can use as a perch
var/obj/parrot_perch = null
var/obj/desired_perches = list(/obj/structure/computerframe, /obj/structure/displaycase, \
/obj/structure/closet, /obj/structure/filingcabinet, \
/obj/machinery/computer, /obj/machinery/clonepod, \
/obj/machinery/dna_scanner, /obj/machinery/dna_scannernew, \
/obj/machinery/nuclearbomb, /obj/machinery/particle_accelerator, \
var/obj/desired_perches = list(/obj/structure/computerframe, /obj/structure/displaycase, \
/obj/structure/filingcabinet, /obj/machinery/teleport, \
/obj/machinery/computer, /obj/machinery/clonepod, \
/obj/machinery/dna_scannernew, /obj/machinery/telecomms, \
/obj/machinery/nuclearbomb, /obj/machinery/particle_accelerator, \
/obj/machinery/recharge_station, /obj/machinery/smartfridge, \
/obj/machinery/suit_storage_unit, /obj/machinery/telecomms, \
/obj/machinery/teleport)
/obj/machinery/suit_storage_unit)
//Parrots are kleptomaniacs. This variable ... stores the item a parrot is holding.
var/obj/item/held_item = null
@@ -89,7 +88,7 @@
/obj/item/device/radio/headset/headset_eng, \
/obj/item/device/radio/headset/headset_med, \
/obj/item/device/radio/headset/headset_sci, \
/obj/item/device/radio/headset/heads/qm)
/obj/item/device/radio/headset/headset_cargo)
ears = new headset(src)
parrot_sleep_dur = parrot_sleep_max //In case someone decides to change the max without changing the duration var
@@ -107,6 +106,10 @@
walk(src,0)
..()
/mob/living/simple_animal/parrot/Stat()
..()
stat("Held Item", held_item)
/*
* Inventory
*/
@@ -310,7 +313,7 @@
//-----SLEEPING
if(parrot_state == PARROT_PERCH)
if(parrot_perch.loc != src.loc) //Make sure someone hasnt moved our perch on us
if(parrot_perch && parrot_perch.loc != src.loc) //Make sure someone hasnt moved our perch on us
if(parrot_perch in view(src))
parrot_state = PARROT_SWOOP | PARROT_RETURN
icon_state = "parrot_fly"
@@ -412,10 +415,15 @@
return
if(in_range(src, parrot_interest))
if(isliving(parrot_interest))
steal_from_mob()
else
steal_from_ground()
else //This should ensure that we only grab the item we want, and make sure it's not already collected on our perch
if(!parrot_perch || parrot_interest.loc != parrot_perch.loc)
held_item = parrot_interest
parrot_interest.loc = src
visible_message("[src] grabs the [held_item]!", "\blue You grab the [held_item]!", "You hear the sounds of wings flapping furiously.")
parrot_interest = null
parrot_state = PARROT_SWOOP | PARROT_RETURN
@@ -583,7 +591,7 @@
if(I.loc != src && I.w_class <= 2)
//If we have a perch and the item is sitting on it, continue
if(!client && parrot_perch && I.loc == parrot_perch)
if(!client && parrot_perch && I.loc == parrot_perch.loc)
continue
held_item = I
@@ -20,6 +20,7 @@
var/meat_amount = 0
var/meat_type
var/stop_automated_movement = 0 //Use this to temporarely stop random movement or to if you write special movement code for animals.
var/wander = 1 // Does the mob wander around when idle?
var/stop_automated_movement_when_pulled = 1 //When set to 1 this stops the animal from moving when someone is pulling it.
//Interaction
@@ -95,7 +96,7 @@
AdjustParalysis(-1)
//Movement
if(!client && !stop_automated_movement)
if(!client && !stop_automated_movement && wander)
if(isturf(src.loc) && !resting && !buckled && canmove) //This is so it only moves if it's not inside a closet, gentics machine, etc.
turns_since_move++
if(turns_since_move >= turns_per_move)
@@ -186,12 +187,12 @@
//Atmos effect
if(bodytemperature < minbodytemp)
health -= cold_damage_per_tick
adjustBruteLoss(cold_damage_per_tick)
else if(bodytemperature > maxbodytemp)
health -= heat_damage_per_tick
adjustBruteLoss(heat_damage_per_tick)
if(!atmos_suitable)
health -= unsuitable_atoms_damage
adjustBruteLoss(unsuitable_atoms_damage)
return 1
/mob/living/simple_animal/Bumped(AM as mob|obj)
@@ -241,11 +242,11 @@
M.attack_log += text("\[[time_stamp()]\] <font color='red'>attacked [src.name] ([src.ckey])</font>")
src.attack_log += text("\[[time_stamp()]\] <font color='orange'>was attacked by [M.name] ([M.ckey])</font>")
var/damage = rand(M.melee_damage_lower, M.melee_damage_upper)
health -= damage
adjustBruteLoss(damage)
/mob/living/simple_animal/bullet_act(var/obj/item/projectile/Proj)
if(!Proj) return
src.health -= Proj.damage
adjustBruteLoss(Proj.damage)
return 0
/mob/living/simple_animal/attack_hand(mob/living/carbon/human/M as mob)
@@ -264,6 +265,7 @@
return
if (!(status_flags & CANPUSH))
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M, M, src )
M.put_in_active_hand(G)
@@ -277,17 +279,12 @@
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if("hurt")
health -= harm_intent_damage
if("hurt", "disarm")
adjustBruteLoss(harm_intent_damage)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message("\red [M] [response_harm] [src]")
if("disarm")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message("\blue [M] [response_disarm] [src]")
return
/mob/living/simple_animal/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
@@ -295,6 +292,7 @@
switch(M.a_intent)
if ("help")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src] with its scythe like arm."), 1)
@@ -303,6 +301,7 @@
return
if(!(status_flags & CANPUSH))
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M, M, src )
M.put_in_active_hand(G)
@@ -316,16 +315,10 @@
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if("hurt")
if("hurt", "disarm")
var/damage = rand(15, 30)
visible_message("\red <B>[M] has slashed at [src]!</B>")
src.health -= damage
if("disarm")
var/damage = rand(15, 30)
visible_message("\red <B>[M] has slashed at [src]!</B>")
src.health -= damage
adjustBruteLoss(damage)
return
@@ -335,23 +328,25 @@
if("help")
visible_message("\blue [L] rubs it's head against [src]")
else
var/damage = rand(5, 10)
visible_message("\red <B>[L] bites [src]!</B>")
if(stat != DEAD)
src.health -= damage
adjustBruteLoss(damage)
L.amount_grown = min(L.amount_grown + damage, L.max_grown)
/mob/living/simple_animal/attackby(var/obj/item/O as obj, var/mob/user as mob) //Marker -Agouri
if(istype(O, /obj/item/stack/medical))
if(stat != DEAD)
var/obj/item/stack/medical/MED = O
if(health < maxHealth)
if(MED.amount >= 1)
health = min(maxHealth, health + MED.heal_brute)
adjustBruteLoss(-MED.heal_brute)
MED.amount -= 1
if(MED.amount <= 0)
del(MED)
@@ -372,7 +367,7 @@
var/damage = O.force
if (O.damtype == HALLOSS)
damage = 0
health -= damage
adjustBruteLoss(damage)
for(var/mob/M in viewers(src, null))
if ((M.client && !( M.blinded )))
M.show_message("\red \b [src] has been attacked with the [O] by [user]. ")
@@ -383,6 +378,7 @@
M.show_message("\red [user] gently taps [src] with the [O]. ")
/mob/living/simple_animal/movement_delay()
var/tally = 0 //Incase I need to add stuff other than "speed" later
@@ -409,19 +405,19 @@
flick("flash", flash)
switch (severity)
if (1.0)
health -= 500
adjustBruteLoss(500)
gib()
return
if (2.0)
health -= 60
adjustBruteLoss(60)
if(3.0)
health -= 30
adjustBruteLoss(30)
/mob/living/simple_animal/adjustBruteLoss(damage)
health -= damage
health = Clamp(health - damage, 0, maxHealth)
/mob/living/simple_animal/proc/SA_attackable(target_mob)
if (isliving(target_mob))
+11 -5
View File
@@ -80,7 +80,7 @@
M.show_message( message, 1, blind_message, 2)
//This is aweful
//This is awful
/mob/attackby(obj/item/weapon/W as obj, mob/user as mob)
//Holding a balloon will shield you from an item that is_sharp() ... cause that makes sense
@@ -108,7 +108,7 @@
//If the mob is not wearing a shield or otherwise is not shielded
if ((!( shielded ) || !( W.flags ) & NOSHIELD))
spawn( 0 )
if (W)
if (W && istype(W, /obj/item)) //The istype is necessary for things like bodybags which are structures that do not have an attack() proc.
W.attack(src, user)
return
return
@@ -573,7 +573,11 @@ var/list/slot_equipment_priority = list( \
show_inv(usr)
/mob/proc/stop_pulling()
/mob/verb/stop_pulling()
set name = "Stop Pulling"
set category = "IC"
if(pulling)
pulling.pulledby = null
pulling = null
@@ -581,11 +585,13 @@ var/list/slot_equipment_priority = list( \
/mob/proc/start_pulling(var/atom/movable/AM)
if ( !AM || !usr || src==AM || !isturf(src.loc) ) //if there's no person pulling OR the person is pulling themself OR the object being pulled is inside something: abort!
return
if (!( AM.anchored ))
if(pulling)
var/pulling_old = pulling
stop_pulling()
// Are we pulling the same thing twice? Just stop pulling.
if(pulling_old == AM)
return
src.pulling = AM
AM.pulledby = src
if(ismob(AM))
+13 -23
View File
@@ -22,10 +22,7 @@ Put (mob/proc)s here that are in dire need of a code cleanup.
if(A.GetDiseaseID() in resistances)
//world << "It resisted us!"
return
var/count = 0
for(var/datum/disease/advance/AD in viruses)
count++
if(count >= 3)
if(count_by_type(viruses, /datum/disease/advance) >= 3)
return
else
@@ -33,6 +30,7 @@ Put (mob/proc)s here that are in dire need of a code cleanup.
//world << "Normal virus and resisted"
return
if(has_disease(virus))
return
@@ -117,41 +115,33 @@ Put (mob/proc)s here that are in dire need of a code cleanup.
if(1)
if(isobj(H.head) && !istype(H.head, /obj/item/weapon/paper))
Cl = H.head
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Head pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(H.wear_mask))
Cl = H.wear_mask
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Mask pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(2)//arms and legs included
if(isobj(H.wear_suit))
Cl = H.wear_suit
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Suit pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(slot_w_uniform))
Cl = slot_w_uniform
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Uniform pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(3)
if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered&HANDS)
Cl = H.wear_suit
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Suit pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(H.gloves))
Cl = H.gloves
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Gloves pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(4)
if(isobj(H.wear_suit) && H.wear_suit.body_parts_covered&FEET)
Cl = H.wear_suit
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Suit pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
if(passed && isobj(H.shoes))
Cl = H.shoes
passed = prob(Cl.permeability_coefficient*100*virus.permeability_mod)
// world << "Shoes pass [passed]"
passed = prob((Cl.permeability_coefficient*100) - 1)
else
src << "Something strange's going on, something's wrong."
@@ -168,11 +158,11 @@ Put (mob/proc)s here that are in dire need of a code cleanup.
if(1)
if(M.wear_mask && isobj(M.wear_mask))
Cl = M.wear_mask
passed = prob(Cl.permeability_coefficient*100+virus.permeability_mod)
passed = prob((Cl.permeability_coefficient*100) - 1)
//world << "Mask pass [passed]"
if(passed && spread_type == AIRBORNE && internals)
passed = (prob(50*virus.permeability_mod))
if(!passed && spread_type == AIRBORNE && !internals)
passed = (prob((50*virus.permeability_mod) - 1))
if(passed)
//world << "Infection in the mob [src]. YAY"
+1 -1
View File
@@ -168,7 +168,7 @@
statpanel("[P.panel]","",P)
*/
//The last mob/living/carbon to push/drag/grab this mob (mostly used by Metroids friend recognition)
//The last mob/living/carbon to push/drag/grab this mob (mostly used by slimes friend recognition)
var/mob/living/carbon/LAssailant = null
//Wizard mode, but can be used in other modes thanks to the brand new "Give Spell" badmin button
+1 -1
View File
@@ -200,7 +200,7 @@
return
*/
if(istype(affecting, /mob/living/carbon/metroid))
if(istype(affecting, /mob/living/carbon/slime))
assailant << "\blue You squeeze [affecting], but nothing interesting happens."
return
+4 -4
View File
@@ -30,13 +30,13 @@
return 1
return 0
/proc/ismetroid(A)
if(istype(A, /mob/living/carbon/metroid))
/proc/isslime(A)
if(istype(A, /mob/living/carbon/slime))
return 1
return 0
/proc/ismetroidadult(A)
if(istype(A, /mob/living/carbon/metroid/adult))
/proc/isslimeadult(A)
if(istype(A, /mob/living/carbon/slime/adult))
return 1
return 0
+4
View File
@@ -250,6 +250,10 @@
return
if(Process_Grab()) return
if(mob.buckled) //if we're buckled to something, tell it we moved.
return mob.buckled.relaymove(mob, direct)
if(!mob.canmove) return
@@ -40,7 +40,8 @@
M.name = src.name
M.real_name = src.real_name
M.dna = src.dna
if(src.dna)
M.dna = src.dna
if(mind)
mind.transfer_to(M)
+19 -9
View File
@@ -231,7 +231,7 @@
usr << "The option ID difference is too big. Please contact administration or the database admin."
return
for(var/optionid = id_min; optionid<= id_max; optionid++)
for(var/optionid = id_min; optionid <= id_max; optionid++)
if(!isnull(href_list["o[optionid]"])) //Test if this optionid was replied to
var/rating
if(href_list["o[optionid]"] == "abstain")
@@ -242,6 +242,17 @@
return
vote_on_numval_poll(pollid, optionid, rating)
if("MULTICHOICE")
var/id_min = text2num(href_list["minoptionid"])
var/id_max = text2num(href_list["maxoptionid"])
if( (id_max - id_min) > 100 ) //Basic exploit prevention
usr << "The option ID difference is too big. Please contact administration or the database admin."
return
for(var/optionid = id_min; optionid <= id_max; optionid++)
if(!isnull(href_list["option_[optionid]"])) //Test if this optionid was selected
vote_on_poll(pollid, optionid, 1)
proc/IsJobAvailable(rank)
var/datum/job/job = job_master.GetJob(rank)
@@ -278,15 +289,14 @@
proc/AnnounceArrival(var/mob/living/carbon/human/character, var/rank)
if (ticker.current_state == GAME_STATE_PLAYING)
var/obj/item/device/radio/intercom/a = new /obj/item/device/radio/intercom(null)// BS12 EDIT Arrivals Announcement Computer, rather than the AI.
a.autosay("\"[character.real_name],[character.wear_id.assignment ? " [character.wear_id.assignment]," : "" ] has arrived on the station.\"", "Arrivals Announcement Computer")
//unlikely for this to be an issue, but just in case
if(istype(character.wear_id, /obj/item/weapon/card/id))
var/obj/item/weapon/card/id/I = character.wear_id
a.autosay("\"[character.real_name],[I.assignment ? " [I.assignment]," : "" ] has arrived on the station.\"", "Arrivals Announcement Computer")
else
a.autosay("\"[character.real_name], visitor, has arrived on the station.\"", "Arrivals Announcement Computer")
del(a)
/*
var/mob/living/silicon/ai/announcer = new (null)
announcer.name = "Arrivals Announcement Computer"
announcer.real_name = "Arrivals Announcement Computer"
a.autosay("\"[character.real_name],[character.wear_id.assignment ? " [character.wear_id.assignment]," : "" ] has arrived on the station.\"", announcer)
del(announcer)
*/
proc/LateChoices()
var/mills = world.time // 1/10 of a second, not real milliseconds but whatever
+78 -7
View File
@@ -84,7 +84,7 @@
establish_db_connection()
if(dbcon.IsConnected())
var/DBQuery/select_query = dbcon.NewQuery("SELECT starttime, endtime, question, polltype FROM erro_poll_question WHERE id = [pollid]")
var/DBQuery/select_query = dbcon.NewQuery("SELECT starttime, endtime, question, polltype, multiplechoiceoptions FROM erro_poll_question WHERE id = [pollid]")
select_query.Execute()
var/pollstarttime = ""
@@ -92,6 +92,7 @@
var/pollquestion = ""
var/polltype = ""
var/found = 0
var/multiplechoiceoptions = 0
while(select_query.NextRow())
pollstarttime = select_query.item[1]
@@ -271,9 +272,71 @@
output += "</form>"
src << browse(output,"window=playerpoll;size=500x500")
if("MULTICHOICE")
var/DBQuery/voted_query = dbcon.NewQuery("SELECT optionid FROM erro_poll_vote WHERE pollid = [pollid] AND ckey = '[usr.ckey]'")
voted_query.Execute()
var/list/votedfor = list()
var/voted = 0
while(voted_query.NextRow())
votedfor.Add(text2num(voted_query.item[1]))
voted = 1
var/list/datum/polloption/options = list()
var/maxoptionid = 0
var/minoptionid = 0
var/DBQuery/options_query = dbcon.NewQuery("SELECT id, text FROM erro_poll_option WHERE pollid = [pollid]")
options_query.Execute()
while(options_query.NextRow())
var/datum/polloption/PO = new()
PO.optionid = text2num(options_query.item[1])
PO.optiontext = options_query.item[2]
if(PO.optionid > maxoptionid)
maxoptionid = PO.optionid
if(PO.optionid < minoptionid || !minoptionid)
minoptionid = PO.optionid
options += PO
if(select_query.item[5])
multiplechoiceoptions = text2num(select_query.item[5])
var/output = "<div align='center'><B>Player poll</B>"
output +="<hr>"
output += "<b>Question: [pollquestion]</b><br>You can select up to [multiplechoiceoptions] options. If you select more, the first [multiplechoiceoptions] will be saved.<br>"
output += "<font size='2'>Poll runs from <b>[pollstarttime]</b> until <b>[pollendtime]</b></font><p>"
if(!voted) //Only make this a form if we have not voted yet
output += "<form name='cardcomp' action='?src=\ref[src]' method='get'>"
output += "<input type='hidden' name='src' value='\ref[src]'>"
output += "<input type='hidden' name='votepollid' value='[pollid]'>"
output += "<input type='hidden' name='votetype' value='MULTICHOICE'>"
output += "<input type='hidden' name='maxoptionid' value='[maxoptionid]'>"
output += "<input type='hidden' name='minoptionid' value='[minoptionid]'>"
output += "<table><tr><td>"
for(var/datum/polloption/O in options)
if(O.optionid && O.optiontext)
if(voted)
if(O.optionid in votedfor)
output += "<b>[O.optiontext]</b><br>"
else
output += "[O.optiontext]<br>"
else
output += "<input type='checkbox' name='option_[O.optionid]' value='[O.optionid]'> [O.optiontext]<br>"
output += "</td></tr></table>"
if(!voted) //Only make this a form if we have not voted yet
output += "<p><input type='submit' value='Vote'>"
output += "</form>"
output += "</div>"
src << browse(output,"window=playerpoll;size=500x250")
return
/mob/new_player/proc/vote_on_poll(var/pollid = -1, var/optionid = -1)
/mob/new_player/proc/vote_on_poll(var/pollid = -1, var/optionid = -1, var/multichoice = 0)
if(pollid == -1 || optionid == -1)
return
@@ -282,15 +345,18 @@
establish_db_connection()
if(dbcon.IsConnected())
var/DBQuery/select_query = dbcon.NewQuery("SELECT starttime, endtime, question, polltype FROM erro_poll_question WHERE id = [pollid] AND Now() BETWEEN starttime AND endtime")
var/DBQuery/select_query = dbcon.NewQuery("SELECT starttime, endtime, question, polltype, multiplechoiceoptions FROM erro_poll_question WHERE id = [pollid] AND Now() BETWEEN starttime AND endtime")
select_query.Execute()
var/validpoll = 0
var/multiplechoiceoptions = 0
while(select_query.NextRow())
if(select_query.item[4] != "OPTION")
if(select_query.item[4] != "OPTION" && select_query.item[4] != "MULTICHOICE")
return
validpoll = 1
if(select_query.item[5])
multiplechoiceoptions = text2num(select_query.item[5])
break
if(!validpoll)
@@ -316,13 +382,18 @@
voted_query.Execute()
while(voted_query.NextRow())
alreadyvoted = 1
break
alreadyvoted += 1
if(!multichoice)
break
if(alreadyvoted)
if(!multichoice && alreadyvoted)
usr << "\red You already voted in this poll."
return
if(multichoice && (alreadyvoted >= multiplechoiceoptions))
usr << "\red You already have more than [multiplechoiceoptions] logged votes on this poll. Enough is enough. Contact the database admin if this is an error."
return
var/adminrank = "Player"
if(usr && usr.client && usr.client.holder)
adminrank = usr.client.holder.rank
+121 -15
View File
@@ -1,26 +1,132 @@
datum/preferences
//The mob should have a gender you want before running this proc.
//The mob should have a gender you want before running this proc. Will run fine without H
proc/randomize_appearance_for(var/mob/living/carbon/human/H)
if(H.gender == MALE)
gender = MALE
else
gender = FEMALE
if(H)
if(H.gender == MALE)
gender = MALE
else
gender = FEMALE
s_tone = random_skin_tone()
h_style = random_hair_style(gender)
f_style = random_facial_hair_style(gender)
r_hair = rand(0,255)
g_hair = rand(0,255)
b_hair = rand(0,255)
r_facial = r_hair
g_facial = g_hair
b_facial = b_hair
r_eyes = rand(0,255)
g_eyes = rand(0,255)
b_eyes = rand(0,255)
randomize_hair_color("hair")
randomize_hair_color("facial")
randomize_eyes_color()
underwear = rand(1,underwear_m.len)
backbag = 2
age = rand(AGE_MIN,AGE_MAX)
copy_to(H,1)
if(H)
copy_to(H,1)
proc/randomize_hair_color(var/target = "hair")
if(prob (75) && target == "facial") // Chance to inherit hair color
r_facial = r_hair
g_facial = g_hair
b_facial = b_hair
return
var/red
var/green
var/blue
var/col = pick ("blonde", "black", "chestnut", "copper", "brown", "wheat", "old", "punk")
switch(col)
if("blonde")
red = 255
green = 255
blue = 0
if("black")
red = 0
green = 0
blue = 0
if("chestnut")
red = 153
green = 102
blue = 51
if("copper")
red = 255
green = 153
blue = 0
if("brown")
red = 102
green = 51
blue = 0
if("wheat")
red = 255
green = 255
blue = 153
if("old")
red = rand (100, 255)
green = red
blue = red
if("punk")
red = rand (0, 255)
green = rand (0, 255)
blue = rand (0, 255)
red = max(min(red + rand (-25, 25), 255), 0)
green = max(min(green + rand (-25, 25), 255), 0)
blue = max(min(blue + rand (-25, 25), 255), 0)
switch(target)
if("hair")
r_hair = red
g_hair = green
b_hair = blue
if("facial")
r_facial = red
g_facial = green
b_facial = blue
proc/randomize_eyes_color()
var/red
var/green
var/blue
var/col = pick ("black", "grey", "brown", "chestnut", "blue", "lightblue", "green", "albino")
switch(col)
if("black")
red = 0
green = 0
blue = 0
if("grey")
red = rand (100, 200)
green = red
blue = red
if("brown")
red = 102
green = 51
blue = 0
if("chestnut")
red = 153
green = 102
blue = 0
if("blue")
red = 51
green = 102
blue = 204
if("lightblue")
red = 102
green = 204
blue = 255
if("green")
red = 0
green = 102
blue = 0
if("albino")
red = rand (200, 255)
green = rand (0, 150)
blue = rand (0, 150)
red = max(min(red + rand (-25, 25), 255), 0)
green = max(min(green + rand (-25, 25), 255), 0)
blue = max(min(blue + rand (-25, 25), 255), 0)
r_eyes = red
g_eyes = green
b_eyes = blue
proc/update_preview_icon() //seriously. This is horrendous.
del(preview_icon_front)
+9 -1
View File
@@ -6,6 +6,14 @@
var/id = 0.0
var/obj/master
/obj/screen/text
icon = null
icon_state = null
mouse_opacity = 0
screen_loc = "CENTER-7,CENTER-7"
maptext_height = 480
maptext_width = 480
/obj/screen/inventory
var/slot_id
@@ -210,7 +218,7 @@
else
return
overlays = null
overlays.Cut()
overlays += image('icons/mob/zone_sel.dmi', "[selecting]")
return
+9 -9
View File
@@ -207,7 +207,7 @@
del(src)
return
/mob/living/carbon/human/proc/Metroidize(adult as num, reproduce as num)
/mob/living/carbon/human/proc/slimeize(adult as num, reproduce as num)
if (monkeyizing)
return
for(var/obj/item/W in src)
@@ -220,25 +220,25 @@
for(var/t in organs)
del(t)
var/mob/living/carbon/metroid/new_metroid
var/mob/living/carbon/slime/new_slime
if(reproduce)
var/number = pick(14;2,3,4) //reproduce (has a small chance of producing 3 or 4 offspring)
var/list/babies = list()
for(var/i=1,i<=number,i++)
var/mob/living/carbon/metroid/M = new/mob/living/carbon/metroid(loc)
var/mob/living/carbon/slime/M = new/mob/living/carbon/slime(loc)
M.nutrition = round(nutrition/number)
step_away(M,src)
babies += M
new_metroid = pick(babies)
new_slime = pick(babies)
else
if(adult)
new_metroid = new /mob/living/carbon/metroid/adult(loc)
new_slime = new /mob/living/carbon/slime/adult(loc)
else
new_metroid = new /mob/living/carbon/metroid(loc)
new_metroid.a_intent = "hurt"
new_metroid.key = key
new_slime = new /mob/living/carbon/slime(loc)
new_slime.a_intent = "hurt"
new_slime.key = key
new_metroid << "<B>You are now a Metroid. Skreee!</B>"
new_slime << "<B>You are now a slime. Skreee!</B>"
spawn(0)//To prevent the proc from returning null.
del(src)
return