Penlight fits in medical belt.

Fixed several runtime errors.
Monkeys and aliens won't stack dozens of blood stains.
Fixed crash in FEA code related to melting floors.
When screwdrived destructive analyzer unlink from RD console protolate instead of itself.


git-svn-id: http://tgstation13.googlecode.com/svn/trunk@1443 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
rastaf.zero@gmail.com
2011-04-14 03:52:09 +00:00
parent e84d394289
commit ad6a6e42aa
38 changed files with 427 additions and 521 deletions

View File

@@ -23,7 +23,7 @@
process()
..()
if(!on)
if(!on || !network)
return 0
var/air_heat_capacity = air_contents.heat_capacity()
var/combined_heat_capacity = current_heat_capacity + air_heat_capacity

View File

@@ -152,9 +152,14 @@ obj
loc:active_hotspot = null
src.sd_SetLuminosity(0)
var/chance_of_deletion = min(100, T.max_fire_temperature_sustained / T.heat_capacity * 8)
if(T.to_be_destroyed)
var/chance_of_deletion
if (T.heat_capacity) //beware of division by zero
chance_of_deletion = T.max_fire_temperature_sustained / T.heat_capacity * 8 //there is no problem with prob(23456), min() was redundant --rastaf0
else
chance_of_deletion = 100
if(prob(chance_of_deletion))
T.ReplaceWithSpace()
else

View File

@@ -87,48 +87,47 @@ datum
return
reaction_turf(var/turf/T, var/volume)//splash the blood all over the place
reaction_turf(var/turf/simulated/T, var/volume)//splash the blood all over the place
if(!istype(T)) return
var/datum/reagent/blood/self = src
src = null
if(!istype(T, /turf/simulated/)) return
var/datum/disease/D = self.data["virus"]
if(istype(self.data["donor"], /mob/living/carbon/human) || !self.data["donor"])
var/turf/simulated/source2 = T
var/list/objsonturf = range(0,T)
var/i
for(i=1, i<=objsonturf.len, i++)
if(istype(objsonturf[i],/obj/decal/cleanable/blood))
return
var/obj/decal/cleanable/blood/blood_prop = new /obj/decal/cleanable/blood(source2)
if(!self.data["donor"] || istype(self.data["donor"], /mob/living/carbon/human))
var/obj/decal/cleanable/blood/blood_prop = locate() in T //find some blood here
if(!blood_prop) //first blood!
blood_prop = new(T)
blood_prop.blood_DNA = self.data["blood_DNA"]
blood_prop.blood_type = self.data["blood_type"]
if(D)
if(D && !blood_prop.virus) //TODO: multiple viruses
blood_prop.virus = new D.type
blood_prop.virus.holder = blood_prop
if(istype(T, /turf/simulated/floor) && D)
if(T.density==0)
blood_prop.virus.spread_type = CONTACT_FEET
else if (D)
else
blood_prop.virus.spread_type = CONTACT_HANDS
else if(istype(self.data["donor"], /mob/living/carbon/monkey))
var/turf/simulated/source1 = T
var/obj/decal/cleanable/blood/blood_prop = new /obj/decal/cleanable/blood(source1)
var/obj/decal/cleanable/blood/blood_prop = locate() in T
if(!blood_prop)
blood_prop = new(T)
blood_prop.blood_DNA = self.data["blood_DNA"]
if(D)
if(D && !blood_prop.virus)
blood_prop.virus = new D.type
blood_prop.virus.holder = blood_prop
if(istype(T, /turf/simulated/floor))
if(T.density==0)
blood_prop.virus.spread_type = CONTACT_FEET
else
blood_prop.virus.spread_type = CONTACT_HANDS
else if(istype(self.data["donor"], /mob/living/carbon/alien))
var/turf/simulated/source2 = T
var/obj/decal/cleanable/xenoblood/blood_prop = new /obj/decal/cleanable/xenoblood(source2)
if(D)
var/obj/decal/cleanable/xenoblood/blood_prop = locate() in T
if(!blood_prop)
blood_prop = new(T)
blood_prop.blood_DNA = self.data["blood_DNA"]
if(D && !blood_prop.virus)
blood_prop.virus = new D.type
blood_prop.virus.holder = blood_prop
if(istype(T, /turf/simulated/floor))
if(T.density==0)
blood_prop.virus.spread_type = CONTACT_FEET
else
blood_prop.virus.spread_type = CONTACT_HANDS
@@ -165,24 +164,25 @@ datum
description = "A ubiquitous chemical substance that is composed of hydrogen and oxygen."
reagent_state = LIQUID
reaction_turf(var/turf/T, var/volume)
if (istype(T, /turf/space)) return
reaction_turf(var/turf/simulated/T, var/volume)
if (!istype(T)) return
src = null
if(volume >= 3)
if(T:wet >= 1) return
T:wet = 1
if(T:wet_overlay)
T:overlays -= T:wet_overlay
T:wet_overlay = null
T:wet_overlay = image('water.dmi',T,"wet_floor")
T:overlays += T:wet_overlay
if(T.wet >= 1) return
T.wet = 1
if(T.wet_overlay)
T.overlays -= T.wet_overlay
T.wet_overlay = null
T.wet_overlay = image('water.dmi',T,"wet_floor")
T.overlays += T.wet_overlay
spawn(800)
if(T:wet >= 2) return
T:wet = 0
if(T:wet_overlay)
T:overlays -= T:wet_overlay
T:wet_overlay = null
if (!istype(T)) return
if(T.wet >= 2) return
T.wet = 0
if(T.wet_overlay)
T.overlays -= T.wet_overlay
T.wet_overlay = null
var/hotspot = (locate(/obj/hotspot) in T)
if(hotspot && !istype(T, /turf/space))
@@ -210,16 +210,17 @@ datum
description = "Lubricant is a substance introduced between two moving surfaces to reduce the friction and wear between them. giggity."
reagent_state = LIQUID
reaction_turf(var/turf/T, var/volume)
if (istype(T, /turf/space)) return
reaction_turf(var/turf/simulated/T, var/volume)
if (!istype(T)) return
src = null
if(T:wet >= 2) return
T:wet = 2
if(T.wet >= 2) return
T.wet = 2
spawn(800)
T:wet = 0
if(T:wet_overlay)
T:overlays -= T:wet_overlay
T:wet_overlay = null
if (!istype(T)) return
T.wet = 0
if(T.wet_overlay)
T.overlays -= T.wet_overlay
T.wet_overlay = null
return
bilk
@@ -1430,23 +1431,25 @@ datum
M:nutrition += nutriment_factor
..()
return
reaction_turf(var/turf/T, var/volume)
reaction_turf(var/turf/simulated/T, var/volume)
if (!istype(T)) return
src = null
if(volume >= 3)
if(T:wet >= 1) return
T:wet = 1
if(T:wet_overlay)
T:overlays -= T:wet_overlay
T:wet_overlay = null
T:wet_overlay = image('water.dmi',T,"wet_floor")
T:overlays += T:wet_overlay
if(T.wet >= 1) return
T.wet = 1
if(T.wet_overlay)
T.overlays -= T.wet_overlay
T.wet_overlay = null
T.wet_overlay = image('water.dmi',T,"wet_floor")
T.overlays += T.wet_overlay
spawn(800)
if(T:wet >= 2) return
T:wet = 0
if(T:wet_overlay)
T:overlays -= T:wet_overlay
T:wet_overlay = null
if (!istype(T)) return
if(T.wet >= 2) return
T.wet = 0
if(T.wet_overlay)
T.overlays -= T.wet_overlay
T.wet_overlay = null
var/hotspot = (locate(/obj/hotspot) in T)
if(hotspot)
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
@@ -2223,7 +2226,6 @@ datum
description = "Deny drinking this and prepare for THE LAW."
reagent_state = LIQUID
on_mob_life(var/mob/M)
spawn(5)
M.stunned = 2
if(!data) data = 1
data++

