This commit is contained in:
Markolie
2015-07-28 18:40:44 +02:00
101 changed files with 3932 additions and 3230 deletions
+14
View File
@@ -493,6 +493,20 @@
dat += "in [flag_loc.loc] at ([flag_loc.x], [flag_loc.y], [flag_loc.z])</td></tr>"
dat += "</table>"
if(istype(ticker.mode, /datum/game_mode/blob))
var/datum/game_mode/blob/mode = ticker.mode
dat += "<br><table cellspacing=5><tr><td><B>Blob</B></td><td></td><td></td></tr>"
dat += "<tr><td><i>Progress: [blobs.len]/[mode.blobwincount]</i></td></tr>"
for(var/datum/mind/blob in mode.infected_crew)
var/mob/M = blob.current
if(M)
dat += "<tr><td><a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(ghost)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
else
dat += "<tr><td><i>Blob not found!</i></td></tr>"
dat += "</table>"
if(ticker.mode.changelings.len)
dat += check_role_table("Changelings", ticker.mode.changelings, src)
+26
View File
@@ -1646,6 +1646,32 @@
log_admin("[src.owner] replied to [key_name(H)]'s HONKplanet message with the message [input].")
H << "You hear something crackle in your headset for a moment before a voice speaks. \"Please stand by for a message from your HONKbrothers. Message as follows, HONK. [input]. Message ends, HONK.\""
else if(href_list["ErtReply"])
if(!check_rights(R_ADMIN))
return
if(alert(src.owner, "Accept or Deny ERT request?", "CentComm Response", "Accept", "Deny") == "Deny")
var/mob/living/carbon/human/H = locate(href_list["ErtReply"])
if(!istype(H))
usr << "This can only be used on instances of type /mob/living/carbon/human"
return
if(H.stat != 0)
usr << "The person you are trying to contact is not conscious."
return
if(!istype(H.l_ear, /obj/item/device/radio/headset) && !istype(H.r_ear, /obj/item/device/radio/headset))
usr << "The person you are trying to contact is not wearing a headset"
return
var/input = input(src.owner, "Please enter a reason for denying [key_name(H)]'s ERT request.","Outgoing message from CentComm", "")
if(!input) return
src.owner << "You sent [input] to [H] via a secure channel."
log_admin("[src.owner] denied [key_name(H)]'s ERT request with the message [input].")
H << "You hear something crackle in your headset for a moment before a voice speaks. \"Your ERT request has been denied for the following reasons: [input]. Message ends.\""
else
src.owner.response_team()
else if(href_list["AdminFaxView"])
if(!check_rights(R_ADMIN))
return
+8
View File
@@ -44,6 +44,14 @@
var/msg = sanitize(copytext(text, 1, MAX_MESSAGE_LEN))
msg = "\blue <b><font color=pink>HONK:</font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) ([admin_jump_link(Sender, "holder")]) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<A HREF='?_src_=holder;BlueSpaceArtillery=\ref[Sender]'>BSA</A>) (<A HREF='?_src_=holder;HONKReply=\ref[Sender]'>RPLY</A>):</b> [msg]"
for(var/client/X in admins)
if(R_EVENT & X.holder.rights)
X << msg
/proc/ERT_Announce(var/text , var/mob/Sender)
var/msg = sanitize(copytext(text, 1, MAX_MESSAGE_LEN))
msg = "\blue <b><font color=orange>ERT REQUEST:</font>[key_name(Sender, 1)] (<A HREF='?_src_=holder;adminplayeropts=\ref[Sender]'>PP</A>) (<A HREF='?_src_=vars;Vars=\ref[Sender]'>VV</A>) (<A HREF='?_src_=holder;subtlemessage=\ref[Sender]'>SM</A>) ([admin_jump_link(Sender, "holder")]) (<A HREF='?_src_=holder;secretsadmin=check_antagonist'>CA</A>) (<A HREF='?_src_=holder;BlueSpaceArtillery=\ref[Sender]'>BSA</A>) (<A HREF='?_src_=holder;ErtReply=\ref[Sender]'>REPLY</A>):</b> [msg]"
for(var/client/X in admins)
if(R_EVENT & X.holder.rights)
X << msg
+1
View File
@@ -148,6 +148,7 @@ obj/item/clothing/head/blob
/obj/item/clothing/head/helmet/ert/command
name = "emergency response team commander helmet"
desc = "An in-atmosphere helmet worn by the commander of a NanoTrasen Emergency Response Team. Has blue highlights."
icon_state = "erthelmet_cmd"
//Security
/obj/item/clothing/head/helmet/ert/security
+6
View File
@@ -6,7 +6,13 @@
var/time = 30 //time in deciseconds
var/parts[] = list() //type paths of items that will be placed in the result
var/chem_catalists[] = list() //like tools but for reagents
var/fruit[] = list() //grown products required by the recipe
/datum/table_recipe/proc/AdjustChems(var/obj/resultobj as obj)
//This proc is to replace the make_food proc of recipes from microwaves and such that are being converted to table crafting recipes.
//Use it to handle the removal of reagents after the food has been created (like removing toxins from a salad made with ambrosia)
//If a recipe does not require it's chems adjusted, don't bother declaring this for the recipe, as it will call this placeholder
return
/datum/table_recipe/IED
name = "IED"
+25
View File
@@ -11,6 +11,13 @@
/obj/structure/table/proc/check_contents(datum/table_recipe/R)
check_table()
main_loop:
if(R.fruit)
for(var/A in R.fruit)
for(var/B in table_contents)
if(B == A)
if(table_contents[B] >= R.fruit[A])
continue main_loop
return 0
for(var/A in R.reqs)
for(var/B in table_contents)
if(ispath(B, A))
@@ -28,6 +35,10 @@
if(istype(I, /obj/item/stack))
var/obj/item/stack/S = I
table_contents[I.type] += S.amount
else if(istype(I, /obj/item/weapon/reagent_containers/food/snacks/grown))
var/obj/item/weapon/reagent_containers/food/snacks/grown/G = I
if(G.seed && G.seed.kitchen_tag)
table_contents[G.seed.kitchen_tag] += 1
else
if(istype(I, /obj/item/weapon/reagent_containers))
var/obj/item/weapon/reagent_containers/RC = I
@@ -75,6 +86,7 @@
I.reagents = new /datum/reagents()
I.reagents.reagent_list.Add(A)
I.CheckParts()
R.AdjustChems(I)
return 1
return 0
@@ -84,6 +96,19 @@
var/reagenttransfer = 0
if(istype(resultobject,/obj/item/weapon/reagent_containers))
reagenttransfer = 1
if(R.fruit)
for(var/A in R.fruit)
amt = R.fruit[A]
fruit_loop: //ha
for(var/obj/item/weapon/reagent_containers/food/snacks/grown/G in loc)
if(G.seed && G.seed.kitchen_tag && (G.seed.kitchen_tag == A))
amt--
G.loc = null //remove it from the table loc so that we don't locate the same fruit every time
if(reagenttransfer)
G.reagents.trans_to(resultobject, G.reagents.total_volume)
qdel(G)
if(amt <= 0)
break fruit_loop
for(var/A in R.reqs)
amt = R.reqs[A]
if(ispath(A, /obj/item/stack))
+4 -4
View File
@@ -67,16 +67,16 @@ var/setup_economy = 0
/proc/setup_economy()
if(setup_economy)
return
var/datum/feed_channel/newChannel = new /datum/feed_channel
newChannel.channel_name = "Public Station Announcements"
newChannel.author = "Automated Announcement Listing"
newChannel.locked = 1
newChannel.is_admin_channel = 1
news_network.network_channels += newChannel
news_network.network_channels += newChannel
newChannel = new /datum/feed_channel
newChannel.channel_name = "Tau Ceti Daily"
newChannel.channel_name = "Nyx Daily"
newChannel.author = "CentComm Minister of Information"
newChannel.locked = 1
newChannel.is_admin_channel = 1
+3 -3
View File
@@ -57,7 +57,7 @@
/datum/event/economic_event/announce()
//copy-pasted from the admin verbs to submit new newscaster messages
var/datum/feed_message/newMsg = new /datum/feed_message
newMsg.author = "Tau Ceti Daily"
newMsg.author = "Nyx Daily"
newMsg.is_admin_message = 1
//see if our location has custom event info for this event
@@ -95,11 +95,11 @@
newMsg.body = "A [pick("festival","week long celebration","day of revelry","planet-wide holiday")] has been declared on [affected_dest.name] by [pick("Governor","Commissioner","General","Commandant","Administrator")] [random_name(pick(MALE,FEMALE))] to celebrate [pick("the birth of their [pick("son","daughter")]","coming of age of their [pick("son","daughter")]","the pacification of rogue military cell","the apprehension of a violent criminal who had been terrorising the planet")]. Massive stocks of food and meat have been bought driving up prices across the planet."
for(var/datum/feed_channel/FC in news_network.network_channels)
if(FC.channel_name == "Tau Ceti Daily")
if(FC.channel_name == "Nyx Daily")
FC.messages += newMsg
break
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
NEWSCASTER.newsAlert("Tau Ceti Daily")
NEWSCASTER.newsAlert("Nyx Daily")
/datum/event/economic_event/end()
for(var/good_type in dearer_goods)
+11 -15
View File
@@ -13,15 +13,14 @@
//copy-pasted from the admin verbs to submit new newscaster messages
var/datum/feed_message/newMsg = new /datum/feed_message
newMsg.author = "Tau Ceti Daily"
newMsg.author = "Nyx Daily"
newMsg.is_admin_message = 1
//see if our location has custom event info for this event
newMsg.body = affected_dest.get_custom_eventstring()
if(!newMsg.body)
newMsg.body = "[affected_dest.name] doesn't have custom events. Bug a coder."
// Too many goddamn strings, Bay. - N3X
/*
newMsg.body = ""
switch(event_type)
if(RESEARCH_BREAKTHROUGH)
newMsg.body = "A major breakthough in the field of [pick("plasma research","super-compressed materials","nano-augmentation","bluespace research","volatile power manipulation")] \
@@ -96,7 +95,7 @@
if(prob(33))
newMsg.body += "were surprised when an unusual species experts have since identified as \
[pick("a subclass of mammal","a divergent abhuman species","an intelligent species of lemur","organic/cyborg hybrids")] turned up. Believed to have been brought in by \
[pick("alien smugglers","early colonists","syndicate raiders","unwitting tourists")], this is the first such specimen discovered in the wild."
[pick("alien smugglers","early colonists","Syndicate raiders","unwitting tourists")], this is the first such specimen discovered in the wild."
else if(prob(50))
newMsg.body += "were attacked by a vicious [pick("nas'r","diyaab","samak","predator which has not yet been identified")]\
. Officials urge caution, and locals are advised to stock up on armaments."
@@ -118,24 +117,21 @@
newMsg.body += "announced their [pick("split","break up","marriage","engagement")] with [pick("TV host","webcast personality","superstar","model","actor","singer")] \
[random_name(pick(MALE,FEMALE))] at [pick("a society ball","a new opening","a launch","a club")] on [affected_dest.name] yesterday, pundits are shocked."
else
// AUTOFIXED BY fix_string_idiocy.py
// C:\Users\Rob\Documents\Projects\vgstation13\code\WorkInProgress\Cael_Aislinn\Economy\Economy_Events_Mundane.dm:119: newMsg.body += "is recovering from plastic surgery in a clinic on [affected_dest.name] for the [pick("second","third","fourth")] time, reportedly having made the decision in response to "
newMsg.body += {"is recovering from plastic surgery in a clinic on [affected_dest.name] for the [pick("second","third","fourth")] time, reportedly having made the decision in response to
[pick("unkind comments by an ex","rumours started by jealous friends","the decision to be dropped by a major sponsor","a disasterous interview on Tau Ceti Tonight")]."}
// END AUTOFIX
newMsg.body += "is recovering from plastic surgery in a clinic on [affected_dest.name] for the [pick("second","third","fourth")] time, reportedly having made the decision in response to "
newMsg.body += "[pick("unkind comments by an ex","rumours started by jealous friends",\
"the decision to be dropped by a major sponsor","a disasterous interview on Nyx Tonight")]."
if(TOURISM)
newMsg.body += "Tourists are flocking to [affected_dest.name] after the surprise announcement of [pick("major shopping bargains by a wily retailer",\
"a huge new ARG by a popular entertainment company","a secret tour by popular artiste [random_name(pick(MALE,FEMALE))]")]. \
Tau Ceti Daily is offering discount tickets for two to see [random_name(pick(MALE,FEMALE))] live in return for eyewitness reports and up to the minute coverage."
*/
Nyx Daily is offering discount tickets for two to see [random_name(pick(MALE,FEMALE))] live in return for eyewitness reports and up to the minute coverage."
for(var/datum/feed_channel/FC in news_network.network_channels)
if(FC.channel_name == "Tau Ceti Daily")
if(FC.channel_name == "Nyx Daily")
FC.messages += newMsg
break
for(var/obj/machinery/newscaster/NEWSCASTER in allCasters)
NEWSCASTER.newsAlert("Tau Ceti Daily")
NEWSCASTER.newsAlert("Nyx Daily")
/datum/event/trivial_news
endWhen = 10
+8 -57
View File
@@ -1,73 +1,24 @@
/datum/event/blob
announceWhen = 120
noAutoEnd = 1
var/nuke_announced = 0
announceWhen = 12
endWhen = 120
var/obj/effect/blob/core/Blob
/datum/event/blob/announce()
command_announcement.Announce("Confirmed outbreak of level 7 biohazard aboard [station_name()]. Nanotrasen has issued a directive 7-10. The station is to be considered quarantined.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg')
command_announcement.Announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/AI/outbreak5.ogg')
for (var/mob/living/silicon/ai/aiPlayer in player_list)
if (aiPlayer.client)
var/law = "The station is under quarantine, prevent biological entities from leaving the station at all costs while minimizing collateral damage."
aiPlayer.set_zeroth_law(law)
aiPlayer << "\red <b>You have detected a change in your laws information:</b>"
aiPlayer << "Laws Updated: [law]"
/datum/event/blob/start()
var/turf/T = pick(blobstart)
if(!T)
kill()
return
return kill()
Blob = new /obj/effect/blob/core(T, 200)
for(var/i = 1; i < rand(3, 6), i++)
Blob.process()
/datum/event/blob/tick()
if(Blob && IsMultiple(activeFor, 3))
Blob.process()
if(blobs.len > 700*0.6 && !nuke_announced)
announce_nuke()
nuke_announced = 1
if(!Blob && !blob_cores.len)
if(!Blob)
kill()
return
/datum/event/blob/proc/announce_nuke()
var/nukecode = "ERROR"
for(var/obj/machinery/nuclearbomb/bomb in world)
if(bomb && bomb.r_code && (bomb.z in config.station_levels))
nukecode = bomb.r_code
command_announcement.Announce("The biohazard has grown out of control and will soon reach critical mass. Activate the nuclear failsafe to maintain quarantine. The Nuclear Authentication Code is [nukecode] ", "Biohazard Alert")
set_security_level("gamma")
var/obj/machinery/door/airlock/vault/V = locate(/obj/machinery/door/airlock/vault) in world
if(V && (V.z in config.station_levels))
V.locked = 0
V.update_icon()
for (var/mob/living/silicon/ai/aiPlayer in player_list)
if (aiPlayer.client)
var/law = "The station is under quarantine, prevent biological entities from leaving the station at all costs. The nuclear failsafe must be activated at any cost, the code is: [nukecode]."
aiPlayer.set_zeroth_law(law)
aiPlayer << "\red <b>You have detected a change in your laws information:</b>"
aiPlayer << "Laws Updated: [law]"
spawn(10)
world << sound('sound/effects/siren.ogg')
/datum/event/blob/kill()
spawn(10)
if(Blob || blob_cores.len)
return
command_announcement.Announce("The level 7 biohazard aboard [station_name()] has been eliminated. Directive 7-10 has been lifted, and the station is no longer quarantined.", "Biohazard Update")
for (var/mob/living/silicon/ai/aiPlayer in player_list)
if (aiPlayer.client)
aiPlayer.clear_zeroth_law()
aiPlayer << "\red <b>You have detected a change in your laws information:</b>"
aiPlayer << "Laws Updated: Zeroth law removed."
..()
if(IsMultiple(activeFor, 3))
Blob.process()
+3 -3
View File
@@ -127,9 +127,9 @@ var/global/list/severity_to_string = list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "PDA Spam", /datum/event/pda_spam, 0, list(ASSIGNMENT_ANY = 4), 0, 25, 50),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Money Lotto", /datum/event/money_lotto, 0, list(ASSIGNMENT_ANY = 1), 1, 5, 15),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Money Hacker", /datum/event/money_hacker, 0, list(ASSIGNMENT_ANY = 4), 1, 10, 25),
// new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Economic News", /datum/event/economic_event, 300),
// new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Trivial News", /datum/event/trivial_news, 400),
// new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Mundane News", /datum/event/mundane_news, 300),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Economic News", /datum/event/economic_event, 300),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Trivial News", /datum/event/trivial_news, 400),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Mundane News", /datum/event/mundane_news, 300),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Lost Carp", /datum/event/carp_migration, 20, list(ASSIGNMENT_SECURITY = 10), 1),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Vermin Infestation",/datum/event/infestation, 100, list(ASSIGNMENT_JANITOR = 100)),
new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Wallrot", /datum/event/wallrot, 0, list(ASSIGNMENT_ENGINEER = 30, ASSIGNMENT_GARDENER = 50)),
+3 -3
View File
@@ -46,10 +46,10 @@ var/global/list/possibleEvents = list()
// Code/WorkInProgress/Cael_Aislinn/Economy/Economy_Events_Mundane.dm
possibleEvents[/datum/event/economic_event] = 300
//possibleEvents[/datum/event/trivial_news] = 400
//possibleEvents[/datum/event/mundane_news] = 300
possibleEvents[/datum/event/trivial_news] = 400
possibleEvents[/datum/event/mundane_news] = 300
possibleEvents[/datum/event/cargo_bonus] = 150
possibleEvents[/datum/event/cargo_bonus] = 100
possibleEvents[/datum/event/revenant] = 75
possibleEvents[/datum/event/pda_spam] = max(min(25, player_list.len) * 4, 200)
+1 -78
View File
@@ -327,19 +327,11 @@
)
result = /obj/item/weapon/reagent_containers/food/snacks/fishandchips
/datum/recipe/microwave/sandwich
items = list(
/obj/item/weapon/reagent_containers/food/snacks/meatsteak,
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/weapon/reagent_containers/food/snacks/cheesewedge,
)
result = /obj/item/weapon/reagent_containers/food/snacks/sandwich
/datum/recipe/microwave/toastedsandwich
items = list(
/obj/item/weapon/reagent_containers/food/snacks/sandwich
)
result = /obj/item/weapon/reagent_containers/food/snacks/toastedsandwich
/datum/recipe/microwave/tomatosoup
reagents = list("water" = 10)
@@ -453,20 +445,6 @@
fruit = list("apple" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/candiedapple
/datum/recipe/microwave/slimeburger
reagents = list("slimejelly" = 5)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/bun
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellyburger/slime
/datum/recipe/microwave/jellyburger
reagents = list("cherryjelly" = 5)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/bun
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellyburger/cherry
/datum/recipe/microwave/twobread
reagents = list("wine" = 5)
items = list(
@@ -475,22 +453,6 @@
)
result = /obj/item/weapon/reagent_containers/food/snacks/twobread
/datum/recipe/microwave/slimesandwich
reagents = list("slimejelly" = 5)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/slime
/datum/recipe/microwave/cherrysandwich
reagents = list("cherryjelly" = 5)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/cherry
/datum/recipe/microwave/bloodsoup
reagents = list("blood" = 10)
fruit = list("bloodtomato" = 2)
@@ -556,39 +518,8 @@
fruit = list("whitebeet" = 1, "cabbage" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/beetsoup
/datum/recipe/microwave/herbsalad
fruit = list("ambrosia" = 3, "apple" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/herbsalad
make_food(var/obj/container as obj)
var/obj/item/weapon/reagent_containers/food/snacks/herbsalad/being_cooked = ..(container)
being_cooked.reagents.del_reagent("toxin")
return being_cooked
/datum/recipe/microwave/aesirsalad
fruit = list("ambrosiadeus" = 3, "goldapple" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/aesirsalad
/datum/recipe/microwave/validsalad
fruit = list("ambrosia" = 3, "potato" = 1)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/meatball,
)
result = /obj/item/weapon/reagent_containers/food/snacks/validsalad
make_food(var/obj/container as obj)
var/obj/item/weapon/reagent_containers/food/snacks/validsalad/being_cooked = ..(container)
being_cooked.reagents.del_reagent("toxin")
return being_cooked
////////////////////////////FOOD ADDITTIONS///////////////////////////////
/datum/recipe/microwave/wrap
reagents = list("soysauce" = 10)
fruit = list("cabbage" = 1)
items = list(
/obj/item/weapon/reagent_containers/food/snacks/friedegg,
)
result = /obj/item/weapon/reagent_containers/food/snacks/wrap
/datum/recipe/microwave/beans
reagents = list("ketchup" = 5)
fruit = list("soybeans" = 2)
@@ -618,14 +549,6 @@
)
result = /obj/item/weapon/reagent_containers/food/snacks/icecreamsandwich
/datum/recipe/microwave/notasandwich
items = list(
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/weapon/reagent_containers/food/snacks/breadslice,
/obj/item/clothing/mask/fakemoustache,
)
result = /obj/item/weapon/reagent_containers/food/snacks/notasandwich
/datum/recipe/microwave/friedbanana
reagents = list("sugar" = 10, "cornoil" = 5)
fruit = list("banana" = 1)
+96
View File
@@ -0,0 +1,96 @@
/* Example for reference when defining recipes
/datum/table_recipe/food
name = "" //in-game display name
reqs[] = list() //type paths of items/reagents consumed associated with how many are needed (equivalent to var/list/items and var/list/reagents combined)
result //type path of item resulting from this craft
tools[] = list() //type paths of items needed but not consumed
time = 30 //time in deciseconds
parts[] = list() //type paths of items that will be placed in the result
fruit[] = list() //grown products required by the recipe
*/
/datum/table_recipe/sandwich
name = "Sandwich"
reqs = list(
/obj/item/weapon/reagent_containers/food/snacks/meatsteak = 1,
/obj/item/weapon/reagent_containers/food/snacks/breadslice = 2,
/obj/item/weapon/reagent_containers/food/snacks/cheesewedge = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/sandwich
/datum/table_recipe/slimesandwich
name = "Slime Jelly Sandwich"
reqs = list(
/datum/reagent/slimejelly = 5,
/obj/item/weapon/reagent_containers/food/snacks/breadslice = 2,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/slime
/datum/table_recipe/cherrysandwich
name = "Cherry Jelly Sandwich"
reqs = list(
/datum/reagent/cherryjelly = 5,
/obj/item/weapon/reagent_containers/food/snacks/breadslice = 2,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/cherry
/datum/table_recipe/slimeburger
name = "Slime Jelly Burger"
reqs = list(
/datum/reagent/slimejelly = 5,
/obj/item/weapon/reagent_containers/food/snacks/bun = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellyburger/slime
/datum/table_recipe/jellyburger
name = "Cherry Jelly Burger"
reqs = list(
/datum/reagent/cherryjelly = 5,
/obj/item/weapon/reagent_containers/food/snacks/bun = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/jellyburger/cherry
/datum/table_recipe/herbsalad
name = "herb salad"
fruit = list("ambrosia" = 3, "apple" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/herbsalad
/datum/table_recipe/herbsalad/AdjustChems(var/obj/resultobj as obj)
if(istype(resultobj, /obj/item/weapon/reagent_containers))
var/obj/item/weapon/reagent_containers/RC = resultobj
RC.reagents.del_reagent("toxin")
/datum/table_recipe/aesirsalad
name = "Aesir salad"
fruit = list("ambrosiadeus" = 3, "goldapple" = 1)
result = /obj/item/weapon/reagent_containers/food/snacks/aesirsalad
/datum/table_recipe/validsalad
name = "valid salad"
fruit = list("ambrosia" = 3, "potato" = 1)
reqs = list(
/obj/item/weapon/reagent_containers/food/snacks/meatball = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/validsalad
/datum/table_recipe/validsalad/AdjustChems(var/obj/resultobj as obj)
if(istype(resultobj, /obj/item/weapon/reagent_containers))
var/obj/item/weapon/reagent_containers/RC = resultobj
RC.reagents.del_reagent("toxin")
/datum/table_recipe/notasandwich
name = "not-a-sandwich"
reqs = list(
/obj/item/weapon/reagent_containers/food/snacks/breadslice = 2,
/obj/item/clothing/mask/fakemoustache = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/notasandwich
/datum/table_recipe/wrap
name = "egg wrap"
fruit = list("cabbage" = 1)
reqs = list(
/datum/reagent/soysauce = 10,
/obj/item/weapon/reagent_containers/food/snacks/friedegg = 1,
)
result = /obj/item/weapon/reagent_containers/food/snacks/wrap
+111 -42
View File
@@ -11,13 +11,16 @@
var/lum_g
var/lum_b
var/list/effect_r
var/list/effect_g
var/list/effect_b
var/tmp/old_lum_r
var/tmp/old_lum_g
var/tmp/old_lum_b
var/list/effect_str
var/list/effect_turf
var/applied
var/vis_update //Whetever we should smartly recalculate visibility. and then only update tiles that became (in) visible to us
var/needs_update
var/destroyed
var/force_update
@@ -38,9 +41,7 @@
parse_light_color()
effect_r = list()
effect_g = list()
effect_b = list()
effect_str = list()
effect_turf = list()
update()
@@ -71,6 +72,13 @@
needs_update = 1
lighting_update_lights += src
/datum/light_source/proc/vis_update()
if(!needs_update)
needs_update = 1
lighting_update_lights += src
vis_update = 1
/datum/light_source/proc/check()
if(!source_atom || !light_range || !light_power)
destroy()
@@ -96,14 +104,19 @@
light_range = source_atom.light_range
. = 1
if(light_range && light_power && !applied)
. = 1
if(. || source_atom.light_color != light_color)//Save the old lumcounts if we need to update, if the colour changed DO IT BEFORE we parse the colour and LOSE the old lumcounts!
old_lum_r = lum_r
old_lum_g = lum_g
old_lum_b = lum_b
if(source_atom.light_color != light_color)
light_color = source_atom.light_color
parse_light_color()
. = 1
if(light_range && light_power && !applied)
. = 1
/datum/light_source/proc/parse_light_color()
if(light_color)
lum_r = GetRedPart(light_color) / 255
@@ -114,49 +127,50 @@
lum_g = 1
lum_b = 1
/datum/light_source/proc/falloff(atom/movable/lighting_overlay/O)
#if LIGHTING_FALLOFF == 1 // circular
. = (O.x - source_turf.x)**2 + (O.y - source_turf.y)**2 + LIGHTING_HEIGHT
#if LIGHTING_LAMBERTIAN == 1
. = CLAMP01((1 - CLAMP01(sqrt(.) / max(1,light_range))) * (1 / (sqrt(. + 1))))
#else
. = 1 - CLAMP01(sqrt(.) / max(1,light_range))
#endif
#elif LIGHTING_FALLOFF == 2 // square
. = abs(O.x - source_turf.x) + abs(O.y - source_turf.y) + LIGHTING_HEIGHT
#if LIGHTING_LAMBERTIAN == 1
. = CLAMP01((1 - CLAMP01(. / max(1,light_range))) * (1 / (sqrt(.)**2 + )))
#else
. = 1 - CLAMP01(. / max(1,light_range))
#endif
#if LIGHTING_FALLOFF == 1 //circular
#define LUM_DISTANCE(swapvar, O, T) swapvar = (O.x - T.x)**2 + (O.y - T.y)**2 + LIGHTING_HEIGHT
#if LIGHTING_LAMBERTIAN == 1
#define LUM_ATTENUATION(swapvar) swapvar = CLAMP01((1 - CLAMP01(sqrt(swapvar) / light_range)) * (1 / sqrt(swapvar + 1)))
#else
#define LUM_ATTENUATION(swapvar) swapvar = 1 - CLAMP01(sqrt(swapvar) / light_range)
#endif
#elif LIGHTING_FALLOFF == 2 //square
#define LUM_DISTANCE(swapvar, O, T) swapvar = abs(O.x - T.x) + abs(O.y - T.y) + LIGHTING_HEIGHT
#if LIGHTING_LAMBERTIAN == 1
#define LUM_ATTENUATION(swapvar) swapvar = CLAMP01((1 - CLAMP01(swapvar / light_range)) * (1 / sqrt(swapvar**2 + 1)))
#else
#define LUM_ATTENUATION(swapvar) swapvar = CLAMP01(swapvar / light_range)
#endif
#endif
#define LUM_FALLOFF(swapvar, O, T) \
LUM_DISTANCE(swapvar, O, T); \
LUM_ATTENUATION(swapvar);
/datum/light_source/proc/apply_lum()
applied = 1
if(istype(source_turf))
for(var/turf/T in dview(light_range, source_turf, INVISIBILITY_LIGHTING))
FOR_DVIEW(var/turf/T, light_range, source_turf, INVISIBILITY_LIGHTING)
if(T.lighting_overlay)
var/strength = light_power * falloff(T.lighting_overlay)
var/strength
LUM_FALLOFF(strength, T, source_turf)
strength *= light_power
if(!strength) //Don't add turfs that aren't affected to the affected turfs.
continue
effect_r += round(lum_r * strength, LIGHTING_ROUND_VALUE)
effect_g += round(lum_g * strength, LIGHTING_ROUND_VALUE)
effect_b += round(lum_b * strength, LIGHTING_ROUND_VALUE)
strength = round(strength, LIGHTING_ROUND_VALUE) //Screw sinking points.
effect_str += strength
T.lighting_overlay.update_lumcount(
round(lum_r * strength, LIGHTING_ROUND_VALUE),
round(lum_g * strength, LIGHTING_ROUND_VALUE),
round(lum_b * strength, LIGHTING_ROUND_VALUE)
lum_r * strength,
lum_g * strength,
lum_b * strength
)
else
effect_r += 0
effect_g += 0
effect_b += 0
effect_str += 0
if(!T.affecting_lights)
T.affecting_lights = list()
@@ -172,11 +186,66 @@
T.affecting_lights -= src
if(T.lighting_overlay)
T.lighting_overlay.update_lumcount(-effect_r[i], -effect_g[i], -effect_b[i])
var/str = effect_str[i]
T.lighting_overlay.update_lumcount(-str * old_lum_r, -str * old_lum_g, -str * old_lum_b)
i++
effect_r.Cut()
effect_g.Cut()
effect_b.Cut()
effect_str.Cut()
effect_turf.Cut()
//Smartly updates the lighting, only removes lum from and adds lum to turfs that actually got changed.
//This is for lights that need to reconsider due to nearby opacity changes.
//Stupid dumb copy pasta because BYOND and speed.
/datum/light_source/proc/smart_vis_update()
var/list/view[0]
FOR_DVIEW(var/turf/T, light_range, source_turf, INVISIBILITY_LIGHTING)
view += T //Filter out turfs.
//This is the part where we calculate new turfs (if any)
var/list/new_turfs = view - effect_turf //This will result with all the tiles that are added.
for(var/turf/T in new_turfs)
//Big huge copy paste from apply_lum() incoming because screw unreadable defines and screw proc call overhead.
if(T.lighting_overlay)
LUM_FALLOFF(., T, source_turf)
. *= light_power
if(!.) //Don't add turfs that aren't affected to the affected turfs.
continue
. = round(., LIGHTING_ROUND_VALUE)
effect_str += .
T.lighting_overlay.update_lumcount(
lum_r * .,
lum_g * .,
lum_b * .
)
else
effect_str += 0
if(!T.affecting_lights)
T.affecting_lights = list()
T.affecting_lights += src
effect_turf += T
var/list/old_turfs = effect_turf - view
for(var/turf/T in old_turfs)
//Insert not-so-huge copy paste from remove_lum().
var/idx = effect_turf.Find(T) //Get the index, luckily Find() is cheap in small lists like this. (with small I mean under a couple thousand len)
if(T.affecting_lights)
T.affecting_lights -= src
if(T.lighting_overlay)
var/str = effect_str[idx]
T.lighting_overlay.update_lumcount(-str * lum_r, -str * lum_g, -str * lum_b)
effect_turf.Cut(idx, idx + 1)
effect_str.Cut(idx, idx + 1)
#undef LUM_FALLOFF
#undef LUM_DISTANCE
#undef LUM_ATTENUATION
+22 -28
View File
@@ -7,7 +7,6 @@
icon = LIGHTING_ICON
layer = LIGHTING_LAYER
invisibility = INVISIBILITY_LIGHTING
blend_mode = BLEND_MULTIPLY
color = "#000000"
icon_state = "light1"
@@ -62,34 +61,33 @@
lighting_update_overlays += src
/atom/movable/lighting_overlay/proc/update_overlay()
var/mx = max(lum_r, lum_g, lum_b)
. = 1 // factor
if(mx > 1)
. = 1/mx
#if LIGHTING_TRANSITIONS == 1
animate(src,
color = rgb(lum_r * 255 * ., lum_g * 255 * ., lum_b * 255 * .),
LIGHTING_TRANSITION_SPEED
)
#else
color = rgb(lum_r * 255 * ., lum_g * 255 * ., lum_b * 255 * .)
#endif
var/turf/T = loc
if(istype(T)) //Incase we're not on a turf, pool ourselves, something happened.
if(color != "#000000")
T.luminosity = 1
else //No light, set the turf's luminosity to 0 to remove it from view()
#if LIGHTING_TRANSITIONS == 1
spawn(LIGHTING_TRANSITION_SPEED)
if(lum_r == lum_g && lum_r == lum_b) //greyscale
blend_mode = BLEND_OVERLAY
if(lum_r <= 0)
T.luminosity = 0
color = "#000000"
alpha = 255
else
T.luminosity = 1
color = "#000000"
alpha = (1 - min(lum_r, 1)) * 255
else
alpha = 255
var/mx = max(lum_r, lum_g, lum_b)
. = 1 // factor
if(mx > 1)
. = 1/mx
blend_mode = BLEND_MULTIPLY
color = rgb(lum_r * 255 * ., lum_g * 255 * ., lum_b * 255 * .)
if(color != "#000000")
T.luminosity = 1
else //No light, set the turf's luminosity to 0 to remove it from view()
T.luminosity = 0
#else
T.luminosity = 0
#endif
else
warning("A lighting overlay realised it's loc was NOT a turf (actual loc: [loc], [loc.type]) in update_overlay() and got qdel'd!")
warning("A lighting overlay realised its loc was NOT a turf (actual loc: [loc][loc ? ", " + loc.type : ""]) in update_overlay() and got qdel'ed!")
qdel(src)
/atom/movable/lighting_overlay/singularity_act()
@@ -104,9 +102,5 @@
var/turf/T = loc
if(istype(T))
T.lighting_overlay = null
for(var/datum/light_source/D in T.affecting_lights) //Remove references to us on the light sources affecting us.
D.effect_r -= src
D.effect_g -= src
D.effect_b -= src
return ..()
+16 -10
View File
@@ -2,31 +2,37 @@ var/global/datum/controller/process/lighting/lighting_controller
/datum/controller/process/lighting/setup()
name = "lighting"
schedule_interval = LIGHTING_INTERVAL
lighting_controller = src
schedule_interval = LIGHTING_INTERVAL
create_lighting_overlays()
/datum/controller/process/lighting/doWork()
var/list/lighting_update_lights_old = lighting_update_lights //We use a different list so any additions to the update lists during a delay from scheck() don't cause things to be cut from the list without being updated.
lighting_update_lights = null //Nulling it first because of http://www.byond.com/forum/?post=1854520
lighting_update_lights = list()
for(var/datum/light_source/L in lighting_update_lights_old)
if(L.needs_update)
if(L.destroyed || L.check() || L.force_update)
L.remove_lum()
if(!L.destroyed) L.apply_lum()
L.force_update = 0
L.needs_update = 0
if(L.destroyed || L.check() || L.force_update)
L.remove_lum()
if(!L.destroyed)
L.apply_lum()
else if(L.vis_update) //We smartly update only tiles that became (in) visible to use.
L.smart_vis_update()
L.vis_update = 0
L.force_update = 0
L.needs_update = 0
scheck()
var/list/lighting_update_overlays_old = lighting_update_overlays //Same as above.
lighting_update_overlays = null //Same as above
lighting_update_overlays = list()
for(var/atom/movable/lighting_overlay/O in lighting_update_overlays_old)
if(O.needs_update)
O.update_overlay()
O.needs_update = 0
O.update_overlay()
O.needs_update = 0
scheck()
+1 -1
View File
@@ -4,7 +4,7 @@
/turf/proc/reconsider_lights()
for(var/datum/light_source/L in affecting_lights)
L.force_update()
L.vis_update()
/turf/proc/lighting_clear_overlays()
if(lighting_overlay)
@@ -3,7 +3,6 @@
#undef LIGHTING_FALLOFF
#undef LIGHTING_LAMBERTIAN
#undef LIGHTING_HEIGHT
#undef LIGHTING_TRANSITIONS
#undef LIGHTING_RESOLUTION
#undef LIGHTING_LAYER
+7
View File
@@ -3,6 +3,7 @@
/mob/camera
name = "camera mob"
density = 0
anchored = 1
status_flags = GODMODE // You can't damage it.
mouse_opacity = 0
see_in_dark = 7
@@ -10,3 +11,9 @@
move_on_shuttle = 0
/mob/camera/experience_pressure_difference()
return
/mob/camera/Destroy()
..()
return QDEL_HINT_HARDDEL_NOW
@@ -110,21 +110,6 @@
updatehealth()
/mob/living/carbon/alien/humanoid/blob_act()
if (stat == 2)
return
var/shielded = 0
var/damage = null
if (stat != 2)
damage = rand(30,40)
if(shielded)
damage /= 4
show_message("<span class='userdanger'>The blob attacks!</span>")
adjustFireLoss(damage)
return
/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."
@@ -1,6 +1,6 @@
//unequip
/mob/living/carbon/alien/humanoid/unEquip(obj/item/I as obj)
. = ..()
/mob/living/carbon/alien/humanoid/unEquip(var/obj/item/I, var/force)
. = ..(I, force)
if(!. || !I)
return
@@ -45,8 +45,8 @@
icon_state = "alien[caste]_leap"
pixel_x = -32
pixel_y = -32
else
icon = initial(icon)
else if(icon == 'icons/mob/alienleap.dmi' && icon_state == "alien[caste]_leap" && pixel_x == -32 && pixel_y == -32)
icon = initial(icon)// ^ this looks odd, but in theory it will prevent the icon and pixel_xy from being reset unless it needs to be
pixel_x = initial(pixel_x)
pixel_y = initial(pixel_y)
@@ -101,30 +101,6 @@
updatehealth()
/mob/living/carbon/alien/larva/blob_act()
if (stat == 2)
return
var/shielded = 0
var/damage = null
if (stat != 2)
damage = rand(10,30)
if(shielded)
damage /= 4
//paralysis += 1
show_message("<span class='userdanger'>The blob attacks you!</span>")
adjustFireLoss(damage)
updatehealth()
return
//can't equip anything
/mob/living/carbon/alien/larva/attack_ui(slot_id)
return
@@ -60,5 +60,8 @@
/mob/living/carbon/brain/ex_act() //you cant blow up brainmobs because it makes transfer_to() freak out when borgs blow up.
return
/mob/living/carbon/brain/blob_act()
return
/mob/living/carbon/brain/binarycheck()
return istype(loc, /obj/item/device/mmi/posibrain)
+8
View File
@@ -1,5 +1,6 @@
mob/living
var/canEnterVentWith = "/obj/item/weapon/implant=0&/obj/item/clothing/mask/facehugger=0&/obj/item/device/radio/borg=0&/obj/machinery/camera=0"
var/datum/middleClickOverride/middleClickOverride = null
/mob/living/carbon/Login()
..()
@@ -20,6 +21,13 @@ mob/living
if(germ_level < GERM_LEVEL_AMBIENT && prob(30)) //if you're just standing there, you shouldn't get more germs beyond an ambient level
germ_level++
/mob/living/carbon/blob_act()
if (stat == DEAD)
return
else
show_message("<span class='userdanger'>The blob attacks!</span>")
adjustBruteLoss(10)
/mob/living/carbon/Move(NewLoc, direct)
. = ..()
if(.)
@@ -381,11 +381,11 @@
..()
/mob/living/carbon/human/blob_act()
if(stat == 2) return
show_message("\red The blob attacks you!")
if(stat == DEAD) return
show_message("<span class='userdanger'>The blob attacks you!</span>")
var/dam_zone = pick("head", "chest", "groin", "l_arm", "l_hand", "r_arm", "r_hand", "l_leg", "l_foot", "r_leg", "r_foot")
var/obj/item/organ/external/affecting = get_organ(ran_zone(dam_zone))
apply_damage(rand(20,30), BRUTE, affecting, run_armor_check(affecting, "melee"))
apply_damage(5, BRUTE, affecting, run_armor_check(affecting, "melee"))
return
/mob/living/carbon/human/attack_animal(mob/living/simple_animal/M as mob)
@@ -7,20 +7,7 @@
if ("help")
visible_message(text("\blue [M] caresses [src] with its scythe like arm."))
if ("grab")
if(M == src || anchored)
return
if (w_uniform)
w_uniform.add_fingerprint(M)
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab(M, src)
M.put_in_active_hand(G)
grabbed_by += G
G.synch()
LAssailant = M
playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1)
visible_message(text("\red [] has grabbed [] passively!", M, src))
grabbedby(M)
if("harm")
M.do_attack_animation(src)
@@ -212,23 +212,8 @@
/mob/living/carbon/slime/blob_act()
if (stat == 2)
return
var/shielded = 0
var/damage = null
if (stat != 2)
damage = rand(10,30)
if(shielded)
damage /= 4
//paralysis += 1
show_message("<span class='userdanger'> The blob attacks you!</span>")
adjustFireLoss(damage)
adjustBruteLoss(20)
updatehealth()
return
@@ -1,8 +1,8 @@
/obj/machinery/computer/drone_control
name = "Maintenance Drone Control"
desc = "Used to monitor the station's drone population and the assembler that services them."
icon = 'icons/obj/computer.dmi'
icon_state = "power"
icon_screen = "power"
icon_keyboard = "power_key"
req_access = list(access_engine_equip)
circuit = "/obj/item/weapon/circuitboard/drone_control"
@@ -243,7 +243,7 @@
/mob/living/simple_animal/borer/verb/secrete_chemicals()
set category = "Alien"
set name = "Secrete Chemicals (50)"
set name = "Secrete Chemicals (30)"
set desc = "Push some chemicals into your host's bloodstream."
if(!host)
@@ -257,17 +257,17 @@
src << "\blue You are feeling far too docile to do that."
return
if(chemicals < 50)
if(chemicals < 30)
src << "You don't have enough chemicals!"
var/chem = input("Select a chemical to secrete.", "Chemicals") as null|anything in list("mannitol","styptic_powder","methamphetamine","sal_acid")
if(!chem || chemicals < 50 || !host || controlling || !src || stat) //Sanity check.
if(!chem || chemicals < 30 || !host || controlling || !src || stat) //Sanity check.
return
src << "\red <B>You squirt a measure of [chem] from your reservoirs into [host]'s bloodstream.</B>"
host.reagents.add_reagent(chem, 15)
chemicals -= 50
host.reagents.add_reagent(chem, 9)
chemicals -= 30
/mob/living/simple_animal/borer/verb/release_host()
set category = "Alien"
+24 -2
View File
@@ -27,8 +27,13 @@
w_class = 5.0
/obj/item/weapon/grab/New(mob/user, mob/victim)
/obj/item/weapon/grab/New(var/mob/user, var/mob/victim)
..()
//Okay, first off, some fucking sanity checking. No user, or no victim, or they are not mobs, no grab.
if(!istype(user) || !istype(victim))
return
loc = user
assailant = user
affecting = victim
@@ -52,8 +57,25 @@
G.dancing = 1
G.adjust_position()
dancing = 1
clean_grabbed_by(assailant, affecting)
adjust_position()
/obj/item/weapon/grab/proc/clean_grabbed_by(var/mob/user, var/mob/victim) //Cleans up any nulls in the grabbed_by list.
if(istype(user))
for(var/entry in user.grabbed_by)
if(isnull(entry) || !istype(entry, /obj/item/weapon/grab)) //the isnull() here is probably redundant- but it might outperform istype, who knows. Better safe than sorry.
user.grabbed_by -= entry
if(istype(victim))
for(var/entry in victim.grabbed_by)
if(isnull(entry) || !istype(entry, /obj/item/weapon/grab))
victim.grabbed_by -= entry
return 1
//Used by throw code to hand over the mob, instead of throwing the grab. The grab is then deleted by the throw code.
/obj/item/weapon/grab/proc/get_mob_if_throwable()
if(affecting && assailant.Adjacent(affecting))
@@ -73,7 +95,7 @@
/obj/item/weapon/grab/process()
confirm()
if(!confirm()) return //If the confirm fails, the grab is about to be deleted. That means it shouldn't continue processing.
if(assailant.client)
if(!hud) return //this somehow can runtime under the right circumstances
+2
View File
@@ -37,6 +37,7 @@
health = 100
min_broken_damage = 50
body_part = LOWER_TORSO
vital = 1
parent_organ = "chest"
/obj/item/organ/external/diona/arm
@@ -117,6 +118,7 @@
health = 50
min_broken_damage = 25
body_part = HEAD
vital = 1
parent_organ = "chest"
/obj/item/organ/external/diona/head/removed()
+2 -2
View File
@@ -197,7 +197,7 @@
return 0
if(targloc == curloc) //Fire the projectile
user.bullet_act(in_chamber)
qdel(in_chamber)
del(in_chamber)
update_icon()
return 1
@@ -285,7 +285,7 @@
else
user << "<span class = 'notice'>Ow...</span>"
user.apply_effect(110,AGONY,0)
qdel(in_chamber)
del(in_chamber)
mouthshoot = 0
return
else
+6 -6
View File
@@ -80,7 +80,7 @@
proc/on_range() //if we want there to be effects when they reach the end of their range
proj_hit = 1
qdel(src)
del(src)
proc/on_hit(var/atom/target, var/blocked = 0, var/hit_zone)
if(!isliving(target)) return 0
@@ -97,7 +97,7 @@
in_chamber.pass_flags = pass_flags //And the pass flags to that of the real projectile...
in_chamber.firer = user
var/output = in_chamber.process() //Test it!
qdel(in_chamber) //No need for it anymore
del(in_chamber) //No need for it anymore
return output //Send it back to the gun!
Bump(atom/A as mob|obj|turf|area)
@@ -168,7 +168,7 @@
if(!istype(src, /obj/item/projectile/beam/lightning))
density = 0
invisibility = 101
qdel(src)
del(src)
return 1
@@ -187,7 +187,7 @@
spawn() //New projectile system
while(loc)
if(kill_count < 1)
qdel(src)
del(src)
return
kill_count--
if((!( current ) || loc == current))
@@ -262,7 +262,7 @@
spawn() //Old projectile system
while(loc)
if(kill_count < 1)
qdel(src)
del(src)
return
kill_count--
if((!( current ) || loc == current))
@@ -337,4 +337,4 @@
trace.firer = user
var/output = trace.process() //Test it!
qdel(trace) //No need for it anymore
return output //Send it back to the gun!
return output //Send it back to the gun!
@@ -0,0 +1,192 @@
// These can only be applied by blobs. They are what blobs are made out of.
// The 4 damage
/datum/reagent/blob
var/message = "The blob strikes you" //message sent to any mob hit by the blob
var/message_living = null //extension to first mob sent to only living mobs i.e. silicons have no skin to be burnt
/datum/reagent/blob/boiling_oil
name = "Boiling Oil"
id = "boiling_oil"
description = ""
color = "#B68D00"
message = "The blob splashes you with burning oil"
/datum/reagent/blob/boiling_oil/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(15*ratio, BURN)
M.adjust_fire_stacks(2*ratio)
M.IgniteMob()
if(isliving(M))
M.emote("scream")
/datum/reagent/blob/toxic_goop
name = "Toxic Goop"
id = "toxic_goop"
description = ""
color = "#008000"
message_living = ", and you feel sick and nauseated"
/datum/reagent/blob/toxic_goop/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(20*ratio, TOX)
/datum/reagent/blob/skin_ripper
name = "Skin Ripper"
id = "skin_ripper"
description = ""
color = "#FF4C4C"
message_living = ", and you feel your skin ripping and tearing off"
/datum/reagent/blob/skin_ripper/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(20*ratio, BRUTE)
if(iscarbon(M))
M.emote("scream")
// Combo Reagents
/datum/reagent/blob/skin_melter
name = "Skin Melter"
id = "skin_melter"
description = ""
color = "#7F0000"
message_living = ", and you feel your skin char and melt"
/datum/reagent/blob/skin_melter/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(10*ratio, BRUTE)
M.apply_damage(10*ratio, BURN)
M.adjust_fire_stacks(2*ratio)
M.IgniteMob()
if(iscarbon(M))
M.emote("scream")
/datum/reagent/blob/lung_destroying_toxin
name = "Lung Destroying Toxin"
id = "lung_destroying_toxin"
description = ""
color = "#00FFC5"
message_living = ", and your lungs feel heavy and weak"
/datum/reagent/blob/lung_destroying_toxin/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(20* ratio, OXY)
M.losebreath += 15*ratio
M.apply_damage(20*ratio, TOX)
// Special Reagents
/datum/reagent/blob/radioactive_liquid
name = "Radioactive Liquid"
id = "radioactive_liquid"
description = ""
color = "#00EE00"
message_living = ", and your skin feels papery and everything hurts"
/datum/reagent/blob/radioactive_liquid/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(10*ratio, BRUTE)
if(istype(M, /mob/living/carbon/human))
M.apply_effect(40*ratio,IRRADIATE,0)
if(prob(33*ratio))
randmuti(M)
if(prob(98))
randmutb(M)
domutcheck(M, null)
M.UpdateAppearance()
/datum/reagent/blob/dark_matter
name = "Dark Matter"
id = "dark_matter"
description = ""
color = "#61407E"
message = "You feel a thrum as the blob strikes you, and everything flies at you"
/datum/reagent/blob/dark_matter/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(15*ratio, BRUTE)
reagent_vortex(M, 0)
/datum/reagent/blob/b_sorium
name = "Sorium"
id = "b_sorium"
description = ""
color = "#808000"
message = "The blob slams into you, and sends you flying"
/datum/reagent/blob/b_sorium/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.apply_damage(15*ratio, BRUTE)
reagent_vortex(M, 1)
/datum/reagent/blob/explosive // I'm gonna burn in hell for this one
name = "Explosive Gelatin"
id = "explosive"
description = ""
color = "#FFA500"
message = "The blob strikes you, and its tendrils explode"
/datum/reagent/blob/explosive/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
if(prob(75*ratio))
explosion(M.loc, 0, 0, 1, 0, 0)
/datum/reagent/blob/omnizine
name = "Omnizine"
id = "b_omnizine"
description = ""
color = "#C8A5DC"
message = "The blob squirts something at you"
message_living = ", and you feel great"
/datum/reagent/blob/omnizine/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.reagents.add_reagent("omnizine", 11*ratio)
/datum/reagent/blob/spacedrugs
name = "Space drugs"
id = "b_space_drugs"
description = ""
color = "#60A584"
message = "The blob squirts something at you"
message_living = ", and you feel funny"
/datum/reagent/blob/spacedrugs/reaction_mob(var/mob/living/M as mob, var/method=TOUCH, var/volume)
if(method == TOUCH)
var/ratio = volume/25
M.hallucination += 20*ratio
M.reagents.add_reagent("space_drugs", 15*ratio)
M.apply_damage(10*ratio, TOX)
/datum/reagent/blob/proc/reagent_vortex(var/mob/living/M as mob, var/setting_type)
var/turf/pull = get_turf(M)
for(var/atom/movable/X in range(4,pull))
if(istype(X, /atom/movable))
if((X) && !X.anchored)
if(setting_type)
step_away(X,pull)
step_away(X,pull)
step_away(X,pull)
step_away(X,pull)
else
X.throw_at(pull)
/datum/reagent/blob/proc/send_message(var/mob/living/M as mob)
var/totalmessage = message
if(message_living && !issilicon(M))
totalmessage += message_living
totalmessage += "!"
M << "<span class='userdanger'>[totalmessage]</span>"
+8 -1
View File
@@ -28,4 +28,11 @@
desc = "Helps with burn injuries."
New()
..()
reagents.add_reagent("silver_sulfadiazine", 40)
reagents.add_reagent("silver_sulfadiazine", 40)
/obj/item/weapon/reagent_containers/pill/patch/synthflesh
name = "syntheflesh patch"
desc = "Helps with burn injuries."
New()
..()
reagents.add_reagent("synthflesh", 20)
@@ -144,34 +144,36 @@
..() // -> item/attackby(, params)
if(istype(W,/obj/item/weapon/kitchen/utensil))
//This will allow forks/spoons/plastic cutlery to pick up sliceables, but requires it to be unsliceable for the knife to pick it up
if((istype(W, /obj/item/weapon/kitchen/utensil/knife) && !slice_path) || !istype(W, /obj/item/weapon/kitchen/utensil/knife))
var/obj/item/weapon/kitchen/utensil/U = W
var/obj/item/weapon/kitchen/utensil/U = W
if(!U.reagents)
U.create_reagents(5)
if(!U.reagents)
U.create_reagents(5)
if (U.reagents.total_volume > 0)
user << "\red You already have something on your [U]."
if (U.reagents.total_volume > 0)
user << "\red You already have something on your [U]."
return
user.visible_message( \
"[user] scoops up some [src] with \the [U]!", \
"\blue You scoop up some [src] with \the [U]!" \
)
src.bitecount++
U.overlays.Cut()
U.loaded = "[src]"
var/image/I = new(U.icon, "loadedfood")
I.color = src.filling_color
U.overlays += I
reagents.trans_to(U,min(reagents.total_volume,5))
if (reagents.total_volume <= 0)
qdel(src)
return
user.visible_message( \
"[user] scoops up some [src] with \the [U]!", \
"\blue You scoop up some [src] with \the [U]!" \
)
src.bitecount++
U.overlays.Cut()
U.loaded = "[src]"
var/image/I = new(U.icon, "loadedfood")
I.color = src.filling_color
U.overlays += I
reagents.trans_to(U,min(reagents.total_volume,5))
if (reagents.total_volume <= 0)
qdel(src)
return
if((slices_num <= 0 || !slices_num) || !slice_path)
return 0
@@ -10,7 +10,12 @@
src.bitesize = 3
/obj/item/weapon/reagent_containers/food/snacks/meat/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
if(istype(W,/obj/item/weapon/kitchen/utensil/knife))
if( \
istype(W, /obj/item/weapon/kitchenknife) || \
istype(W, /obj/item/weapon/butch) || \
istype(W, /obj/item/weapon/scalpel) || \
istype(W, /obj/item/weapon/kitchen/utensil/knife) \
)
new /obj/item/weapon/reagent_containers/food/snacks/rawcutlet(src)
new /obj/item/weapon/reagent_containers/food/snacks/rawcutlet(src)
new /obj/item/weapon/reagent_containers/food/snacks/rawcutlet(src)
@@ -13,6 +13,7 @@
var/obj/machinery/keycard_auth/event_source
var/mob/event_triggered_by
var/mob/event_confirmed_by
var/ert_reason = "Reason for ERT"
//1 = select event
//2 = authenticate
anchored = 1.0
@@ -38,8 +39,8 @@
event_source.confirmed = 1
event_source.event_confirmed_by = usr
else if(screen == 2)
if(event == "Emergency Response Team" && !ert_chosen.len)
user << "<span class='notice'>Pick the Emergency Response Team type first!</span>"
if(event == "Emergency Response Team" && ert_reason == "Reason for ERT")
user << "<span class='notice'>Supply a reason for calling the ERT first!</span>"
return
event_triggered_by = usr
broadcast_request() //This is the device making the initial event request. It needs to broadcast to other devices
@@ -69,12 +70,7 @@
var/data[0]
data["screen"] = screen
data["event"] = event
data["erttypes"] = list()
for(var/type in response_team_types)
var/active = 0
if((type in ert_chosen))
active = 1
data["erttypes"] += list(list("name" = type, "active" = active))
data["ertreason"] = ert_reason
ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open)
if (!ui)
@@ -92,17 +88,12 @@
usr << "This device is without power."
return
if(href_list["triggerevent"])
ert_chosen.Cut()
event = href_list["triggerevent"]
screen = 2
if(href_list["reset"])
reset()
if(href_list["ert"])
var/chosen = href_list["ert"]
if((chosen in response_team_types) && !(chosen in ert_chosen))
ert_chosen |= chosen
else
ert_chosen -= chosen
ert_reason = input(usr, "Reason for ERT Call:", "", "")
nanomanager.update_uis(src)
add_fingerprint(usr)
@@ -165,9 +156,13 @@
usr << "\red All Emergency Response Teams are dispatched and can not be called at this time."
return
response_team_chosen_types += ert_chosen
trigger_armed_response_team(1)
feedback_inc("alert_keycard_auth_ert",1)
usr << "<span class = 'notice'>ERT request transmitted.</span>"
if(admins.len)
ERT_Announce(ert_reason , event_triggered_by)
ert_reason = "Reason for ERT"
feedback_inc("alert_keycard_auth_ert",1)
else
trigger_armed_response_team(new /datum/response_team/amber) // No admins? No problem. Automatically send a code amber ERT.
/obj/machinery/keycard_auth/proc/is_ert_blocked()
return ticker.mode && ticker.mode.ert_disabled