| Nuclear Disk(s) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| [N.name], "
var/atom/disk_loc = N.loc
while(!istype(disk_loc, /turf))
@@ -489,6 +492,11 @@
if(ticker.mode.cult.len)
dat += check_role_table("Cultists", ticker.mode.cult, 0)
+ dat += " use Cult Mindspeak" + if(GAMEMODE_IS_CULT) + var/datum/game_mode/cult/cult_round = ticker.mode + if(!cult_round.narsie_condition_cleared) + dat += " complete objective (debug)" if(ticker.mode.traitors.len) dat += check_role_table("Traitors", ticker.mode.traitors) diff --git a/code/modules/admin/topic.dm b/code/modules/admin/topic.dm index 1efb3567828..4a01b1161e8 100644 --- a/code/modules/admin/topic.dm +++ b/code/modules/admin/topic.dm @@ -1533,6 +1533,34 @@ else if(href_list["check_antagonist"]) check_antagonists() + else if(href_list["cult_nextobj"]) + if(alert(usr, "Validate the current Cult objective and unlock the next one?", "Cult Cheat Code", "Yes", "No") != "Yes") + return + + if(!GAMEMODE_IS_CULT) + alert("Couldn't locate cult mode datum! This shouldn't ever happen, tell a coder!") + return + + var/datum/game_mode/cult/cult_round = ticker.mode + cult_round.bypass_phase() + message_admins("Admin [key_name_admin(usr)] has unlocked the Cult's next objective.") + log_admin("Admin [key_name_admin(usr)] has unlocked the Cult's next objective.") + + else if(href_list["cult_mindspeak"]) + var/input = stripped_input(usr, "Communicate to all the cultists with the voice of [ticker.mode.cultdat.entity_name]", "Voice of [ticker.mode.cultdat.entity_name]", "") + if(!input) + return + + for(var/datum/mind/H in ticker.mode.cult) + if (H.current) + to_chat(H.current, "[ticker.mode.cultdat.entity_name] murmurs, [input]") + + for(var/mob/dead/observer/O in player_list) + to_chat(O, "[ticker.mode.cultdat.entity_name] murmurs, [input]") + + message_admins("Admin [key_name_admin(usr)] has talked with the Voice of [ticker.mode.cultdat.entity_name].") + log_admin("[key_name(usr)] Voice of [ticker.mode.cultdat.entity_name]: [input]") + else if(href_list["adminplayerobservecoodjump"]) if(!check_rights(R_ADMIN)) return @@ -2145,6 +2173,7 @@ else var/atom/O = new path(target) if(O) + O.admin_spawned = TRUE O.dir = obj_dir if(obj_name) O.name = obj_name @@ -2277,11 +2306,11 @@ if(gravity_is_on) log_admin("[key_name(usr)] toggled gravity on.", 1) message_admins("\blue [key_name_admin(usr)] toggled gravity on.", 1) - command_announcement.Announce("Gravity generators are again functioning within normal parameters. Sorry for any inconvenience.") + event_announcement.Announce("Gravity generators are again functioning within normal parameters. Sorry for any inconvenience.") else log_admin("[key_name(usr)] toggled gravity off.", 1) message_admins("\blue [key_name_admin(usr)] toggled gravity off.", 1) - command_announcement.Announce("Feedback surge detected in mass-distributions systems. Artifical gravity has been disabled whilst the system reinitializes. Further failures may result in a gravitational collapse and formation of blackholes. Have a nice day.") + event_announcement.Announce("Feedback surge detected in mass-distributions systems. Artifical gravity has been disabled whilst the system reinitializes. Further failures may result in a gravitational collapse and formation of blackholes. Have a nice day.") if("power") feedback_inc("admin_secrets_fun_used",1) @@ -2553,7 +2582,7 @@ if(is_station_level(W.z) && !istype(get_area(W), /area/bridge) && !istype(get_area(W), /area/crew_quarters) && !istype(get_area(W), /area/security/prison)) W.req_access = list() message_admins("[key_name_admin(usr)] activated Egalitarian Station mode") - command_announcement.Announce("Centcomm airlock control override activated. Please take this time to get acquainted with your coworkers.", new_sound = 'sound/AI/commandreport.ogg') + event_announcement.Announce("Centcomm airlock control override activated. Please take this time to get acquainted with your coworkers.", new_sound = 'sound/AI/commandreport.ogg') if("onlyone") feedback_inc("admin_secrets_fun_used",1) feedback_add_details("admin_secrets_fun_used","OO") diff --git a/code/modules/admin/verbs/adminhelp.dm b/code/modules/admin/verbs/adminhelp.dm index c17671995ff..73b481bbc6b 100644 --- a/code/modules/admin/verbs/adminhelp.dm +++ b/code/modules/admin/verbs/adminhelp.dm @@ -119,6 +119,7 @@ var/list/adminhelp_ignored_words = list("unknown","the","a","an","of","monkey"," for(var/client/X in modholders + adminholders) if(X.prefs.sound & SOUND_ADMINHELP) X << 'sound/effects/adminhelp.ogg' + window_flash(X) to_chat(X, msg) //show it to the person adminhelping too diff --git a/code/modules/admin/verbs/adminpm.dm b/code/modules/admin/verbs/adminpm.dm index 63241ce43c5..5de3178e7ff 100644 --- a/code/modules/admin/verbs/adminpm.dm +++ b/code/modules/admin/verbs/adminpm.dm @@ -133,6 +133,7 @@ if(holder && !C.holder) recieve_message = "-- Click the [recieve_pm_type]'s name to reply --\n" if(C.adminhelped) + window_flash(C) to_chat(C, recieve_message) C.adminhelped = 0 @@ -149,6 +150,9 @@ adminhelp(reply) //sender has left, adminhelp instead return + // for emoji, we have to define a specific span for jquery to look for + msg = "[msg]" + recieve_message = "[type] from-[recieve_pm_type][key_name(src, C, C.holder ? 1 : 0, type)]: [msg]" to_chat(C, recieve_message) to_chat(src, "[send_pm_type][type] to-[key_name(C, src, holder ? 1 : 0, type)]: [msg]") diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm index 862eed1b986..59ea8992889 100644 --- a/code/modules/admin/verbs/debug.dm +++ b/code/modules/admin/verbs/debug.dm @@ -1474,3 +1474,57 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that return error_cache.showTo(usr) + +/client/proc/jump_to_ruin() + set category = "Debug" + set name = "Jump to Ruin" + set desc = "Displays a list of all placed ruins to teleport to." + + if(!check_rights(R_DEBUG)) + return + + var/list/names = list() + for(var/i in ruin_landmarks) + var/obj/effect/landmark/ruin/ruin_landmark = i + var/datum/map_template/ruin/template = ruin_landmark.ruin_template + + var/count = 1 + var/name = template.name + var/original_name = name + + while(name in names) + count++ + name = "[original_name] ([count])" + + names[name] = ruin_landmark + + var/ruinname = input("Select ruin", "Jump to Ruin") as null|anything in names + + var/obj/effect/landmark/ruin/landmark = names[ruinname] + + if(istype(landmark)) + var/datum/map_template/ruin/template = landmark.ruin_template + admin_forcemove(usr, get_turf(landmark)) + + to_chat(usr, "[template.name]") + to_chat(usr, "[template.description]") + + log_admin("[key_name(usr)] jumped to ruin [ruinname]") + if(!isobserver(usr)) + message_admins("[key_name_admin(usr)] jumped to ruin [ruinname]", 1) + + feedback_add_details("admin_verb","JT") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + +/client/proc/toggle_medal_disable() + set category = "Debug" + set name = "Toggle Medal Disable" + set desc = "Toggles the safety lock on trying to contact the medal hub." + + if(!check_rights(R_DEBUG)) + return + + global.medals_enabled = !global.medals_enabled + + message_admins("[key_name_admin(src)] [global.medals_enabled ? "disabled" : "enabled"] the medal hub lockout.") + feedback_add_details("admin_verb","TMH") // If... + log_admin("[key_name(src)] [global.medals_enabled ? "disabled" : "enabled"] the medal hub lockout.") diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index bfc4f7a8887..5a53b0201b3 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -30,6 +30,12 @@ var/intercom_range_display_status = 0 src.pixel_x = -224 src.pixel_y = -224 +/obj/effect/debugging/mapfix_marker + name = "map fix marker" + icon = 'icons/mob/screen_gen.dmi' + icon_state = "mapfixmarker" + desc = "I am a mappers mistake." + /obj/effect/debugging/marker icon = 'icons/turf/areas.dmi' icon_state = "yellow" diff --git a/code/modules/admin/verbs/massmodvar.dm b/code/modules/admin/verbs/massmodvar.dm index c416f224cf9..c7b2d6d537e 100644 --- a/code/modules/admin/verbs/massmodvar.dm +++ b/code/modules/admin/verbs/massmodvar.dm @@ -137,32 +137,38 @@ for(var/mob/M in mob_list) if( istype(M , O.type) ) M.vars[variable] = O.vars[variable] + M.on_varedit(variable) else if(istype(O, /obj)) for(var/obj/A in world) if( istype(A , O.type) ) A.vars[variable] = O.vars[variable] + A.on_varedit(variable) else if(istype(O, /turf)) for(var/turf/A in world) if( istype(A , O.type) ) A.vars[variable] = O.vars[variable] + A.on_varedit(variable) else if(istype(O, /mob)) for(var/mob/M in mob_list) if(M.type == O.type) M.vars[variable] = O.vars[variable] + M.on_varedit(variable) else if(istype(O, /obj)) for(var/obj/A in world) if(A.type == O.type) A.vars[variable] = O.vars[variable] + A.on_varedit(variable) else if(istype(O, /turf)) for(var/turf/A in world) if(A.type == O.type) A.vars[variable] = O.vars[variable] + A.on_varedit(variable) if("edit referenced object") return .(O.vars[variable]) diff --git a/code/modules/admin/verbs/modifyvariables.dm b/code/modules/admin/verbs/modifyvariables.dm index 0be55889bc2..8cce4c5a761 100644 --- a/code/modules/admin/verbs/modifyvariables.dm +++ b/code/modules/admin/verbs/modifyvariables.dm @@ -131,7 +131,7 @@ var/list/forbidden_varedit_object_types = list( L[var_value] = mod_list_add_ass() //haha if("No") L += var_value - + /client/proc/mod_list(var/list/L) if(!check_rights(R_VAREDIT)) return @@ -440,6 +440,7 @@ var/list/forbidden_varedit_object_types = list( if(var_as_text == null) var_as_text = "[O.vars[variable]]" + O.on_varedit(variable) log_to_dd("### VarEdit by [src]: [O.type] [variable]=[html_encode("[var_as_text]")]") log_admin("[key_name(src)] modified [original_name]'s [variable] to [var_as_text]") message_admins("[key_name_admin(src)] modified [original_name]'s [variable] to [var_as_text]", 1) diff --git a/code/modules/awaymissions/bluespaceartillery.dm b/code/modules/awaymissions/bluespaceartillery.dm index 6b6eb863b45..1da3d3bfc55 100644 --- a/code/modules/awaymissions/bluespaceartillery.dm +++ b/code/modules/awaymissions/bluespaceartillery.dm @@ -58,7 +58,7 @@ if(reload_cooldown > delta) return 1 - command_announcement.Announce("Bluespace artillery fire detected. Brace for impact.") + event_announcement.Announce("Bluespace artillery fire detected. Brace for impact.") message_admins("[key_name_admin(usr)] has launched an artillery strike.", 1) var/list/L = list() for(var/turf/T in get_area_turfs(targetarea.type)) diff --git a/code/modules/awaymissions/corpse.dm b/code/modules/awaymissions/corpse.dm index b2864d1c7cc..4c050e0d4f3 100644 --- a/code/modules/awaymissions/corpse.dm +++ b/code/modules/awaymissions/corpse.dm @@ -26,6 +26,8 @@ var/corpseidicon = null //For setting it to be a gold, silver, centcomm etc ID var/timeofdeath = null var/coffin = 0 + var/brute_damage = 0 + var/oxy_damage = 0 /obj/effect/landmark/corpse/initialize() if(istype(src,/obj/effect/landmark/corpse/clown)) @@ -37,34 +39,36 @@ var/mob/living/carbon/human/human/M = new /mob/living/carbon/human/human (src.loc) M.real_name = src.name M.death(1) //Kills the new mob + M.adjustOxyLoss(oxy_damage) + M.adjustBruteLoss(brute_damage) M.timeofdeath = timeofdeath - if(src.mob_species) - M.set_species(src.mob_species) - if(src.corpseuniform) - M.equip_to_slot_or_del(new src.corpseuniform(M), slot_w_uniform) - if(src.corpsesuit) - M.equip_to_slot_or_del(new src.corpsesuit(M), slot_wear_suit) - if(src.corpseshoes) - M.equip_to_slot_or_del(new src.corpseshoes(M), slot_shoes) - if(src.corpsegloves) - M.equip_to_slot_or_del(new src.corpsegloves(M), slot_gloves) - if(src.corpseradio) - M.equip_to_slot_or_del(new src.corpseradio(M), slot_l_ear) - if(src.corpseglasses) - M.equip_to_slot_or_del(new src.corpseglasses(M), slot_glasses) - if(src.corpsemask) - M.equip_to_slot_or_del(new src.corpsemask(M), slot_wear_mask) - if(src.corpsehelmet) - M.equip_to_slot_or_del(new src.corpsehelmet(M), slot_head) - if(src.corpsebelt) - M.equip_to_slot_or_del(new src.corpsebelt(M), slot_belt) - if(src.corpsepocket1) - M.equip_to_slot_or_del(new src.corpsepocket1(M), slot_r_store) - if(src.corpsepocket2) - M.equip_to_slot_or_del(new src.corpsepocket2(M), slot_l_store) - if(src.corpseback) - M.equip_to_slot_or_del(new src.corpseback(M), slot_back) - if(src.corpseid == 1) + if(mob_species) + M.set_species(mob_species) + if(corpseuniform) + M.equip_to_slot_or_del(new corpseuniform(M), slot_w_uniform) + if(corpsesuit) + M.equip_to_slot_or_del(new corpsesuit(M), slot_wear_suit) + if(corpseshoes) + M.equip_to_slot_or_del(new corpseshoes(M), slot_shoes) + if(corpsegloves) + M.equip_to_slot_or_del(new corpsegloves(M), slot_gloves) + if(corpseradio) + M.equip_to_slot_or_del(new corpseradio(M), slot_l_ear) + if(corpseglasses) + M.equip_to_slot_or_del(new corpseglasses(M), slot_glasses) + if(corpsemask) + M.equip_to_slot_or_del(new corpsemask(M), slot_wear_mask) + if(corpsehelmet) + M.equip_to_slot_or_del(new corpsehelmet(M), slot_head) + if(corpsebelt) + M.equip_to_slot_or_del(new corpsebelt(M), slot_belt) + if(corpsepocket1) + M.equip_to_slot_or_del(new corpsepocket1(M), slot_r_store) + if(corpsepocket2) + M.equip_to_slot_or_del(new corpsepocket2(M), slot_l_store) + if(corpseback) + M.equip_to_slot_or_del(new corpseback(M), slot_back) + if(corpseid == 1) var/obj/item/weapon/card/id/W = new(M) W.name = "[M.real_name]'s ID Card" var/datum/job/jobdatum @@ -73,9 +77,9 @@ if(J.title == corpseidaccess) jobdatum = J break - if(src.corpseidicon) + if(corpseidicon) W.icon_state = corpseidicon - if(src.corpseidaccess) + if(corpseidaccess) if(jobdatum) W.access = jobdatum.get_access() else @@ -84,18 +88,14 @@ W.assignment = corpseidjob W.registered_name = M.real_name M.equip_to_slot_or_del(W, slot_wear_id) - if(src.coffin == 1) + if(coffin == 1) var/obj/structure/closet/coffin/sarcophagus/sarc = locate(/obj/structure/closet/coffin/sarcophagus) in loc if(sarc) M.loc = sarc qdel(src) - - // I'll work on making a list of corpses people request for maps, or that I think will be commonly used. Syndicate operatives for example. - - - - +/obj/effect/landmark/corpse/damaged + brute_damage = 1000 /obj/effect/landmark/corpse/syndicatesoldier name = "Syndicate Operative" diff --git a/code/modules/awaymissions/zlevel.dm b/code/modules/awaymissions/zlevel.dm index b12ee063f2d..f5b951eb627 100644 --- a/code/modules/awaymissions/zlevel.dm +++ b/code/modules/awaymissions/zlevel.dm @@ -205,7 +205,17 @@ var/global/list/potentialRandomZlevels = generateMapList(filename = "config/away template = safepick(possible_ruins) if(!template) return 0 + var/turf/central_turf = get_turf(src) + for(var/i in template.get_affected_turfs(central_turf, 1)) + var/turf/T = i + for(var/mob/living/simple_animal/monster in T) + qdel(monster) + for(var/obj/structure/flora/ash/plant in T) + qdel(plant) template.load(get_turf(src),centered = 1) template.loaded++ + var/datum/map_template/ruin = template + if(istype(ruin)) + new /obj/effect/landmark/ruin(central_turf, ruin) qdel(src) return 1 diff --git a/code/modules/client/preference/loadout/loadout_hat.dm b/code/modules/client/preference/loadout/loadout_hat.dm index e5f8c158092..7e4ca4620d9 100644 --- a/code/modules/client/preference/loadout/loadout_hat.dm +++ b/code/modules/client/preference/loadout/loadout_hat.dm @@ -117,3 +117,13 @@ display_name = "science beret" path = /obj/item/clothing/head/beret/sci allowed_roles = list("Research Director", "Scientist") + +/datum/gear/hat/surgicalcap_purple + display_name = "surgical cap, purple" + path = /obj/item/clothing/head/surgery/purple + allowed_roles = list("Chief Medical Officer", "Medical Doctor") + +/datum/gear/hat/surgicalcap_green + display_name = "surgical cap, green" + path = /obj/item/clothing/head/surgery/green + allowed_roles = list("Chief Medical Officer", "Medical Doctor") \ No newline at end of file diff --git a/code/modules/client/preference/loadout/loadout_uniform.dm b/code/modules/client/preference/loadout/loadout_uniform.dm index aaec97829c8..d7df4da720b 100644 --- a/code/modules/client/preference/loadout/loadout_uniform.dm +++ b/code/modules/client/preference/loadout/loadout_uniform.dm @@ -98,6 +98,19 @@ path = /obj/item/clothing/under/rank/head_of_security/skirt allowed_roles = list("Head of Security") +/datum/gear/uniform/medical + subtype_path = /datum/gear/uniform/medical + +/datum/gear/uniform/medical/pscrubs + display_name = "medical scrubs, purple" + path = /obj/item/clothing/under/rank/medical/purple + allowed_roles = list("Chief Medical Officer", "Medical Doctor") + +/datum/gear/uniform/medical/gscrubs + display_name = "medical scrubs, green" + path = /obj/item/clothing/under/rank/medical/green + allowed_roles = list("Chief Medical Officer", "Medical Doctor") + /datum/gear/uniform/sec subtype_path = /datum/gear/uniform/sec diff --git a/code/modules/client/preference/preferences.dm b/code/modules/client/preference/preferences.dm index bf139ee4c8b..c9b3127094b 100644 --- a/code/modules/client/preference/preferences.dm +++ b/code/modules/client/preference/preferences.dm @@ -23,6 +23,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts // ROLE_GANG = 21, ROLE_BORER = 21, ROLE_NINJA = 21, + ROLE_GSPIDER = 21, ROLE_ABDUCTOR = 30, ) @@ -92,6 +93,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts var/show_ghostitem_attack = TRUE var/UI_style_color = "#ffffff" var/UI_style_alpha = 255 + var/windowflashing = TRUE //character preferences @@ -417,6 +419,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts dat += " General Settings" dat += "Fancy NanoUI: [(nanoui_fancy) ? "Yes" : "No"]" dat += "Ghost-Item Attack Animation: [(show_ghostitem_attack) ? "Yes" : "No"] " + dat += "Window Flashing: [(windowflashing) ? "Yes" : "No"] " dat += "Custom UI settings: " dat += " - UI Style: [UI_style] " dat += " - Color: [UI_style_color]
" @@ -1934,6 +1937,9 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts if("ghost_att_anim") show_ghostitem_attack = !show_ghostitem_attack + if("winflash") + windowflashing = !windowflashing + if("UIcolor") var/UI_style_color_new = input(user, "Choose your UI color, dark colors are not recommended!", UI_style_color) as color|null if(!UI_style_color_new) return @@ -1962,6 +1968,9 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts if("randomslot") randomslot = !randomslot + if(isnewplayer(usr)) + var/mob/new_player/N = usr + N.new_player_panel_proc() if("hear_midis") sound ^= SOUND_MIDI @@ -2145,35 +2154,28 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts if(disabilities & DISABILITY_FLAG_FAT && character.species.flags & CAN_BE_FAT) character.dna.SetSEState(FATBLOCK,1,1) - character.mutations += FAT - character.mutations += OBESITY character.overeatduration = 600 if(disabilities & DISABILITY_FLAG_NEARSIGHTED) character.dna.SetSEState(GLASSESBLOCK,1,1) - character.disabilities |= NEARSIGHTED if(disabilities & DISABILITY_FLAG_EPILEPTIC) character.dna.SetSEState(EPILEPSYBLOCK,1,1) - character.disabilities |= EPILEPSY if(disabilities & DISABILITY_FLAG_DEAF) character.dna.SetSEState(DEAFBLOCK,1,1) - character.disabilities |= DEAF if(disabilities & DISABILITY_FLAG_BLIND) character.dna.SetSEState(BLINDBLOCK,1,1) - character.disabilities |= BLIND if(disabilities & DISABILITY_FLAG_MUTE) character.dna.SetSEState(MUTEBLOCK,1,1) - character.disabilities |= MUTE S.handle_dna(character) if(character.dna.dirtySE) character.dna.UpdateSE() - domutcheck(character, null, MUTCHK_FORCED) + domutcheck(character, null, MUTCHK_FORCED) //'Activates' all the above disabilities. character.dna.ready_dna(character, flatten_SE = 0) character.sync_organ_dna(assimilate=1) @@ -2187,26 +2189,26 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts /datum/preferences/proc/open_load_dialog(mob/user) var/DBQuery/query = dbcon.NewQuery("SELECT slot,real_name FROM [format_table_name("characters")] WHERE ckey='[user.ckey]' ORDER BY slot") + var/list/slotnames[max_save_slots] + + if(!query.Execute()) + var/err = query.ErrorMsg() + log_game("SQL ERROR during character slot loading. Error : \[[err]\]\n") + message_admins("SQL ERROR during character slot loading. Error : \[[err]\]\n") + return + while(query.NextRow()) + slotnames[text2num(query.item[1])] = query.item[2] var/dat = "" dat += " " var/name - for(var/i=1, i<=max_save_slots, i++) - if(!query.Execute()) - var/err = query.ErrorMsg() - log_game("SQL ERROR during character slot loading. Error : \[[err]\]\n") - message_admins("SQL ERROR during character slot loading. Error : \[[err]\]\n") - return - while(query.NextRow()) - if(i==text2num(query.item[1])) - name = query.item[2] - if(!name) name = "Character[i]" - if(i==default_slot) + for(var/i in 1 to max_save_slots) + name = slotnames[i] || "Character [i]" + if(i == default_slot) name = "[name]" dat += "[name] " - name = null dat += " " dat += "Close " diff --git a/code/modules/client/preference/preferences_mysql.dm b/code/modules/client/preference/preferences_mysql.dm index 581daf222d3..8f1b11b5ca6 100644 --- a/code/modules/client/preference/preferences_mysql.dm +++ b/code/modules/client/preference/preferences_mysql.dm @@ -14,7 +14,8 @@ nanoui_fancy, show_ghostitem_attack, lastchangelog, - exp + exp, + windowflashing FROM [format_table_name("player")] WHERE ckey='[C.ckey]'"} ) @@ -42,6 +43,7 @@ show_ghostitem_attack = text2num(query.item[12]) lastchangelog = query.item[13] exp = query.item[14] + windowflashing = text2num(query.item[15]) //Sanitize ooccolor = sanitize_hexcolor(ooccolor, initial(ooccolor)) @@ -57,6 +59,7 @@ show_ghostitem_attack = sanitize_integer(show_ghostitem_attack, 0, 1, initial(show_ghostitem_attack)) lastchangelog = sanitize_text(lastchangelog, initial(lastchangelog)) exp = sanitize_text(exp, initial(exp)) + windowflashing = sanitize_integer(windowflashing, 0, 1, initial(windowflashing)) return 1 /datum/preferences/proc/save_preferences(client/C) @@ -500,21 +503,24 @@ return return 1 -/* -/datum/preferences/proc/random_character(client/C) +/datum/preferences/proc/load_random_character_slot(client/C) var/DBQuery/query = dbcon.NewQuery("SELECT slot FROM [format_table_name("characters")] WHERE ckey='[C.ckey]' ORDER BY slot") + var/list/saves = list() + + if(!query.Execute()) + var/err = query.ErrorMsg() + log_game("SQL ERROR during random character slot picking. Error : \[[err]\]\n") + message_admins("SQL ERROR during random character slot picking. Error : \[[err]\]\n") + return while(query.NextRow()) - var/list/saves = list() - for(var/i=1, i<=MAX_SAVE_SLOTS, i++) - if(i==text2num(query.item[1])) - saves += i + saves += text2num(query.item[1]) if(!saves.len) load_character(C) return 0 load_character(C,pick(saves)) - return 1*/ + return 1 /datum/preferences/proc/SetChangelog(client/C,hash) lastchangelog=hash diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index 078f83f506a..c80c13d514b 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -193,8 +193,9 @@ BLIND // can't see anything "Drask" = 'icons/mob/species/drask/gloves.dmi' ) -/obj/item/clothing/gloves/proc/Touch() - return +// Called just before an attack_hand(), in mob/UnarmedAttack() +/obj/item/clothing/gloves/proc/Touch(atom/A, proximity) + return 0 // return 1 to cancel attack_hand() /obj/item/clothing/gloves/attackby(obj/item/weapon/W, mob/user, params) if(istype(W, /obj/item/weapon/wirecutters)) diff --git a/code/modules/clothing/gloves/miscellaneous.dm b/code/modules/clothing/gloves/miscellaneous.dm index 2b932df2dc1..aefb7188f5c 100644 --- a/code/modules/clothing/gloves/miscellaneous.dm +++ b/code/modules/clothing/gloves/miscellaneous.dm @@ -56,3 +56,74 @@ icon_state = "latex" item_state = "lgloves" flags = NODROP + + +/obj/item/clothing/gloves/color/yellow/stun + name = "stun gloves" + desc = "Horrendous and awful. It smells like cancer. The fact it has wires attached to it is incidental." + var/obj/item/weapon/stock_parts/cell/cell = null + var/stun_strength = 5 + var/stun_cost = 3750 + +/obj/item/clothing/gloves/color/yellow/stun/New() + ..() + update_icon() + +/obj/item/clothing/gloves/color/yellow/stun/Destroy() + if(cell) + qdel(cell) + cell = null + return ..() + +/obj/item/clothing/gloves/color/yellow/stun/Touch(atom/A, proximity) + if(!ishuman(loc)) + return FALSE //Only works while worn + if(!iscarbon(A)) + return FALSE + if(!proximity) + return FALSE + if(cell) + var/mob/living/carbon/human/H = loc + if(H.a_intent == I_HARM) + var/mob/living/carbon/C = A + if(cell.use(stun_cost)) + var/datum/effect/system/spark_spread/s = new /datum/effect/system/spark_spread + s.set_up(5, 0, loc) + s.start() + playsound(loc, 'sound/weapons/Egloves.ogg', 50, 1, -1) + H.do_attack_animation(C) + visible_message("[C] has been touched with [src] by [H]!") + C.Stun(stun_strength) + C.Weaken(stun_strength) + C.apply_effect(STUTTER, stun_strength) + else + to_chat(H, "Not enough charge!") + return TRUE + return FALSE + +/obj/item/clothing/gloves/color/yellow/stun/update_icon() + ..() + overlays.Cut() + overlays += "gloves_wire" + if(cell) + overlays += "gloves_cell" + +/obj/item/clothing/gloves/color/yellow/stun/attackby(obj/item/weapon/W, mob/living/user, params) + if(istype(W, /obj/item/weapon/stock_parts/cell)) + if(!cell) + if(!user.drop_item()) + to_chat(user, "[W] is stuck to you!") + return + W.forceMove(src) + cell = W + to_chat(user, "You attach [W] to [src].") + update_icon() + else + to_chat(user, "[src] already has a cell.") + + else if(iswirecutter(W)) + if(cell) + to_chat(user, "You cut [cell] away from [src].") + cell.forceMove(get_turf(loc)) + cell = null + update_icon() \ No newline at end of file diff --git a/code/modules/clothing/head/misc.dm b/code/modules/clothing/head/misc.dm index 98e5026ae81..88638abde76 100644 --- a/code/modules/clothing/head/misc.dm +++ b/code/modules/clothing/head/misc.dm @@ -79,9 +79,17 @@ name = "cueball helmet" desc = "A large, featureless white orb meant to be worn on your head. How do you even see out of this thing?" icon_state = "cueball" + item_state = "cueball" flags = HEADCOVERSEYES | HEADCOVERSMOUTH | BLOCKHAIR - item_state="cueball" - flags_inv = 0 + flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE + +/obj/item/clothing/head/snowman + name = "snowman head" + desc = "A ball of white styrofoam. So festive." + icon_state = "snowman_h" + item_state = "snowman_h" + flags = HEADCOVERSEYES | HEADCOVERSMOUTH | BLOCKHAIR + flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE /obj/item/clothing/head/that name = "sturdy top-hat" @@ -348,6 +356,16 @@ attack_verb = list("warned", "cautioned", "smashed") burn_state = FIRE_PROOF +/obj/item/clothing/head/jester + name = "jester hat" + desc = "A hat with bells, to add some merryness to the suit." + icon_state = "jester_hat" + +/obj/item/clothing/head/rice_hat + name = "rice hat" + desc = "Welcome to the rice fields, motherfucker." + icon_state = "rice_hat" + /obj/item/clothing/head/griffin name = "griffon head" desc = "Why not 'eagle head'? Who knows." diff --git a/code/modules/clothing/masks/miscellaneous.dm b/code/modules/clothing/masks/miscellaneous.dm index f299419ed09..427cc071eda 100644 --- a/code/modules/clothing/masks/miscellaneous.dm +++ b/code/modules/clothing/masks/miscellaneous.dm @@ -139,6 +139,7 @@ w_class = 2 gas_transfer_coefficient = 0.90 + /obj/item/clothing/mask/pig name = "pig mask" desc = "A rubber pig mask." @@ -188,6 +189,58 @@ if(user.real_name == "[originalname][temporaryname]" || user.real_name == "A Horse With No Name") //if it's somehow changed while the mask is on it doesn't revert user.real_name = originalname +/obj/item/clothing/mask/face + flags = MASKCOVERSMOUTH + flags_inv = HIDEFACE + +/obj/item/clothing/mask/face/rat + name = "rat mask" + desc = "A mask made of soft vinyl and latex, representing the head of a rat." + icon_state = "rat" + item_state = "rat" + +/obj/item/clothing/mask/face/fox + name = "fox mask" + desc = "A mask made of soft vinyl and latex, representing the head of a fox." + icon_state = "fox" + item_state = "fox" + +/obj/item/clothing/mask/face/bee + name = "bee mask" + desc = "A mask made of soft vinyl and latex, representing the head of a bee." + icon_state = "bee" + item_state = "bee" + +/obj/item/clothing/mask/face/bear + name = "bear mask" + desc = "A mask made of soft vinyl and latex, representing the head of a bear." + icon_state = "bear" + item_state = "bear" + +/obj/item/clothing/mask/face/bat + name = "bat mask" + desc = "A mask made of soft vinyl and latex, representing the head of a bat." + icon_state = "bat" + item_state = "bat" + +/obj/item/clothing/mask/face/raven + name = "raven mask" + desc = "A mask made of soft vinyl and latex, representing the head of a raven." + icon_state = "raven" + item_state = "raven" + +/obj/item/clothing/mask/face/jackal + name = "jackal mask" + desc = "A mask made of soft vinyl and latex, representing the head of a jackal." + icon_state = "jackal" + item_state = "jackal" + +/obj/item/clothing/mask/face/tribal + name = "tribal mask" + desc = "A mask carved out of wood, detailed carefully by hand." + icon_state = "bumba" + item_state = "bumba" + /obj/item/clothing/mask/fawkes name = "Guy Fawkes mask" desc = "A mask designed to help you remember a specific date." @@ -287,7 +340,7 @@ icon_override = 'icons/goonstation/mob/clothing/mask.dmi' lefthand_file = 'icons/goonstation/mob/inhands/clothing_lefthand.dmi' righthand_file = 'icons/goonstation/mob/inhands/clothing_righthand.dmi' - flags = NODROP + flags = NODROP | AIRTIGHT | MASKCOVERSMOUTH /obj/item/clothing/mask/cursedclown/equipped(mob/user, slot) ..() diff --git a/code/modules/clothing/shoes/miscellaneous.dm b/code/modules/clothing/shoes/miscellaneous.dm index 4b2ae0ea01b..702c47d13ed 100644 --- a/code/modules/clothing/shoes/miscellaneous.dm +++ b/code/modules/clothing/shoes/miscellaneous.dm @@ -212,3 +212,15 @@ righthand_file = 'icons/goonstation/mob/inhands/clothing_righthand.dmi' flags = NODROP shoe_sound = "clownstep" + +/obj/item/clothing/shoes/singery + name = "yellow performer's boots" + desc = "These boots were made for dancing." + icon_state = "ysing" + put_on_delay = 50 + +/obj/item/clothing/shoes/singerb + name = "blue performer's boots" + desc = "These boots were made for dancing." + icon_state = "bsing" + put_on_delay = 50 diff --git a/code/modules/clothing/spacesuits/breaches.dm b/code/modules/clothing/spacesuits/breaches.dm index 7c74f77b054..37c88241173 100644 --- a/code/modules/clothing/spacesuits/breaches.dm +++ b/code/modules/clothing/spacesuits/breaches.dm @@ -92,7 +92,7 @@ var/global/list/breach_burn_descriptors = list( if(!breaches) breaches = list() - if(damage > 25) return //We don't need to keep tracking it when it's at 250% pressure loss, really. + if(damage >= 25) return //We don't need to keep tracking it when it's at 250% pressure loss, really. if(!loc) return var/turf/T = get_turf(src) @@ -125,7 +125,7 @@ var/global/list/breach_burn_descriptors = list( var/datum/breach/B = new() breaches += B - B.class = min(amount,5) + B.class = min(amount,(5 - max(damage - 20,0))) //We cap the check at 25, this line could overshoot without the calculation if it gets enough dammage in one shot. B.damtype = damtype B.update_descriptor() diff --git a/code/modules/clothing/spacesuits/rig/modules/combat.dm b/code/modules/clothing/spacesuits/rig/modules/combat.dm index 16ddf2bdd69..925beda23cd 100644 --- a/code/modules/clothing/spacesuits/rig/modules/combat.dm +++ b/code/modules/clothing/spacesuits/rig/modules/combat.dm @@ -119,7 +119,7 @@ gun.attack_self(holder.wearer) return 1 - gun.process_fire(target,holder.wearer) + gun.afterattack(target,holder.wearer) return 1 /obj/item/rig_module/mounted/egun diff --git a/code/modules/clothing/spacesuits/rig/modules/handheld.dm b/code/modules/clothing/spacesuits/rig/modules/handheld.dm new file mode 100644 index 00000000000..1a8a66a5fc4 --- /dev/null +++ b/code/modules/clothing/spacesuits/rig/modules/handheld.dm @@ -0,0 +1,50 @@ + +/obj/item/rig_module/handheld + name = "mounted device" + desc = "Some kind of hardsuit extension." + usable = 0 + selectable = 0 + toggleable = 1 + disruptive = 0 + activate_string = "Deploy" + deactivate_string = "Retract" + + var/device_type + var/obj/item/device + +/obj/item/rig_module/handheld/activate() + if(!..()) + return + + if(!holder.wearer.put_in_hands(device)) + to_chat(holder.wearer, "You need a free hand to hold \the [device].") + active = 0 + return + + to_chat(holder.wearer, "You deploy \the [device].") + + +/obj/item/rig_module/handheld/deactivate() + if(!..()) + return + if(ismob(device.loc)) //Better check for the holder, instead of assuming the rigwearer has it. + var/mob/M = device.loc //Helps in case the code fails to keep the module in one place, this should still return it. + M.unEquip(device, 1) + + device.loc = src + to_chat(holder.wearer, "You retract \the [device].") + +/obj/item/rig_module/handheld/New() + ..() + if(device_type) + device = new device_type(src) + device.flags |= NODROP //We don't want to drop it while it's active/inhand. + activate_string += " [device]" + deactivate_string += " [device]" + +/obj/item/rig_module/handheld/horn + name = "mounted bikehorn" + desc = "For tactical honking" + interface_name = "mounted bikehorn" + interface_desc = "Honks" + device_type = /obj/item/weapon/bikehorn diff --git a/code/modules/clothing/spacesuits/rig/modules/utility.dm b/code/modules/clothing/spacesuits/rig/modules/utility.dm index 46471966aa7..aa1e644e506 100644 --- a/code/modules/clothing/spacesuits/rig/modules/utility.dm +++ b/code/modules/clothing/spacesuits/rig/modules/utility.dm @@ -94,7 +94,9 @@ */ /obj/item/rig_module/device/New() ..() - if(device_type) device = new device_type(src) + if(device_type) + device = new device_type(src) + device.flags |= ABSTRACT //Abstract in the sense that it's not an item that stands alone, but rather is just there to let the module act like it. /obj/item/rig_module/device/engage(atom/target) if(!..() || !device) @@ -417,13 +419,15 @@ interface_desc = "Leave your mark." engage_string = "Toggle stamp type" usable = 1 - var/iastamp - var/deniedstamp + var/obj/iastamp //Theese were just vars, but any device would need to be an object + var/obj/deniedstamp //Stops assigning non-objects to theese vars, which probably would break quite a bit. /obj/item/rig_module/device/stamp/New() ..() iastamp = new /obj/item/weapon/stamp/law(src) deniedstamp = new /obj/item/weapon/stamp/denied(src) + iastamp.flags |= ABSTRACT + deniedstamp.flags |= ABSTRACT device = iastamp /obj/item/rig_module/device/stamp/engage(atom/target) @@ -488,4 +492,4 @@ W.update_icon() /obj/item/rig_module/welding_tank/proc/get_fuel() - return reagents.get_reagent_amount("fuel") \ No newline at end of file + return reagents.get_reagent_amount("fuel") diff --git a/code/modules/clothing/spacesuits/rig/rig.dm b/code/modules/clothing/spacesuits/rig/rig.dm index 2ebd01a9162..0b9e87891d8 100644 --- a/code/modules/clothing/spacesuits/rig/rig.dm +++ b/code/modules/clothing/spacesuits/rig/rig.dm @@ -42,7 +42,7 @@ //Component/device holders. var/obj/item/weapon/tank/air_supply // Air tank, if any. - var/obj/item/clothing/shoes/boots = null // Deployable boots, if any. + var/obj/item/clothing/shoes/magboots/boots = null // Deployable boots, if any. var/obj/item/clothing/suit/space/new_rig/chest // Deployable chestpiece, if any. var/obj/item/clothing/head/helmet/space/new_rig/helmet = null // Deployable helmet, if any. var/obj/item/clothing/gloves/rig/gloves = null // Deployable gauntlets, if any. @@ -76,6 +76,7 @@ var/airtight = 1 //If set, will adjust AIRTIGHT and STOPSPRESSUREDMAGE flags on components. Otherwise it should leave them untouched. var/emp_protection = 0 + var/has_emergency_release = 1 //Allows suit to be removed from outside. // Wiring! How exciting. var/datum/wires/rig/wires @@ -126,14 +127,17 @@ if(helm_type) helmet = new helm_type(src) verbs |= /obj/item/weapon/rig/proc/toggle_helmet + helmet.item_color="[initial(icon_state)]_sealed" //For the lightswitching to know the correct string to manipulate if(boot_type) boots = new boot_type(src) verbs |= /obj/item/weapon/rig/proc/toggle_boots + boots.magboot_state="[initial(icon_state)]_sealed" //For the magboot (de)activation to know the correct string to manipulate if(chest_type) chest = new chest_type(src) if(allowed) chest.allowed = allowed chest.slowdown = offline_slowdown + chest.holder = src verbs |= /obj/item/weapon/rig/proc/toggle_chest for(var/obj/item/piece in list(gloves,helmet,boots,chest)) @@ -183,6 +187,10 @@ /obj/item/weapon/rig/proc/reset() offline = 2 flags &= ~NODROP + if(helmet && helmet.on) + helmet.toggle_light(wearer) + if(boots && boots.magpulse) + boots.attack_self(wearer) for(var/obj/item/piece in list(helmet,boots,gloves,chest)) if(!piece) continue piece.icon_state = "[initial(icon_state)]" @@ -254,6 +262,7 @@ switch(msg_type) if("boots") to_chat(wearer, "\The [correct_piece] seal around your feet.") + correct_piece.icon_state = "[initial(icon_state)]_sealed0" //Solution to not need a sprite for off, on, and unused magboots. if(user != wearer) to_chat(user, "\The [correct_piece] has been sealed.") wearer.update_inv_shoes() @@ -269,6 +278,7 @@ wearer.update_inv_wear_suit() if("helmet") to_chat(wearer, "\The [correct_piece] hisses closed.") + correct_piece.icon_state = "[initial(icon_state)]_sealed0" //Solution to not need a sprite for off, on, and unused helmet light. if(user != wearer) to_chat(user, "\The [correct_piece] has been sealed.") wearer.update_inv_head() @@ -383,10 +393,14 @@ sealing = FALSE if(failed_to_seal) - for(var/obj/item/piece in list(helmet, boots, gloves, chest)) + for(var/obj/item/piece in list(gloves, chest)) if(!piece) continue piece.icon_state = "[initial(icon_state)]_sealed" + if(helmet) + helmet.icon_state = "[initial(icon_state)]_sealed[helmet.on]" + if(boots) + boots.icon_state = "[initial(icon_state)]_sealed[boots.magpulse]" if(airtight) update_component_sealed() update_icon(1) @@ -406,6 +420,10 @@ update_icon(1) /obj/item/weapon/rig/proc/update_component_sealed() + if(istype(boots) && !(flags & NODROP) && boots.magpulse) //If we have (active) boots and unsealed the suit, we deactivate the magboots. + boots.attack_self(wearer) + if(istype(helmet) && !(flags & NODROP) && helmet.on) //If we have an (active) headlamp and unsealed the suit, we deactivate the headlamp. + helmet.toggle_light(wearer) for(var/obj/item/piece in list(helmet,boots,gloves,chest)) if(!(flags & NODROP)) piece.flags &= ~STOPSPRESSUREDMAGE @@ -695,6 +713,8 @@ M.visible_message("[M] struggles into \the [src].", "You struggle into \the [src].") wearer = M wearer.wearing_rig = src + if(has_emergency_release) + M.verbs |= /obj/item/weapon/rig/proc/emergency_release update_icon() /obj/item/weapon/rig/proc/toggle_piece(var/piece, var/mob/living/user, var/deploy_mode, var/force) @@ -705,15 +725,15 @@ if(isliving(uneq_piece.loc)) var/mob/living/L = uneq_piece.loc L.unEquip(uneq_piece, 1) - uneq_piece.flags &= ~NODROP uneq_piece.forceMove(src) return 0 if(sealing || !cell || !cell.charge) return 0 - if(user == wearer && user.incapacitated()) // If the user isn't wearing the suit it's probably an AI. - return 0 + if(!(deploy_mode == ONLY_RETRACT && force)) //This should be the case while stripping, stripping does trigger the if statement below. + if(user == wearer && user.incapacitated()) // If the user isn't wearing the suit it's probably an AI. + return 0 var/obj/item/check_slot var/equip_to @@ -752,7 +772,6 @@ if(to_strip) to_strip.unEquip(use_obj, 1) - use_obj.flags &= ~NODROP use_obj.forceMove(src) if(wearer) to_chat(wearer, "Your [use_obj] [use_obj.gender == PLURAL ? "retract" : "retracts"] swiftly.") @@ -762,13 +781,11 @@ to_chat(wearer, "You are unable to deploy \the [piece] as \the [check_slot] [check_slot.gender == PLURAL ? "are" : "is"] in the way.") return use_obj.forceMove(wearer) - use_obj.flags &= ~NODROP if(!wearer.equip_to_slot_if_possible(use_obj, equip_to, 0, 1)) use_obj.forceMove(src) else if(wearer) to_chat(wearer, "Your [use_obj.name] [use_obj.gender == PLURAL ? "deploy" : "deploys"] swiftly.") - use_obj.flags |= NODROP if(piece == "helmet" && helmet) helmet.update_light(wearer) @@ -777,17 +794,17 @@ if(!wearer || !user) return 0 - if(flags & NODROP) - if(wearer.head && wearer.head != helmet) + if(flags & NODROP) //We need to check if we have the part, the person is wearing something in the parts slot, and if yes, are they the same. + if(helmet && wearer.head && wearer.head != helmet) to_chat(user, "\The [wearer.head] is blocking \the [src] from deploying!") return 0 - if(wearer.gloves && wearer.gloves != gloves) + if(gloves && wearer.gloves && wearer.gloves != gloves) to_chat(user, "\The [wearer.gloves] is preventing \the [src] from deploying!") return 0 - if(wearer.shoes && wearer.shoes != boots) + if(boots && wearer.shoes && wearer.shoes != boots) to_chat(user, "\The [wearer.shoes] is preventing \the [src] from deploying!") return 0 - if(wearer.wear_suit && wearer.wear_suit != chest) + if(chest && wearer.wear_suit && wearer.wear_suit != chest) to_chat(user, "\The [wearer.wear_suit] is preventing \the [src] from deploying!") return 0 @@ -797,6 +814,7 @@ /obj/item/weapon/rig/dropped(var/mob/user) ..() + user.verbs -= /obj/item/weapon/rig/proc/emergency_release for(var/piece in list("helmet","gauntlets","chest","boots")) toggle_piece(piece, user, ONLY_RETRACT, 1) if(wearer) @@ -996,6 +1014,38 @@ else return null +/obj/item/weapon/rig/proc/emergency_release() + set name = "Suit Emergency Release" + set desc = "Activate the suits emergency release system." + set category = "Object" + set src in oview(1) + var/obj/item/weapon/rig/T = get_rig() + return T.do_emergency_release(usr) + +/obj/item/weapon/rig/proc/do_emergency_release(var/mob/living/user) + if(!can_touch(user, wearer) || !has_emergency_release) + return can_touch(user,wearer) + usr.visible_message("[user] starts activating \the [src] emergency seals release!") + if(!do_after(user,240, target = wearer)) + to_chat(user, "You need to focus on activating the emergency release.") + return 0 + usr.visible_message("[user] activated \the [src] emergency seals release!") + malfunctioning += 1 + malfunction_delay = 30 + unseal(user) + return 1 + +/obj/item/weapon/rig/proc/can_touch(var/mob/user, var/mob/wearer) + if(!user) + return 0 + if(!wearer.Adjacent(user)) + return 0 + if(user.restrained()) + to_chat(user, "You need your hands free for this.") + return 0 + if(user.stat || user.paralysis || user.sleeping || user.lying || user.weakened) + return 0 + return 1 #undef ONLY_DEPLOY #undef ONLY_RETRACT #undef SEAL_DELAY diff --git a/code/modules/clothing/spacesuits/rig/rig_armormod.dm b/code/modules/clothing/spacesuits/rig/rig_armormod.dm new file mode 100644 index 00000000000..ec045c7da2d --- /dev/null +++ b/code/modules/clothing/spacesuits/rig/rig_armormod.dm @@ -0,0 +1,21 @@ +/obj/item/clothing/suit/space/new_rig/calc_breach_damage() + ..() + holder.update_armor() //New dammage, new armormultiplikator. + return damage + +/obj/item/weapon/rig/proc/update_armor() + var/multi = 1 //Multiplicative modification to the armor, maybe add an additive later on + if(chest) + multi *= (100 - chest.damage) / 100 //If we have some breaches, lower the armor value. + + //TODO check for other armor mods, likely modules, which need to be coded. + + for(var/obj/item/piece in list(gloves, helmet, boots, chest)) + if(!istype(piece)) //Do we have the piece + continue + if(islist(armor)) //Did we even give them some armor, if this is the case, the list should be initialized from New() + var/list/L = armor + for(var/armortype in L) + piece.armor[armortype] = L[armortype]*multi + +//Perfect place to also add something like shield modules, or any other hit_reaction modules check. diff --git a/code/modules/clothing/spacesuits/rig/rig_attackby.dm b/code/modules/clothing/spacesuits/rig/rig_attackby.dm index b89c59cf837..a57c2258b04 100644 --- a/code/modules/clothing/spacesuits/rig/rig_attackby.dm +++ b/code/modules/clothing/spacesuits/rig/rig_attackby.dm @@ -141,7 +141,7 @@ if(user.r_hand && user.l_hand) cell.forceMove(get_turf(user)) else - cell.forceMove(user.put_in_hands(cell)) + user.put_in_hands(cell) cell = null else to_chat(user, "There is nothing loaded in that mount.") diff --git a/code/modules/clothing/spacesuits/rig/rig_pieces.dm b/code/modules/clothing/spacesuits/rig/rig_pieces.dm index dab4ad5ac35..0480490c0ca 100644 --- a/code/modules/clothing/spacesuits/rig/rig_pieces.dm +++ b/code/modules/clothing/spacesuits/rig/rig_pieces.dm @@ -4,7 +4,7 @@ /obj/item/clothing/head/helmet/space/new_rig name = "helmet" - flags = HEADCOVERSEYES | BLOCKHAIR | HEADCOVERSMOUTH | THICKMATERIAL + flags = HEADCOVERSEYES | BLOCKHAIR | HEADCOVERSMOUTH | THICKMATERIAL | NODROP flags_inv = HIDEEARS|HIDEEYES|HIDEFACE|HIDEMASK body_parts_covered = HEAD heat_protection = HEAD @@ -12,11 +12,12 @@ var/brightness_on = 4 var/on = 0 sprite_sheets = list( - "Tajara" = 'icons/mob/species/tajaran/helmet.dmi', + "Tajaran" = 'icons/mob/species/tajaran/helmet.dmi', "Skrell" = 'icons/mob/species/skrell/helmet.dmi', "Unathi" = 'icons/mob/species/unathi/helmet.dmi' ) species_restricted = null + actions_types = list(/datum/action/item_action/toggle_helmet_light) flash_protect = 2 @@ -28,13 +29,17 @@ toggle_light(user) /obj/item/clothing/head/helmet/space/new_rig/proc/toggle_light(mob/user) - on = !on - icon_state = "rig[on]-[item_color]" + if(flags & AIRTIGHT) //Could also check for STOPSPRESSUREDMAGE, but one is enough, both get toggled when the seal gets toggled. - if(on) - set_light(brightness_on) + on = !on + icon_state = "[item_color][on]" + + if(on) + set_light(brightness_on) + else + set_light(0) else - set_light(0) + to_chat(user, "You cannot turn the light on while the suit isn't sealed.") if(istype(user,/mob/living/carbon/human)) var/mob/living/carbon/human/H = user @@ -42,7 +47,7 @@ /obj/item/clothing/gloves/rig name = "gauntlets" - flags = THICKMATERIAL + flags = THICKMATERIAL | NODROP body_parts_covered = HANDS heat_protection = HANDS cold_protection = HANDS @@ -51,12 +56,19 @@ /obj/item/clothing/shoes/magboots/rig name = "boots" + flags = NODROP body_parts_covered = FEET cold_protection = FEET heat_protection = FEET species_restricted = null gender = PLURAL +/obj/item/clothing/shoes/magboots/rig/attack_self(mob/user) + if(flags & AIRTIGHT) //Could also check for STOPSPRESSUREDMAGE, but one is enough, both get toggled when the seal gets toggled. + ..(user) + else + to_chat(user, "You cannot activate mag-pulse traction system while the suit is not sealed.") + /obj/item/clothing/suit/space/new_rig name = "chestpiece" allowed = list(/obj/item/device/flashlight,/obj/item/weapon/tank) @@ -64,14 +76,14 @@ heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS cold_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS flags_inv = HIDEJUMPSUIT|HIDETAIL - flags = STOPSPRESSUREDMAGE | THICKMATERIAL | AIRTIGHT + flags = STOPSPRESSUREDMAGE | THICKMATERIAL | AIRTIGHT | NODROP slowdown = 0 - //will reach 10 breach damage after 25 laser carbine blasts, 3 revolver hits, or ~1 PTR hit. Completely immune to smg or sts hits. - breach_threshold = 38 + breach_threshold = 20 resilience = 0.2 can_breach = 1 + var/obj/item/weapon/rig/holder sprite_sheets = list( - "Tajara" = 'icons/mob/species/tajaran/suit.dmi', + "Tajaran" = 'icons/mob/species/tajaran/suit.dmi', "Unathi" = 'icons/mob/species/unathi/suit.dmi' ) diff --git a/code/modules/clothing/spacesuits/rig/suits/light.dm b/code/modules/clothing/spacesuits/rig/suits/light.dm index 0bda9f9288a..2a38480dabc 100644 --- a/code/modules/clothing/spacesuits/rig/suits/light.dm +++ b/code/modules/clothing/spacesuits/rig/suits/light.dm @@ -112,7 +112,7 @@ name = "stealth suit control module" suit_type = "stealth" desc = "A highly advanced and expensive suit designed for covert operations." - icon_state = "stealth_rig" + icon_state = "ninja_rig" //supposed to be "stealth_rig", but as it currently only has a semi-copied ninja rig sprite, we can just use them directly. req_access = list(access_syndicate) diff --git a/code/modules/clothing/suits/jobs.dm b/code/modules/clothing/suits/jobs.dm index 886a98e4678..0ccdf7027d3 100644 --- a/code/modules/clothing/suits/jobs.dm +++ b/code/modules/clothing/suits/jobs.dm @@ -38,7 +38,7 @@ item_state = "apron" blood_overlay_type = "armor" body_parts_covered = UPPER_TORSO|LOWER_TORSO - allowed = list (/obj/item/weapon/reagent_containers/spray/plantbgone,/obj/item/device/analyzer/plant_analyzer,/obj/item/seeds,/obj/item/weapon/reagent_containers/glass/bottle/fertilizer,/obj/item/weapon/minihoe) + allowed = list(/obj/item/weapon/reagent_containers/spray/plantbgone,/obj/item/device/plant_analyzer,/obj/item/seeds,/obj/item/weapon/reagent_containers/glass/bottle, /obj/item/weapon/reagent_containers/glass/beaker, /obj/item/weapon/cultivator,/obj/item/weapon/reagent_containers/spray/pestspray,/obj/item/weapon/hatchet,/obj/item/weapon/storage/bag/plants) species_fit = list("Vox") sprite_sheets = list( "Vox" = 'icons/mob/species/vox/suit.dmi' diff --git a/code/modules/clothing/suits/miscellaneous.dm b/code/modules/clothing/suits/miscellaneous.dm index 8798caf2e06..ef20bbd0362 100644 --- a/code/modules/clothing/suits/miscellaneous.dm +++ b/code/modules/clothing/suits/miscellaneous.dm @@ -249,6 +249,13 @@ I.overlays += image(icon = 'icons/mob/robots.dmi' , icon_state = "eyes-robot") //gotta look realistic H.add_alt_appearance("standard_borg_disguise", I, silicon_mob_list+H) //you look like a robot to robots! (including yourself because you're totally a robot) +/obj/item/clothing/suit/snowman + name = "snowman outfit" + desc = "Two white spheres covered in white glitter. 'Tis the season." + icon_state = "snowman" + item_state = "snowman" + body_parts_covered = UPPER_TORSO|LOWER_TORSO + flags_inv = HIDEJUMPSUIT /obj/item/clothing/suit/poncho name = "poncho" @@ -279,6 +286,44 @@ item_state = "ponchoshame" flags = NODROP +/obj/item/clothing/suit/hooded/carp_costume + name = "carp costume" + desc = "A costume made from 'synthetic' carp scales, it smells." + icon_state = "carp_casual" + item_state = "labcoat" + body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS + cold_protection = UPPER_TORSO|LOWER_TORSO|ARMS + min_cold_protection_temperature = FIRE_SUIT_MIN_TEMP_PROTECT //Space carp like space, so you should too + allowed = list(/obj/item/weapon/tank/emergency_oxygen) + hoodtype = /obj/item/clothing/head/hooded/carp_hood + +/obj/item/clothing/head/hooded/carp_hood + name = "carp hood" + desc = "A hood attached to a carp costume." + icon_state = "carp_casual" + body_parts_covered = HEAD + cold_protection = HEAD + min_cold_protection_temperature = FIRE_SUIT_MIN_TEMP_PROTECT + flags = NODROP|BLOCKHAIR + flags_inv = HIDEEARS + +/obj/item/clothing/suit/hooded/bee_costume // It's Hip! + name = "bee costume" + desc = "Bee the true Queen!" + icon_state = "bee" + item_state = "labcoat" + body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS + flags = THICKMATERIAL + hoodtype = /obj/item/clothing/head/hooded/bee_hood + +/obj/item/clothing/head/hooded/bee_hood + name = "bee hood" + desc = "A hood attached to a bee costume." + icon_state = "bee" + body_parts_covered = HEAD + flags = THICKMATERIAL|NODROP|BLOCKHAIR + flags_inv = HIDEEARS + /obj/item/clothing/suit/bloated_human //OH MY GOD WHAT HAVE YOU DONE!?!?!? name = "bloated human suit" desc = "A horribly bloated suit made from human skins." @@ -376,7 +421,7 @@ /obj/item/clothing/suit/hooded/wintercoat/hydro name = "hydroponics winter coat" icon_state = "wintercoat_hydro" - allowed = list(/obj/item/weapon/reagent_containers/spray, /obj/item/device/analyzer/plant_analyzer, /obj/item/seeds, /obj/item/weapon/reagent_containers/glass/bottle, /obj/item/weapon/hatchet, /obj/item/weapon/storage/bag/plants) + allowed = list(/obj/item/weapon/reagent_containers/spray, /obj/item/device/plant_analyzer, /obj/item/seeds, /obj/item/weapon/reagent_containers/glass/bottle, /obj/item/weapon/hatchet, /obj/item/weapon/storage/bag/plants) hoodtype = /obj/item/clothing/head/winterhood/hydro /obj/item/clothing/head/winterhood/hydro @@ -728,6 +773,13 @@ adjust_flavour = null burn_state = FIRE_PROOF +/obj/item/clothing/suit/jacket/leather/overcoat + name = "leather overcoat" + desc = "That's a damn fine coat." + icon_state = "leathercoat" + body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS|LEGS + cold_protection = UPPER_TORSO|LOWER_TORSO|ARMS|LEGS + /obj/item/clothing/suit/officercoat name = "Clown Officer's Coat" desc = "A classy clown officer's overcoat, also designed by Hugo Boss." diff --git a/code/modules/clothing/under/miscellaneous.dm b/code/modules/clothing/under/miscellaneous.dm index 6da895760af..486d7d7c34e 100644 --- a/code/modules/clothing/under/miscellaneous.dm +++ b/code/modules/clothing/under/miscellaneous.dm @@ -495,6 +495,26 @@ item_color = "janimaid" body_parts_covered = UPPER_TORSO|LOWER_TORSO +/obj/item/clothing/under/singery + name = "yellow performer's outfit" + desc = "Just looking at this makes you want to sing." + icon_state = "ysing" + item_state = "ysing" + item_color = "ysing" + +/obj/item/clothing/under/singerb + name = "blue performer's outfit" + desc = "Just looking at this makes you want to sing." + icon_state = "bsing" + item_state = "bsing" + item_color = "bsing" + +/obj/item/clothing/under/jester + name = "jester suit" + desc = "A jolly dress, well suited to entertain your master, nuncle." + icon_state = "jester" + item_color = "jester" + /obj/item/clothing/under/flappers name = "flappers" desc = "Nothing like the roarin' '20s, flapping the night away on the dance floor." diff --git a/code/modules/computer3/computers/communications.dm b/code/modules/computer3/computers/communications.dm index a4fad8a16cb..bff075c4791 100644 --- a/code/modules/computer3/computers/communications.dm +++ b/code/modules/computer3/computers/communications.dm @@ -47,7 +47,7 @@ New() ..() - crew_announcement.newscast = 1 + crew_announcement.newscast = 0 Reset() ..() diff --git a/code/modules/computer3/program_disks.dm b/code/modules/computer3/program_disks.dm index 201fff39392..64b592b06be 100644 --- a/code/modules/computer3/program_disks.dm +++ b/code/modules/computer3/program_disks.dm @@ -1,44 +1,30 @@ - - /obj/item/weapon/disk/file/arcade name = "Arcade game grab pack" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/arcade,/datum/file/program/arcade,/datum/file/program/arcade,/datum/file/program/arcade) /*/obj/item/weapon/disk/file/aifixer name = "AI System Integrity Restorer" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/aifixer)*/ /obj/item/weapon/disk/file/atmos_alert name = "Atmospheric Alert Notifier" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/atmos_alert) /obj/item/weapon/disk/file/cameras name = "Camera Viewer" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/security) /obj/item/weapon/disk/file/card name = "ID Card Modifier" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/card_comp) /* /obj/item/weapon/disk/file/genetics name = "Genetics & Cloning" desc = "A program install disk." - icon = 'icons/obj/stock_parts.dmi' - icon_state = "datadisk_arcade" spawn_files = list(/datum/file/program/cloning,/datum/file/program/dnascanner) */ diff --git a/code/modules/computer3/storage.dm b/code/modules/computer3/storage.dm index 9ff8cab497b..acb569d3072 100644 --- a/code/modules/computer3/storage.dm +++ b/code/modules/computer3/storage.dm @@ -163,6 +163,7 @@ //parent_type = /obj/item/part/computer/storage // todon't: do this name = "Data Disk" desc = "A device that can be inserted and removed into computers easily as a form of portable data storage. This one stores 1 Megabyte" + icon_state = "datadisk_arcade" var/list/files var/list/spawn_files = list() var/writeprotect = 0 diff --git a/code/modules/crafting/recipes.dm b/code/modules/crafting/recipes.dm index 288dcfcd9c5..c75efd74929 100644 --- a/code/modules/crafting/recipes.dm +++ b/code/modules/crafting/recipes.dm @@ -6,7 +6,6 @@ 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 var/category = CAT_MISC // Recipe category /datum/crafting_recipe/proc/AdjustChems(var/obj/resultobj as obj) @@ -308,4 +307,11 @@ time = 20 reqs = list(/obj/item/stack/sheet/mineral/bananium = 5, /obj/item/weapon/bikehorn) - category = CAT_MISC \ No newline at end of file + category = CAT_MISC + +/datum/crafting_recipe/bonfire + name = "Bonfire" + time = 60 + reqs = list(/obj/item/weapon/grown/log = 5) + result = /obj/structure/bonfire + category = CAT_PRIMAL \ No newline at end of file diff --git a/code/modules/customitems/item_defines.dm b/code/modules/customitems/item_defines.dm index df0f6916530..97d010439c9 100644 --- a/code/modules/customitems/item_defines.dm +++ b/code/modules/customitems/item_defines.dm @@ -154,6 +154,14 @@ icon_on = "guessipon" icon_off = "guessip" +/obj/item/weapon/lighter/zippo/fluff/duckchan // Duckchan: Rybys Romney + name = "Monogrammed Zippo" + desc = " A shiny purple zippo lighter, engraved with Rybys Romney and BuzzPing's name, with a festive green flame." + icon = 'icons/obj/custom_items.dmi' + icon_state = "rybysfluff" + icon_on = "rybysfluffopen" + icon_off = "rybysfluff" + /obj/item/weapon/fluff/dogwhistle //phantasmicdream: Zeke Varloss name = "Sax's whistle" desc = "This whistle seems to have a strange aura about it. Maybe you should blow on it?" @@ -376,6 +384,18 @@ icon_state = "kakicharakiti" //////////// Suits //////////// +/obj/item/clothing/suit/fluff/dusty_jacket //ComputerlessCitizen: Screech + name = "Dusty Jacket" + desc = "A worn leather jacket. Some burn holes have been patched." + body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS + icon = 'icons/obj/custom_items.dmi' + icon_state = "dusty_jacket" + ignore_suitadjust = 1 + actions_types = list() + adjust_flavour = null + species_fit = null + sprite_sheets = null + /obj/item/clothing/suit/storage/labcoat/fluff/aeneas_rinil //Socialsystem: Lynn Fea name = "Robotics labcoat" desc = "A labcoat with a few markings denoting it as the labcoat of roboticist." diff --git a/code/modules/events/alien_infestation.dm b/code/modules/events/alien_infestation.dm index 3bc26b52799..ed8b8d52ccd 100644 --- a/code/modules/events/alien_infestation.dm +++ b/code/modules/events/alien_infestation.dm @@ -10,7 +10,7 @@ /datum/event/alien_infestation/announce() if(successSpawn) - command_announcement.Announce("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert", new_sound = 'sound/AI/aliens.ogg') + event_announcement.Announce("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert", new_sound = 'sound/AI/aliens.ogg') /datum/event/alien_infestation/start() var/list/vents = list() @@ -29,6 +29,8 @@ respawnable_list -= C.client var/mob/living/carbon/alien/larva/new_xeno = new(vent.loc) new_xeno.key = C.key + if(ticker && ticker.mode) + ticker.mode.xenos += new_xeno.mind spawncount-- successSpawn = 1 diff --git a/code/modules/events/anomaly.dm b/code/modules/events/anomaly.dm index a1f951f5747..0349d09d0b8 100644 --- a/code/modules/events/anomaly.dm +++ b/code/modules/events/anomaly.dm @@ -15,7 +15,7 @@ setup(safety_loop) /datum/event/anomaly/announce() - command_announcement.Announce("Localized hyper-energetic flux wave detected on long range scanners. Expected location of impact: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("Localized hyper-energetic flux wave detected on long range scanners. Expected location of impact: [impact_area.name].", "Anomaly Alert") /datum/event/anomaly/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/anomaly_bluespace.dm b/code/modules/events/anomaly_bluespace.dm index 65b005c2538..e5327d92b16 100644 --- a/code/modules/events/anomaly_bluespace.dm +++ b/code/modules/events/anomaly_bluespace.dm @@ -4,7 +4,7 @@ endWhen = 160 /datum/event/anomaly/anomaly_bluespace/announce() - command_announcement.Announce("Unstable bluespace anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("Unstable bluespace anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") /datum/event/anomaly/anomaly_bluespace/start() var/turf/T = pick(get_area_turfs(impact_area)) @@ -33,7 +33,7 @@ var/turf/TO = get_turf(chosen) // the turf of origin we're travelling TO playsound(TO, 'sound/effects/phasein.ogg', 100, 1) - command_announcement.Announce("Massive bluespace translocation detected.", "Anomaly Alert") + event_announcement.Announce("Massive bluespace translocation detected.", "Anomaly Alert") var/list/flashers = list() for(var/mob/living/carbon/C in viewers(TO, null)) diff --git a/code/modules/events/anomaly_flux.dm b/code/modules/events/anomaly_flux.dm index b7a14ab9327..e5cebbff40d 100644 --- a/code/modules/events/anomaly_flux.dm +++ b/code/modules/events/anomaly_flux.dm @@ -4,7 +4,7 @@ endWhen = 180 /datum/event/anomaly/anomaly_flux/announce() - command_announcement.Announce("Localized hyper-energetic flux wave detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("Localized hyper-energetic flux wave detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") /datum/event/anomaly/anomaly_flux/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/anomaly_grav.dm b/code/modules/events/anomaly_grav.dm index 0c9f3776f82..19fe7a41525 100644 --- a/code/modules/events/anomaly_grav.dm +++ b/code/modules/events/anomaly_grav.dm @@ -4,7 +4,7 @@ endWhen = 70 /datum/event/anomaly/anomaly_grav/announce() - command_announcement.Announce("Gravitational anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("Gravitational anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") /datum/event/anomaly/anomaly_grav/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/anomaly_pyro.dm b/code/modules/events/anomaly_pyro.dm index b1cf81b23c3..3c2e6025952 100644 --- a/code/modules/events/anomaly_pyro.dm +++ b/code/modules/events/anomaly_pyro.dm @@ -4,7 +4,7 @@ endWhen = 110 /datum/event/anomaly/anomaly_pyro/announce() - command_announcement.Announce("Atmospheric anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("Atmospheric anomaly detected on long range scanners. Expected location: [impact_area.name].", "Anomaly Alert") /datum/event/anomaly/anomaly_pyro/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/anomaly_vortex.dm b/code/modules/events/anomaly_vortex.dm index c950444978e..662669509cb 100644 --- a/code/modules/events/anomaly_vortex.dm +++ b/code/modules/events/anomaly_vortex.dm @@ -4,7 +4,7 @@ endWhen = 80 /datum/event/anomaly/anomaly_vortex/announce() - command_announcement.Announce("Localized high-intensity vortex anomaly detected on long range scanners. Expected location: [impact_area.name]", "Anomaly Alert") + event_announcement.Announce("Localized high-intensity vortex anomaly detected on long range scanners. Expected location: [impact_area.name]", "Anomaly Alert") /datum/event/anomaly/anomaly_vortex/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/blob.dm b/code/modules/events/blob.dm index 3fc9d3f1bdc..0bb69c693bb 100644 --- a/code/modules/events/blob.dm +++ b/code/modules/events/blob.dm @@ -4,7 +4,7 @@ var/obj/effect/blob/core/Blob /datum/event/blob/announce() - command_announcement.Announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/AI/outbreak5.ogg') + event_announcement.Announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/AI/outbreak5.ogg') /datum/event/blob/start() var/turf/T = pick(blobstart) diff --git a/code/modules/events/brand_intelligence.dm b/code/modules/events/brand_intelligence.dm index d640bca8641..8245f24b291 100644 --- a/code/modules/events/brand_intelligence.dm +++ b/code/modules/events/brand_intelligence.dm @@ -14,7 +14,7 @@ "You don't want to buy anything? Yeah, well I didn't want to buy your mom either.") /datum/event/brand_intelligence/announce() - command_announcement.Announce("Rampant brand intelligence has been detected aboard [station_name()], please stand-by. The origin is believed to be \a [originMachine.name].", "Machine Learning Alert") + event_announcement.Announce("Rampant brand intelligence has been detected aboard [station_name()], please stand-by. The origin is believed to be \a [originMachine.name].", "Machine Learning Alert") /datum/event/brand_intelligence/start() for(var/obj/machinery/vending/V in machines) diff --git a/code/modules/events/cargobonus.dm b/code/modules/events/cargobonus.dm index 75276615a40..c51c7ff41a8 100644 --- a/code/modules/events/cargobonus.dm +++ b/code/modules/events/cargobonus.dm @@ -2,7 +2,7 @@ announceWhen = 5 /datum/event/cargo_bonus/announce() - command_announcement.Announce("Congratulations! [station_name()] was chosen for a supply limit increase. Please contact the local cargo department for details!", "Supply Alert") + event_announcement.Announce("Congratulations! [station_name()] was chosen for a supply limit increase. Please contact the local cargo department for details!", "Supply Alert") /datum/event/cargo_bonus/start() supply_controller.points += rand(100,500) \ No newline at end of file diff --git a/code/modules/events/carp_migration.dm b/code/modules/events/carp_migration.dm index 13b5c884131..abab5c39254 100644 --- a/code/modules/events/carp_migration.dm +++ b/code/modules/events/carp_migration.dm @@ -14,7 +14,7 @@ announcement = "Massive migration of unknown biological entities has been detected near [station_name()], please stand-by." else announcement = "Unknown biological [spawned_carp.len == 1 ? "entity has" : "entities have"] been detected near [station_name()], please stand-by." - command_announcement.Announce(announcement, "Lifesign Alert") + event_announcement.Announce(announcement, "Lifesign Alert") /datum/event/carp_migration/start() if(severity == EVENT_LEVEL_MAJOR) diff --git a/code/modules/events/communications_blackout.dm b/code/modules/events/communications_blackout.dm index 6ada1a25c0f..1b499027150 100644 --- a/code/modules/events/communications_blackout.dm +++ b/code/modules/events/communications_blackout.dm @@ -12,7 +12,7 @@ to_chat(A, " ") if(prob(30)) //most of the time, we don't want an announcement, so as to allow AIs to fake blackouts. - command_announcement.Announce(alert) + event_announcement.Announce(alert) /datum/event/communications_blackout/start() for(var/obj/machinery/telecomms/T in telecomms_list) @@ -20,7 +20,7 @@ /proc/communications_blackout(var/silent = 1) if(!silent) - command_announcement.Announce("Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT", new_sound = 'sound/misc/interference.ogg') + event_announcement.Announce("Ionospheric anomalies detected. Temporary telecommunication failure imminent. Please contact you-BZZT", new_sound = 'sound/misc/interference.ogg') else // AIs will always know if there's a comm blackout, rogue AIs could then lie about comm blackouts in the future while they shutdown comms for(var/mob/living/silicon/ai/A in player_list) to_chat(A, " ") diff --git a/code/modules/events/disease_outbreak.dm b/code/modules/events/disease_outbreak.dm index e8483ccc4ca..069ef9865af 100644 --- a/code/modules/events/disease_outbreak.dm +++ b/code/modules/events/disease_outbreak.dm @@ -7,7 +7,7 @@ announceWhen = rand(15, 30) /datum/event/disease_outbreak/announce() - command_announcement.Announce("Confirmed outbreak of level 7 major viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg') + event_announcement.Announce("Confirmed outbreak of level 7 major viral biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg') /datum/event/disease_outbreak/start() if(!virus_type) diff --git a/code/modules/events/electrical_storm.dm b/code/modules/events/electrical_storm.dm index c0ef182571b..94ef81ceee5 100644 --- a/code/modules/events/electrical_storm.dm +++ b/code/modules/events/electrical_storm.dm @@ -3,7 +3,7 @@ var/lightsoutRange = 25 /datum/event/electrical_storm/announce() - command_announcement.Announce("An electrical storm has been detected in your area, please repair potential electronic overloads.", "Electrical Storm Alert") + event_announcement.Announce("An electrical storm has been detected in your area, please repair potential electronic overloads.", "Electrical Storm Alert") /datum/event/electrical_storm/start() var/list/epicentreList = list() diff --git a/code/modules/events/grid_check.dm b/code/modules/events/grid_check.dm index 5a892efb691..db9dd4c6955 100644 --- a/code/modules/events/grid_check.dm +++ b/code/modules/events/grid_check.dm @@ -8,14 +8,14 @@ power_failure(0) /datum/event/grid_check/announce() - command_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Automated Grid Check", new_sound = 'sound/AI/poweroff.ogg') + event_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Automated Grid Check", new_sound = 'sound/AI/poweroff.ogg') /datum/event/grid_check/end() power_restore() /proc/power_failure(var/announce = 1) if(announce) - command_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Critical Power Failure", new_sound = 'sound/AI/poweroff.ogg') + event_announcement.Announce("Abnormal activity detected in [station_name()]'s powernet. As a precautionary measure, the station's power will be shut off for an indeterminate duration.", "Critical Power Failure", new_sound = 'sound/AI/poweroff.ogg') var/list/skipped_areas = list(/area/turret_protected/ai) var/list/skipped_areas_apc = list(/area/engine/engineering) @@ -45,7 +45,7 @@ var/list/skipped_areas_apc = list(/area/engine/engineering) if(announce) - command_announcement.Announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg') + event_announcement.Announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg') for(var/obj/machinery/power/apc/C in apcs) var/area/current_area = get_area(C) if(current_area.type in skipped_areas_apc || !is_station_level(C.z)) @@ -64,7 +64,7 @@ /proc/power_restore_quick(var/announce = 1) if(announce) - command_announcement.Announce("All SMESs on [station_name()] have been recharged. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg') + event_announcement.Announce("All SMESs on [station_name()] have been recharged. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg') for(var/obj/machinery/power/smes/S in machines) if(!is_station_level(S.z)) continue diff --git a/code/modules/events/immovable_rod.dm b/code/modules/events/immovable_rod.dm index 3012b0f9535..f7c48c88e23 100644 --- a/code/modules/events/immovable_rod.dm +++ b/code/modules/events/immovable_rod.dm @@ -11,7 +11,7 @@ In my current plan for it, 'solid' will be defined as anything with density == 1 announceWhen = 5 /datum/event/immovable_rod/announce() - command_announcement.Announce("What the fuck was that?!", "General Alert") + event_announcement.Announce("What the fuck was that?!", "General Alert") /datum/event/immovable_rod/start() var/startside = pick(cardinal) @@ -34,8 +34,13 @@ In my current plan for it, 'solid' will be defined as anything with density == 1 loc = start z_original = z destination = end + poi_list |= src if(end && end.z==z_original) walk_towards(src, destination, 1) + +/obj/effect/immovablerod/Destroy() + poi_list.Remove(src) + return ..() /obj/effect/immovablerod/Move() if(z != z_original || loc == destination) diff --git a/code/modules/events/infestation.dm b/code/modules/events/infestation.dm index ee2aa2de868..8e4a5834ba2 100644 --- a/code/modules/events/infestation.dm +++ b/code/modules/events/infestation.dm @@ -97,7 +97,7 @@ /datum/event/infestation/announce() - command_announcement.Announce("Bioscans indicate that [vermstring] have been breeding in [locstring]. Clear them out, before this starts to affect productivity.", "Lifesign Alert") + event_announcement.Announce("Bioscans indicate that [vermstring] have been breeding in [locstring]. Clear them out, before this starts to affect productivity.", "Lifesign Alert") #undef LOC_KITCHEN #undef LOC_ATMOS diff --git a/code/modules/events/ion_storm.dm b/code/modules/events/ion_storm.dm index 20a53a4413f..4979b0889ed 100644 --- a/code/modules/events/ion_storm.dm +++ b/code/modules/events/ion_storm.dm @@ -17,7 +17,7 @@ /datum/event/ion_storm/announce() if(announceEvent == ION_ANNOUNCE || (announceEvent == ION_RANDOM && prob(ionAnnounceChance))) - command_announcement.Announce("Ion storm detected near the station. Please check all AI-controlled equipment for errors.", "Anomaly Alert", 'sound/AI/ionstorm.ogg') + event_announcement.Announce("Ion storm detected near the station. Please check all AI-controlled equipment for errors.", "Anomaly Alert", 'sound/AI/ionstorm.ogg') /datum/event/ion_storm/start() diff --git a/code/modules/events/mass_hallucination.dm b/code/modules/events/mass_hallucination.dm index a3f302cff9f..500350a037c 100644 --- a/code/modules/events/mass_hallucination.dm +++ b/code/modules/events/mass_hallucination.dm @@ -9,4 +9,4 @@ H.AdjustHallucinate(rand(50, 100)) /datum/event/mass_hallucination/announce() - command_announcement.Announce("It seems that station [station_name()] is passing through a minor radiation field, this may cause some hallucination, but no further damage") + event_announcement.Announce("It seems that station [station_name()] is passing through a minor radiation field, this may cause some hallucination, but no further damage") diff --git a/code/modules/events/meaty_gore.dm b/code/modules/events/meaty_gore.dm index 729f5182344..b9cb43deb99 100644 --- a/code/modules/events/meaty_gore.dm +++ b/code/modules/events/meaty_gore.dm @@ -1,5 +1,5 @@ /datum/event/meteor_wave/gore/announce() - command_announcement.Announce("Unknown biological debris have been detected near [station_name()], please stand-by.", "Debris Alert") + event_announcement.Announce("Unknown biological debris have been detected near [station_name()], please stand-by.", "Debris Alert") /datum/event/meteor_wave/gore/setup() waves = 3 @@ -14,4 +14,4 @@ /datum/event/meteor_wave/gore/end() - command_announcement.Announce("The station has cleared the debris.", "Debris Alert") + event_announcement.Announce("The station has cleared the debris.", "Debris Alert") diff --git a/code/modules/events/meaty_ops.dm b/code/modules/events/meaty_ops.dm index 19263c75f82..d92e79edea9 100644 --- a/code/modules/events/meaty_ops.dm +++ b/code/modules/events/meaty_ops.dm @@ -1,6 +1,6 @@ /datum/event/meteor_wave/goreop/announce() var/meteor_declaration = "MeteorOps have declared their intent to utterly destroy [station_name()] with their own bodies, and dares the crew to try and stop them." - command_announcement.Announce(meteor_declaration, "Declaration of 'War'", 'sound/effects/siren.ogg') + event_announcement.Announce(meteor_declaration, "Declaration of 'War'", 'sound/effects/siren.ogg') /datum/event/meteor_wave/goreop/setup() waves = 3 @@ -16,4 +16,4 @@ /datum/event/meteor_wave/goreops/end() - command_announcement.Announce("All MeteorOps are dead. Major Station Victory.", "MeteorOps") \ No newline at end of file + event_announcement.Announce("All MeteorOps are dead. Major Station Victory.", "MeteorOps") \ No newline at end of file diff --git a/code/modules/events/meaty_ores.dm b/code/modules/events/meaty_ores.dm index df56749734e..48d24ebeef1 100644 --- a/code/modules/events/meaty_ores.dm +++ b/code/modules/events/meaty_ores.dm @@ -1,8 +1,8 @@ /datum/event/dust/meaty/announce() if(prob(16)) - command_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert") + event_announcement.Announce("Unknown biological entities have been detected near [station_name()], please stand-by.", "Lifesign Alert") else - command_announcement.Announce("Meaty ores have been detected on collision course with the station.", "Meaty Ore Alert", new_sound = 'sound/AI/meteors.ogg') + event_announcement.Announce("Meaty ores have been detected on collision course with the station.", "Meaty Ore Alert", new_sound = 'sound/AI/meteors.ogg') /datum/event/dust/meaty/setup() qnty = rand(45,125) diff --git a/code/modules/events/meteors.dm b/code/modules/events/meteors.dm index d26e43dba6b..b21e02bd7fa 100644 --- a/code/modules/events/meteors.dm +++ b/code/modules/events/meteors.dm @@ -10,9 +10,9 @@ /datum/event/meteor_wave/announce() switch(severity) if(EVENT_LEVEL_MAJOR) - command_announcement.Announce("Meteors have been detected on collision course with the station.", "Meteor Alert", new_sound = 'sound/AI/meteors.ogg') + event_announcement.Announce("Meteors have been detected on collision course with the station.", "Meteor Alert", new_sound = 'sound/AI/meteors.ogg') else - command_announcement.Announce("The station is now in a meteor shower.", "Meteor Alert") + event_announcement.Announce("The station is now in a meteor shower.", "Meteor Alert") //meteor showers are lighter and more common, /datum/event/meteor_wave/tick() @@ -25,9 +25,9 @@ /datum/event/meteor_wave/end() switch(severity) if(EVENT_LEVEL_MAJOR) - command_announcement.Announce("The station has cleared the meteor storm.", "Meteor Alert") + event_announcement.Announce("The station has cleared the meteor storm.", "Meteor Alert") else - command_announcement.Announce("The station has cleared the meteor shower", "Meteor Alert") + event_announcement.Announce("The station has cleared the meteor shower", "Meteor Alert") /datum/event/meteor_wave/proc/get_meteors() switch(severity) diff --git a/code/modules/events/prison_break.dm b/code/modules/events/prison_break.dm index 340ca836e94..8f16d2636ea 100644 --- a/code/modules/events/prison_break.dm +++ b/code/modules/events/prison_break.dm @@ -37,7 +37,7 @@ /datum/event/prison_break/announce() if(areas && areas.len > 0) - command_announcement.Announce("[pick("Gr3y.T1d3 virus","Malignant trojan")] detected in [station_name()] [(eventDept == "Security")? "imprisonment":"containment"] subroutines. Secure any compromised areas immediately. Station AI involvement is recommended.", "[eventDept] Alert") + event_announcement.Announce("[pick("Gr3y.T1d3 virus","Malignant trojan")] detected in [station_name()] [(eventDept == "Security")? "imprisonment":"containment"] subroutines. Secure any compromised areas immediately. Station AI involvement is recommended.", "[eventDept] Alert") /datum/event/prison_break/start() for(var/area/A in world) diff --git a/code/modules/events/radiation_storm.dm b/code/modules/events/radiation_storm.dm index 7968e2493cf..2e090979ce6 100644 --- a/code/modules/events/radiation_storm.dm +++ b/code/modules/events/radiation_storm.dm @@ -21,7 +21,7 @@ /datum/event/radiation_storm/start() spawn() - command_announcement.Announce("High levels of radiation detected near the station. Please evacuate into one of the shielded maintenance tunnels.", "Anomaly Alert", new_sound = 'sound/AI/radiation.ogg') + event_announcement.Announce("High levels of radiation detected near the station. Please evacuate into one of the shielded maintenance tunnels.", "Anomaly Alert", new_sound = 'sound/AI/radiation.ogg') for(var/area/A in world) if(!is_station_level(A.z) || is_safe_zone(A)) @@ -32,7 +32,7 @@ sleep(600) - command_announcement.Announce("The station has entered the radiation belt. Please remain in a sheltered area until we have passed the radiation belt.", "Anomaly Alert") + event_announcement.Announce("The station has entered the radiation belt. Please remain in a sheltered area until we have passed the radiation belt.", "Anomaly Alert") for(var/i = 0, i < 10, i++) for(var/mob/living/carbon/human/H in living_mob_list) @@ -58,7 +58,7 @@ sleep(100) - command_announcement.Announce("The station has passed the radiation belt. Please report to medbay if you experience any unusual symptoms. Maintenance will lose all access again shortly.", "Anomaly Alert") + event_announcement.Announce("The station has passed the radiation belt. Please report to medbay if you experience any unusual symptoms. Maintenance will lose all access again shortly.", "Anomaly Alert") for(var/area/A in world) if(!is_station_level(A.z) || is_safe_zone(A)) diff --git a/code/modules/events/rogue_drones.dm b/code/modules/events/rogue_drones.dm index 9b7386fe470..3a770bf7864 100644 --- a/code/modules/events/rogue_drones.dm +++ b/code/modules/events/rogue_drones.dm @@ -30,7 +30,7 @@ msg = "Contact has been lost with a combat drone wing operating out of the NSV Icarus. If any are sighted in the area, approach with caution." else msg = "Unidentified hackers have targetted a combat drone wing deployed from the NSV Icarus. If any are sighted in the area, approach with caution." - command_announcement.Announce(msg, "Rogue drone alert") + event_announcement.Announce(msg, "Rogue drone alert") /datum/event/rogue_drone/tick() return @@ -48,6 +48,6 @@ num_recovered++ if(num_recovered > drones_list.len * 0.75) - command_announcement.Announce("Icarus drone control reports the malfunctioning wing has been recovered safely.", "Rogue drone alert") + event_announcement.Announce("Icarus drone control reports the malfunctioning wing has been recovered safely.", "Rogue drone alert") else - command_announcement.Announce("Icarus drone control registers disappointment at the loss of the drones, but the survivors have been recovered.", "Rogue drone alert") + event_announcement.Announce("Icarus drone control registers disappointment at the loss of the drones, but the survivors have been recovered.", "Rogue drone alert") diff --git a/code/modules/events/spacevine.dm b/code/modules/events/spacevine.dm index cf00e4f78b9..61ba1b5350d 100644 --- a/code/modules/events/spacevine.dm +++ b/code/modules/events/spacevine.dm @@ -1,11 +1,570 @@ -/var/global/spacevines_spawned = 0 - -/datum/event/spacevine - announceWhen = 10 +//Types of usual mutations +#define POSITIVE 1 +#define NEGATIVE 2 +#define MINOR_NEGATIVE 3 /datum/event/spacevine/start() - spacevine_infestation() - spacevines_spawned = 1 + var/list/turfs = list() //list of all the empty floor turfs in the hallway areas -/datum/event/spacevine/announce() - command_announcement.Announce("Confirmed outbreak of level 7 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", new_sound = 'sound/AI/outbreak7.ogg') + var/obj/effect/spacevine/SV = new() + + for(var/area/hallway/A in world) + for(var/turf/F in A) + if(F.Enter(SV)) + turfs += F + + qdel(SV) + + if(turfs.len) //Pick a turf to spawn at if we can + var/turf/T = pick(turfs) + new/obj/effect/spacevine_controller(T) //spawn a controller at turf + + +/datum/spacevine_mutation + var/name = "" + var/severity = 1 + var/hue + var/quality + +/datum/spacevine_mutation/proc/add_mutation_to_vinepiece(obj/effect/spacevine/holder) + holder.mutations |= src + holder.color = hue + +/datum/spacevine_mutation/proc/process_mutation(obj/effect/spacevine/holder) + return + +/datum/spacevine_mutation/proc/process_temperature(obj/effect/spacevine/holder, temp, volume) + return + +/datum/spacevine_mutation/proc/on_birth(obj/effect/spacevine/holder) + return + +/datum/spacevine_mutation/proc/on_grow(obj/effect/spacevine/holder) + return + +/datum/spacevine_mutation/proc/on_death(obj/effect/spacevine/holder) + return + +/datum/spacevine_mutation/proc/on_hit(obj/effect/spacevine/holder, mob/hitter, obj/item/I, expected_damage) + . = expected_damage + +/datum/spacevine_mutation/proc/on_cross(obj/effect/spacevine/holder, mob/crosser) + return + +/datum/spacevine_mutation/proc/on_chem(obj/effect/spacevine/holder, datum/reagent/R) + return + +/datum/spacevine_mutation/proc/on_eat(obj/effect/spacevine/holder, mob/living/eater) + return + +/datum/spacevine_mutation/proc/on_spread(obj/effect/spacevine/holder, turf/target) + return + +/datum/spacevine_mutation/proc/on_buckle(obj/effect/spacevine/holder, mob/living/buckled) + return + +/datum/spacevine_mutation/proc/on_explosion(severity, obj/effect/spacevine/holder) + return + + +/datum/spacevine_mutation/space_covering + name = "space protective" + hue = "#aa77aa" + quality = POSITIVE + +/turf/simulated/floor/vines + color = "#aa77aa" + icon_state = "vinefloor" + broken_states = list() + + +//All of this shit is useless for vines + +/turf/simulated/floor/vines/attackby() + return + +/turf/simulated/floor/vines/burn_tile() + return + +/turf/simulated/floor/vines/break_tile() + return + +/turf/simulated/floor/vines/make_plating() + return + +/turf/simulated/floor/vines/break_tile_to_plating() + return + +/turf/simulated/floor/vines/ex_act(severity) + if(severity < 3) + ChangeTurf(baseturf) + +/turf/simulated/floor/vines/narsie_act() + if(prob(20)) + ChangeTurf(baseturf) //nar sie eats this shit + +/turf/simulated/floor/vines/singularity_pull(S, current_size) + if(current_size >= STAGE_FIVE) + if(prob(50)) + ChangeTurf(baseturf) + +/turf/simulated/floor/vines/ChangeTurf(turf/open/floor/T) + . = ..() + //Do this *after* the turf has changed as qdel in spacevines will call changeturf again if it hasn't + for(var/obj/effect/spacevine/SV in src) + qdel(SV) + +/datum/spacevine_mutation/space_covering + var/static/list/coverable_turfs + +/datum/spacevine_mutation/space_covering/New() + . = ..() + if(!coverable_turfs) + coverable_turfs = typecacheof(list( + /turf/space + )) + coverable_turfs -= typecacheof(list( + /turf/space/transit + )) + +/datum/spacevine_mutation/space_covering/on_grow(obj/effect/spacevine/holder) + process_mutation(holder) + +/datum/spacevine_mutation/space_covering/process_mutation(obj/effect/spacevine/holder) + var/turf/T = get_turf(holder) + if(is_type_in_typecache(T, coverable_turfs)) + var/currtype = T.type + T.ChangeTurf(/turf/simulated/floor/vines) + T.baseturf = currtype + +/datum/spacevine_mutation/space_covering/on_death(obj/effect/spacevine/holder) + var/turf/T = get_turf(holder) + if(istype(T, /turf/simulated/floor/vines)) + T.ChangeTurf(T.baseturf) + +/datum/spacevine_mutation/bluespace + name = "bluespace" + hue = "#3333ff" + quality = MINOR_NEGATIVE + +/datum/spacevine_mutation/bluespace/on_spread(obj/effect/spacevine/holder, turf/target) + if(holder.energy > 1 && !locate(/obj/effect/spacevine) in target) + holder.master.spawn_spacevine_piece(target, holder) + +/datum/spacevine_mutation/light + name = "light" + hue = "#ffff00" + quality = POSITIVE + severity = 4 + +/datum/spacevine_mutation/light/on_grow(obj/effect/spacevine/holder) + if(holder.energy) + holder.set_light(severity) + +/datum/spacevine_mutation/toxicity + name = "toxic" + hue = "#ff00ff" + severity = 10 + quality = NEGATIVE + +/datum/spacevine_mutation/toxicity/on_cross(obj/effect/spacevine/holder, mob/living/crosser) + if(issilicon(crosser)) + return + if(prob(severity) && istype(crosser) && !isvineimmune(crosser)) + to_chat(crosser, "You accidently touch the vine and feel a strange sensation.") + crosser.adjustToxLoss(5) + +/datum/spacevine_mutation/toxicity/on_eat(obj/effect/spacevine/holder, mob/living/eater) + if(!isvineimmune(eater)) + eater.adjustToxLoss(5) + +/datum/spacevine_mutation/explosive //OH SHIT IT CAN CHAINREACT RUN!!! + name = "explosive" + hue = "#ff0000" + quality = NEGATIVE + severity = 2 + +/datum/spacevine_mutation/explosive/on_explosion(explosion_severity, obj/effect/spacevine/holder) + if(explosion_severity < 3) + qdel(holder) + else + . = 1 + spawn(5) + qdel(holder) + +/datum/spacevine_mutation/explosive/on_death(obj/effect/spacevine/holder, mob/hitter, obj/item/I) + explosion(holder.loc, 0, 0, severity, 0, 0) + +/datum/spacevine_mutation/fire_proof + name = "fire proof" + hue = "#ff8888" + quality = MINOR_NEGATIVE + +/datum/spacevine_mutation/fire_proof/process_temperature(obj/effect/spacevine/holder, temp, volume) + return 1 + +/datum/spacevine_mutation/fire_proof/on_hit(obj/effect/spacevine/holder, mob/hitter, obj/item/I, expected_damage) + if(I && I.damtype == "fire") + . = 0 + else + . = expected_damage + +/datum/spacevine_mutation/vine_eating + name = "vine eating" + hue = "#ff7700" + quality = MINOR_NEGATIVE + +/datum/spacevine_mutation/vine_eating/on_spread(obj/effect/spacevine/holder, turf/target) + var/obj/effect/spacevine/prey = locate() in target + if(prey && !prey.mutations.Find(src)) //Eat all vines that are not of the same origin + qdel(prey) + +/datum/spacevine_mutation/aggressive_spread //very OP, but im out of other ideas currently + name = "aggressive spreading" + hue = "#333333" + severity = 3 + quality = NEGATIVE + +/datum/spacevine_mutation/aggressive_spread/on_spread(obj/effect/spacevine/holder, turf/target) + target.ex_act(severity) // vine immunity handled at /mob/ex_act + +/datum/spacevine_mutation/aggressive_spread/on_buckle(obj/effect/spacevine/holder, mob/living/buckled) + buckled.ex_act(severity) + +/datum/spacevine_mutation/transparency + name = "transparent" + hue = "" + quality = POSITIVE + +/datum/spacevine_mutation/transparency/on_grow(obj/effect/spacevine/holder) + holder.set_opacity(0) + holder.alpha = 125 + +/datum/spacevine_mutation/thorns + name = "thorny" + hue = "#666666" + severity = 10 + quality = NEGATIVE + +/datum/spacevine_mutation/thorns/on_cross(obj/effect/spacevine/holder, mob/living/crosser) + if(prob(severity) && istype(crosser) && !isvineimmune(holder)) + var/mob/living/M = crosser + M.adjustBruteLoss(5) + to_chat(M, "You cut yourself on the thorny vines.") + +/datum/spacevine_mutation/thorns/on_hit(obj/effect/spacevine/holder, mob/living/hitter, obj/item/I, expected_damage) + if(prob(severity) && istype(hitter) && !isvineimmune(holder)) + var/mob/living/M = hitter + M.adjustBruteLoss(5) + to_chat(M, "You cut yourself on the thorny vines.") + . = expected_damage + +/datum/spacevine_mutation/woodening + name = "hardened" + hue = "#997700" + quality = NEGATIVE + +/datum/spacevine_mutation/woodening/on_grow(obj/effect/spacevine/holder) + if(holder.energy) + holder.density = 1 + holder.maxhealth = 100 + holder.health = holder.maxhealth + +/datum/spacevine_mutation/woodening/on_hit(obj/effect/spacevine/holder, mob/living/hitter, obj/item/I, expected_damage) + if(!is_sharp(I)) + . = expected_damage * 0.5 + else + . = expected_damage + +/datum/spacevine_mutation/flowering + name = "flowering" + hue = "#0A480D" + quality = NEGATIVE + severity = 10 + +/datum/spacevine_mutation/flowering/on_grow(obj/effect/spacevine/holder) + if(holder.energy == 2 && prob(severity) && !locate(/obj/structure/alien/resin/flower_bud_enemy) in range(5,holder)) + new /obj/structure/alien/resin/flower_bud_enemy(get_turf(holder)) + +/datum/spacevine_mutation/flowering/on_cross(obj/effect/spacevine/holder, mob/living/crosser) + if(prob(25)) + holder.entangle(crosser) + + +// SPACE VINES (Note that this code is very similar to Biomass code) +/obj/effect/spacevine + name = "space vines" + desc = "An extremely expansionistic species of vine." + icon = 'icons/effects/spacevines.dmi' + icon_state = "Light1" + anchored = 1 + density = 0 + layer = MOB_LAYER + 0.8 + mouse_opacity = 2 //Clicking anywhere on the turf is good enough + pass_flags = PASSTABLE | PASSGRILLE + var/health = 50 + var/maxhealth = 50 + var/energy = 0 + var/obj/effect/spacevine_controller/master = null + var/list/mutations = list() + +/obj/effect/spacevine/New() + ..() + color = "#ffffff" + +/obj/effect/spacevine/examine(mob/user) + ..() + var/text = "This one is a" + if(mutations.len) + for(var/A in mutations) + var/datum/spacevine_mutation/SM = A + text += " [SM.name]" + else + text += " normal" + text += " vine." + to_chat(user, text) + +/obj/effect/spacevine/Destroy() + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_death(src) + if(master) + master.vines -= src + master.growth_queue -= src + if(!master.vines.len) + var/obj/item/seeds/kudzu/KZ = new(loc) + KZ.mutations |= mutations + KZ.set_potency(master.mutativeness * 10) + KZ.set_production((master.spread_cap / initial(master.spread_cap)) * 5) + master = null + mutations.Cut() + set_opacity(0) + if(buckled_mob) + unbuckle_mob() + return ..() + +/obj/effect/spacevine/proc/add_mutation(datum/spacevine_mutation/mutation) + mutations |= mutation + color = mutation.hue + +/obj/effect/spacevine/proc/on_chem_effect(datum/reagent/R) + var/override = 0 + for(var/datum/spacevine_mutation/SM in mutations) + override += SM.on_chem(src, R) + if(!override && istype(R, /datum/reagent/glyphosate)) + if(prob(50)) + qdel(src) + +/obj/effect/spacevine/proc/eat(mob/eater) + var/override = 0 + for(var/datum/spacevine_mutation/SM in mutations) + override += SM.on_eat(src, eater) + if(!override) + if(prob(10)) + eater.say("Nom") + qdel(src) + +/obj/effect/spacevine/attackby(obj/item/weapon/W, mob/user, params) + if (!W || !user || !W.type) + return + user.changeNext_move(CLICK_CD_MELEE) + var/force = W.force + + if(istype(W, /obj/item/weapon/scythe)) + force = force * 4 + for(var/obj/effect/spacevine/B in orange(1,src)) + B.health = health - force + if(B.health < 1) + qdel(B) + + health = health - force + + if(health < 1) + qdel(src) + + return + + if(is_sharp(W)) + force = force * 4 + + if(W && W.damtype == "fire") + force = force * 4 + + for(var/datum/spacevine_mutation/SM in mutations) + force = SM.on_hit(src, user, W, force) //on_hit now takes override damage as arg and returns new value for other mutations to permutate further + + health = health - force + if(health < 1) + qdel(src) + + ..() + +/obj/effect/spacevine/Crossed(mob/crosser) + if(isliving(crosser)) + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_cross(src, crosser) + +/obj/effect/spacevine/attack_hand(mob/user) + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_hit(src, user) + user_unbuckle_mob(user, user) + +/obj/effect/spacevine/attack_alien(mob/living/user) + eat(user) + +/obj/effect/spacevine_controller + invisibility = 101 + var/list/obj/effect/spacevine/vines = list() + var/list/growth_queue = list() + var/spread_multiplier = 5 + var/spread_cap = 30 + var/list/mutations_list = list() + var/mutativeness = 1 + +/obj/effect/spacevine_controller/New(loc, list/muts, potency, production) + color = "#ffffff" + spawn_spacevine_piece(loc, , muts) + processing_objects.Add(src) + init_subtypes(/datum/spacevine_mutation/, mutations_list) + if(potency != null) + mutativeness = potency / 10 + if(production != null) + spread_cap *= production / 5 + spread_multiplier /= production / 5 + ..() + + +/obj/effect/spacevine_controller/ex_act() //only killing all vines will end this suffering + return + +/obj/effect/spacevine_controller/singularity_act() + return + +/obj/effect/spacevine_controller/singularity_pull() + return + +/obj/effect/spacevine_controller/Destroy() + processing_objects.Remove(src) + return ..() + +/obj/effect/spacevine_controller/proc/spawn_spacevine_piece(turf/location, obj/effect/spacevine/parent, list/muts) + var/obj/effect/spacevine/SV = new(location) + growth_queue += SV + vines += SV + SV.master = src + if(muts && muts.len) + for(var/datum/spacevine_mutation/M in muts) + M.add_mutation_to_vinepiece(SV) + return + if(parent) + SV.mutations |= parent.mutations + SV.color = parent.color + if(prob(mutativeness)) + var/list/random_mutations_picked = mutations_list - SV.mutations + if(random_mutations_picked.len) + var/datum/spacevine_mutation/randmut = pick(random_mutations_picked) + randmut.add_mutation_to_vinepiece(SV) + + for(var/datum/spacevine_mutation/SM in SV.mutations) + SM.on_birth(SV) + +/obj/effect/spacevine_controller/process() + if(!vines) + qdel(src) //space vines exterminated. Remove the controller + return + if(!growth_queue) + qdel(src) //Sanity check + return + + var/length = 0 + + length = min( spread_cap , max( 1 , vines.len / spread_multiplier ) ) + var/i = 0 + var/list/obj/effect/spacevine/queue_end = list() + + for(var/obj/effect/spacevine/SV in growth_queue) + if(qdeleted(SV)) + continue + i++ + queue_end += SV + growth_queue -= SV + for(var/datum/spacevine_mutation/SM in SV.mutations) + SM.process_mutation(SV) + if(SV.energy < 2) //If tile isn't fully grown + if(prob(20)) + SV.grow() + else //If tile is fully grown + SV.entangle_mob() + + //if(prob(25)) + SV.spread() + if(i >= length) + break + + growth_queue = growth_queue + queue_end + +/obj/effect/spacevine/proc/grow() + if(!energy) + icon_state = pick("Med1", "Med2", "Med3") + energy = 1 + set_opacity(1) + else + icon_state = pick("Hvy1", "Hvy2", "Hvy3") + energy = 2 + + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_grow(src) + +/obj/effect/spacevine/proc/entangle_mob() + if(!buckled_mob && prob(25)) + for(var/mob/living/V in loc) + entangle(V) + if(has_buckled_mobs()) + break //only capture one mob at a time + + +/obj/effect/spacevine/proc/entangle(mob/living/V) + if(!V || isvineimmune(V)) + return + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_buckle(src, V) + if((V.stat != DEAD) && (V.buckled != src)) //not dead or captured + to_chat(V, "The vines [pick("wind", "tangle", "tighten")] around you!") + buckle_mob(V, 1) + +/obj/effect/spacevine/proc/spread() + var/direction = pick(cardinal) + var/turf/stepturf = get_step(src,direction) + for(var/datum/spacevine_mutation/SM in mutations) + SM.on_spread(src, stepturf) + stepturf = get_step(src,direction) //in case turf changes, to make sure no runtimes happen + if(!locate(/obj/effect/spacevine, stepturf)) + if(stepturf.Enter(src)) + if(master) + master.spawn_spacevine_piece(stepturf, src) + +/obj/effect/spacevine/ex_act(severity) + var/i + for(var/datum/spacevine_mutation/SM in mutations) + i += SM.on_explosion(severity, src) + if(!i && prob(100/severity)) + qdel(src) + +/obj/effect/spacevine/temperature_expose(null, temp, volume) + var/override = 0 + for(var/datum/spacevine_mutation/SM in mutations) + override += SM.process_temperature(src, temp, volume) + if(!override) + qdel(src) + +/obj/effect/spacevine/CanPass(atom/movable/mover, turf/target, height=0) + if(isvineimmune(mover)) + . = TRUE + else + . = ..() + +/proc/isvineimmune(atom/A) + . = FALSE + if(isliving(A)) + var/mob/living/M = A + if(("vines" in M.faction) || ("plants" in M.faction)) + . = TRUE \ No newline at end of file diff --git a/code/modules/events/spider_infestation.dm b/code/modules/events/spider_infestation.dm index 2b3ffb799df..ab703f0edc9 100644 --- a/code/modules/events/spider_infestation.dm +++ b/code/modules/events/spider_infestation.dm @@ -10,7 +10,7 @@ sent_spiders_to_station = 1 /datum/event/spider_infestation/announce() - command_announcement.Announce("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert", new_sound = 'sound/AI/aliens.ogg') + event_announcement.Announce("Unidentified lifesigns detected coming aboard [station_name()]. Secure any exterior access, including ducting and ventilation.", "Lifesign Alert", new_sound = 'sound/AI/aliens.ogg') /datum/event/spider_infestation/start() diff --git a/code/modules/events/tear.dm b/code/modules/events/tear.dm index e409f6592d8..7a13c239de0 100644 --- a/code/modules/events/tear.dm +++ b/code/modules/events/tear.dm @@ -5,7 +5,7 @@ var/obj/effect/tear/TE /datum/event/tear/announce() - command_announcement.Announce("A tear in the fabric of space and time has opened. Expected location: [impact_area.name].", "Anomaly Alert") + event_announcement.Announce("A tear in the fabric of space and time has opened. Expected location: [impact_area.name].", "Anomaly Alert") /datum/event/tear/start() var/turf/T = pick(get_area_turfs(impact_area)) diff --git a/code/modules/events/vent_clog.dm b/code/modules/events/vent_clog.dm index e5679764a39..137ffc83183 100644 --- a/code/modules/events/vent_clog.dm +++ b/code/modules/events/vent_clog.dm @@ -6,7 +6,7 @@ var/list/vents = list() /datum/event/vent_clog/announce() - command_announcement.Announce("The scrubbers network is experiencing a backpressure surge. Some ejection of contents may occur.", "Atmospherics alert") + event_announcement.Announce("The scrubbers network is experiencing a backpressure surge. Some ejection of contents may occur.", "Atmospherics alert") /datum/event/vent_clog/setup() endWhen = rand(25, 100) diff --git a/code/modules/events/wallrot.dm b/code/modules/events/wallrot.dm index a246345b632..84c0ee211c4 100644 --- a/code/modules/events/wallrot.dm +++ b/code/modules/events/wallrot.dm @@ -3,7 +3,7 @@ endWhen = announceWhen + 1 /datum/event/wallrot/announce() - command_announcement.Announce("Harmful fungi detected on station. Station structures may be contaminated.", "Biohazard Alert") + event_announcement.Announce("Harmful fungi detected on station. Station structures may be contaminated.", "Biohazard Alert") /datum/event/wallrot/start() spawn() diff --git a/code/modules/events/wormholes.dm b/code/modules/events/wormholes.dm index 398994f972d..91a4612cb16 100644 --- a/code/modules/events/wormholes.dm +++ b/code/modules/events/wormholes.dm @@ -21,7 +21,7 @@ wormholes += new /obj/effect/portal/wormhole(T, null, null, -1) /datum/event/wormholes/announce() - command_announcement.Announce("Space-time anomalies detected on the station. There is no additional data.", "Anomaly Alert", new_sound = 'sound/AI/spanomalies.ogg') + event_announcement.Announce("Space-time anomalies detected on the station. There is no additional data.", "Anomaly Alert", new_sound = 'sound/AI/spanomalies.ogg') /datum/event/wormholes/tick() if(activeFor % shift_frequency == 0) diff --git a/code/modules/fish/fish_items.dm b/code/modules/fish/fish_items.dm index 0266f06df90..7d5d3bf20ce 100644 --- a/code/modules/fish/fish_items.dm +++ b/code/modules/fish/fish_items.dm @@ -1,6 +1,6 @@ var/global/list/fish_items_list = list("goldfish" = /obj/item/weapon/fish/goldfish, - "clownfish" = /obj/item/weapon/bananapeel/clownfish, + "clownfish" = /obj/item/weapon/grown/bananapeel/clownfish, "shark" = /obj/item/weapon/fish/shark, "baby space carp" = /obj/item/weapon/fish/babycarp, "catfish" = /obj/item/weapon/fish/catfish, @@ -208,7 +208,7 @@ var/global/list/fish_items_list = list("goldfish" = /obj/item/weapon/fish/goldfi ..() -/obj/item/weapon/bananapeel/clownfish +/obj/item/weapon/grown/bananapeel/clownfish name = "clown fish" desc = "Even underwater, you cannot escape HONKing." icon = 'icons/obj/fish_items.dmi' diff --git a/code/modules/food_and_drinks/drinks/bottler/bottler.dm b/code/modules/food_and_drinks/drinks/bottler/bottler.dm index c6b88b78c6c..81974b39c0e 100644 --- a/code/modules/food_and_drinks/drinks/bottler/bottler.dm +++ b/code/modules/food_and_drinks/drinks/bottler/bottler.dm @@ -213,12 +213,7 @@ for(var/i = 1, i <= slots.len, i++) var/obj/item/O = slots[i] if(istype(O, recipe.ingredients[i])) - if(istype(O, /obj/item/weapon/reagent_containers/food/snacks/grown)) - var/obj/item/weapon/reagent_containers/food/snacks/grown/G = O - if(G.seed && G.seed.kitchen_tag == recipe.tags[i]) - number_matches++ - else - number_matches++ + number_matches++ if(number_matches == 3) return recipe return null diff --git a/code/modules/food_and_drinks/drinks/bottler/bottler_recipes.dm b/code/modules/food_and_drinks/drinks/bottler/bottler_recipes.dm index be7504afade..85b3452ebfc 100644 --- a/code/modules/food_and_drinks/drinks/bottler/bottler_recipes.dm +++ b/code/modules/food_and_drinks/drinks/bottler/bottler_recipes.dm @@ -3,7 +3,6 @@ var/name = "" var/description = "" var/list/ingredients[3] - var/list/tags[3] var/datum/reagent/result = null @@ -12,12 +11,10 @@ name = "Example" description = "This is an example." ingredients = list(thing_1, thing_2, thing_3) - tags = list(null, "tag_2", null) result = "water" The ingredients list must have 3 non-null entries. -The tags list must have 3 entries, using null where a tag is unused. -Failing to ensure both lists have EXACTLY 3 entries (unless the system is updated in the future to use a different number) will result in runtimes. +Failing to ensure the list has EXACTLY 3 entries (unless the system is updated in the future to use a different number) will result in runtimes. There is no excuse to do this wrong now that there is an example for you. --FalseIncarnate */ @@ -25,62 +22,55 @@ There is no excuse to do this wrong now that there is an example for you. --Fals /datum/bottler_recipe/Paradise_Punch name = "Paradise Punch" description = "Tastes just how you'd think Paradise would if you could bottle it." - ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown) - tags = list("grapes", "banana", "cherries") + ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown/grapes, + /obj/item/weapon/reagent_containers/food/snacks/grown/banana, + /obj/item/weapon/reagent_containers/food/snacks/grown/cherries) result = "paradise_punch" /datum/bottler_recipe/Applepocalypse name = "Apple-pocalypse" description = "If doomsday came in fruit form, it'd probably be apples." - ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown) - tags = list("apple", "apple", "apple") + ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown/apple, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple) result = "apple-pocalypse" /datum/bottler_recipe/Berry_Banned name = "Berry Banned" description = "Reason for ban: Excessive Flavor." - ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown) - tags = list("berries", "berries", "berries") + ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown/berries, + /obj/item/weapon/reagent_containers/food/snacks/grown/berries, + /obj/item/weapon/reagent_containers/food/snacks/grown/berries) result = "berry_banned" /datum/bottler_recipe/Berry_Banned2 name = "Berry Banned" description = "Reason for ban: Excessive Flavor." - ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown, - /obj/item/weapon/reagent_containers/food/snacks/grown) - tags = list("poisonberries", "poisonberries", "poisonberries") + ingredients = list(/obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison, + /obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison, + /obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison) result = "berry_banned2" /datum/bottler_recipe/Blackeye_Brew name = "Blackeye Brew" description = "Creamy, smooth flavor, just like the bald heads of the masses. Supposedly aged for 30 years." ingredients = list(/obj/item/weapon/reagent_containers/food/drinks/cans/cola, - /obj/item/weapon/reagent_containers/food/snacks/grown, + /obj/item/weapon/reagent_containers/food/snacks/grown/sugarcane, /obj/item/weapon/reagent_containers/food/snacks/icecream) - tags = list(null, "sugarcane", null) result = "blackeye_brew" /datum/bottler_recipe/Grape_Granade name = "Grape Granade" description = "Exploding with grape flavor and a favorite among ERT members system-wide." ingredients = list(/obj/item/weapon/reagent_containers/food/drinks/cans/grape_juice, - /obj/item/weapon/reagent_containers/food/snacks/grown, + /obj/item/weapon/reagent_containers/food/snacks/grown/grapes, /obj/item/device/flash) - tags = list(null, "grapes", null) result = "grape_granade" /datum/bottler_recipe/Meteor_Malt name = "Meteor Malt" description = "Soft drinks have been detected on collision course with your tastebuds." ingredients = list(/obj/item/weapon/ore, - /obj/item/weapon/reagent_containers/food/snacks/grown, + /obj/item/weapon/reagent_containers/food/snacks/grown/wheat, /obj/item/weapon/ore) - tags = list(null, "wheat", null) result = "meteor_malt" diff --git a/code/modules/food_and_drinks/drinks/drinks.dm b/code/modules/food_and_drinks/drinks/drinks.dm index 0814bf988f4..eedae606007 100644 --- a/code/modules/food_and_drinks/drinks/drinks.dm +++ b/code/modules/food_and_drinks/drinks/drinks.dm @@ -331,4 +331,11 @@ name = "cup" desc = "A cup with the british flag emblazoned on it." icon_state = "britcup" - volume = 30 \ No newline at end of file + volume = 30 + +/obj/item/weapon/reagent_containers/food/drinks/mushroom_bowl + name = "mushroom bowl" + desc = "A bowl made out of mushrooms. Not food, though it might have contained some at some point." + icon = 'icons/obj/lavaland/ash_flora.dmi' + icon_state = "mushroom_bowl" + w_class = 2 \ No newline at end of file diff --git a/code/modules/food_and_drinks/food.dm b/code/modules/food_and_drinks/food.dm index f14c0d19254..4655dcba98f 100644 --- a/code/modules/food_and_drinks/food.dm +++ b/code/modules/food_and_drinks/food.dm @@ -5,7 +5,8 @@ possible_transfer_amounts = null volume = 50 //Sets the default container amount for all food items. var/filling_color = "#FFFFFF" //Used by sandwiches. - var/bitesize = 1 + var/junkiness = 0 //for junk food. used to lower human satiety. + var/bitesize = 2 var/consume_sound = 'sound/items/eatfood.ogg' var/apply_type = INGEST var/apply_method = "swallow" @@ -15,5 +16,5 @@ /obj/item/weapon/reagent_containers/food/New() ..() - pixel_x = rand(-10, 10) //Randomizes postion - pixel_y = rand(-10, 10) \ No newline at end of file + pixel_x = rand(-5, 5) //Randomizes postion + pixel_y = rand(-5, 5) \ No newline at end of file diff --git a/code/modules/food_and_drinks/food/candy.dm b/code/modules/food_and_drinks/food/candy.dm index 32a4a584a88..d0d6ab4b32d 100644 --- a/code/modules/food_and_drinks/food/candy.dm +++ b/code/modules/food_and_drinks/food/candy.dm @@ -22,7 +22,6 @@ desc = "Such sweet, fattening food." icon_state = "chocolatebar" filling_color = "#7D5F46" - bitesize = 2 list_reagents = list("nutriment" = 2, "chocolate" = 4) /obj/item/weapon/reagent_containers/food/snacks/candy/caramel @@ -30,7 +29,6 @@ desc = "Chewy and dense, yet it practically melts in your mouth!" icon_state = "caramel" filling_color = "#DB944D" - bitesize = 2 list_reagents = list("cream" = 2, "sugar" = 2) @@ -39,7 +37,6 @@ desc = "A hard, brittle candy with a distinctive taste." icon_state = "toffee" filling_color = "#7D5F46" - bitesize = 2 list_reagents = list("nutriment" = 3, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/candy/nougat @@ -47,7 +44,6 @@ desc = "A soft, chewy candy commonly found in candybars." icon_state = "nougat" filling_color = "#7D5F46" - bitesize = 2 list_reagents = list("nutriment" = 3, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/candy/taffy @@ -55,7 +51,6 @@ desc = "Old fashioned saltwater taffy. Chewy!" icon_state = "candy1" filling_color = "#7D5F46" - bitesize = 2 list_reagents = list("nutriment" = 3, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/candy/taffy/New() @@ -111,7 +106,6 @@ desc = "It's a handful of candy corn. Cannot be stored in a detective's hat, alas." icon_state = "candycorn" filling_color = "#FFFCB0" - bitesize = 2 list_reagents = list("nutriment" = 4, "sugar" = 2) // *********************************************************** @@ -134,14 +128,15 @@ trash = /obj/item/trash/candy filling_color = "#7D5F46" bitesize = 3 - list_reagents = list("nutriment" = 2, "chocolate" = 5) + junkiness = 25 + list_reagents = list("nutriment" = 1, "chocolate" = 1) + /obj/item/weapon/reagent_containers/food/snacks/candy/candycane name = "candy cane" desc = "A festive mint candy cane." icon_state = "candycane" filling_color = "#F2F2F2" - bitesize = 2 list_reagents = list("minttoxin" = 1, "sugar" = 5) /obj/item/weapon/reagent_containers/food/snacks/candy/gummybear @@ -181,7 +176,6 @@ desc = "Not legal tender. Tasty though." icon_state = "candy_cash" filling_color = "#302000" - bitesize = 2 list_reagents = list("nutriment" = 2, "chocolate" = 4) /obj/item/weapon/reagent_containers/food/snacks/candy/coin @@ -511,32 +505,35 @@ // Candybar Flavors // *********************************************************** -/obj/item/weapon/reagent_containers/food/snacks/candy/candybar/rice +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery + list_reagents = list("nutriment" = 1, "chocolate" = 1) + +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/rice name = "Asteroid Crunch Bar" desc = "Crunchy rice deposits in delicious chocolate! A favorite of miners galaxy-wide." icon_state = "asteroidcrunch" trash = /obj/item/trash/candy filling_color = "#7D5F46" -/obj/item/weapon/reagent_containers/food/snacks/candy/candybar/toffee +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/toffee name = "Yum-baton Bar" desc = "Chocolate and toffee in the shape of a baton. Security sure knows how to pound these down!" icon_state = "yumbaton" filling_color = "#7D5F46" -/obj/item/weapon/reagent_containers/food/snacks/candy/candybar/caramel +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/caramel name = "Malper Bar" desc = "A chocolate syringe filled with a caramel injection. Just what the doctor ordered!" icon_state = "malper" filling_color = "#7D5F46" -/obj/item/weapon/reagent_containers/food/snacks/candy/candybar/caramel_nougat +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/caramel_nougat name = "Toxins Test Bar" desc = "An explosive combination of chocolate, caramel, and nougat. Research has never been so tasty!" icon_state = "toxinstest" filling_color = "#7D5F46" -/obj/item/weapon/reagent_containers/food/snacks/candy/candybar/nougat +/obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/nougat name = "Tool-erone Bar" desc = "Chocolate-covered nougat, shaped like a wrench. Great for an engineer on the go!" icon_state = "toolerone" diff --git a/code/modules/food_and_drinks/food/customizables.dm b/code/modules/food_and_drinks/food/customizables.dm index 77e3f22a1e8..dfd89a809da 100644 --- a/code/modules/food_and_drinks/food/customizables.dm +++ b/code/modules/food_and_drinks/food/customizables.dm @@ -69,6 +69,7 @@ icon_state = "breadslice" var/baseicon = "sandwich" var/basename = "sandwich" + bitesize = 4 var/top = 1 //Do we have a top? var/obj/item/toptype var/add_overlays = 1 //Do we stack? @@ -76,7 +77,6 @@ var/sandwich_limit = 40 var/fullycustom = 0 trash = /obj/item/trash/plate - bitesize = 2 var/list/ingredients = list() list_reagents = list("nutriment" = 8) diff --git a/code/modules/food_and_drinks/food/meat.dm b/code/modules/food_and_drinks/food/meat.dm index 4635f6eb9b1..19d8307c906 100644 --- a/code/modules/food_and_drinks/food/meat.dm +++ b/code/modules/food_and_drinks/food/meat.dm @@ -44,4 +44,12 @@ /obj/item/weapon/reagent_containers/food/snacks/meat/ham name = "Ham" desc = "Taste like bacon." - list_reagents = list("protein" = 3, "porktonium" = 10) \ No newline at end of file + list_reagents = list("protein" = 3, "porktonium" = 10) + +/obj/item/weapon/reagent_containers/food/snacks/meat/meatwheat + name = "meatwheat clump" + desc = "This doesn't look like meat, but your standards aren't that high to begin with." + list_reagents = list("nutriment" = 3, "vitamin" = 2, "blood" = 5) + filling_color = rgb(150, 0, 0) + icon_state = "meatwheat_clump" + bitesize = 4 \ No newline at end of file diff --git a/code/modules/food_and_drinks/food/seafood.dm b/code/modules/food_and_drinks/food/seafood.dm index c0a95d39315..0a219ee2de6 100644 --- a/code/modules/food_and_drinks/food/seafood.dm +++ b/code/modules/food_and_drinks/food/seafood.dm @@ -6,7 +6,7 @@ icon_state = "fishfillet" filling_color = "#FFDEFE" bitesize = 6 - list_reagents = list("protein" = 3, "carpotoxin" = 3) + list_reagents = list("protein" = 3, "carpotoxin" = 2, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/salmonmeat name = "raw salmon" @@ -14,8 +14,8 @@ icon = 'icons/obj/food/seafood.dmi' icon_state = "fishfillet" filling_color = "#FFDEFE" - bitesize = 3 - list_reagents = list("protein" = 3) + bitesize = 6 + list_reagents = list("protein" = 3, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/salmonsteak name = "Salmon steak" @@ -25,7 +25,7 @@ trash = /obj/item/trash/plate filling_color = "#7A3D11" bitesize = 3 - list_reagents = list("nutriment" = 4, "sodiumchloride" = 1, "blackpepper" = 1) + list_reagents = list("nutriment" = 4, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/catfishmeat name = "raw catfish" @@ -33,8 +33,8 @@ icon = 'icons/obj/food/seafood.dmi' icon_state = "fishfillet" filling_color = "#FFDEFE" - bitesize = 3 - list_reagents = list("protein" = 3) + bitesize = 6 + list_reagents = list("protein" = 3, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/fishfingers name = "Fish Fingers" @@ -42,8 +42,8 @@ icon = 'icons/obj/food/seafood.dmi' icon_state = "fishfingers" filling_color = "#FFDEFE" - bitesize = 3 - list_reagents = list("nutriment" = 4, "carpotoxin" = 3) + bitesize = 1 + list_reagents = list("nutriment" = 4) /obj/item/weapon/reagent_containers/food/snacks/fishburger name = "Fillet -o- Carp Sandwich" @@ -52,7 +52,7 @@ icon_state = "fishburger" filling_color = "#FFDEFE" bitesize = 3 - list_reagents = list("nutriment" = 6, "carpotoxin" = 3) + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/cubancarp name = "Cuban Carp" @@ -62,7 +62,7 @@ trash = /obj/item/trash/plate filling_color = "#E9ADFF" bitesize = 3 - list_reagents = list("nutriment" = 6, "carpotoxin" = 3, "capsaicin" = 3) + list_reagents = list("nutriment" = 6, "capsaicin" = 1) /obj/item/weapon/reagent_containers/food/snacks/fishandchips name = "Fish and Chips" @@ -71,7 +71,7 @@ icon_state = "fishandchips" filling_color = "#E3D796" bitesize = 3 - list_reagents = list("nutriment" = 6, "carpotoxin" = 3) + list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/sashimi name = "carp sashimi" @@ -79,7 +79,7 @@ icon = 'icons/obj/food/seafood.dmi' icon_state = "sashimi" bitesize = 3 - list_reagents = list("nutriment" = 6, "toxin" = 5) + list_reagents = list("nutriment" = 6, "capsaicin" = 5) /obj/item/weapon/reagent_containers/food/snacks/fried_shrimp name = "fried shrimp" diff --git a/code/modules/food_and_drinks/food/snacks.dm b/code/modules/food_and_drinks/food/snacks.dm index 49cd0c1fa3b..aafc4fd3648 100644 --- a/code/modules/food_and_drinks/food/snacks.dm +++ b/code/modules/food_and_drinks/food/snacks.dm @@ -11,7 +11,9 @@ var/eatverb var/wrapped = 0 var/dried_type = null + var/dry = 0 var/cooktype[0] + var/cooked_type = null //for microwave cooking. path of the resulting item after microwaving //Placeholder for effect that trigger on eating that aren't tied to reagents. @@ -25,12 +27,8 @@ user.visible_message("[user] finishes eating \the [src].") user.unEquip(src) //so icons update :[ Post_Consume(M) - if(trash) - if(ispath(trash,/obj/item)) - var/obj/item/TrashItem = new trash(user) - user.put_in_hands(TrashItem) - else if(istype(trash,/obj/item)) - user.put_in_hands(trash) + var/obj/item/trash_item = generate_trash(usr) + usr.put_in_hands(trash_item) qdel(src) return @@ -47,7 +45,7 @@ qdel(src) return 0 - if(istype(M, /mob/living/carbon)) + if(iscarbon(M)) var/mob/living/carbon/C = M if(C.eat(src, user)) bitecount++ @@ -173,6 +171,19 @@ return +/obj/item/weapon/reagent_containers/food/snacks/proc/generate_trash(atom/location) + if(trash) + if(ispath(trash, /obj/item)) + . = new trash(location) + trash = null + return + else if(istype(trash, /obj/item)) + var/obj/item/trash_item = trash + trash_item.forceMove(location) + . = trash + trash = null + return + /obj/item/weapon/reagent_containers/food/snacks/Destroy() if(contents) for(var/atom/movable/something in contents) @@ -255,20 +266,23 @@ trash = /obj/item/trash/snack_bowl filling_color = "#468C00" bitesize = 3 - list_reagents = list("nutriment" = 8, "omnizine" = 8) + list_reagents = list("nutriment" = 8, "omnizine" = 8, "vitamin" = 6) /obj/item/weapon/reagent_containers/food/snacks/chips name = "chips" desc = "Commander Riker's What-The-Crisps" icon_state = "chips" + bitesize = 1 trash = /obj/item/trash/chips filling_color = "#E8C31E" - list_reagents = list("nutriment" = 3, "sodiumchloride" = 1) + junkiness = 20 + list_reagents = list("nutriment" = 1, "sodiumchloride" = 1, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/cornchips name = "corn chips" desc = "Goes great with salsa! OLE!" icon_state = "chips" + bitesize = 1 trash = /obj/item/trash/chips filling_color = "#E8C31E" list_reagents = list("nutriment" = 3) @@ -277,23 +291,22 @@ name = "cookie" desc = "COOKIE!!!" icon_state = "COOKIE!!!" + bitesize = 1 filling_color = "#DBC94F" - list_reagents = list("nutriment" = 5) + list_reagents = list("nutriment" = 1) /obj/item/weapon/reagent_containers/food/snacks/chocolatebar name = "Chocolate Bar" desc = "Such sweet, fattening food." icon_state = "chocolatebar" filling_color = "#7D5F46" - bitesize = 2 - list_reagents = list("nutriment" = 2, "chocolate" = 4) + list_reagents = list("nutriment" = 2, "sugar" = 2, "cocoa" = 2) /obj/item/weapon/reagent_containers/food/snacks/choc_pile //for reagent chocolate being spilled on turfs name = "Pile of Chocolate" desc = "A pile of pure chocolate pieces." icon_state = "cocoa" filling_color = "#7D5F46" - bitesize = 2 list_reagents = list("chocolate" = 5) /obj/item/weapon/reagent_containers/food/snacks/chocolateegg @@ -301,95 +314,75 @@ desc = "Such sweet, fattening food." icon_state = "chocolateegg" filling_color = "#7D5F46" - bitesize = 2 - list_reagents = list("nutriment" = 3, "chocolate" = 4) + list_reagents = list("nutriment" = 4, "sugar" = 2, "cocoa" = 2) /obj/item/weapon/reagent_containers/food/snacks/donut name = "donut" desc = "Goes great with Robust Coffee." icon_state = "donut1" - filling_color = "#D9C386" - bitesize = 3 + bitesize = 5 + list_reagents = list("nutriment" = 3, "sugar" = 2) + var/extra_reagent = null + filling_color = "#D2691E" + var/randomized_sprinkles = 1 -/obj/item/weapon/reagent_containers/food/snacks/donut/normal - name = "donut" - desc = "Goes great with Robust Coffee." - icon_state = "donut1" - list_reagents = list("nutriment" = 3, "sprinkles" = 1) - -/obj/item/weapon/reagent_containers/food/snacks/donut/normal/New() +/obj/item/weapon/reagent_containers/food/snacks/donut/New() ..() - if(prob(30)) + if(randomized_sprinkles && prob(30)) icon_state = "donut2" name = "frosted donut" reagents.add_reagent("sprinkles", 2) + filling_color = "#FF69B4" /obj/item/weapon/reagent_containers/food/snacks/donut/sprinkles name = "frosted donut" icon_state = "donut2" - list_reagents = list("nutriment" = 3, "sprinkles" = 3) + list_reagents = list("nutriment" = 3, "sugar" = 2, "spinkles" = 2) + filling_color = "#FF69B4" + randomized_sprinkles = 0 /obj/item/weapon/reagent_containers/food/snacks/donut/chaos - name = "Chaos Donut" + name = "chaos donut" desc = "Like life, it never quite tastes the same." - icon_state = "donut1" - filling_color = "#ED11E6" bitesize = 10 /obj/item/weapon/reagent_containers/food/snacks/donut/chaos/New() ..() - var/extra_reagent = pick("nutriment", "capsaicin", "frostoil", "sprinkles", "plasma", "chocolate", "slimejelly", "banana", "berryjuice", "omnizine") + extra_reagent = pick("nutriment", "capsaicin", "frostoil", "krokodil", "plasma", "cocoa", "slimejelly", "banana", "berryjuice", "omnizine") reagents.add_reagent("[extra_reagent]", 3) if(prob(30)) icon_state = "donut2" - name = "Frosted Chaos Donut" + name = "frosted chaos donut" reagents.add_reagent("sprinkles", 2) - + filling_color = "#FF69B4" /obj/item/weapon/reagent_containers/food/snacks/donut/jelly - name = "Jelly Donut" + name = "jelly donut" desc = "You jelly?" icon_state = "jdonut1" - filling_color = "#ED1169" - bitesize = 5 - list_reagents = list("nutriment" = 3, "sprinkles" = 1, "berryjuice" = 5) + extra_reagent = "berryjuice" /obj/item/weapon/reagent_containers/food/snacks/donut/jelly/New() ..() + if(extra_reagent) + reagents.add_reagent("[extra_reagent]", 3) if(prob(30)) icon_state = "jdonut2" - name = "Frosted Jelly Donut" + name = "frosted jelly Donut" reagents.add_reagent("sprinkles", 2) + filling_color = "#FF69B4" -/obj/item/weapon/reagent_containers/food/snacks/donut/slimejelly - name = "Jelly Donut" +/obj/item/weapon/reagent_containers/food/snacks/donut/jelly/slimejelly + name = "jelly donut" desc = "You jelly?" icon_state = "jdonut1" - filling_color = "#ED1169" - bitesize = 5 - list_reagents = list("nutriment" = 3, "sprinkles" = 1, "slimejelly" = 5) + extra_reagent = "slimejelly" -/obj/item/weapon/reagent_containers/food/snacks/donut/slimejelly/New() - ..() - if(prob(30)) - icon_state = "jdonut2" - name = "Frosted Jelly Donut" - reagents.add_reagent("sprinkles", 2) - -/obj/item/weapon/reagent_containers/food/snacks/donut/cherryjelly - name = "Jelly Donut" +/obj/item/weapon/reagent_containers/food/snacks/donut/jelly/cherryjelly + name = "jelly donut" desc = "You jelly?" icon_state = "jdonut1" - filling_color = "#ED1169" - bitesize = 5 - list_reagents = list("nutriment" = 3, "sprinkles" = 1, "cherryjelly" = 5) - -/obj/item/weapon/reagent_containers/food/snacks/donut/cherryjelly/New() - ..() - if(prob(30)) - icon_state = "jdonut2" - name = "Frosted Jelly Donut" - reagents.add_reagent("sprinkles", 2) + extra_reagent = "cherryjelly" /obj/item/weapon/reagent_containers/food/snacks/egg name = "egg" @@ -458,14 +451,15 @@ desc = "A fried egg, with a touch of salt and pepper." icon_state = "friedegg" filling_color = "#FFDF78" - list_reagents = list("nutriment" = 2, "egg" = 5, "sodiumchloride" = 1, "blackpepper" = 1) + bitesize = 1 + list_reagents = list("nutriment" = 3, "egg" = 5) /obj/item/weapon/reagent_containers/food/snacks/boiledegg name = "Boiled egg" desc = "A hard boiled egg." icon_state = "egg" filling_color = "#FFFFFF" - list_reagents = list("nutriment" = 2, "egg" = 5) + list_reagents = list("nutriment" = 2, "egg" = 5, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/organ @@ -475,7 +469,7 @@ icon_state = "appendix" filling_color = "#E00D34" bitesize = 3 - list_reagents = list("protein" = 4) + list_reagents = list("protein" = 4, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/appendix //yes, this is the same as meat. I might do something different in future @@ -485,7 +479,7 @@ icon_state = "appendix" filling_color = "#E00D34" bitesize = 3 - list_reagents = list("protein" = 3) + list_reagents = list("protein" = 3, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/appendix/inflamed name = "inflamed appendix" @@ -499,7 +493,7 @@ desc = "We all love tofu." filling_color = "#FFFEE0" bitesize = 3 - list_reagents = list("plantmatter" = 3) + list_reagents = list("plantmatter" = 2) /obj/item/weapon/reagent_containers/food/snacks/fried_tofu name = "Fried Tofu" @@ -507,7 +501,7 @@ desc = "Proof that even vegetarians crave unhealthy foods." filling_color = "#FFFEE0" bitesize = 3 - list_reagents = list("nutriment" = 3) + list_reagents = list("plantmatter" = 3) /obj/item/weapon/reagent_containers/food/snacks/tofurkey name = "Tofurkey" @@ -530,7 +524,7 @@ icon_state = "hugemushroomslice" filling_color = "#E0D7C5" bitesize = 6 - list_reagents = list("plantmatter" = 3, "psilocybin" = 3) + list_reagents = list("plantmatter" = 3, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/tomatomeat name = "tomato slice" @@ -538,7 +532,7 @@ icon_state = "tomatomeat" filling_color = "#DB0000" bitesize = 6 - list_reagents = list("protein" = 3) + list_reagents = list("protein" = 2) /obj/item/weapon/reagent_containers/food/snacks/bearmeat name = "bear meat" @@ -546,7 +540,7 @@ icon_state = "bearmeat" filling_color = "#DB0000" bitesize = 3 - list_reagents = list("protein" = 12, "methamphetamine" = 5) + list_reagents = list("protein" = 12, "morphine" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/xenomeat name = "meat" @@ -554,14 +548,14 @@ icon_state = "xenomeat" filling_color = "#43DE18" bitesize = 6 - list_reagents = list("protein" = 3) + list_reagents = list("protein" = 3, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/spidermeat name = "spider meat" desc = "A slab of spider meat." icon_state = "spidermeat" bitesize = 3 - list_reagents = list("protein" = 3, "toxin" = 3) + list_reagents = list("protein" = 3, "toxin" = 3, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/lizardmeat name = "mutant lizard meat" @@ -575,7 +569,6 @@ name = "spider leg" desc = "A still twitching leg of a giant spider... you don't really want to eat this, do you?" icon_state = "spiderleg" - bitesize = 2 list_reagents = list("protein" = 2, "toxin" = 2) /obj/item/weapon/reagent_containers/food/snacks/meatball @@ -583,16 +576,14 @@ desc = "A great meal all round." icon_state = "meatball" filling_color = "#DB0000" - bitesize = 2 - list_reagents = list("protein" = 3) + list_reagents = list("protein" = 4, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/sausage name = "Sausage" desc = "A piece of mixed, long meat." icon_state = "sausage" filling_color = "#DB0000" - bitesize = 2 - list_reagents = list("protein" = 6, "porktonium" = 10) + list_reagents = list("protein" = 6, "vitamin" = 1, "porktonium" = 10) /obj/item/weapon/reagent_containers/food/snacks/donkpocket name = "Donk-pocket" @@ -639,16 +630,16 @@ desc = "A strange looking burger. It looks almost sentient." icon_state = "brainburger" filling_color = "#F2B6EA" - bitesize = 2 - list_reagents = list("nutriment" = 6, "prions" = 10) + bitesize = 3 + list_reagents = list("nutriment" = 6, "prions" = 10, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/ghostburger name = "Ghost Burger" desc = "Spooky! It doesn't look very filling." icon_state = "ghostburger" filling_color = "#FFF2FF" - bitesize = 2 - list_reagents = list("nutriment" = 2) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/human var/hname = "" @@ -659,71 +650,72 @@ name = "-burger" desc = "A bloody burger." icon_state = "hburger" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/cheeseburger name = "cheeseburger" desc = "The cheese adds a good flavor." icon_state = "cheeseburger" - list_reagents = list("nutriment" = 2) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/monkeyburger name = "burger" desc = "The cornerstone of every nutritious breakfast." icon_state = "hburger" filling_color = "#D63C3C" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/tofuburger name = "Tofu Burger" desc = "What.. is that meat?" icon_state = "tofuburger" filling_color = "#FFFEE0" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/roburger name = "roburger" desc = "The lettuce is the only organic component. Beep." icon_state = "roburger" filling_color = "#CCCCCC" - bitesize = 2 - list_reagents = list("nutriment" = 2, "nanomachines" = 10) + bitesize = 3 + list_reagents = list("nutriment" = 6, "nanomachines" = 10, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/roburgerbig name = "roburger" desc = "This massive patty looks like poison. Beep." icon_state = "roburger" filling_color = "#CCCCCC" - volume = 100 - bitesize = 0.1 - list_reagents = list("nanomachines" = 100) + volume = 120 + bitesize = 3 + list_reagents = list("nutriment" = 6, "nanomachines" = 70, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/xenoburger name = "xenoburger" desc = "Smells caustic. Tastes like heresy." icon_state = "xburger" filling_color = "#43DE18" - bitesize = 2 - list_reagents = list("nutriment" = 8) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/clownburger name = "Clown Burger" desc = "This tastes funny..." icon_state = "clownburger" filling_color = "#FF00FF" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/mimeburger name = "Mime Burger" desc = "Its taste defies language." icon_state = "mimeburger" filling_color = "#FFFFFF" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/omelette name = "Omelette Du Fromage" @@ -731,14 +723,14 @@ icon_state = "omelette" trash = /obj/item/trash/plate filling_color = "#FFF9A8" - list_reagents = list("nutriment" = 8) + list_reagents = list("nutriment" = 8, "vitamin" = 1) + bitesize = 1 /obj/item/weapon/reagent_containers/food/snacks/muffin name = "Muffin" desc = "A delicious and spongy little cake" icon_state = "muffin" filling_color = "#E0CF9B" - bitesize = 2 list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/pie @@ -748,7 +740,7 @@ trash = /obj/item/trash/plate filling_color = "#FBFFB8" bitesize = 3 - list_reagents = list("nutriment" = 4, "banana" = 5) + list_reagents = list("nutriment" = 6, "banana" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/pie/throw_impact(atom/hit_atom) ..() @@ -762,7 +754,7 @@ icon_state = "berryclafoutis" trash = /obj/item/trash/plate bitesize = 3 - list_reagents = list("nutriment" = 4, "berryjuice" = 5) + list_reagents = list("nutriment" = 10, "berryjuice" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/waffles name = "waffles" @@ -770,8 +762,7 @@ icon_state = "waffles" trash = /obj/item/trash/waffles filling_color = "#E6DEB5" - bitesize = 2 - list_reagents = list("nutriment" = 8) + list_reagents = list("nutriment" = 8, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/eggplantparm name = "Eggplant Parmigiana" @@ -779,8 +770,7 @@ icon_state = "eggplantparm" trash = /obj/item/trash/plate filling_color = "#4D2F5E" - bitesize = 2 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 6, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/soylentgreen name = "Soylent Green" @@ -788,8 +778,7 @@ icon_state = "soylent_green" trash = /obj/item/trash/waffles filling_color = "#B8E6B5" - bitesize = 2 - list_reagents = list("nutriment" = 10) + list_reagents = list("nutriment" = 10, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/soylenviridians name = "Soylen Virdians" @@ -797,8 +786,7 @@ icon_state = "soylent_yellow" trash = /obj/item/trash/waffles filling_color = "#E6FA61" - bitesize = 2 - list_reagents = list("nutriment" = 10) + list_reagents = list("nutriment" = 10, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/meatpie name = "Meat-pie" @@ -806,8 +794,8 @@ desc = "An old barber recipe, very delicious!" trash = /obj/item/trash/plate filling_color = "#948051" - bitesize = 2 - list_reagents = list("nutriment" = 10) + bitesize = 3 + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/tofupie name = "Tofu-pie" @@ -815,24 +803,24 @@ desc = "A delicious tofu pie." trash = /obj/item/trash/plate filling_color = "#FFFEE0" - bitesize = 2 - list_reagents = list("nutriment" = 10) + bitesize = 3 + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/amanita_pie name = "amanita pie" desc = "Sweet and tasty poison pie." icon_state = "amanita_pie" filling_color = "#FFCCCC" - bitesize = 3 - list_reagents = list("nutriment" = 5, "amanitin" = 3, "psilocybin" = 1) + bitesize = 4 + list_reagents = list("nutriment" = 6, "amanitin" = 3, "psilocybin" = 1, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/plump_pie name = "plump pie" desc = "I bet you love stuff made out of plump helmets!" icon_state = "plump_pie" filling_color = "#B8279B" - bitesize = 2 - list_reagents = list("nutriment" = 8) + bitesize = 3 + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/plump_pie/New() ..() @@ -847,8 +835,7 @@ desc = "A delicious meatpie. Probably heretical." trash = /obj/item/trash/plate filling_color = "#43DE18" - bitesize = 2 - list_reagents = list("nutriment" = 10) + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/wingfangchu name = "Wing Fang Chu" @@ -856,8 +843,7 @@ icon_state = "wingfangchu" trash = /obj/item/trash/snack_bowl filling_color = "#43DE18" - bitesize = 2 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 6, "soysauce" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/human/kabob name = "-kabob" @@ -865,7 +851,6 @@ desc = "A human meat, on a stick." trash = /obj/item/stack/rods filling_color = "#A85340" - bitesize = 2 list_reagents = list("nutriment" = 8) /obj/item/weapon/reagent_containers/food/snacks/monkeykabob @@ -874,7 +859,6 @@ desc = "Delicious meat, on a stick." trash = /obj/item/stack/rods filling_color = "#A85340" - bitesize = 2 list_reagents = list("nutriment" = 8) /obj/item/weapon/reagent_containers/food/snacks/tofukabob @@ -883,7 +867,6 @@ desc = "Vegan meat, on a stick." trash = /obj/item/stack/rods filling_color = "#FFFEE0" - bitesize = 2 list_reagents = list("nutriment" = 8) /obj/item/weapon/reagent_containers/food/snacks/popcorn @@ -912,8 +895,14 @@ desc = "Beef jerky made from the finest space cows." trash = /obj/item/trash/sosjerky filling_color = "#631212" - bitesize = 2 - list_reagents = list("protein" = 4) + junkiness = 25 + list_reagents = list("protein" = 1, "sugar" = 3) + +/obj/item/weapon/reagent_containers/food/snacks/sosjerky/healthy + name = "homemade beef jerky" + desc = "Homemade beef jerky made from the finest space cows." + list_reagents = list("nutriment" = 3, "vitamin" = 1) + junkiness = 0 /obj/item/weapon/reagent_containers/food/snacks/pistachios name = "Pistachios" @@ -921,7 +910,8 @@ desc = "A snack of deliciously salted pistachios. A perfectly valid choice..." trash = /obj/item/trash/pistachios filling_color = "#BAD145" - list_reagents = list("plantmatter" = 6, "sodiumchloride" = 1) + junkiness = 20 + list_reagents = list("plantmatter" = 2, "sodiumchloride" = 1, "sugar" = 4) /obj/item/weapon/reagent_containers/food/snacks/no_raisin name = "4no Raisins" @@ -929,14 +919,21 @@ desc = "Best raisins in the universe. Not sure why." trash = /obj/item/trash/raisins filling_color = "#343834" - list_reagents = list("plantmatter" = 6) + junkiness = 25 + list_reagents = list("plantmatter" = 2, "sugar" = 4) + +/obj/item/weapon/reagent_containers/food/snacks/no_raisin/healthy + name = "homemade raisins" + desc = "homemade raisins, the best in all of spess." + list_reagents = list("nutriment" = 3, "vitamin" = 2) + junkiness = 0 /obj/item/weapon/reagent_containers/food/snacks/spacetwinkie name = "Space Twinkie" icon_state = "space_twinkie" desc = "Guaranteed to survive longer then you will." filling_color = "#FFE591" - bitesize = 2 + junkiness = 25 list_reagents = list("sugar" = 4) /obj/item/weapon/reagent_containers/food/snacks/cheesiehonkers @@ -945,36 +942,36 @@ desc = "Bite sized cheesie snacks that will honk all over your mouth" trash = /obj/item/trash/cheesie filling_color = "#FFA305" - bitesize = 2 - list_reagents = list("nutriment" = 4, "fake_cheese" = 2) + junkiness = 25 + list_reagents = list("nutriment" = 1, "fake_cheese" = 2, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/chinese/chowmein name = "chow mein" desc = "What is in this anyways?" icon_state = "chinese1" - bitesize = 2 - list_reagents = list("nutriment" = 6, "beans" = 3, "msg" = 4) + junkiness = 25 + list_reagents = list("nutriment" = 1, "beans" = 3, "msg" = 4, "sugar" = 2) /obj/item/weapon/reagent_containers/food/snacks/chinese/tao name = "Admiral Yamamoto carp" desc = "Tastes like chicken." icon_state = "chinese2" - bitesize = 2 - list_reagents = list("nutriment" = 4, "protein" = 2, "msg" = 4) + junkiness = 25 + list_reagents = list("nutriment" = 1, "protein" = 1, "msg" = 4, "sugar" = 4) /obj/item/weapon/reagent_containers/food/snacks/chinese/newdles name = "chinese newdles" desc = "Made fresh, weekly!" icon_state = "chinese3" - bitesize = 2 - list_reagents = list("nutriment" = 6, "msg" = 4) + junkiness = 25 + list_reagents = list("nutriment" = 1, "msg" = 4, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/chinese/rice name = "fried rice" desc = "A timeless classic." icon_state = "chinese4" - bitesize = 2 - list_reagents = list("nutriment" = 3, "rice" = 3, "msg" = 4) + junkiness = 20 + list_reagents = list("nutriment" = 1, "rice" = 3, "msg" = 4, "sugar" = 2) /obj/item/weapon/reagent_containers/food/snacks/syndicake name = "Syndi-Cakes" @@ -990,7 +987,6 @@ desc = "Totally baked." icon_state = "loadedbakedpotato" filling_color = "#9C7A68" - bitesize = 2 list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/fries @@ -999,7 +995,6 @@ icon_state = "fries" trash = /obj/item/trash/plate filling_color = "#EDDD00" - bitesize = 2 list_reagents = list("nutriment" = 4) /obj/item/weapon/reagent_containers/food/snacks/soydope @@ -1008,7 +1003,6 @@ icon_state = "soydope" trash = /obj/item/trash/plate filling_color = "#C4BF76" - bitesize = 2 list_reagents = list("nutriment" = 2) /obj/item/weapon/reagent_containers/food/snacks/spagetti @@ -1016,7 +1010,7 @@ desc = "A bundle of raw spaghetti." icon_state = "spagetti" filling_color = "#EDDD00" - list_reagents = list("nutriment" = 1) + list_reagents = list("nutriment" = 1, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/cheesyfries name = "Cheesy Fries" @@ -1024,7 +1018,6 @@ icon_state = "cheesyfries" trash = /obj/item/trash/plate filling_color = "#EDDD00" - bitesize = 2 list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/fortunecookie @@ -1032,7 +1025,6 @@ desc = "A true prophecy in each cookie!" icon_state = "fortune_cookie" filling_color = "#E8E79E" - bitesize = 2 list_reagents = list("nutriment" = 3) /obj/item/weapon/reagent_containers/food/snacks/badrecipe @@ -1040,8 +1032,7 @@ desc = "Someone should be demoted from chef for this." icon_state = "badrecipe" filling_color = "#211F02" - bitesize = 2 - list_reagents = list("????" = 5, "carbon" = 3) + list_reagents = list("????" = 30) /obj/item/weapon/reagent_containers/food/snacks/badrecipe/New() ..() @@ -1056,7 +1047,7 @@ trash = /obj/item/trash/plate filling_color = "#7A3D11" bitesize = 3 - list_reagents = list("nutriment" = 4, "sodiumchloride" = 1, "blackpepper" = 1) + list_reagents = list("nutriment" = 5) /obj/item/weapon/reagent_containers/food/snacks/spacylibertyduff name = "Spacy Liberty Duff" @@ -1080,7 +1071,6 @@ name = "Poppy pretzel" desc = "It's all twisted up!" icon_state = "poppypretzel" - bitesize = 2 filling_color = "#916E36" list_reagents = list("nutriment" = 5) @@ -1091,7 +1081,7 @@ trash = /obj/item/trash/snack_bowl filling_color = "#785210" bitesize = 5 - list_reagents = list("nutriment" = 8, "water" = 5) + list_reagents = list("nutriment" = 8, "water" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/slimesoup name = "slime soup" @@ -1099,7 +1089,7 @@ icon_state = "slimesoup" filling_color = "#C4DBA0" bitesize = 5 - list_reagents = list("slimejelly" = 5, "water" = 10) + list_reagents = list("nutriment" = 5, "slimejelly" = 5, "water" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/bloodsoup name = "Tomato soup" @@ -1107,7 +1097,7 @@ icon_state = "tomatosoup" filling_color = "#FF0000" bitesize = 5 - list_reagents = list("nutriment" = 2, "blood" = 10, "water" = 5) + list_reagents = list("nutriment" = 2, "blood" = 10, "water" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/clownstears name = "Clown's Tears" @@ -1115,7 +1105,7 @@ icon_state = "clownstears" filling_color = "#C4FBFF" bitesize = 5 - list_reagents = list("nutriment" = 4, "banana" = 5, "water" = 10) + list_reagents = list("nutriment" = 4, "banana" = 5, "water" = 5, "vitamin" = 8) /obj/item/weapon/reagent_containers/food/snacks/vegetablesoup name = "Vegetable soup" @@ -1124,7 +1114,7 @@ trash = /obj/item/trash/snack_bowl filling_color = "#AFC4B5" bitesize = 5 - list_reagents = list("nutriment" = 8, "water" = 5) + list_reagents = list("nutriment" = 8, "water" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/nettlesoup name = "Nettle soup" @@ -1133,54 +1123,20 @@ trash = /obj/item/trash/snack_bowl filling_color = "#AFC4B5" bitesize = 5 - list_reagents = list("nutriment" = 8, "water" = 5, "omnizine" = 5) + list_reagents = list("nutriment" = 8, "water" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/mysterysoup - name = "Mystery soup" + name = "mystery soup" desc = "The mystery is, why aren't you eating it?" icon_state = "mysterysoup" - trash = /obj/item/trash/snack_bowl - filling_color = "#F082FF" + var/extra_reagent = null bitesize = 5 + list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/mysterysoup/New() ..() - var/mysteryselect = pick(1,2,3,4,5,6,7,8,9,10) - switch(mysteryselect) - if(1) - reagents.add_reagent("nutriment", 6) - reagents.add_reagent("capsaicin", 3) - reagents.add_reagent("tomatojuice", 2) - if(2) - reagents.add_reagent("nutriment", 6) - reagents.add_reagent("frostoil", 3) - reagents.add_reagent("tomatojuice", 2) - if(3) - reagents.add_reagent("nutriment", 5) - reagents.add_reagent("water", 5) - reagents.add_reagent("omnizine", 5) - if(4) - reagents.add_reagent("nutriment", 5) - reagents.add_reagent("water", 10) - if(5) - reagents.add_reagent("nutriment", 2) - reagents.add_reagent("banana", 10) - if(6) - reagents.add_reagent("nutriment", 6) - reagents.add_reagent("blood", 10) - if(7) - reagents.add_reagent("slimejelly", 10) - reagents.add_reagent("water", 10) - if(8) - reagents.add_reagent("carbon", 10) - reagents.add_reagent("toxin", 10) - if(9) - reagents.add_reagent("nutriment", 5) - reagents.add_reagent("tomatojuice", 10) - if(10) - reagents.add_reagent("nutriment", 6) - reagents.add_reagent("tomatojuice", 5) - reagents.add_reagent("oculine", 5) + extra_reagent = pick("capsaicin", "frostoil", "omnizine", "banana", "blood", "slimejelly", "toxin", "banana", "carbon", "oculine") + reagents.add_reagent("[extra_reagent]", 5) /obj/item/weapon/reagent_containers/food/snacks/wishsoup name = "Wish Soup" @@ -1195,7 +1151,8 @@ ..() if(prob(25)) desc = "A wish come true!" // hue - reagents.add_reagent("nutriment", 8) + reagents.add_reagent("nutriment", 9) + reagents.add_reagent("vitamin", 1) /obj/item/weapon/reagent_containers/food/snacks/hotchili name = "Hot Chili" @@ -1204,7 +1161,7 @@ trash = /obj/item/trash/snack_bowl filling_color = "#FF3C00" bitesize = 5 - list_reagents = list("nutriment" = 6, "capsaicin" = 3, "tomatojuice" = 2) + list_reagents = list("nutriment" = 5, "capsaicin" = 1, "tomatojuice" = 2, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/coldchili name = "Cold Chili" @@ -1213,20 +1170,18 @@ filling_color = "#2B00FF" trash = /obj/item/trash/snack_bowl bitesize = 5 - list_reagents = list("nutriment" = 6, "frostoil" = 3, "tomatojuice" = 2) + list_reagents = list("nutriment" = 5, "frostoil" = 1, "tomatojuice" = 2, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/raw_bacon name = "raw bacon" desc = "It's fleshy and pink!" icon_state = "raw_bacon" - bitesize = 2 list_reagents = list("nutriment" = 1, "porktonium" = 10) /obj/item/weapon/reagent_containers/food/snacks/bacon name = "bacon" desc = "It looks juicy and tastes amazing!" icon_state = "bacon2" - bitesize = 2 list_reagents = list("nutriment" = 4, "porktonium" = 10, "msg" = 4) /obj/item/weapon/reagent_containers/food/snacks/telebacon @@ -1234,7 +1189,6 @@ desc = "It tastes a little odd but it is still delicious." icon_state = "bacon" var/obj/item/device/radio/beacon/bacon/baconbeacon - bitesize = 2 list_reagents = list("nutriment" = 4, "porktonium" = 10) /obj/item/weapon/reagent_containers/food/snacks/telebacon/New() @@ -1254,7 +1208,7 @@ bitesize = 12 filling_color = "#ADAC7F" var/monkey_type = "Monkey" - list_reagents = list("protein" = 10) + list_reagents = list("nutriment" = 2) /obj/item/weapon/reagent_containers/food/snacks/monkeycube/afterattack(obj/O, mob/user, proximity) if(!proximity) @@ -1342,8 +1296,8 @@ desc = "This is absolutely Ei Nath." icon_state = "spellburger" filling_color = "#D505FF" - bitesize = 2 - list_reagents = list("nutriment" = 6) + bitesize = 3 + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/bigbiteburger name = "Big Bite Burger" @@ -1351,7 +1305,7 @@ icon_state = "bigbiteburger" filling_color = "#E3D681" bitesize = 3 - list_reagents = list("nutriment" = 14) + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/enchiladas name = "Enchiladas" @@ -1368,7 +1322,7 @@ icon_state = "burrito" trash = /obj/item/trash/plate filling_color = "#A36A1F" - list_reagents = list("nutriment" = 5) + list_reagents = list("nutriment" = 4, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/chimichanga name = "Chimichanga" @@ -1385,7 +1339,7 @@ trash = /obj/item/trash/tray filling_color = "#5C3C11" bitesize = 6 - list_reagents = list("nutriment" = 10, "banana" = 5, "blackpepper" = 1, "sodiumchloride" = 1) + list_reagents = list("nutriment" = 10, "banana" = 5, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/baguette name = "Baguette" @@ -1393,7 +1347,7 @@ icon_state = "baguette" filling_color = "#E3D796" bitesize = 3 - list_reagents = list("nutriment" = 6, "blackpepper" = 1, "sodiumchloride" = 1) + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/sandwich name = "Sandwich" @@ -1401,8 +1355,7 @@ icon_state = "sandwich" trash = /obj/item/trash/plate filling_color = "#D9BE29" - bitesize = 2 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/toastedsandwich name = "Toasted Sandwich" @@ -1410,7 +1363,6 @@ icon_state = "toastedsandwich" trash = /obj/item/trash/plate filling_color = "#D9BE29" - bitesize = 2 list_reagents = list("nutriment" = 6, "carbon" = 2) /obj/item/weapon/reagent_containers/food/snacks/grilledcheese @@ -1419,8 +1371,7 @@ icon_state = "toastedsandwich" trash = /obj/item/trash/plate filling_color = "#D9BE29" - bitesize = 2 - list_reagents = list("nutriment" = 7) //why make a regualr sandwhich when you can make grilled cheese, with this nutriment value? + list_reagents = list("nutriment" = 7, "vitamin" = 1) //why make a regualr sandwhich when you can make grilled cheese, with this nutriment value? /obj/item/weapon/reagent_containers/food/snacks/tomatosoup name = "Tomato Soup" @@ -1428,8 +1379,8 @@ icon_state = "tomatosoup" trash = /obj/item/trash/snack_bowl filling_color = "#D92929" - bitesize = 3 - list_reagents = list("nutriment" = 5, "tomatojuice" = 10) + bitesize = 5 + list_reagents = list("nutriment" = 5, "tomatojuice" = 10, "vitamin" = 3) /obj/item/weapon/reagent_containers/food/snacks/rofflewaffles name = "Roffle Waffles" @@ -1438,15 +1389,15 @@ trash = /obj/item/trash/waffles filling_color = "#FF00F7" bitesize = 4 - list_reagents = list("nutriment" = 8, "psilocybin" = 8) + list_reagents = list("nutriment" = 8, "psilocybin" = 2, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/stew name = "Stew" desc = "A nice and warm stew. Healthy and strong." icon_state = "stew" filling_color = "#9E673A" - bitesize = 10 - list_reagents = list("nutriment" = 10, "tomatojuice" = 5, "oculine" = 5, "water" = 5) + bitesize = 7 + list_reagents = list("nutriment" = 10, "oculine" = 5, "tomatojuice" = 5, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/jelliedtoast name = "Jellied Toast" @@ -1455,42 +1406,39 @@ trash = /obj/item/trash/plate filling_color = "#B572AB" bitesize = 3 - list_reagents = list("nutriment" = 1) /obj/item/weapon/reagent_containers/food/snacks/jelliedtoast/cherry - list_reagents = list("nutriment" = 1, "cherryjelly" = 5) + list_reagents = list("nutriment" = 1, "cherryjelly" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/jelliedtoast/slime - list_reagents = list("nutriment" = 1, "slimejelly" = 5) + list_reagents = list("nutriment" = 1, "slimejelly" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/jellyburger name = "Jelly Burger" desc = "Culinary delight..?" icon_state = "jellyburger" filling_color = "#B572AB" - bitesize = 2 - list_reagents = list("nutriment" = 5) + bitesize = 3 /obj/item/weapon/reagent_containers/food/snacks/jellyburger/slime - list_reagents = list("nutriment" = 5, "slimejelly" = 5) + list_reagents = list("nutriment" = 6, "slimejelly" = 5, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/jellyburger/cherry - list_reagents = list("nutriment" = 5, "cherryjelly" = 5) + list_reagents = list("nutriment" = 6, "cherryjelly" = 5, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/milosoup name = "Milosoup" desc = "The universes best soup! Yum!!!" icon_state = "milosoup" trash = /obj/item/trash/snack_bowl - bitesize = 4 - list_reagents = list("nutriment" = 8, "water" = 5) + bitesize = 5 + list_reagents = list("nutriment" = 7, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/stewedsoymeat name = "Stewed Soy Meat" desc = "Even non-vegetarians will LOVE this!" icon_state = "stewedsoymeat" trash = /obj/item/trash/plate - bitesize = 2 list_reagents = list("nutriment" = 8) /obj/item/weapon/reagent_containers/food/snacks/boiledspagetti @@ -1499,8 +1447,7 @@ icon_state = "spagettiboiled" trash = /obj/item/trash/plate filling_color = "#FCEE81" - bitesize = 2 - list_reagents = list("nutriment" = 2) + list_reagents = list("nutriment" = 2, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/boiledrice name = "Boiled Rice" @@ -1508,8 +1455,7 @@ icon_state = "boiledrice" trash = /obj/item/trash/snack_bowl filling_color = "#FFFBDB" - bitesize = 2 - list_reagents = list("nutriment" = 2) + list_reagents = list("nutriment" = 5, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/ricepudding name = "Rice Pudding" @@ -1517,8 +1463,7 @@ icon_state = "rpudding" trash = /obj/item/trash/snack_bowl filling_color = "#FFFBDB" - bitesize = 2 - list_reagents = list("nutriment" = 4) + list_reagents = list("nutriment" = 7, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/pastatomato name = "Spagetti" @@ -1527,7 +1472,7 @@ trash = /obj/item/trash/plate filling_color = "#DE4545" bitesize = 4 - list_reagents = list("nutriment" = 6, "tomatojuice" = 10) + list_reagents = list("nutriment" = 6, "tomatojuice" = 10, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/meatballspagetti name = "Spagetti & Meatballs" @@ -1535,23 +1480,20 @@ icon_state = "meatballspagetti" trash = /obj/item/trash/plate filling_color = "#DE4545" - bitesize = 2 - list_reagents = list("nutriment" = 8, "synaptizine" = 5) + list_reagents = list("nutriment" = 8, "synaptizine" = 5, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/spesslaw name = "Spesslaw" desc = "A lawyers favourite" icon_state = "spesslaw" filling_color = "#DE4545" - bitesize = 2 - list_reagents = list("nutriment" = 8, "synaptizine" = 10) + list_reagents = list("nutriment" = 8, "synaptizine" = 10, "vitamin" = 6) /obj/item/weapon/reagent_containers/food/snacks/poppypretzel name = "Poppy Pretzel" desc = "A large soft pretzel full of POP!" icon_state = "poppypretzel" filling_color = "#AB7D2E" - bitesize = 2 list_reagents = list("nutriment" = 5) /obj/item/weapon/reagent_containers/food/snacks/carrotfries @@ -1560,16 +1502,15 @@ icon_state = "carrotfries" trash = /obj/item/trash/plate filling_color = "#FAA005" - bitesize = 2 - list_reagents = list("plantmatter" = 3, "oculine" = 3) + list_reagents = list("plantmatter" = 3, "oculine" = 3, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/superbiteburger name = "Super Bite Burger" desc = "This is a mountain of a burger. FOOD!" icon_state = "superbiteburger" filling_color = "#CCA26A" - bitesize = 10 - list_reagents = list("nutriment" = 50) + bitesize = 7 + list_reagents = list("nutriment" = 40, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/candiedapple name = "Candied Apple" @@ -1577,7 +1518,7 @@ icon_state = "candiedapple" filling_color = "#F21873" bitesize = 3 - list_reagents = list("nutriment" = 3) // A candy apple without sugar... + list_reagents = list("nutriment" = 3, "sugar" = 2) /obj/item/weapon/reagent_containers/food/snacks/applepie name = "Apple Pie" @@ -1585,7 +1526,7 @@ icon_state = "applepie" filling_color = "#E0EDC5" bitesize = 3 - list_reagents = list("nutriment" = 4) + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/cherrypie name = "Cherry Pie" @@ -1593,7 +1534,7 @@ icon_state = "cherrypie" filling_color = "#FF525A" bitesize = 3 - list_reagents = list("nutriment" = 4) + list_reagents = list("nutriment" = 10, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/twobread name = "Two Bread" @@ -1601,7 +1542,7 @@ icon_state = "twobread" filling_color = "#DBCC9A" bitesize = 3 - list_reagents = list("nutriment" = 2) + list_reagents = list("nutriment" = 2, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/jellysandwich name = "Jelly Sandwich" @@ -1610,13 +1551,12 @@ trash = /obj/item/trash/plate filling_color = "#9E3A78" bitesize = 3 - list_reagents = list("nutriment" = 2) /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/slime - list_reagents = list("nutriment" = 2, "slimejelly" = 5) + list_reagents = list("nutriment" = 2, "slimejelly" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/jellysandwich/cherry - list_reagents = list("nutriment" = 2, "cherryjelly" = 5) + list_reagents = list("nutriment" = 2, "cherryjelly" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/boiledslimecore name = "Boiled Slime Core" @@ -1629,8 +1569,9 @@ name = "mint" desc = "it is only wafer thin." icon_state = "mint" + bitesize = 1 filling_color = "#F2F2F2" - list_reagents = list("minttoxin" = 2) + list_reagents = list("minttoxin" = 1) /obj/item/weapon/reagent_containers/food/snacks/mushroomsoup name = "chantrelle soup" @@ -1638,15 +1579,14 @@ icon_state = "mushroomsoup" trash = /obj/item/trash/snack_bowl filling_color = "#E386BF" - bitesize = 3 - list_reagents = list("nutriment" = 8) + bitesize = 5 + list_reagents = list("nutriment" = 8, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/plumphelmetbiscuit name = "plump helmet biscuit" desc = "This is a finely-prepared plump helmet biscuit. The ingredients are exceptionally minced plump helmet, and well-minced dwarven wheat flour." icon_state = "phelmbiscuit" filling_color = "#CFB4C4" - bitesize = 2 list_reagents = list("nutriment" = 5) /obj/item/weapon/reagent_containers/food/snacks/plumphelmetbiscuit/New() @@ -1654,7 +1594,6 @@ if(prob(10)) name = "exceptional plump helmet biscuit" desc = "Microwave is taken by a fey mood! It has cooked an exceptional plump helmet biscuit!" // Is this a reference? - reagents.add_reagent("nutriment", 3) reagents.add_reagent("omnizine", 5) /obj/item/weapon/reagent_containers/food/snacks/chawanmushi @@ -1670,25 +1609,13 @@ desc = "Wait, how do you spell it again..?" icon_state = "beetsoup" trash = /obj/item/trash/snack_bowl + bitesize = 5 filling_color = "#FAC9FF" - bitesize = 2 - list_reagents = list("nutriment" = 8) + list_reagents = list("nutriment" = 7, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/beetsoup/New() ..() - switch(rand(1,6)) - if(1) - name = "borsch" - if(2) - name = "bortsch" - if(3) - name = "borstch" - if(4) - name = "borsh" - if(5) - name = "borshch" - if(6) - name = "borscht" + name = pick("borsch","bortsch","borstch","borsh","borshch","borscht") /obj/item/weapon/reagent_containers/food/snacks/herbsalad name = "herb salad" @@ -1697,7 +1624,7 @@ trash = /obj/item/trash/snack_bowl filling_color = "#76B87F" bitesize = 3 - list_reagents = list("nutriment" = 8) + list_reagents = list("nutriment" = 8, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/validsalad name = "valid salad" @@ -1706,7 +1633,7 @@ trash = /obj/item/trash/snack_bowl filling_color = "#76B87F" bitesize = 3 - list_reagents = list("nutriment" = 8, "omnizine" = 5) + list_reagents = list("nutriment" = 8, "salglu_solution" = 5, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/appletart name = "golden apple streusel tart" @@ -1715,45 +1642,13 @@ trash = /obj/item/trash/plate filling_color = "#FFFF00" bitesize = 3 - list_reagents = list("nutriment" = 8, "gold" = 5) - -/obj/item/weapon/reagent_containers/food/snacks/dough_ball - name = "ball of raw dough" - desc = "A ball of raw dough, ready to be molded into new recipes." - icon = 'icons/obj/food/food_ingredients.dmi' - icon_state = "dough" - list_reagents = list("nutriment" = 3) - -/obj/item/weapon/reagent_containers/food/snacks/dough_ball/attackby(obj/item/weapon/W, mob/user, params) - if(istype(W,/obj/item/weapon/kitchen/rollingpin)) - user.visible_message( \ - "[user] flattens the dough with the rolling pin!", \ - "You flatten the dough with your rolling pin!" \ - ) - new /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough(loc) - qdel(src) + list_reagents = list("nutriment" = 8, "gold" = 5, "vitamin" = 4) /////////////////////////////////////////////////Sliceable//////////////////////////////////////// // All the food items that can be sliced into smaller bits like Meatbread and Cheesewheels // sliceable is just an organization type path, it doesn't have any additional code or variables tied to it. -/obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough - name = "flattened dough" - desc = "Still raw. You resist the temptation to cover it in tomato sauce." - icon = 'icons/obj/food/food_ingredients.dmi' - icon_state = "flatdough" - slice_path = /obj/item/weapon/reagent_containers/food/snacks/doughslice - slices_num = 3 - list_reagents = list("nutriment" = 3) - -/obj/item/weapon/reagent_containers/food/snacks/doughslice - name = "slice of dough" - desc = "an individual portion of raw dough, ready to be cooked." - icon = 'icons/obj/food/food_ingredients.dmi' - icon_state = "doughslice" - bitesize = 2 - /obj/item/weapon/reagent_containers/food/snacks/sliceable/meatbread name = "meatbread loaf" desc = "The culinary base of every self-respecting eloquen/tg/entleman." @@ -1761,8 +1656,7 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/meatbreadslice slices_num = 5 filling_color = "#FF7575" - bitesize = 2 - list_reagents = list("protein" = 20, "nutriment" = 10) + list_reagents = list("protein" = 20, "nutriment" = 10, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/meatbreadslice name = "meatbread slice" @@ -1770,7 +1664,6 @@ icon_state = "meatbreadslice" trash = /obj/item/trash/plate filling_color = "#FF7575" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/xenomeatbread name = "xenomeatbread loaf" @@ -1779,8 +1672,7 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/xenomeatbreadslice slices_num = 5 filling_color = "#8AFF75" - bitesize = 2 - list_reagents = list("protein" = 20, "nutriment" = 10) + list_reagents = list("protein" = 20, "nutriment" = 10, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/xenomeatbreadslice name = "xenomeatbread slice" @@ -1788,7 +1680,6 @@ icon_state = "xenobreadslice" trash = /obj/item/trash/plate filling_color = "#8AFF75" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/spidermeatbread name = "spider meat loaf" @@ -1796,15 +1687,13 @@ icon_state = "spidermeatbread" slice_path = /obj/item/weapon/reagent_containers/food/snacks/spidermeatbreadslice slices_num = 5 - bitesize = 2 - list_reagents = list("protein" = 20, "nutriment" = 10, "toxin" = 15) + list_reagents = list("protein" = 20, "nutriment" = 10, "toxin" = 15, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/spidermeatbreadslice name = "spider meat bread slice" desc = "A slice of meatloaf made from an animal that most likely still wants you dead." icon_state = "xenobreadslice" trash = /obj/item/trash/plate - bitesize = 2 list_reagents = list("toxin" = 2) /obj/item/weapon/reagent_containers/food/snacks/sliceable/bananabread @@ -1814,7 +1703,6 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/bananabreadslice slices_num = 5 filling_color = "#EDE5AD" - bitesize = 2 list_reagents = list("banana" = 20, "nutriment" = 20) /obj/item/weapon/reagent_containers/food/snacks/bananabreadslice @@ -1823,7 +1711,6 @@ icon_state = "bananabreadslice" trash = /obj/item/trash/plate filling_color = "#EDE5AD" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/tofubread name = "Tofubread" @@ -1832,8 +1719,7 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/tofubreadslice slices_num = 5 filling_color = "#F7FFE0" - bitesize = 2 - list_reagents = list("nutriment" = 30) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/tofubreadslice name = "Tofubread slice" @@ -1841,7 +1727,6 @@ icon_state = "tofubreadslice" trash = /obj/item/trash/plate filling_color = "#F7FFE0" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/carrotcake name = "Carrot Cake" @@ -1849,9 +1734,9 @@ icon_state = "carrotcake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/carrotcakeslice slices_num = 5 + bitesize = 3 filling_color = "#FFD675" - bitesize = 2 - list_reagents = list("nutriment" = 25, "oculine" = 10) + list_reagents = list("nutriment" = 20, "oculine" = 10, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/carrotcakeslice name = "Carrot Cake slice" @@ -1859,7 +1744,6 @@ icon_state = "carrotcake_slice" trash = /obj/item/trash/plate filling_color = "#FFD675" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/braincake name = "Brain Cake" @@ -1868,8 +1752,8 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/braincakeslice slices_num = 5 filling_color = "#E6AEDB" - bitesize = 2 - list_reagents = list("protein" = 15, "nutriment" = 10, "mannitol" = 10) + bitesize = 3 + list_reagents = list("protein" = 10, "nutriment" = 10, "mannitol" = 10, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/braincakeslice name = "Brain Cake slice" @@ -1877,7 +1761,6 @@ icon_state = "braincakeslice" trash = /obj/item/trash/plate filling_color = "#E6AEDB" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/cheesecake name = "Cheese Cake" @@ -1886,8 +1769,8 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/cheesecakeslice slices_num = 5 filling_color = "#FAF7AF" - bitesize = 2 - list_reagents = list("nutriment" = 25) + bitesize = 3 + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/cheesecakeslice name = "Cheese Cake slice" @@ -1895,7 +1778,6 @@ icon_state = "cheesecake_slice" trash = /obj/item/trash/plate filling_color = "#FAF7AF" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/plaincake name = "Vanilla Cake" @@ -1903,8 +1785,9 @@ icon_state = "plaincake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/plaincakeslice slices_num = 5 + bitesize = 3 filling_color = "#F7EDD5" - list_reagents = list("nutriment" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/plaincakeslice name = "Vanilla Cake slice" @@ -1912,7 +1795,6 @@ icon_state = "plaincake_slice" trash = /obj/item/trash/plate filling_color = "#F7EDD5" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/orangecake name = "Orange Cake" @@ -1920,8 +1802,9 @@ icon_state = "orangecake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/orangecakeslice slices_num = 5 + bitesize = 3 filling_color = "#FADA8E" - list_reagents = list("nutriment" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/orangecakeslice name = "Orange Cake slice" @@ -1929,16 +1812,16 @@ icon_state = "orangecake_slice" trash = /obj/item/trash/plate filling_color = "#FADA8E" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/limecake name = "Lime Cake" desc = "A cake with added lime." icon_state = "limecake" + bitesize = 3 slice_path = /obj/item/weapon/reagent_containers/food/snacks/limecakeslice slices_num = 5 filling_color = "#CBFA8E" - list_reagents = list("nutriment" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/limecakeslice name = "Lime Cake slice" @@ -1946,7 +1829,6 @@ icon_state = "limecake_slice" trash = /obj/item/trash/plate filling_color = "#CBFA8E" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/lemoncake name = "Lemon Cake" @@ -1954,8 +1836,9 @@ icon_state = "lemoncake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/lemoncakeslice slices_num = 5 + bitesize = 3 filling_color = "#FAFA8E" - list_reagents = list("nutriment" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/lemoncakeslice name = "Lemon Cake slice" @@ -1963,7 +1846,6 @@ icon_state = "lemoncake_slice" trash = /obj/item/trash/plate filling_color = "#FAFA8E" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/chocolatecake name = "Chocolate Cake" @@ -1971,8 +1853,9 @@ icon_state = "chocolatecake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/chocolatecakeslice slices_num = 5 + bitesize = 3 filling_color = "#805930" - list_reagents = list("nutriment" = 20, "chocolate" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/chocolatecakeslice name = "Chocolate Cake slice" @@ -1980,7 +1863,6 @@ icon_state = "chocolatecake_slice" trash = /obj/item/trash/plate filling_color = "#805930" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/cheesewheel name = "Cheese wheel" @@ -1989,22 +1871,19 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/cheesewedge slices_num = 5 filling_color = "#FFF700" - bitesize = 2 - list_reagents = list("nutriment" = 20, "cheese" = 20) + list_reagents = list("nutriment" = 15, "vitamin" = 5, "cheese" = 20) /obj/item/weapon/reagent_containers/food/snacks/cheesewedge name = "Cheese wedge" desc = "A wedge of delicious Cheddar. The cheese wheel it was cut from can't have gone far." icon_state = "cheesewedge" filling_color = "#FFF700" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/weirdcheesewedge name = "Weird Cheese" desc = "Some kind of... gooey, messy, gloopy thing. Similar to cheese, but only in the looser sense of the word." icon_state = "weirdcheesewedge" filling_color = "#00FF33" - bitesize = 2 list_reagents = list("mercury" = 5, "lsd" = 5, "ethanol" = 5, "weird_cheese" = 5) /obj/item/weapon/reagent_containers/food/snacks/sliceable/birthdaycake @@ -2015,7 +1894,7 @@ slices_num = 5 filling_color = "#FFD6D6" bitesize = 3 - list_reagents = list("nutriment" = 20, "sprinkles" = 10) + list_reagents = list("nutriment" = 20, "sprinkles" = 10, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/birthdaycakeslice name = "Birthday Cake slice" @@ -2023,7 +1902,6 @@ icon_state = "birthdaycakeslice" trash = /obj/item/trash/plate filling_color = "#FFD6D6" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/bread name = "Bread" @@ -2032,8 +1910,7 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/breadslice slices_num = 6 filling_color = "#FFE396" - bitesize = 2 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 10) /obj/item/weapon/reagent_containers/food/snacks/breadslice name = "Bread slice" @@ -2041,8 +1918,7 @@ icon_state = "breadslice" trash = /obj/item/trash/plate filling_color = "#D27332" - bitesize = 2 - list_reagents = list("bread" = 5) + list_reagents = list("nutriment" = 2, "bread" = 5) /obj/item/weapon/reagent_containers/food/snacks/sliceable/creamcheesebread name = "Cream Cheese Bread" @@ -2051,8 +1927,7 @@ slice_path = /obj/item/weapon/reagent_containers/food/snacks/creamcheesebreadslice slices_num = 5 filling_color = "#FFF896" - bitesize = 2 - list_reagents = list("nutriment" = 20) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/creamcheesebreadslice name = "Cream Cheese Bread slice" @@ -2060,14 +1935,13 @@ icon_state = "creamcheesebreadslice" trash = /obj/item/trash/plate filling_color = "#FFF896" - bitesize = 2 + list_reagents = list("nutriment" = 4, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/watermelonslice name = "Watermelon Slice" desc = "A slice of watery goodness." icon_state = "watermelonslice" filling_color = "#FF3867" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/applecake name = "Apple Cake" @@ -2075,8 +1949,9 @@ icon_state = "applecake" slice_path = /obj/item/weapon/reagent_containers/food/snacks/applecakeslice slices_num = 5 + bitesize = 3 filling_color = "#EBF5B8" - list_reagents = list("nutriment" = 15) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/applecakeslice name = "Apple Cake slice" @@ -2084,7 +1959,6 @@ icon_state = "applecakeslice" trash = /obj/item/trash/plate filling_color = "#EBF5B8" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/pumpkinpie name = "Pumpkin Pie" @@ -2092,8 +1966,9 @@ icon_state = "pumpkinpie" slice_path = /obj/item/weapon/reagent_containers/food/snacks/pumpkinpieslice slices_num = 5 + bitesize = 3 filling_color = "#F5B951" - list_reagents = list("nutriment" = 15) + list_reagents = list("nutriment" = 20, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/pumpkinpieslice name = "Pumpkin Pie slice" @@ -2101,12 +1976,12 @@ icon_state = "pumpkinpieslice" trash = /obj/item/trash/plate filling_color = "#F5B951" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/cracker name = "Cracker" desc = "It's a salted cracker." icon_state = "cracker" + bitesize = 1 filling_color = "#F5DEB8" list_reagents = list("nutriment" = 1) @@ -2140,15 +2015,14 @@ icon_state = "pizzamargherita" slice_path = /obj/item/weapon/reagent_containers/food/snacks/margheritaslice slices_num = 6 - bitesize = 2 - list_reagents = list("nutriment" = 40, "tomatojuice" = 6) + list_reagents = list("nutriment" = 30, "tomatojuice" = 6, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/margheritaslice name = "Margherita slice" desc = "A slice of the classic pizza." icon_state = "pizzamargheritaslice" filling_color = "#BAA14C" - bitesize = 2 + list_reagents = list("nutriment" = 5) /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/meatpizza name = "Meatpizza" @@ -2156,15 +2030,13 @@ icon_state = "meatpizza" slice_path = /obj/item/weapon/reagent_containers/food/snacks/meatpizzaslice slices_num = 6 - bitesize = 2 - list_reagents = list("protein" = 30, "nutriment" = 20, "tomatojuice" = 6) + list_reagents = list("protein" = 30, "tomatojuice" = 6, "vitamin" = 8) /obj/item/weapon/reagent_containers/food/snacks/meatpizzaslice name = "Meatpizza slice" desc = "A slice of a meaty pizza." icon_state = "meatpizzaslice" filling_color = "#BAA14C" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/mushroompizza name = "Mushroompizza" @@ -2172,15 +2044,13 @@ icon_state = "mushroompizza" slice_path = /obj/item/weapon/reagent_containers/food/snacks/mushroompizzaslice slices_num = 6 - bitesize = 2 - list_reagents = list("plantmatter" = 25, "nutriment" = 10) + list_reagents = list("plantmatter" = 30, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/mushroompizzaslice name = "Mushroompizza slice" desc = "Maybe it is the last slice of pizza in your life." icon_state = "mushroompizzaslice" filling_color = "#BAA14C" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/vegetablepizza name = "Vegetable pizza" @@ -2188,15 +2058,13 @@ icon_state = "vegetablepizza" slice_path = /obj/item/weapon/reagent_containers/food/snacks/vegetablepizzaslice slices_num = 6 - bitesize = 2 - list_reagents = list("plantmatter" = 20, "nutriment" = 10, "tomatojuice" = 6, "oculine" = 12) + list_reagents = list("plantmatter" = 25, "tomatojuice" = 6, "oculine" = 12, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/vegetablepizzaslice name = "Vegetable pizza slice" desc = "A slice of the most green pizza of all pizzas not containing green ingredients " icon_state = "vegetablepizzaslice" filling_color = "#BAA14C" - bitesize = 2 /obj/item/pizzabox name = "pizza box" @@ -2377,57 +2245,52 @@ name = "egg wrap" desc = "The precursor to Pigs in a Blanket." icon_state = "wrap" - bitesize = 2 list_reagents = list("nutriment" = 5) /obj/item/weapon/reagent_containers/food/snacks/beans name = "tin of beans" desc = "Musical fruit in a slightly less musical container." icon_state = "beans" - bitesize = 2 - list_reagents = list("nutriment" = 10, "beans" = 10) + list_reagents = list("nutriment" = 10, "beans" = 10, "vitamin" = 3) /obj/item/weapon/reagent_containers/food/snacks/benedict name = "eggs benedict" desc = "There is only one egg on this, how rude." icon_state = "benedict" bitesize = 3 - list_reagents = list("nutriment" = 3, "egg" = 3) + list_reagents = list("nutriment" = 6, "egg" = 3, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/hotdog name = "hotdog" desc = "Fresh footlong ready to go down on." icon_state = "hotdog" bitesize = 3 - list_reagents = list("nutriment" = 3, "ketchup" = 3) + list_reagents = list("nutriment" = 6, "ketchup" = 3, "vitamin" = 3) /obj/item/weapon/reagent_containers/food/snacks/meatbun name = "meat bun" desc = "Has the potential to not be Dog." icon_state = "meatbun" bitesize = 6 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 6, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/icecreamsandwich name = "icecream sandwich" desc = "Portable Ice-cream in it's own packaging." icon_state = "icecreamsandwich" - bitesize = 2 list_reagents = list("nutriment" = 2, "ice" = 2) /obj/item/weapon/reagent_containers/food/snacks/notasandwich name = "not-a-sandwich" desc = "Something seems to be wrong with this, you can't quite figure what. Maybe it's his moustache." icon_state = "notasandwich" - bitesize = 2 - list_reagents = list("nutriment" = 6) + list_reagents = list("nutriment" = 6, "vitamin" = 6) /obj/item/weapon/reagent_containers/food/snacks/sugarcookie name = "sugar cookie" desc = "Just like your little sister used to make." icon_state = "sugarcookie" - bitesize = 2 - list_reagents = list("nutriment" = 2, "sugar" = 5) + list_reagents = list("nutriment" = 3, "sugar" = 3) /obj/item/weapon/reagent_containers/food/snacks/friedbanana name = "Fried Banana" @@ -2441,8 +2304,7 @@ icon_state = "dionaroast" trash = /obj/item/trash/plate filling_color = "#75754B" - bitesize = 2 - list_reagents = list("plantmatter" = 4, "nutriment" = 2, "radium" = 2) + list_reagents = list("plantmatter" = 4, "nutriment" = 2, "radium" = 2, "vitamin" = 4) /obj/item/weapon/reagent_containers/food/snacks/boiledspiderleg name = "boiled spider leg" @@ -2450,14 +2312,13 @@ icon_state = "spiderlegcooked" trash = /obj/item/trash/plate bitesize = 3 - list_reagents = list("nutriment" = 3, "toxin" = 2) + list_reagents = list("nutriment" = 3, "capsaicin" = 2) /obj/item/weapon/reagent_containers/food/snacks/spidereggs name = "spider eggs" desc = "A cluster of juicy spider eggs. A great side dish for when you care not for your health." icon_state = "spidereggs" - bitesize = 2 - list_reagents = list("protein" = 2, "toxin" = 3) + list_reagents = list("protein" = 2, "toxin" = 2) /obj/item/weapon/reagent_containers/food/snacks/spidereggsham name = "green eggs and ham" @@ -2465,7 +2326,7 @@ icon_state = "spidereggsham" trash = /obj/item/trash/plate bitesize = 4 - list_reagents = list("nutriment" = 6, "sodiumchloride" = 1, "toxin" = 3) + list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/sliceable/turkey name = "Turkey" @@ -2473,8 +2334,7 @@ icon_state = "turkey" slice_path = /obj/item/weapon/reagent_containers/food/snacks/turkeyslice slices_num = 6 - bitesize = 2 - list_reagents = list("protein" = 24, "nutriment" = 18) + list_reagents = list("protein" = 24, "nutriment" = 18, "vitamin" = 5) /obj/item/weapon/reagent_containers/food/snacks/turkeyslice name = "turkey serving" @@ -2482,7 +2342,6 @@ icon_state = "turkeyslice" trash = /obj/item/trash/plate filling_color = "#B97A57" - bitesize = 2 /obj/item/weapon/reagent_containers/food/snacks/mashed_potatoes //mashed taters name = "mashed potatoes" @@ -2490,8 +2349,7 @@ icon_state = "mashedtaters" trash = /obj/item/trash/plate filling_color = "#D6D9C1" - bitesize = 2 - list_reagents = list("nutriment" = 5, "gravy" = 5, "mashedpotatoes" = 10) + list_reagents = list("nutriment" = 5, "gravy" = 5, "mashedpotatoes" = 10, "vitamin" = 2) ////////////////////////////////ICE CREAM/////////////////////////////////// /obj/item/weapon/reagent_containers/food/snacks/icecream @@ -2499,6 +2357,7 @@ desc = "Delicious ice cream." icon = 'icons/obj/kitchen.dmi' icon_state = "icecream_cone" + bitesize = 3 list_reagents = list("nutriment" = 1, "sugar" = 1) /obj/item/weapon/reagent_containers/food/snacks/icecream/New() @@ -2532,7 +2391,6 @@ desc = "A box of cereal." icon = 'icons/obj/food/food.dmi' icon_state = "cereal_box" - bitesize = 2 list_reagents = list("nutriment" = 3) /obj/item/weapon/reagent_containers/food/snacks/deepfryholder @@ -2540,7 +2398,6 @@ desc = "If you can see this description the code for the deep fryer fucked up." icon = 'icons/obj/food/food.dmi' icon_state = "deepfried_holder_icon" - bitesize = 2 list_reagents = list("nutriment" = 3) /obj/item/weapon/reagent_containers/food/snacks/dough @@ -2548,8 +2405,7 @@ desc = "A piece of dough." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "dough" - bitesize = 2 - list_reagents = list("nutriment" = 3) + list_reagents = list("nutriment" = 6) // Dough + rolling pin = flat dough /obj/item/weapon/reagent_containers/food/snacks/dough/attackby(obj/item/I, mob/user, params) @@ -2571,14 +2427,13 @@ icon_state = "flat dough" slice_path = /obj/item/weapon/reagent_containers/food/snacks/doughslice slices_num = 3 - list_reagents = list("nutriment" = 3) + list_reagents = list("nutriment" = 6) /obj/item/weapon/reagent_containers/food/snacks/doughslice name = "dough slice" desc = "The building block of an impressive dish." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "doughslice" - bitesize = 2 list_reagents = list("nutriment" = 1) /obj/item/weapon/reagent_containers/food/snacks/bun @@ -2586,53 +2441,34 @@ desc = "The base for any self-respecting burger." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "bun" - bitesize = 3 - list_reagents = list("nutriment" = 4) + list_reagents = list("nutriment" = 1) /obj/item/weapon/reagent_containers/food/snacks/taco name = "taco" desc = "Take a bite!" icon_state = "taco" bitesize = 3 - list_reagents = list("nutriment" = 7) + list_reagents = list("nutriment" = 7, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/cutlet name = "cutlet" desc = "A tasty meat slice." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "cutlet" - bitesize = 2 list_reagents = list("protein" = 2) -/obj/item/weapon/reagent_containers/food/snacks/rawmeatball - name = "raw meatball" - desc = "A raw meatball." - icon = 'icons/obj/food/food_ingredients.dmi' - icon_state = "rawmeatball" - bitesize = 2 - list_reagents = list("protein" = 2) - -/obj/item/weapon/reagent_containers/food/snacks/hotdog - name = "hotdog" - desc = "Unrelated to dogs, maybe." - icon_state = "hotdog" - bitesize = 2 - list_reagents = list("protein" = 6) - /obj/item/weapon/reagent_containers/food/snacks/flatbread name = "flatbread" desc = "Bland but filling." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "flatbread" - bitesize = 2 - list_reagents = list("nutriment" = 3) + list_reagents = list("nutriment" = 6, "vitamin" = 1) /obj/item/weapon/reagent_containers/food/snacks/rawsticks name = "raw potato sticks" desc = "Raw fries, not very tasty." icon = 'icons/obj/food/food_ingredients.dmi' icon_state = "rawsticks" - bitesize = 2 list_reagents = list("plantmatter" = 3) /obj/item/weapon/reagent_containers/food/snacks/ectoplasm @@ -2649,7 +2485,7 @@ trash = /obj/item/trash/liquidfood filling_color = "#A8A8A8" bitesize = 4 - list_reagents = list("nutriment" = 20, "iron" = 3) + list_reagents = list("nutriment" = 20, "iron" = 3, "vitamin" = 2) /obj/item/weapon/reagent_containers/food/snacks/tastybread @@ -2658,5 +2494,28 @@ icon_state = "tastybread" trash = /obj/item/trash/tastybread filling_color = "#A66829" - bitesize = 2 - list_reagents = list("nutriment" = 6) \ No newline at end of file + junkiness = 20 + list_reagents = list("nutriment" = 2, "sugar" = 4) + +/obj/item/weapon/reagent_containers/food/snacks/yakiimo + name = "yaki imo" + desc = "Made with roasted sweet potatoes!" + icon_state = "yakiimo" + trash = /obj/item/trash/plate + list_reagents = list("nutriment" = 5, "vitamin" = 4) + filling_color = "#8B1105" + +/obj/item/weapon/reagent_containers/food/snacks/roastparsnip + name = "roast parsnip" + desc = "Sweet and crunchy." + icon_state = "roastparsnip" + trash = /obj/item/trash/plate + list_reagents = list("nutriment" = 3, "vitamin" = 4) + filling_color = "#FF5500" + +/obj/item/weapon/reagent_containers/food/snacks/tatortot + name = "tator tot" + desc = "A large fried potato nugget that may or may not try to valid you." + icon_state = "tatortot" + list_reagents = list("nutriment" = 4) + filling_color = "FFD700" \ No newline at end of file diff --git a/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm b/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm index 73607d4e3ab..d9b98c82724 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm @@ -48,11 +48,7 @@ return 0 for(var/Type in subtypesof(/datum/deepfryer_special)) var/datum/deepfryer_special/P = new Type() - 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.kitchen_tag != P.input) - continue - else if(!istype(I, P.input)) + if(!istype(I, P.input)) continue return P return 0 diff --git a/code/modules/food_and_drinks/kitchen_machinery/gibber.dm b/code/modules/food_and_drinks/kitchen_machinery/gibber.dm index fafa983cf1d..908411f5731 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/gibber.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/gibber.dm @@ -12,8 +12,12 @@ var/locked = 0 //Used to prevent mobs from breaking the feedin anim var/gib_throw_dir = WEST // Direction to spit meat and gibs in. Defaults to west. - var/gibtime = 40 // Time from starting until meat appears + var/gibtime = 40 // Time from starting until meat appears + var/animation_delay = GIBBER_ANIMATION_DELAY + + // For hiding gibs, making an even more devious trap (invisible autogibbers) + var/stealthmode = FALSE var/list/victims = list() use_power = 1 @@ -110,25 +114,25 @@ /obj/machinery/gibber/proc/move_into_gibber(var/mob/user,var/mob/living/victim) if(occupant) - to_chat(user, "The gibber is full, empty it first!") + to_chat(user, "The [src] is full, empty it first!") return if(operating) - to_chat(user, "The gibber is locked and running, wait for it to finish.") + to_chat(user, "The [src] is locked and running, wait for it to finish.") return if(!ishuman(victim) || issmall(victim)) - to_chat(user, "This is not suitable for the gibber!") + to_chat(user, "This is not suitable for the [src]]!") return if(victim.abiotic(1)) to_chat(user, "Subject may not have abiotic items on.") return - user.visible_message("[user] starts to put [victim] into the gibber!") + user.visible_message("[user] starts to put [victim] into the [src]!") add_fingerprint(user) if(do_after(user, 30, target = victim) && user.Adjacent(src) && victim.Adjacent(user) && !occupant) - user.visible_message("[user] stuffs [victim] into the gibber!") + user.visible_message("[user] stuffs [victim] into the [src]]!") victim.forceMove(src) occupant = victim @@ -195,16 +199,16 @@ holder2.layer = MOB_LAYER + 0.1 //3D, it's above the mob, rest of the gibber is behind holder2.anchored = 1 - animate(holder, pixel_y = 16, time = GIBBER_ANIMATION_DELAY) //animate going down + animate(holder, pixel_y = 16, time = animation_delay) //animate going down - sleep(GIBBER_ANIMATION_DELAY) + sleep(animation_delay) holder.overlays -= feedee //reset static icon feedee.icon += icon('icons/obj/kitchen.dmi', "footicon") //this is some byond magic; += to the icon var with a black and white image will mask it holder.overlays += feedee - animate(holder, pixel_y = -3, time = GIBBER_ANIMATION_DELAY) //animate going down further + animate(holder, pixel_y = -3, time = animation_delay) //animate going down further - sleep(GIBBER_ANIMATION_DELAY) //time everything right, animate doesn't prevent proc from continuing + sleep(animation_delay) //time everything right, animate doesn't prevent proc from continuing qdel(holder) //get rid of holder object qdel(holder2) //get rid of holder object @@ -231,7 +235,7 @@ operating = 1 update_icon() var/offset = prob(50) ? -2 : 2 - animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = 200) //start shaking + animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = gibtime * 5) //start shaking var/slab_name = occupant.name var/slab_count = 3 @@ -254,8 +258,8 @@ new /obj/effect/decal/cleanable/blood/gibs(src) if(!UserOverride) - occupant.attack_log += "\[[time_stamp()]\] Was gibbed by [key_name(user)]" //One shall not simply gib a mob unnoticed! - user.attack_log += "\[[time_stamp()]\] Gibbed [key_name(occupant)]" + occupant.create_attack_log("Was gibbed by [key_name(user)]") //One shall not simply gib a mob unnoticed!) + user.create_attack_log("Gibbed [key_name(occupant)]") if(occupant.ckey) msg_admin_attack("[key_name_admin(user)] gibbed [key_name_admin(occupant)]") @@ -266,11 +270,10 @@ occupant.LAssailant = user else //this looks ugly but it's better than a copy-pasted startgibbing proc override - occupant.attack_log += "\[[time_stamp()]\] Was gibbed by an autogibber (\the [src])" + occupant.create_attack_log("Was gibbed by an autogibber (\the [src])") occupant.emote("scream") playsound(get_turf(src), 'sound/goonstation/effects/gib.ogg', 50, 1) - victims += "\[[time_stamp()]\] [occupant.name] ([occupant.ckey]) killed by [UserOverride ? "Autogibbing" : "[user] ([user.ckey])"]" //have to do this before ghostizing occupant.death(1) occupant.ghostize() @@ -281,15 +284,20 @@ playsound(get_turf(src), 'sound/effects/splat.ogg', 50, 1) operating = 0 - for(var/obj/item/thing in contents) //Meat is spawned inside the gibber and thrown out afterwards. - thing.loc = get_turf(thing) // Drop it onto the turf for throwing. - thing.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) // Being pelted with bits of meat and bone would hurt. - sleep(1) + if(stealthmode) + for(var/atom/movable/AM in contents) + qdel(AM) + sleep(1) + else + for(var/obj/item/thing in contents) //Meat is spawned inside the gibber and thrown out afterwards. + thing.loc = get_turf(thing) // Drop it onto the turf for throwing. + thing.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) // Being pelted with bits of meat and bone would hurt. + sleep(1) - for(var/obj/effect/gibs in contents) //throw out the gibs too - gibs.loc = get_turf(gibs) //drop onto turf for throwing - gibs.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) - sleep(1) + for(var/obj/effect/gibs in contents) //throw out the gibs too + gibs.loc = get_turf(gibs) //drop onto turf for throwing + gibs.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) + sleep(1) pixel_x = initial(pixel_x) //return to it's spot after shaking operating = 0 @@ -306,6 +314,8 @@ var/acceptdir = NORTH var/lastacceptdir = NORTH var/turf/lturf + var/consumption_delay = 3 SECONDS + var/list/victim_targets = list() /obj/machinery/gibber/autogibber/New() ..() @@ -320,7 +330,7 @@ RefreshParts() /obj/machinery/gibber/autogibber/process() - if(!lturf || occupant || locked || dirty || operating) + if(!lturf || occupant || locked || dirty || operating || victim_targets.len) return if(acceptdir != lastacceptdir) @@ -331,15 +341,21 @@ lturf = T for(var/mob/living/carbon/human/H in lturf) - if(istype(H) && H.loc == lturf) - visible_message({"\The [src] states, "Food detected!""}) - sleep(30) + victim_targets += H + + if(victim_targets.len) + visible_message({"\The [src] states, "Food detected!""}) + sleep(consumption_delay) + for(var/mob/living/carbon/H in victim_targets) if(H.loc == lturf) //still standing there if(force_move_into_gibber(H)) + locked = 1 // no escape ejectclothes(occupant) cleanbay() startgibbing(null, 1) + locked = 0 break + victim_targets.Cut() /obj/machinery/gibber/autogibber/proc/force_move_into_gibber(var/mob/living/carbon/human/victim) if(!istype(victim)) return 0 @@ -364,7 +380,7 @@ continue if(istype(O,/obj/item/organ)) continue - if(O.flags & NODROP) + if(O.flags & NODROP || stealthmode) qdel(O) //they are already dead by now H.unEquip(O) O.loc = loc @@ -372,7 +388,7 @@ sleep(1) for(var/obj/item/clothing/C in H) - if(C.flags & NODROP) + if(C.flags & NODROP || stealthmode) qdel(C) H.unEquip(C) C.loc = loc @@ -384,7 +400,9 @@ /obj/machinery/gibber/autogibber/proc/cleanbay() var/spats = 0 //keeps track of how many items get spit out. Don't show a message if none are found. for(var/obj/O in src) - if(istype(O)) + if(stealthmode) + qdel(O) + else if(istype(O)) O.loc = loc O.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) spats++ diff --git a/code/modules/food_and_drinks/kitchen_machinery/juicer.dm b/code/modules/food_and_drinks/kitchen_machinery/juicer.dm index 03ceb5c0034..edf714d0f21 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/juicer.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/juicer.dm @@ -4,27 +4,29 @@ icon = 'icons/obj/kitchen.dmi' icon_state = "juicer1" layer = 2.9 - density = 0 + density = 1 anchored = 0 use_power = 1 idle_power_usage = 5 active_power_usage = 100 + pass_flags = PASSTABLE var/obj/item/weapon/reagent_containers/beaker = null - var/global/list/allowed_items = list( + var/global/list/allowed_items = list ( + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato = "tomatojuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot = "carrotjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/grapes = "grapejuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/grapes/green = "grapejuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/banana = "banana", + /obj/item/weapon/reagent_containers/food/snacks/grown/potato = "potato", + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lemon = "lemonjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/orange = "orangejuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lime = "limejuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/watermelon = "watermelonjuice", /obj/item/weapon/reagent_containers/food/snacks/watermelonslice = "watermelonjuice", - /obj/item/weapon/reagent_containers/food/snacks/grown = "water", - ) - - var/global/list/allowed_tags = list ( - "tomato" = "tomatojuice", - "carrot" = "carrotjuice", - "berries" = "berryjuice", - "banana" = "banana", - "potato" = "potato", - "lemon" = "lemonjuice", - "orange" = "orangejuice", - "lime" = "limejuice", - "poisonberries" = "poisonberryjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison = "poisonberryjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/berries = "berryjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/pumpkin = "pumpkinjuice", + /obj/item/weapon/reagent_containers/food/snacks/grown/blumpkin = "blumpkinjuice", ) /obj/machinery/juicer/New() @@ -135,23 +137,18 @@ beaker = null update_icon() -/obj/machinery/juicer/proc/get_juice_id(var/obj/item/weapon/reagent_containers/food/snacks/O) - if(istype(O, /obj/item/weapon/reagent_containers/food/snacks/watermelonslice)) - return "watermelonjuice" - else if(istype(O, /obj.item/weapon/reagent_containers/food/snacks/grown)) - var/obj/item/weapon/reagent_containers/food/snacks/grown/G = O - for(var/i in allowed_tags) - if(G.seed.kitchen_tag == allowed_tags[i]) - return allowed_tags[i] - return "water" +/obj/machinery/juicer/proc/get_juice_id(obj/item/weapon/reagent_containers/food/snacks/grown/O) + for (var/i in allowed_items) + if (istype(O, i)) + return allowed_items[i] -/obj/machinery/juicer/proc/get_juice_amount(var/obj/item/weapon/reagent_containers/food/snacks/grown/O) - if(!istype(O)) +/obj/machinery/juicer/proc/get_juice_amount(obj/item/weapon/reagent_containers/food/snacks/grown/O) + if(!istype(O) || !O.seed) return 5 - else if(O.potency == -1) + else if (O.seed.potency == -1) return 5 else - return round(5*sqrt(O.potency)) + return round(5*sqrt(O.seed.potency)) /obj/machinery/juicer/proc/juice() power_change() //it is a portable machine @@ -167,19 +164,21 @@ if(beaker.reagents.total_volume >= beaker.reagents.maximum_volume) break -/obj/structure/closet/crate/juice - New() - ..() - new/obj/machinery/juicer(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) - new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) \ No newline at end of file +/obj/structure/closet/crate/juice/New() + ..() + new/obj/machinery/juicer(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/grapes(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/grapes(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/tomato(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/carrot(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/berries(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/banana(src) + new/obj/item/weapon/reagent_containers/food/snacks/grown/grapes(src) diff --git a/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm b/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm index ef7591e3955..baf5e8e98ee 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm @@ -8,7 +8,7 @@ use_power = 1 idle_power_usage = 5 active_power_usage = 100 - flags = OPENCONTAINER | NOREACT + flags = OPENCONTAINER var/operating = 0 // Is it on? var/dirty = 0 // = {0..100} Does it need cleaning? var/broken = 0 // ={0,1,2} How broken is it??? @@ -33,6 +33,7 @@ /obj/machinery/kitchen_machine/New() create_reagents(100) + reagents.set_reacting(FALSE) if(!available_recipes) available_recipes = new acceptable_items = new @@ -45,7 +46,7 @@ acceptable_items |= item for(var/reagent in recipe.reagents) acceptable_reagents |= reagent - if(recipe.items || recipe.fruit) + if(recipe.items) max_n_of_items = max(max_n_of_items,recipe.count_n_items()) else qdel(recipe) diff --git a/code/modules/food_and_drinks/kitchen_machinery/processor.dm b/code/modules/food_and_drinks/kitchen_machinery/processor.dm index 5183fe6a4fa..df9d1dddf4d 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/processor.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/processor.dm @@ -71,21 +71,34 @@ input = /obj/item/weapon/reagent_containers/food/snacks/meat output = /obj/item/weapon/reagent_containers/food/snacks/meatball -/datum/food_processor_process/potato - input = "potato" +/datum/food_processor_process/potatowedges + input = /obj/item/weapon/reagent_containers/food/snacks/grown/potato/wedges output = /obj/item/weapon/reagent_containers/food/snacks/fries +/datum/food_processor_process/sweetpotato + input = /obj/item/weapon/reagent_containers/food/snacks/grown/potato/sweet + output = /obj/item/weapon/reagent_containers/food/snacks/yakiimo + +/datum/food_processor_process/potato + input = /obj/item/weapon/reagent_containers/food/snacks/grown/potato + output = /obj/item/weapon/reagent_containers/food/snacks/tatortot + /datum/food_processor_process/carrot - input = "carrot" + input = /obj/item/weapon/reagent_containers/food/snacks/grown/carrot output = /obj/item/weapon/reagent_containers/food/snacks/carrotfries /datum/food_processor_process/soybeans - input = "soybeans" + input = /obj/item/weapon/reagent_containers/food/snacks/grown/soybeans output = /obj/item/weapon/reagent_containers/food/snacks/soydope /datum/food_processor_process/spaghetti input = /obj/item/weapon/reagent_containers/food/snacks/doughslice output = /obj/item/weapon/reagent_containers/food/snacks/spagetti + +/datum/food_processor_process/parsnip + input = /obj/item/weapon/reagent_containers/food/snacks/grown/parsnip + output = /obj/item/weapon/reagent_containers/food/snacks/roastparsnip + ///////////////////////// ///END OBJECT RECIPIES/// ///////////////////////// @@ -142,14 +155,10 @@ //END RECIPE DATUMS -/obj/machinery/processor/proc/select_recipe(var/X) +/obj/machinery/processor/proc/select_recipe(X) for(var/Type in subtypesof(/datum/food_processor_process) - /datum/food_processor_process/mob) var/datum/food_processor_process/P = new Type() - if(istype(X, /obj/item/weapon/reagent_containers/food/snacks/grown)) - var/obj/item/weapon/reagent_containers/food/snacks/grown/G = X - if(G.seed.kitchen_tag != P.input) - continue - else if(!istype(X, P.input)) + if(!istype(X, P.input)) continue return P return 0 diff --git a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm index 149744675a9..3c694f993cf 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm @@ -10,7 +10,6 @@ use_power = 1 idle_power_usage = 5 active_power_usage = 100 - flags = NOREACT var/max_n_of_items = 1500 var/icon_on = "smartfridge" var/icon_off = "smartfridge-off" @@ -25,6 +24,8 @@ /obj/machinery/smartfridge/New() ..() + create_reagents() + reagents.set_reacting(FALSE) component_parts = list() var/obj/item/weapon/circuitboard/smartfridge/board = new(null) board.set_type(type) @@ -54,7 +55,7 @@ return ..() /obj/machinery/smartfridge/proc/accept_check(obj/item/O) - if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/grown/) || istype(O,/obj/item/seeds/)) + if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/grown/) || istype(O,/obj/item/seeds/) || istype(O,/obj/item/weapon/grown/)) return 1 return 0 @@ -82,7 +83,7 @@ return 1 if(istype(O,/obj/item/weapon/storage/pill_bottle/)) return 1 - if(istype(O,/obj/item/weapon/reagent_containers/food/pill/)) + if(ispill(O)) return 1 return 0 @@ -108,7 +109,7 @@ return 1 if(istype(O,/obj/item/weapon/storage/pill_bottle/)) return 1 - if(istype(O,/obj/item/weapon/reagent_containers/food/pill/)) + if(ispill(O)) return 1 return 0 @@ -192,14 +193,15 @@ * Item Adding ********************/ -/obj/machinery/smartfridge/attackby(obj/item/O, mob/user) - if(istype(O, /obj/item/weapon/screwdriver) && anchored) - playsound(loc, 'sound/items/Screwdriver.ogg', 50, 1) - panel_open = !panel_open - to_chat(user, "You [panel_open ? "open" : "close"] the maintenance panel.") - overlays.Cut() - if(panel_open) - overlays += image(icon, "[initial(icon_state)]-panel") +/obj/machinery/smartfridge/default_deconstruction_screwdriver(mob/user, obj/item/weapon/screwdriver/S) + . = ..(user, icon_state, icon_state, S) + + overlays.Cut() + if(panel_open) + overlays += image(icon, "[initial(icon_state)]-panel") + +/obj/machinery/smartfridge/attackby(obj/item/O, var/mob/user) + if(default_deconstruction_screwdriver(user, O)) return if(exchange_parts(user, O)) @@ -305,7 +307,7 @@ to_chat(user, "Some items are refused.") nanomanager.update_uis(src) -/obj/machinery/smartfridge/secure/emag_act(user) +/obj/machinery/smartfridge/secure/emag_act(mob/user) emagged = 1 locked = -1 to_chat(user, "You short out the product lock on [src].") @@ -401,6 +403,127 @@ visible_message("[src] launches [throw_item.name] at [target.name]!") return 1 +// ---------------------------- +// Drying Rack 'smartfridge' +// ---------------------------- +/obj/machinery/smartfridge/drying_rack + name = "drying rack" + desc = "A wooden contraption, used to dry plant products, food and leather." + icon = 'icons/obj/hydroponics/equipment.dmi' + icon_state = "drying_rack_on" + use_power = 1 + idle_power_usage = 5 + active_power_usage = 200 + icon_on = "drying_rack_on" + icon_off = "drying_rack" + var/drying = FALSE + +/obj/machinery/smartfridge/drying_rack/New() + ..() + if(component_parts && component_parts.len) + component_parts.Cut() + component_parts = null + +/obj/machinery/smartfridge/drying_rack/Destroy() + new /obj/item/stack/sheet/wood(loc, 10) + return ..() + +/obj/machinery/smartfridge/drying_rack/RefreshParts() + return + +/obj/machinery/smartfridge/drying_rack/default_deconstruction_screwdriver() + return + +/obj/machinery/smartfridge/drying_rack/exchange_parts() + return + +/obj/machinery/smartfridge/drying_rack/spawn_frame() + return + +/obj/machinery/smartfridge/drying_rack/default_deconstruction_crowbar(obj/item/weapon/crowbar/C, ignore_panel = 1) + ..() + +/obj/machinery/smartfridge/drying_rack/power_change() + if(powered() && anchored) + stat &= ~NOPOWER + else + stat |= NOPOWER + toggle_drying(TRUE) + update_icon() + +/obj/machinery/smartfridge/drying_rack/load() //For updating the filled overlay + ..() + update_icon() + +/obj/machinery/smartfridge/drying_rack/update_icon() + ..() + overlays.Cut() + if(drying) + overlays += "drying_rack_drying" + if(contents.len) + overlays += "drying_rack_filled" + +/obj/machinery/smartfridge/drying_rack/process() + ..() + if(drying) + if(rack_dry())//no need to update unless something got dried + update_icon() + +/obj/machinery/smartfridge/drying_rack/accept_check(obj/item/O) + if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/)) + var/obj/item/weapon/reagent_containers/food/snacks/S = O + if(S.dried_type) + return TRUE + if(istype(O,/obj/item/stack/sheet/wetleather/)) + return TRUE + return FALSE + +/obj/machinery/smartfridge/drying_rack/proc/toggle_drying(forceoff) + if(drying || forceoff) + drying = FALSE + use_power = 1 + else + drying = TRUE + use_power = 2 + update_icon() + +/obj/machinery/smartfridge/drying_rack/proc/rack_dry() + for(var/obj/item/weapon/reagent_containers/food/snacks/S in contents) + if(S.dried_type == S.type)//if the dried type is the same as the object's type, don't bother creating a whole new item... + S.color = "#ad7257" + S.dry = TRUE + S.forceMove(get_turf(src)) + else + var/dried = S.dried_type + new dried(loc) + qdel(S) + return TRUE + for(var/obj/item/stack/sheet/wetleather/WL in contents) + var/obj/item/stack/sheet/leather/L = new(loc) + L.amount = WL.amount + qdel(WL) + return TRUE + return FALSE + +/obj/machinery/smartfridge/drying_rack/emp_act(severity) + ..() + atmos_spawn_air(SPAWN_HEAT) + +/obj/machinery/smartfridge/drying_rack/verb/adjust_drying() + set category = "Object" + set name = "Toggle Drying" + set src in view(1) + + if(!iscarbon(usr)) + to_chat(usr, "You can't do that!") + return + + if(usr.incapacitated()) + return + + toggle_drying(FALSE) + update_icon() + /************************ * Secure SmartFridges *************************/ @@ -413,4 +536,4 @@ to_chat(usr, "Access denied.") nanomanager.update_uis(src) return 0 - return ..() + return ..() \ No newline at end of file diff --git a/code/modules/food_and_drinks/recipes/recipes_candy.dm b/code/modules/food_and_drinks/recipes/recipes_candy.dm index 98f969a17ec..4dcecb657b8 100644 --- a/code/modules/food_and_drinks/recipes/recipes_candy.dm +++ b/code/modules/food_and_drinks/recipes/recipes_candy.dm @@ -27,14 +27,14 @@ /datum/recipe/candy/fudge_peanut reagents = list("sugar" = 5, "milk" = 5) - items = list(/obj/item/weapon/reagent_containers/food/snacks/chocolatebar) - fruit = list("peanuts" = 3) + items = list(/obj/item/weapon/reagent_containers/food/snacks/chocolatebar, /obj/item/weapon/reagent_containers/food/snacks/grown/peanuts, + /obj/item/weapon/reagent_containers/food/snacks/grown/peanuts, /obj/item/weapon/reagent_containers/food/snacks/grown/peanuts) result = /obj/item/weapon/reagent_containers/food/snacks/candy/fudge/peanut /datum/recipe/candy/fudge_cherry reagents = list("sugar" = 5, "milk" = 5) - items = list(/obj/item/weapon/reagent_containers/food/snacks/chocolatebar) - fruit = list("cherries" = 3) + items = list(/obj/item/weapon/reagent_containers/food/snacks/chocolatebar, /obj/item/weapon/reagent_containers/food/snacks/grown/cherries, + /obj/item/weapon/reagent_containers/food/snacks/grown/cherries, /obj/item/weapon/reagent_containers/food/snacks/grown/cherries) result = /obj/item/weapon/reagent_containers/food/snacks/candy/fudge/cherry /datum/recipe/candy/fudge_cookies_n_cream @@ -50,8 +50,8 @@ items = list( /obj/item/weapon/reagent_containers/food/snacks/chocolatebar, /obj/item/weapon/reagent_containers/food/snacks/candy/caramel, + /obj/item/weapon/reagent_containers/food/snacks/grown/peanuts ) - fruit = list("peanuts" = 1) result = /obj/item/weapon/reagent_containers/food/snacks/candy/fudge/turtle /datum/recipe/candy/fudge @@ -319,10 +319,7 @@ /datum/recipe/candy/gummybear_wtf2 reagents = list() - fruit = list("ambrosia" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/candy/gummybear - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/candy/gummybear, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris) result = /obj/item/weapon/reagent_containers/food/snacks/candy/gummybear/wtf // *********************************************************** @@ -386,10 +383,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/candy/gummyworm/wtf /datum/recipe/candy/gummyworm_wtf2 - fruit = list("ambrosia" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/candy/gummyworm - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/candy/gummyworm, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris) result = /obj/item/weapon/reagent_containers/food/snacks/candy/gummyworm/wtf // *********************************************************** @@ -489,10 +483,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/candy/jellybean/wtf /datum/recipe/candy/jellybean_wtf2 - fruit = list("ambrosia" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/candy/jellybean - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/candy/jellybean, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris) result = /obj/item/weapon/reagent_containers/food/snacks/candy/jellybean/wtf // *********************************************************** @@ -505,7 +496,7 @@ /obj/item/weapon/reagent_containers/food/snacks/candy/candybar, /obj/item/weapon/reagent_containers/food/snacks/candy/caramel, ) - result = /obj/item/weapon/reagent_containers/food/snacks/candy/candybar/caramel + result = /obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/caramel /datum/recipe/candy/toolerone reagents = list() @@ -513,7 +504,7 @@ /obj/item/weapon/reagent_containers/food/snacks/candy/candybar, /obj/item/weapon/reagent_containers/food/snacks/candy/nougat, ) - result = /obj/item/weapon/reagent_containers/food/snacks/candy/candybar/nougat + result = /obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/nougat /datum/recipe/candy/yumbaton reagents = list() @@ -521,14 +512,14 @@ /obj/item/weapon/reagent_containers/food/snacks/candy/candybar, /obj/item/weapon/reagent_containers/food/snacks/candy/toffee, ) - result = /obj/item/weapon/reagent_containers/food/snacks/candy/candybar/toffee + result = /obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/toffee /datum/recipe/candy/crunch reagents = list("rice" = 5) items = list( /obj/item/weapon/reagent_containers/food/snacks/candy/candybar, ) - result = /obj/item/weapon/reagent_containers/food/snacks/candy/candybar/rice + result = /obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/rice /datum/recipe/candy/toxinstest reagents = list() @@ -537,4 +528,4 @@ /obj/item/weapon/reagent_containers/food/snacks/candy/caramel, /obj/item/weapon/reagent_containers/food/snacks/candy/nougat, ) - result = /obj/item/weapon/reagent_containers/food/snacks/candy/candybar/caramel_nougat + result = /obj/item/weapon/reagent_containers/food/snacks/candy/confectionery/caramel_nougat diff --git a/code/modules/food_and_drinks/recipes/recipes_microwave.dm b/code/modules/food_and_drinks/recipes/recipes_microwave.dm index 5903e191b4e..962aa5e92a4 100644 --- a/code/modules/food_and_drinks/recipes/recipes_microwave.dm +++ b/code/modules/food_and_drinks/recipes/recipes_microwave.dm @@ -10,11 +10,8 @@ result = /obj/item/weapon/reagent_containers/food/snacks/boiledegg /datum/recipe/microwave/dionaroast - fruit = list("apple" = 1) reagents = list("facid" = 5) //It dissolves the carapace. Still poisonous, though. - items = list( - /obj/item/weapon/holder/diona, - ) + items = list(/obj/item/weapon/holder/diona, /obj/item/weapon/reagent_containers/food/snacks/grown/apple) result = /obj/item/weapon/reagent_containers/food/snacks/dionaroast /datum/recipe/microwave/jellydonut @@ -29,24 +26,24 @@ items = list( /obj/item/weapon/reagent_containers/food/snacks/dough ) - result = /obj/item/weapon/reagent_containers/food/snacks/donut/slimejelly + result = /obj/item/weapon/reagent_containers/food/snacks/donut/jelly/slimejelly /datum/recipe/microwave/jellydonut/cherry reagents = list("cherryjelly" = 5, "sugar" = 5) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough ) - result = /obj/item/weapon/reagent_containers/food/snacks/donut/cherryjelly + result = /obj/item/weapon/reagent_containers/food/snacks/donut/jelly/cherryjelly /datum/recipe/microwave/donut reagents = list("sugar" = 5) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough ) - result = /obj/item/weapon/reagent_containers/food/snacks/donut/normal + result = /obj/item/weapon/reagent_containers/food/snacks/donut /datum/recipe/microwave/donut/sprinkles - reagents = list("sugar" = 5, "sprinkles" = 3) + reagents = list("sugar" = 5, "sprinkles" = 2) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough ) @@ -150,16 +147,16 @@ result = /obj/item/weapon/reagent_containers/food/snacks/warmdonkpocket /datum/recipe/microwave/eggplantparm - fruit = list("eggplant" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/eggplant ) result = /obj/item/weapon/reagent_containers/food/snacks/eggplantparm /datum/recipe/microwave/soylenviridians - fruit = list("soybeans" = 1) reagents = list("flour" = 10) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/soybeans) result = /obj/item/weapon/reagent_containers/food/snacks/soylenviridians /datum/recipe/microwave/soylentgreen @@ -185,25 +182,27 @@ result = /obj/item/weapon/reagent_containers/food/snacks/cheesyfries /datum/recipe/microwave/cubancarp - fruit = list("chili" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/carpmeat, + /obj/item/weapon/reagent_containers/food/snacks/grown/chili ) result = /obj/item/weapon/reagent_containers/food/snacks/cubancarp /datum/recipe/microwave/popcorn - fruit = list("corn" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/corn) result = /obj/item/weapon/reagent_containers/food/snacks/popcorn /datum/recipe/microwave/spacylibertyduff reagents = list("water" = 5, "vodka" = 5) - fruit = list("libertycap" = 3) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/libertycap, /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/libertycap, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/libertycap) result = /obj/item/weapon/reagent_containers/food/snacks/spacylibertyduff /datum/recipe/microwave/amanitajelly reagents = list("water" = 5, "vodka" = 5) - fruit = list("amanita" = 3) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita, /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita) result = /obj/item/weapon/reagent_containers/food/snacks/amanitajelly /datum/recipe/microwave/amanitajelly/make_food(obj/container) @@ -213,23 +212,18 @@ /datum/recipe/microwave/meatballsoup reagents = list("water" = 10) - fruit = list("potato" = 1, "carrot" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/meatball , - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/meatball, /obj/item/weapon/reagent_containers/food/snacks/grown/potato, /obj/item/weapon/reagent_containers/food/snacks/grown/carrot) result = /obj/item/weapon/reagent_containers/food/snacks/meatballsoup /datum/recipe/microwave/vegetablesoup reagents = list("water" = 10) - fruit = list("carrot" = 1, "corn" = 1, "eggplant" = 1, "potato" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/potato, /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, + /obj/item/weapon/reagent_containers/food/snacks/grown/corn, /obj/item/weapon/reagent_containers/food/snacks/grown/eggplant) result = /obj/item/weapon/reagent_containers/food/snacks/vegetablesoup /datum/recipe/microwave/nettlesoup reagents = list("water" = 10) - fruit = list("nettle" = 1, "potato" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/egg, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/egg, /obj/item/weapon/grown/nettle/basic, /obj/item/weapon/reagent_containers/food/snacks/grown/potato) result = /obj/item/weapon/reagent_containers/food/snacks/nettlesoup /datum/recipe/microwave/wishsoup @@ -237,17 +231,11 @@ result= /obj/item/weapon/reagent_containers/food/snacks/wishsoup /datum/recipe/microwave/hotchili - fruit = list("chili" = 1, "tomato" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/meat, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/grown/chili, /obj/item/weapon/reagent_containers/food/snacks/grown/tomato) result = /obj/item/weapon/reagent_containers/food/snacks/hotchili /datum/recipe/microwave/coldchili - fruit = list("icechili" = 1, "tomato" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/meat, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/grown/icepepper, /obj/item/weapon/reagent_containers/food/snacks/grown/tomato) result = /obj/item/weapon/reagent_containers/food/snacks/coldchili /datum/recipe/microwave/spellburger @@ -275,10 +263,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/bigbiteburger /datum/recipe/microwave/enchiladas - fruit = list("chili" = 2, "corn" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/cutlet, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/cutlet, /obj/item/weapon/reagent_containers/food/snacks/grown/chili, /obj/item/weapon/reagent_containers/food/snacks/grown/corn) result = /obj/item/weapon/reagent_containers/food/snacks/enchiladas /datum/recipe/microwave/burrito @@ -292,11 +277,8 @@ result = /obj/item/weapon/reagent_containers/food/snacks/burrito /datum/recipe/microwave/monkeysdelight - fruit = list("banana" = 1) reagents = list("sodiumchloride" = 1, "blackpepper" = 1, "flour" = 10) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/monkeycube - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/monkeycube, /obj/item/weapon/reagent_containers/food/snacks/grown/banana) result = /obj/item/weapon/reagent_containers/food/snacks/monkeysdelight /datum/recipe/microwave/fishandchips @@ -323,15 +305,14 @@ /datum/recipe/microwave/tomatosoup reagents = list("water" = 10) - fruit = list("tomato" = 2) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/tomato, /obj/item/weapon/reagent_containers/food/snacks/grown/tomato) result = /obj/item/weapon/reagent_containers/food/snacks/tomatosoup /datum/recipe/microwave/stew reagents = list("water" = 10) - fruit = list("tomato" = 1, "potato" = 1, "carrot" = 1, "eggplant" = 1, "mushroom" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/meat, - ) + items= list(/obj/item/weapon/reagent_containers/food/snacks/grown/tomato, /obj/item/weapon/reagent_containers/food/snacks/grown/potato, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, /obj/item/weapon/reagent_containers/food/snacks/grown/eggplant, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, /obj/item/weapon/reagent_containers/food/snacks/meat) result = /obj/item/weapon/reagent_containers/food/snacks/stew /datum/recipe/microwave/slimetoast @@ -359,11 +340,8 @@ result = /obj/item/weapon/reagent_containers/food/snacks/milosoup /datum/recipe/microwave/stewedsoymeat - fruit = list("carrot" = 1, "tomato" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/soydope, - /obj/item/weapon/reagent_containers/food/snacks/soydope, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/soydope, /obj/item/weapon/reagent_containers/food/snacks/soydope, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, /obj/item/weapon/reagent_containers/food/snacks/grown/tomato) result = /obj/item/weapon/reagent_containers/food/snacks/stewedsoymeat /datum/recipe/microwave/boiledspagetti @@ -383,17 +361,12 @@ /datum/recipe/microwave/pastatomato reagents = list("water" = 5) - fruit = list("tomato" = 2) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/spagetti, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/spagetti, /obj/item/weapon/reagent_containers/food/snacks/grown/tomato, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato) result = /obj/item/weapon/reagent_containers/food/snacks/pastatomato /datum/recipe/microwave/poppypretzel - items = list( - /obj/item/seeds/poppyseed, - /obj/item/weapon/reagent_containers/food/snacks/dough, - ) + items = list(/obj/item/seeds/poppy, /obj/item/weapon/reagent_containers/food/snacks/dough) result = /obj/item/weapon/reagent_containers/food/snacks/poppypretzel /datum/recipe/microwave/meatballspagetti @@ -418,19 +391,19 @@ /datum/recipe/microwave/superbiteburger reagents = list("sodiumchloride" = 5, "blackpepper" = 5) - fruit = list("tomato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/bigbiteburger, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/boiledegg, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/superbiteburger /datum/recipe/microwave/candiedapple reagents = list("water" = 5, "sugar" = 5) - fruit = list("apple" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/apple) result = /obj/item/weapon/reagent_containers/food/snacks/candiedapple /datum/recipe/microwave/slimeburger @@ -473,19 +446,18 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/bloodsoup reagents = list("blood" = 10) - fruit = list("bloodtomato" = 2) + items = list(/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 /datum/recipe/microwave/slimesoup reagents = list("water" = 10, "slimejelly" = 5) - items = list() result = /obj/item/weapon/reagent_containers/food/snacks/slimesoup /datum/recipe/microwave/clownstears reagents = list("water" = 10) - fruit = list("banana" = 1) items = list( /obj/item/weapon/ore/bananium, + /obj/item/weapon/reagent_containers/food/snacks/grown/banana ) result = /obj/item/weapon/reagent_containers/food/snacks/clownstears @@ -519,25 +491,26 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/mushroomsoup reagents = list("water" = 5, "milk" = 5) - fruit = list("mushroom" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom) result = /obj/item/weapon/reagent_containers/food/snacks/mushroomsoup /datum/recipe/microwave/chawanmushi reagents = list("water" = 5, "soysauce" = 5) - fruit = list("mushroom" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/egg, /obj/item/weapon/reagent_containers/food/snacks/egg, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom ) result = /obj/item/weapon/reagent_containers/food/snacks/chawanmushi /datum/recipe/microwave/beetsoup reagents = list("water" = 10) - fruit = list("whitebeet" = 1, "cabbage" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/whitebeet, /obj/item/weapon/reagent_containers/food/snacks/grown/cabbage) result = /obj/item/weapon/reagent_containers/food/snacks/beetsoup /datum/recipe/microwave/herbsalad - fruit = list("ambrosia" = 3, "apple" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, + /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, /obj/item/weapon/reagent_containers/food/snacks/grown/apple) result = /obj/item/weapon/reagent_containers/food/snacks/herbsalad /datum/recipe/microwave/herbsalad/make_food(obj/container) @@ -546,14 +519,14 @@ datum/recipe/microwave/slimesandwich return being_cooked /datum/recipe/microwave/aesirsalad - fruit = list("ambrosiadeus" = 3, "goldapple" = 1) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus, + /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus, /obj/item/weapon/reagent_containers/food/snacks/grown/apple/gold) 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, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, + /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris, /obj/item/weapon/reagent_containers/food/snacks/grown/potato, + /obj/item/weapon/reagent_containers/food/snacks/meatball) result = /obj/item/weapon/reagent_containers/food/snacks/validsalad /datum/recipe/microwave/validsalad/make_food(obj/container) @@ -565,15 +538,12 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/wrap reagents = list("soysauce" = 10) - fruit = list("cabbage" = 1) - items = list( - /obj/item/weapon/reagent_containers/food/snacks/friedegg, - ) + items = list(/obj/item/weapon/reagent_containers/food/snacks/friedegg, /obj/item/weapon/reagent_containers/food/snacks/grown/cabbage ) result = /obj/item/weapon/reagent_containers/food/snacks/wrap /datum/recipe/microwave/beans reagents = list("ketchup" = 5) - fruit = list("soybeans" = 2) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/soybeans, /obj/item/weapon/reagent_containers/food/snacks/grown/soybeans) result = /obj/item/weapon/reagent_containers/food/snacks/beans /datum/recipe/microwave/benedict @@ -586,10 +556,10 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/meatbun reagents = list("soysauce" = 5) - fruit = list("cabbage" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/meatball, + /obj/item/weapon/reagent_containers/food/snacks/grown/cabbage ) result = /obj/item/weapon/reagent_containers/food/snacks/meatbun @@ -610,9 +580,9 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/friedbanana reagents = list("sugar" = 10, "cornoil" = 5) - fruit = list("banana" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/banana ) result = /obj/item/weapon/reagent_containers/food/snacks/friedbanana @@ -655,8 +625,8 @@ datum/recipe/microwave/slimesandwich result = /obj/item/weapon/reagent_containers/food/snacks/sashimi /datum/recipe/microwave/mashedtaters - fruit = list("potato" = 1) reagents = list("gravy" = 5) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/potato) result = /obj/item/weapon/reagent_containers/food/snacks/mashed_potatoes ////////////////////////////////////////// @@ -671,12 +641,6 @@ datum/recipe/microwave/slimesandwich ) result = /obj/item/weapon/reagent_containers/food/snacks/taco -/datum/recipe/microwave/meatball - items = list( - /obj/item/weapon/reagent_containers/food/snacks/rawmeatball - ) - result = /obj/item/weapon/reagent_containers/food/snacks/meatball - /datum/recipe/microwave/fries items = list( /obj/item/weapon/reagent_containers/food/snacks/rawsticks diff --git a/code/modules/food_and_drinks/recipes/recipes_oven.dm b/code/modules/food_and_drinks/recipes/recipes_oven.dm index d20c06e260f..473641c4cc8 100644 --- a/code/modules/food_and_drinks/recipes/recipes_oven.dm +++ b/code/modules/food_and_drinks/recipes/recipes_oven.dm @@ -51,11 +51,11 @@ /datum/recipe/oven/bananabread reagents = list("milk" = 5, "sugar" = 15) - fruit = list("banana" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/banana ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/bananabread @@ -68,11 +68,13 @@ /datum/recipe/oven/carrotcake reagents = list("milk" = 5, "sugar" = 15) - fruit = list("carrot" = 3) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/carrotcake @@ -119,24 +121,24 @@ /datum/recipe/oven/pie reagents = list("sugar" = 5) - fruit = list("banana" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/banana ) result = /obj/item/weapon/reagent_containers/food/snacks/pie /datum/recipe/oven/cherrypie reagents = list("sugar" = 10) - fruit = list("cherries" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/cherries ) result = /obj/item/weapon/reagent_containers/food/snacks/cherrypie /datum/recipe/oven/berryclafoutis - fruit = list("berries" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/berries ) result = /obj/item/weapon/reagent_containers/food/snacks/berryclafoutis @@ -155,9 +157,9 @@ result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/tofubread /datum/recipe/oven/loadedbakedpotato - fruit = list("potato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/potato ) result = /obj/item/weapon/reagent_containers/food/snacks/loadedbakedpotato @@ -194,71 +196,80 @@ return . /datum/recipe/oven/pizzamargherita - fruit = list("tomato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/margherita /datum/recipe/oven/meatpizza - fruit = list("tomato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/meatpizza /datum/recipe/oven/syntipizza - fruit = list("tomato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/meat/syntiflesh, /obj/item/weapon/reagent_containers/food/snacks/meat/syntiflesh, /obj/item/weapon/reagent_containers/food/snacks/meat/syntiflesh, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/meatpizza /datum/recipe/oven/mushroompizza - fruit = list("mushroom" = 5, "tomato" = 1) + items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/mushroompizza /datum/recipe/oven/vegetablepizza - fruit = list("eggplant" = 1, "carrot" = 1, "corn" = 1, "tomato" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, + /obj/item/weapon/reagent_containers/food/snacks/grown/eggplant, + /obj/item/weapon/reagent_containers/food/snacks/grown/carrot, + /obj/item/weapon/reagent_containers/food/snacks/grown/corn, + /obj/item/weapon/reagent_containers/food/snacks/grown/tomato ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/vegetablepizza /datum/recipe/oven/amanita_pie - fruit = list("amanita" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita ) result = /obj/item/weapon/reagent_containers/food/snacks/amanita_pie /datum/recipe/oven/plump_pie - fruit = list("plumphelmet" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/plumphelmet ) result = /obj/item/weapon/reagent_containers/food/snacks/plump_pie /datum/recipe/oven/plumphelmetbiscuit - fruit = list("plumphelmet" = 1) reagents = list("water" = 5, "flour" = 5) + items = list(/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/plumphelmet) result = /obj/item/weapon/reagent_containers/food/snacks/plumphelmetbiscuit /datum/recipe/oven/creamcheesebread @@ -301,49 +312,53 @@ return being_cooked /datum/recipe/oven/applepie - fruit = list("apple" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple ) result = /obj/item/weapon/reagent_containers/food/snacks/applepie /datum/recipe/oven/applecake reagents = list("milk" = 5, "sugar" = 5) - fruit = list("apple" = 2) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/applecake /datum/recipe/oven/orangecake reagents = list("milk" = 5) - fruit = list("orange" = 2) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/orange, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/orange ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/orangecake /datum/recipe/oven/limecake reagents = list("milk" = 5) - fruit = list("lime" = 2) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lime, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lime ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/limecake /datum/recipe/oven/lemoncake reagents = list("milk" = 5) - fruit = list("lemon" = 2) items = list( /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, /obj/item/weapon/reagent_containers/food/snacks/dough, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lemon, + /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lemon ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/lemoncake @@ -370,17 +385,17 @@ /datum/recipe/oven/pumpkinpie reagents = list("milk" = 5, "sugar" = 5) - fruit = list("pumpkin" = 1) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough, + /obj/item/weapon/reagent_containers/food/snacks/grown/pumpkin ) result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/pumpkinpie /datum/recipe/oven/appletart - fruit = list("goldapple" = 1) reagents = list("sugar" = 5, "milk" = 5, "flour" = 10) items = list( - /obj/item/weapon/reagent_containers/food/snacks/egg + /obj/item/weapon/reagent_containers/food/snacks/egg, + /obj/item/weapon/reagent_containers/food/snacks/grown/apple/gold ) result = /obj/item/weapon/reagent_containers/food/snacks/appletart diff --git a/code/modules/food_and_drinks/recipes/tablecraft/recipes_table.dm b/code/modules/food_and_drinks/recipes/tablecraft/recipes_table.dm index b6c943dbdab..f7eb2fa4a68 100644 --- a/code/modules/food_and_drinks/recipes/tablecraft/recipes_table.dm +++ b/code/modules/food_and_drinks/recipes/tablecraft/recipes_table.dm @@ -6,7 +6,6 @@ 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/crafting_recipe/sandwich @@ -55,45 +54,6 @@ result = /obj/item/weapon/reagent_containers/food/snacks/jellyburger/cherry category = CAT_FOOD -/* Temporarily disabled until we can find a workaround for this fruit shit. -/datum/crafting_recipe/herbsalad - name = "herb salad" - fruit = list("ambrosia" = 3, "apple" = 1) - result = /obj/item/weapon/reagent_containers/food/snacks/herbsalad - -/datum/crafting_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/crafting_recipe/aesirsalad - name = "Aesir salad" - fruit = list("ambrosiadeus" = 3, "goldapple" = 1) - result = /obj/item/weapon/reagent_containers/food/snacks/aesirsalad - -/datum/crafting_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/crafting_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/crafting_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 -*/ - /datum/crafting_recipe/notasandwich name = "not-a-sandwich" reqs = list( diff --git a/code/modules/garbage_collection/__gc_info.dm b/code/modules/garbage_collection/__gc_info.dm index be72097a8c9..e36b5fd2b1b 100644 --- a/code/modules/garbage_collection/__gc_info.dm +++ b/code/modules/garbage_collection/__gc_info.dm @@ -1,7 +1,7 @@ /* =============================================================================== - How Garbage Collection Works + How Garbage Collection Works =============================================================================== In BYOND, there are exactly two ways anything gets deleted: @@ -31,8 +31,8 @@ that can't be. There are two main procs involved in this process: /proc/qdel(datumToDelete) This is, effectively, a replacement for del that tells an object to prepare itself to be soft deleted by calling its Destroy() proc. Depending on the qdel hint returned by Destroy(), qdel will queue the object in the garbage collector - (to be hard deleted if it isn't soft deleted), directly delete the object, pool the object, or ignore the object and - assume it will handle deleting itself. An object passed into qdel will have its gcDestroyed var set, so + (to be hard deleted if it isn't soft deleted), directly delete the object, or ignore the object and + assume it will handle deleting itself. An object passed into qdel will have its gcDestroyed var set, so isnull(gcDestroyed) will be true if an object is not being destroyed, and false if it is (which means you should get rid of the reference you have to it). @@ -50,7 +50,7 @@ that can't be. There are two main procs involved in this process: should use a Del proc for any necessary cleanup, as a Destroy proc on them will not automatically get called. When called by qdel, Destroy is expected to return a qdel hint, which determines whether the object should be directly - deleted, queued for deletion, pooled, or ignored entirely; which of these are appropriate will vary, though objects + deleted, queued for deletion, or ignored entirely; which of these are appropriate will vary, though objects should be pooled or queued whenever possible. The full list of qdel hints are in the code for the qdel proc. As mentioned above, gcDestroyed can be used to tell whether an object is being destroyed. This is important, because if @@ -62,7 +62,4 @@ reference immediately. The inner workings of the GC itself and the stuff related to testing it probably don't need a detailed description - if you intend to work with them, it would be best to read the code to understand what they do. -Pooling is related to GC, in that it's meant to reduce deletion overhead, but it does so by re-using objects instead of -deleting them at all. Explaining pooling is outside the scope of this file. - */ \ No newline at end of file diff --git a/code/modules/garbage_collection/garbage_collector.dm b/code/modules/garbage_collection/garbage_collector.dm index 3d6007d313e..e2204788016 100644 --- a/code/modules/garbage_collection/garbage_collector.dm +++ b/code/modules/garbage_collection/garbage_collector.dm @@ -149,8 +149,6 @@ var/global/datum/controller/process/garbage_collector/garbageCollector del(D) if(garbageCollector) garbageCollector.dels_count++ - if(QDEL_HINT_PUTINPOOL) //qdel will put this object in the pool. - PlaceInPool(D,0) if(QDEL_HINT_FINDREFERENCE)//qdel will, if TESTING is enabled, display all references to this object, then queue the object for deletion. #ifdef TESTING D.find_references(remove_from_queue = FALSE) diff --git a/code/modules/hydroponics/beekeeping/beebox.dm b/code/modules/hydroponics/beekeeping/beebox.dm index 817f002f014..18f87a8a45a 100644 --- a/code/modules/hydroponics/beekeeping/beebox.dm +++ b/code/modules/hydroponics/beekeeping/beebox.dm @@ -33,7 +33,7 @@ /obj/structure/beebox name = "apiary" desc = "Dr Miles Manners is just your average Wasp themed super hero by day, but by night he becomes DR BEES!" - icon = 'icons/obj/apiary_bees.dmi' + icon = 'icons/obj/hydroponics/equipment.dmi' icon_state = "beebox" anchored = 1 density = 1 @@ -251,4 +251,4 @@ if(!user.put_in_active_hand(QB)) QB.forceMove(get_turf(src)) visible_message("[user] removes the queen from the apiary.") - queen_bee = null \ No newline at end of file + queen_bee = null diff --git a/code/modules/hydroponics/beekeeping/beekeeper_suit.dm b/code/modules/hydroponics/beekeeping/beekeeper_suit.dm index 93b5b0c53a8..640d022c9e3 100644 --- a/code/modules/hydroponics/beekeeping/beekeeper_suit.dm +++ b/code/modules/hydroponics/beekeeping/beekeeper_suit.dm @@ -13,4 +13,5 @@ icon_state = "beekeeper" item_state = "beekeeper" flags = THICKMATERIAL - allowed = list (/obj/item/weapon/reagent_containers/spray/plantbgone,/obj/item/device/analyzer/plant_analyzer,/obj/item/seeds,/obj/item/weapon/reagent_containers/glass/bottle/fertilizer,/obj/item/weapon/minihoe) + allowed = list (/obj/item/weapon/reagent_containers/spray,/obj/item/device/plant_analyzer,/obj/item/seeds,/obj/item/weapon/reagent_containers/glass/bottle,/obj/item/weapon/cultivator) + diff --git a/code/modules/hydroponics/beekeeping/honey_frame.dm b/code/modules/hydroponics/beekeeping/honey_frame.dm index a58ab7041c7..74eec401d6d 100644 --- a/code/modules/hydroponics/beekeeping/honey_frame.dm +++ b/code/modules/hydroponics/beekeeping/honey_frame.dm @@ -1,8 +1,8 @@ /obj/item/honey_frame name = "honey frame" - desc = "a scaffold for bees to build honeycomb on" - icon = 'icons/obj/apiary_bees.dmi' + desc = "A scaffold for bees to build honeycomb on." + icon = 'icons/obj/hydroponics/equipment.dmi' icon_state = "honey_frame" var/honeycomb_capacity = 10 //10 Honeycomb per frame by default, researchable frames perhaps? diff --git a/code/modules/hydroponics/beekeeping/honeycomb.dm b/code/modules/hydroponics/beekeeping/honeycomb.dm index 23588cc5c48..713e46804e7 100644 --- a/code/modules/hydroponics/beekeeping/honeycomb.dm +++ b/code/modules/hydroponics/beekeeping/honeycomb.dm @@ -1,8 +1,8 @@ /obj/item/weapon/reagent_containers/honeycomb name = "honeycomb" - desc = "a hexagonal mesh of honeycomb" - icon = 'icons/obj/apiary_bees.dmi' + desc = "A hexagonal mesh of honeycomb." + icon = 'icons/obj/hydroponics/harvest.dmi' icon_state = "honeycomb" possible_transfer_amounts = list() disease_amount = 0 @@ -22,10 +22,10 @@ overlays.Cut() var/image/honey if(honey_color) - honey = image(icon = 'icons/obj/apiary_bees.dmi', icon_state = "greyscale_honey") + honey = image(icon = 'icons/obj/hydroponics/harvest.dmi', icon_state = "greyscale_honey") honey.color = honey_color else - honey = image(icon = 'icons/obj/apiary_bees.dmi', icon_state = "honey") + honey = image(icon = 'icons/obj/hydroponics/harvest.dmi', icon_state = "honey") overlays += honey @@ -37,4 +37,4 @@ reagents.add_reagent(R.id,5) else honey_color = "" - update_icon() + update_icon() \ No newline at end of file diff --git a/code/modules/hydroponics/biogenerator.dm b/code/modules/hydroponics/biogenerator.dm new file mode 100644 index 00000000000..6635329c4cb --- /dev/null +++ b/code/modules/hydroponics/biogenerator.dm @@ -0,0 +1,325 @@ +/obj/machinery/biogenerator + name = "Biogenerator" + desc = "Converts plants into biomass, which can be used to construct useful items." + icon = 'icons/obj/biogenerator.dmi' + icon_state = "biogen-empty" + density = 1 + anchored = 1 + use_power = 1 + idle_power_usage = 40 + var/processing = 0 + var/obj/item/weapon/reagent_containers/glass/beaker = null + var/points = 0 + var/menustat = "menu" + var/efficiency = 0 + var/productivity = 0 + var/max_items = 40 + var/datum/research/files + var/list/show_categories = list("Food", "Botany Chemicals", "Leather and Cloth") + var/list/timesFiveCategories = list("Food", "Botany Chemicals") + +/obj/machinery/biogenerator/New() + ..() + files = new /datum/research/biogenerator(src) + create_reagents(1000) + component_parts = list() + component_parts += new /obj/item/weapon/circuitboard/biogenerator(null) + component_parts += new /obj/item/weapon/stock_parts/matter_bin(null) + component_parts += new /obj/item/weapon/stock_parts/manipulator(null) + component_parts += new /obj/item/weapon/stock_parts/console_screen(null) + component_parts += new /obj/item/stack/cable_coil(null, 1) + RefreshParts() + +/obj/machinery/biogenerator/Destroy() + if(beaker) + qdel(beaker) + beaker = null + return ..() + +/obj/machinery/biogenerator/ex_act(severity) + if(beaker) + beaker.ex_act(severity) + ..() + +/obj/machinery/biogenerator/RefreshParts() + var/E = 0 + var/P = 0 + var/max_storage = 40 + for(var/obj/item/weapon/stock_parts/matter_bin/B in component_parts) + P += B.rating + max_storage = 40 * B.rating + for(var/obj/item/weapon/stock_parts/manipulator/M in component_parts) + E += M.rating + efficiency = E + productivity = P + max_items = max_storage + +/obj/machinery/biogenerator/on_reagent_change() //When the reagents change, change the icon as well. + update_icon() + +/obj/machinery/biogenerator/update_icon() + if(panel_open) + icon_state = "biogen-empty-o" + else if(!beaker) + icon_state = "biogen-empty" + else if(!processing) + icon_state = "biogen-stand" + else + icon_state = "biogen-work" + return + +/obj/machinery/biogenerator/attackby(obj/item/O, mob/user, params) + if(user.a_intent == I_HARM) + return ..() + + if(processing) + to_chat(user, "The biogenerator is currently processing.") + return + + if(default_deconstruction_screwdriver(user, "biogen-empty-o", "biogen-empty", O)) + if(beaker) + var/obj/item/weapon/reagent_containers/glass/B = beaker + B.forceMove(loc) + beaker = null + update_icon() + return + + if(exchange_parts(user, O)) + return + + if(default_deconstruction_crowbar(O)) + return + + if(istype(O, /obj/item/weapon/reagent_containers/glass)) + . = 1 //no afterattack + if(!panel_open) + if(beaker) + to_chat(user, "A container is already loaded into the machine.") + else + if(!user.drop_item()) + return + O.forceMove(src) + beaker = O + to_chat(user, "You add the container to the machine.") + update_icon() + updateUsrDialog() + else + to_chat(user, "Close the maintenance panel first.") + return + + else if(istype(O, /obj/item/weapon/storage/bag/plants)) + var/obj/item/weapon/storage/bag/plants/PB = O + var/i = 0 + for(var/obj/item/weapon/reagent_containers/food/snacks/grown/G in contents) + i++ + if(i >= max_items) + to_chat(user, "The biogenerator is already full! Activate it.") + else + for(var/obj/item/weapon/reagent_containers/food/snacks/grown/G in PB.contents) + if(i >= max_items) + break + PB.remove_from_storage(G, src) + i++ + if(i Biogenerator is processing! Please wait... " + else + switch(menustat) + if("nopoints") + dat += " You do not have enough biomass to create products. "
+ menustat = "menu"
+ if("complete")
+ dat += "Please, put growns into reactor and activate it. Operation complete. "
+ menustat = "menu"
+ if("void")
+ dat += "Error: No growns inside. "
+ menustat = "menu"
+ if("nobeakerspace")
+ dat += "Please, put growns into reactor. Not enough space left in container. Unable to create product. "
+ menustat = "menu"
+ if(beaker)
+ var/categories = show_categories.Copy()
+ for(var/V in categories)
+ categories[V] = list()
+ for(var/V in files.known_designs)
+ var/datum/design/D = files.known_designs[V]
+ for(var/C in categories)
+ if(C in D.category)
+ categories[C] += D
+
+ dat += "Biomass: [points] units. " + dat += "ActivateDetach Container" + for(var/cat in categories) + dat += " [cat]:" + dat += ""
+ for(var/V in categories[cat])
+ var/datum/design/D = V
+ dat += "[D.name]: Make"
+ if(cat in timesFiveCategories)
+ dat += "x5"
+ if(ispath(D.build_path, /obj/item/stack))
+ dat += "x10"
+ dat += "([D.materials[MAT_BIOMASS]/efficiency]) "
+ else
+ dat += "" + dat += " No container inside, please insert container. "
+
+ var/datum/browser/popup = new(user, "biogen", name, 350, 520)
+ popup.set_content(dat)
+ popup.open()
+ return
+
+/obj/machinery/biogenerator/attack_hand(mob/user)
+ interact(user)
+
+/obj/machinery/biogenerator/proc/activate()
+ if(usr.stat != 0)
+ return
+ if(stat != 0) //NOPOWER etc
+ return
+ if(processing)
+ to_chat(usr, "The biogenerator is in the process of working.")
+ return
+ var/S = 0
+ for(var/obj/item/weapon/reagent_containers/food/snacks/grown/I in contents)
+ S += 5
+ if(I.reagents.get_reagent_amount("nutriment") < 0.1)
+ points += 1*productivity
+ else
+ points += I.reagents.get_reagent_amount("nutriment")*10*productivity
+ qdel(I)
+ if(S)
+ processing = 1
+ update_icon()
+ updateUsrDialog()
+ playsound(loc, 'sound/machines/blender.ogg', 50, 1)
+ use_power(S*30)
+ sleep(S+15/productivity)
+ processing = 0
+ update_icon()
+ else
+ menustat = "void"
+ return
+
+/obj/machinery/biogenerator/proc/check_cost(list/materials, multiplier = 1, remove_points = 1)
+ if(materials.len != 1 || materials[1] != MAT_BIOMASS)
+ return 0
+ if (materials[MAT_BIOMASS]*multiplier/efficiency > points)
+ menustat = "nopoints"
+ return 0
+ else
+ if(remove_points)
+ points -= materials[MAT_BIOMASS]*multiplier/efficiency
+ update_icon()
+ updateUsrDialog()
+ return 1
+
+/obj/machinery/biogenerator/proc/check_container_volume(list/reagents, multiplier = 1)
+ var/sum_reagents = 0
+ for(var/R in reagents)
+ sum_reagents += reagents[R]
+ sum_reagents *= multiplier
+
+ if(beaker.reagents.total_volume + sum_reagents > beaker.reagents.maximum_volume)
+ menustat = "nobeakerspace"
+ return 0
+
+ return 1
+
+/obj/machinery/biogenerator/proc/create_product(datum/design/D, amount)
+ if(!beaker || !loc)
+ return 0
+
+ if(ispath(D.build_path, /obj/item/stack))
+ if(!check_container_volume(D.make_reagents, amount))
+ return 0
+ if(!check_cost(D.materials, amount))
+ return 0
+
+ var/obj/item/stack/product = new D.build_path(loc)
+ product.amount = amount
+ for(var/R in D.make_reagents)
+ beaker.reagents.add_reagent(R, D.make_reagents[R]*amount)
+ else
+ var/i = amount
+ while(i > 0)
+ if(!check_container_volume(D.make_reagents))
+ return .
+ if(!check_cost(D.materials))
+ return .
+ if(D.build_path)
+ new D.build_path(loc)
+ for(var/R in D.make_reagents)
+ beaker.reagents.add_reagent(R, D.make_reagents[R])
+ . = 1
+ --i
+
+ menustat = "complete"
+ update_icon()
+ return .
+
+/obj/machinery/biogenerator/proc/detach()
+ if(beaker)
+ beaker.forceMove(loc)
+ beaker = null
+ update_icon()
+
+/obj/machinery/biogenerator/Topic(href, href_list)
+ if(..() || panel_open)
+ return
+
+ usr.set_machine(src)
+
+ if(href_list["activate"])
+ activate()
+ updateUsrDialog()
+
+ else if(href_list["detach"])
+ detach()
+ updateUsrDialog()
+
+ else if(href_list["create"])
+ var/amount = (text2num(href_list["amount"]))
+ var/datum/design/D = locate(href_list["create"])
+ create_product(D, amount)
+ updateUsrDialog()
+
+ else if(href_list["menu"])
+ menustat = "menu"
+ updateUsrDialog()
diff --git a/code/modules/hydroponics/gene_modder.dm b/code/modules/hydroponics/gene_modder.dm
new file mode 100644
index 00000000000..dcfd2601813
--- /dev/null
+++ b/code/modules/hydroponics/gene_modder.dm
@@ -0,0 +1,410 @@
+/obj/machinery/plantgenes
+ name = "plant DNA manipulator"
+ desc = "An advanced device designed to manipulate plant genetic makeup."
+ icon = 'icons/obj/hydroponics/equipment.dmi'
+ icon_state = "dnamod"
+ density = 1
+ anchored = 1
+
+ var/obj/item/seeds/seed
+ var/obj/item/weapon/disk/plantgene/disk
+
+ var/list/core_genes = list()
+ var/list/reagent_genes = list()
+ var/list/trait_genes = list()
+
+ var/datum/plant_gene/target
+ var/operation = ""
+ var/rating = 0
+ var/max_extract_pot = 50
+ // The cap on potency gene extraction.
+ // This number is for T1, each upgraded part adds 5% for a tech level above T1.
+ // At T4, it reaches 95%.
+
+/obj/machinery/plantgenes/New()
+ ..()
+ component_parts = list()
+ component_parts += new /obj/item/weapon/circuitboard/plantgenes(src)
+ component_parts += new /obj/item/weapon/stock_parts/console_screen(src)
+ component_parts += new /obj/item/weapon/stock_parts/scanning_module(src)
+ component_parts += new /obj/item/weapon/stock_parts/micro_laser(src)
+ component_parts += new /obj/item/weapon/stock_parts/manipulator(src)
+ RefreshParts()
+
+/obj/machinery/plantgenes/RefreshParts()
+ rating = 0
+ for(var/I in component_parts)
+ if(istype(I, /obj/item/weapon/stock_parts))
+ var/obj/item/weapon/stock_parts/S = I
+ rating += S.rating-1
+ max_extract_pot = initial(max_extract_pot) + rating*5
+
+/obj/machinery/plantgenes/update_icon()
+ ..()
+ overlays.Cut()
+ if((stat & (BROKEN|NOPOWER)))
+ icon_state = "dnamod-off"
+ else
+ icon_state = "dnamod"
+ if(seed)
+ overlays += "dnamod-dna"
+ if(panel_open)
+ overlays += "dnamod-open"
+
+/obj/machinery/plantgenes/attackby(obj/item/I, mob/user, params)
+ if(default_deconstruction_screwdriver(user, "dnamod", "dnamod", I))
+ update_icon()
+ return
+ if(exchange_parts(user, I))
+ return
+ if(default_deconstruction_crowbar(I))
+ return
+ if(isrobot(user))
+ return
+
+ if(istype(I, /obj/item/seeds))
+ if(seed)
+ to_chat(user, "A sample is already loaded into the machine!")
+ else
+ if(!user.drop_item())
+ return
+ insert_seed(I)
+ to_chat(user, "You add [I] to the machine.")
+ interact(user)
+ return
+ else if(istype(I, /obj/item/weapon/disk/plantgene))
+ if(disk)
+ to_chat(user, "A data disk is already loaded into the machine!")
+ else
+ if(!user.drop_item())
+ return
+ disk = I
+ disk.forceMove(src)
+ to_chat(user, "You add [I] to the machine.")
+ interact(user)
+ else
+ ..()
+
+
+/obj/machinery/plantgenes/attack_hand(mob/user)
+ if(..())
+ return
+ interact(user)
+
+/obj/machinery/plantgenes/interact(mob/user)
+ user.set_machine(src)
+ if(!user)
+ return
+
+ var/datum/browser/popup = new(user, "plantdna", "Plant DNA Manipulator", 450, 600)
+ if(!(in_range(src, user) || issilicon(user)))
+ popup.close()
+ return
+
+ var/dat = ""
+
+ if(operation)
+ if(!seed || (!target && operation != "insert"))
+ operation = ""
+ target = null
+ interact(user)
+ return
+ if((operation == "replace" || operation == "insert") && (!disk || !disk.gene))
+ operation = ""
+ target = null
+ interact(user)
+ return
+
+ dat += "Confirm OperationAre you sure you want to [operation] "
+ switch(operation)
+ if("remove")
+ dat += "[target.get_name()] gene from \the [seed]? "
+ popup.set_content(dat)
+ popup.open()
+ return
+
+ dat+= "" + if("extract") + dat += "[target.get_name()] gene from \the [seed]? " + dat += "The sample will be destroyed in process!" + if(istype(target, /datum/plant_gene/core/potency)) + var/datum/plant_gene/core/gene = target + if(gene.value > max_extract_pot) + dat += " This device's extraction capabilities are currently limited to [max_extract_pot] potency. " + dat += "Target gene will be degraded to [max_extract_pot] potency on extraction." + if("replace") + dat += "[target.get_name()] gene with [disk.gene.get_name()]? " + if("insert") + dat += "[disk.gene.get_name()] gene into \the [seed]? " + dat += " "
+
+ dat += " "
+
+ if(seed)
+ var/can_insert = disk && disk.gene && disk.gene.can_add(seed)
+ var/can_extract = disk && !disk.read_only
+
+ dat += "Plant Sample: Core Genes
Content Genes"
+ if(reagent_genes.len)
+ dat += " "
+ if(can_insert && istype(disk.gene, /datum/plant_gene/reagent))
+ dat += "Insert: [disk.gene.get_name()]"
+
+ dat += "
" + dat += " Trait Genes"
+ if(trait_genes.len)
+ dat += " "
+ else
+ dat += "
" + if(can_insert && istype(disk.gene, /datum/plant_gene/trait)) + dat += "Insert: [disk.gene.get_name()]" + dat += " No sample found. Please, insert a plant sample to use this device." + popup.set_content(dat) + popup.open() + + +/obj/machinery/plantgenes/Topic(var/href, var/list/href_list) + if(..()) + return + usr.set_machine(src) + + if(href_list["eject_seed"] && !operation) + if(seed) + seed.forceMove(loc) + seed.verb_pickup() + seed = null + update_genes() + update_icon() + else + var/obj/item/I = usr.get_active_hand() + if(istype(I, /obj/item/seeds)) + if(!usr.drop_item()) + return + insert_seed(I) + to_chat(usr, "You add [I] to the machine.") + update_icon() + else if(href_list["eject_disk"] && !operation) + if(disk) + disk.forceMove(loc) + disk.verb_pickup() + disk = null + update_genes() + else + var/obj/item/I = usr.get_active_hand() + if(istype(I, /obj/item/weapon/disk/plantgene)) + if(!usr.drop_item()) + return + disk = I + disk.forceMove(src) + to_chat(usr, "You add [I] to the machine.") + else if(href_list["op"] == "insert" && disk && disk.gene && seed) + if(!operation) // Wait for confirmation + operation = "insert" + else + if(!istype(disk.gene, /datum/plant_gene/core) && disk.gene.can_add(seed)) + seed.genes += disk.gene.Copy() + if(istype(disk.gene, /datum/plant_gene/reagent)) + seed.reagents_from_genes() + update_genes() + repaint_seed() + operation = "" + target = null + + else if(href_list["gene"] && seed) + var/datum/plant_gene/G = seed.get_gene(href_list["gene"]) + if(!G || !href_list["op"] || !(href_list["op"] in list("remove", "extract", "replace"))) + interact(usr) + return + + if(!operation || target != G) // Wait for confirmation + target = G + operation = href_list["op"] + + else if(operation == href_list["op"] && target == G) + switch(href_list["op"]) + if("remove") + if(!istype(G, /datum/plant_gene/core)) + seed.genes -= G + if(istype(G, /datum/plant_gene/reagent)) + seed.reagents_from_genes() + repaint_seed() + if("extract") + if(disk && !disk.read_only) + disk.gene = G + if(istype(G, /datum/plant_gene/core/potency)) + var/datum/plant_gene/core/gene = G + gene.value = min(gene.value, max_extract_pot) + disk.update_name() + qdel(seed) + seed = null + update_icon() + if("replace") + if(disk && disk.gene && istype(disk.gene, G.type) && istype(G, /datum/plant_gene/core)) + seed.genes -= G + var/datum/plant_gene/core/C = disk.gene.Copy() + seed.genes += C + C.apply_stat(seed) + repaint_seed() + if("insert") + if(disk && disk.gene && !istype(disk.gene, /datum/plant_gene/core) && disk.gene.can_add(seed)) + seed.genes += disk.gene.Copy() + if(istype(disk.gene, /datum/plant_gene/reagent)) + seed.reagents_from_genes() + repaint_seed() + + update_genes() + operation = "" + target = null + else if(href_list["abort"]) + operation = "" + target = null + + interact(usr) + +/obj/machinery/plantgenes/proc/insert_seed(obj/item/seeds/S) + if(!istype(S) || seed) + return + S.forceMove(src) + seed = S + update_genes() + update_icon() + +/obj/machinery/plantgenes/proc/update_genes() + core_genes = list() + reagent_genes = list() + trait_genes = list() + + if(seed) + var/gene_paths = list( + /datum/plant_gene/core/potency, + /datum/plant_gene/core/yield, + /datum/plant_gene/core/production, + /datum/plant_gene/core/endurance, + /datum/plant_gene/core/lifespan, + /datum/plant_gene/core/weed_rate, + /datum/plant_gene/core/weed_chance + ) + for(var/a in gene_paths) + core_genes += seed.get_gene(a) + + for(var/datum/plant_gene/reagent/G in seed.genes) + reagent_genes += G + for(var/datum/plant_gene/trait/G in seed.genes) + trait_genes += G + +/obj/machinery/plantgenes/proc/repaint_seed() + if(!seed) + return + if(copytext(seed.name, 1, 13) == "experimental") + return // Already modded name and icon + seed.name = "experimental " + seed.name + seed.icon_state = "seed-x" + +/* + * Plant DNA disk + */ + +/obj/item/weapon/disk/plantgene + name = "plant data disk" + desc = "A disk for storing plant genetic data." + icon_state = "datadisk_hydro" + materials = list(MAT_METAL=30, MAT_GLASS=10) + var/datum/plant_gene/gene + var/read_only = 0 //Well, it's still a floppy disk + +/obj/item/weapon/disk/plantgene/New() + ..() + overlays += "datadisk_gene" + pixel_x = rand(-5, 5) + pixel_y = rand(-5, 5) + +/obj/item/weapon/disk/plantgene/attackby(obj/item/weapon/W, mob/user, params) + ..() + if(istype(W, /obj/item/weapon/pen)) + var/t = stripped_input(user, "What would you like the label to be?", name, null) + if(user.get_active_hand() != W) + return + if(!in_range(src, user) && loc != user) + return + if(t) + name = "plant data disk - '[t]'" + else + name = "plant data disk" + +/obj/item/weapon/disk/plantgene/proc/update_name() + if(gene) + name = "plant data disk - '[gene.get_name()]'" + else + name = "plant data disk" + +/obj/item/weapon/disk/plantgene/attack_self(mob/user) + read_only = !read_only + to_chat(user, "You flip the write-protect tab to [read_only ? "protected" : "unprotected"].") + +/obj/item/weapon/disk/plantgene/examine(mob/user) + ..() + to_chat(user, "The write-protect tab is set to [read_only ? "protected" : "unprotected"].") + + +/* + * Plant DNA Disks Box + */ +/obj/item/weapon/storage/box/disks_plantgene + name = "plant data disks box" + icon_state = "disk_kit" + +/obj/item/weapon/storage/box/disks_plantgene/New() + ..() + for(var/i in 1 to 7) + new /obj/item/weapon/disk/plantgene(src) \ No newline at end of file diff --git a/code/modules/hydroponics/grown.dm b/code/modules/hydroponics/grown.dm index 81d489d9da1..2322bbad5ca 100644 --- a/code/modules/hydroponics/grown.dm +++ b/code/modules/hydroponics/grown.dm @@ -1,535 +1,148 @@ -//Grown foods. +// *********************************************************** +// Foods that are produced from hydroponics ~~~~~~~~~~ +// Data from the seeds carry over to these grown foods +// *********************************************************** + +// Base type. Subtypes are found in /grown dir. /obj/item/weapon/reagent_containers/food/snacks/grown - - name = "fruit" - icon = 'icons/obj/hydroponics_products.dmi' - icon_state = "blank" - desc = "Nutritious! Probably." - - var/plantname - var/datum/seed/seed - var/potency = -1 - var/awakening = 0 + icon = 'icons/obj/hydroponics/harvest.dmi' + var/obj/item/seeds/seed = null // type path, gets converted to item on New(). It's safe to assume it's always a seed item. + var/plantname = "" + var/bitesize_mod = 0 + var/splat_type = /obj/effect/decal/cleanable/plant_smudge + // If set, bitesize = 1 + round(reagents.total_volume / bitesize_mod) + dried_type = -1 + // Saves us from having to define each stupid grown's dried_type as itself. + // If you don't want a plant to be driable (watermelons) set this to null in the time definition. burn_state = FLAMMABLE + origin_tech = "biotech=1" -/obj/item/weapon/reagent_containers/food/snacks/grown/New(newloc,planttype) - +/obj/item/weapon/reagent_containers/food/snacks/grown/New(newloc, var/obj/item/seeds/new_seed = null) ..() - if(!dried_type) + if(new_seed) + seed = new_seed.Copy() + else if(ispath(seed)) + // This is for adminspawn or map-placed growns. They get the default stats of their seed type. + seed = new seed() + seed.adjust_potency(50-seed.potency) + + pixel_x = rand(-5, 5) + pixel_y = rand(-5, 5) + + if(dried_type == -1) dried_type = type - src.pixel_x = rand(-5.0, 5) - src.pixel_y = rand(-5.0, 5) - - // Fill the object up with the appropriate reagents. - if(planttype) - plantname = planttype - - if(!plantname) - return - - if(!plant_controller) - sleep(250) // ugly hack, should mean roundstart plants are fine. - if(!plant_controller) - to_chat(world, "Plant controller does not exist and [src] requires it. Aborting.") - qdel(src) - return - - seed = plant_controller.seeds[plantname] - - if(!seed) - return - - name = "[seed.seed_name]" - - if(seed.modular_icon == 1) - update_icon() - else - icon = 'icons/obj/harvest.dmi' - icon_state = seed.preset_icon - - if(!seed.chems) - return - - potency = seed.get_trait(TRAIT_POTENCY) - - for(var/rid in seed.chems) - var/list/reagent_data = seed.chems[rid] - if(reagent_data && reagent_data.len) - var/rtotal = reagent_data[1] - if(reagent_data.len > 1 && potency > 0) - rtotal += round(potency/reagent_data[2]) - reagents.add_reagent(rid,max(1,rtotal)) - update_desc() - update_trash() - if(reagents.total_volume > 0) - bitesize = 1+round(reagents.total_volume / 2, 1) - -/obj/item/weapon/reagent_containers/food/snacks/grown/proc/update_trash() - if(!seed) - return - trash = seed.trash_type - if(seed.kitchen_tag) - if(seed.kitchen_tag == "watermelon") // 15% chance to leave behind a pack of watermelon seeds - if(prob(15)) - var/obj/item/seeds/seeds = new() - seeds.seed = seed - seeds.update_seed() - trash = seeds - else - trash = null - -/obj/item/weapon/reagent_containers/food/snacks/grown/proc/update_desc() - - if(!seed) - return - if(!plant_controller) - sleep(250) // ugly hack, should mean roundstart plants are fine. - if(!plant_controller) - to_chat(world, "Plant controller does not exist and [src] requires it. Aborting.") - qdel(src) - return - - if(plant_controller.product_descs["[seed.uid]"]) - desc = plant_controller.product_descs["[seed.uid]"] - else - var/list/descriptors = list() - if(reagents.has_reagent("sugar") || reagents.has_reagent("cherryjelly") || reagents.has_reagent("honey") || reagents.has_reagent("berryjuice")) - descriptors |= "sweet" - if(reagents.has_reagent("charcoal")) - descriptors |= "astringent" - if(reagents.has_reagent("frostoil")) - descriptors |= "numbing" - if(reagents.has_reagent("nutriment")) - descriptors |= "nutritious" - if(reagents.has_reagent("condensedcapsaicin") || reagents.has_reagent("capsaicin")) - descriptors |= "spicy" - if(reagents.has_reagent("cocoa")) - descriptors |= "bitter" - if(reagents.has_reagent("orangejuice") || reagents.has_reagent("lemonjuice") || reagents.has_reagent("limejuice")) - descriptors |= "sweet-sour" - if(reagents.has_reagent("radium") || reagents.has_reagent("uranium")) - descriptors |= "radioactive" - if(reagents.has_reagent("amanitin") || reagents.has_reagent("toxin") || reagents.has_reagent("carpotoxin")) - descriptors |= "poisonous" - if(reagents.has_reagent("lsd") || reagents.has_reagent("space_drugs") || reagents.has_reagent("psilocybin")) - descriptors |= "hallucinogenic" - if(reagents.has_reagent("styptic_powder")) - descriptors |= "medicinal" - if(reagents.has_reagent("gold") || reagents.has_reagent("silver")) - descriptors |= "shiny" - if(reagents.has_reagent("lube")) - descriptors |= "slippery" - if(reagents.has_reagent("facid") || reagents.has_reagent("sacid")) - descriptors |= "acidic" - if(reagents.has_reagent("fuel")) - descriptors |= "flammable" - if(reagents.has_reagent("moonshine")) - descriptors |= "intoxicating" - if(seed.get_trait(TRAIT_JUICY)) - descriptors |= "juicy" - if(seed.get_trait(TRAIT_STINGS)) - descriptors |= "stinging" - if(seed.get_trait(TRAIT_TELEPORTING)) - descriptors |= "glowing" - if(seed.get_trait(TRAIT_EXPLOSIVE)) - descriptors |= "bulbous" - - var/descriptor_num = rand(2,4) - var/descriptor_count = descriptor_num - desc = "A" - while(descriptors.len && descriptor_num > 0) - var/chosen = pick(descriptors) - descriptors -= chosen - desc += "[(descriptor_count>1 && descriptor_count!=descriptor_num) ? "," : "" ] [chosen]" - descriptor_num-- - if(seed.seed_noun == "spores") - desc += " mushroom" - else - desc += " fruit" - plant_controller.product_descs["[seed.uid]"] = desc - desc += ". Delicious! Probably." - -/obj/item/weapon/reagent_containers/food/snacks/grown/update_icon() - if(!seed || !plant_controller || !plant_controller.plant_icon_cache) - return - if(seed.modular_icon != 1) - return - overlays.Cut() - var/image/plant_icon - var/icon_key = "fruit-[seed.get_trait(TRAIT_PRODUCT_ICON)]-[seed.get_trait(TRAIT_PRODUCT_COLOUR)]-[seed.get_trait(TRAIT_PLANT_COLOUR)]" - if(plant_controller.plant_icon_cache[icon_key]) - plant_icon = plant_controller.plant_icon_cache[icon_key] - else - plant_icon = image('icons/obj/hydroponics_products.dmi',"blank") - var/image/fruit_base = image('icons/obj/hydroponics_products.dmi',"[seed.get_trait(TRAIT_PRODUCT_ICON)]-product") - fruit_base.color = "[seed.get_trait(TRAIT_PRODUCT_COLOUR)]" - plant_icon.overlays |= fruit_base - if("[seed.get_trait(TRAIT_PRODUCT_ICON)]-leaf" in icon_states('icons/obj/hydroponics_products.dmi')) - var/image/fruit_leaves = image('icons/obj/hydroponics_products.dmi',"[seed.get_trait(TRAIT_PRODUCT_ICON)]-leaf") - fruit_leaves.color = "[seed.get_trait(TRAIT_PLANT_COLOUR)]" - plant_icon.overlays |= fruit_leaves - plant_controller.plant_icon_cache[icon_key] = plant_icon - overlays |= plant_icon - -/obj/item/weapon/reagent_containers/food/snacks/grown/Crossed(var/mob/living/M) - if(seed && seed.get_trait(TRAIT_JUICY) == 2) - if(istype(M)) - - if(M.buckled) - return - - if(istype(M,/mob/living/carbon/human)) - var/mob/living/carbon/human/H = M - if(H.shoes && H.shoes.flags & NOSLIP) - return - - M.stop_pulling() - to_chat(M, "You slipped on the [name]!") - playsound(src.loc, 'sound/misc/slip.ogg', 50, 1, -3) - M.Stun(8) - M.Weaken(5) - seed.thrown_at(src,M) - sleep(-1) - if(src) qdel(src) - return - -/obj/item/weapon/reagent_containers/food/snacks/grown/throw_impact(atom/hit_atom) - ..() - if(seed) seed.thrown_at(src,hit_atom) - -/obj/item/weapon/reagent_containers/food/snacks/grown/attackby(var/obj/item/weapon/W, var/mob/user) if(seed) - if(seed.get_trait(TRAIT_PRODUCES_POWER) && istype(W, /obj/item/stack/cable_coil)) - var/obj/item/stack/cable_coil/C = W - if(C.use(5)) - //TODO: generalize this. - to_chat(user, "You add some cable to the [src.name] and slide it inside the battery casing.") - var/obj/item/weapon/stock_parts/cell/potato/pocell = new /obj/item/weapon/stock_parts/cell/potato(get_turf(user)) - if(src.loc == user && !(user.l_hand && user.r_hand) && istype(user,/mob/living/carbon/human)) - user.put_in_hands(pocell) - pocell.maxcharge = src.potency * 10 - pocell.charge = pocell.maxcharge - qdel(src) - return - else if(W.sharp) - var/reagents_per_slice - var/obj/slice - if(seed.kitchen_tag == "pumpkin") // Ugggh these checks are awful. - user.show_message("You carve a face into [src]!", 1) - new /obj/item/clothing/head/hardhat/pumpkinhead (user.loc) - qdel(src) - return - else if(seed.kitchen_tag == "potato") - to_chat(user, "You slice \the [src] into sticks.") - reagents_per_slice = reagents.total_volume - slice = new /obj/item/weapon/reagent_containers/food/snacks/rawsticks(get_turf(src)) - reagents.trans_to(slice, reagents_per_slice) - qdel(src) - return - else if(seed.kitchen_tag == "carrot") - to_chat(user, "You slice \the [src] into sticks.") - reagents_per_slice = reagents.total_volume - slice = new /obj/item/weapon/reagent_containers/food/snacks/carrotfries(get_turf(src)) - reagents.trans_to(slice, reagents_per_slice) - qdel(src) - return - else if(seed.kitchen_tag == "watermelon") - to_chat(user, "You slice \the [src] into large slices.") - reagents_per_slice = reagents.total_volume/5 - for(var/i=0,i<5,i++) - slice = new /obj/item/weapon/reagent_containers/food/snacks/watermelonslice(get_turf(src)) - reagents.trans_to(slice, reagents_per_slice) - qdel(src) - return - else if(seed.kitchen_tag == "soybeans") - to_chat(user, "You roughly chop up \the [src].") - reagents_per_slice = reagents.total_volume - slice = new /obj/item/weapon/reagent_containers/food/snacks/soydope(get_turf(src)) - reagents.trans_to(slice, reagents_per_slice) - qdel(src) - return - else if(seed.chems) - if(istype(W,/obj/item/weapon/hatchet) && !isnull(seed.chems["woodpulp"])) - user.show_message("You make planks out of \the [src]!", 1) - for(var/i=0,i<2,i++) - var/obj/item/stack/sheet/wood/NG = new (user.loc) - NG.color = seed.get_trait(TRAIT_PRODUCT_COLOUR) - for(var/obj/item/stack/sheet/wood/G in user.loc) - if(G==NG) - continue - if(G.amount>=G.max_amount) - continue - G.attackby(NG, user) - to_chat(user, "You add the newly-formed wood to the stack. It now contains [NG.amount] planks.") - qdel(src) - return - else if(istype(W, /obj/item/weapon/rollingpaper)) - if(seed.kitchen_tag == "ambrosia" || seed.kitchen_tag == "ambrosiadeus" || seed.kitchen_tag == "tobacco" || seed.kitchen_tag == "stobacco") - user.unEquip(W) - if(seed.kitchen_tag == "ambrosia") - var/obj/item/clothing/mask/cigarette/joint/J = new /obj/item/clothing/mask/cigarette/joint(user.loc) - J.chem_volume = src.reagents.total_volume - src.reagents.trans_to(J, J.chem_volume) - qdel(W) - user.put_in_active_hand(J) - else if(seed.kitchen_tag == "ambrosiadeus") - var/obj/item/clothing/mask/cigarette/joint/deus/J = new /obj/item/clothing/mask/cigarette/joint/deus(user.loc) - J.chem_volume = src.reagents.total_volume - src.reagents.trans_to(J, J.chem_volume) - qdel(W) - user.put_in_active_hand(J) - else if(seed.kitchen_tag == "tobacco" || seed.kitchen_tag == "stobacco") - var/obj/item/clothing/mask/cigarette/handroll/J = new /obj/item/clothing/mask/cigarette/handroll(user.loc) - J.chem_volume = src.reagents.total_volume - src.reagents.trans_to(J, J.chem_volume) - qdel(W) - user.put_in_active_hand(J) - to_chat(user, "\blue You roll the [src] into a rolling paper.") - qdel(src) - else - to_chat(user, "\red You can't roll a smokable from the [src].") + for(var/datum/plant_gene/trait/T in seed.genes) + T.on_new(src, newloc) + seed.prepare_result(src) + transform *= TransformUsingVariable(seed.potency, 100, 0.5) //Makes the resulting produce's sprite larger or smaller based on potency! + add_juice() - ..() -/obj/item/weapon/reagent_containers/food/snacks/grown/attack(var/mob/living/carbon/M, var/mob/user, var/def_zone) - if(awakening) - to_chat(user, "The [src] is twitching and shaking, preventing you from eating it.") - return - if(user == M) - return ..() - if(user.a_intent == I_HARM) - - // This is being copypasted here because reagent_containers (WHY DOES FOOD DESCEND FROM THAT) overrides it completely. - // TODO: refactor all food paths to be less horrible and difficult to work with in this respect. ~Z - if(!istype(M)) return 0 - - if(!def_zone) - def_zone = check_zone(user.zone_sel.selecting) - - user.lastattacked = M - M.lastattacker = user - user.attack_log += "\[[time_stamp()]\] Attacked [key_name(M)] with [name] (INTENT: [uppertext(user.a_intent)]) (DAMTYE: [uppertext(damtype)])" - M.attack_log += "\[[time_stamp()]\] Attacked by [key_name(user)] with [name] (INTENT: [uppertext(user.a_intent)]) (DAMTYE: [uppertext(damtype)])" - msg_admin_attack("[key_name_admin(user)] attacked [key_name_admin(M)] with [name] (INTENT: [uppertext(user.a_intent)]) (DAMTYE: [uppertext(damtype)])" ) - - if(istype(M, /mob/living/carbon/human)) - var/mob/living/carbon/human/H = M - var/hit = H.attacked_by(src, user, def_zone) - if(hit && hitsound) - playsound(loc, hitsound, 50, 1, -1) - //return hit - else - if(attack_verb.len) - user.visible_message("[M] has been [pick(attack_verb)] with [src] by [user]!") - else - user.visible_message("[M] has been attacked with [src] by [user]!") - - if(hitsound) - playsound(loc, hitsound, 50, 1, -1) - switch(damtype) - if("brute") - M.take_organ_damage(force) - if(prob(33)) - var/turf/simulated/location = get_turf(M) - if(istype(location)) location.add_blood_floor(M) - if("fire") - M.take_organ_damage(0, force) - M.updatehealth() - - if(seed && seed.get_trait(TRAIT_CARNIVOROUS)) - seed.do_thorns(M, src, def_zone) - - if(ishuman(M) && seed && seed.get_trait(TRAIT_STINGS)) - if(!reagents || reagents.total_volume <= 0) - return - seed.do_sting(M, src, def_zone) - reagents.remove_any(rand(1,3)) //use up some of the reagents at random - sleep(-1) - if(!src) - return - if(reagents && reagents.total_volume <= 0) //used-up fruit will be destroyed - if(user) - to_chat(user, "\The [src] has dried out and crumbles to dust.") - //user.drop_from_inventory(src) - qdel(src) - else if(prob(35)) //fruit that still has reagents has a chance of breaking each time it stings on hit - if(user) - to_chat(user, "\The [src] has fallen to bits.") - //user.drop_from_inventory(src) - qdel(src) - - add_fingerprint(user) +/obj/item/weapon/reagent_containers/food/snacks/grown/proc/add_juice() + if(reagents) + if(bitesize_mod) + bitesize = 1 + round(reagents.total_volume / bitesize_mod) return 1 + return 0 - else - ..() - -/obj/item/weapon/reagent_containers/food/snacks/grown/attack_self(mob/user as mob) - - if(!seed) - return - - if(istype(user.loc,/turf/space)) - return - - if(user.a_intent == I_HARM) - user.visible_message("\The [user] squashes \the [src]!") - seed.thrown_at(src,user) - sleep(-1) - if(src) qdel(src) - return - - if(user.a_intent == I_DISARM && seed.get_trait(TRAIT_SPREAD) > 0) //Using disarm so we can tell if you want to plant or convert non-final plants - to_chat(user, "You plant the [src.name].") - new /obj/machinery/portable_atmospherics/hydroponics/soil/invisible(get_turf(user),src.seed) - new /obj/effect/plant(get_turf(user), src.seed) - qdel(src) - return - - - if(!seed.final_form) //This isn't even my final form! (sorry, it had to be done) - switch(seed.kitchen_tag) - if("comfrey") - var/obj/item/stack/medical/bruise_pack/comfrey/poultice = new /obj/item/stack/medical/bruise_pack/comfrey(user.loc) - poultice.heal_brute = potency - to_chat(user, "You mash the leaves into a poultice.") - qdel(src) - return - if("aloe") - var/obj/item/stack/medical/ointment/aloe/poultice = new /obj/item/stack/medical/ointment/aloe(user.loc) - poultice.heal_burn = potency - to_chat(user, "You mash the petals into a poultice.") - qdel(src) - return - if("grass") - user.show_message("You make a grass tile out of \the [src]!", 1) - for(var/i=0,i<2,i++) - var/obj/item/stack/tile/grass/G = new (user.loc) - G.color = seed.get_trait(TRAIT_PRODUCT_COLOUR) - for(var/obj/item/stack/tile/grass/NG in user.loc) - if(G==NG) - continue - if(NG.amount>=NG.max_amount) - continue - NG.attackby(G, user) - to_chat(user, "You add the newly-formed grass to the stack. It now contains [G.amount] tiles.") - qdel(src) - return - if("sunflower") - var/obj/item/weapon/grown/sunflower/SF = new /obj/item/weapon/grown/sunflower(user.loc) - user.unEquip(src) - user.put_in_hands(SF) - qdel(src) - return - if("novaflower") - var/obj/item/weapon/grown/novaflower/NF = new /obj/item/weapon/grown/novaflower(user.loc) - if(prob(10)) - user.say("PRAISE THE SUN!") - else - to_chat(user, "PRAISE THE SUN!") - user.unEquip(src) - user.put_in_hands(NF) - qdel(src) - return - if("nettle") - var/obj/item/weapon/grown/nettle/nettle = new /obj/item/weapon/grown/nettle(user.loc) - nettle.force = round((5 + potency / 5), 1) - to_chat(user, "You straighten up the plant.") - user.unEquip(src) - user.put_in_hands(nettle) - qdel(src) - return - if("deathnettle") - var/obj/item/weapon/grown/nettle/death/DN = new /obj/item/weapon/grown/nettle/death(user.loc) - DN.force = round((5 + potency / 2.5), 1) - to_chat(user, "You straighten up the plant.") - user.unEquip(src) - user.put_in_hands(DN) - qdel(src) - return - if("killertomato") - if(awakening || istype(user.loc,/turf/space)) - return - to_chat(user, "You begin to awaken the Killer Tomato...") - awakening = 1 - - spawn(30) - if(!qdeleted(src)) - var/mob/living/simple_animal/hostile/killertomato/K = new /mob/living/simple_animal/hostile/killertomato(get_turf(src.loc)) - var/endurance_value = seed.get_trait(TRAIT_ENDURANCE) - K.maxHealth += round(endurance_value / 3) - K.melee_damage_lower += round(potency / 10) - K.melee_damage_upper += round(potency / 10) - var/production_value = seed.get_trait(TRAIT_PRODUCTION) - K.move_to_delay -= round(production_value / 50) - K.health = K.maxHealth - K.visible_message("The Killer Tomato growls as it suddenly awakens.") - if(user) - user.unEquip(src) - qdel(src) - if("cashpod") - to_chat(user, "You crack open the cash pod...") - var/value = round(seed.get_trait(TRAIT_POTENCY)) - user.unEquip(src) - switch(value) - if(0) - to_chat(user, "It's empty! What a waste...") - if(1 to 10) - to_chat(user, "It has a space dollar inside. Woo.") - new /obj/item/weapon/spacecash(get_turf(user)) - if(11 to 20) - to_chat(user, "It has 10 space dollars inside!") - new /obj/item/weapon/spacecash/c10(get_turf(user)) - if(21 to 30) - to_chat(user, "It has 20 space dollars inside! Cool!") - new /obj/item/weapon/spacecash/c20(get_turf(user)) - if(31 to 40) - to_chat(user, "It has 50 space dollars inside! Nice!") - new /obj/item/weapon/spacecash/c50(get_turf(user)) - if(41 to 50) - to_chat(user, "It has 100 space dollars inside! Sweet!") - new /obj/item/weapon/spacecash/c100(get_turf(user)) - if(51 to 60) - to_chat(user, "It has 200 space dollars inside! Awesome!") - new /obj/item/weapon/spacecash/c200(get_turf(user)) - if(61 to 80) - to_chat(user, "It has 500 space dollars inside! CHA-CHING!") - new /obj/item/weapon/spacecash/c500(get_turf(user)) - else - to_chat(user, "It has 1000 space dollars inside! JACKPOT!") - new /obj/item/weapon/spacecash/c1000(get_turf(user)) - qdel(src) - return - -/obj/item/weapon/reagent_containers/food/snacks/grown/pickup(mob/user) +/obj/item/weapon/reagent_containers/food/snacks/grown/examine(user) ..() - if(!seed) + if(seed) + for(var/datum/plant_gene/trait/T in seed.genes) + if(T.examine_line) + to_chat(user, T.examine_line) + +/obj/item/weapon/reagent_containers/food/snacks/grown/attackby(obj/item/O, mob/user, params) + ..() + if (istype(O, /obj/item/device/plant_analyzer)) + var/msg = "*---------*\n This is \a [src].\n" + if(seed) + msg += seed.get_analyzer_text() + var/reag_txt = "" + if(seed) + for(var/reagent_id in seed.reagents_add) + var/datum/reagent/R = chemical_reagents_list[reagent_id] + var/amt = reagents.get_reagent_amount(reagent_id) + reag_txt += "\n- [R.name]: [amt]" + + if(reag_txt) + msg += reag_txt + msg += " *---------*" + to_chat(user, msg) + else + if(seed) + for(var/datum/plant_gene/trait/T in seed.genes) + T.on_attackby(src, O, user) + + +// Various gene procs +/obj/item/weapon/reagent_containers/food/snacks/grown/attack_self(mob/user) + if(seed && seed.get_gene(/datum/plant_gene/trait/squash)) + squash(user) + ..() + +/obj/item/weapon/reagent_containers/food/snacks/grown/throw_impact(atom/hit_atom) + if(!..()) //was it caught by a mob? + if(seed) + for(var/datum/plant_gene/trait/T in seed.genes) + T.on_throw_impact(src, hit_atom) + if(seed.get_gene(/datum/plant_gene/trait/squash)) + squash(hit_atom) + +/obj/item/weapon/reagent_containers/food/snacks/grown/proc/squash(atom/target) + var/turf/T = get_turf(target) + if(ispath(splat_type, /obj/effect/decal/cleanable/plant_smudge)) + if(filling_color) + var/obj/O = new splat_type(T) + O.color = filling_color + O.name = "[name] smudge" + else if(splat_type) + new splat_type(T) + + if(trash) + generate_trash(T) + + visible_message("[src] has been squashed.","You hear a smack.") + if(seed) + for(var/datum/plant_gene/trait/trait in seed.genes) + trait.on_squash(src, target) + + for(var/A in T) + if(reagents) + reagents.reaction(A) + + qdel(src) + +/obj/item/weapon/reagent_containers/food/snacks/grown/On_Consume() + if(iscarbon(usr)) + if(seed) + for(var/datum/plant_gene/trait/T in seed.genes) + T.on_consume(src, usr) + ..() + +/obj/item/weapon/reagent_containers/food/snacks/grown/Crossed(atom/movable/AM) + if(seed) + for(var/datum/plant_gene/trait/T in seed.genes) + T.on_cross(src, AM) + ..() + + +// Glow gene procs +/obj/item/weapon/reagent_containers/food/snacks/grown/generate_trash(atom/location) + if(trash && ispath(trash, /obj/item/weapon/grown)) + . = new trash(location, seed) + trash = null return - if(seed.get_trait(TRAIT_STINGS)) - var/mob/living/carbon/human/H = user - if(istype(H) && H.gloves) - return - if(!reagents || reagents.total_volume <= 0) - return - reagents.remove_any(rand(1,3)) //Todo, make it actually remove the reagents the seed uses. - seed.do_thorns(H,src) - seed.do_sting(H,src,pick("r_hand","l_hand")) + return ..() - -/obj/item/weapon/reagent_containers/food/snacks/grown/On_Consume(mob/M, mob/user) - if(seed && seed.get_trait(TRAIT_BATTERY_RECHARGE)) - if(!reagents.total_volume) - var/batteries_recharged = 0 - for(var/obj/item/weapon/stock_parts/cell/C in user.GetAllContents()) - var/newcharge = (potency*0.01)*C.maxcharge - if(C.charge < newcharge) - C.charge = newcharge - if(isobj(C.loc)) - var/obj/O = C.loc - O.update_icon() //update power meters and such - batteries_recharged = 1 - if(batteries_recharged) - to_chat(user, "Battery has recovered.") - ..() \ No newline at end of file +// For item-containing growns such as eggy or gatfruit +/obj/item/weapon/reagent_containers/food/snacks/grown/shell/attack_self(mob/user) + user.unEquip(src) + if(trash) + var/obj/item/T = generate_trash() + user.put_in_hands(T) + to_chat(user, "You open [src]\'s shell, revealing \a [T].") + qdel(src) diff --git a/code/modules/hydroponics/grown/ambrosia.dm b/code/modules/hydroponics/grown/ambrosia.dm new file mode 100644 index 00000000000..9700b8f3d3b --- /dev/null +++ b/code/modules/hydroponics/grown/ambrosia.dm @@ -0,0 +1,86 @@ +// Ambrosia - base type +/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia + seed = /obj/item/seeds/ambrosia + name = "ambrosia branch" + desc = "This is a plant." + icon_state = "ambrosiavulgaris" + slot_flags = SLOT_HEAD + filling_color = "#008000" + bitesize_mod = 2 + +// Ambrosia Vulgaris +/obj/item/seeds/ambrosia + name = "pack of ambrosia vulgaris seeds" + desc = "These seeds grow into common ambrosia, a plant grown by and from medicine." + icon_state = "seed-ambrosiavulgaris" + species = "ambrosiavulgaris" + plantname = "Ambrosia Vulgaris" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris + lifespan = 60 + endurance = 25 + yield = 6 + potency = 5 + icon_dead = "ambrosia-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/ambrosia/deus) + reagents_add = list("space_drugs" = 0.15, "bicaridine" = 0.1, "kelotane" = 0.1, "vitamin" = 0.04, "nutriment" = 0.05, "toxin" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/vulgaris + seed = /obj/item/seeds/ambrosia + name = "ambrosia vulgaris branch" + desc = "This is a plant containing various healing chemicals." + origin_tech = "biotech=2" + +// Ambrosia Deus +/obj/item/seeds/ambrosia/deus + name = "pack of ambrosia deus seeds" + desc = "These seeds grow into ambrosia deus. Could it be the food of the gods..?" + icon_state = "seed-ambrosiadeus" + species = "ambrosiadeus" + plantname = "Ambrosia Deus" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus + mutatelist = list(/obj/item/seeds/ambrosia/gaia) + reagents_add = list("weak_omnizine" = 0.15, "synaptizine" = 0.15, "space_drugs" = 0.1, "vitamin" = 0.04, "nutriment" = 0.05) + rarity = 40 + +/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus + seed = /obj/item/seeds/ambrosia/deus + name = "ambrosia deus branch" + desc = "Eating this makes you feel immortal!" + icon_state = "ambrosiadeus" + filling_color = "#008B8B" + origin_tech = "biotech=4;materials=3" + +//Ambrosia Gaia +/obj/item/seeds/ambrosia/gaia + name = "pack of ambrosia gaia seeds" + desc = "These seeds grow into ambrosia gaia, filled with infinite potential." + icon_state = "seed-ambrosia_gaia" + species = "ambrosia_gaia" + plantname = "Ambrosia Gaia" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/gaia + mutatelist = list() + reagents_add = list("earthsblood" = 0.05, "nutriment" = 0.06, "vitamin" = 0.05) + rarity = 30 //These are some pretty good plants right here + genes = list() + weed_rate = 4 + weed_chance = 100 + +/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/gaia + name = "ambrosia gaia branch" + desc = "Eating this makes you immortal." + icon_state = "ambrosia_gaia" + filling_color = rgb(255, 175, 0) + origin_tech = "biotech=6;materials=5" + light_range = 3 + seed = /obj/item/seeds/ambrosia/gaia + +// Ambrosia Cruciatus +/obj/item/seeds/ambrosia/cruciatus + product = /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/cruciatus + potency = 10 + mutatelist = list() + reagents_add = list("thc" = 0.15, "kelotane" = 0.15, "bicaridine" = 0.1, "bath_salts" = 0.20, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/cruciatus + seed = /obj/item/seeds/ambrosia/cruciatus \ No newline at end of file diff --git a/code/modules/hydroponics/grown/apple.dm b/code/modules/hydroponics/grown/apple.dm new file mode 100644 index 00000000000..8acfac34f74 --- /dev/null +++ b/code/modules/hydroponics/grown/apple.dm @@ -0,0 +1,57 @@ +// Apple +/obj/item/seeds/apple + name = "pack of apple seeds" + desc = "These seeds grow into apple trees." + icon_state = "seed-apple" + species = "apple" + plantname = "Apple Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/apple + lifespan = 55 + endurance = 35 + yield = 5 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "apple-grow" + icon_dead = "apple-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/apple/gold) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/apple + seed = /obj/item/seeds/apple + name = "apple" + desc = "It's a little piece of Eden." + icon_state = "apple" + filling_color = "#FF4500" + bitesize = 100 // Always eat the apple in one bite + +// Posioned Apple +/obj/item/seeds/apple/poisoned + product = /obj/item/weapon/reagent_containers/food/snacks/grown/apple/poisoned + mutatelist = list() + reagents_add = list("cyanide" = 0.5, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 50 // Source of cyanide, and hard (almost impossible) to obtain normally. + +/obj/item/weapon/reagent_containers/food/snacks/grown/apple/poisoned + seed = /obj/item/seeds/apple/poisoned + +// Gold Apple +/obj/item/seeds/apple/gold + name = "pack of golden apple seeds" + desc = "These seeds grow into golden apple trees. Good thing there are no firebirds in space." + icon_state = "seed-goldapple" + species = "goldapple" + plantname = "Golden Apple Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/apple/gold + maturation = 10 + production = 10 + mutatelist = list() + reagents_add = list("gold" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 40 // Alchemy! + +/obj/item/weapon/reagent_containers/food/snacks/grown/apple/gold + seed = /obj/item/seeds/apple/gold + name = "golden apple" + desc = "Emblazoned upon the apple is the word 'Kallisti'." + icon_state = "goldapple" + filling_color = "#FFD700" + origin_tech = "biotech=4;materials=5" diff --git a/code/modules/hydroponics/grown/banana.dm b/code/modules/hydroponics/grown/banana.dm new file mode 100644 index 00000000000..b59eeb42e53 --- /dev/null +++ b/code/modules/hydroponics/grown/banana.dm @@ -0,0 +1,121 @@ +// Banana +/obj/item/seeds/banana + name = "pack of banana seeds" + desc = "They're seeds that grow into banana trees. When grown, keep away from clown." + icon_state = "seed-banana" + species = "banana" + plantname = "Banana Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/banana + lifespan = 50 + endurance = 30 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_dead = "banana-dead" + genes = list(/datum/plant_gene/trait/slip, /datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/banana/mime, /obj/item/seeds/banana/bluespace) + reagents_add = list("banana" = 0.1, "potassium" = 0.1, "vitamin" = 0.04, "nutriment" = 0.02) + +/obj/item/weapon/reagent_containers/food/snacks/grown/banana + seed = /obj/item/seeds/banana + name = "banana" + desc = "It's an excellent prop for a clown." + icon_state = "banana" + item_state = "banana" + trash = /obj/item/weapon/grown/bananapeel + filling_color = "#FFFF00" + bitesize = 5 + +/obj/item/weapon/reagent_containers/food/snacks/grown/banana/suicide_act(mob/user) + user.visible_message("[user] is aiming the [src.name] at themself! It looks like \he's trying to commit suicide.") + playsound(loc, 'sound/items/bikehorn.ogg', 50, 1, -1) + sleep(25) + if(!user) + return (OXYLOSS) + user.say("BANG!") + sleep(25) + if(!user) + return (OXYLOSS) + user.visible_message("[user] laughs so hard they begin to suffocate!") + return (OXYLOSS) + +/obj/item/weapon/grown/bananapeel + seed = /obj/item/seeds/banana + name = "banana peel" + desc = "A peel from a banana." + icon_state = "banana_peel" + item_state = "banana_peel" + w_class = 1 + throwforce = 0 + throw_speed = 3 + throw_range = 7 + +/obj/item/weapon/grown/bananapeel/suicide_act(mob/user) + user.visible_message("[user] is deliberately slipping on the [src.name]! It looks like \he's trying to commit suicide.") + playsound(loc, 'sound/misc/slip.ogg', 50, 1, -1) + return (BRUTELOSS) + + +// Mimana - invisible sprites are totally a feature! +/obj/item/seeds/banana/mime + name = "pack of mimana seeds" + desc = "They're seeds that grow into mimana trees. When grown, keep away from mime." + icon_state = "seed-mimana" + species = "mimana" + plantname = "Mimana Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/banana/mime + growthstages = 4 + mutatelist = list() + reagents_add = list("nothing" = 0.1, "capulettium_plus" = 0.1, "nutriment" = 0.02) + rarity = 15 + +/obj/item/weapon/reagent_containers/food/snacks/grown/banana/mime + seed = /obj/item/seeds/banana/mime + name = "mimana" + desc = "It's an excellent prop for a mime." + icon_state = "mimana" + trash = /obj/item/weapon/grown/bananapeel/mimanapeel + filling_color = "#FFFFEE" + +/obj/item/weapon/grown/bananapeel/mimanapeel + seed = /obj/item/seeds/banana/mime + name = "mimana peel" + desc = "A mimana peel." + icon_state = "mimana_peel" + +// Bluespace Banana +/obj/item/seeds/banana/bluespace + name = "pack of bluespace banana seeds" + desc = "They're seeds that grow into bluespace banana trees. When grown, keep away from bluespace clown." + icon_state = "seed-banana-blue" + species = "bluespacebanana" + icon_grow = "banana-grow" + plantname = "Bluespace Banana Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/banana/bluespace + mutatelist = list() + genes = list(/datum/plant_gene/trait/slip, /datum/plant_gene/trait/teleport, /datum/plant_gene/trait/repeated_harvest) + reagents_add = list("singulo" = 0.2, "banana" = 0.1, "vitamin" = 0.04, "nutriment" = 0.02) + rarity = 30 + +/obj/item/weapon/reagent_containers/food/snacks/grown/banana/bluespace + seed = /obj/item/seeds/banana/bluespace + name = "bluespace banana" + icon_state = "banana_blue" + trash = /obj/item/weapon/grown/bananapeel/bluespace + filling_color = "#0000FF" + origin_tech = "biotech=3;bluespace=5" + +/obj/item/weapon/grown/bananapeel/bluespace + seed = /obj/item/seeds/banana/bluespace + name = "bluespace banana peel" + desc = "A peel from a bluespace banana." + icon_state = "banana_peel_blue" + +// Other +/obj/item/weapon/grown/bananapeel/specialpeel //used by /obj/item/clothing/shoes/clown_shoes/banana_shoes + name = "synthesized banana peel" + desc = "A synthetic banana peel." + +/obj/item/weapon/grown/bananapeel/specialpeel/Crossed(AM) + if(iscarbon(AM)) + var/mob/living/carbon/carbon = AM + if(carbon.slip("[src]", 2, 2)) + qdel(src) diff --git a/code/modules/hydroponics/grown/beans.dm b/code/modules/hydroponics/grown/beans.dm new file mode 100644 index 00000000000..277dfd06298 --- /dev/null +++ b/code/modules/hydroponics/grown/beans.dm @@ -0,0 +1,48 @@ +// Soybeans +/obj/item/seeds/soya + name = "pack of soybean seeds" + desc = "These seeds grow into soybean plants." + icon_state = "seed-soybean" + species = "soybean" + plantname = "Soybean Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/soybeans + maturation = 4 + production = 4 + potency = 15 + growthstages = 4 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "soybean-grow" + icon_dead = "soybean-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/soya/koi) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/soybeans + seed = /obj/item/seeds/soya + name = "soybeans" + desc = "It's pretty bland, but oh the possibilities..." + gender = PLURAL + icon_state = "soybeans" + filling_color = "#F0E68C" + bitesize_mod = 2 + +// Koibean +/obj/item/seeds/soya/koi + name = "pack of koibean seeds" + desc = "These seeds grow into koibean plants." + icon_state = "seed-koibean" + species = "koibean" + plantname = "Koibean Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/koibeans + potency = 10 + mutatelist = list() + reagents_add = list("carpotoxin" = 0.1, "vitamin" = 0.04, "nutriment" = 0.05) + rarity = 20 + +/obj/item/weapon/reagent_containers/food/snacks/grown/koibeans + seed = /obj/item/seeds/soya/koi + name = "koibean" + desc = "Something about these seems fishy." + icon_state = "koibeans" + filling_color = "#F0E68C" + bitesize_mod = 2 \ No newline at end of file diff --git a/code/modules/hydroponics/grown/berries.dm b/code/modules/hydroponics/grown/berries.dm new file mode 100644 index 00000000000..165853c63f7 --- /dev/null +++ b/code/modules/hydroponics/grown/berries.dm @@ -0,0 +1,188 @@ +// Berries +/obj/item/seeds/berry + name = "pack of berry seeds" + desc = "These seeds grow into berry bushes." + icon_state = "seed-berry" + species = "berry" + plantname = "Berry Bush" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/berries + lifespan = 20 + maturation = 5 + production = 5 + yield = 2 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "berry-grow" // Uses one growth icons set for all the subtypes + icon_dead = "berry-dead" // Same for the dead icon + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/berry/glow, /obj/item/seeds/berry/poison) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/berries + seed = /obj/item/seeds/berry + name = "bunch of berries" + desc = "Nutritious!" + icon_state = "berrypile" + gender = PLURAL + filling_color = "#FF00FF" + bitesize_mod = 2 + +// Poison Berries +/obj/item/seeds/berry/poison + name = "pack of poison-berry seeds" + desc = "These seeds grow into poison-berry bushes." + icon_state = "seed-poisonberry" + species = "poisonberry" + plantname = "Poison-Berry Bush" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison + mutatelist = list(/obj/item/seeds/berry/death) + reagents_add = list("cyanide" = 0.15, "tirizene" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 10 // Mildly poisonous berries are common in reality + +/obj/item/weapon/reagent_containers/food/snacks/grown/berries/poison + seed = /obj/item/seeds/berry/poison + name = "bunch of poison-berries" + desc = "Taste so good, you could die!" + icon_state = "poisonberrypile" + filling_color = "#C71585" + +// Death Berries +/obj/item/seeds/berry/death + name = "pack of death-berry seeds" + desc = "These seeds grow into death berries." + icon_state = "seed-deathberry" + species = "deathberry" + plantname = "Death Berry Bush" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/berries/death + lifespan = 30 + potency = 50 + mutatelist = list() + reagents_add = list("coniine" = 0.08, "tirizene" = 0.1, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 30 + +/obj/item/weapon/reagent_containers/food/snacks/grown/berries/death + seed = /obj/item/seeds/berry/death + name = "bunch of death-berries" + desc = "Taste so good, you could die!" + icon_state = "deathberrypile" + filling_color = "#708090" + +// Glow Berries +/obj/item/seeds/berry/glow + name = "pack of glow-berry seeds" + desc = "These seeds grow into glow-berry bushes." + icon_state = "seed-glowberry" + species = "glowberry" + plantname = "Glow-Berry Bush" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/berries/glow + lifespan = 30 + endurance = 25 + mutatelist = list() + genes = list(/datum/plant_gene/trait/glow/berry , /datum/plant_gene/trait/noreact, /datum/plant_gene/trait/repeated_harvest) + reagents_add = list("uranium" = 0.25, "iodine" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 20 + +/obj/item/weapon/reagent_containers/food/snacks/grown/berries/glow + seed = /obj/item/seeds/berry/glow + name = "bunch of glow-berries" + desc = "Nutritious!" + icon_state = "glowberrypile" + filling_color = "#7CFC00" + origin_tech = "plasmatech=6" + light_color = "#006622" + +// Cherries +/obj/item/seeds/cherry + name = "pack of cherry pits" + desc = "Careful not to crack a tooth on one... That'd be the pits." + icon_state = "seed-cherry" + species = "cherry" + plantname = "Cherry Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cherries + lifespan = 35 + endurance = 35 + maturation = 5 + production = 5 + growthstages = 5 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "cherry-grow" + icon_dead = "cherry-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/cherry/blue) + reagents_add = list("nutriment" = 0.07, "sugar" = 0.07) + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherries + seed = /obj/item/seeds/cherry + name = "cherries" + desc = "Great for toppings!" + icon_state = "cherry" + gender = PLURAL + filling_color = "#FF0000" + bitesize_mod = 2 + +// Blue Cherries +/obj/item/seeds/cherry/blue + name = "pack of blue cherry pits" + desc = "The blue kind of cherries" + icon_state = "seed-bluecherry" + species = "bluecherry" + plantname = "Blue Cherry Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/bluecherries + mutatelist = list() + reagents_add = list("nutriment" = 0.07, "sugar" = 0.07) + rarity = 10 + +/obj/item/weapon/reagent_containers/food/snacks/grown/bluecherries + seed = /obj/item/seeds/cherry/blue + name = "blue cherries" + desc = "They're cherries that are blue." + icon_state = "bluecherry" + filling_color = "#6495ED" + bitesize_mod = 2 + +// Grapes +/obj/item/seeds/grape + name = "pack of grape seeds" + desc = "These seeds grow into grape vines." + icon_state = "seed-grapes" + species = "grape" + plantname = "Grape Vine" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/grapes + lifespan = 50 + endurance = 25 + maturation = 3 + production = 5 + yield = 4 + growthstages = 2 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "grape-grow" + icon_dead = "grape-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/grape/green) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1, "sugar" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/grapes + seed = /obj/item/seeds/grape + name = "bunch of grapes" + desc = "Nutritious!" + icon_state = "grapes" + dried_type = /obj/item/weapon/reagent_containers/food/snacks/no_raisin + filling_color = "#FF1493" + bitesize_mod = 2 + +// Green Grapes +/obj/item/seeds/grape/green + name = "pack of green grape seeds" + desc = "These seeds grow into green-grape vines." + icon_state = "seed-greengrapes" + species = "greengrape" + plantname = "Green-Grape Vine" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/grapes/green + reagents_add = list("kelotane" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1, "sugar" = 0.1) + // No rarity: technically it's a beneficial mutant, but it's not exactly "new"... + mutatelist = list() + +/obj/item/weapon/reagent_containers/food/snacks/grown/grapes/green + seed = /obj/item/seeds/grape/green + name = "bunch of green grapes" + icon_state = "greengrapes" + filling_color = "#7FFF00" diff --git a/code/modules/hydroponics/grown/cannabis.dm b/code/modules/hydroponics/grown/cannabis.dm new file mode 100644 index 00000000000..ab1dff988e8 --- /dev/null +++ b/code/modules/hydroponics/grown/cannabis.dm @@ -0,0 +1,121 @@ +// Cannabis +/obj/item/seeds/cannabis + name = "pack of cannabis seeds" + desc = "Taxable." + icon_state = "seed-cannabis" + species = "cannabis" + plantname = "Cannabis Plant" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cannabis + maturation = 8 + potency = 20 + growthstages = 1 + growing_icon = 'icons/goonstation/objects/hydroponics.dmi' + icon_grow = "cannabis-grow" // Uses one growth icons set for all the subtypes + icon_dead = "cannabis-dead" // Same for the dead icon + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/cannabis/rainbow, + /obj/item/seeds/cannabis/death, + /obj/item/seeds/cannabis/white, + /obj/item/seeds/cannabis/ultimate) + reagents_add = list("thc" = 0.15) + + +/obj/item/seeds/cannabis/rainbow + name = "pack of rainbow weed seeds" + desc = "These seeds grow into rainbow weed. Groovy." + icon_state = "seed-megacannabis" + species = "megacannabis" + plantname = "Rainbow Weed" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/rainbow + mutatelist = list() + reagents_add = list("lsd" = 0.15, "thc" = 0.15) + rarity = 40 + +/obj/item/seeds/cannabis/death + name = "pack of deathweed seeds" + desc = "These seeds grow into deathweed. Not groovy." + icon_state = "seed-blackcannabis" + species = "blackcannabis" + plantname = "Deathweed" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/death + mutatelist = list() + reagents_add = list("cyanide" = 0.35, "thc" = 0.15) + rarity = 40 + +/obj/item/seeds/cannabis/white + name = "pack of lifeweed seeds" + desc = "I will give unto him that is munchies of the fountain of the cravings of life, freely." + icon_state = "seed-whitecannabis" + species = "whitecannabis" + plantname = "Lifeweed" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/white + mutatelist = list() + reagents_add = list("omnizine" = 0.35, "thc" = 0.15) + rarity = 40 + + +/obj/item/seeds/cannabis/ultimate + name = "pack of omega weed seeds" + desc = "These seeds grow into omega weed." + icon_state = "seed-ocannabis" + species = "ocannabis" + plantname = "Omega Weed" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/ultimate + mutatelist = list() + reagents_add = list("lsd" = 0.15, + "suicider" = 0.15, + "space_drugs" = 0.15, + "mercury" = 0.15, + "lithium" = 0.15, + "atropine" = 0.15, + "ephedrine" = 0.15, + "haloperidol" = 0.15, + "methamphetamine" = 0.15, + "thc" = 0.15, + "psilocybin" = 0.15, + "hairgrownium" = 0.15, + "ectoplasm" = 0.15, + "bath_salts" = 0.15, + "itching_powder" = 0.15, + "crank" = 0.15, + "krokodil" = 0.15, + "histamine" = 0.15) + rarity = 69 + + +// --------------------------------------------------------------- + +/obj/item/weapon/reagent_containers/food/snacks/grown/cannabis + seed = /obj/item/seeds/cannabis + icon = 'icons/goonstation/objects/hydroponics.dmi' + name = "cannabis leaf" + desc = "Recently legalized in most galaxies." + icon_state = "cannabis" + filling_color = "#00FF00" + bitesize_mod = 2 + + +/obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/rainbow + seed = /obj/item/seeds/cannabis/rainbow + name = "rainbow cannabis leaf" + desc = "Is it supposed to be glowing like that...?" + icon_state = "megacannabis" + +/obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/death + seed = /obj/item/seeds/cannabis/death + name = "death cannabis leaf" + desc = "Looks a bit dark. Oh well." + icon_state = "blackcannabis" + +/obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/white + seed = /obj/item/seeds/cannabis/white + name = "white cannabis leaf" + desc = "It feels smooth and nice to the touch." + icon_state = "whitecannabis" + +/obj/item/weapon/reagent_containers/food/snacks/grown/cannabis/ultimate + seed = /obj/item/seeds/cannabis/ultimate + name = "omega cannibas leaf" + desc = "You feel dizzy looking at it. What the fuck?" + icon_state = "ocannabis" + volume = 420 diff --git a/code/modules/hydroponics/grown/cereals.dm b/code/modules/hydroponics/grown/cereals.dm new file mode 100644 index 00000000000..fd5ea080ca3 --- /dev/null +++ b/code/modules/hydroponics/grown/cereals.dm @@ -0,0 +1,90 @@ +// Wheat +/obj/item/seeds/wheat + name = "pack of wheat seeds" + desc = "These may, or may not, grow into wheat." + icon_state = "seed-wheat" + species = "wheat" + plantname = "Wheat Stalks" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/wheat + production = 1 + yield = 4 + potency = 15 + icon_dead = "wheat-dead" + mutatelist = list(/obj/item/seeds/wheat/oat, /obj/item/seeds/wheat/meat) + reagents_add = list("nutriment" = 0.04) + +/obj/item/weapon/reagent_containers/food/snacks/grown/wheat + seed = /obj/item/seeds/wheat + name = "wheat" + desc = "Sigh... wheat... a-grain?" + gender = PLURAL + icon_state = "wheat" + filling_color = "#F0E68C" + bitesize_mod = 2 + +// Oat +/obj/item/seeds/wheat/oat + name = "pack of oat seeds" + desc = "These may, or may not, grow into oat." + icon_state = "seed-oat" + species = "oat" + plantname = "Oat Stalks" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/oat + mutatelist = list() + +/obj/item/weapon/reagent_containers/food/snacks/grown/oat + seed = /obj/item/seeds/wheat/oat + name = "oat" + desc = "Eat oats, do squats." + gender = PLURAL + icon_state = "oat" + filling_color = "#556B2F" + bitesize_mod = 2 + +// Rice +/obj/item/seeds/wheat/rice + name = "pack of rice seeds" + desc = "These may, or may not, grow into rice." + icon_state = "seed-rice" + species = "rice" + plantname = "Rice Stalks" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/rice + mutatelist = list() + growthstages = 3 + +/obj/item/weapon/reagent_containers/food/snacks/grown/rice + seed = /obj/item/seeds/wheat/rice + name = "rice" + desc = "Rice to meet you." + gender = PLURAL + icon_state = "rice" + filling_color = "#FAFAD2" + bitesize_mod = 2 + +//Meatwheat - grows into synthetic meat +/obj/item/seeds/wheat/meat + name = "pack of meatwheat seeds" + desc = "If you ever wanted to drive a vegetarian to insanity, here's how." + icon_state = "seed-meatwheat" + species = "meatwheat" + plantname = "Meatwheat" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/meatwheat + mutatelist = list() + +/obj/item/weapon/reagent_containers/food/snacks/grown/meatwheat + name = "meatwheat" + desc = "Some blood-drenched wheat stalks. You can crush them into what passes for meat if you squint hard enough." + icon_state = "meatwheat" + gender = PLURAL + filling_color = rgb(150, 0, 0) + bitesize_mod = 2 + seed = /obj/item/seeds/wheat/meat + +/obj/item/weapon/reagent_containers/food/snacks/grown/meatwheat/attack_self(mob/living/user) + user.visible_message("[user] crushes [src] into meat.", "You crush [src] into something that resembles meat.") + playsound(user, 'sound/effects/blobattack.ogg', 50, 1) + var/obj/item/weapon/reagent_containers/food/snacks/meat/meatwheat/M = new(get_turf(user)) + user.drop_item() + qdel(src) + user.put_in_hands(M) + return 1 diff --git a/code/modules/hydroponics/grown/chili.dm b/code/modules/hydroponics/grown/chili.dm new file mode 100644 index 00000000000..4d07f17bb4c --- /dev/null +++ b/code/modules/hydroponics/grown/chili.dm @@ -0,0 +1,76 @@ +// Chili +/obj/item/seeds/chili + name = "pack of chili seeds" + desc = "These seeds grow into chili plants. HOT! HOT! HOT!" + icon_state = "seed-chili" + species = "chili" + plantname = "Chili Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/chili + lifespan = 20 + maturation = 5 + production = 5 + yield = 4 + potency = 20 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "chili-grow" // Uses one growth icons set for all the subtypes + icon_dead = "chili-dead" // Same for the dead icon + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/chili/ice, /obj/item/seeds/chili/ghost) + reagents_add = list("capsaicin" = 0.25, "vitamin" = 0.04, "nutriment" = 0.04) + +/obj/item/weapon/reagent_containers/food/snacks/grown/chili + seed = /obj/item/seeds/chili + name = "chili" + desc = "It's spicy! Wait... IT'S BURNING ME!!" + icon_state = "chilipepper" + filling_color = "#FF0000" + bitesize_mod = 2 + +// Ice Chili +/obj/item/seeds/chili/ice + name = "pack of ice pepper seeds" + desc = "These seeds grow into ice pepper plants." + icon_state = "seed-icepepper" + species = "chiliice" + plantname = "Ice Pepper Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/icepepper + lifespan = 25 + maturation = 4 + production = 4 + rarity = 20 + mutatelist = list() + reagents_add = list("frostoil" = 0.25, "vitamin" = 0.02, "nutriment" = 0.02) + +/obj/item/weapon/reagent_containers/food/snacks/grown/icepepper + seed = /obj/item/seeds/chili/ice + name = "ice pepper" + desc = "It's a mutant strain of chili" + icon_state = "icepepper" + filling_color = "#0000CD" + bitesize_mod = 2 + origin_tech = "biotech=4" + +// Ghost Chili +/obj/item/seeds/chili/ghost + name = "pack of ghost chili seeds" + desc = "These seeds grow into a chili said to be the hottest in the galaxy." + icon_state = "seed-chilighost" + species = "chilighost" + plantname = "Ghost Chili Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/ghost_chili + endurance = 10 + maturation = 10 + production = 10 + yield = 3 + rarity = 20 + mutatelist = list() + reagents_add = list("condensedcapsaicin" = 0.3, "capsaicin" = 0.55, "nutriment" = 0.04) + +/obj/item/weapon/reagent_containers/food/snacks/grown/ghost_chili + seed = /obj/item/seeds/chili/ghost + name = "ghost chili" + desc = "It seems to be vibrating gently." + icon_state = "ghostchilipepper" + filling_color = "#F8F8FF" + bitesize_mod = 4 + origin_tech = "biotech=4;magnets=5" \ No newline at end of file diff --git a/code/modules/hydroponics/grown/citrus.dm b/code/modules/hydroponics/grown/citrus.dm new file mode 100644 index 00000000000..7562e013b50 --- /dev/null +++ b/code/modules/hydroponics/grown/citrus.dm @@ -0,0 +1,155 @@ +// Citrus - base type +/obj/item/weapon/reagent_containers/food/snacks/grown/citrus + seed = /obj/item/seeds/lime + name = "citrus" + desc = "It's so sour, your face will twist." + icon_state = "lime" + bitesize_mod = 2 + +// Lime +/obj/item/seeds/lime + name = "pack of lime seeds" + desc = "These are very sour seeds." + icon_state = "seed-lime" + species = "lime" + plantname = "Lime Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lime + lifespan = 55 + endurance = 50 + yield = 4 + potency = 15 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/orange) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lime + seed = /obj/item/seeds/lime + name = "lime" + desc = "It's so sour, your face will twist." + icon_state = "lime" + filling_color = "#00FF00" + +// Orange +/obj/item/seeds/orange + name = "pack of orange seeds" + desc = "Sour seeds." + icon_state = "seed-orange" + species = "orange" + plantname = "Orange Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/orange + lifespan = 60 + endurance = 50 + yield = 5 + potency = 20 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "lime-grow" + icon_dead = "lime-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/lime) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/citrus/orange + seed = /obj/item/seeds/orange + name = "orange" + desc = "It's an tangy fruit." + icon_state = "orange" + filling_color = "#FFA500" + +// Lemon +/obj/item/seeds/lemon + name = "pack of lemon seeds" + desc = "These are sour seeds." + icon_state = "seed-lemon" + species = "lemon" + plantname = "Lemon Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lemon + lifespan = 55 + endurance = 45 + yield = 4 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "lime-grow" + icon_dead = "lime-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/firelemon) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/citrus/lemon + seed = /obj/item/seeds/lemon + name = "lemon" + desc = "When life gives you lemons, make lemonade." + icon_state = "lemon" + filling_color = "#FFD700" + +// Combustible lemon +/obj/item/seeds/firelemon //combustible lemon is too long so firelemon + name = "pack of combustible lemon seeds" + desc = "When life gives you lemons, don't make lemonade. Make life take the lemons back! Get mad! I don't want your damn lemons!" + icon_state = "seed-firelemon" + species = "firelemon" + plantname = "Combustible Lemon Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/firelemon + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "lime-grow" + icon_dead = "lime-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + lifespan = 55 + endurance = 45 + yield = 4 + reagents_add = list("nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon + seed = /obj/item/seeds/firelemon + name = "Combustible Lemon" + desc = "Made for burning houses down." + icon_state = "firelemon" + bitesize_mod = 2 + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon/attack_self(mob/living/user) + var/area/A = get_area(user) + user.visible_message("[user] primes the [src]!", "You prime the [src]!") + var/message = "[ADMIN_LOOKUPFLW(user)] primed a combustible lemon for detonation at [A] [ADMIN_COORDJMP(user)]" + bombers += message + message_admins(message) + log_game("[key_name(user)] primed a combustible lemon for detonation at [A] [COORD(user)].") + if(iscarbon(user)) + var/mob/living/carbon/C = user + C.throw_mode_on() + icon_state = "firelemon_active" + playsound(loc, 'sound/weapons/armbomb.ogg', 75, 1, -3) + addtimer(src, "prime", rand(10, 60)) + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon/burn() + prime() + ..() + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon/proc/update_mob() + if(ismob(loc)) + var/mob/M = loc + M.unEquip(src) + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon/ex_act(severity) + qdel(src) //Ensuring that it's deleted by its own explosion + +/obj/item/weapon/reagent_containers/food/snacks/grown/firelemon/proc/prime() + switch(seed.potency) //Combustible lemons are alot like IEDs, lots of flame, very little bang. + if(0 to 30) + update_mob() + explosion(loc,-1,-1,2, flame_range = 1) + qdel(src) + if(31 to 50) + update_mob() + explosion(loc,-1,-1,2, flame_range = 2) + qdel(src) + if(51 to 70) + update_mob() + explosion(loc,-1,-1,2, flame_range = 3) + qdel(src) + if(71 to 90) + update_mob() + explosion(loc,-1,-1,2, flame_range = 4) + qdel(src) + else + update_mob() + explosion(loc,-1,-1,2, flame_range = 5) + qdel(src) diff --git a/code/modules/hydroponics/grown/cocoa_vanilla.dm b/code/modules/hydroponics/grown/cocoa_vanilla.dm new file mode 100644 index 00000000000..6e04bdaf97d --- /dev/null +++ b/code/modules/hydroponics/grown/cocoa_vanilla.dm @@ -0,0 +1,46 @@ +// Cocoa Pod +/obj/item/seeds/cocoapod + name = "pack of cocoa pod seeds" + desc = "These seeds grow into cacao trees. They look fattening." //SIC: cocoa is the seeds. The trees are spelled cacao. + icon_state = "seed-cocoapod" + species = "cocoapod" + plantname = "Cocao Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cocoapod + lifespan = 20 + maturation = 5 + production = 5 + yield = 2 + growthstages = 5 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "cocoapod-grow" + icon_dead = "cocoapod-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/cocoapod/vanillapod) + reagents_add = list("cocoa" = 0.25, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/cocoapod + seed = /obj/item/seeds/cocoapod + name = "cocoa pod" + desc = "Fattening... Mmmmm... chucklate." + icon_state = "cocoapod" + filling_color = "#FFD700" + bitesize_mod = 2 + +// Vanilla Pod +/obj/item/seeds/cocoapod/vanillapod + name = "pack of vanilla pod seeds" + desc = "These seeds grow into vanilla trees. They look fattening." + icon_state = "seed-vanillapod" + species = "vanillapod" + plantname = "Vanilla Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/vanillapod + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list() + reagents_add = list("vanilla" = 0.25, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/vanillapod + seed = /obj/item/seeds/cocoapod/vanillapod + name = "vanilla pod" + desc = "Fattening... Mmmmm... vanilla." + icon_state = "vanillapod" + filling_color = "#FFD700" \ No newline at end of file diff --git a/code/modules/hydroponics/grown/corn.dm b/code/modules/hydroponics/grown/corn.dm new file mode 100644 index 00000000000..835b2574731 --- /dev/null +++ b/code/modules/hydroponics/grown/corn.dm @@ -0,0 +1,84 @@ +// Corn +/obj/item/seeds/corn + name = "pack of corn seeds" + desc = "I don't mean to sound corny..." + icon_state = "seed-corn" + species = "corn" + plantname = "Corn Stalks" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/corn + maturation = 8 + potency = 20 + growthstages = 3 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "corn-grow" // Uses one growth icons set for all the subtypes + icon_dead = "corn-dead" // Same for the dead icon + mutatelist = list(/obj/item/seeds/corn/snapcorn) + reagents_add = list("cornoil" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/corn + seed = /obj/item/seeds/corn + name = "ear of corn" + desc = "Needs some butter!" + icon_state = "corn" + cooked_type = /obj/item/weapon/reagent_containers/food/snacks/popcorn + filling_color = "#FFFF00" + trash = /obj/item/weapon/grown/corncob + bitesize_mod = 2 + +/obj/item/weapon/grown/corncob + name = "corn cob" + desc = "A reminder of meals gone by." + icon_state = "corncob" + item_state = "corncob" + w_class = 1 + throwforce = 0 + throw_speed = 3 + throw_range = 7 + +/obj/item/weapon/grown/corncob/attackby(obj/item/weapon/grown/W, mob/user, params) + if(is_sharp(W)) + to_chat(user, "You use [W] to fashion a pipe out of the corn cob!") + new /obj/item/clothing/mask/cigarette/pipe/cobpipe (user.loc) + user.unEquip(src) + qdel(src) + return + else + return ..() + +// Snapcorn +/obj/item/seeds/corn/snapcorn + name = "pack of snapcorn seeds" + desc = "Oh snap!" + icon_state = "seed-snapcorn" + species = "snapcorn" + plantname = "Snapcorn Stalks" + product = /obj/item/weapon/grown/snapcorn + mutatelist = list() + rarity = 10 + +/obj/item/weapon/grown/snapcorn + seed = /obj/item/seeds/corn/snapcorn + name = "snap corn" + desc = "A cob with snap pops" + icon_state = "snapcorn" + item_state = "corncob" + w_class = 1 + throwforce = 0 + throw_speed = 3 + throw_range = 7 + var/snap_pops = 1 + +/obj/item/weapon/grown/snapcorn/add_juice() + ..() + snap_pops = max(round(seed.potency/8), 1) + +/obj/item/weapon/grown/snapcorn/attack_self(mob/user) + ..() + to_chat(user, "You pick a snap pop from the cob.") + var/obj/item/toy/snappop/S = new /obj/item/toy/snappop(user.loc) + if(ishuman(user)) + user.put_in_hands(S) + snap_pops -= 1 + if(!snap_pops) + new /obj/item/weapon/grown/corncob(user.loc) + qdel(src) \ No newline at end of file diff --git a/code/modules/hydroponics/grown/eggplant.dm b/code/modules/hydroponics/grown/eggplant.dm new file mode 100644 index 00000000000..8ec46ff77de --- /dev/null +++ b/code/modules/hydroponics/grown/eggplant.dm @@ -0,0 +1,44 @@ +// Eggplant +/obj/item/seeds/eggplant + name = "pack of eggplant seeds" + desc = "These seeds grow to produce berries that look nothing like eggs." + icon_state = "seed-eggplant" + species = "eggplant" + plantname = "Eggplants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/eggplant + yield = 2 + potency = 20 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "eggplant-grow" + icon_dead = "eggplant-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/eggplant/eggy) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/eggplant + seed = /obj/item/seeds/eggplant + name = "eggplant" + desc = "Maybe there's a chicken inside?" + icon_state = "eggplant" + filling_color = "#800080" + bitesize_mod = 2 + +// Egg-Plant +/obj/item/seeds/eggplant/eggy + desc = "These seeds grow to produce berries that look a lot like eggs." + icon_state = "seed-eggy" + species = "eggy" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/shell/eggy + lifespan = 75 + production = 12 + mutatelist = list() + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/shell/eggy + seed = /obj/item/seeds/eggplant/eggy + name = "Egg-plant" + desc = "There MUST be a chicken inside." + icon_state = "eggyplant" + trash = /obj/item/weapon/reagent_containers/food/snacks/egg + filling_color = "#F8F8FF" + bitesize_mod = 2 \ No newline at end of file diff --git a/code/modules/hydroponics/grown/flowers.dm b/code/modules/hydroponics/grown/flowers.dm new file mode 100644 index 00000000000..74fc57be99c --- /dev/null +++ b/code/modules/hydroponics/grown/flowers.dm @@ -0,0 +1,202 @@ +// Poppy +/obj/item/seeds/poppy + name = "pack of poppy seeds" + desc = "These seeds grow into poppies." + icon_state = "seed-poppy" + species = "poppy" + plantname = "Poppy Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/poppy + endurance = 10 + maturation = 8 + yield = 6 + potency = 20 + growthstages = 3 + growing_icon = 'icons/obj/hydroponics/growing_flowers.dmi' + icon_grow = "poppy-grow" + icon_dead = "poppy-dead" + mutatelist = list(/obj/item/seeds/poppy/geranium, /obj/item/seeds/poppy/lily) + reagents_add = list("bicaridine" = 0.2, "nutriment" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/poppy + seed = /obj/item/seeds/poppy + name = "poppy" + desc = "Long-used as a symbol of rest, peace, and death." + icon_state = "poppy" + slot_flags = SLOT_HEAD + filling_color = "#FF6347" + bitesize_mod = 3 + +// Lily +/obj/item/seeds/poppy/lily + name = "pack of lily seeds" + desc = "These seeds grow into lilies." + icon_state = "seed-lily" + species = "lily" + plantname = "Lily Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/poppy/lily + mutatelist = list() + +/obj/item/weapon/reagent_containers/food/snacks/grown/poppy/lily + seed = /obj/item/seeds/poppy/lily + name = "lily" + desc = "A beautiful orange flower" + icon_state = "lily" + filling_color = "#FFA500" + +// Geranium +/obj/item/seeds/poppy/geranium + name = "pack of geranium seeds" + desc = "These seeds grow into geranium." + icon_state = "seed-geranium" + species = "geranium" + plantname = "Geranium Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/poppy/geranium + mutatelist = list() + +/obj/item/weapon/reagent_containers/food/snacks/grown/poppy/geranium + seed = /obj/item/seeds/poppy/geranium + name = "geranium" + desc = "A beautiful blue flower" + icon_state = "geranium" + filling_color = "#008B8B" + + +// Harebell +/obj/item/seeds/harebell + name = "pack of harebell seeds" + desc = "These seeds grow into pretty little flowers." + icon_state = "seed-harebell" + species = "harebell" + plantname = "Harebells" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/harebell + lifespan = 100 + endurance = 20 + maturation = 7 + production = 1 + yield = 2 + potency = 30 + growthstages = 4 + genes = list(/datum/plant_gene/trait/plant_type/weed_hardy) + growing_icon = 'icons/obj/hydroponics/growing_flowers.dmi' + reagents_add = list("nutriment" = 0.04) + +/obj/item/weapon/reagent_containers/food/snacks/grown/harebell + seed = /obj/item/seeds/harebell + name = "harebell" + desc = "\"I'll sweeten thy sad grave: thou shalt not lack the flower that's like thy face, pale primrose, nor the azured hare-bell, like thy veins; no, nor the leaf of eglantine, whom not to slander, out-sweeten'd not thy breath.\"" + icon_state = "harebell" + slot_flags = SLOT_HEAD + filling_color = "#E6E6FA" + bitesize_mod = 3 + + +// Sunflower +/obj/item/seeds/sunflower + name = "pack of sunflower seeds" + desc = "These seeds grow into sunflowers." + icon_state = "seed-sunflower" + species = "sunflower" + plantname = "Sunflowers" + product = /obj/item/weapon/grown/sunflower + endurance = 20 + production = 2 + yield = 2 + growthstages = 3 + growing_icon = 'icons/obj/hydroponics/growing_flowers.dmi' + icon_grow = "sunflower-grow" + icon_dead = "sunflower-dead" + mutatelist = list(/obj/item/seeds/sunflower/moonflower, /obj/item/seeds/sunflower/novaflower) + reagents_add = list("cornoil" = 0.08, "nutriment" = 0.04) + +/obj/item/weapon/grown/sunflower // FLOWER POWER! + seed = /obj/item/seeds/sunflower + name = "sunflower" + desc = "It's beautiful! A certain person might beat you to death if you trample these." + icon_state = "sunflower" + damtype = "fire" + force = 0 + slot_flags = SLOT_HEAD + throwforce = 0 + w_class = 1 + throw_speed = 1 + throw_range = 3 + +/obj/item/weapon/grown/sunflower/attack(mob/M, mob/user) + to_chat(M, " [user] smacks you with a sunflower!FLOWER POWER") + to_chat(user, "Your sunflower's FLOWER POWERstrikes [M]") + +// Moonflower +/obj/item/seeds/sunflower/moonflower + name = "pack of moonflower seeds" + desc = "These seeds grow into moonflowers." + icon_state = "seed-moonflower" + species = "moonflower" + plantname = "Moonflowers" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/moonflower + mutatelist = list() + reagents_add = list("moonshine" = 0.2, "vitamin" = 0.02, "nutriment" = 0.02) + rarity = 15 + +/obj/item/weapon/reagent_containers/food/snacks/grown/moonflower + seed = /obj/item/seeds/sunflower/moonflower + name = "moonflower" + desc = "Store in a location at least 50 yards away from werewolves." + icon_state = "moonflower" + slot_flags = SLOT_HEAD + filling_color = "#E6E6FA" + bitesize_mod = 2 + +// Novaflower +/obj/item/seeds/sunflower/novaflower + name = "pack of novaflower seeds" + desc = "These seeds grow into novaflowers." + icon_state = "seed-novaflower" + species = "novaflower" + plantname = "Novaflowers" + product = /obj/item/weapon/grown/novaflower + mutatelist = list() + reagents_add = list("condensedcapsaicin" = 0.25, "capsaicin" = 0.3, "nutriment" = 0) + rarity = 20 + +/obj/item/weapon/grown/novaflower + seed = /obj/item/seeds/sunflower/novaflower + name = "novaflower" + desc = "These beautiful flowers have a crisp smokey scent, like a summer bonfire." + icon_state = "novaflower" + damtype = "fire" + force = 0 + slot_flags = SLOT_HEAD + throwforce = 0 + w_class = 1 + throw_speed = 1 + throw_range = 3 + attack_verb = list("roasted", "scorched", "burned") + +/obj/item/weapon/grown/novaflower/add_juice() + ..() + force = round((5 + seed.potency / 5), 1) + +/obj/item/weapon/grown/novaflower/attack(mob/living/carbon/M, mob/user) + ..() + if(isliving(M)) + to_chat(M, "You are lit on fire from the intense heat of the [name]!") + M.adjust_fire_stacks(seed.potency / 20) + if(M.IgniteMob()) + message_admins("[key_name_admin(user)] set [key_name_admin(M)] on fire") + log_game("[key_name(user)] set [key_name(M)] on fire") + +/obj/item/weapon/grown/novaflower/afterattack(atom/A as mob|obj, mob/user,proximity) + if(!proximity) + return + if(force > 0) + force -= rand(1, (force / 3) + 1) + else + to_chat(usr, "All the petals have fallen off the [name] from violent whacking!") + usr.unEquip(src) + qdel(src) + +/obj/item/weapon/grown/novaflower/pickup(mob/living/carbon/human/user) + ..() + if(!user.gloves) + to_chat(user, "The [name] burns your bare hand!") + user.adjustFireLoss(rand(1, 5)) diff --git a/code/modules/hydroponics/grown/grass_carpet.dm b/code/modules/hydroponics/grown/grass_carpet.dm new file mode 100644 index 00000000000..f113074911c --- /dev/null +++ b/code/modules/hydroponics/grown/grass_carpet.dm @@ -0,0 +1,67 @@ +// Grass +/obj/item/seeds/grass + name = "pack of grass seeds" + desc = "These seeds grow into grass. Yummy!" + icon_state = "seed-grass" + species = "grass" + plantname = "Grass" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/grass + lifespan = 40 + endurance = 40 + maturation = 2 + production = 5 + yield = 5 + growthstages = 2 + icon_grow = "grass-grow" + icon_dead = "grass-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/grass/carpet) + reagents_add = list("nutriment" = 0.02, "hydrogen" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/grass + seed = /obj/item/seeds/grass + name = "grass" + desc = "Green and lush." + icon_state = "grassclump" + filling_color = "#32CD32" + bitesize_mod = 2 + var/stacktype = /obj/item/stack/tile/grass + var/tile_coefficient = 0.02 // 1/50 + +/obj/item/weapon/reagent_containers/food/snacks/grown/grass/attack_self(mob/user) + to_chat(user, "You prepare the astroturf.") + var/grassAmt = 1 + round(seed.potency * tile_coefficient) // The grass we're holding + for(var/obj/item/weapon/reagent_containers/food/snacks/grown/grass/G in user.loc) // The grass on the floor + if(G.type != type) + continue + grassAmt += 1 + round(G.seed.potency * tile_coefficient) + qdel(G) + var/obj/item/stack/tile/GT = new stacktype(user.loc) + while(grassAmt > GT.max_amount) + GT.amount = GT.max_amount + grassAmt -= GT.max_amount + GT = new stacktype(user.loc) + GT.amount = grassAmt + for(var/obj/item/stack/tile/T in user.loc) + if((T.type == stacktype) && (T.amount < T.max_amount) && (T != GT)) + T.attackby(GT, user) + qdel(src) + return + +// Carpet +/obj/item/seeds/grass/carpet + name = "pack of carpet seeds" + desc = "These seeds grow into stylish carpet samples." + icon_state = "seed-carpet" + species = "carpet" + plantname = "Carpet" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/grass/carpet + mutatelist = list() + rarity = 10 + +/obj/item/weapon/reagent_containers/food/snacks/grown/grass/carpet + seed = /obj/item/seeds/grass/carpet + name = "carpet" + desc = "The textile industry's dark secret." + icon_state = "carpetclump" + stacktype = /obj/item/stack/tile/carpet diff --git a/code/modules/hydroponics/grown/herbals.dm b/code/modules/hydroponics/grown/herbals.dm new file mode 100644 index 00000000000..05efe26bd99 --- /dev/null +++ b/code/modules/hydroponics/grown/herbals.dm @@ -0,0 +1,53 @@ +/obj/item/seeds/comfrey + name = "pack of comfrey seeds" + desc = "These seeds grow into comfrey." + icon_state = "seed-cabbage" + species = "cabbage" + plantname = "comfrey" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/comfrey + yield = 2 + maturation = 3 + growthstages = 1 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/comfrey + seed = /obj/item/seeds/comfrey + name = "comfrey leaf" + desc = "Mash to turn into a poultice." + icon_state = "tea_astra_leaves" + color = "#378C61" + bitesize_mod = 2 + +/obj/item/weapon/reagent_containers/food/snacks/grown/comfrey/attack_self(mob/user) + var/obj/item/stack/medical/bruise_pack/comfrey/C = new(get_turf(user)) + C.heal_brute = seed.potency + to_chat(user, "You mash [src] into a poultice.") + user.drop_item() + qdel(src) + +/obj/item/seeds/aloe + name = "pack of aloe seeds" + desc = "These seeds grow into aloe vera plant." + icon_state = "seed-ambrosiavulgaris" + species = "ambrosiavulgaris" + plantname = "Aloe Vera Plant" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/aloe + yield = 2 + icon_dead = "ambrosia-dead" + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/aloe + seed = /obj/item/seeds/aloe + name = "aloe leaf" + desc = "Mash to turn into a poultice." + icon_state = "ambrosiavulgaris" + color = "#4CC5C7" + bitesize_mod = 2 + +/obj/item/weapon/reagent_containers/food/snacks/grown/aloe/attack_self(mob/user) + var/obj/item/stack/medical/ointment/aloe/A = new(get_turf(user)) + A.heal_burn = seed.potency + to_chat(user, "You mash [src] into a poultice.") + user.drop_item() + qdel(src) \ No newline at end of file diff --git a/code/modules/hydroponics/grown/kudzu.dm b/code/modules/hydroponics/grown/kudzu.dm new file mode 100644 index 00000000000..84ea01235e9 --- /dev/null +++ b/code/modules/hydroponics/grown/kudzu.dm @@ -0,0 +1,97 @@ +// A very special plant, deserving it's own file. + +/obj/item/seeds/kudzu + name = "pack of kudzu seeds" + desc = "These seeds grow into a weed that grows incredibly fast." + icon_state = "seed-kudzu" + species = "kudzu" + plantname = "Kudzu" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/kudzupod + genes = list(/datum/plant_gene/trait/repeated_harvest, /datum/plant_gene/trait/plant_type/weed_hardy) + lifespan = 20 + endurance = 10 + yield = 4 + growthstages = 4 + rarity = 30 + var/list/mutations = list() + reagents_add = list("charcoal" = 0.04, "nutriment" = 0.02) + +/obj/item/seeds/kudzu/Copy() + var/obj/item/seeds/kudzu/S = ..() + S.mutations = mutations.Copy() + return S + +/obj/item/seeds/kudzu/suicide_act(mob/user) + user.visible_message("[user] swallows the pack of kudzu seeds! It looks like \he's trying to commit suicide..") + plant(user) + return (BRUTELOSS) + +/obj/item/seeds/kudzu/proc/plant(mob/user) + if(istype(user.loc, /turf/space)) + return + var/turf/T = get_turf(src) + message_admins("Kudzu planted by [key_name_admin(user)](?) (FLW) at ([T.x],[T.y],[T.z] - (JMP))",0,1) + investigate_log("was planted by [key_name(user)] at ([T.x],[T.y],[T.z])","kudzu") + new /obj/effect/spacevine_controller(user.loc, mutations, potency, production) + user.drop_item() + qdel(src) + +/obj/item/seeds/kudzu/attack_self(mob/user) + plant(user) + to_chat(user, "You plant the kudzu. You monster.") + +/obj/item/seeds/kudzu/get_analyzer_text() + var/text = ..() + var/text_string = "" + for(var/datum/spacevine_mutation/SM in mutations) + text_string += "[(text_string == "") ? "" : ", "][SM.name]" + text += "\n- Plant Mutations: [(text_string == "") ? "None" : text_string]" + return text + +/obj/item/seeds/kudzu/on_chem_reaction(datum/reagents/S) + var/list/temp_mut_list = list() + + if(S.has_reagent("sterilizine", 5)) + for(var/datum/spacevine_mutation/SM in mutations) + if(SM.quality == NEGATIVE) + temp_mut_list += SM + if(prob(20) && temp_mut_list.len) + mutations.Remove(pick(temp_mut_list)) + temp_mut_list.Cut() + + if(S.has_reagent("welding_fuel", 5)) + for(var/datum/spacevine_mutation/SM in mutations) + if(SM.quality == POSITIVE) + temp_mut_list += SM + if(prob(20) && temp_mut_list.len) + mutations.Remove(pick(temp_mut_list)) + temp_mut_list.Cut() + + if(S.has_reagent("phenol", 5)) + for(var/datum/spacevine_mutation/SM in mutations) + if(SM.quality == MINOR_NEGATIVE) + temp_mut_list += SM + if(prob(20) && temp_mut_list.len) + mutations.Remove(pick(temp_mut_list)) + temp_mut_list.Cut() + + if(S.has_reagent("blood", 15)) + adjust_production(rand(15, -5)) + + if(S.has_reagent("amanitin", 5)) + adjust_production(rand(5, -15)) + + if(S.has_reagent("plasma", 5)) + adjust_potency(rand(5, -15)) + + if(S.has_reagent("holywater", 10)) + adjust_potency(rand(15, -5)) + + +/obj/item/weapon/reagent_containers/food/snacks/grown/kudzupod + seed = /obj/item/seeds/kudzu + name = "kudzu pod" + desc = "Pueraria Virallis: An invasive species with vines that rapidly creep and wrap around whatever they contact." + icon_state = "kudzupod" + filling_color = "#6B8E23" + bitesize_mod = 2 \ No newline at end of file diff --git a/code/modules/hydroponics/grown/melon.dm b/code/modules/hydroponics/grown/melon.dm new file mode 100644 index 00000000000..633c39d37f6 --- /dev/null +++ b/code/modules/hydroponics/grown/melon.dm @@ -0,0 +1,47 @@ +// Watermelon +/obj/item/seeds/watermelon + name = "pack of watermelon seeds" + desc = "These seeds grow into watermelon plants." + icon_state = "seed-watermelon" + species = "watermelon" + plantname = "Watermelon Vines" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/watermelon + lifespan = 50 + endurance = 40 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_dead = "watermelon-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/watermelon/holy) + reagents_add = list("water" = 0.2, "vitamin" = 0.04, "nutriment" = 0.2) + +/obj/item/weapon/reagent_containers/food/snacks/grown/watermelon + seed = /obj/item/seeds/watermelon + name = "watermelon" + desc = "It's full of watery goodness." + icon_state = "watermelon" + slice_path = /obj/item/weapon/reagent_containers/food/snacks/watermelonslice + slices_num = 5 + dried_type = null + w_class = 3 + filling_color = "#008000" + bitesize_mod = 3 + +// Holymelon +/obj/item/seeds/watermelon/holy + name = "pack of holymelon seeds" + desc = "These seeds grow into holymelon plants." + icon_state = "seed-holymelon" + species = "holymelon" + plantname = "Holy Melon Vines" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/holymelon + mutatelist = list() + reagents_add = list("holywater" = 0.2, "vitamin" = 0.04, "nutriment" = 0.1) + rarity = 20 + +/obj/item/weapon/reagent_containers/food/snacks/grown/holymelon + seed = /obj/item/seeds/watermelon/holy + name = "holymelon" + desc = "The water within this melon has been blessed by some deity that's particularly fond of watermelon." + icon_state = "holymelon" + filling_color = "#FFD700" + dried_type = null diff --git a/code/modules/hydroponics/grown/misc.dm b/code/modules/hydroponics/grown/misc.dm new file mode 100644 index 00000000000..0d0d786a077 --- /dev/null +++ b/code/modules/hydroponics/grown/misc.dm @@ -0,0 +1,139 @@ +// Weeds +/obj/item/seeds/weeds + name = "pack of weed seeds" + desc = "Yo mang, want some weeds?" + icon_state = "seed" + species = "weeds" + plantname = "Starthistle" + lifespan = 100 + endurance = 50 // damm pesky weeds + maturation = 5 + production = 1 + yield = -1 + potency = -1 + growthstages = 4 + genes = list(/datum/plant_gene/trait/plant_type/weed_hardy) + + +// Cabbage +/obj/item/seeds/cabbage + name = "pack of cabbage seeds" + desc = "These seeds grow into cabbages." + icon_state = "seed-cabbage" + species = "cabbage" + plantname = "Cabbages" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cabbage + lifespan = 50 + endurance = 25 + maturation = 3 + production = 5 + yield = 4 + growthstages = 1 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/replicapod) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/cabbage + seed = /obj/item/seeds/cabbage + name = "cabbage" + desc = "Ewwwwwwwwww. Cabbage." + icon_state = "cabbage" + filling_color = "#90EE90" + bitesize_mod = 2 + + +// Sugarcane +/obj/item/seeds/sugarcane + name = "pack of sugarcane seeds" + desc = "These seeds grow into sugarcane." + icon_state = "seed-sugarcane" + species = "sugarcane" + plantname = "Sugarcane" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/sugarcane + genes = list(/datum/plant_gene/trait/repeated_harvest) + lifespan = 60 + endurance = 50 + maturation = 3 + yield = 4 + growthstages = 3 + reagents_add = list("sugar" = 0.25) + +/obj/item/weapon/reagent_containers/food/snacks/grown/sugarcane + seed = /obj/item/seeds/sugarcane + name = "sugarcane" + desc = "Sickly sweet." + icon_state = "sugarcane" + filling_color = "#FFD700" + bitesize_mod = 2 + + +// Gatfruit +/obj/item/seeds/gatfruit + name = "pack of gatfruit seeds" + desc = "These seeds grow into .357 revolvers." + icon_state = "seed-gatfruit" + species = "gatfruit" + plantname = "Gatfruit Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/shell/gatfruit + genes = list(/datum/plant_gene/trait/repeated_harvest) + lifespan = 20 + endurance = 20 + maturation = 40 + production = 10 + yield = 2 + potency = 60 + growthstages = 2 + rarity = 60 // Obtainable only with xenobio+superluck. + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + reagents_add = list("sulfur" = 0.1, "carbon" = 0.1, "nitrogen" = 0.07, "potassium" = 0.05) + +/obj/item/weapon/reagent_containers/food/snacks/grown/shell/gatfruit + seed = /obj/item/seeds/gatfruit + name = "gatfruit" + desc = "It smells like burning." + icon_state = "gatfruit" + origin_tech = "combat=6" + trash = /obj/item/weapon/gun/projectile/revolver + bitesize_mod = 2 + +//Cherry Bombs +/obj/item/seeds/cherry/bomb + name = "pack of cherry bomb pits" + desc = "They give you vibes of dread and frustration." + icon_state = "seed-cherry_bomb" + species = "cherry_bomb" + plantname = "Cherry Bomb Tree" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb + mutatelist = list() + reagents_add = list("nutriment" = 0.1, "sugar" = 0.1, "blackpowder" = 0.7) + rarity = 60 //See above + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb + name = "cherry bombs" + desc = "You think you can hear the hissing of a tiny fuse." + icon_state = "cherry_bomb" + filling_color = rgb(20, 20, 20) + seed = /obj/item/seeds/cherry/bomb + bitesize_mod = 2 + volume = 125 //Gives enough room for the black powder at max potency + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb/attack_self(mob/living/user) + var/area/A = get_area(user) + user.visible_message("[user] plucks the stem from [src]!", "You pluck the stem from [src], which begins to hiss loudly!") + message_admins("[user] ([user.key ? user.key : "no key"]) primed a cherry bomb for detonation at [A] ([user.x], [user.y], [user.z]) (JMP)") + log_game("[user] ([user.key ? user.key : "no key"]) primed a cherry bomb for detonation at [A] ([user.x],[user.y],[user.z]).") + prime() + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb/burn() + prime() + ..() + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb/ex_act(severity) + qdel(src) //Ensuring that it's deleted by its own explosion. Also prevents mass chain reaction with piles of cherry bombs + +/obj/item/weapon/reagent_containers/food/snacks/grown/cherry_bomb/proc/prime() + icon_state = "cherry_bomb_lit" + playsound(src, 'sound/goonstation/misc/fuse.ogg', seed.potency, 0) + reagents.chem_temp = 1000 //Sets off the black powder + reagents.handle_reactions() diff --git a/code/modules/hydroponics/grown/mushrooms.dm b/code/modules/hydroponics/grown/mushrooms.dm new file mode 100644 index 00000000000..0588bdef455 --- /dev/null +++ b/code/modules/hydroponics/grown/mushrooms.dm @@ -0,0 +1,294 @@ +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom + name = "mushroom" + bitesize_mod = 2 + + +// Reishi +/obj/item/seeds/reishi + name = "pack of reishi mycelium" + desc = "This mycelium grows into something medicinal and relaxing." + icon_state = "mycelium-reishi" + species = "reishi" + plantname = "Reishi" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/reishi + lifespan = 35 + endurance = 35 + maturation = 10 + production = 5 + yield = 4 + potency = 15 + growthstages = 4 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + reagents_add = list("morphine" = 0.35, "charcoal" = 0.35, "nutriment" = 0) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/reishi + seed = /obj/item/seeds/reishi + name = "reishi" + desc = "Ganoderma lucidum: A special fungus known for its medicinal and stress relieving properties." + icon_state = "reishi" + filling_color = "#FF4500" + + +// Fly Amanita +/obj/item/seeds/amanita + name = "pack of fly amanita mycelium" + desc = "This mycelium grows into something horrible." + icon_state = "mycelium-amanita" + species = "amanita" + plantname = "Fly Amanitas" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita + lifespan = 50 + endurance = 35 + maturation = 10 + production = 5 + yield = 4 + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + mutatelist = list(/obj/item/seeds/angel) + reagents_add = list("psilocybin" = 0.04, "amanitin" = 0.35, "nutriment" = 0, "growthserum" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/amanita + seed = /obj/item/seeds/amanita + name = "fly amanita" + desc = "Amanita Muscaria: Learn poisonous mushrooms by heart. Only pick mushrooms you know." + icon_state = "amanita" + filling_color = "#FF0000" + + +// Destroying Angel +/obj/item/seeds/angel + name = "pack of destroying angel mycelium" + desc = "This mycelium grows into something devastating." + icon_state = "mycelium-angel" + species = "angel" + plantname = "Destroying Angels" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/angel + lifespan = 50 + endurance = 35 + maturation = 12 + production = 5 + yield = 2 + potency = 35 + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + reagents_add = list("psilocybin" = 0.04, "amanitin" = 0.1, "nutriment" = 0, "amanitin" = 0.2) + rarity = 30 + origin_tech = "biotech=5" + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/angel + seed = /obj/item/seeds/angel + name = "destroying angel" + desc = "Amanita Virosa: Deadly poisonous basidiomycete fungus filled with alpha amatoxins." + icon_state = "angel" + filling_color = "#C0C0C0" + + +// Liberty Cap +/obj/item/seeds/liberty + name = "pack of liberty-cap mycelium" + desc = "This mycelium grows into liberty-cap mushrooms." + icon_state = "mycelium-liberty" + species = "liberty" + plantname = "Liberty-Caps" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/libertycap + maturation = 7 + production = 1 + yield = 5 + potency = 15 + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + reagents_add = list("psilocybin" = 0.25, "nutriment" = 0.02) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/libertycap + seed = /obj/item/seeds/liberty + name = "liberty-cap" + desc = "Psilocybe Semilanceata: Liberate yourself!" + icon_state = "libertycap" + filling_color = "#DAA520" + + +// Plump Helmet +/obj/item/seeds/plump + name = "pack of plump-helmet mycelium" + desc = "This mycelium grows into helmets... maybe." + icon_state = "mycelium-plump" + species = "plump" + plantname = "Plump-Helmet Mushrooms" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/plumphelmet + maturation = 8 + production = 1 + yield = 4 + potency = 15 + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + mutatelist = list(/obj/item/seeds/plump/walkingmushroom) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/plumphelmet + seed = /obj/item/seeds/plump + name = "plump-helmet" + desc = "Plumus Hellmus: Plump, soft and s-so inviting~" + icon_state = "plumphelmet" + filling_color = "#9370DB" + + +// Walking Mushroom +/obj/item/seeds/plump/walkingmushroom + name = "pack of walking mushroom mycelium" + desc = "This mycelium will grow into huge stuff!" + icon_state = "mycelium-walkingmushroom" + species = "walkingmushroom" + plantname = "Walking Mushrooms" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/walkingmushroom + lifespan = 30 + endurance = 30 + maturation = 5 + yield = 1 + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + mutatelist = list() + reagents_add = list("vitamin" = 0.05, "nutriment" = 0.15) + rarity = 30 + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/walkingmushroom + seed = /obj/item/seeds/plump/walkingmushroom + name = "walking mushroom" + desc = "Plumus Locomotus: The beginning of the great walk." + icon_state = "walkingmushroom" + filling_color = "#9370DB" + origin_tech = "biotech=4;programming=5" + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/walkingmushroom/attack_self(mob/user) + if(istype(user.loc, /turf/space)) + return + var/mob/living/simple_animal/hostile/mushroom/M = new /mob/living/simple_animal/hostile/mushroom(user.loc) + M.maxHealth += round(seed.endurance / 4) + M.melee_damage_lower += round(seed.potency / 20) + M.melee_damage_upper += round(seed.potency / 20) + M.move_to_delay -= round(seed.production / 50) + M.health = M.maxHealth + qdel(src) + to_chat(user, "You plant the walking mushroom.") + + +// Chanterelle +/obj/item/seeds/chanter + name = "pack of chanterelle mycelium" + desc = "This mycelium grows into chanterelle mushrooms." + icon_state = "mycelium-chanter" + species = "chanter" + plantname = "Chanterelle Mushrooms" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/chanterelle + lifespan = 35 + endurance = 20 + maturation = 7 + production = 1 + yield = 5 + potency = 15 + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/chanterelle + seed = /obj/item/seeds/chanter + name = "chanterelle cluster" + desc = "Cantharellus Cibarius: These jolly yellow little shrooms sure look tasty!" + icon_state = "chanterelle" + filling_color = "#FFA500" + + +// Glowshroom +/obj/item/seeds/glowshroom + name = "pack of glowshroom mycelium" + desc = "This mycelium -glows- into mushrooms!" + icon_state = "mycelium-glowshroom" + species = "glowshroom" + plantname = "Glowshrooms" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/glowshroom + lifespan = 100 //ten times that is the delay + endurance = 30 + maturation = 15 + production = 1 + yield = 3 //-> spread + potency = 30 //-> brightness + growthstages = 4 + rarity = 20 + genes = list(/datum/plant_gene/trait/glow, /datum/plant_gene/trait/plant_type/fungal_metabolism) + growing_icon = 'icons/obj/hydroponics/growing_mushrooms.dmi' + mutatelist = list(/obj/item/seeds/glowshroom/glowcap) + reagents_add = list("radium" = 0.1, "phosphorus" = 0.1, "nutriment" = 0.04) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/glowshroom + seed = /obj/item/seeds/glowshroom + name = "glowshroom cluster" + desc = "Mycena Bregprox: This species of mushroom glows in the dark." + icon_state = "glowshroom" + filling_color = "#00FA9A" + var/effect_path = /obj/effect/glowshroom + origin_tech = "biotech=4;plasmatech=6" + light_color = "#006622" + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/glowshroom/attack_self(mob/user) + if(istype(user.loc, /turf/space)) + return + var/obj/effect/glowshroom/planted = new effect_path(user.loc) + planted.delay = planted.delay - seed.production * 100 //So the delay goes DOWN with better stats instead of up. :I + planted.endurance = seed.endurance + planted.yield = seed.yield + planted.potency = seed.potency + to_chat(user, "You plant [src].") + qdel(src) + + +// Glowcap +/obj/item/seeds/glowshroom/glowcap + name = "pack of glowcap mycelium" + desc = "This mycelium -powers- into mushrooms!" + icon_state = "mycelium-glowcap" + species = "glowcap" + icon_grow = "glowshroom-grow" + icon_dead = "glowshroom-dead" + plantname = "Glowcaps" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/glowshroom/glowcap + genes = list(/datum/plant_gene/trait/glow, /datum/plant_gene/trait/cell_charge, /datum/plant_gene/trait/plant_type/fungal_metabolism) + mutatelist = list() + reagents_add = list("teslium" = 0.1, "nutriment" = 0.04) + rarity = 30 + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/glowshroom/glowcap + seed = /obj/item/seeds/glowshroom/glowcap + name = "glowcap cluster" + desc = "Mycena Ruthenia: This species of mushroom glows in the dark, but aren't bioluminescent. They're warm to the touch..." + icon_state = "glowcap" + filling_color = "#00FA9A" + effect_path = /obj/effect/glowshroom/glowcap + origin_tech = "biotech=4;powerstorage=6;plasmatech=4" + light_color = "#8E0300" + +// Fungus/Mold +/obj/item/seeds/fungus + name = "pack of fungus spores" + desc = "These spores grow into fungus." + icon_state = "mycelium-tower" + species = "mold" + plantname = "Fungus" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/fungus + yield = 4 + icon_grow = "mold-grow" + icon_dead = "mold-dead" + icon_harvest = "mold-harvest" + growthstages = 3 + genes = list(/datum/plant_gene/trait/plant_type/fungal_metabolism) + reagents_add = list("fungus" = 0.35) + +/obj/item/weapon/reagent_containers/food/snacks/grown/mushroom/fungus + seed = /obj/item/seeds/fungus + name = "fungus" + desc = "A fungus ideal for making antibacterials." + icon_state = "angel" + color = "#4f4331" \ No newline at end of file diff --git a/code/modules/hydroponics/grown/nettle.dm b/code/modules/hydroponics/grown/nettle.dm new file mode 100644 index 00000000000..f6d9be51b4a --- /dev/null +++ b/code/modules/hydroponics/grown/nettle.dm @@ -0,0 +1,113 @@ +/obj/item/seeds/nettle + name = "pack of nettle seeds" + desc = "These seeds grow into nettles." + icon_state = "seed-nettle" + species = "nettle" + plantname = "Nettles" + product = /obj/item/weapon/grown/nettle/basic + lifespan = 30 + endurance = 40 // tuff like a toiger + yield = 4 + growthstages = 5 + genes = list(/datum/plant_gene/trait/repeated_harvest, /datum/plant_gene/trait/plant_type/weed_hardy) + mutatelist = list(/obj/item/seeds/nettle/death) + reagents_add = list("sacid" = 0.5) + +/obj/item/seeds/nettle/death + name = "pack of death-nettle seeds" + desc = "These seeds grow into death-nettles." + icon_state = "seed-deathnettle" + species = "deathnettle" + plantname = "Death Nettles" + product = /obj/item/weapon/grown/nettle/death + endurance = 25 + maturation = 8 + yield = 2 + genes = list(/datum/plant_gene/trait/repeated_harvest, /datum/plant_gene/trait/plant_type/weed_hardy, /datum/plant_gene/trait/stinging) + mutatelist = list() + reagents_add = list("facid" = 0.5, "sacid" = 0.5) + rarity = 20 + +/obj/item/weapon/grown/nettle //abstract type + name = "nettle" + desc = "It's probably not wise to touch it with bare hands..." + icon = 'icons/obj/weapons.dmi' + icon_state = "nettle" + damtype = "fire" + force = 15 + hitsound = 'sound/weapons/bladeslice.ogg' + throwforce = 5 + w_class = 1 + throw_speed = 1 + throw_range = 3 + origin_tech = "combat=3" + attack_verb = list("stung") + +/obj/item/weapon/grown/nettle/suicide_act(mob/user) + user.visible_message("[user] is eating some of the [src.name]! It looks like \he's trying to commit suicide.") + return (BRUTELOSS|TOXLOSS) + +/obj/item/weapon/grown/nettle/pickup(mob/living/user) + ..() + if(!ishuman(user)) + return 0 + var/mob/living/carbon/human/H = user + if(H.gloves) + return 0 + var/organ = ((H.hand ? "l_":"r_") + "arm") + var/obj/item/organ/external/affecting = H.get_organ(organ) + if(affecting) + if(affecting.take_damage(0, force)) + H.UpdateDamageIcon() + to_chat(H, "The nettle burns your bare hand!") + return 1 + + + +/obj/item/weapon/grown/nettle/afterattack(atom/A as mob|obj, mob/user,proximity) + if(!proximity) + return + if(force > 0) + force -= rand(1, (force / 3) + 1) // When you whack someone with it, leaves fall off + else + to_chat(usr, "All the leaves have fallen off the nettle from violent whacking.") + usr.unEquip(src) + qdel(src) + +/obj/item/weapon/grown/nettle/basic + seed = /obj/item/seeds/nettle + +/obj/item/weapon/grown/nettle/basic/add_juice() + ..() + force = round((5 + seed.potency / 5), 1) + +/obj/item/weapon/grown/nettle/death + seed = /obj/item/seeds/nettle/death + name = "deathnettle" + desc = "The glowing nettle incites rage in you just from looking at it!" + icon_state = "deathnettle" + force = 30 + throwforce = 15 + origin_tech = "combat=5" + +/obj/item/weapon/grown/nettle/death/add_juice() + ..() + force = round((5 + seed.potency / 2.5), 1) + +/obj/item/weapon/grown/nettle/death/pickup(mob/living/carbon/user) + if(..()) + if(prob(50)) + user.Paralyse(5) + to_chat(user, "You are stunned by the Deathnettle when you try picking it up!") + +/obj/item/weapon/grown/nettle/death/attack(mob/living/carbon/M, mob/user) + ..() + if(isliving(M)) + to_chat(M, "You are stunned by the powerful acid of the Deathnettle!") + add_logs(user, M, "attacked", src) + + M.AdjustEyeBlurry(force/7) + if(prob(20)) + M.Paralyse(force / 6) + M.Weaken(force / 15) + M.drop_item() diff --git a/code/modules/hydroponics/grown/nymph.dm b/code/modules/hydroponics/grown/nymph.dm new file mode 100644 index 00000000000..b1868f10a11 --- /dev/null +++ b/code/modules/hydroponics/grown/nymph.dm @@ -0,0 +1,26 @@ +/obj/item/seeds/nymph + name = "pack of diona nymph seeds" + desc = "These seeds grow into diona nymphs." + icon_state = "seed-replicapod" + species = "replicapod" + plantname = "Nymph Pod" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/nymph_pod + lifespan = 50 + endurance = 8 + maturation = 10 + production = 1 + yield = 1 + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/nymph_pod + seed = /obj/item/seeds/nymph + name = "nymph pod" + desc = "A peculiar wriggling pod with a grown nymph inside. Crack it open to let the nymph out." + icon_state = "mushy" + bitesize_mod = 2 + +/obj/item/weapon/reagent_containers/food/snacks/grown/nymph_pod/attack_self(mob/user) + new /mob/living/simple_animal/diona(get_turf(user)) + to_chat(user, "You crack open [src] letting the nymph out.") + user.drop_item() + qdel(src) \ No newline at end of file diff --git a/code/modules/hydroponics/grown/peanut.dm b/code/modules/hydroponics/grown/peanut.dm new file mode 100644 index 00000000000..922b64a8a20 --- /dev/null +++ b/code/modules/hydroponics/grown/peanut.dm @@ -0,0 +1,25 @@ +// Peanuts +/obj/item/seeds/peanuts + name = "pack of peanut seeds" + desc = "These seeds grow into peanuts." + icon_state = "seed-potato" + species = "potato" + plantname = "Peanut Vines" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/peanuts + lifespan = 30 + maturation = 10 + production = 1 + yield = 4 + growthstages = 4 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "potato-grow" + icon_dead = "potato-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + reagents_add = list("nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/peanuts + seed = /obj/item/seeds/peanuts + name = "patch of peanuts" + desc = "Best avoided if you have spess allergies." + icon_state = "peanuts" + gender = PLURAL \ No newline at end of file diff --git a/code/modules/hydroponics/grown/potato.dm b/code/modules/hydroponics/grown/potato.dm new file mode 100644 index 00000000000..2b144679698 --- /dev/null +++ b/code/modules/hydroponics/grown/potato.dm @@ -0,0 +1,65 @@ +// Potato +/obj/item/seeds/potato + name = "pack of potato seeds" + desc = "Boil 'em! Mash 'em! Stick 'em in a stew!" + icon_state = "seed-potato" + species = "potato" + plantname = "Potato Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/potato + lifespan = 30 + maturation = 10 + production = 1 + yield = 4 + growthstages = 4 + growing_icon = 'icons/obj/hydroponics/growing_vegetables.dmi' + icon_grow = "potato-grow" + icon_dead = "potato-dead" + genes = list(/datum/plant_gene/trait/battery) + mutatelist = list(/obj/item/seeds/potato/sweet) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/potato + seed = /obj/item/seeds/potato + name = "potato" + desc = "Boil 'em! Mash 'em! Stick 'em in a stew!" + icon_state = "potato" + filling_color = "#E9967A" + bitesize = 100 + + +/obj/item/weapon/reagent_containers/food/snacks/grown/potato/wedges + name = "potato wedges" + desc = "Slices of neatly cut potato." + icon_state = "potato_wedges" + filling_color = "#E9967A" + bitesize = 100 + + +/obj/item/weapon/reagent_containers/food/snacks/grown/potato/attackby(obj/item/weapon/W, mob/user, params) + if(is_sharp(W)) + to_chat(user, "You cut the potato into wedges with [W].") + var/obj/item/weapon/reagent_containers/food/snacks/grown/potato/wedges/Wedges = new /obj/item/weapon/reagent_containers/food/snacks/grown/potato/wedges + if(!remove_item_from_storage(user)) + user.unEquip(src) + user.put_in_hands(Wedges) + qdel(src) + else + return ..() + + +// Sweet Potato +/obj/item/seeds/potato/sweet + name = "pack of sweet potato seeds" + desc = "These seeds grow into sweet potato plants." + icon_state = "seed-sweetpotato" + species = "sweetpotato" + plantname = "Sweet Potato Plants" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/potato/sweet + mutatelist = list() + reagents_add = list("vitamin" = 0.1, "sugar" = 0.1, "nutriment" = 0.1) + +/obj/item/weapon/reagent_containers/food/snacks/grown/potato/sweet + seed = /obj/item/seeds/potato/sweet + name = "sweet potato" + desc = "It's sweet." + icon_state = "sweetpotato" \ No newline at end of file diff --git a/code/modules/hydroponics/grown/pumpkin.dm b/code/modules/hydroponics/grown/pumpkin.dm new file mode 100644 index 00000000000..ed8e64742ce --- /dev/null +++ b/code/modules/hydroponics/grown/pumpkin.dm @@ -0,0 +1,54 @@ +// Pumpkin +/obj/item/seeds/pumpkin + name = "pack of pumpkin seeds" + desc = "These seeds grow into pumpkin vines." + icon_state = "seed-pumpkin" + species = "pumpkin" + plantname = "Pumpkin Vines" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/pumpkin + lifespan = 50 + endurance = 40 + growthstages = 3 + growing_icon = 'icons/obj/hydroponics/growing_fruits.dmi' + icon_grow = "pumpkin-grow" + icon_dead = "pumpkin-dead" + genes = list(/datum/plant_gene/trait/repeated_harvest) + mutatelist = list(/obj/item/seeds/pumpkin/blumpkin) + reagents_add = list("vitamin" = 0.04, "nutriment" = 0.2) + +/obj/item/weapon/reagent_containers/food/snacks/grown/pumpkin + seed = /obj/item/seeds/pumpkin + name = "pumpkin" + desc = "It's large and scary." + icon_state = "pumpkin" + filling_color = "#FFA500" + bitesize_mod = 2 + +/obj/item/weapon/reagent_containers/food/snacks/grown/pumpkin/attackby(obj/item/weapon/W as obj, mob/user as mob, params) + if(is_sharp(W)) + user.show_message("You carve a face into [src]!", 1) + new /obj/item/clothing/head/hardhat/pumpkinhead(user.loc) + qdel(src) + return + else + return ..() + +// Blumpkin +/obj/item/seeds/pumpkin/blumpkin + name = "pack of blumpkin seeds" + desc = "These seeds grow into blumpkin vines." + icon_state = "seed-blumpkin" + species = "blumpkin" + plantname = "Blumpkin Vines" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/blumpkin + mutatelist = list() + reagents_add = list("ammonia" = 0.2, "chlorine" = 0.1, "nutriment" = 0.2) + rarity = 20 + +/obj/item/weapon/reagent_containers/food/snacks/grown/blumpkin + seed = /obj/item/seeds/pumpkin/blumpkin + name = "blumpkin" + desc = "The pumpkin's toxic sibling." + icon_state = "blumpkin" + filling_color = "#87CEFA" + bitesize_mod = 2 diff --git a/code/modules/hydroponics/grown/random.dm b/code/modules/hydroponics/grown/random.dm new file mode 100644 index 00000000000..1f48f83c9a5 --- /dev/null +++ b/code/modules/hydroponics/grown/random.dm @@ -0,0 +1,29 @@ +//Random seeds; stats, traits, and plant type are randomized for each seed. + +/obj/item/seeds/random + name = "pack of strange seeds" + desc = "Mysterious seeds as strange as their name implies. Spooky" + icon_state = "seed-x" + species = "?????" + plantname = "strange plant" + product = /obj/item/weapon/reagent_containers/food/snacks/grown/random + icon_grow = "xpod-grow" + icon_dead = "xpod-dead" + icon_harvest = "xpod-harvest" + growthstages = 4 + +/obj/item/seeds/random/New() + randomize_stats() + ..() + if(prob(60)) + add_random_reagents() + if(prob(50)) + add_random_traits() + add_random_plant_type(35) + +/obj/item/weapon/reagent_containers/food/snacks/grown/random + seed = /obj/item/seeds/random + name = "strange plant" + desc = "What could this even be?" + icon_state = "crunchy" + bitesize_mod = 2 \ No newline at end of file diff --git a/code/modules/hydroponics/grown/replicapod.dm b/code/modules/hydroponics/grown/replicapod.dm new file mode 100644 index 00000000000..f3cfa967363 --- /dev/null +++ b/code/modules/hydroponics/grown/replicapod.dm @@ -0,0 +1,104 @@ +// A very special plant, deserving it's own file. + +/obj/item/seeds/replicapod + name = "pack of replica pod seeds" + desc = "These seeds grow into replica pods. They say these are used to harvest humans." + icon_state = "seed-replicapod" + species = "replicapod" + plantname = "Replica Pod" + product = /mob/living/carbon/human/diona //verrry special -- Urist + lifespan = 50 + endurance = 8 + maturation = 10 + production = 1 + yield = 1 //seeds if there isn't a dna inside + potency = 30 + var/ckey = null + var/realName = null + var/datum/mind/mind = null + var/blood_gender = null + var/blood_type = null + var/factions = null + var/contains_sample = 0 + +/obj/item/seeds/replicapod/Destroy() + mind = null + return ..() + +/obj/item/seeds/replicapod/attackby(obj/item/weapon/W, mob/user, params) + if(istype(W,/obj/item/weapon/reagent_containers/syringe)) + if(!contains_sample) + for(var/datum/reagent/blood/bloodSample in W.reagents.reagent_list) + if(bloodSample.data["mind"] && bloodSample.data["cloneable"] == 1) + mind = bloodSample.data["mind"] + ckey = bloodSample.data["ckey"] + realName = bloodSample.data["real_name"] + blood_gender = bloodSample.data["gender"] + blood_type = bloodSample.data["blood_type"] + factions = bloodSample.data["factions"] + W.reagents.clear_reagents() + to_chat(user, "You inject the contents of the syringe into the seeds.") + contains_sample = 1 + else + to_chat(user, "The seeds reject the sample!") + else + to_chat(user, "The seeds already contain a genetic sample!") + else + return ..() + +/obj/item/seeds/replicapod/get_analyzer_text() + var/text = ..() + if(contains_sample) + text += "\n It contains a blood sample!" + return text + + +/obj/item/seeds/replicapod/harvest(mob/user = usr) //now that one is fun -- Urist + var/obj/machinery/hydroponics/parent = loc + var/make_podman = 0 + var/ckey_holder = null + if(config.revival_pod_plants) + if(ckey) + for(var/mob/M in player_list) + if(isobserver(M)) + var/mob/dead/observer/O = M + if(O.ckey == ckey && O.can_reenter_corpse) + make_podman = 1 + break + else + if(M.ckey == ckey && M.stat == DEAD && !M.suiciding) + make_podman = 1 + break + else //If the player has ghosted from his corpse before blood was drawn, his ckey is no longer attached to the mob, so we need to match up the cloned player through the mind key + for(var/mob/M in player_list) + if(mind && M.mind && ckey(M.mind.key) == ckey(mind.key) && M.ckey && M.client && M.stat == DEAD && !M.suiciding) + if(isobserver(M)) + var/mob/dead/observer/O = M + if(!O.can_reenter_corpse) + break + make_podman = 1 + ckey_holder = M.ckey + break + + if(make_podman) //all conditions met! + var/mob/living/carbon/human/diona/podman = new /mob/living/carbon/human/diona(parent.loc) + if(realName) + podman.real_name = realName + mind.transfer_to(podman) + if(ckey) + podman.ckey = ckey + else + podman.ckey = ckey_holder + podman.gender = blood_gender + podman.faction |= factions + + else //else, one packet of seeds. maybe two + var/seed_count = 1 + if(prob(getYield() * 20)) + seed_count++ + var/output_loc = parent.Adjacent(user) ? user.loc : parent.loc //needed for TK + for(var/i=0,i " + + if (contents.len == 0) + dat += "No seeds" + else + dat += "
Seed storage contents
Plant data for [form_title]" - user.visible_message("[user] runs the scanner over \the [target].") - - dat += "General Data" - - dat += "
Reagent Data" - - dat += "This sample contains: " - for(var/datum/reagent/R in grown_reagents.reagent_list) - dat += " - [R.id], [grown_reagents.get_reagent_amount(R.id)] unit(s)" - - dat += " Other Data" - - if(grown_seed.get_trait(TRAIT_HARVEST_REPEAT)) - dat += "This plant can be harvested repeatedly." - - if(grown_seed.get_trait(TRAIT_IMMUTABLE) == -1) - dat += "This plant is highly mutable. " - else if(grown_seed.get_trait(TRAIT_IMMUTABLE) > 0) - dat += "This plant does not possess genetics that are alterable. " - - if(grown_seed.get_trait(TRAIT_REQUIRES_NUTRIENTS)) - if(grown_seed.get_trait(TRAIT_NUTRIENT_CONSUMPTION) < 0.05) - dat += "It consumes a small amount of nutrient fluid. " - else if(grown_seed.get_trait(TRAIT_NUTRIENT_CONSUMPTION) > 0.2) - dat += "It requires a heavy supply of nutrient fluid. " - else - dat += "It requires a supply of nutrient fluid. " - - if(grown_seed.get_trait(TRAIT_REQUIRES_WATER)) - if(grown_seed.get_trait(TRAIT_WATER_CONSUMPTION) < 1) - dat += "It requires very little water. " - else if(grown_seed.get_trait(TRAIT_WATER_CONSUMPTION) > 5) - dat += "It requires a large amount of water. " - else - dat += "It requires a stable supply of water. " - - if(grown_seed.mutants && grown_seed.mutants.len) - dat += "It exhibits a high degree of potential subspecies shift. " - - dat += "It thrives in a temperature of [grown_seed.get_trait(TRAIT_IDEAL_HEAT)] Kelvin." - - if(grown_seed.consume_gasses && grown_seed.consume_gasses.len) - for(var/gas in grown_seed.consume_gasses) - if(gas == "carbon_dioxide") gas = "carbon dioxide" - if(gas == "toxins") gas = "plasma" - dat += " It requires an environment rich in [gas] gas to thrive." - - if(grown_seed.exude_gasses && grown_seed.exude_gasses.len) - for(var/gas in grown_seed.exude_gasses) - if(gas == "carbon_dioxide") gas = "carbon dioxide" - if(gas == "toxins") gas = "plasma" - dat += " It releases [gas] gas as a byproduct of it's growth." - - if(grown_seed.get_trait(TRAIT_LOWKPA_TOLERANCE) < 20) - dat += " It is well adapted to low pressure levels." - if(grown_seed.get_trait(TRAIT_HIGHKPA_TOLERANCE) > 220) - dat += " It is well adapted to high pressure levels." - - if(grown_seed.get_trait(TRAIT_HEAT_TOLERANCE) > 30) - dat += " It is well adapted to a range of temperatures." - else if(grown_seed.get_trait(TRAIT_HEAT_TOLERANCE) < 10) - dat += " It is very sensitive to temperature shifts." - - dat += " It thrives in a light level of [grown_seed.get_trait(TRAIT_IDEAL_LIGHT)] lumen[grown_seed.get_trait(TRAIT_IDEAL_LIGHT) == 1 ? "" : "s"]." - - if(grown_seed.get_trait(TRAIT_LIGHT_TOLERANCE) > 10) - dat += " It is well adapted to a range of light levels." - else if(grown_seed.get_trait(TRAIT_LIGHT_TOLERANCE) < 3) - dat += " It is very sensitive to light level shifts." - - if(grown_seed.get_trait(TRAIT_TOXINS_TOLERANCE) < 3) - dat += " It is highly sensitive to toxins." - else if(grown_seed.get_trait(TRAIT_TOXINS_TOLERANCE) > 6) - dat += " It is remarkably resistant to toxins." - - if(grown_seed.get_trait(TRAIT_PEST_TOLERANCE) < 3) - dat += " It is highly sensitive to pests." - else if(grown_seed.get_trait(TRAIT_PEST_TOLERANCE) > 6) - dat += " It is remarkably resistant to pests." - - if(grown_seed.get_trait(TRAIT_WEED_TOLERANCE) < 3) - dat += " It is highly sensitive to weeds." - else if(grown_seed.get_trait(TRAIT_WEED_TOLERANCE) > 6) - dat += " It is remarkably resistant to weeds." - - switch(grown_seed.get_trait(TRAIT_SPREAD)) - if(1) - dat += " It is able to be planted outside of a tray." - if(2) - dat += " It is a robust and vigorous vine that will spread rapidly." - - switch(grown_seed.get_trait(TRAIT_CARNIVOROUS)) - if(1) - dat += " It is carniovorous and will eat tray pests for sustenance." - if(2) - dat += " It is carnivorous and poses a significant threat to living things around it." - - if(grown_seed.get_trait(TRAIT_PARASITE)) - dat += " It is capable of parisitizing and gaining sustenance from tray weeds." - if(grown_seed.get_trait(TRAIT_ALTER_TEMP)) - dat += " It will periodically alter the local temperature by [grown_seed.get_trait(TRAIT_ALTER_TEMP)] Kelvin." - - if(grown_seed.get_trait(TRAIT_BIOLUM)) - dat += " It is [grown_seed.get_trait(TRAIT_BIOLUM_COLOUR) ? "bio-luminescent" : "bio-luminescent"]." - - if(grown_seed.get_trait(TRAIT_PRODUCES_POWER)) - dat += " The fruit will function as a battery if prepared appropriately." - - if(grown_seed.get_trait(TRAIT_BATTERY_RECHARGE)) - dat += " The fruit hums with an odd electrical energy." - - if(grown_seed.get_trait(TRAIT_STINGS)) - dat += " The fruit is covered in stinging spines." - - if(grown_seed.get_trait(TRAIT_JUICY) == 1) - dat += " The fruit is soft-skinned and juicy." - else if(grown_seed.get_trait(TRAIT_JUICY) == 2) - dat += " The fruit is excessively juicy." - - if(grown_seed.get_trait(TRAIT_EXPLOSIVE)) - dat += " The fruit is internally unstable." - - if(grown_seed.get_trait(TRAIT_TELEPORTING)) - dat += " The fruit is temporal/spatially unstable." - - if(dat) - last_data = dat - dat += " \[print report\]" - user << browse(dat,"window=plant_analyzer") - - return - -/obj/item/weapon/minihoe // -- Numbers - name = "mini hoe" - desc = "It's used for removing weeds or scratching your back." - icon = 'icons/obj/weapons.dmi' - icon_state = "hoe" - item_state = "hoe" - flags = CONDUCT | NOBLUDGEON - force = 5 - throwforce = 7 - w_class = 2 - materials = list(MAT_METAL=50) - attack_verb = list("slashed", "sliced", "cut", "clawed") - hitsound = 'sound/weapons/bladeslice.ogg' - -//Hatchets and things to kill kudzu -/obj/item/weapon/hatchet - name = "hatchet" - desc = "A very sharp axe blade upon a short fibremetal handle. It has a long history of chopping things, but now it is used for chopping wood." - icon = 'icons/obj/weapons.dmi' - icon_state = "hatchet" - flags = CONDUCT - force = 12 - sharp = 1 - edge = 1 - w_class = 2 - throwforce = 15 - throw_speed = 4 - throw_range = 4 - materials = list(MAT_METAL=15000) - origin_tech = "materials=2;combat=1" - attack_verb = list("chopped", "torn", "cut") - hitsound = 'sound/weapons/bladeslice.ogg' - -/obj/item/weapon/hatchet/unathiknife - name = "duelling knife" - desc = "A length of leather-bound wood studded with razor-sharp teeth. How crude." - icon = 'icons/obj/weapons.dmi' - icon_state = "unathiknife" - attack_verb = list("ripped", "torn", "cut") - -/obj/item/weapon/scythe - icon_state = "scythe0" - name = "scythe" - desc = "A sharp and curved blade on a long fibremetal handle, this tool makes it easy to reap what you sow." - force = 13 - throwforce = 5 - sharp = 1 - edge = 1 - throw_speed = 2 - throw_range = 3 - w_class = 4 - var/extend = 1 - flags = CONDUCT - armour_penetration = 20 - slot_flags = SLOT_BACK - origin_tech = "materials=2;combat=2" - attack_verb = list("chopped", "sliced", "cut", "reaped") - hitsound = 'sound/weapons/bladeslice.ogg' - -/obj/item/weapon/scythe/afterattack(atom/A, mob/user as mob, proximity) - if(!proximity) return - if(istype(A, /obj/effect/plant) && extend == 1) - for(var/obj/effect/plant/B in orange(A,1)) - if(prob(80)) - B.die_off(1) - qdel(A) - -/obj/item/weapon/scythe/tele - icon_state = "tscythe0" - name = "telescopic scythe" - desc = "A sharp and curved blade on a collapsable fibremetal handle, this tool is the pinnacle of covert reaping technology." - force = 3.0 - sharp = 0 - edge = 0 - throw_speed = 2 - throw_range = 3 - w_class = 2 - extend = 0 - armour_penetration = 20 - slot_flags = SLOT_BELT - origin_tech = "materials=3;combat=3" - attack_verb = list("chopped", "sliced", "cut", "reaped") - hitsound = "swing_hit" - -/obj/item/weapon/scythe/tele/attack_self(mob/user as mob) - extend = !extend - if(extend) - to_chat(user, "With a flick of the wrist, you extend the scythe. It's reaping time!") - icon_state = "tscythe1" - item_state = "scythe0" - slot_flags &= ~SLOT_BELT - w_class = 4 //doesnt fit in backpack when its on for balance - force = 13 //normal scythe damage - attack_verb = list("chopped", "sliced", "cut", "reaped") - hitsound = 'sound/weapons/bladeslice.ogg' - //Extend sound (blade unsheath) - playsound(src.loc, 'sound/weapons/blade_unsheath.ogg', 50, 1) //Sound credit to Qat of Freesound.org - else - to_chat(user, "You collapse the scythe, folding it for easy storage.") - icon_state = "tscythe0" - item_state = "tscythe0" //no sprite in other words - slot_flags |= SLOT_BELT - w_class = 2 - force = 3 //not so robust now - attack_verb = list("hit", "poked") - hitsound = "swing_hit" - //Collapse sound (blade sheath) - playsound(src.loc, 'sound/weapons/blade_sheath.ogg', 50, 1) //Sound credit to Q.K. of Freesound.org - if(istype(user,/mob/living/carbon/human)) - var/mob/living/carbon/human/H = user - H.update_inv_l_hand() - H.update_inv_r_hand() - add_fingerprint(user) - if(!blood_DNA) return - if(blood_overlay && (blood_DNA.len >= 1)) //updates blood overlay, if any - overlays.Cut()//this might delete other item overlays as well but eeeeeeeh - - var/icon/I = new /icon(src.icon, src.icon_state) - I.Blend(new /icon('icons/effects/blood.dmi', rgb(255,255,255)),ICON_ADD) - I.Blend(new /icon('icons/effects/blood.dmi', "itemblood"),ICON_MULTIPLY) - blood_overlay = I - - overlays += blood_overlay - - return - -/obj/item/weapon/rsp - name = "\improper Rapid-Seed-Producer (RSP)" - desc = "A device used to rapidly deploy seeds." - icon = 'icons/obj/items.dmi' - icon_state = "rcd" - opacity = 0 - density = 0 - anchored = 0.0 - var/matter = 0 - var/mode = 1 - w_class = 3 - -/obj/item/weapon/bananapeel - name = "banana peel" - desc = "A peel from a banana." - icon = 'icons/obj/items.dmi' - icon_state = "banana_peel" - item_state = "banana_peel" - w_class = 1 - throwforce = 0 - throw_speed = 4 - throw_range = 20 - -/obj/item/weapon/corncob - name = "corn cob" - desc = "A reminder of meals gone by." - icon = 'icons/obj/harvest.dmi' - icon_state = "corncob" - item_state = "corncob" - w_class = 1 - throwforce = 0 - throw_speed = 4 - throw_range = 20 diff --git a/code/modules/hydroponics/trays/tray_update_icons.dm b/code/modules/hydroponics/trays/tray_update_icons.dm deleted file mode 100644 index aac0822a283..00000000000 --- a/code/modules/hydroponics/trays/tray_update_icons.dm +++ /dev/null @@ -1,86 +0,0 @@ -//Refreshes the icon and sets the luminosity -/obj/machinery/portable_atmospherics/hydroponics/update_icon() - // Update name. - if(seed) - if(mechanical) - name = "[base_name] (#[seed.uid])" - else - name = "[seed.seed_name]" - else - name = initial(name) - - if(labelled) - name += " ([labelled])" - - overlays.Cut() - // Updates the plant overlay. - if(!isnull(seed)) - - if(mechanical && health <= (seed.get_trait(TRAIT_ENDURANCE) / 2)) - overlays += "over_lowhealth3" - - if(dead) - var/ikey = "[seed.get_trait(TRAIT_PLANT_ICON)]-dead" - var/image/dead_overlay = plant_controller.plant_icon_cache["[ikey]"] - if(!dead_overlay) - dead_overlay = image('icons/obj/hydroponics_growing.dmi', "[ikey]") - dead_overlay.color = DEAD_PLANT_COLOUR - overlays |= dead_overlay - else - if(!seed.growth_stages) - seed.update_growth_stages() - if(!seed.growth_stages) - to_chat(world, "Seed type [seed.get_trait(TRAIT_PLANT_ICON)] cannot find a growth stage value.") - return - var/overlay_stage = 1 - if(age >= seed.get_trait(TRAIT_MATURATION)) - overlay_stage = seed.growth_stages - else - var/maturation = seed.get_trait(TRAIT_MATURATION)/seed.growth_stages - if(maturation < 1) - maturation = 1 - overlay_stage = maturation ? max(1,round(age/maturation)) : 1 - var/ikey = "[seed.get_trait(TRAIT_PLANT_ICON)]-[overlay_stage]" - var/image/plant_overlay = plant_controller.plant_icon_cache["[ikey]-[seed.get_trait(TRAIT_PLANT_COLOUR)]"] - if(!plant_overlay) - plant_overlay = image('icons/obj/hydroponics_growing.dmi', "[ikey]") - plant_overlay.color = seed.get_trait(TRAIT_PLANT_COLOUR) - plant_controller.plant_icon_cache["[ikey]-[seed.get_trait(TRAIT_PLANT_COLOUR)]"] = plant_overlay - overlays |= plant_overlay - last_plant_ikey = ikey - - if(harvest && overlay_stage == seed.growth_stages) - ikey = "[seed.get_trait(TRAIT_PRODUCT_ICON)]" - var/image/harvest_overlay = plant_controller.plant_icon_cache["product-[ikey]-[seed.get_trait(TRAIT_PLANT_COLOUR)]"] - if(!harvest_overlay) - harvest_overlay = image('icons/obj/hydroponics_products.dmi', "[ikey]") - harvest_overlay.color = seed.get_trait(TRAIT_PRODUCT_COLOUR) - plant_controller.plant_icon_cache["product-[ikey]-[seed.get_trait(TRAIT_PRODUCT_COLOUR)]"] = harvest_overlay - overlays |= harvest_overlay - - //Draw the cover. - if(closed_system) - overlays += "hydrocover" - - //Updated the various alert icons. - if(mechanical) - if(waterlevel <= 10) - overlays += "over_lowwater3" - if(nutrilevel <= 2) - overlays += "over_lownutri3" - if(weedlevel >= 5 || pestlevel >= 5 || toxins >= 40) - overlays += "over_alert3" - if(harvest) - overlays += "over_harvest3" - - // Update bioluminescence. - if(seed) - if(seed.get_trait(TRAIT_BIOLUM)) - var/clr - if(seed.get_trait(TRAIT_BIOLUM_COLOUR)) - clr = seed.get_trait(TRAIT_BIOLUM_COLOUR) - set_light(round(seed.get_trait(TRAIT_POTENCY)/10), l_color = clr) - return - - set_light(0) - return \ No newline at end of file diff --git a/code/modules/library/computers/checkout.dm b/code/modules/library/computers/checkout.dm index 2c0932f1707..2decc555693 100644 --- a/code/modules/library/computers/checkout.dm +++ b/code/modules/library/computers/checkout.dm @@ -459,5 +459,5 @@ B.title = newbook.title B.author = newbook.author B.dat = newbook.content - B.icon_state = "book[rand(1,9)]" + B.icon_state = "book[rand(1,16)]" visible_message("[src]'s printer hums as it produces a completely bound book. How did it do that?") diff --git a/code/modules/library/lib_machines.dm b/code/modules/library/lib_machines.dm index ac6507ee720..6afe3f84518 100644 --- a/code/modules/library/lib_machines.dm +++ b/code/modules/library/lib_machines.dm @@ -217,8 +217,8 @@ var/global/list/library_section_names = list("Any", "Fiction", "Non-Fiction", "A var/obj/item/weapon/book/b = new(loc) b.dat = P.info b.name = "Print Job #[rand(100, 999)]" - b.icon_state = "book[rand(1,7)]" + b.icon_state = "book[rand(1,16)]" qdel(P) return 1 else - return ..() \ No newline at end of file + return ..() diff --git a/code/modules/lighting/lighting_overlay.dm b/code/modules/lighting/lighting_overlay.dm index 525de63a0af..24854085c1a 100644 --- a/code/modules/lighting/lighting_overlay.dm +++ b/code/modules/lighting/lighting_overlay.dm @@ -3,7 +3,6 @@ mouse_opacity = 0 simulated = 0 anchored = 1 - flags = NOREACT icon = LIGHTING_ICON layer = LIGHTING_LAYER invisibility = INVISIBILITY_LIGHTING diff --git a/code/modules/mining/abandonedcrates.dm b/code/modules/mining/abandonedcrates.dm index cd229550880..db641754240 100644 --- a/code/modules/mining/abandonedcrates.dm +++ b/code/modules/mining/abandonedcrates.dm @@ -22,7 +22,7 @@ switch(loot) if(1 to 5) //5% chance new /obj/item/weapon/reagent_containers/food/drinks/bottle/rum(src) - new /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosiadeus(src) + new /obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus(src) new /obj/item/weapon/reagent_containers/food/drinks/bottle/whiskey(src) new /obj/item/weapon/lighter(src) if(6 to 10) @@ -41,11 +41,9 @@ if(21 to 25) for(var/i in 1 to 5) new /obj/item/weapon/contraband/poster(src) - if(26 to 30) + if(26 to 35) for(var/i in 1 to 3) new /obj/item/weapon/reagent_containers/glass/beaker/noreact(src) - if(31 to 35) - new /obj/item/seeds/cash(src) if(36 to 40) new /obj/item/weapon/melee/baton(src) if(41 to 45) diff --git a/code/modules/mining/equipment_locker.dm b/code/modules/mining/equipment_locker.dm index fb98f3a8c15..712fca9592a 100644 --- a/code/modules/mining/equipment_locker.dm +++ b/code/modules/mining/equipment_locker.dm @@ -727,7 +727,7 @@ ranged = 1 sentience_type = SENTIENCE_MINEBOT ranged_message = "shoots" - ranged_cooldown_cap = 3 + ranged_cooldown_time = 30 projectiletype = /obj/item/projectile/kinetic projectilesound = 'sound/weapons/Gunshot4.ogg' speak_emote = list("states") @@ -737,6 +737,7 @@ healable = 0 var/mode = MINEDRONE_COLLECT var/light_on = 0 + var/mesons_active var/datum/action/innate/minedrone/toggle_light/toggle_light_action var/datum/action/innate/minedrone/toggle_meson_vision/toggle_meson_vision_action @@ -863,6 +864,28 @@ mode = MINEDRONE_COLLECT SetCollectBehavior() + +/mob/living/simple_animal/hostile/mining_drone/update_sight() + if(!client) + return + if(stat == DEAD) + grant_death_vision() + return + + if(mesons_active) + sight |= SEE_TURFS + see_invisible = SEE_INVISIBLE_MINIMUM + else + sight &= ~SEE_TURFS + see_invisible = SEE_INVISIBLE_LIVING + + see_in_dark = initial(see_in_dark) + + if(client.eye != src) + var/atom/A = client.eye + if(A.update_remote_sight(src)) //returns 1 if we override all other sight updates. + return + //Actions for sentient minebots /datum/action/innate/minedrone @@ -889,15 +912,10 @@ /datum/action/innate/minedrone/toggle_meson_vision/Activate() var/mob/living/simple_animal/hostile/mining_drone/user = owner + user.mesons_active = !user.mesons_active + user.update_sight() - if(user.sight & SEE_TURFS) - user.sight &= ~SEE_TURFS - user.see_invisible = SEE_INVISIBLE_LIVING - else - user.sight |= SEE_TURFS - user.see_invisible = SEE_INVISIBLE_MINIMUM - - to_chat(user, "You toggle your meson vision [(user.sight & SEE_TURFS) ? "on" : "off"].") + to_chat(user, "You toggle your meson vision [(user.mesons_active) ? "on" : "off"].") /datum/action/innate/minedrone/toggle_mode name = "Toggle Mode" @@ -960,10 +978,10 @@ name = "minebot cooldown upgrade" /obj/item/device/mine_bot_ugprade/cooldown/upgrade_bot(mob/living/simple_animal/hostile/mining_drone/M, mob/user) - if(M.ranged_cooldown_cap != initial(M.ranged_cooldown_cap)) + if(M.ranged_cooldown_time != initial(M.ranged_cooldown_time)) to_chat(user, "[M] already has a decreased weapon cooldown!") return - M.ranged_cooldown_cap = 1 + M.ranged_cooldown_time = 10 to_chat(user, "You upgrade [M]'s ranged weaponry, reducing its cooldown.") qdel(src) diff --git a/code/modules/mining/lavaland/ash_flora.dm b/code/modules/mining/lavaland/ash_flora.dm new file mode 100644 index 00000000000..922dd34a166 --- /dev/null +++ b/code/modules/mining/lavaland/ash_flora.dm @@ -0,0 +1,205 @@ +/obj/structure/flora/ash + gender = PLURAL + icon = 'icons/obj/lavaland/ash_flora.dmi' + icon_state = "l_mushroom" + name = "large mushrooms" + desc = "A number of large mushrooms, covered in a faint layer of ash and what can only be spores." + var/harvested_name = "shortened mushrooms" + var/harvested_desc = "Some quickly regrowing mushrooms, formerly known to be quite large." + var/needs_sharp_harvest = TRUE + var/harvest = /obj/item/weapon/reagent_containers/food/snacks/ash_flora/shavings + var/harvest_amount_low = 1 + var/harvest_amount_high = 3 + var/harvest_time = 60 + var/harvest_message_low = "You pick a mushroom, but fail to collect many shavings from its cap." + var/harvest_message_med = "You pick a mushroom, carefully collecting the shavings from its cap." + var/harvest_message_high = "You harvest and collect shavings from several mushroom caps." + var/harvested = FALSE + var/base_icon + var/regrowth_time_low = 4800 + var/regrowth_time_high = 8400 + +/obj/structure/flora/ash/New() + ..() + base_icon = "[icon_state][rand(1, 4)]" + icon_state = base_icon + if(prob(15)) + harvest(null, TRUE) + +/obj/structure/flora/ash/proc/harvest(user, no_drop) + if(harvested) + return 0 + if(!no_drop) + var/rand_harvested = rand(harvest_amount_low, harvest_amount_high) + if(rand_harvested) + if(user) + var/msg = harvest_message_med + if(rand_harvested == harvest_amount_low) + msg = harvest_message_low + else if(rand_harvested == harvest_amount_high) + msg = harvest_message_high + to_chat(user, "[msg]") + for(var/i in 1 to rand_harvested) + new harvest(get_turf(src)) + icon_state = "[base_icon]p" + name = harvested_name + desc = harvested_desc + harvested = TRUE + addtimer(src, "regrow", rand(regrowth_time_low, regrowth_time_high)) + return 1 + +/obj/structure/flora/ash/proc/regrow() + icon_state = base_icon + name = initial(name) + desc = initial(desc) + harvested = FALSE + +/obj/structure/flora/ash/attackby(obj/item/weapon/W, mob/user, params) + if(!harvested && needs_sharp_harvest && W.sharp) + user.visible_message("[user] starts to harvest from [src] with [W].","You begin to harvest from [src] with [W].") + if(do_after(user, harvest_time, target = src)) + harvest(user) + else + return ..() + +/obj/structure/flora/ash/attack_hand(mob/user) + if(!harvested && !needs_sharp_harvest) + user.visible_message("[user] starts to harvest from [src].","You begin to harvest from [src].") + if(do_after(user, harvest_time, target = src)) + harvest(user) + else + ..() + +/obj/structure/flora/ash/tall_shroom //exists only so that the spawning check doesn't allow these spawning near other things + regrowth_time_low = 4200 + +/obj/structure/flora/ash/leaf_shroom + icon_state = "s_mushroom" + name = "leafy mushrooms" + desc = "A number of mushrooms, each of which surrounds a greenish sporangium with a number of leaf-like structures." + harvested_name = "leafless mushrooms" + harvested_desc = "A bunch of formerly-leafed mushrooms, with their sporangiums exposed. Scandalous?" + harvest = /obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_leaf + needs_sharp_harvest = FALSE + harvest_amount_high = 4 + harvest_time = 20 + harvest_message_low = "You pluck a single, suitable leaf." + harvest_message_med = "You pluck a number of leaves, leaving a few unsuitable ones." + harvest_message_high = "You pluck quite a lot of suitable leaves." + regrowth_time_low = 2400 + regrowth_time_high = 6000 + +/obj/structure/flora/ash/cap_shroom + icon_state = "r_mushroom" + name = "tall mushrooms" + desc = "Several mushrooms, the larger of which have a ring of conks at the midpoint of their stems." + harvested_name = "small mushrooms" + harvested_desc = "Several small mushrooms near the stumps of what likely were larger mushrooms." + harvest = /obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_cap + harvest_amount_high = 4 + harvest_time = 50 + harvest_message_low = "You slice the cap off of a mushroom." + harvest_message_med = "You slice off a few conks from the larger mushrooms." + harvest_message_high = "You slice off a number of caps and conks from these mushrooms." + regrowth_time_low = 3000 + regrowth_time_high = 5400 + +/obj/structure/flora/ash/stem_shroom + icon_state = "t_mushroom" + name = "numerous mushrooms" + desc = "A large number of mushrooms, some of which have long, fleshy stems. They're radiating light!" + luminosity = 1 + harvested_name = "tiny mushrooms" + harvested_desc = "A few tiny mushrooms around larger stumps. You can already see them growing back." + harvest = /obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_stem + harvest_amount_high = 4 + harvest_time = 40 + harvest_message_low = "You pick and slice the cap off of a mushroom, leaving the stem." + harvest_message_med = "You pick and decapitate several mushrooms for their stems." + harvest_message_high = "You acquire a number of stems from these mushrooms." + regrowth_time_low = 3000 + regrowth_time_high = 6000 + +/obj/structure/flora/ash/cacti + icon_state = "cactus" + name = "fruiting cacti" + desc = "Several prickly cacti, brimming with ripe fruit and covered in a thin layer of ash." + harvested_name = "cacti" + harvested_desc = "A bunch of prickly cacti. You can see fruits slowly growing beneath the covering of ash." + harvest = /obj/item/weapon/reagent_containers/food/snacks/ash_flora/cactus_fruit + needs_sharp_harvest = FALSE + harvest_amount_high = 2 + harvest_time = 10 + harvest_message_low = "You pick a cactus fruit." + harvest_message_med = "You pick several cactus fruit." //shouldn't show up, because you can't get more than two + harvest_message_high = "You pick a pair of cactus fruit." + regrowth_time_low = 4800 + regrowth_time_high = 7200 + +/obj/structure/flora/ash/cacti/Crossed(mob/AM) + if(ishuman(AM) && has_gravity(loc) && prob(70)) + var/mob/living/carbon/human/H = AM + if(!H.shoes && !H.lying) //ouch, my feet. + var/picked_def_zone = pick("l_leg", "r_leg") + var/obj/item/organ/external/affected = H.get_organ(picked_def_zone) + if(!istype(affected)) + return + H.apply_damage(rand(3, 6), BRUTE, picked_def_zone) + H.Weaken(2) + H.visible_message("[H] steps on a cactus!", \ + "You step on a cactus!") + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora + name = "mushroom shavings" + desc = "Some shavings from a tall mushroom. With enough, might serve as a bowl." + icon = 'icons/obj/lavaland/ash_flora.dmi' + icon_state = "mushroom_shavings" + list_reagents = list("sugar" = 3, "ethanol" = 2, "stabilizing_agent" = 3, "minttoxin" = 2) + w_class = 1 + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/New() + ..() + pixel_x = rand(-4, 4) + pixel_y = rand(-4, 4) + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/shavings //for actual crafting + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_leaf + name = "mushroom leaf" + desc = "A leaf, from a mushroom." + list_reagents = list("nutriment" = 3, "vitfro" = 2, "nicotine" = 2) + icon_state = "mushroom_leaf" + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_cap + name = "mushroom cap" + desc = "The cap of a large mushroom." + list_reagents = list("lsd" = 2, "entpoly" = 4, "psilocybin" = 2) + icon_state = "mushroom_cap" + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/mushroom_stem + name = "mushroom stem" + desc = "A long mushroom stem. It's slightly glowing." + list_reagents = list("tinlux" = 2, "vitamin" = 1, "space_drugs" = 1) + icon_state = "mushroom_stem" + luminosity = 1 + +/obj/item/weapon/reagent_containers/food/snacks/ash_flora/cactus_fruit + name = "cactus fruit" + list_reagents = list("vitamin" = 2, "nutriment" = 2, "vitfro" = 4) + desc = "A cactus fruit covered in a thick, reddish skin. And some ash." + icon_state = "cactus_fruit" + +/obj/item/mushroom_bowl + name = "mushroom bowl" + desc = "A bowl made out of mushrooms. Not food, though it might have contained some at some point." + icon = 'icons/obj/lavaland/ash_flora.dmi' + icon_state = "mushroom_bowl" + w_class = 2 + +//what you can craft with these things +/datum/crafting_recipe/mushroom_bowl + name = "Mushroom Bowl" + result = /obj/item/weapon/reagent_containers/food/drinks/mushroom_bowl + reqs = list(/obj/item/weapon/reagent_containers/food/snacks/ash_flora/shavings = 5) + time = 30 + category = CAT_PRIMAL diff --git a/code/modules/mining/lavaland/colossus_loot.dm b/code/modules/mining/lavaland/colossus_loot.dm new file mode 100644 index 00000000000..1928ff0f342 --- /dev/null +++ b/code/modules/mining/lavaland/colossus_loot.dm @@ -0,0 +1,493 @@ +//Black Box + +/obj/machinery/smartfridge/black_box + name = "black box" + desc = "A completely indestructible chunk of crystal, rumoured to predate the start of this universe. It looks like you could store things inside it." + icon = 'icons/obj/lavaland/artefacts.dmi' + icon_state = "blackbox" + icon_on = "blackbox" + icon_off = "blackbox" + luminosity = 8 + max_n_of_items = INFINITY + unacidable = 1 + pixel_y = -4 + use_power = 0 + var/memory_saved = FALSE + var/list/stored_items = list() + var/static/list/blacklist = typecacheof(list(/obj/item/weapon/spellbook)) + +/obj/machinery/smartfridge/black_box/update_icon() + return + +/obj/machinery/smartfridge/black_box/accept_check(obj/item/O) + if(!istype(O)) + return FALSE + if(is_type_in_typecache(O, blacklist)) + return FALSE + return TRUE + +/obj/machinery/smartfridge/black_box/New() + var/static/obj/machinery/smartfridge/black_box/current + if(current && current != src) + qdel(src, force=TRUE) + return + current = src + ReadMemory() + . = ..() + +/obj/machinery/smartfridge/black_box/process() + ..() + if(!memory_saved && ticker.current_state == GAME_STATE_FINISHED) + WriteMemory() + +/obj/machinery/smartfridge/black_box/proc/WriteMemory() + var/savefile/S = new /savefile("data/npc_saves/Blackbox.sav") + stored_items = list() + + for(var/obj/O in (contents-component_parts)) + stored_items += O.type + + S["stored_items"] << stored_items + memory_saved = TRUE + +/obj/machinery/smartfridge/black_box/proc/ReadMemory() + var/savefile/S = new /savefile("data/npc_saves/Blackbox.sav") + S["stored_items"] >> stored_items + + if(isnull(stored_items)) + stored_items = list() + + for(var/item in stored_items) + create_item(item) + +//in it's own proc to avoid issues with items that nolonger exist in the code base. +//try catch doesn't always prevent byond runtimes from halting a proc, +/obj/machinery/smartfridge/black_box/proc/create_item(item_type) + new item_type(src) + +/obj/machinery/smartfridge/black_box/Destroy(force = FALSE) + if(force) + for(var/thing in src) + qdel(thing) + return ..() + else + return QDEL_HINT_LETMELIVE + + +//No taking it apart + +/obj/machinery/smartfridge/black_box/default_deconstruction_screwdriver() + return + +/obj/machinery/smartfridge/black_box/exchange_parts() + return + +/obj/machinery/smartfridge/black_box/default_unfasten_wrench() + return + +/obj/machinery/smartfridge/black_box/default_deconstruction_crowbar() + return + +///Anomolous Crystal/// + +/obj/machinery/anomalous_crystal + name = "anomalous crystal" + desc = "A strange chunk of crystal, being in the presence of it fills you with equal parts excitement and dread." + icon = 'icons/obj/lavaland/artefacts.dmi' + icon_state = "anomaly_crystal" + luminosity = 8 + use_power = 0 + density = 1 + unacidable = 1 + var/activation_method = "touch" + var/activation_damage_type = null + var/last_use_timer = 0 + var/cooldown_add = 30 + var/list/affected_targets = list() + var/activation_sound = 'sound/effects/break_stone.ogg' + +/obj/machinery/anomalous_crystal/New() + activation_method = pick("touch","laser","bullet","energy","bomb","mob_bump","weapon","speech") // "heat" removed due to lack of is_hot() + ..() + +/obj/machinery/anomalous_crystal/hear_talk(mob/speaker, message) + ..() + if(isliving(speaker) && message) + ActivationReaction(speaker, "speech") + +/obj/machinery/anomalous_crystal/attack_hand(mob/user) + ..() + ActivationReaction(user,"touch") + +/obj/machinery/anomalous_crystal/attackby(obj/item/I, mob/user, params) + ActivationReaction(user,"weapon") + ..() + +/obj/machinery/anomalous_crystal/bullet_act(obj/item/projectile/P, def_zone) + ..() + if(istype(P, /obj/item/projectile/magic)) + ActivationReaction(P.firer, "magic", P.damage_type) + return + ActivationReaction(P.firer, P.flag, P.damage_type) + +/obj/machinery/anomalous_crystal/proc/ActivationReaction(mob/user, method, damtype) + if(world.time < last_use_timer) + return 0 + if(activation_damage_type && activation_damage_type != damtype) + return 0 + if(method != activation_method) + return 0 + last_use_timer = (world.time + cooldown_add) + playsound(user, activation_sound, 100, 1) + return 1 + +/obj/machinery/anomalous_crystal/Bumped(atom/AM as mob|obj) + ..() + if(ismob(AM)) + ActivationReaction(AM,"mob_bump") + +/obj/machinery/anomalous_crystal/ex_act() + ActivationReaction(null,"bomb") + +/obj/machinery/anomalous_crystal/random/New()//Just a random crysal spawner for loot + var/random_crystal = pick(typesof(/obj/machinery/anomalous_crystal) - /obj/machinery/anomalous_crystal/random - /obj/machinery/anomalous_crystal) + new random_crystal(loc) + qdel(src) + +/obj/machinery/anomalous_crystal/honk //Strips and equips you as a clown. I apologize for nothing + activation_method = "mob_bump" + activation_sound = 'sound/items/bikehorn.ogg' + +/obj/machinery/anomalous_crystal/honk/ActivationReaction(mob/user) + if(..() && ishuman(user) && !(user in affected_targets)) + var/mob/living/carbon/human/H = user + for(var/obj/item/W in H) + H.unEquip(W) + var/datum/job/clown/C = job_master.GetJob("Clown") + C.equip(H) + affected_targets.Add(H) + +/obj/machinery/anomalous_crystal/honk/New() + ..() + activation_method = pick("mob_bump","speech") + +/obj/machinery/anomalous_crystal/theme_warp //Warps the area you're in to look like a new one + activation_method = "touch" + cooldown_add = 200 + var/terrain_theme = "winter" + var/NewTerrainFloors + var/NewTerrainWalls + var/NewTerrainChairs + var/NewTerrainTables + var/list/NewFlora = list() + var/florachance = 8 + +/obj/machinery/anomalous_crystal/theme_warp/New() + ..() + terrain_theme = pick("lavaland","winter","jungle","alien") + switch(terrain_theme) + if("lavaland")//Depressurizes the place... and free cult metal, I guess. + NewTerrainFloors = /turf/simulated/floor/basalt // Needs to be updated after turf update + NewTerrainWalls = /turf/simulated/wall/cult + NewFlora = list(/mob/living/simple_animal/hostile/asteroid/goldgrub) + florachance = 1 + if("winter") //Snow terrain is slow to move in and cold! Get the assistants to shovel your driveway. + NewTerrainFloors = /turf/simulated/floor/snow // Needs to be updated after turf update + NewTerrainWalls = /turf/simulated/wall/mineral/wood + NewTerrainChairs = /obj/structure/stool/bed/chair/wood/normal + NewTerrainTables = /obj/structure/table/glass + NewFlora = list(/obj/structure/flora/grass/green, /obj/structure/flora/grass/brown, /obj/structure/flora/grass/both) + if("jungle") //Beneficial due to actually having breathable air. Plus, monkeys and bows and arrows. + NewTerrainFloors = /turf/simulated/floor/grass + NewTerrainWalls = /turf/simulated/wall/mineral/sandstone + NewTerrainChairs = /obj/structure/stool/bed/chair/wood/normal + NewTerrainTables = /obj/structure/table/woodentable + NewFlora = list(/obj/structure/flora/ausbushes/sparsegrass, /obj/structure/flora/ausbushes/fernybush, /obj/structure/flora/ausbushes/leafybush, + /obj/structure/flora/ausbushes/grassybush, /obj/structure/flora/ausbushes/sunnybush, /obj/structure/flora/tree/palm, /mob/living/carbon/human/monkey, + /obj/item/weapon/gun/projectile/bow, /obj/item/weapon/storage/backpack/quiver/full) + florachance = 20 + if("alien") //Beneficial, turns stuff into alien alloy which is useful to cargo and research. Also repairs atmos. + NewTerrainFloors = /turf/simulated/floor/mineral/abductor + NewTerrainWalls = /turf/simulated/wall/mineral/abductor + NewTerrainChairs = /obj/structure/stool/bed/abductor //ayys apparently don't have chairs. An entire species of people who only recline. + NewTerrainTables = /obj/structure/table/abductor + +/obj/machinery/anomalous_crystal/theme_warp/ActivationReaction(mob/user, method) + if(..()) + var/area/A = get_area(src) + if(!A.outdoors && !(A in affected_targets)) + for(var/atom/Stuff in A) + if(isturf(Stuff)) + var/turf/T = Stuff + if((isspaceturf(T) || isfloorturf(T)) && NewTerrainFloors) + var/turf/simulated/O = T.ChangeTurf(NewTerrainFloors) + if(O.air) + var/datum/gas_mixture/G = O.air + G.copy_from(O.air) + if(prob(florachance) && NewFlora.len && !is_blocked_turf(O)) + var/atom/Picked = pick(NewFlora) + new Picked(O) + continue + if(iswallturf(T) && NewTerrainWalls) + T.ChangeTurf(NewTerrainWalls) + continue + if(istype(Stuff, /obj/structure/stool/bed/chair) && NewTerrainChairs) + var/obj/structure/stool/bed/chair/Original = Stuff + var/obj/structure/stool/bed/chair/C = new NewTerrainChairs(Original.loc) + C.dir = Original.dir + qdel(Stuff) + continue + if(istype(Stuff, /obj/structure/table) && NewTerrainTables) + var/obj/structure/table/Original = Stuff + var/obj/structure/table/T = new NewTerrainTables(Original.loc) + T.dir = Original.dir + qdel(Stuff) + continue + affected_targets += A + +/obj/machinery/anomalous_crystal/emitter //Generates a projectile when interacted with + activation_method = "touch" + cooldown_add = 50 + var/generated_projectile = /obj/item/projectile/beam/emitter + +/obj/machinery/anomalous_crystal/emitter/New() + ..() + generated_projectile = pick(/obj/item/projectile/magic/fireball/infernal,/obj/item/projectile/magic/spellblade, + /obj/item/projectile/bullet/meteorshot, /obj/item/projectile/beam/xray, /obj/item/projectile/colossus) + +/obj/machinery/anomalous_crystal/emitter/ActivationReaction(mob/user, method) + if(..()) + var/obj/item/projectile/P = new generated_projectile(get_turf(src)) + P.dir = dir + switch(dir) + if(NORTH) + P.yo = 20 + P.xo = 0 + if(EAST) + P.yo = 0 + P.xo = 20 + if(WEST) + P.yo = 0 + P.xo = -20 + else + P.yo = -20 + P.xo = 0 + P.fire() + +/obj/machinery/anomalous_crystal/dark_reprise //Revives anyone nearby, but turns them into shadowpeople and renders them uncloneable, so the crystal is your only hope of getting up again if you go down. + activation_method = "touch" + activation_sound = 'sound/hallucinations/growl1.ogg' + +/obj/machinery/anomalous_crystal/dark_reprise/ActivationReaction(mob/user, method) + if(..()) + for(var/i in range(1, src)) + if(isturf(i)) + new /obj/effect/overlay/temp/cult/sparks(i) + continue + if(ishuman(i)) + var/mob/living/carbon/human/H = i + if(H.stat == DEAD) + H.set_species("Shadow") + H.revive() + H.disabilities |= NOCLONE //Free revives, but significantly limits your options for reviving except via the crystal + H.grab_ghost(force = TRUE) + +/obj/machinery/anomalous_crystal/helpers //Lets ghost spawn as helpful creatures that can only heal people slightly. Incredibly fragile and they can't converse with humans + activation_method = "touch" + var/ready_to_deploy = 0 + +/obj/machinery/anomalous_crystal/helpers/ActivationReaction(mob/user, method) + if(..() && !ready_to_deploy) + ready_to_deploy = 1 + notify_ghosts("An anomalous crystal has been activated in [get_area(src)]! This crystal can always be used by ghosts hereafter.", enter_link = "(Click to enter)", source = src, action = NOTIFY_ATTACK) + +/obj/machinery/anomalous_crystal/helpers/attack_ghost(mob/dead/observer/user) + ..() + if(ready_to_deploy) + var/be_helper = alert("Become a Lightgeist? (Warning, You can no longer be cloned!)",,"Yes","No") + if(be_helper == "No") + return + var/mob/living/simple_animal/hostile/lightgeist/W = new /mob/living/simple_animal/hostile/lightgeist(get_turf(loc)) + W.key = user.key + +/obj/machinery/anomalous_crystal/helpers/Topic(href, href_list) + if(href_list["ghostjoin"]) + var/mob/dead/observer/ghost = usr + if(istype(ghost)) + attack_ghost(ghost) + +/mob/living/simple_animal/hostile/lightgeist + name = "lightgeist" + desc = "This small floating creature is a completely unknown form of life... being near it fills you with a sense of tranquility." + icon_state = "lightgeist" + icon_living = "lightgeist" + icon_dead = "butterfly_dead" + turns_per_move = 1 + response_help = "waves away" + response_disarm = "brushes aside" + response_harm = "disrupts" + speak_emote = list("oscillates") + maxHealth = 2 + health = 2 + harm_intent_damage = 1 + friendly = "mends" + density = 0 + flying = 1 + pass_flags = PASSTABLE | PASSGRILLE | PASSMOB + ventcrawler = 2 + mob_size = MOB_SIZE_TINY + gold_core_spawnable = 0 + speak_emote = list("warps") + damage_coeff = list(BRUTE = 1, BURN = 1, TOX = 0, CLONE = 0, STAMINA = 0, OXY = 0) + luminosity = 4 + faction = list("neutral") + universal_understand = 1 + del_on_death = 1 + unsuitable_atmos_damage = 0 + flying = 1 + minbodytemp = 0 + maxbodytemp = 1500 + environment_smash = 0 + AIStatus = AI_OFF + stop_automated_movement = 1 + var/heal_power = 5 + +/mob/living/simple_animal/hostile/lightgeist/New() + ..() + verbs -= /mob/living/verb/pulled + verbs -= /mob/verb/me_verb + var/datum/atom_hud/medsensor = huds[DATA_HUD_MEDICAL_ADVANCED] + medsensor.add_hud_to(src) + +/mob/living/simple_animal/hostile/lightgeist/AttackingTarget() + ..() + if(isliving(target) && target != src) + var/mob/living/L = target + if(L.stat < DEAD) + L.heal_overall_damage(heal_power, heal_power) + new /obj/effect/overlay/temp/heal(get_turf(target), "#80F5FF") + +/mob/living/simple_animal/hostile/lightgeist/ghostize() + if(..()) + death() + +/obj/machinery/anomalous_crystal/refresher //Deletes and recreates a copy of the item, "refreshing" it. + activation_method = "touch" + cooldown_add = 50 + activation_sound = 'sound/magic/TIMEPARADOX2.ogg' + var/list/banned_items_typecache = list(/obj/item/weapon/storage, /obj/item/weapon/implant, /obj/item/weapon/implanter, /obj/item/weapon/disk/nuclear, /obj/item/projectile, /obj/item/weapon/spellbook) + +/obj/machinery/anomalous_crystal/refresher/New() + ..() + banned_items_typecache = typecacheof(banned_items_typecache) + + +/obj/machinery/anomalous_crystal/refresher/ActivationReaction(mob/user, method) + if(..()) + var/list/L = list() + var/turf/T = get_step(src, dir) + new /obj/effect/overlay/temp/emp/pulse(T) + for(var/i in T) + if(istype(i, /obj/item) && !is_type_in_typecache(i, banned_items_typecache)) + var/obj/item/W = i + if(!W.admin_spawned) + L += W + if(L.len) + var/obj/item/CHOSEN = pick(L) + new CHOSEN.type(T) + qdel(CHOSEN) + +/obj/machinery/anomalous_crystal/possessor //Allows you to bodyjack small animals, then exit them at your leisure, but you can only do this once per activation. Because they blow up. Also, if the bodyjacked animal dies, SO DO YOU. + activation_method = "touch" + +/obj/machinery/anomalous_crystal/possessor/ActivationReaction(mob/user, method) + if(..()) + if(ishuman(user)) + var/mobcheck = 0 + for(var/mob/living/simple_animal/A in range(1, src)) + if(A.melee_damage_upper > 5 || A.mob_size >= MOB_SIZE_LARGE || A.ckey || A.stat) + break + var/obj/structure/closet/stasis/S = new /obj/structure/closet/stasis(A) + user.forceMove(S) + mobcheck = 1 + break + if(!mobcheck) + new /mob/living/simple_animal/cockroach(get_step(src,dir)) //Just in case there aren't any animals on the station, this will leave you with a terrible option to possess if you feel like it + +/obj/structure/closet/stasis + name = "quantum entanglement stasis warp field" + desc = "You can hardly comprehend this thing... which is why you can't see it." + icon_state = null //This shouldn't even be visible, so if it DOES show up, at least nobody will notice + density = 1 + anchored = 1 + var/mob/living/simple_animal/holder_animal + +/obj/structure/closet/stasis/process() + if(holder_animal) + if(holder_animal.stat == DEAD && !qdeleted(holder_animal)) + dump_contents() + holder_animal.gib() + return + +/obj/structure/closet/stasis/New() + ..() + if(isanimal(loc)) + holder_animal = loc + processing_objects.Add(src) + +/obj/structure/closet/stasis/Entered(atom/A) + if(isliving(A) && holder_animal) + var/mob/living/L = A + L.notransform = 1 + L.disabilities |= MUTE + L.status_flags |= GODMODE + L.mind.transfer_to(holder_animal) + var/obj/effect/proc_holder/spell/targeted/exit_possession/P = new /obj/effect/proc_holder/spell/targeted/exit_possession + holder_animal.mind.AddSpell(P) + holder_animal.verbs -= /mob/living/verb/pulled + +/obj/structure/closet/stasis/dump_contents(var/kill = 1) + processing_objects.Remove(src) + for(var/mob/living/L in src) + L.disabilities &= ~MUTE + L.status_flags &= ~GODMODE + L.notransform = 0 + if(holder_animal && !qdeleted(holder_animal)) + holder_animal.mind.transfer_to(L) + L.mind.RemoveSpell(/obj/effect/proc_holder/spell/targeted/exit_possession) + if(kill || !isanimal(loc)) + L.death(0) + ..() + +/obj/structure/closet/stasis/emp_act() + return + +/obj/structure/closet/stasis/ex_act() + return + +/obj/effect/proc_holder/spell/targeted/exit_possession + name = "Exit Possession" + desc = "Exits the body you are possessing" + charge_max = 60 + clothes_req = 0 + invocation_type = "none" + max_targets = 1 + range = -1 + include_user = 1 + selection_type = "view" + action_icon_state = "exit_possession" + sound = null + +/obj/effect/proc_holder/spell/targeted/exit_possession/cast(list/targets, mob/user = usr) + if(!isfloorturf(user.loc)) + return + var/datum/mind/target_mind = user.mind + var/mob/living/current = user // Saving the current mob here to gib as usr seems to get confused after the mind's been transferred, due to delay in transfer_to + for(var/i in user) + if(istype(i, /obj/structure/closet/stasis)) + var/obj/structure/closet/stasis/S = i + S.dump_contents(0) + qdel(S) + break + current.gib() + target_mind.RemoveSpell(/obj/effect/proc_holder/spell/targeted/exit_possession) diff --git a/code/modules/mining/lavaland/necropolis_chests.dm b/code/modules/mining/lavaland/necropolis_chests.dm new file mode 100644 index 00000000000..649a868077d --- /dev/null +++ b/code/modules/mining/lavaland/necropolis_chests.dm @@ -0,0 +1,618 @@ +//The chests dropped by mob spawner tendrils. Also contains associated loot. + +/obj/structure/closet/crate/necropolis + name = "necropolis chest" + desc = "It's watching you closely." + icon_state = "necrocrate" + icon_opened = "necrocrateopen" + icon_closed = "necrocrate" + +/obj/structure/closet/crate/necropolis/tendril + desc = "It's watching you suspiciously." + +/obj/structure/closet/crate/necropolis/tendril/New() + ..() + // uncomment me once these items are being implemented + /*var/loot = rand(1,25) + switch(loot) + if(1) + new /obj/item/device/shared_storage/red(src) + if(2) + new /obj/item/clothing/suit/space/hardsuit/cult(src) + if(3) + new /obj/item/device/soulstone/anybody(src) + if(4) + new /obj/item/weapon/katana/cursed(src) + if(5) + new /obj/item/clothing/glasses/godeye(src) + if(6) + new /obj/item/weapon/reagent_containers/glass/bottle/potion/flight(src) + if(7) + new /obj/item/weapon/pickaxe/diamond(src) + if(8) + new /obj/item/clothing/head/culthood(src) + new /obj/item/clothing/suit/cultrobes(src) + new /obj/item/weapon/bedsheet/cult(src) + if(9) + new /obj/item/organ/brain/alien(src) + if(10) + new /obj/item/organ/heart/cursed(src) + if(11) + new /obj/item/ship_in_a_bottle(src) + if(12) + new /obj/item/clothing/suit/space/hardsuit/ert/paranormal/beserker(src) + if(13) + new /obj/item/weapon/sord(src) + if(14) + new /obj/item/weapon/nullrod/scythe/talking(src) + if(15) + new /obj/item/weapon/nullrod/armblade(src) + if(16) + new /obj/item/weapon/guardiancreator(src) + if(17) + new /obj/item/borg/upgrade/modkit/aoe/turfs/andmobs(src) + if(18) + new /obj/item/device/warp_cube/red(src) + if(19) + new /obj/item/device/wisp_lantern(src) + if(20) + new /obj/item/device/immortality_talisman(src) + if(21) + new /obj/item/weapon/gun/magic/hook(src) + if(22) + new /obj/item/voodoo(src) + if(23) + new /obj/item/weapon/grenade/clusterbuster/inferno(src) + if(24) + new /obj/item/weapon/reagent_containers/food/drinks/bottle/holywater/hell(src) + new /obj/item/clothing/suit/space/hardsuit/ert/paranormal/inquisitor(src) + if(25) + new /obj/item/weapon/spellbook/oneuse/summonitem(src)*/ + +///Bosses + +//Dragon + +/obj/structure/closet/crate/necropolis/dragon + name = "dragon chest" + +/obj/structure/closet/crate/necropolis/dragon/New() + ..() + var/loot = rand(1,4) + switch(loot) + if(1) + new /obj/item/weapon/melee/ghost_sword(src) + if(2) + new /obj/item/weapon/lava_staff(src) + if(3) + new /obj/item/weapon/spellbook/oneuse/sacredflame(src) + new /obj/item/weapon/gun/magic/wand/fireball(src) + if(4) + new /obj/item/weapon/dragons_blood(src) + +/obj/item/weapon/melee/ghost_sword + name = "spectral blade" + desc = "A rusted and dulled blade. It doesn't look like it'd do much damage. It glows weakly." + icon_state = "spectral" + item_state = "spectral" + flags = CONDUCT + sharp = 1 + edge = 1 + w_class = 4 + force = 1 + throwforce = 1 + hitsound = 'sound/effects/ghost2.ogg' + attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "rended") + var/summon_cooldown = 0 + var/list/mob/dead/observer/spirits + +/obj/item/weapon/melee/ghost_sword/New() + ..() + spirits = list() + processing_objects.Add(src) + poi_list |= src + +/obj/item/weapon/melee/ghost_sword/Destroy() + for(var/mob/dead/observer/G in spirits) + G.invisibility = initial(G.invisibility) + spirits.Cut() + processing_objects.Remove(src) + poi_list -= src + . = ..() + +/obj/item/weapon/melee/ghost_sword/attack_self(mob/user) + if(summon_cooldown > world.time) + to_chat(user, "You just recently called out for aid. You don't want to annoy the spirits.") + return + to_chat(user, "You call out for aid, attempting to summon spirits to your side.") + + notify_ghosts("[user] is raising their [src], calling for your help!", enter_link="(Click to help)", source = user, action = NOTIFY_FOLLOW) + + summon_cooldown = world.time + 600 + +/obj/item/weapon/melee/ghost_sword/Topic(href, href_list) + if(href_list["follow"]) + var/mob/dead/observer/ghost = usr + if(istype(ghost)) + ghost.ManualFollow(src) + +/obj/item/weapon/melee/ghost_sword/process() + ghost_check() + +/obj/item/weapon/melee/ghost_sword/proc/ghost_check() + var/ghost_counter = 0 + var/turf/T = get_turf(src) + var/list/contents = T.GetAllContents() + var/mob/dead/observer/current_spirits = list() + + for(var/mob/dead/observer/O in player_list) + if(is_type_in_list(O.following, contents)) + ghost_counter++ + O.invisibility = 0 + current_spirits |= O + + for(var/mob/dead/observer/G in spirits - current_spirits) + G.invisibility = initial(G.invisibility) + + spirits = current_spirits + + return ghost_counter + +/obj/item/weapon/melee/ghost_sword/attack(mob/living/target, mob/living/carbon/human/user) + force = 0 + var/ghost_counter = ghost_check() + + force = Clamp((ghost_counter * 4), 0, 75) + user.visible_message("[user] strikes with the force of [ghost_counter] vengeful spirits!") + ..() + +/obj/item/weapon/melee/ghost_sword/hit_reaction(mob/living/carbon/human/owner, attack_text, final_block_chance, damage, attack_type) + var/ghost_counter = ghost_check() + final_block_chance += Clamp((ghost_counter * 5), 0, 75) + owner.visible_message("[owner] is protected by a ring of [ghost_counter] ghosts!") + return ..() + +// Blood + +/obj/item/weapon/dragons_blood + name = "bottle of dragons blood" + desc = "You're not actually going to drink this, are you?" + icon = 'icons/obj/wizard.dmi' + icon_state = "vial" + +/obj/item/weapon/dragons_blood/attack_self(mob/living/carbon/human/user) + if(!istype(user)) + return + + var/mob/living/carbon/human/H = user + var/random = rand(1,3) + + switch(random) + if(1) + to_chat(user, "Your flesh begins to melt! Miraculously, you seem fine otherwise.") + H.set_species("Skeleton") + if(2) + to_chat(user, "Power courses through you! You can now shift your form at will.") + if(user.mind) + var/obj/effect/proc_holder/spell/targeted/shapeshift/dragon/D = new + user.mind.AddSpell(D) + if(3) + to_chat(user, "You feel like you could walk straight through lava now.") + H.weather_immunities |= "lava" + + playsound(user.loc,'sound/items/drink.ogg', rand(10,50), 1) + qdel(src) + +/datum/disease/transformation/dragon + name = "dragon transformation" + cure_text = "nothing" + cures = list("adminordrazine") + agent = "dragon's blood" + desc = "What do dragons have to do with Space Station 13?" + stage_prob = 20 + severity = BIOHAZARD + visibility_flags = 0 + stage1 = list("Your bones ache.") + stage2 = list("Your skin feels scaley.") + stage3 = list("You have an overwhelming urge to terrorize some peasants.", "Your teeth feel sharper.") + stage4 = list("Your blood burns.") + stage5 = list("You're a fucking dragon. However, any previous allegiances you held still apply. It'd be incredibly rude to eat your still human friends for no reason.") + new_form = /mob/living/simple_animal/hostile/megafauna/dragon/lesser + +//Lava Staff + +/obj/item/weapon/lava_staff + name = "staff of lava" + desc = "The ability to fill the emergency shuttle with lava. What more could you want out of life?" + icon_state = "staffofstorms" + item_state = "staffofstorms" + icon = 'icons/obj/guns/magic.dmi' + slot_flags = SLOT_BACK + item_state = "staffofstorms" + w_class = 4 + force = 25 + damtype = BURN + hitsound = 'sound/weapons/sear.ogg' + var/turf_type = /turf/unsimulated/floor/lava // /turf/simulated/floor/plating/lava/smooth once Lavaland turfs are added + var/transform_string = "lava" + var/reset_turf_type = /turf/simulated/floor/plating/airless/asteroid // /turf/simulated/floor/plating/asteroid/basalt once Lavaland turfs are added + var/reset_string = "basalt" + var/create_cooldown = 100 + var/create_delay = 30 + var/reset_cooldown = 50 + var/timer = 0 + var/banned_turfs + +/obj/item/weapon/lava_staff/New() + . = ..() + banned_turfs = typecacheof(list(/turf/space/transit, /turf/unsimulated)) + +/obj/item/weapon/lava_staff/afterattack(atom/target, mob/user, proximity_flag, click_parameters) + ..() + if(timer > world.time) + return + + if(is_type_in_typecache(target, banned_turfs)) + return + + if(target in view(user.client.view, get_turf(user))) + + var/turf/simulated/T = get_turf(target) + if(!istype(T)) + return + if(!istype(T, turf_type)) + var/obj/effect/overlay/temp/lavastaff/L = new /obj/effect/overlay/temp/lavastaff(T) + L.alpha = 0 + animate(L, alpha = 255, time = create_delay) + user.visible_message("[user] points [src] at [T]!") + timer = world.time + create_delay + 1 + if(do_after(user, create_delay, target = T)) + user.visible_message("[user] turns \the [T] into [transform_string]!") + message_admins("[key_name_admin(user)] fired the lava staff at [get_area(target)] (JMP).") + log_game("[key_name(user)] fired the lava staff at [get_area(target)] ([T.x], [T.y], [T.z]).") + T.ChangeTurf(turf_type) + timer = world.time + create_cooldown + qdel(L) + else + timer = world.time + qdel(L) + return + else + user.visible_message("[user] turns \the [T] into [reset_string]!") + T.ChangeTurf(reset_turf_type) + timer = world.time + reset_cooldown + playsound(T,'sound/magic/Fireball.ogg', 200, 1) + +/obj/effect/overlay/temp/lavastaff + icon_state = "lavastaff_warn" + duration = 50 + +// Bubblegum + +/obj/structure/closet/crate/necropolis/bubblegum + name = "bubblegum chest" + +/obj/structure/closet/crate/necropolis/bubblegum/New() + ..() + var/loot = rand(1,3) + switch(loot) + if(1) + new /obj/item/mayhem(src) + if(2) + new /obj/item/blood_contract(src) + if(3) + new /obj/item/weapon/gun/magic/staff/spellblade(src) + +// Mayhem + +/obj/item/mayhem + name = "mayhem in a bottle" + desc = "A magically infused bottle of blood, the scent of which will drive anyone nearby into a murderous frenzy." + icon = 'icons/obj/wizard.dmi' + icon_state = "vial" + +/obj/item/mayhem/attack_self(mob/user) + for(var/mob/living/carbon/human/H in range(7,user)) + spawn() + var/obj/effect/mine/pickup/bloodbath/B = new(H) + B.mineEffect(H) + to_chat(user, "You shatter the bottle!") + playsound(user.loc, 'sound/effects/Glassbr1.ogg', 100, 1) + qdel(src) + +// Blood Contract + +/obj/item/blood_contract + name = "blood contract" + icon = 'icons/obj/wizard.dmi' + icon_state = "scroll2" + color = "#FF0000" + desc = "Mark your target for death." + var/used = FALSE + +/obj/item/blood_contract/attack_self(mob/user) + if(used) + return + + used = TRUE + var/choice = input(user,"Who do you want dead?","Choose Your Victim") as null|anything in player_list + + if(!choice) + used = FALSE + return + else if(!isliving(choice)) + to_chat(user, "[choice] is already dead!") + used = FALSE + return + else + var/mob/living/L = choice + + message_admins("[key_name_admin(L)] has been marked for death by [key_name_admin(user)].") + log_admin("[key_name(L)] has been marked for death by [key_name(user)].") + + var/datum/objective/survive/survive = new + survive.owner = L.mind + L.mind.objectives += survive + to_chat(L, "You've been marked for death! Don't let the demons get you!") + L.color = "#FF0000" + spawn() + var/obj/effect/mine/pickup/bloodbath/B = new(L) + B.mineEffect(L) + + for(var/mob/living/carbon/human/H in player_list) + if(H == L) + continue + to_chat(H, "You have an overwhelming desire to kill [L]. They have been marked red! Go kill them!") + H.put_in_hands(new /obj/item/weapon/kitchen/knife/butcher(H)) + + qdel(src) + +// Legion + +// Staff of Storms + +/obj/item/weapon/staff/storm + name = "staff of storms" + desc = "An ancient staff retrieved from the remains of Legion. The wind stirs as you move it." + icon_state = "staffofstorms" + item_state = "staffofstorms" + icon = 'icons/obj/guns/magic.dmi' + slot_flags = SLOT_BACK + item_state = "staffofstorms" + w_class = 4 + force = 25 + damtype = BURN + hitsound = 'sound/weapons/sear.ogg' + var/storm_type = /datum/weather/ash_storm + var/storm_cooldown = 0 + +/obj/item/weapon/staff/storm/attack_self(mob/user) + if(storm_cooldown > world.time) + to_chat(user, "The staff is still recharging!") + return + + var/area/user_area = get_area(user) + var/datum/weather/A + var/z_level_name = space_manager.levels_by_name[user.z] + for(var/V in weather_master.existing_weather) + var/datum/weather/W = V + if(W.target_z == z_level_name && W.area_type == user_area.type) + A = W + break + if(A) + + if(A.stage != END_STAGE) + if(A.stage == WIND_DOWN_STAGE) + to_chat(user, "The storm is already ending! It would be a waste to use the staff now.") + return + user.visible_message("[user] holds [src] skywards as an orange beam travels into the sky!", \ + "You hold [src] skyward, dispelling the storm!") + playsound(user, 'sound/magic/Staff_Change.ogg', 200, 0) + A.wind_down() + return + else + A = new storm_type + A.name = "staff storm" + A.area_type = user_area.type + A.target_z = z_level_name + A.telegraph_duration = 100 + A.end_duration = 100 + + user.visible_message("[user] holds [src] skywards as red lightning crackles into the sky!", \ + "You hold [src] skyward, calling down a terrible storm!") + playsound(user, 'sound/magic/Staff_Change.ogg', 200, 0) + A.telegraph() + storm_cooldown = world.time + 200 + +// Hierophant + +//Hierophant + +/obj/item/weapon/hierophant_staff + name = "Hierophant's staff" + desc = "A large club with intense magic power infused into it." + icon_state = "hierophant_staff" + item_state = "hierophant_staff" + icon = 'icons/obj/guns/magic.dmi' + slot_flags = SLOT_BACK + w_class = 4 + force = 20 + hitsound = "swing_hit" + //hitsound = 'sound/weapons/sonic_jackhammer.ogg' + actions_types = list(/datum/action/item_action/vortex_recall, /datum/action/item_action/toggle_unfriendly_fire) + var/cooldown_time = 20 //how long the cooldown between non-melee ranged attacks is + var/chaser_cooldown = 101 //how long the cooldown between firing chasers at mobs is + var/chaser_timer = 0 //what our current chaser cooldown is + var/timer = 0 //what our current cooldown is + var/blast_range = 3 //how long the cardinal blast's walls are + var/obj/effect/hierophant/rune //the associated rune we teleport to + var/teleporting = FALSE //if we ARE teleporting + var/friendly_fire_check = FALSE //if the blasts we make will consider our faction against the faction of hit targets + +/obj/item/weapon/hierophant_staff/afterattack(atom/target, mob/user, proximity_flag, click_parameters) + ..() + var/turf/T = get_turf(target) + if(!T || timer > world.time) + return + timer = world.time + CLICK_CD_MELEE //by default, melee attacks only cause melee blasts, and have an accordingly short cooldown + if(proximity_flag) + spawn(0) + aoe_burst(T, user) + add_logs(user, target, "fired 3x3 blast at", src) + else + if(ismineralturf(target) && get_dist(user, target) < 6) //target is minerals, we can hit it(even if we can't see it) + spawn(0) + cardinal_blasts(T, user) + timer = world.time + cooldown_time + else if(target in view(5, get_turf(user))) //if the target is in view, hit it + timer = world.time + cooldown_time + if(isliving(target) && chaser_timer <= world.time) //living and chasers off cooldown? fire one! + chaser_timer = world.time + chaser_cooldown + new /obj/effect/overlay/temp/hierophant/chaser(get_turf(user), user, target, 1.5, friendly_fire_check) + add_logs(user, target, "fired a chaser at", src) + else + spawn(0) + cardinal_blasts(T, user) //otherwise, just do cardinal blast + add_logs(user, target, "fired cardinal blast at", src) + else + to_chat(user, "That target is out of range!") //too far away + +/obj/item/weapon/hierophant_staff/ui_action_click(mob/user, actiontype) + if(actiontype == /datum/action/item_action/toggle_unfriendly_fire) //toggle friendly fire... + friendly_fire_check = !friendly_fire_check + to_chat(user, "You toggle friendly fire [friendly_fire_check ? "off":"on"]!") + return + if(user.get_active_hand() != src && user.get_inactive_hand() != src) //you need to hold the staff to teleport + to_chat(user, "You need to hold the staff in your hands to [rune ? "teleport with it" : "create a rune"]!") + return + if(!rune) + if(isturf(user.loc)) + user.visible_message("[user] holds [src] carefully in front of them, moving it in a strange pattern...", \ + "You start creating a hierophant rune to teleport to...") + timer = world.time + 51 + if(do_after(user, 50, target = user)) + var/turf/T = get_turf(user) + playsound(T,'sound/magic/Blind.ogg', 200, 1, -4) + new /obj/effect/overlay/temp/hierophant/telegraph/teleport(T, user) + var/obj/effect/hierophant/H = new/obj/effect/hierophant(T) + rune = H + user.update_action_buttons_icon() + user.visible_message("[user] creates a strange rune beneath them!", \ + "You create a hierophant rune, which you can teleport yourself and any allies to at any time!\n\ + You can remove the rune to place a new one by striking it with the staff.") + else + timer = world.time + else + to_chat(user, "You need to be on solid ground to produce a rune!") + return + if(get_dist(user, rune) <= 2) //rune too close abort + to_chat(user, "You are too close to the rune to teleport to it!") + return + if(is_blocked_turf(get_turf(rune))) + to_chat(user, "The rune is blocked by something, preventing teleportation!") + return + teleporting = TRUE //start channel + user.update_action_buttons_icon() + user.visible_message("[user] starts to glow faintly...") + timer = world.time + 50 + if(do_after(user, 40, target = user) && rune) + var/turf/T = get_turf(rune) + var/turf/source = get_turf(user) + if(is_blocked_turf(T)) + teleporting = FALSE + to_chat(user, "The rune is blocked by something, preventing teleportation!") + user.update_action_buttons_icon() + return + new /obj/effect/overlay/temp/hierophant/telegraph(T, user) + new /obj/effect/overlay/temp/hierophant/telegraph(source, user) + playsound(T,'sound/magic/blink.ogg', 200, 1) + //playsound(T,'sound/magic/Wand_Teleport.ogg', 200, 1) + playsound(source,'sound/magic/blink.ogg', 200, 1) + //playsound(source,'sound/machines/AirlockOpen.ogg', 200, 1) + if(!do_after(user, 3, target = user) || !rune) //no walking away shitlord + teleporting = FALSE + if(user) + user.update_action_buttons_icon() + return + if(is_blocked_turf(T)) + teleporting = FALSE + to_chat(user, "The rune is blocked by something, preventing teleportation!") + user.update_action_buttons_icon() + return + add_logs(user, rune, "teleported self from ([source.x],[source.y],[source.z]) to") + new /obj/effect/overlay/temp/hierophant/telegraph/teleport(T, user) + new /obj/effect/overlay/temp/hierophant/telegraph/teleport(source, user) + for(var/t in RANGE_TURFS(1, T)) + var/obj/effect/overlay/temp/hierophant/blast/B = new /obj/effect/overlay/temp/hierophant/blast(t, user, TRUE) //blasts produced will not hurt allies + B.damage = 30 + for(var/t in RANGE_TURFS(1, source)) + var/obj/effect/overlay/temp/hierophant/blast/B = new /obj/effect/overlay/temp/hierophant/blast(t, user, TRUE) //but absolutely will hurt enemies + B.damage = 30 + for(var/mob/living/L in range(1, source)) + spawn(0) + teleport_mob(source, L, T, user) //regardless, take all mobs near us along + sleep(6) //at this point the blasts detonate + else + timer = world.time + teleporting = FALSE + if(user) + user.update_action_buttons_icon() + +/obj/item/weapon/hierophant_staff/proc/teleport_mob(turf/source, mob/M, turf/target, mob/user) + var/turf/turf_to_teleport_to = get_step(target, get_dir(source, M)) //get position relative to caster + if(!turf_to_teleport_to || is_blocked_turf(turf_to_teleport_to)) + return + animate(M, alpha = 0, time = 2, easing = EASE_OUT) //fade out + sleep(1) + if(!M) + return + M.visible_message("[M] fades out!") + sleep(2) + if(!M) + return + M.forceMove(turf_to_teleport_to) + sleep(1) + if(!M) + return + animate(M, alpha = 255, time = 2, easing = EASE_IN) //fade IN + sleep(1) + if(!M) + return + M.visible_message("[M] fades in!") + if(user != M) + add_logs(user, M, "teleported", null, "from ([source.x],[source.y],[source.z])") + +/obj/item/weapon/hierophant_staff/proc/cardinal_blasts(turf/T, mob/living/user) //fire cardinal cross blasts with a delay + if(!T) + return + new /obj/effect/overlay/temp/hierophant/telegraph/cardinal(T, user) + playsound(T,'sound/magic/blink.ogg', 200, 1) + //playsound(T,'sound/effects/bin_close.ogg', 200, 1) + sleep(2) + new /obj/effect/overlay/temp/hierophant/blast(T, user, friendly_fire_check) + for(var/d in cardinal) + spawn(0) + blast_wall(T, d, user) + +/obj/item/weapon/hierophant_staff/proc/blast_wall(turf/T, dir, mob/living/user) //make a wall of blasts blast_range tiles long + if(!T) + return + var/range = blast_range + var/turf/previousturf = T + var/turf/J = get_step(previousturf, dir) + for(var/i in 1 to range) + if(!J) + return + new /obj/effect/overlay/temp/hierophant/blast(J, user, friendly_fire_check) + previousturf = J + J = get_step(previousturf, dir) + +/obj/item/weapon/hierophant_staff/proc/aoe_burst(turf/T, mob/living/user) //make a 3x3 blast around a target + if(!T) + return + new /obj/effect/overlay/temp/hierophant/telegraph(T, user) + playsound(T,'sound/magic/blink.ogg', 200, 1) + //playsound(T,'sound/effects/bin_close.ogg', 200, 1) + sleep(2) + for(var/t in RANGE_TURFS(1, T)) + new /obj/effect/overlay/temp/hierophant/blast(t, user, friendly_fire_check) \ No newline at end of file diff --git a/code/modules/mining/mine_areas.dm b/code/modules/mining/mine_areas.dm index 96ef9d3104b..e07d779c9a8 100644 --- a/code/modules/mining/mine_areas.dm +++ b/code/modules/mining/mine_areas.dm @@ -13,6 +13,7 @@ power_environ = 0 power_equip = 0 power_light = 0 + outdoors = 1 ambientsounds = list('sound/ambience/ambimine.ogg') /area/mine/dangerous/unexplored @@ -25,6 +26,7 @@ power_environ = 0 power_equip = 0 power_light = 0 + outdoors = 1 ambientsounds = list('sound/ambience/ambimine.ogg') /area/mine/lobby diff --git a/code/modules/mining/mine_items.dm b/code/modules/mining/mine_items.dm index 83e794b9d20..6027a0272d8 100644 --- a/code/modules/mining/mine_items.dm +++ b/code/modules/mining/mine_items.dm @@ -2,10 +2,12 @@ //this item is intended to give the effect of entering the mine, so that light gradually fades /obj/effect/light_emitter - name = "Light-emtter" + name = "Light emtter" anchored = 1 + invisibility = 101 unacidable = 1 light_range = 8 + light_power = 0 /**********************Miner Lockers**************************/ @@ -89,7 +91,7 @@ var/excavation_amount = 100 /obj/item/weapon/pickaxe/proc/playDigSound() - playsound(src, pick(digsound),20,1) + playsound(src, pick(digsound),20,1) /obj/item/weapon/pickaxe/silver name = "silver-plated pickaxe" diff --git a/code/modules/mining/ore.dm b/code/modules/mining/ore.dm index ec36988cb20..9e4d268281c 100644 --- a/code/modules/mining/ore.dm +++ b/code/modules/mining/ore.dm @@ -62,6 +62,10 @@ points = 1 refined_type = /obj/item/stack/sheet/glass materials = list(MAT_GLASS=MINERAL_MATERIAL_AMOUNT) + +/obj/item/weapon/ore/glass/basalt + name = "volcanic ash" + icon_state = "volcanic_sand" /obj/item/weapon/ore/glass/attack_self(mob/living/user as mob) to_chat(user, "You use the sand to make sandstone.") diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index 9954b8e12b2..db6ef63ad22 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -226,6 +226,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp if(client.statpanel == "Status") show_stat_station_time() show_stat_emergency_shuttle_eta() + stat(null, "Respawnability: [(src in respawnable_list) ? "Yes" : "No"]") /mob/dead/observer/verb/reenter_corpse() set category = "Ghost" @@ -667,4 +668,4 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp mind.active = 1 mind.transfer_to(new_char) else - new_char.key = key \ No newline at end of file + new_char.key = key diff --git a/code/modules/mob/dead/observer/spells.dm b/code/modules/mob/dead/observer/spells.dm index 39dae4c0746..620c1854e73 100644 --- a/code/modules/mob/dead/observer/spells.dm +++ b/code/modules/mob/dead/observer/spells.dm @@ -25,7 +25,7 @@ var/global/list/boo_phrases=list( invocation_type = "none" range = 1 // Or maybe 3? -/obj/effect/proc_holder/spell/aoe_turf/boo/cast(list/targets) +/obj/effect/proc_holder/spell/aoe_turf/boo/cast(list/targets, mob/user = usr) for(var/turf/T in targets) for(var/atom/A in T.contents) diff --git a/code/modules/mob/living/carbon/alien/alien_defenses.dm b/code/modules/mob/living/carbon/alien/alien_defenses.dm index c6e2bcc510d..c1ce34bf8e7 100644 --- a/code/modules/mob/living/carbon/alien/alien_defenses.dm +++ b/code/modules/mob/living/carbon/alien/alien_defenses.dm @@ -35,7 +35,7 @@ In all, this is a lot like the monkey code. /N visible_message("[M.name] bites [src]!", \ "[M.name] bites [src]!") adjustBruteLoss(damage) - add_logs(M, src, "attacked", admin=0) + add_logs(M, src, "attacked", admin=0, print_attack_log = 0) updatehealth() else to_chat(M, "[name] is too injured for that.") diff --git a/code/modules/mob/living/carbon/alien/larva/larva.dm b/code/modules/mob/living/carbon/alien/larva/larva.dm index c7c8c1cefa8..a78ab9c4c77 100644 --- a/code/modules/mob/living/carbon/alien/larva/larva.dm +++ b/code/modules/mob/living/carbon/alien/larva/larva.dm @@ -116,7 +116,7 @@ "[M] [M.attacktext] [src]!") var/damage = rand(M.melee_damage_lower, M.melee_damage_upper) adjustBruteLoss(damage) - add_logs(M, src, "attacked", admin=0) + add_logs(M, src, "attacked", admin=0, print_attack_log = 0) updatehealth() diff --git a/code/modules/mob/living/carbon/brain/brain.dm b/code/modules/mob/living/carbon/brain/brain.dm index 555fcff29da..e8afbb0360b 100644 --- a/code/modules/mob/living/carbon/brain/brain.dm +++ b/code/modules/mob/living/carbon/brain/brain.dm @@ -10,6 +10,7 @@ /mob/living/carbon/brain/New() create_reagents(330) + add_language("Galactic Common") ..() /mob/living/carbon/brain/Destroy() diff --git a/code/modules/mob/living/carbon/brain/brain_item.dm b/code/modules/mob/living/carbon/brain/brain_item.dm index e3ffe2074a7..064605001dd 100644 --- a/code/modules/mob/living/carbon/brain/brain_item.dm +++ b/code/modules/mob/living/carbon/brain/brain_item.dm @@ -116,12 +116,6 @@ mmi_icon_state = "slime_mmi" // parent_organ = "chest" Hello I am from the ministry of rubber forehead aliens how are you -/obj/item/organ/internal/brain/slime/take_damage(var/amount, var/silent = 1) - //Slimes are 150% more vulnerable to brain damage - damage = between(0, src.damage + (1.5*amount), max_damage) //Since they take the damage twice, this is +150% - return ..() - - /obj/item/organ/internal/brain/golem name = "Runic mind" desc = "A tightly furled roll of paper, covered with indecipherable runes." diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index fed16671887..07ba42b69d7 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -34,12 +34,12 @@ /mob/living/carbon/Move(NewLoc, direct) . = ..() if(.) - if(src.nutrition && src.stat != 2) - src.nutrition -= HUNGER_FACTOR/10 - if(src.m_intent == "run") - src.nutrition -= HUNGER_FACTOR/10 - if((FAT in src.mutations) && src.m_intent == "run" && src.bodytemperature <= 360) - src.bodytemperature += 2 + if(nutrition && stat != DEAD) + nutrition -= hunger_drain / 10 + if(m_intent == "run") + nutrition -= hunger_drain / 10 + if((FAT in mutations) && m_intent == "run" && bodytemperature <= 360) + bodytemperature += 2 // Moving around increases germ_level faster if(germ_level < GERM_LEVEL_MOVE_CAP && prob(8)) @@ -914,14 +914,14 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, /mob/living/carbon/proc/slip(var/description, var/stun, var/weaken, var/tilesSlipped, var/walkSafely, var/slipAny) if(flying || buckled || (walkSafely && m_intent == "walk")) - return + return 0 if((lying) && (!(tilesSlipped))) - return + return 0 if(!(slipAny)) if(istype(src, /mob/living/carbon/human)) var/mob/living/carbon/human/H = src if((isobj(H.shoes) && H.shoes.flags & NOSLIP) || H.species.bodyflags & FEET_NOSLIP) - return + return 0 if(tilesSlipped) for(var/t = 0, t<=tilesSlipped, t++) spawn (t) step(src, src.dir) @@ -939,9 +939,10 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, /mob/living/carbon/proc/eat(var/obj/item/weapon/reagent_containers/food/toEat, mob/user) if(!istype(toEat)) return 0 - var/fullness = 0 + var/fullness = nutrition + 10 if(istype(toEat, /obj/item/weapon/reagent_containers/food/snacks)) - fullness = nutrition + (reagents.get_reagent_amount("nutriment") * 20) + (reagents.get_reagent_amount("protein") * 25) + (reagents.get_reagent_amount("plantmatter") * 25) + for(var/datum/reagent/consumable/C in reagents.reagent_list) //we add the nutrition value of what we're currently digesting + fullness += C.nutriment_factor * C.volume / (C.metabolization_rate * metabolism_efficiency * digestion_ratio) if(user == src) if(istype(toEat, /obj/item/weapon/reagent_containers/food/drinks)) if(!selfDrink(toEat)) @@ -957,18 +958,21 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, return 1 /mob/living/carbon/proc/selfFeed(var/obj/item/weapon/reagent_containers/food/toEat, fullness) - if(istype(toEat, /obj/item/weapon/reagent_containers/food/pill)) + if(ispill(toEat)) to_chat(src, "You [toEat.apply_method] [toEat].") else + if(toEat.junkiness && satiety < -150 && nutrition > NUTRITION_LEVEL_STARVING + 50 ) + to_chat(src, "You don't feel like eating any more junk food at the moment.") + return 0 if(fullness <= 50) to_chat(src, "You hungrily chew out a piece of [toEat] and gobble it!") - else if(fullness > 50 && fullness <= 150) + else if(fullness > 50 && fullness < 150) to_chat(src, "You hungrily begin to eat [toEat].") - else if(fullness > 150 && fullness <= 350) + else if(fullness > 150 && fullness < 500) to_chat(src, "You take a bite of [toEat].") - else if(fullness > 350 && fullness <= 550) + else if(fullness > 500 && fullness < 600) to_chat(src, "You unwillingly chew a bit of [toEat].") - else if(fullness > (550 * (1 + overeatduration / 2000))) // The more you eat - the more you can eat + else if(fullness > (600 * (1 + overeatduration / 2000))) // The more you eat - the more you can eat to_chat(src, "You cannot force any more of [toEat] to go down your throat.") return 0 return 1 @@ -977,7 +981,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, return 1 /mob/living/carbon/proc/forceFed(var/obj/item/weapon/reagent_containers/food/toEat, mob/user, fullness) - if(fullness <= (550 * (1 + overeatduration / 1000))) + if(ispill(toEat) || fullness <= (600 * (1 + overeatduration / 1000))) if(!toEat.instant_application) visible_message("[user] attempts to force [src] to [toEat.apply_method] [toEat].") else @@ -991,8 +995,8 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, return 1 /mob/living/carbon/proc/forceFedAttackLog(var/obj/item/weapon/reagent_containers/food/toEat, mob/user) - attack_log += text("\[[time_stamp()]\] Has been fed [toEat.name] by [user.name] ([user.ckey]) Reagents: [toEat.reagentlist(toEat)]") - user.attack_log += text("\[[time_stamp()]\] Fed [toEat.name] to [name] ([ckey]) Reagents: [toEat.reagentlist(toEat)]") + create_attack_log("Has been fed [toEat.name] by [user.name] ([user.ckey]) Reagents: [toEat.reagentlist(toEat)]") + user.create_attack_log("Fed [toEat.name] to [name] ([ckey]) Reagents: [toEat.reagentlist(toEat)]") log_attack("[user.name] ([user.ckey]) fed [name] ([ckey]) with [toEat.name] Reagents: [toEat.reagentlist(toEat)] (INTENT: [uppertext(user.a_intent)])") if(!iscarbon(user)) LAssailant = null @@ -1005,15 +1009,14 @@ so that different stomachs can handle things in different ways VB*/ /mob/living/carbon/proc/consume(var/obj/item/weapon/reagent_containers/food/toEat) if(!toEat.reagents) return + if(satiety > -200) + satiety -= toEat.junkiness if(toEat.consume_sound) playsound(loc, toEat.consume_sound, rand(10,50), 1) if(toEat.reagents.total_volume) - toEat.reagents.reaction(src, toEat.apply_type) - spawn(0) - if(toEat.reagents.total_volume > toEat.bitesize) - toEat.reagents.trans_to(src, toEat.bitesize*toEat.transfer_efficiency) - else - toEat.reagents.trans_to(src, toEat.reagents.total_volume*toEat.transfer_efficiency) + var/fraction = min(toEat.bitesize/toEat.reagents.total_volume, 1) + toEat.reagents.reaction(src, toEat.apply_type, fraction) + toEat.reagents.trans_to(src, toEat.bitesize*toEat.transfer_efficiency) /mob/living/carbon/get_access() . = ..() diff --git a/code/modules/mob/living/carbon/carbon_defenses.dm b/code/modules/mob/living/carbon/carbon_defenses.dm index efebc58ffc1..b2dcf20f1b2 100644 --- a/code/modules/mob/living/carbon/carbon_defenses.dm +++ b/code/modules/mob/living/carbon/carbon_defenses.dm @@ -36,4 +36,4 @@ for(var/datum/disease/D in user.viruses) if(D.IsSpreadByTouch()) ContractDisease(D) - return 0 + return 0 \ No newline at end of file diff --git a/code/modules/mob/living/carbon/human/emote.dm b/code/modules/mob/living/carbon/human/emote.dm index 558a6f8e9de..f9315966d27 100644 --- a/code/modules/mob/living/carbon/human/emote.dm +++ b/code/modules/mob/living/carbon/human/emote.dm @@ -83,12 +83,12 @@ message = "[src] pings at [param]." else message = "[src] pings." - playsound(src.loc, 'sound/machines/ping.ogg', 50, 0) + playsound(loc, 'sound/machines/ping.ogg', 50, 0) m_type = 2 if("buzz2") message = "[src] emits an irritated buzzing sound." - playsound(src.loc, 'sound/machines/buzz-two.ogg', 50, 0) + playsound(loc, 'sound/machines/buzz-two.ogg', 50, 0) m_type = 2 if("buzz", "buzzes") @@ -105,7 +105,7 @@ message = "[src] buzzes at [param]." else message = "[src] buzzes." - playsound(src.loc, 'sound/machines/buzz-sigh.ogg', 50, 0) + playsound(loc, 'sound/machines/buzz-sigh.ogg', 50, 0) m_type = 2 if("beep", "beeps") @@ -122,7 +122,7 @@ message = "[src] beeps at [param]." else message = "[src] beeps." - playsound(src.loc, 'sound/machines/twobeep.ogg', 50, 0) + playsound(loc, 'sound/machines/twobeep.ogg', 50, 0) m_type = 2 if("drone", "drones", "hum", "hums", "rumble", "rumbles") @@ -139,7 +139,7 @@ message = "[src] drones at [param]." else message = "[src] rumbles." - playsound(src.loc, 'sound/voice/DraskTalk.ogg', 50, 0) + playsound(loc, 'sound/voice/DraskTalk.ogg', 50, 0) m_type = 2 if("squish", "squishes") @@ -156,7 +156,7 @@ message = "[src] squishes at [param]." else message = "[src] squishes." - playsound(src.loc, 'sound/effects/slime_squish.ogg', 50, 0) //Credit to DrMinky (freesound.org) for the sound. + playsound(loc, 'sound/effects/slime_squish.ogg', 50, 0) //Credit to DrMinky (freesound.org) for the sound. m_type = 2 if("yes") @@ -173,7 +173,7 @@ message = "[src] emits an affirmative blip at [param]." else message = "[src] emits an affirmative blip." - playsound(src.loc, 'sound/machines/synth_yes.ogg', 50, 0) + playsound(loc, 'sound/machines/synth_yes.ogg', 50, 0) m_type = 2 if("no") @@ -190,7 +190,7 @@ message = "[src] emits a negative blip at [param]." else message = "[src] emits a negative blip." - playsound(src.loc, 'sound/machines/synth_no.ogg', 50, 0) + playsound(loc, 'sound/machines/synth_no.ogg', 50, 0) m_type = 2 if("wag", "wags") @@ -202,7 +202,7 @@ else if(species.bodyflags & TAIL_WAGGING) if(!wear_suit || !(wear_suit.flags_inv & HIDETAIL) && !istype(wear_suit, /obj/item/clothing/suit/space)) message = "[src] starts wagging \his tail." - src.start_tail_wagging(1) + start_tail_wagging(1) else return else @@ -212,15 +212,25 @@ if("swag", "swags") if(species.bodyflags & TAIL_WAGGING || body_accessory) message = "[src] stops wagging \his tail." - src.stop_tail_wagging(1) + stop_tail_wagging(1) else return m_type = 1 if("airguitar") - if(!src.restrained()) + if(!restrained()) message = "[src] is strumming the air and headbanging like a safari chimp." m_type = 1 + + if("dance") + if(!restrained()) + message = "[src] dances around happily." + m_type = 1 + + if("jump") + if(!restrained()) + message = "[src] jumps!" + m_type = 1 if("blink", "blinks") message = "[src] blinks." @@ -231,7 +241,7 @@ m_type = 1 if("bow", "bows") - if(!src.buckled) + if(!buckled) var/M = null if(param) for(var/mob/A in view(null, null)) @@ -248,7 +258,7 @@ m_type = 1 if("salute", "salutes") - if(!src.buckled) + if(!buckled) var/M = null if(param) for(var/mob/A in view(null, null)) @@ -288,13 +298,13 @@ message = "[src] makes a peculiar noise." m_type = 2 if("clap", "claps") - if(!src.restrained()) + if(!restrained()) message = "[src] claps." m_type = 2 if(miming) m_type = 1 if("flap", "flaps") - if(!src.restrained()) + if(!restrained()) message = "[src] flaps \his wings." m_type = 2 if(miming) @@ -302,7 +312,7 @@ if("flip", "flips") m_type = 1 - if(!src.restrained()) + if(!restrained()) var/M = null if(param) for(var/mob/A in view(1, null)) @@ -340,7 +350,7 @@ SpinAnimation(5,1) if("aflap", "aflaps") - if(!src.restrained()) + if(!restrained()) message = "[src] flaps \his wings ANGRILY!" m_type = 2 if(miming) @@ -376,7 +386,7 @@ if("faint", "faints") message = "[src] faints." - if(src.sleeping) + if(sleeping) return //Can't faint while asleep AdjustSleeping(2) m_type = 1 @@ -578,11 +588,11 @@ message = "[src] takes a drag from a cigarette and blows \"[M]\" out in smoke." m_type = 1 else - message = "[src] says, \"[M], please. They had a family.\" [src.name] takes a drag from a cigarette and blows their name out in smoke." + message = "[src] says, \"[M], please. They had a family.\" [name] takes a drag from a cigarette and blows their name out in smoke." m_type = 2 if("point", "points") - if(!src.restrained()) + if(!restrained()) var/atom/M = null if(param) for(var/atom/A as mob|obj|turf in view()) @@ -597,7 +607,7 @@ m_type = 1 if("raise", "raises") - if(!src.restrained()) + if(!restrained()) message = "[src] raises a hand." m_type = 1 @@ -610,12 +620,12 @@ m_type = 1 if("signal", "signals") - if(!src.restrained()) + if(!restrained()) var/t1 = round(text2num(param)) if(isnum(t1)) - if(t1 <= 5 && (!src.r_hand || !src.l_hand)) + if(t1 <= 5 && (!r_hand || !l_hand)) message = "[src] raises [t1] finger\s." - else if(t1 <= 10 && (!src.r_hand && !src.l_hand)) + else if(t1 <= 10 && (!r_hand && !l_hand)) message = "[src] raises [t1] finger\s." m_type = 1 @@ -699,7 +709,7 @@ if("hug", "hugs") m_type = 1 - if(!src.restrained()) + if(!restrained()) var/M = null if(param) for(var/mob/A in view(1, null)) @@ -716,7 +726,7 @@ if("handshake") m_type = 1 - if(!src.restrained() && !src.r_hand) + if(!restrained() && !r_hand) var/mob/M = null if(param) for(var/mob/A in view(1, null)) @@ -734,7 +744,7 @@ if("dap", "daps") m_type = 1 - if(!src.restrained()) + if(!restrained()) var/M = null if(param) for(var/mob/A in view(1, null)) @@ -748,7 +758,7 @@ if("slap", "slaps") m_type = 1 - if(!src.restrained()) + if(!restrained()) var/M = null if(param) for(var/mob/A in view(1, null)) @@ -757,11 +767,11 @@ break if(M) message = "[src] slaps [M] across the face. Ouch!" - playsound(src.loc, 'sound/effects/snap.ogg', 50, 1) + playsound(loc, 'sound/effects/snap.ogg', 50, 1) else message = "[src] slaps \himself!" - playsound(src.loc, 'sound/effects/snap.ogg', 50, 1) - src.adjustFireLoss(4) + playsound(loc, 'sound/effects/snap.ogg', 50, 1) + adjustFireLoss(4) if("scream", "screams") if(miming) @@ -772,9 +782,9 @@ message = "[src] [species.scream_verb]!" m_type = 2 if(gender == FEMALE) - playsound(src.loc, "[species.female_scream_sound]", 80, 1, 0, pitch = get_age_pitch()) + playsound(loc, "[species.female_scream_sound]", 80, 1, 0, pitch = get_age_pitch()) else - playsound(src.loc, "[species.male_scream_sound]", 80, 1, 0, pitch = get_age_pitch()) //default to male screams if no gender is present. + playsound(loc, "[species.male_scream_sound]", 80, 1, 0, pitch = get_age_pitch()) //default to male screams if no gender is present. else message = "[src] makes a very loud noise." @@ -799,24 +809,24 @@ return message = "[src] snaps \his fingers." - playsound(src.loc, 'sound/effects/fingersnap.ogg', 50, 1, -3) + playsound(loc, 'sound/effects/fingersnap.ogg', 50, 1, -3) else message = "[src] snaps \his fingers right off!" - playsound(src.loc, 'sound/effects/snap.ogg', 50, 1) + playsound(loc, 'sound/effects/snap.ogg', 50, 1) // Needed for M_TOXIC_FART if("fart", "farts") if(reagents.has_reagent("simethicone")) return -// playsound(src.loc, 'sound/effects/fart.ogg', 50, 1, -3) //Admins still vote no to fun +// playsound(loc, 'sound/effects/fart.ogg', 50, 1, -3) //Admins still vote no to fun if(locate(/obj/item/weapon/storage/bible) in get_turf(src)) to_chat(viewers(src), "[src] farts on the Bible!") to_chat(viewers(src), "A mysterious force smites [src]!") var/datum/effect/system/spark_spread/s = new /datum/effect/system/spark_spread s.set_up(3, 1, src) s.start() - src.gib() + gib() else if(TOXIC_FARTS in mutations) message = "[src] unleashes a [pick("horrible","terrible","foul","disgusting","awful")] fart." else if(SUPER_FART in mutations) @@ -841,9 +851,9 @@ M.reagents.add_reagent("jenkem", 1) if("help") - var/emotelist = "aflap(s), airguitar, blink(s), blink(s)_r, blush(es), bow(s)-(none)/mob, burp(s), choke(s), chuckle(s), clap(s), collapse(s), cough(s),cry, cries, custom, dap(s)(none)/mob," \ - + " deathgasp(s), drool(s), eyebrow,fart(s), faint(s), flap(s), flip(s), frown(s), gasp(s), giggle(s), glare(s)-(none)/mob, grin(s), groan(s), grumble(s), handshake-mob, hug(s)-(none)/mob," \ - + " glare(s)-(none)/mob, grin(s), johnny, laugh(s), look(s)-(none)/mob, moan(s), mumble(s), nod(s), pale(s), point(s)-atom, quiver(s), raise(s), salute(s)-(none)/mob, scream(s), shake(s)," \ + var/emotelist = "aflap(s), airguitar, blink(s), blink(s)_r, blush(es), bow(s)-(none)/mob, burp(s), choke(s), chuckle(s), clap(s), collapse(s), cough(s),cry, cries, custom, dance, dap(s)(none)/mob," \ + + " deathgasp(s), drool(s), eyebrow, fart(s), faint(s), flap(s), flip(s), frown(s), gasp(s), giggle(s), glare(s)-(none)/mob, grin(s), groan(s), grumble(s), grin(s)," \ + + " handshake-mob, hug(s)-(none)/mob, johnny, jump, laugh(s), look(s)-(none)/mob, moan(s), mumble(s), nod(s), pale(s), point(s)-atom, quiver(s), raise(s), salute(s)-(none)/mob, scream(s), shake(s)," \ + " shiver(s), shrug(s), sigh(s), signal(s)-#1-10,slap(s)-(none)/mob, smile(s),snap(s), sneeze(s), sniff(s), snore(s), stare(s)-(none)/mob, swag(s), tremble(s), twitch(es), twitch(es)_s," \ + " wag(s), wave(s), whimper(s), wink(s), yawn(s)" if(species.name == "Machine") diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index ff7622731d6..453402ec7e3 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -253,10 +253,10 @@ if(5) msg += "[t_He] looks absolutely soaked.\n" - if(nutrition < 100) + if(nutrition < NUTRITION_LEVEL_STARVING - 50) msg += "[t_He] [t_is] severely malnourished.\n" - else if(nutrition >= 500) - if(user.nutrition < 100) + else if(nutrition >= NUTRITION_LEVEL_FAT) + if(user.nutrition < NUTRITION_LEVEL_STARVING - 50) msg += "[t_He] [t_is] plump and delicious looking - Like a fat little piggy. A tasty piggy.\n" else msg += "[t_He] [t_is] quite chubby.\n" @@ -516,7 +516,7 @@ return istype(H.glasses, /obj/item/clothing/glasses/hud/health) || istype(H.glasses, /obj/item/clothing/glasses/hud/health/health_advanced) || istype(CIH,/obj/item/organ/internal/cyberimp/eyes/hud/medical) else return 0 - else if(istype(M, /mob/living/silicon)) + else if(isrobot(M) || isAI(M)) //Stand-in/Stopgap to prevent pAIs from freely altering records, pending a more advanced Records system switch(hudtype) if("security") return 1 diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index cd0e9d751c9..ae88df869d9 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -805,10 +805,12 @@ unEquip(pocket_item) if(thief_mode) usr.put_in_hands(pocket_item) + add_logs(usr, src, "stripped", addition="of [pocket_item]", print_attack_log = isLivingSSD(src)) else if(place_item) usr.unEquip(place_item) equip_to_slot_if_possible(place_item, pocket_id, 0, 1) + add_logs(usr, src, "equipped", addition="with [pocket_item]", print_attack_log = isLivingSSD(src)) // Update strip window if(usr.machine == src && in_range(src, usr)) @@ -817,6 +819,7 @@ // Display a warning if the user mocks up if they don't have pickpocket gloves. if(!thief_mode) to_chat(src, "You feel your [pocket_side] pocket being fumbled with!") + add_logs(usr, src, "attempted to strip", addition="of [pocket_item]", print_attack_log = isLivingSSD(src)) if(href_list["set_sensor"]) if(istype(w_uniform, /obj/item/clothing/under)) @@ -1536,6 +1539,9 @@ else see_invisible = SEE_INVISIBLE_LIVING + hunger_drain = species.hunger_drain + digestion_ratio = species.digestion_ratio + if(species.base_color && default_colour) //Apply colour. r_skin = color2R(species.base_color) diff --git a/code/modules/mob/living/carbon/human/human_attackhand.dm b/code/modules/mob/living/carbon/human/human_attackhand.dm index cea8c962af7..a8e075f2433 100644 --- a/code/modules/mob/living/carbon/human/human_attackhand.dm +++ b/code/modules/mob/living/carbon/human/human_attackhand.dm @@ -182,8 +182,8 @@ apply_effect(2, WEAKEN, run_armor_check(affecting, "melee")) playsound(loc, 'sound/weapons/thudswoosh.ogg', 50, 1, -1) visible_message("[M] has pushed [src]!") - M.attack_log += text("\[[time_stamp()]\] Pushed [src.name] ([src.ckey])") - src.attack_log += text("\[[time_stamp()]\] Has been pushed by [M.name] ([M.ckey])") + M.create_attack_log("Pushed [src.name] ([src.ckey])") + src.create_attack_log("Has been pushed by [M.name] ([M.ckey])") if(!iscarbon(M)) LAssailant = null else diff --git a/code/modules/mob/living/carbon/human/human_damage.dm b/code/modules/mob/living/carbon/human/human_damage.dm index 0e2e95bc778..4cf009ec44f 100644 --- a/code/modules/mob/living/carbon/human/human_damage.dm +++ b/code/modules/mob/living/carbon/human/human_damage.dm @@ -28,13 +28,15 @@ med_hud_set_status() handle_hud_icons() -/mob/living/carbon/human/adjustBrainLoss(var/amount) +/mob/living/carbon/human/adjustBrainLoss(amount) if(status_flags & GODMODE) return 0 //godmode if(species && species.has_organ["brain"]) var/obj/item/organ/internal/brain/sponge = get_int_organ(/obj/item/organ/internal/brain) if(sponge) + if(species) + amount = amount * species.brain_mod sponge.take_damage(amount, 1) brainloss = sponge.damage else @@ -42,14 +44,16 @@ else brainloss = 0 -/mob/living/carbon/human/setBrainLoss(var/amount) +/mob/living/carbon/human/setBrainLoss(amount) if(status_flags & GODMODE) return 0 //godmode if(species && species.has_organ["brain"]) var/obj/item/organ/internal/brain/sponge = get_int_organ(/obj/item/organ/internal/brain) if(sponge) - sponge.damage = min(max(amount, 0),(maxHealth*2)) + if(species) + amount = amount * species.brain_mod + sponge.damage = min(max(amount, 0), (maxHealth*2)) brainloss = sponge.damage else brainloss = 200 @@ -84,25 +88,25 @@ return amount -/mob/living/carbon/human/adjustBruteLoss(var/amount) - if(species && species.brute_mod) - amount = amount*species.brute_mod +/mob/living/carbon/human/adjustBruteLoss(amount) + if(species) + amount = amount * species.brute_mod if(amount > 0) take_overall_damage(amount, 0) else heal_overall_damage(-amount, 0) -/mob/living/carbon/human/adjustFireLoss(var/amount) - if(species && species.burn_mod) - amount = amount*species.burn_mod +/mob/living/carbon/human/adjustFireLoss(amount) + if(species) + amount = amount * species.burn_mod if(amount > 0) take_overall_damage(0, amount) else heal_overall_damage(0, -amount) -/mob/living/carbon/human/proc/adjustBruteLossByPart(var/amount, var/organ_name, var/obj/damage_source = null) - if(species && species.brute_mod) - amount = amount*species.brute_mod +/mob/living/carbon/human/proc/adjustBruteLossByPart(amount, organ_name, obj/damage_source = null) + if(species) + amount = amount * species.brute_mod if(organ_name in organs_by_name) var/obj/item/organ/external/O = get_organ(organ_name) @@ -114,9 +118,9 @@ O.heal_damage(-amount, 0, internal=0, robo_repair=(O.status & ORGAN_ROBOT)) -/mob/living/carbon/human/proc/adjustFireLossByPart(var/amount, var/organ_name, var/obj/damage_source = null) - if(species && species.burn_mod) - amount = amount*species.burn_mod +/mob/living/carbon/human/proc/adjustFireLossByPart(amount, organ_name, obj/damage_source = null) + if(species) + amount = amount * species.burn_mod if(organ_name in organs_by_name) var/obj/item/organ/external/O = get_organ(organ_name) @@ -134,13 +138,11 @@ wearing_rig.notify_ai("Warning: user consciousness failure. Mobility control passed to integrated intelligence system.") ..() -/mob/living/carbon/human/adjustCloneLoss(var/amount) +/mob/living/carbon/human/adjustCloneLoss(amount) + if(species) + amount = amount * species.clone_mod ..() - if(species.flags & (NO_DNA)) - cloneloss = 0 - return - var/heal_prob = max(0, 80 - getCloneLoss()) var/mut_prob = min(80, getCloneLoss() + 10) if(amount > 0) //cloneloss is being added @@ -176,44 +178,30 @@ // Defined here solely to take species flags into account without having to recast at mob/living level. -/mob/living/carbon/human/getOxyLoss() - if(species.flags & NO_BREATHE) - oxyloss = 0 - return ..() +/mob/living/carbon/human/adjustOxyLoss(amount) + if(species) + amount = amount * species.oxy_mod + ..() -/mob/living/carbon/human/adjustOxyLoss(var/amount) - if(species.flags & NO_BREATHE) - oxyloss = 0 - else - ..() +/mob/living/carbon/human/setOxyLoss(amount) + if(species) + amount = amount * species.oxy_mod + ..() -/mob/living/carbon/human/setOxyLoss(var/amount) - if(species.flags & NO_BREATHE) - oxyloss = 0 //this literally overrides three procs, excessive much? - else - ..() +/mob/living/carbon/human/adjustToxLoss(amount) + if(species) + amount = amount * species.tox_mod + ..() -/mob/living/carbon/human/getToxLoss() - if(species.flags & NO_POISON) - toxloss = 0 - return ..() - -/mob/living/carbon/human/adjustToxLoss(var/amount) - if(species.flags & NO_POISON) - toxloss = 0 - else - ..() - -/mob/living/carbon/human/setToxLoss(var/amount) - if(species.flags & NO_POISON) - toxloss = 0 //this *also* overrides three procs, definately excessive - else - ..() +/mob/living/carbon/human/setToxLoss(amount) + if(species) + amount = amount * species.tox_mod + ..() //////////////////////////////////////////// //Returns a list of damaged organs -/mob/living/carbon/human/proc/get_damaged_organs(var/brute, var/burn, var/flags = AFFECT_ALL_ORGANS) +/mob/living/carbon/human/proc/get_damaged_organs(brute, burn, flags = AFFECT_ALL_ORGANS) var/list/obj/item/organ/external/parts = list() for(var/obj/item/organ/external/O in organs) if((brute && O.brute_dam) || (burn && O.burn_dam)) @@ -235,7 +223,7 @@ //Heals ONE external organ, organ gets randomly selected from damaged ones. //It automatically updates damage overlays if necesary //It automatically updates health status -/mob/living/carbon/human/heal_organ_damage(var/brute, var/burn) +/mob/living/carbon/human/heal_organ_damage(brute, burn) var/list/obj/item/organ/external/parts = get_damaged_organs(brute,burn) if(!parts.len) return @@ -247,7 +235,7 @@ //Damages ONE external organ, organ gets randomly selected from damagable ones. //It automatically updates damage overlays if necesary //It automatically updates health status -/mob/living/carbon/human/take_organ_damage(var/brute, var/burn, var/sharp = 0, var/edge = 0) +/mob/living/carbon/human/take_organ_damage(brute, burn, sharp = 0, edge = 0) var/list/obj/item/organ/external/parts = get_damageable_organs() if(!parts.len) return @@ -259,7 +247,7 @@ //Heal MANY external organs, in random order -/mob/living/carbon/human/heal_overall_damage(var/brute, var/burn, var/internal=0, var/robotic=0) +/mob/living/carbon/human/heal_overall_damage(brute, burn, internal=0, robotic=0) var/list/obj/item/organ/external/parts = get_damaged_organs(brute,burn) var/update = 0 @@ -282,7 +270,7 @@ UpdateDamageIcon() // damage MANY external organs, in random order -/mob/living/carbon/human/take_overall_damage(var/brute, var/burn, var/sharp = 0, var/edge = 0, var/used_weapon = null) +/mob/living/carbon/human/take_overall_damage(brute, burn, sharp = 0, edge = 0, used_weapon = null) if(status_flags & GODMODE) return //godmode var/list/obj/item/organ/external/parts = get_damageable_organs() @@ -337,7 +325,7 @@ This function restores all organs. return 0 -/mob/living/carbon/human/proc/get_organ(var/zone) +/mob/living/carbon/human/proc/get_organ(zone) if(!zone) zone = "chest" if(zone in list("eyes", "mouth")) @@ -345,7 +333,7 @@ This function restores all organs. return organs_by_name[zone] -/mob/living/carbon/human/apply_damage(var/damage = 0, var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0, var/sharp = 0, var/edge = 0, var/obj/used_weapon = null) +/mob/living/carbon/human/apply_damage(damage = 0, damagetype = BRUTE, def_zone = null, blocked = 0, sharp = 0, edge = 0, obj/used_weapon = null) //Handle other types of damage if((damagetype != BRUTE) && (damagetype != BURN)) ..(damage, damagetype, def_zone, blocked) @@ -373,7 +361,7 @@ This function restores all organs. switch(damagetype) if(BRUTE) damageoverlaytemp = 20 - if(species && species.brute_mod) + if(species) damage = damage * species.brute_mod if(organ.take_damage(damage, 0, sharp, edge, used_weapon)) @@ -398,7 +386,7 @@ This function restores all organs. if(BURN) damageoverlaytemp = 20 - if(species && species.burn_mod) + if(species) damage = damage * species.burn_mod if(organ.take_damage(0, damage, sharp, edge, used_weapon)) @@ -406,4 +394,4 @@ This function restores all organs. // Will set our damageoverlay icon to the next level, which will then be set back to the normal level the next mob.Life(). updatehealth() - return 1 + return 1 \ No newline at end of file diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm index 0ceabc84bfe..986a3ffb9c4 100644 --- a/code/modules/mob/living/carbon/human/human_defense.dm +++ b/code/modules/mob/living/carbon/human/human_defense.dm @@ -38,6 +38,7 @@ emp_act var/obj/item/organ/external/organ = get_organ(check_zone(def_zone)) if(isnull(organ)) + . = bullet_act(P, "chest") //act on chest instead return //Shrapnel @@ -56,6 +57,18 @@ emp_act organ.add_autopsy_data(P.name, P.damage) // Add the bullet's name to the autopsy data return (..(P , def_zone)) + +/mob/living/carbon/human/check_projectile_dismemberment(obj/item/projectile/P, def_zone) + var/obj/item/organ/external/affecting = get_organ(check_zone(def_zone)) + if(affecting && !affecting.cannot_amputate && affecting.get_damage() >= (affecting.max_damage - P.dismemberment)) + var/damtype = DROPLIMB_EDGE + switch(P.damage_type) + if(BRUTE) + damtype = DROPLIMB_BLUNT + if(BURN) + damtype = DROPLIMB_BURN + + affecting.droplimb(FALSE, damtype) /mob/living/carbon/human/getarmor(var/def_zone, var/type) var/armorval = 0 @@ -187,8 +200,8 @@ emp_act --src.meatleft to_chat(user, "\red You hack off a chunk of meat from [src.name]") if(!src.meatleft) - src.attack_log += "\[[time_stamp()]\] Was chopped up into meat by [key_name(user)]" - user.attack_log += "\[[time_stamp()]\] Chopped up [key_name(src)] into meat Back: | [(inventory_back && !(inventory_back.flags&ABSTRACT)) ? inventory_back : "Empty"] | | Collar: | [(collar && !(collar.flags&ABSTRACT)) ? collar : "Empty"] | Collar: | [(collar && !(collar.flags&ABSTRACT)) ? collar : "Empty"] | |
| Left Hand: | [(l_hand && !(l_hand.flags&ABSTRACT)) ? l_hand : "Empty"] |
| Right Hand: | [(r_hand && !(r_hand.flags&ABSTRACT)) ? r_hand : "Empty"] |
| Collar: | [(collar && !(collar.flags&ABSTRACT)) ? collar : "Empty"] |
| Collar: | [(collar && !(collar.flags&ABSTRACT)) ? collar : "Empty"] |
Setup Character
[real_name]
{{:value}} - |
+ {{:helper.link('Select', null, { 'shipSelect' : value })}} |
+
There are no available shipping destinations. |