View File

@@ -815,7 +815,7 @@
user << "\red You cannot directly remove reagents from this object."
return
var/trans = target.reagents.trans_to(src, target:amount_per_transfer_from_this)
var/trans = target.reagents.trans_to(src, amount_per_transfer_from_this) // transfer from, transfer to - who cares?
user << "\blue You fill the syringe with [trans] units of the solution."
if (reagents.total_volume >= reagents.maximum_volume)

View File

@@ -11,6 +11,7 @@
attack_hand(mob/user as mob)
if (src.wrapped) //sometimes items can disappear. For example, bombs. --rastaf0
src.wrapped.loc = (get_turf(src.loc))
if (istype(src.wrapped,/obj/closet))
var/obj/closet/O = src.wrapped
@@ -36,6 +37,7 @@
attack_hand(mob/user as mob)
if (src.wrapped) //sometimes items can disappear. For example, bombs. --rastaf0
src.wrapped.loc = (get_turf(src.loc))
del(src)

View File

@@ -87,6 +87,7 @@
/datum/recipe/proc/make_food(var/obj/container as obj)
var/obj/result_obj = new result(container)
for (var/obj/O in (container.contents-result_obj))
if (O.reagents)
O.reagents.del_reagent("nutriment")
O.reagents.update_total()
O.reagents.trans_to(result_obj, O.reagents.total_volume)
@@ -110,7 +111,9 @@
var/i_count = 0
. = possible_recipes[1]
for (var/datum/recipe/recipe in possible_recipes)
if (recipe.items.len > i_count || (recipe.items.len == i_count && recipe.reagents.len > r_count ))
var/N_i = (recipe.items)?(recipe.items.len):0
var/N_r = (recipe.reagents)?(recipe.reagents.len):0
if (N_i > i_count || (N_i== i_count && N_r > r_count ))
r_count = recipe.reagents.len
i_count = recipe.items.len
. = recipe

View File

@@ -34,7 +34,9 @@
"/obj/item/weapon/zippo",
"/obj/item/weapon/cigpacket",
"/obj/item/weapon/storage/pill_bottle",
"/obj/item/weapon/medical")
"/obj/item/weapon/medical",
"/obj/item/device/flashlight/pen"
)
flags = FPRINT | TABLEPASS | ONBELT
/obj/item/weapon/storage

View File

@@ -183,7 +183,7 @@
world << sound('intercept.ogg')
check_finished()
if(!changeling.current)
if(!changeling)
return 1
if(istype(changeling.current,/mob/living/silicon))

View File

@@ -169,13 +169,7 @@
implants += W
for(var/obj/item/W in usr)
usr.u_equip(W)
if (usr.client)
usr.client.screen -= W
if (W)
W.loc = usr.loc
W.dropped(usr)
W.layer = initial(W.layer)
usr.drop_from_slot(W)
usr.update_clothing()
usr.monkeyizing = 1

View File

@@ -36,13 +36,13 @@
event = 1
command_alert("Space-time anomalies detected on the station. There is no additional data.", "Anomaly Alert")
world << sound('spanomalies.ogg')
var/list/turfs = list( )
var/list/turfs = new
var/turf/picked
for(var/turf/T in world)
if(T.z == 1 && istype(T,/turf/simulated/floor) && !istype(T,/turf/space))
for(var/turf/simulated/floor/T in world)
if(T.z == 1)
turfs += T
for(var/turf/T in world)
if(prob(20) && T.z == 1 && istype(T,/turf/simulated/floor))
for(var/turf/simulated/floor/T in turfs)
if(prob(20))
spawn(50+rand(0,3000))
picked = pick(turfs)
var/obj/portal/P = new /obj/portal( T )

