Merge pull request #4038 from Cheridan/ghost_notifications

Notifications + Random Stuff
This commit is contained in:
Alex
2014-07-03 17:29:49 +01:00
18 changed files with 145 additions and 198 deletions
+2
View File
@@ -173,6 +173,8 @@
if(Ninja.mind != Mind) //something has gone wrong!
ERROR("The ninja wasn't assigned the right mind. ;ç;")
Ninja << sound('sound/effects/ninja_greeting.ogg') //so ninja you probably wouldn't even know if you were made one
success_spawn = 1
/*
+2 -2
View File
@@ -919,8 +919,8 @@
/datum/recipe/bloodsoup
reagents = list("blood" = 10)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato,
/obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato,
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blood,
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blood,
)
result = /obj/item/weapon/reagent_containers/food/snacks/bloodsoup
+63 -61
View File
@@ -572,28 +572,35 @@
reagents.add_reagent("moonshine", 1+round((potency / 10), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
//tomaters
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato
seed = "/obj/item/seeds/tomatoseed"
name = "tomato"
desc = "I say to-mah-to, you say tom-mae-to."
icon_state = "tomato"
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato
New(var/loc, var/potency = 10)
..()
if(reagents)
reagents.add_reagent("nutriment", 1+round((potency / 10), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
var/splat = /obj/effect/decal/cleanable/tomato_smudge
throw_impact(atom/hit_atom)
..()
new/obj/effect/decal/cleanable/tomato_smudge(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed.</span>","<span class='moderate'>You hear a smack.</span>")
for(var/atom/A in get_turf(hit_atom))
src.reagents.reaction(A)
del(src) // Not qdel, because it'll hit other mobs then the floor for runtimes.
return
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/New(var/loc, var/potency = 10)
..()
if(reagents)
reagents.add_reagent("nutriment", 1+round((potency / 10), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/killertomato
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/proc/squish(atom/target)
new splat(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed.</span>","<span class='notice'>You hear a smack.</span>")
for(var/atom/A in get_turf(target))
src.reagents.reaction(A)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/throw_impact(atom/hit_atom)
..()
squish(hit_atom)
del(src) // Not qdel, because it'll hit other mobs then the floor for runtimes.
return
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/killer
seed = "/obj/item/seeds/killertomatoseed"
name = "killer-tomato"
desc = "I say to-mah-to, you say tom-mae-to... OH GOD IT'S EATING MY LEGS!!"
@@ -604,7 +611,7 @@
reagents.add_reagent("nutriment", 1+round((potency / 10), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/killertomato/attack_self(mob/user as mob)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/killer/attack_self(mob/user as mob)
if(istype(user.loc,/turf/space))
return
new /mob/living/simple_animal/tomato(user.loc)
@@ -612,12 +619,15 @@
user << "<span class='notice'>You plant the killer-tomato.</span>"
/obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blood
seed = "/obj/item/seeds/bloodtomatoseed"
name = "blood-tomato"
desc = "So bloody...so...very...bloody....AHHHH!!!!"
icon_state = "bloodtomato"
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blood
splat = /obj/effect/decal/cleanable/blood/splatter
New(var/loc, var/potency = 10)
..()
if(reagents)
@@ -625,22 +635,15 @@
reagents.add_reagent("blood", 1+round((potency / 5), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato/throw_impact(atom/hit_atom)
..()
new/obj/effect/decal/cleanable/blood/splatter(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed.</span>","<span class='moderate'>You hear a smack.</span>")
src.reagents.reaction(get_turf(hit_atom))
for(var/atom/A in get_turf(hit_atom))
src.reagents.reaction(A)
del(src) // Not qdel, because it'll hit other mobs then the floor for runtimes.
return
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue
seed = "/obj/item/seeds/bluetomatoseed"
name = "blue-tomato"
desc = "I say blue-mah-to, you say blue-mae-to."
icon_state = "bluetomato"
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue
splat = /obj/effect/decal/cleanable/oil
New(var/loc, var/potency = 10)
..()
if(reagents)
@@ -648,27 +651,40 @@
reagents.add_reagent("lube", 1+round((potency / 5), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/throw_impact(atom/hit_atom)
..()
new/obj/effect/decal/cleanable/oil(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed.</span>","<span class='moderate'>You hear a smack.</span>")
src.reagents.reaction(get_turf(hit_atom))
for(var/atom/A in get_turf(hit_atom))
src.reagents.reaction(A)
del(src) // Not qdel, because it'll hit other mobs then the floor for runtimes.
return
/obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato/Crossed(AM as mob|obj)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/Crossed(AM as mob|obj)
if (istype(AM, /mob/living/carbon))
var/mob/M = AM
if (istype(M, /mob/living/carbon/human) && (isobj(M:shoes) && M:shoes.flags&NOSLIP))
return
var/mob/living/carbon/M = AM
var/stun = Clamp(potency / 10, 1, 10)
var/weaken = Clamp(potency / 20, 0.5, 5)
M.slip(stun, weaken, src)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/bluespace
seed = "/obj/item/seeds/bluespacetomatoseed"
name = "blue-space tomato"
desc = "So lubricated, you might slip through space-time."
icon_state = "bluespacetomato"
origin_tech = "bluespace=3"
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/bluespace
New(var/loc, var/potency = 20)
..()
if(reagents)
reagents.add_reagent("nutriment", 1+round((potency / 20), 1))
reagents.add_reagent("singulo", 1+round((potency / 5), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/bluespace/attack_self(var/mob/user)
squish(user)
user.drop_item()
src.visible_message("<span class='notice'>[user] squashes the [src.name].</span>","<span class='notice'>You hear a smack.</span>")
qdel(src)
/obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/bluespace/squish(atom/squishee)
..()
var/teleport_radius = potency/10
if(isliving(squishee))
new /obj/effect/decal/cleanable/molten_item(squishee.loc) //Leave a pile of goo behind for dramatic effect...
do_teleport(squishee, get_turf(squishee), teleport_radius)
M.stop_pulling()
M << "\blue You slipped on the [name]!"
playsound(src.loc, 'sound/misc/slip.ogg', 50, 1, -3)
M.Stun(8)
M.Weaken(5)
/obj/item/weapon/reagent_containers/food/snacks/grown/wheat
seed = "/obj/item/seeds/wheatseed"
@@ -955,20 +971,6 @@
spawn(5) //Workaround to keep harvesting from working weirdly.
qdel(src)
/obj/item/weapon/reagent_containers/food/snacks/grown/bluespacetomato
seed = "/obj/item/seeds/bluespacetomatoseed"
name = "blue-space tomato"
desc = "So lubricated, you might slip through space-time."
icon_state = "bluespacetomato"
origin_tech = "bluespace=3"
dried_type = /obj/item/weapon/reagent_containers/food/snacks/grown/bluespacetomato
New(var/loc, var/potency = 20)
..()
if(reagents)
reagents.add_reagent("nutriment", 1+round((potency / 20), 1))
reagents.add_reagent("singulo", 1+round((potency / 5), 1))
bitesize = 1+round(reagents.total_volume / 2, 1)
/obj/item/weapon/reagent_containers/food/snacks/grown/gatfruit
seed = "/obj/item/seeds/gatfruit"
name = "gatfruit"
@@ -183,9 +183,18 @@
throwforce = 0
throw_speed = 3
throw_range = 7
/obj/item/weapon/grown/bananapeel/New(var/loc, var/potency = 10)
..()
/obj/item/weapon/grown/bananapeel/Crossed(AM as mob|obj)
if (istype(AM, /mob/living/carbon))
var/mob/living/carbon/M = AM
var/stun = Clamp(potency / 10, 1, 10)
var/weaken = Clamp(potency / 20, 0.5, 5)
M.slip(stun, weaken, src)
/obj/item/weapon/grown/corncob
name = "corn cob"
desc = "A reminder of meals gone by."
+1 -53
View File
@@ -102,56 +102,4 @@
new /obj/item/clothing/mask/cigarette/pipe/cobpipe (user.loc)
usr.unEquip(src)
qdel(src)
return
//Bluespace Tomatoes
/obj/item/weapon/reagent_containers/food/snacks/grown/bluespacetomato/throw_impact(atom/hit_atom)
..()
var/mob/M = usr
var/outer_teleport_radius = potency/10 //Plant potency determines radius of teleport.
var/inner_teleport_radius = potency/15
var/list/turfs = new/list()
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
if(inner_teleport_radius < 1) //Wasn't potent enough, it just splats.
new/obj/effect/decal/cleanable/oil(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed.</span>","<span class='moderate'>You hear a smack.</span>")
usr.unEquip(src)
qdel(src)
return
for(var/turf/T in orange(M,outer_teleport_radius))
if(T in orange(M,inner_teleport_radius)) continue
if(istype(T,/turf/space)) continue
if(T.density) continue
if(T.x>world.maxx-outer_teleport_radius || T.x<outer_teleport_radius) continue
if(T.y>world.maxy-outer_teleport_radius || T.y<outer_teleport_radius) continue
turfs += T
if(!turfs.len)
var/list/turfs_to_pick_from = list()
for(var/turf/T in orange(M,outer_teleport_radius))
if(!(T in orange(M,inner_teleport_radius)))
turfs_to_pick_from += T
turfs += pick(/turf in turfs_to_pick_from)
var/turf/picked = pick(turfs)
if(!isturf(picked)) return
switch(rand(1,2))//Decides randomly to teleport the thrower or the throwee.
if(1) // Teleports the person who threw the tomato.
s.set_up(3, 1, M)
s.start()
new/obj/effect/decal/cleanable/molten_item(M.loc) //Leaves a pile of goo behind for dramatic effect.
M.loc = picked //
sleep(1)
s.set_up(3, 1, M)
s.start() //Two set of sparks, one before the teleport and one after.
if(2) //Teleports mob the tomato hit instead.
for(var/mob/A in get_turf(hit_atom))//For the mobs in the tile that was hit...
s.set_up(3, 1, A)
s.start()
new/obj/effect/decal/cleanable/molten_item(A.loc) //Leave a pile of goo behind for dramatic effect...
A.loc = picked//And teleport them to the chosen location.
sleep(1)
s.set_up(3, 1, A)
s.start()
new/obj/effect/decal/cleanable/oil(src.loc)
src.visible_message("<span class='notice'>The [src.name] has been squashed, causing a distortion in space-time.</span>","<span class='moderate'>You hear a splat and a crackle.</span>")
qdel(src)
return
return
+4 -4
View File
@@ -221,7 +221,7 @@
icon_state = "seed-bloodtomato"
species = "bloodtomato"
plantname = "Blood-Tomato Plants"
product = /obj/item/weapon/reagent_containers/food/snacks/grown/bloodtomato
product = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blood
lifespan = 25
endurance = 20
maturation = 8
@@ -255,7 +255,7 @@
icon_state = "seed-killertomato"
species = "killertomato"
plantname = "Killer-Tomato Plants"
product = /obj/item/weapon/reagent_containers/food/snacks/grown/killertomato
product = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/killer
lifespan = 25
endurance = 15
maturation = 8
@@ -273,7 +273,7 @@
icon_state = "seed-bluetomato"
species = "bluetomato"
plantname = "Blue-Tomato Plants"
product = /obj/item/weapon/reagent_containers/food/snacks/grown/bluetomato
product = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue
lifespan = 25
endurance = 15
maturation = 8
@@ -291,7 +291,7 @@
icon_state = "seed-bluespacetomato"
species = "bluespacetomato"
plantname = "Blue-Space Tomato Plants"
product = /obj/item/weapon/reagent_containers/food/snacks/grown/bluespacetomato
product = /obj/item/weapon/reagent_containers/food/snacks/grown/tomato/blue/bluespace
lifespan = 25
endurance = 15
maturation = 8
@@ -927,14 +927,6 @@ mob/living/carbon/slime/var/temperature_resistance = T0C+75
G << "You are an adamantine golem. You move slowly, but are highly resistant to heat and cold as well as blunt trauma. You are unable to wear clothes, but can still use most tools. Serve [user], and assist them in completing their goals at any cost."
qdel(src)
proc/announce_to_ghosts()
for(var/mob/dead/observer/G in player_list)
if(G.client)
var/area/A = get_area(src)
if(A)
G << "Golem rune created in [A.name]."
/mob/living/carbon/slime/getTrail()
return null
+7
View File
@@ -423,6 +423,13 @@ proc/is_special_character(mob/M) // returns 1 for special characters and 2 for h
/mob/proc/reagent_check(var/datum/reagent/R) // utilized in the species code
return 1
/proc/notify_ghosts(var/message, var/ghost_sound = null) //Easy notification of ghosts.
for(var/mob/dead/observer/O in player_list)
if(O.client)
O << "<span class='ghostalert'>[message]<span>"
if(ghost_sound)
O << sound(ghost_sound)
/proc/item_heal_robotic(var/mob/living/carbon/human/H, var/mob/user, var/brute, var/burn)
var/obj/item/organ/limb/affecting = H.get_organ(check_zone(user.zone_sel.selecting))
@@ -490,6 +490,11 @@
..()
world << "<font size='15' color='red'><b>NAR-SIE HAS RISEN</b></font>"
world << pick(sound('sound/hallucinations/im_here1.ogg'), sound('sound/hallucinations/im_here2.ogg'))
var/area/A = get_area(src)
if(A)
notify_ghosts("Nar-Sie has risen in \the [A.name]. Reach out to the Geometer to be given a new shell for your soul.")
if(emergency_shuttle)
emergency_shuttle.incall(0.3) // Cannot recall
+1 -1
View File
@@ -1419,7 +1419,7 @@ datum/chemical_reaction/pestkiller
feedback_add_details("slime_cores_used","[replacetext(name," ","_")]")
var/obj/effect/golemrune/Z = new /obj/effect/golemrune
Z.loc = get_turf(holder.my_atom)
Z.announce_to_ghosts()
notify_ghosts("Golem rune created in [Z.name]", 'sound/effects/ghost2.ogg')
//Bluespace