git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3990 316c924e-a436-60f5-8080-3fe189b3f50e

This commit is contained in:
johnsonmt88@gmail.com
2012-07-05 21:06:44 +00:00
parent 93e4d2c1ff
commit 3bd93d58a8
4 changed files with 242 additions and 202 deletions

View File

@@ -699,7 +699,10 @@
//G = null //G = null
// search for ghosts, if the corpse is empty and the scanner is connected to a cloner // search for ghosts, if the corpse is empty and the scanner is connected to a cloner
if(locate(/obj/machinery/computer/cloning, get_step(src, EAST))) if(locate(/obj/machinery/computer/cloning, get_step(src, NORTH)) \
|| locate(/obj/machinery/computer/cloning, get_step(src, SOUTH)) \
|| locate(/obj/machinery/computer/cloning, get_step(src, EAST)) \
|| locate(/obj/machinery/computer/cloning, get_step(src, WEST)))
if (!M.client) if (!M.client)
for(var/mob/dead/observer/ghost in world) for(var/mob/dead/observer/ghost in world)

View File

@@ -476,11 +476,11 @@ var/list/sacrificed = list()
T.imbue = "deafen" T.imbue = "deafen"
imbued_from = R imbued_from = R
break break
/*if(R.word1==worddestr && R.word2==wordsee && R.word3==wordother) //blind if(R.word1==worddestr && R.word2==wordsee && R.word3==wordother) //blind
T = new(src.loc) T = new(src.loc)
T.imbue = "blind" T.imbue = "blind"
imbued_from = R imbued_from = R
break*/ break
if(R.word1==wordself && R.word2==wordother && R.word3==wordtech) //communicat if(R.word1==wordself && R.word2==wordother && R.word3==wordtech) //communicat
T = new(src.loc) T = new(src.loc)
T.imbue = "communicate" T.imbue = "communicate"
@@ -863,7 +863,7 @@ var/list/sacrificed = list()
return fizzle() return fizzle()
else else
var/affected = 0 var/affected = 0
for(var/mob/living/carbon/C in viewers(usr)) for(var/mob/living/carbon/C in view(2,usr))
if (iscultist(C)) if (iscultist(C))
continue continue
var/obj/item/weapon/nullrod/N = locate() in C var/obj/item/weapon/nullrod/N = locate() in C
@@ -997,13 +997,20 @@ var/list/sacrificed = list()
usr.whisper("N'ath reth sh'yro eth d'raggathnor!") usr.whisper("N'ath reth sh'yro eth d'raggathnor!")
usr.visible_message("\red Rune disappears with a flash of red light, and a set of armor appears on you..", \ usr.visible_message("\red Rune disappears with a flash of red light, and a set of armor appears on you..", \
"\red You are blinded by the flash of red light! After you're able to see again, you see that you are now wearing a set of armor.") "\red You are blinded by the flash of red light! After you're able to see again, you see that you are now wearing a set of armor.")
user.equip_if_possible(new /obj/item/clothing/shoes/cult(user), user.slot_shoes)
user.equip_if_possible(new /obj/item/clothing/suit/cultrobes/alt(user), user.slot_wear_suit)
user.equip_if_possible(new /obj/item/clothing/head/culthood/alt(user), user.slot_head) user.equip_if_possible(new /obj/item/clothing/head/culthood/alt(user), user.slot_head)
//user.equip_if_possible(new /obj/item/clothing/gloves/black(user), user.slot_gloves) user.equip_if_possible(new /obj/item/clothing/suit/cultrobes/alt(user), user.slot_wear_suit)
//user.equip_if_possible(new /obj/item/clothing/suit/magusred(user), user.slot_wear_suit) user.equip_if_possible(new /obj/item/clothing/shoes/cult(user), user.slot_shoes)
//user.equip_if_possible(new /obj/item/clothing/head/magus(user), user.slot_head)
user.equip_if_possible(new /obj/item/weapon/melee/cultblade(user), user.slot_r_hand)
user.equip_if_possible(new /obj/item/weapon/storage/backpack/cultpack(user), user.slot_back) user.equip_if_possible(new /obj/item/weapon/storage/backpack/cultpack(user), user.slot_back)
if(!user.equip_if_possible(new /obj/item/weapon/melee/cultblade(user), user.slot_r_hand))
user.equip_if_possible(new /obj/item/weapon/melee/cultblade(user), user.slot_l_hand)
user.update_inv_head(0)
user.update_inv_wear_suit(0)
user.update_inv_shoes(0)
user.update_inv_back(0)
user.update_inv_l_hand(0)
user.update_inv_r_hand()
del(src) del(src)
return return