View File

@@ -205,7 +205,7 @@ datum
return num_to_eat
check_completion()
if((owner.current.absorbed_dna.len - 1) >= num_to_eat)
if(owner && owner.current && owner.current.absorbed_dna && ((owner.current.absorbed_dna.len - 1) >= num_to_eat))
return 1
else
return 0

View File

@@ -275,6 +275,8 @@
return
/obj/machinery/camera/attack_ai(var/mob/living/silicon/ai/user as mob)
if (!istype(user))
return
if (src.network != user.network || !(src.status))
return
user.current = src

View File

@@ -91,13 +91,13 @@
new O.type (src)
O:use(1)
user.visible_message( \
"[user] has added one of [O] to \the [src].", \
"\blue [user] has added one of [O] to \the [src].", \
"\blue You add one of [O] to \the [src].")
else
user.before_take_item(O)
O.loc = src
user.visible_message( \
"[user] has added \the [O] to \the [src].", \
"\blue [user] has added \the [O] to \the [src].", \
"\blue You add \the [O] to \the [src].")
else if(istype(O,/obj/item/weapon/reagent_containers/glass) || \
istype(O,/obj/item/weapon/reagent_containers/food/drinks) || \

View File

@@ -331,7 +331,8 @@
R.amount--
throw_item = new dump_path(src.loc)
break
if (!throw_item)
return 0
spawn(0)
throw_item.throw_at(target, 16, 3)
src.visible_message("\red <b>[src] launches [throw_item.name] at [target.name]!</b>")

View File

@@ -513,7 +513,10 @@ var/list/sacrificed = list()
communicate()
var/input = input(usr, "Please choose a message to tell to the other acolytes.", "Voice of Blood", "") as text|null
if(!input)
if (istype(src))
return fizzle()
else
return
if(istype(src,/obj/rune))
usr.say("O bidai nabora se'sma!")
else

View File

@@ -223,8 +223,9 @@
src.use_power = 2
src.updateUsrDialog()
sleep(get_construction_time_w_coeff(part,0.1))
if(!src) return
//if(!src) return // you do not need to check it, all sleeping procedires will be terminated when src dies. -- rastaf0
src.use_power = 1
if(!being_built) return //was runtime error with null.Move()
src.being_built.Move(get_step(src,EAST))
src.icon_state = initial(src.icon_state)
src.visible_message("<b>[src]</b> beeps, \"The [src.being_built] is complete\".")

View File

@@ -108,6 +108,7 @@
return
var/obj/mecha/Mech = M.loc
spawn() //this helps prevent clickspam fest.
if (Mech)
Mech.click_action(object,M)
else
return ..()

View File

@@ -24,7 +24,7 @@
user << "\red It appears to be broken."
return
var/obj/item/weapon/card/id/I = W
if (src.allowed(user) || !src.registered || (istype(W, /obj/item/weapon/card/id) && src.registered == I.registered))
if (src.allowed(user) || !src.registered || (istype(I) && (src.registered == I.registered)))
//they can open all lockers, or nobody owns this, or they own this locker
src.locked = !( src.locked )
for(var/mob/O in viewers(user, 3))

View File

@@ -82,6 +82,8 @@ MASS SPECTROMETER
/obj/item/device/detective_scanner/attack(mob/living/carbon/human/M as mob, mob/user as mob)
if (!istype(M))
user << "\red [M] is not humas and cannot have the fingerprints."
if (( !( istype(M.dna, /datum/dna) ) || M.gloves) )
user << "\blue No fingerprints found on [M]"
else

View File

@@ -58,12 +58,9 @@ FINGERPRINT CARD
if(istype(W,/obj/item/weapon/photo))
if(!(PHOTO))
src.PHOTO = W
usr.u_equip(W)
usr.before_take_item(W)
W.loc = src
if ((usr.client && usr.s_active != src))
usr.client.screen -= W
//src.orient2hud(usr)
W.dropped(usr)
add_fingerprint(usr)
usr << "\blue You add the photo to the ID"
else

View File

@@ -10,9 +10,9 @@
del(src)
/obj/item/weapon/tank/attack_self(mob/user as mob)
user.machine = src
if (!(src.air_contents))
return
user.machine = src
var/using_internal
if(istype(loc,/mob/living/carbon))
@@ -45,22 +45,26 @@
if(istype(loc,/mob/living/carbon))
var/mob/living/carbon/location = loc
if(location.internal == src)
usr << "\blue You close the tank release valve."
usr << "\blue You close \the [src] release valve."
if (location.internals)
location.internals.icon_state = "internal0"
else
if(location.wear_mask && (location.wear_mask.flags & MASKINTERNALS))
location.internal = src
usr << "\blue You open the tank valve."
usr << "\blue You open \the [src] valve."
if (location.internals)
location.internals.icon_state = "internal1"
else
usr << "\blue The valve immediately closes."
usr << "\blue You need something to connect to \the [src]."
src.add_fingerprint(usr)
/*
* the following is needed for a tank lying on the floor. But currently we restrict players to use not weared tanks as intrals. --rastaf
for(var/mob/M in viewers(1, src.loc))
if ((M.client && M.machine == src))
src.attack_self(M)
*/
src.attack_self(usr)
else
usr << browse(null, "window=tank")
return
@@ -144,10 +148,10 @@
else if(integrity < 3)
integrity++
/* redundant. --rastaf0
/obj/item/weapon/tank/attack(mob/M as mob, mob/user as mob)
..()
*/
/*
if ((prob(30) && M.stat < 2))
var/mob/living/carbon/human/H = M
@@ -173,7 +177,7 @@
/obj/item/weapon/tank/attackby(obj/item/weapon/W as obj, mob/user as mob)
..()
var/obj/item/weapon/icon = src
var/obj/icon = src
if (istype(src.loc, /obj/item/assembly))
icon = src.loc
if ((istype(W, /obj/item/device/analyzer) || (istype(W, /obj/item/device/pda))) && get_dist(user, src) <= 1)
@@ -228,7 +232,7 @@
..()
/obj/item/weapon/tank/examine()
var/obj/item/weapon/icon = src
var/obj/icon = src
if (istype(src.loc, /obj/item/assembly))
icon = src.loc
if (!in_range(src, usr))
@@ -371,7 +375,8 @@
ground_zero.assume_air(air_contents)
ground_zero.hotspot_expose(1000, 125)
if(src.master) del(src.master)
if(src.master)
del(src.master)
del(src)
/obj/item/weapon/tank/plasma/attackby(obj/item/weapon/W as obj, mob/user as mob)
@@ -381,178 +386,128 @@
var/obj/item/assembly/rad_ignite/S = W
if (!( S.status ))
return
var/obj/item/assembly/r_i_ptank/R = new /obj/item/assembly/r_i_ptank( user )
var/obj/item/assembly/r_i_ptank/R = new
R.part1 = S.part1
S.part1.loc = R
S.part1.master = R
R.part2 = S.part2
S.part2.loc = R
S.part2.master = R
S.layer = initial(S.layer)
if (user.client)
user.client.screen -= S
if (user.r_hand == S)
user.u_equip(S)
user.r_hand = R
else
user.u_equip(S)
user.l_hand = R
src.master = R
src.layer = initial(src.layer)
user.u_equip(src)
if (user.client)
user.client.screen -= src
src.loc = R
R.part3 = src
R.layer = 20
R.loc = user
user.put_in_hand(R)
user.before_take_item(src)
src.loc = R
S.part1 = null
S.part2 = null
//S = null
del(S)
if (istype(W, /obj/item/assembly/prox_ignite))
var/obj/item/assembly/prox_ignite/S = W
if (!( S.status ))
return
var/obj/item/assembly/m_i_ptank/R = new /obj/item/assembly/m_i_ptank( user )
var/obj/item/assembly/m_i_ptank/R = new
R.part1 = S.part1
S.part1.loc = R
S.part1.master = R
R.part2 = S.part2
S.part2.loc = R
S.part2.master = R
S.layer = initial(S.layer)
if (user.client)
user.client.screen -= S
if (user.r_hand == S)
user.u_equip(S)
user.r_hand = R
else
user.u_equip(S)
user.l_hand = R
src.master = R
src.layer = initial(src.layer)
user.u_equip(src)
if (user.client)
user.client.screen -= src
src.loc = R
R.part3 = src
R.layer = 20
R.loc = user
user.put_in_hand(R)
user.before_take_item(src)
src.loc = R
S.part1 = null
S.part2 = null
//S = null
del(S)
if (istype(W, /obj/item/assembly/time_ignite))
var/obj/item/assembly/time_ignite/S = W
if (!( S.status ))
return
var/obj/item/assembly/t_i_ptank/R = new /obj/item/assembly/t_i_ptank( user )
var/obj/item/assembly/t_i_ptank/R = new
R.part1 = S.part1
if (S.part1)
S.part1.loc = R
S.part1.master = R
R.part2 = S.part2
if (S.part2)
S.part2.loc = R
S.part2.master = R
S.layer = initial(S.layer)
if (user.client)
user.client.screen -= S
if (user.r_hand == S)
user.u_equip(S)
user.r_hand = R
else
user.u_equip(S)
user.l_hand = R
src.master = R
src.layer = initial(src.layer)
user.u_equip(src)
if (user.client)
user.client.screen -= src
src.loc = R
R.part3 = src
R.layer = 20
R.loc = user
user.put_in_hand(R)
user.before_take_item(src)
src.loc = R
S.part1 = null
S.part2 = null
//S = null
del(S)
if (istype(W, /obj/item/assembly/a_i_a))
var/obj/item/assembly/a_i_a/S = W
if (!( S.status ))
return
var/obj/item/clothing/suit/armor/a_i_a_ptank/R = new /obj/item/clothing/suit/armor/a_i_a_ptank( user )
var/obj/item/clothing/suit/armor/a_i_a_ptank/R = new
R.part1 = S.part1
S.part1.loc = R
S.part1.master = R
R.part2 = S.part2
S.part2.loc = R
S.part2.master = R
R.part3 = S.part3
S.part3.loc = R
S.part3.master = R
S.layer = initial(S.layer)
if (user.client)
user.client.screen -= S
if (user.r_hand == S)
user.u_equip(S)
user.r_hand = R
else
user.u_equip(S)
user.l_hand = R
src.master = R
src.layer = initial(src.layer)
user.u_equip(src)
if (user.client)
user.client.screen -= src
src.loc = R
R.part4 = src
R.layer = 20
R.loc = user
user.put_in_hand(R)
user.before_take_item(src)
src.loc = R
S.part1 = null
S.part2 = null
S.part3 = null
//S = null
del(S)
// PantsNote: More flamethrower assembly code. WOO!
if (istype(W, /obj/item/assembly/w_r_ignite))
var/obj/item/assembly/w_r_ignite/S = W
if (!( S.status ))
return
var/obj/item/weapon/flamethrower/R = new /obj/item/weapon/flamethrower( user )
var/obj/item/weapon/flamethrower/R = new
R.part1 = S.part1
S.part1.loc = R
S.part1.master = R
R.part2 = S.part2
S.part2.loc = R
S.part2.master = R
R.part3 = S.part3
S.part3.loc = R
S.part3.master = R
S.layer = initial(S.layer)
if (user.client)
user.client.screen -= S
if (user.r_hand == S)
user.u_equip(S)
user.r_hand = R
else
user.u_equip(S)
user.l_hand = R
src.master = R
src.layer = initial(src.layer)
user.u_equip(src)
if (user.client)
user.client.screen -= src
src.loc = R
R.part4 = src
R.layer = 20
R.loc = user
user.put_in_hand(R)
user.before_take_item(src)
src.loc = R
S.part1 = null
S.part2 = null
S.part3 = null
//S = null
del(S)
return

View File

@@ -114,6 +114,8 @@
return
/obj/item/assembly/time_ignite/receive_signal()
if (!status)
return
for(var/mob/O in hearers(1, src.loc))
O.show_message(text("\icon[] *beep* *beep*", src), 3, "*beep* *beep*", 2)
src.part2.ignite()
@@ -130,11 +132,9 @@
var/turf/T = src.loc
if (ismob(T))
T = T.loc
if (src.part1)
src.part1.loc = T
src.part1.master = null
src.part1 = null
if (src.part2)
src.part2.loc = T
src.part2.master = null
src.part2 = null
@@ -148,7 +148,6 @@
user.show_message("\blue The timer is now secured!", 1)
else
user.show_message("\blue The timer is now unsecured!", 1)
if (src.part2)
src.part2.status = src.status
src.add_fingerprint(user)
return
@@ -166,10 +165,10 @@
if (ismob(T))
T = T.loc
src.part1.loc = T
src.part2.loc = T
src.part1.master = null
src.part2.master = null
src.part1 = null
src.part2.loc = T
src.part2.master = null
src.part2 = null
del(src)
@@ -183,7 +182,22 @@
src.part2.status = src.status
src.add_fingerprint(user)
if(( istype(W, /obj/item/clothing/suit/armor/vest) ) && src.status)
var/obj/item/assembly/a_i_a/R = new /obj/item/assembly/a_i_a( user )
var/obj/item/assembly/a_i_a/R = new
R.part1 = part1
R.part1.master = R
part1 = null
R.part2 = part2
R.part2.master = R
part2 = null
user.put_in_hand(R)
user.before_take_item(W)
R.part3 = W
R.part3.master = R
del(src)
/* WTF THIS SHIT? It is working? Shouldn't. --rastaf0
W.loc = R
R.part1 = W
R.part2 = W
@@ -207,6 +221,7 @@
R.layer = 20
R.loc = user
src.add_fingerprint(user)
*/
return
/* else if ((istype(W, /obj/item/device/timer) && !( src.status )))
@@ -241,18 +256,21 @@
if (ismob(T))
T = T.loc
src.part1.loc = T
src.part2.loc = T
src.part3.loc = T
src.part1.master = null
src.part2.master = null
src.part3.master = null
src.part1 = null
src.part2.loc = T
src.part2.master = null
src.part2 = null
src.part3.loc = T
src.part3.master = null
src.part3 = null
del(src)
return
if (( istype(W, /obj/item/weapon/screwdriver) ))
if (!src.status && (!part1||!part2||!part3))
user << "\red You cannot finish the assembly, not all components are in place!"
return
src.status = !( src.status )
if (src.status)
user.show_message("\blue The armor is now secured!", 1)
@@ -306,7 +324,6 @@
return
/obj/item/assembly/rad_time/attack_self(mob/user as mob)
src.part1.attack_self(user, src.status)
src.part2.attack_self(user, src.status)
src.add_fingerprint(user)
@@ -369,7 +386,6 @@
return
/obj/item/assembly/rad_prox/receive_signal(datum/signal/signal)
if (!src.part2 || !src.part1) return
if (signal.source == src.part2)
src.part1.send_signal("ACTIVATE")
return
@@ -425,7 +441,6 @@
return
/obj/item/assembly/rad_infra/attack_self(mob/user as mob)
src.part1.attack_self(user, src.status)
src.part2.attack_self(user, src.status)
src.add_fingerprint(user)
@@ -516,6 +531,7 @@
/obj/item/assembly/prox_ignite/attack_self(mob/user as mob)
if (src.part1)
src.part1.attack_self(user, src.status)
src.add_fingerprint(user)
return
@@ -578,6 +594,7 @@
/obj/item/assembly/rad_ignite/attack_self(mob/user as mob)
if (src.part1)
src.part1.attack_self(user, src.status)
src.add_fingerprint(user)
return
@@ -631,13 +648,13 @@
/obj/item/assembly/m_i_ptank/dropped()
spawn( 0 )
src.part1.sense()
part1.sense()
return
return
/obj/item/assembly/m_i_ptank/examine()
..()
src.part3.examine()
part3.examine()
/obj/item/assembly/m_i_ptank/Del()
@@ -654,36 +671,25 @@
..()
if (istype(W, /obj/item/device/analyzer))
src.part3.attackby(W, user)
return
if ((istype(W, /obj/item/weapon/wrench) && !( src.status )))
var/obj/item/assembly/prox_ignite/R = new /obj/item/assembly/prox_ignite( )
var/obj/item/assembly/prox_ignite/R = new(get_turf(src.loc))
R.part1 = src.part1
R.part1.master = R
R.part1.loc = R
R.part2 = src.part2
R.loc = src.loc
if (user.r_hand == src)
user.r_hand = R
R.layer = 20
R.part2.master = R
R.part2.loc = R
if (user.get_inactive_hand()==src)
user.put_in_inactive_hand(part3)
else
if (user.l_hand == src)
user.l_hand = R
R.layer = 20
src.part1.loc = R
src.part2.loc = R
src.part1.master = R
src.part2.master = R
var/turf/T = src.loc
if (!( istype(T, /turf) ))
T = T.loc
if (!( istype(T, /turf) ))
T = T.loc
src.part3.loc = T
part3.loc = src.loc
src.part1 = null
src.part2 = null
src.part3 = null
//SN src = null
del(src)
return
if (!( istype(W, /obj/item/weapon/weldingtool) ))
if (!( istype(W, /obj/item/weapon/weldingtool)&&W:welding ))
return
if (!( src.status ))
src.status = 1
@@ -754,35 +760,22 @@
if (istype(W, /obj/item/device/analyzer))
src.part3.attackby(W, user)
return
if ((istype(W, /obj/item/weapon/wrench) && !( src.status )))
var/obj/item/assembly/time_ignite/R = new /obj/item/assembly/time_ignite( )
var/obj/item/assembly/time_ignite/R = new(get_turf(src.loc))
R.part1 = src.part1
R.part1.master = R
R.part1.loc = R
R.part2 = src.part2
R.loc = src.loc
if (user.r_hand == src)
user.r_hand = R
R.layer = 20
R.part2.master = R
R.part2.loc = R
if (user.get_inactive_hand()==src)
user.put_in_inactive_hand(part3)
else
if (user.l_hand == src)
user.l_hand = R
R.layer = 20
if(src.part1)
src.part1.loc = R
src.part1.master = R
if(src.part2)
src.part2.loc = R
src.part2.master = R
var/turf/T = src.loc
if (!( istype(T, /turf) ))
T = T.loc
if (!( istype(T, /turf) ))
T = T.loc
src.part3.loc = T
part3.loc = src.loc
src.part1 = null
src.part2 = null
src.part3 = null
//SN src = null
del(src)
return
if (!( istype(W, /obj/item/weapon/weldingtool) && W:welding))
@@ -798,13 +791,11 @@
bombers += "[key_name(user)] unwelded a time bomb. Temp: [src.part3.air_contents.temperature-T0C]"
user << "\blue The hole has been closed."
src.part2.status = src.status
src.add_fingerprint(user)
return
/obj/item/assembly/t_i_ptank/attack_self(mob/user as mob)
if (src.part1)
src.part1.attack_self(user, 1)
playsound(src.loc, 'armbomb.ogg', 100, 1)
src.add_fingerprint(user)
@@ -848,33 +839,22 @@
if (istype(W, /obj/item/device/analyzer))
src.part3.attackby(W, user)
return
if ((istype(W, /obj/item/weapon/wrench) && !( src.status )))
var/obj/item/assembly/rad_ignite/R = new /obj/item/assembly/rad_ignite( )
var/obj/item/assembly/rad_ignite/R = new(get_turf(src.loc))
R.part1 = src.part1
R.part1.master = R
R.part1.loc = R
R.part2 = src.part2
R.loc = src.loc
if (user.r_hand == src)
user.r_hand = R
R.layer = 20
R.part2.master = R
R.part2.loc = R
if (user.get_inactive_hand()==src)
user.put_in_inactive_hand(part3)
else
if (user.l_hand == src)
user.l_hand = R
R.layer = 20
src.part1.loc = R
src.part2.loc = R
src.part1.master = R
src.part2.master = R
var/turf/T = src.loc
if (!( istype(T, /turf) ))
T = T.loc
if (!( istype(T, /turf) ))
T = T.loc
src.part3.loc = T
part3.loc = src.loc
src.part1 = null
src.part2 = null
src.part3 = null
//SN src = null
del(src)
return
if (!( istype(W, /obj/item/weapon/weldingtool) && W:welding ))
@@ -904,37 +884,26 @@
..()
if (istype(W, /obj/item/device/analyzer))
src.part4.attackby(W, user)
return
if ((istype(W, /obj/item/weapon/wrench) && !( src.status )))
var/obj/item/assembly/a_i_a/R = new /obj/item/assembly/a_i_a( )
var/obj/item/assembly/a_i_a/R = new(get_turf(src.loc))
R.part1 = src.part1
R.part1.master = R
R.part1.loc = R
R.part2 = src.part2
R.part2.master = R
R.part2.loc = R
R.part3 = src.part3
R.loc = src.loc
if (user.r_hand == src)
user.r_hand = R
R.layer = 20
R.part3.master = R
R.part3.loc = R
if (user.get_inactive_hand()==src)
user.put_in_inactive_hand(part4)
else
if (user.l_hand == src)
user.l_hand = R
R.layer = 20
src.part1.loc = R
src.part2.loc = R
src.part3.loc = R
src.part1.master = R
src.part2.master = R
src.part3.master = R
var/turf/T = src.loc
if (!( istype(T, /turf) ))
T = T.loc
if (!( istype(T, /turf) ))
T = T.loc
src.part4.loc = T
part4.loc = src.loc
src.part1 = null
src.part2 = null
src.part3 = null
src.part4 = null
//SN src = null
del(src)
return
if (( istype(W, /obj/item/weapon/weldingtool) && W:welding))
@@ -953,8 +922,6 @@
return
/obj/item/assembly/r_i_ptank/attack_self(mob/user as mob)
if (src.part1)
playsound(src.loc, 'armbomb.ogg', 100, 1)
src.part1.attack_self(user, 1)
src.add_fingerprint(user)

View File

@@ -46,7 +46,7 @@ Note: Must be placed within 3 tiles of the R&D Console
if (!opened)
opened = 1
if(linked_console)
linked_console.linked_lathe = null
linked_console.linked_destroy = null
linked_console = null
icon_state = "d_analyzer_t"
user << "You open the maintenance hatch of [src]."

View File

@@ -5,14 +5,7 @@
src << "Only administrators may use this command."
return
for(var/obj/item/W in M)
if (istype(W,/obj/item))
M.u_equip(W)
if (M.client)
M.client.screen -= W
if (W)
W.loc = M.loc
W.dropped(M)
W.layer = initial(W.layer)
M.drop_from_slot(W)
log_admin("[key_name(usr)] made [key_name(M)] drop everything!")
message_admins("[key_name_admin(usr)] made [key_name_admin(M)] drop everything!", 1)
@@ -29,14 +22,7 @@
return
//strip their stuff before they teleport into a cell :downs:
for(var/obj/item/W in M)
if (!istype(W,/datum/organ))
M.u_equip(W)
if (M.client)
M.client.screen -= W
if (W)
W.loc = M.loc
W.dropped(M)
W.layer = initial(W.layer)
M.drop_from_slot(W)
//teleport person to cell
M.paralysis += 5
sleep(5) //so they black out before warping

View File

@@ -174,3 +174,12 @@ var/list/karma_spenders = list()
else if(!src.client.be_alien)
src.client.be_alien = 1
src << "You are now included in alien candidate lists until end of round."
/mob/dead/observer/memory()
set hidden = 1
src << "\red You are dead! You have no mind to store memory!"
/mob/dead/observer/add_memory()
set hidden = 1
src << "\red You are dead! You have no mind to store memory!"

View File

@@ -13,15 +13,18 @@ Doesn't work on other aliens/AI.*/
if(src.stat)
src << "\green You must be conscious to do this."
return
if(src.toxloss >= 100)
if(!isturf(src.loc) || istype(src.loc, /turf/space))
src << "\green Bad place for garden!"
return
if(src.toxloss < 100)
src << "\green Not enough plasma stored."
return
src.toxloss -= 100
for(var/mob/O in viewers(src, null))
O.show_message(text("\green <B>[src] has planted some alien weeds!</B>"), 1)
var/obj/alien/weeds/W = new /obj/alien/weeds(src.loc)
var/obj/alien/weeds/W = new (src.loc)
W.Life()
else
src << "\green Not enough plasma stored."
return
/mob/living/carbon/alien/humanoid/verb/call_to()

View File

@@ -1,18 +1,18 @@
/mob/living/carbon/alien/humanoid/drone/New()
spawn (1)
src.verbs += /mob/living/carbon/alien/humanoid/proc/corrode_target
src.verbs -= /mob/living/carbon/alien/humanoid/verb/call_to
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(src.name == "alien drone")
src.name = text("alien drone ([rand(1, 1000)])")
src.real_name = src.name
spawn (1)
src.verbs += /mob/living/carbon/alien/humanoid/proc/corrode_target
src.verbs -= /mob/living/carbon/alien/humanoid/verb/call_to
src.stand_icon = new /icon('alien.dmi', "aliend_s")
src.lying_icon = new /icon('alien.dmi', "aliend_l")
src.icon = src.stand_icon
if(src.name == "alien drone") src.name = text("alien drone ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
//Drones use the same base as generic humanoids.
//Drone verbs

View File

@@ -1,17 +1,17 @@
/mob/living/carbon/alien/humanoid/hunter/New()
spawn (1)
src.verbs -= /mob/living/carbon/alien/humanoid/verb/corrode
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(src.name == "alien hunter")
src.name = text("alien hunter ([rand(1, 1000)])")
src.real_name = src.name
spawn (1)
src.verbs -= /mob/living/carbon/alien/humanoid/verb/corrode
src.stand_icon = new /icon('alien.dmi', "alienh_s")
src.lying_icon = new /icon('alien.dmi', "alienh_l")
src.icon = src.stand_icon
if(src.name == "alien hunter") src.name = text("alien hunter ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
/mob/living/carbon/alien/humanoid/hunter

View File

@@ -1,17 +1,17 @@
/mob/living/carbon/alien/humanoid/sentinel/New()
spawn (1)
src.verbs += /mob/living/carbon/alien/humanoid/proc/corrode_target
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(src.name == "alien sentinel")
src.name = text("alien sentinel ([rand(1, 1000)])")
src.real_name = src.name
spawn (1)
src.verbs += /mob/living/carbon/alien/humanoid/proc/corrode_target
src.stand_icon = new /icon('alien.dmi', "aliens_s")
src.lying_icon = new /icon('alien.dmi', "aliens_l")
src.icon = src.stand_icon
if(src.name == "alien sentinel") src.name = text("alien sentinel ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
/mob/living/carbon/alien/humanoid/sentinel

View File

@@ -1,20 +1,19 @@
//This is fine right now, if we're adding organ specific damage this needs to be updated
/mob/living/carbon/alien/humanoid/New()
spawn (1)
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(src.name == "alien")
src.name = text("alien ([rand(1, 1000)])")
src.real_name = src.name
spawn (1)
if(!istype(src, /mob/living/carbon/alien/humanoid/queen))
src.stand_icon = new /icon('alien.dmi', "alien_s")
src.lying_icon = new /icon('alien.dmi', "alien_l")
src.icon = src.stand_icon
if(src.name == "alien") src.name = text("alien ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
..()

View File

@@ -1,21 +1,20 @@
/mob/living/carbon/alien/humanoid/queen/New()
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
//there should only be one queen
// if(src.name == "alien")
// src.name = text("alien ([rand(1, 1000)])")
src.real_name = src.name
spawn (1)
src.verbs += /mob/living/carbon/alien/humanoid/proc/corrode_target
src.verbs += /mob/living/carbon/alien/humanoid/sentinel/verb/spit
src.verbs -= /mob/living/carbon/alien/humanoid/verb/ventcrawl
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
src.stand_icon = new /icon('alien.dmi', "queen_s")
src.lying_icon = new /icon('alien.dmi', "queen_l")
src.icon = src.stand_icon
//there should only be one queen
// if(src.name == "alien") src.name = text("alien ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
/mob/living/carbon/alien/humanoid/queen

View File

@@ -1,15 +1,14 @@
//This is fine right now, if we're adding organ specific damage this needs to be updated
/mob/living/carbon/alien/larva/New()
spawn (1)
var/datum/reagents/R = new/datum/reagents(100)
reagents = R
R.my_atom = src
if(src.name == "alien larva") src.name = text("alien larva ([rand(1, 1000)])")
if(src.name == "alien larva")
src.name = text("alien larva ([rand(1, 1000)])")
src.real_name = src.name
src << "\blue Your icons have been generated!"
spawn (1)
update_clothing()
src << "\blue Your icons have been generated!"
// spawn(1200) grow() Grow after 120 seconds -- TLE Commented out because life.dm has better version -- Urist
..()

View File

@@ -2,10 +2,10 @@
var/obj/item/device/mmi/container = null
New()
spawn(1)
var/datum/reagents/R = new/datum/reagents(1000)
reagents = R
R.my_atom = src
..()
say_understands(var/other)
if (istype(other, /mob/living/silicon/ai))

View File

@@ -7,7 +7,6 @@
if (!dna)
dna = new /datum/dna( null )
spawn (1)
var/datum/organ/external/chest/chest = new /datum/organ/external/chest( src )
chest.owner = src
var/datum/organ/external/groin/groin = new /datum/organ/external/groin( src )
@@ -52,17 +51,15 @@
src.gender = MALE
g = "m"
spawn (1)
if(!src.stand_icon)
src.stand_icon = new /icon('human.dmi', "body_[g]_s")
if(!src.lying_icon)
src.lying_icon = new /icon('human.dmi', "body_[g]_l")
src.icon = src.stand_icon
src << "\blue Your icons have been generated!"
update_clothing()
src << "\blue Your icons have been generated!"
..()
/mob/living/carbon/human/Bump(atom/movable/AM as mob|obj, yes)
if ((!( yes ) || src.now_pushing))

View File

@@ -1,5 +1,4 @@
/mob/living/carbon/monkey/New()
spawn(1)
var/datum/reagents/R = new/datum/reagents(1000)
reagents = R
R.my_atom = src
@@ -20,10 +19,9 @@
src.dna.uni_identity += "12C"
src.dna.uni_identity += "4E2"
if(src.name == "monkey") src.name = text("monkey ([rand(1, 1000)])")
if(src.name == "monkey")
src.name = text("monkey ([rand(1, 1000)])")
src.real_name = src.name
return
..()
return

View File

@@ -1123,6 +1123,7 @@
if (item)
item.layer = initial(item.layer)
var/turf/T = get_turf(src.loc)
if (istype(T))
T.Entered(item)
return
@@ -1138,16 +1139,17 @@
if (W)
W.layer = initial(W.layer)
var/turf/T = get_turf(src.loc)
if (T)
if (istype(T))
T.Entered(W)
return
/mob/proc/before_take_item(var/obj/item/item)
u_equip(item)
if (src.client)
src.client.screen -= item
item.loc = null
src.update_clothing()
item.layer = initial(item.layer)
u_equip(item)
//if (src.client)
// src.client.screen -= item
//src.update_clothing()
return
/mob/proc/get_active_hand()
@@ -1299,7 +1301,10 @@
msg = copytext(msg, 1, MAX_MESSAGE_LEN)
msg = sanitize(msg)
if(mind)
mind.store_memory(msg)
else
src << "The game appears to have misplaced your mind datum, so we can't show you your notes."
/mob/proc/store_memory(msg as message, popup, sane = 1)
msg = copytext(msg, 1, MAX_MESSAGE_LEN)

View File

@@ -4,13 +4,7 @@
for(var/obj/item/W in src)
if (W==src.w_uniform) // will be teared
continue
src.u_equip(W)
if (src.client)
src.client.screen -= W
if (W)
W.loc = src.loc
W.dropped(src)
W.layer = initial(W.layer)
drop_from_slot(W)
src.update_clothing()
src.monkeyizing = 1
src.canmove = 0
@@ -58,15 +52,8 @@
/mob/living/carbon/AIize()
if (src.monkeyizing)
return
for(var/obj/item/weapon/W in src)
src.u_equip(W)
if (src.client)
src.client.screen -= W
if (W)
W.loc = src.loc
W.dropped(src)
W.layer = initial(W.layer)
del(W)
for(var/obj/item/W in src)
drop_from_slot(W)
src.update_clothing()
src.monkeyizing = 1
src.canmove = 0
@@ -170,15 +157,8 @@
/mob/living/carbon/human/proc/Robotize()
if (src.monkeyizing)
return
for(var/obj/item/weapon/W in src)
src.u_equip(W)
if (src.client)
src.client.screen -= W
if (W)
W.loc = src.loc
W.dropped(src)
W.layer = initial(W.layer)
del(W)
for(var/obj/item/W in src)
drop_from_slot(W)
src.update_clothing()
src.monkeyizing = 1
src.canmove = 0
@@ -235,14 +215,8 @@
/mob/living/carbon/human/proc/Alienize()
if (src.monkeyizing)
return
for(var/obj/item/weapon/W in src)
src.u_equip(W)
if (src.client)
src.client.screen -= W
if (W)
W.loc = src.loc
W.dropped(src)
W.layer = initial(W.layer)
for(var/obj/item/W in src)
drop_from_slot(W)
src.update_clothing()
src.monkeyizing = 1
src.canmove = 0

View File

@@ -1 +1 @@
extended
traitor