View File

@@ -390,7 +390,7 @@
if(!(user.zone_sel.selecting == ("head")) || !istype(M, /mob/living/carbon/human)) if(!(user.zone_sel.selecting == ("head")) || !istype(M, /mob/living/carbon/human))
return ..() return ..()
if(!(locate(/obj/machinery/optable, M.loc) && M.resting)) if( !(locate(/obj/machinery/optable, M.loc) && M.resting) && ( !(locate(/obj/structure/table/, M.loc) && M.lying) && prob(50) ) )
return ..() return ..()
var/mob/living/carbon/human/H = M var/mob/living/carbon/human/H = M

View File

@@ -30,17 +30,27 @@ obj/structure/meteorhit(obj/O as obj)
var/state = 0 var/state = 0
attackby(obj/item/W as obj, mob/user as mob) attackby(obj/item/W as obj, mob/user as mob)
if(istype(W, /obj/item/weapon/wrench) && state == 0 && anchored && !istype(src,/obj/structure/girder/displaced)) if(istype(W, /obj/item/weapon/wrench) && state == 0)
if(anchored && !istype(src,/obj/structure/girder/displaced))
playsound(src.loc, 'Ratchet.ogg', 100, 1) playsound(src.loc, 'Ratchet.ogg', 100, 1)
user << "\blue Now disassembling the girder" user << "\blue Now disassembling the girder"
if(do_after(user,40)) if(do_after(user,40))
if(!src) return
user << "\blue You dissasembled the girder!" user << "\blue You dissasembled the girder!"
new /obj/item/stack/sheet/metal(get_turf(src)) new /obj/item/stack/sheet/metal(get_turf(src))
del(src) del(src)
else if(!anchored)
playsound(src.loc, 'Ratchet.ogg', 100, 1)
user << "\blue Now securing the girder"
if(get_turf(user, 40))
user << "\blue You secured the girder!"
new/obj/structure/girder( src.loc )
del(src)
else if(istype(W, /obj/item/weapon/pickaxe/plasmacutter)) else if(istype(W, /obj/item/weapon/pickaxe/plasmacutter))
user << "\blue Now slicing apart the girder" user << "\blue Now slicing apart the girder"
if(do_after(user,30)) if(do_after(user,30))
if(!src) return
user << "\blue You slice apart the girder!" user << "\blue You slice apart the girder!"
new /obj/item/stack/sheet/metal(get_turf(src)) new /obj/item/stack/sheet/metal(get_turf(src))
del(src) del(src)
@@ -50,70 +60,11 @@ obj/structure/meteorhit(obj/O as obj)
new /obj/item/stack/sheet/metal(get_turf(src)) new /obj/item/stack/sheet/metal(get_turf(src))
del(src) del(src)
else if(istype(W, /obj/item/stack/sheet) && !anchored)
switch(W.type)
if(/obj/item/stack/sheet/metal)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall (src.loc)
if(/obj/item/stack/sheet/plasteel)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falserwall (src.loc)
if(/obj/item/stack/sheet/gold)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/gold (src.loc)
if(/obj/item/stack/sheet/silver)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/silver (src.loc)
if(/obj/item/stack/sheet/diamond)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/diamond (src.loc)
if(/obj/item/stack/sheet/uranium)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/uranium (src.loc)
if(/obj/item/stack/sheet/plasma)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/plasma (src.loc)
if(/obj/item/stack/sheet/clown)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/clown (src.loc)
if(/obj/item/stack/sheet/sandstone)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/sandstone (src.loc)
/* if(/obj/item/stack/sheet/wood)
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/wood (src.loc)*/
add_hiddenprint(usr)
del(src)
/* else if((istype(W, /obj/item/stack/sheet/metal)) && (W:amount >= 2) && istype(src,/obj/structure/girder/displaced))
W:use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall (src.loc)
add_hiddenprint(usr)
del(src)
else if(istype(W, /obj/item/stack/sheet/plasteel) && istype(src,/obj/structure/girder/displaced))
W:use(2)
user << "\blue You create a false r wall! Push on it to open or close the passage."
new /obj/structure/falserwall (src.loc)
add_hiddenprint(usr)
del(src)*/
else if(istype(W, /obj/item/weapon/screwdriver) && state == 2 && istype(src,/obj/structure/girder/reinforced)) else if(istype(W, /obj/item/weapon/screwdriver) && state == 2 && istype(src,/obj/structure/girder/reinforced))
playsound(src.loc, 'Screwdriver.ogg', 100, 1) playsound(src.loc, 'Screwdriver.ogg', 100, 1)
user << "\blue Now unsecuring support struts" user << "\blue Now unsecuring support struts"
if(do_after(user,40)) if(do_after(user,40))
if(!src) return
user << "\blue You unsecured the support struts!" user << "\blue You unsecured the support struts!"
state = 1 state = 1
@@ -121,6 +72,7 @@ obj/structure/meteorhit(obj/O as obj)
playsound(src.loc, 'Wirecutter.ogg', 100, 1) playsound(src.loc, 'Wirecutter.ogg', 100, 1)
user << "\blue Now removing support struts" user << "\blue Now removing support struts"
if(do_after(user,40)) if(do_after(user,40))
if(!src) return
user << "\blue You removed the support struts!" user << "\blue You removed the support struts!"
new/obj/structure/girder( src.loc ) new/obj/structure/girder( src.loc )
del(src) del(src)
@@ -129,24 +81,28 @@ obj/structure/meteorhit(obj/O as obj)
playsound(src.loc, 'Crowbar.ogg', 100, 1) playsound(src.loc, 'Crowbar.ogg', 100, 1)
user << "\blue Now dislodging the girder" user << "\blue Now dislodging the girder"
if(do_after(user, 40)) if(do_after(user, 40))
if(!src) return
user << "\blue You dislodged the girder!" user << "\blue You dislodged the girder!"
new/obj/structure/girder/displaced( src.loc ) new/obj/structure/girder/displaced( src.loc )
del(src) del(src)
else if(istype(W, /obj/item/weapon/wrench) && state == 0 && !anchored ) else if(istype(W, /obj/item/stack/sheet))
playsound(src.loc, 'Ratchet.ogg', 100, 1)
user << "\blue Now securing the girder"
if(get_turf(user, 40))
user << "\blue You secured the girder!"
new/obj/structure/girder( src.loc )
del(src)
else if((istype(W, /obj/item/stack/sheet)) && (W:amount >= 2)) var/obj/item/stack/sheet/S = W
switch(W.type) switch(S.type)
if(/obj/item/stack/sheet/metal) if(/obj/item/stack/sheet/metal)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithWall() Tsrc.ReplaceWithWall()
@@ -154,14 +110,22 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/X in Tsrc.loc) for(var/turf/simulated/wall/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/plasteel) if(/obj/item/stack/sheet/plasteel)
if (src.icon_state == "reinforced") //Time to finalize! if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falserwall (src.loc)
else
if (src.icon_state == "reinforced") //I cant believe someone would actually write this line of code...
if(S.amount < 1) return ..()
user << "\blue Now finalising reinforced wall." user << "\blue Now finalising reinforced wall."
if(do_after(user, 50)) if(do_after(user, 50))
if(!src || !S || S.amount < 1) return
S.use(1)
user << "\blue Wall fully reinforced!" user << "\blue Wall fully reinforced!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithRWall() Tsrc.ReplaceWithRWall()
@@ -169,22 +133,31 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/r_wall/X in Tsrc.loc) for(var/turf/simulated/wall/r_wall/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W)
W:use(1)
del(src) del(src)
return return
else else
if(S.amount < 1) return ..()
user << "\blue Now reinforcing girders" user << "\blue Now reinforcing girders"
if (do_after(user,60)) if (do_after(user,60))
if(!src || !S || S.amount < 1) return
S.use(1)
user << "\blue Girders reinforced!" user << "\blue Girders reinforced!"
W:use(1)
new/obj/structure/girder/reinforced( src.loc ) new/obj/structure/girder/reinforced( src.loc )
del(src) del(src)
return return
if(/obj/item/stack/sheet/gold) if(/obj/item/stack/sheet/gold)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/gold (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("gold") Tsrc.ReplaceWithMineralWall("gold")
@@ -192,13 +165,21 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/silver) if(/obj/item/stack/sheet/silver)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/silver (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("silver") Tsrc.ReplaceWithMineralWall("silver")
@@ -206,13 +187,21 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/diamond) if(/obj/item/stack/sheet/diamond)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/diamond (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("diamond") Tsrc.ReplaceWithMineralWall("diamond")
@@ -220,13 +209,21 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/uranium) if(/obj/item/stack/sheet/uranium)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/uranium (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("uranium") Tsrc.ReplaceWithMineralWall("uranium")
@@ -234,13 +231,21 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/plasma) if(/obj/item/stack/sheet/plasma)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/plasma (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("plasma") Tsrc.ReplaceWithMineralWall("plasma")
@@ -248,13 +253,20 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/clown) if(/obj/item/stack/sheet/clown)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/clown (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("clown") Tsrc.ReplaceWithMineralWall("clown")
@@ -262,13 +274,21 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
if(/obj/item/stack/sheet/sandstone) if(/obj/item/stack/sheet/sandstone)
if(!anchored)
if(S.amount < 2) return
S.use(2)
user << "\blue You create a false wall! Push on it to open or close the passage."
new /obj/structure/falsewall/sandstone (src.loc)
else
if(S.amount < 2) return ..()
user << "\blue Now adding plating..." user << "\blue Now adding plating..."
if (do_after(user,40)) if (do_after(user,40))
if(!src || !S || S.amount < 2) return
S.use(2)
user << "\blue You added the plating!" user << "\blue You added the plating!"
var/turf/Tsrc = get_turf(src) var/turf/Tsrc = get_turf(src)
Tsrc.ReplaceWithMineralWall("sandstone") Tsrc.ReplaceWithMineralWall("sandstone")
@@ -276,10 +296,12 @@ obj/structure/meteorhit(obj/O as obj)
P.layer = 1 P.layer = 1
for(var/turf/simulated/wall/mineral/X in Tsrc.loc) for(var/turf/simulated/wall/mineral/X in Tsrc.loc)
if(X) X.add_hiddenprint(usr) if(X) X.add_hiddenprint(usr)
if (W) W:use(2)
del(src) del(src)
return return
add_hiddenprint(usr)
del(src)
else if(istype(W, /obj/item/pipe)) else if(istype(W, /obj/item/pipe))
var/obj/item/pipe/P = W var/obj/item/pipe/P = W
if (P.pipe_type in list(0, 1, 5)) //simple pipes, simple bends, and simple manifolds. if (P.pipe_type in list(0, 1, 5)) //simple pipes, simple bends, and simple manifolds.
@@ -467,6 +489,14 @@ obj/structure/meteorhit(obj/O as obj)
radiate() radiate()
..() ..()
/obj/structure/falsewall/update_icon()//Calling icon_update will refresh the smoothwalls if it's closed, otherwise it will make sure the icon is correct if it's open
..()
if(density)
icon_state = "[mineral]0"
src.relativewall()
else
icon_state = "[mineral]fwall_open"
/obj/structure/falsewall/attackby(obj/item/weapon/W as obj, mob/user as mob) /obj/structure/falsewall/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(istype(W, /obj/item/weapon/screwdriver)) if(istype(W, /obj/item/weapon/screwdriver))
var/turf/T = get_turf(src) var/turf/T = get_turf(src)