diff --git a/.gitignore b/.gitignore index eebe308e9c8..b1c6675bbfe 100644 --- a/.gitignore +++ b/.gitignore @@ -8,7 +8,6 @@ /cfg/**/* # Ignore compiled linux libs in the root folder, e.g. librust_g.so -/*.so #Ignore compiled files and other files generated during compilation. *.mdme diff --git a/_maps/map_files/Fortress Nash/FortNash1.dmm b/_maps/map_files/Fortress Nash/FortNash1.dmm index fb32d8648d1..67c56177ebc 100644 --- a/_maps/map_files/Fortress Nash/FortNash1.dmm +++ b/_maps/map_files/Fortress Nash/FortNash1.dmm @@ -38978,7 +38978,7 @@ /obj/machinery/light{ dir = 4 }, -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel, /area/f13/building) "jbE" = ( diff --git a/_maps/map_files/Pahrump-AB/Pahrump-AB-Lower.dmm b/_maps/map_files/Pahrump-AB/Pahrump-AB-Lower.dmm index 87f63ceb350..c4681062249 100644 --- a/_maps/map_files/Pahrump-AB/Pahrump-AB-Lower.dmm +++ b/_maps/map_files/Pahrump-AB/Pahrump-AB-Lower.dmm @@ -2032,8 +2032,8 @@ "bHh" = ( /obj/effect/decal/cleanable/dirt, /obj/structure/closet/crate, -/obj/item/ingot/silver, -/obj/item/ingot/silver, +/obj/item/blacksmith/ingot/silver, +/obj/item/blacksmith/ingot/silver, /obj/item/coin/silver, /obj/item/coin/silver, /obj/item/coin/silver, @@ -11627,12 +11627,12 @@ /area/f13/caves) "hqo" = ( /obj/structure/rack, -/obj/item/ingot/iron, -/obj/item/ingot/iron, -/obj/item/ingot/titanium, -/obj/item/ingot/titanium, -/obj/item/ingot/adamantine, -/obj/item/ingot/adamantine, +/obj/item/blacksmith/ingot/iron, +/obj/item/blacksmith/ingot/iron, +/obj/item/blacksmith/ingot/titanium, +/obj/item/blacksmith/ingot/titanium, +/obj/item/blacksmith/ingot/adamantine, +/obj/item/blacksmith/ingot/adamantine, /turf/open/floor/plating/tunnel{ icon_state = "tunnelchess" }, @@ -24731,10 +24731,10 @@ /area/f13/caves) "tfm" = ( /obj/structure/table, -/obj/item/ingot/uranium, -/obj/item/ingot/uranium, -/obj/item/ingot/uranium, -/obj/item/ingot/uranium, +/obj/item/blacksmith/ingot/uranium, +/obj/item/blacksmith/ingot/uranium, +/obj/item/blacksmith/ingot/uranium, +/obj/item/blacksmith/ingot/uranium, /turf/open/floor/plating/rust, /area/f13/radiation) "tfn" = ( diff --git a/_maps/map_files/Pahrump-AB/Pahrump-AB.dmm b/_maps/map_files/Pahrump-AB/Pahrump-AB.dmm index 2fd93907d43..4edcb06af0c 100644 --- a/_maps/map_files/Pahrump-AB/Pahrump-AB.dmm +++ b/_maps/map_files/Pahrump-AB/Pahrump-AB.dmm @@ -43220,7 +43220,7 @@ /area/f13/wasteland) "mFn" = ( /obj/effect/decal/cleanable/dirt, -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel/f13/vault_floor/misc/vaultrust{ color = "#e4e4e4" }, @@ -60632,7 +60632,7 @@ /area/f13/wasteland) "uIx" = ( /obj/effect/decal/cleanable/dirt, -/obj/structure/anvil/obtainable/legion, +/obj/structure/blacksmith/anvil/obtainable/legion, /turf/open/floor/plasteel/f13/vault_floor/misc/vaultrust{ color = "#e4e4e4" }, diff --git a/_maps/map_files/Pahrump-Old/Pahrump-Sunset-Lower.dmm b/_maps/map_files/Pahrump-Old/Pahrump-Sunset-Lower.dmm index 9cc64a1a4c5..e623cecd520 100644 --- a/_maps/map_files/Pahrump-Old/Pahrump-Sunset-Lower.dmm +++ b/_maps/map_files/Pahrump-Old/Pahrump-Sunset-Lower.dmm @@ -34981,7 +34981,7 @@ /turf/open/floor/plating/tunnel, /area/f13/caves) "vdZ" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel/f13/vault_floor/misc/vaultrust, /area/f13/building) "vep" = ( diff --git a/_maps/map_files/Pahrump-Old/Pahrump-Sunset.dmm b/_maps/map_files/Pahrump-Old/Pahrump-Sunset.dmm index 33ce2d3625b..063769187cb 100644 --- a/_maps/map_files/Pahrump-Old/Pahrump-Sunset.dmm +++ b/_maps/map_files/Pahrump-Old/Pahrump-Sunset.dmm @@ -2329,7 +2329,7 @@ /turf/open/floor/plasteel/f13/vault_floor/white, /area/f13/village) "aVn" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/outside/dirt, /area/f13/wasteland) "aVq" = ( @@ -13038,7 +13038,7 @@ /turf/open/floor/f13/wood, /area/f13/building) "fxC" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/inside/mountain, /area/f13/caves) "fxD" = ( @@ -23515,7 +23515,7 @@ /obj/machinery/light/small{ dir = 4 }, -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/inside/mountain, /area/f13/caves) "jKT" = ( diff --git a/_maps/map_files/Pahrump-Sunset - Backup/MapGuide.dmm b/_maps/map_files/Pahrump-Sunset - Backup/MapGuide.dmm index 4aa9af7b266..3cf99a7efac 100644 --- a/_maps/map_files/Pahrump-Sunset - Backup/MapGuide.dmm +++ b/_maps/map_files/Pahrump-Sunset - Backup/MapGuide.dmm @@ -1,6 +1,6 @@ //MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE "aa" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /obj/effect/turf_decal/weather/dirt{ dir = 1 }, diff --git a/_maps/map_files/Pahrump-Sunset - Backup/Pahrump-Sunset.dmm b/_maps/map_files/Pahrump-Sunset - Backup/Pahrump-Sunset.dmm index a7a6112e8e3..77a7c195727 100644 --- a/_maps/map_files/Pahrump-Sunset - Backup/Pahrump-Sunset.dmm +++ b/_maps/map_files/Pahrump-Sunset - Backup/Pahrump-Sunset.dmm @@ -11054,7 +11054,7 @@ /obj/machinery/light{ dir = 4 }, -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel, /area/f13/building) "aMG" = ( diff --git a/_maps/map_files/Pahrump-Sunset - Backup/RockSprings.dmm b/_maps/map_files/Pahrump-Sunset - Backup/RockSprings.dmm index 82de31fca1d..629be417f47 100644 --- a/_maps/map_files/Pahrump-Sunset - Backup/RockSprings.dmm +++ b/_maps/map_files/Pahrump-Sunset - Backup/RockSprings.dmm @@ -13500,7 +13500,7 @@ }, /area/f13/wasteland) "gxZ" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel/cult, /area/f13/building/tribal) "gyv" = ( @@ -25240,7 +25240,7 @@ }, /area/f13/building/tribal) "mdu" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/outside/sidewalk, /area/f13/building) "mdO" = ( diff --git a/_maps/map_files/Temp Map Storage/Pahrump-Sunset - Outdated.dmm b/_maps/map_files/Temp Map Storage/Pahrump-Sunset - Outdated.dmm index 5946e287e05..07e3778c5b6 100644 --- a/_maps/map_files/Temp Map Storage/Pahrump-Sunset - Outdated.dmm +++ b/_maps/map_files/Temp Map Storage/Pahrump-Sunset - Outdated.dmm @@ -2407,7 +2407,7 @@ /turf/open/floor/plasteel/f13/vault_floor/white, /area/f13/village) "aVn" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/outside/dirt, /area/f13/wasteland) "aVq" = ( @@ -23889,7 +23889,7 @@ /obj/machinery/light/small{ dir = 4 }, -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/indestructible/ground/inside/mountain, /area/f13/caves) "jKT" = ( diff --git a/_maps/map_files/Temp Map Storage/Pahrump-Sunset-Lower - Outdated.dmm b/_maps/map_files/Temp Map Storage/Pahrump-Sunset-Lower - Outdated.dmm index 234f2d95236..b7757cbae31 100644 --- a/_maps/map_files/Temp Map Storage/Pahrump-Sunset-Lower - Outdated.dmm +++ b/_maps/map_files/Temp Map Storage/Pahrump-Sunset-Lower - Outdated.dmm @@ -35056,7 +35056,7 @@ /turf/open/floor/plating/tunnel, /area/f13/caves) "vdZ" = ( -/obj/structure/furnace, +/obj/structure/blacksmith/furnace, /turf/open/floor/plasteel/f13/vault_floor/misc/vaultrust, /area/f13/building) "vep" = ( diff --git a/code/__DEFINES/melee.dm b/code/__DEFINES/melee.dm index 29b89339fa2..aaf93046c3c 100644 --- a/code/__DEFINES/melee.dm +++ b/code/__DEFINES/melee.dm @@ -60,3 +60,53 @@ #define WEAPON_BLUNT_TWOHAND_MULT 1 /// Blunt wound addition #define WEAPON_BLUNT_WOUND_ADD 100 // limb wrecker +// MORE MELEE DEFINES + +/// Weapon baseplate values +#define WEAPON_FORCE_SMALL_TOOL 12 +#define WEAPON_FORCE_BIG_TOOL 20 +#define WEAPON_FORCE_KNIFE 27 +#define WEAPON_FORCE_BIG_KNIFE 30 +#define WEAPON_FORCE_SWORD 35 +#define WEAPON_FORCE_SPEAR 24 +#define WEAPON_FORCE_SPEAR_WIELDED 32 +#define WEAPON_FORCE_FIST_WEAPON 29 +#define WEAPON_FORCE_CLUB 30 +#define WEAPON_FORCE_CLUB_WIELDED 39 +#define WEAPON_FORCE_BRUTAL 45 +#define WEAPON_FORCE_MASSIVE 55 + +/// Thrown forces +#define THROWING_PATHETIC 4 +#define THROWING_POOR 10 +#define THROWING_DECENT 20 +#define THROWING_EFFECTIVE 25 +#define THROWING_GOOD 30 +#define THROWING_SUPREME 40 + +/// Melee attack speed +#define MELEE_SPEED_FASTEST 6 +#define MELEE_SPEED_FAST 7 +#define MELEE_SPEED_NORMAL 8 +#define MELEE_SPEED_SLOW 9 +#define MELEE_SPEED_SLOWER 10 +#define MELEE_SPEED_SLOWEST 14 + +/// Melee armor piercing +#define PIERCING_MINOR 0.1 +#define PIERCING_MODERATE 0.2 +#define PIERCING_MAJOR 0.3 + +/// Melee wound bonuses +#define WOUNDING_MALUS_SHALLOW -10 +#define WOUNDING_BONUS_TINY 4 +#define WOUNDING_BONUS_SMALL 8 +#define WOUNDING_BONUS_MODEST 12 +#define WOUNDING_BONUS_BIG 20 +#define WOUNDING_BONUS_HUGE 30 + +/// Throwing distances +#define THROWRANGE_BAD 3 +#define THROWRANGE_AVERAGE 5 +#define THROWRANGE_GOOD 6 +#define THROWRANGE_JAVELIN 7 diff --git a/code/__DEFINES/preferences.dm b/code/__DEFINES/preferences.dm index 010c630b336..310d0cea832 100644 --- a/code/__DEFINES/preferences.dm +++ b/code/__DEFINES/preferences.dm @@ -15,10 +15,11 @@ #define DISABLE_DEATHRATTLE (1<<12) #define DISABLE_ARRIVALRATTLE (1<<13) #define COMBOHUD_LIGHTING (1<<14) +#define MUSIC_RADIO (1<<15) // Gap in prefs between tg and fortune13 prefs. #define SPLIT_ADMIN_TABS (1<<23) -#define TOGGLES_DEFAULT (SOUND_ADMINHELP|SOUND_MIDI|SOUND_AMBIENCE|SOUND_LOBBY|MEMBER_PUBLIC|INTENT_STYLE|MIDROUND_ANTAG|SOUND_INSTRUMENTS|SOUND_SHIP_AMBIENCE|SOUND_PRAYERS|SOUND_ANNOUNCEMENTS) +#define TOGGLES_DEFAULT (SOUND_ADMINHELP|SOUND_MIDI|MUSIC_RADIO|SOUND_AMBIENCE|SOUND_LOBBY|MEMBER_PUBLIC|INTENT_STYLE|MIDROUND_ANTAG|SOUND_INSTRUMENTS|SOUND_SHIP_AMBIENCE|SOUND_PRAYERS|SOUND_ANNOUNCEMENTS) //Chat toggles #define CHAT_OOC (1<<0) diff --git a/code/_globalvars/lists/loadout_categories.dm b/code/_globalvars/lists/loadout_categories.dm index 8d1c1f4fbb9..5c76b8ccae3 100644 --- a/code/_globalvars/lists/loadout_categories.dm +++ b/code/_globalvars/lists/loadout_categories.dm @@ -1,5 +1,5 @@ GLOBAL_LIST_INIT(loadout_categories, list( - LOADOUT_CATEGORY_BACKPACK = list(LOADOUT_SUBCATEGORY_BACKPACK_GENERAL,/* LOADOUT_SUBCATEGORY_BACKPACK_TOYS,*/ LOADOUT_SUBCATEGORY_BACKPACK_BACKPACKS, LOADOUT_SUBCATEGORY_BACKPACK_RATIONS/*, LOADOUT_SUBCATEGORY_BACKPACK_VAULTGUNS*/), + //LOADOUT_CATEGORY_BACKPACK = list(LOADOUT_SUBCATEGORY_BACKPACK_GENERAL,/* LOADOUT_SUBCATEGORY_BACKPACK_TOYS,*/ LOADOUT_SUBCATEGORY_BACKPACK_BACKPACKS, LOADOUT_SUBCATEGORY_BACKPACK_RATIONS/*, LOADOUT_SUBCATEGORY_BACKPACK_VAULTGUNS*/), LOADOUT_CATEGORY_NECK = list(LOADOUT_SUBCATEGORY_NECK_GENERAL,/* LOADOUT_SUBCATEGORY_NECK_TIE,*/ LOADOUT_SUBCATEGORY_NECK_SCARVES), LOADOUT_CATEGORY_MASK = list(LOADOUT_SUBCATEGORY_MASK_GENERAL, LOADOUT_SUBCATEGORY_MASK_BANDANA/*, LOADOUT_SUBCATEGORY_MASK_MISCELLANEOUS*/), LOADOUT_CATEGORY_HANDS = LOADOUT_SUBCATEGORIES_NONE, diff --git a/code/_globalvars/lists/objects.dm b/code/_globalvars/lists/objects.dm index b8cc7b2555d..6f5c0a64886 100644 --- a/code/_globalvars/lists/objects.dm +++ b/code/_globalvars/lists/objects.dm @@ -52,3 +52,4 @@ GLOBAL_LIST_EMPTY(trash_piles) //list of all trash_piles GLOBAL_LIST_EMPTY(money_piles) GLOBAL_LIST_EMPTY(lamppost) //list of all lampposts +GLOBAL_LIST_EMPTY_TYPED(radio_list, /obj/item/radio) //For the radio station. See radio_station.dm diff --git a/code/controllers/subsystem/jukeboxes.dm b/code/controllers/subsystem/jukeboxes.dm index 265edfa0c47..3d9964c22dc 100644 --- a/code/controllers/subsystem/jukeboxes.dm +++ b/code/controllers/subsystem/jukeboxes.dm @@ -1,7 +1,7 @@ SUBSYSTEM_DEF(jukeboxes) name = "Jukeboxes" wait = 5 - var/list/songs = list() + var/list/datum/track/songs = list() var/list/activejukeboxes = list() var/list/freejukeboxchannels = list() @@ -115,3 +115,17 @@ SUBSYSTEM_DEF(jukeboxes) M.playsound_local(currentturf, null, 100, channel = jukeinfo[2], S = song_played) CHECK_TICK return +//BIG IRON EDIT start +/datum/controller/subsystem/jukeboxes/proc/add_song(datum/track/NS) //proc usted to add a song, when a disk is added to a jukebox + if(SSjukeboxes.songs.len) + for(var/datum/track/CT in SSjukeboxes.songs) + if(NS.song_associated_id == CT.song_associated_id) + return FALSE + SSjukeboxes.songs += NS + +/datum/controller/subsystem/jukeboxes/proc/remove_song(datum/track/NS) //proc usted to remove a song, when a disk is removed from a jukebox + for(var/datum/track/RT in SSjukeboxes.songs) + if(NS.song_associated_id == RT.song_associated_id) + SSjukeboxes.songs -= NS + return TRUE +//BIG IRON EDIT -end diff --git a/code/datums/components/crafting/recipes/recipes_forge.dm b/code/datums/components/crafting/recipes/recipes_forge.dm index 49b6dc9791a..d71cbda87e2 100644 --- a/code/datums/components/crafting/recipes/recipes_forge.dm +++ b/code/datums/components/crafting/recipes/recipes_forge.dm @@ -13,14 +13,14 @@ /obj/item/wirecutters = 1, /obj/item/stack/sheet/metal = 20, ) - time = 400 + time = 30 SECONDS category = CAT_CRAFTING subcategory = CAT_FORGING /datum/crafting_recipe/tableanvil name = "Table Anvil" - result = /obj/structure/anvil/obtainable/table - time = 300 + result = /obj/structure/blacksmith/anvil/obtainable/table + time = 20 SECONDS reqs = list( /obj/item/stack/sheet/metal = 8, /obj/item/stack/rods = 8, @@ -31,8 +31,8 @@ /datum/crafting_recipe/anvil name = "Anvil" - result = /obj/structure/anvil/obtainable/basic - time = 450 + result = /obj/structure/blacksmith/anvil/obtainable + time = 30 SECONDS reqs = list( /obj/item/stack/sheet/metal = 50, /obj/item/stack/sheet/mineral/titanium = 15, @@ -43,8 +43,8 @@ /datum/crafting_recipe/sandvil name = "Sandstone Anvil" - result = /obj/structure/anvil/obtainable/sandstone - time = 300 + result = /obj/structure/blacksmith/anvil/obtainable/sandstone + time = 25 SECONDS reqs = list(/obj/item/stack/sheet/mineral/sandstone = 16) tools = list(TOOL_CROWBAR) category = CAT_CRAFTING @@ -52,8 +52,8 @@ /datum/crafting_recipe/furnace name = "Furnace" - result = /obj/structure/furnace - time = 300 + result = /obj/structure/blacksmith/furnace/sandstone + time = 20 SECONDS reqs = list( /obj/item/stack/sheet/mineral/sandstone = 20, /obj/item/stack/sheet/metal = 6, @@ -85,19 +85,6 @@ category = CAT_CRAFTING subcategory = CAT_FORGING -/datum/crafting_recipe/bone_ingot - name = "Processable bone" - result = /obj/item/ingot/bone - time = 100 - reqs = list( - /obj/item/stack/sheet/bone = 2, - /obj/item/crafting/wonderglue = 1, - /obj/item/stack/rods = 2 - ) - tools = list(TOOL_WORKBENCH) - category = CAT_CRAFTING - subcategory = CAT_FORGING - //KNIVES// /datum/crafting_recipe/melee/forged/cleaver diff --git a/code/datums/materials/basemats.dm b/code/datums/materials/basemats.dm index 3b533068a54..dd83c39876c 100644 --- a/code/datums/materials/basemats.dm +++ b/code/datums/materials/basemats.dm @@ -215,7 +215,7 @@ Unless you know what you're doing, only use the first three numbers. They're in name = "pre-war steel" desc = "A powerful material made out of magic, I mean science!" color = "#6d7e8e" - strength_modifier = 1.3 + strength_modifier = 1.2 categories = list(MAT_CATEGORY_RIGID = TRUE, MAT_CATEGORY_BASE_RECIPES = TRUE) sheet_type = /obj/item/stack/sheet/mineral/adamantine value_per_unit = 0.25 @@ -310,7 +310,7 @@ Unless you know what you're doing, only use the first three numbers. They're in name = "bronze" desc = "Clock Cult? Never heard of it." color = "#92661A" - strength_modifier = 1.15 + strength_modifier = 1 categories = list(MAT_CATEGORY_RIGID = TRUE, MAT_CATEGORY_BASE_RECIPES = TRUE) sheet_type = /obj/item/stack/sheet/bronze value_per_unit = 0.025 diff --git a/code/game/machinery/autolathe.dm b/code/game/machinery/autolathe.dm index 52e85ac495a..3949dc31b08 100644 --- a/code/game/machinery/autolathe.dm +++ b/code/game/machinery/autolathe.dm @@ -8,6 +8,7 @@ /obj/machinery/autolathe name = "autolathe" desc = "It produces items using metal and glass." + icon = 'icons/fallout/machines/autolathe.dmi' icon_state = "autolathe" var/icon_state_base = "autolathe" var/icon_state_open = "autolathe_t" @@ -572,7 +573,7 @@ /obj/machinery/autolathe/ammo name = "reloading bench" - icon = 'icons/obj/machines/reloadingbench.dmi' + icon = 'icons/fallout/machines/reloadingbench.dmi' desc = "An ammo bench that utilizes metal and other materials to make ammo and magazines." circuit = /obj/item/circuitboard/machine/autolathe/ammo stored_research = /datum/techweb/specialized/autounlocking/autolathe/ammo @@ -833,6 +834,7 @@ new /obj/item/book/granter/crafting_recipe/gunsmith_three(src) if(advanced) new /obj/item/book/granter/crafting_recipe/gunsmith_four(src) + cut_overlays() return /obj/machinery/autolathe/ammo/unlocked_basic @@ -840,6 +842,11 @@ simple = 1 basic = 1 +/obj/machinery/autolathe/ammo/unlocked_basic/Initialize() + . = ..() + add_overlay("book1") + add_overlay("book2") + /obj/machinery/autolathe/ammo/unlocked simple = 1 basic = 1 @@ -905,3 +912,10 @@ materials.max_amount = max_mats prod_coeff = STANDARD_PART_LEVEL_LATHE_COEFFICIENT(default_workspeed) +/obj/machinery/autolathe/ammo/unlocked/Initialize() + . = ..() + add_overlay("book1") + add_overlay("book2") + add_overlay("book3") + add_overlay("book4") + diff --git a/code/game/machinery/dance_machine.dm b/code/game/machinery/dance_machine.dm index 22234dd7b75..eeacfa3e6b4 100644 --- a/code/game/machinery/dance_machine.dm +++ b/code/game/machinery/dance_machine.dm @@ -11,7 +11,15 @@ var/stop = 0 var/volume = 70 var/datum/track/selection = null + var/obj/item/lock_part/lock = null //BIG IRON EDIT START + var/open_tray = FALSE //usted to determine if the jukebox is open or not, needs a key + var/list/obj/item/record_disk/record_disks = list() //list of inserted disk inthe jukebox + var/obj/item/record_disk/selected_disk = null //the disk chosen to view or ejection +/obj/machinery/jukebox/constructed //BIG IRON EDIT start- a sub jukebox with access for everyone + req_one_access = null + desc = "an improvised jukebox, made with scraps and hopes" +//BIG IRON EDIT -end- /obj/machinery/jukebox/disco name = "radiant dance machine mark IV" desc = "The first three prototypes were discontinued after mass casualty incidents." @@ -21,6 +29,20 @@ var/list/spotlights = list() var/list/sparkles = list() +//BIG IRON EDIT -start +/obj/machinery/jukebox/Initialize() //BIG IRON EDIT -start + . = ..() + lock = new /obj/item/lock_part() + lock.forceMove(src) + var/obj/item/key/vending/K = new /obj/item/key/vending() + K.name = "[src.name] key" + K.forceMove(src.loc) + if(lock) + lock.is_secured = 0 + lock.store_key(K) + lock.is_secured = 1 +//BIG IRON EDIT -end + /obj/machinery/jukebox/disco/indestructible name = "radiant dance machine mark V" desc = "Now redesigned with data gathered from the extensive disco and plasma research." @@ -37,14 +59,56 @@ if(!active && !(flags_1 & NODECONSTRUCT_1)) if(istype(O, /obj/item/wrench)) if(!anchored && !isinspace()) - to_chat(user,span_notice("You secure [src] to the floor.")) + to_chat(user,"You secure [src] to the floor.") setAnchored(TRUE) else if(anchored) - to_chat(user,span_notice("You unsecure and disconnect [src].")) + to_chat(user,"You unsecure and disconnect [src].") setAnchored(FALSE) playsound(src, 'sound/items/deconstruct.ogg', 50, 1) return + if(istype(O, /obj/item/key)) //BIG IRON EDIT -start this one checks for a key used in the jukebox + if(lock.check_key(O)) //check if the key used is assinged to this lock + if(open_tray == FALSE) + open_tray = TRUE + to_chat(user,span_warning("you open the [src]'s tray.")) + else + open_tray = FALSE + to_chat(user,span_warning("you close the [src]'s tray.")) + playsound(src, 'sound/items/Ratchet.ogg', 60, 1) + return + else + playsound(src, 'sound/machines/DeniedBeep.ogg', 60, 1) + to_chat(usr, "Unknown key.") + return + else if(istype(O, /obj/item/record_disk)) //this one checks for a record disk and if the jukebox is open, it adds it to the machine + if(open_tray == FALSE) + to_chat(usr, "The Disk Tray is not open!") + return + var/obj/item/record_disk/I = O + if(!I.R.song_associated_id) + to_chat(user, span_warning("This record is empty!")) + return + for(var/datum/track/RT in SSjukeboxes.songs) + if(I.R.song_associated_id == RT.song_associated_id) + to_chat(user, span_warning("this track is already added to the jukebox!")) + return + record_disks += I + O.forceMove(src) + playsound(src, 'sound/effects/plastic_click.ogg', 100, 0) + if(I.R.song_path) + SSjukeboxes.add_song(I.R) + return//BIG IRON EDIT -end return ..() +/obj/machinery/jukebox/proc/eject_record(obj/item/record_disk/M) //BIG IRON EDIT -start- ejects a record as defined and removes it's song from the list + if(!M) + visible_message("no disk to eject") + return + playsound(src, 'sound/effects/disk_tray.ogg', 100, 0) + src.visible_message(" ejected the [selected_disk] from the [src]!") + M.forceMove(get_turf(src)) + SSjukeboxes.remove_song(M.R) + record_disks -= M + selected_disk = null /obj/machinery/jukebox/update_icon_state() if(active) @@ -54,18 +118,18 @@ /obj/machinery/jukebox/ui_status(mob/user) if(!anchored) - to_chat(user,span_warning("This device must be anchored by a wrench!")) + to_chat(user,"This device must be anchored by a wrench!") return UI_CLOSE if(!allowed(user) && !isobserver(user)) - to_chat(user,span_warning("Error: Access Denied.")) + to_chat(user,"Error: Access Denied.") user.playsound_local(src, 'sound/misc/compiler-failure.ogg', 25, TRUE) return UI_CLOSE if(!SSjukeboxes.songs.len && !isobserver(user)) - to_chat(user,span_warning("Error: No music tracks have been authorized for your station. Petition Central Command to resolve this issue.")) + to_chat(user,"Error: No music tracks have been authorized for your station. Petition Central Command to resolve this issue.") playsound(src, 'sound/misc/compiler-failure.ogg', 25, TRUE) return UI_CLOSE return ..() - + /obj/machinery/jukebox/ui_interact(mob/user, datum/tgui/ui) ui = SStgui.try_update_ui(user, src, ui) if(!ui) @@ -84,10 +148,23 @@ data["track_selected"] = null data["track_length"] = null data["track_beat"] = null + data["disks"] = list() + for(var/obj/item/record_disk/RD in record_disks) + var/list/tracks_data = list( + name = RD.name + ) + data["disks"] += list(tracks_data) + data["disk_selected"] = null //BIG IRON EDIT- start more tracks data + data["disk_selected_lenght"] = null + data["disk_beat"] = null //BIG IRON EDIT -end if(selection) data["track_selected"] = selection.song_name data["track_length"] = DisplayTimeText(selection.song_length) data["track_beat"] = selection.song_beat + if(selected_disk) + data["disk_selected"] = selected_disk + data["disk_selected_length"] = DisplayTimeText(selected_disk.R.song_length) + data["disk_selected_beat"] = selected_disk.R.song_beat data["volume"] = volume return data @@ -102,7 +179,7 @@ return if(!active) if(stop > world.time) - to_chat(usr, span_warning("Error: The device is still resetting from the last activation, it will be ready again in [DisplayTimeText(stop-world.time)].")) + to_chat(usr, "Error: The device is still resetting from the last activation, it will be ready again in [DisplayTimeText(stop-world.time)].") playsound(src, 'sound/misc/compiler-failure.ogg', 50, TRUE) return activate_music() @@ -113,7 +190,7 @@ return TRUE if("select_track") if(active) - to_chat(usr, span_warning("Error: You cannot change the song until the current one is over.")) + to_chat(usr, "Error: You cannot change the song until the current one is over.") return var/list/available = list() for(var/datum/track/S in SSjukeboxes.songs) @@ -123,6 +200,30 @@ return selection = available[selected] return TRUE + if("select_record") //BIG IRON EDIT -start- how an user chooses a disk + if(!record_disks.len) + to_chat(usr, "Error: no tracks on the bin!.") + return + var/list/obj/item/record_disk/availabledisks = list() + for(var/obj/item/record_disk/RR in record_disks) + availabledisks[RR.name] = RR + var/selecteddisk = params["record"] + if(QDELETED(src) || !selecteddisk) + return + selected_disk = availabledisks[selecteddisk] + updateUsrDialog() + if("eject_disk") // sanity check for the disk ejection + if(!record_disks.len) + to_chat(usr, "Error: no disks in trays.") + return + if(!selected_disk) + to_chat(usr,"Error: no disk chosen." ) + return + if(selection == selected_disk.R) + selection = null + eject_record(selected_disk) + return TRUE +//BIG IRON EDIT -end if("set_volume") var/new_volume = params["volume"] if(new_volume == "reset") @@ -139,6 +240,9 @@ return TRUE /obj/machinery/jukebox/proc/activate_music() + if(!selection) + visible_message("Track is no longer avaible") + return var/jukeboxslottotake = SSjukeboxes.addjukebox(src, selection, 2) if(jukeboxslottotake) active = TRUE @@ -453,3 +557,239 @@ for(var/mob/living/M in rangers) if(prob(5+(allowed(M)*4)) && CHECK_MOBILITY(M, MOBILITY_MOVE)) dance(M) + +/obj/item/record_disk //BIG IRON EDIT START- the objets used in the creation o music + name = "record disk" //used to store tracks to add to the jukeboxes + desc = "A disk for storing music. Dear god." + icon = 'icons/obj/machines/disk_recorder.dmi' + icon_state = "record_disk" + lefthand_file = 'icons/mob/inhands/items_lefthand.dmi' + righthand_file = 'icons/mob/inhands/items_righthand.dmi' + force = 5 + throwforce = 16 + throw_speed = 2 + w_class = WEIGHT_CLASS_SMALL + attack_verb = list("sliced", "DISKED", "Played music to") + siemens_coefficient = 0 //Means it's insulated + sharpness = SHARP_EDGED + resistance_flags = NONE + max_integrity = 45 + var/datum/track/R = new () + +/obj/item/record_disk/Initialize() //moves them a bit so they are not all accumulated on the same pixel + ..() + name = "Generic record disk" // the name changes with music + pixel_x = rand(-3, 3) + pixel_y = rand(-3, 3) + +/obj/item/record_disk/throw_impact() //since they are not made with petrolium they are a bit more fragile + ..() + src.visible_message("The spinning [src] shatters on impact!") + Destroy() + +/obj/item/record_disk/Destroy() + playsound(src, 'sound/effects/record_shatter.ogg', 100, 0) + new /obj/item/record_shard(get_turf(src)) + new /obj/item/record_shard(get_turf(src)) + new /obj/item/record_shard(get_turf(src)) + new /obj/item/record_shard(get_turf(src)) + new /obj/item/record_shard(get_turf(src)) + ..() +/obj/item/record_shard //if the disk breaks you get pieces of disk that can cut into your feet if you are not carefull + name = "record disk shard" + desc = "A broken shard of a record disk. Who knew record disks were so fragile." + icon = 'icons/obj/machines/disk_recorder.dmi' + icon_state = "record_shard" + lefthand_file = 'icons/mob/inhands/items_lefthand.dmi' + righthand_file = 'icons/mob/inhands/items_righthand.dmi' + w_class = WEIGHT_CLASS_TINY + force = 5 + throwforce = 8 + attack_verb = list("stabs", "DISKED", "sliced") + hitsound = 'sound/weapons/bladeslice.ogg' + resistance_flags = ACID_PROOF + armor = list("melee" = 100, "bullet" = 0, "laser" = 0, "energy" = 100, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 100) + max_integrity = 40 + sharpness = SHARP_POINTY + +/obj/item/record_shard/suicide_act(mob/user) + user.visible_message("[user] is slitting [user.p_their()] [pick("wrists", "throat")] with the record disk shard! It looks like [user.p_theyre()] trying to commit suicide.") + return (BRUTELOSS) + +/obj/item/record_shard/Initialize() + . = ..() + AddComponent(/datum/component/caltrop, force) + AddComponent(/datum/component/butchering, 150, 65) + pixel_x = rand(-8, 8) + pixel_y = rand(-8, 8) + +/obj/item/record_shard/afterattack(atom/A as mob|obj, mob/user, proximity) + . = ..() + if(!proximity || !(src in user)) + return + if(isturf(A)) + return + if(istype(A, /obj/item/storage)) + return + var/hit_hand = ((user.active_hand_index % 2 == 0) ? "r_" : "l_") + "arm" + if(ishuman(user)) + var/mob/living/carbon/human/H = user + if(!H.gloves && !HAS_TRAIT(H, TRAIT_PIERCEIMMUNE)) // golems, etc + to_chat(H, span_warning("[src] cuts into your hand!")) + H.apply_damage(force*0.5, BRUTE, hit_hand) + else if(ismonkey(user)) + var/mob/living/carbon/monkey/M = user + if(!HAS_TRAIT(M, TRAIT_PIERCEIMMUNE)) + to_chat(M, span_warning("[src] cuts into your hand!")) + M.apply_damage(force*0.5, BRUTE, hit_hand) + +/obj/machinery/gramophone_recorder //used to record new tracks to add to the jukeboxes, due to the nature of such Admin Discretion is advised when when given to the playerbase + name = "Gramophone Recorder" + desc = "old gramaphone used to record sounds and audio." + icon = 'icons/obj/machines/disk_recorder.dmi' + icon_state = "gramophone_recorder" + verb_say = "transmit" + density = TRUE + circuit = /obj/item/circuitboard/machine/gramophone_recorder + var/list/music_to_burn + var/obj/item/record_disk/R //Our stored record disk + var/inuse = FALSE + var/list/menu_options = list("EJECT", "Burn existing music", "Burn custom music", "Rename disk", "Update Songs Library") + var/datum/track/music_file = null + var/custom_name + var/loaded_song_path + var/loaded_song_name + var/loaded_song_length + var/loaded_song_beat + var/loaded_song_associated_id + +/obj/machinery/gramophone_recorder/Initialize() + . = ..() + Update_library() + update_icon() + +/obj/machinery/gramophone_recorder/proc/Update_library() //this is used to check for the currently loaded songs + var/list/available[SSjukeboxes.songs.len] + if(available == null) + src.visible_message("no song in library") + for(var/datum/track/S in SSjukeboxes.songs) + available[S.song_name] = S + music_to_burn = available + src.visible_message(" music library has been updated.") + +/obj/machinery/gramophone_recorder/proc/diskProcess() //its an old piece of tech and it takes it's time + addtimer(CALLBACK(src, .proc/burnDisk), 40) + inuse = TRUE + src.visible_message("your disk is being burned, please stand by.") + +/obj/machinery/gramophone_recorder/proc/burnDisk() //basically just burns the gathered info into the loaded disk + if(!R) + visible_message("There's no disk to burn!") + inuse = FALSE + return + R.R.song_path = loaded_song_path + R.R.song_name = loaded_song_name + R.R.song_length = loaded_song_length + R.R.song_beat = loaded_song_beat + R.R.song_associated_id = loaded_song_associated_id + R.name = "[R.R.song_name] record disk" + playsound(src, 'sound/machines/ping.ogg', 50, 1) + src.visible_message(" [R] is ready!.") + inuse = FALSE + +/obj/machinery/gramophone_recorder/attack_hand(mob/living/user) + if(stat & NOPOWER || stat & BROKEN) + update_icon() + return + if(!R) + to_chat(user, "There is no record disk inserted!") + return + if(inuse) + to_chat(user, "A disk is currently being burned!") + return + var/choice = input(user, "Disk: [R] \nChoose an option", "[src] menu") as null|anything in menu_options + if(!user.Adjacent(src)) + to_chat(user, "You are too far away!") + return + if(inuse) + to_chat(user, "A disk is currently being burned!") + return + switch(choice) + if(null) + return + if("EJECT") + if(inuse == TRUE) + to_chat(user, "There's no disk to burn!") + return + playsound(src, 'sound/effects/disk_tray.ogg', 100, 0) + src.visible_message("[user] ejects the [R] from the [src]!") + R.forceMove(get_turf(src)) + R = null + icon_state = "gramophone_recorder" + return + if("Burn existing music") + if(!SSjukeboxes.songs.len) + src.visible_message(" No songs loaded!") + return + var/list/available = list() + for(var/datum/track/S in SSjukeboxes.songs) + available[S.song_name] = S + music_file = input(user, "Choose a song from the library", "[src] menu") as null|anything in music_to_burn + if(QDELETED(src) || !music_file || !istype(available[music_file], /datum/track)) + return + music_file = available[music_file] + loaded_song_path = music_file + loaded_song_name = music_file.song_name + loaded_song_length = music_file.song_length + loaded_song_beat = music_file.song_beat + if(!findtext(music_file.song_associated_id, "CS", 1, 2)) + loaded_song_associated_id = music_file.song_associated_id + else + loaded_song_associated_id = "CS[music_file.song_associated_id]" + diskProcess() + if("Burn custom music") + loaded_song_path = input(user, "Choose a custom song!") as null|sound //uses the server AllowedUpload, by the time of writting,it was about 1024kb + if(loaded_song_path == null) + return + loaded_song_name = input(user, "Enter the song's name") as null|text + if(loaded_song_name == null) + loaded_song_name = "CUSTOM" + loaded_song_length = input(user, "enter the song's duration (in seconds)") as null|text + loaded_song_length = text2num(loaded_song_length) + loaded_song_length *= 10 //why is server time in 0.1 + if(loaded_song_length == null || !isnum(loaded_song_length)) + loaded_song_length = 1800 //3 minutes is good for most songs, no? + loaded_song_beat = 10 + loaded_song_associated_id = "CS00[loaded_song_path]" //while originally not used for much, associated ID can be used to identify different files when checking for songs to add + if(inuse) + to_chat(user, "A disk is currently being burned!") + return + diskProcess() + if("Rename disk") + custom_name = input(user, "Enter new disk name") as null|text + if(custom_name) + R.name = custom_name + src.audible_message("[src] beeps, 'Record disk renamed to: [R]' ") + custom_name = null + else + to_chat(user, "Name selection invalid.") + if("Update Songs Library") + Update_library() + src.audible_message("[src] beeps, 'updated music library") + +/obj/machinery/gramophone_recorder/attackby(obj/item/I, mob/user) + if(stat & NOPOWER || stat & BROKEN) + update_icon() + return + if(istype(I, /obj/item/record_disk)) + if(!R) //only one disk on the tray + R = I + I.forceMove(src) + playsound(src, 'sound/effects/disk_tray.ogg', 100, 0) + usr.visible_message("[user] loads the [R] into the [src].") + icon_state = "loaded_recorder" + return + else + to_chat(user, "There is already a record disk loaded into the [src]!") + return + ..() diff --git a/code/game/machinery/iv_drip.dm b/code/game/machinery/iv_drip.dm index c1da161102d..a6fdb8b94f0 100644 --- a/code/game/machinery/iv_drip.dm +++ b/code/game/machinery/iv_drip.dm @@ -48,7 +48,7 @@ else . += "beakeridle" if(beaker.reagents.total_volume) - var/mutable_appearance/filling_overlay = mutable_appearance('icons/obj/iv_drip.dmi', "reagent") + var/mutable_appearance/filling_overlay = mutable_appearance('modular_BD2/general/icons/primitive_medical.dmi', "reagent") var/percent = round((beaker.reagents.total_volume / beaker.volume) * 100) switch(percent) @@ -212,6 +212,8 @@ set name = "Toggle Mode" set src in view(1) + if(src == /obj/machinery/iv_drip/primitive) + return if(!isliving(usr)) to_chat(usr, span_warning("You can't do that!")) return diff --git a/code/game/objects/effects/spawners/f13lootdrop.dm b/code/game/objects/effects/spawners/f13lootdrop.dm index 580c7730d65..333dc191012 100644 --- a/code/game/objects/effects/spawners/f13lootdrop.dm +++ b/code/game/objects/effects/spawners/f13lootdrop.dm @@ -1130,7 +1130,7 @@ name = "autoloader and ammo spawner" items = list( /obj/item/gun/ballistic/automatic/pistol/sig, - /obj/item/ammo_box/magazine/m45/socom + /obj/item/ammo_box/magazine/m45 ) /obj/effect/spawner/bundle/f13/thatgun @@ -2421,7 +2421,7 @@ /obj/item/advanced_crafting_components/receiver, /obj/item/advanced_crafting_components/assembly, /obj/item/advanced_crafting_components/alloys, -// no ingots rip /obj/item/blacksmith/ingot/adamantine, // Valuable for smithing + /obj/item/blacksmith/ingot/adamantine, // Valuable for smithing ) /obj/effect/spawner/lootdrop/f13/attachments diff --git a/code/game/objects/items/circuitboards/machine_circuitboards.dm b/code/game/objects/items/circuitboards/machine_circuitboards.dm index c2f2f835f16..0692a3b8f13 100644 --- a/code/game/objects/items/circuitboards/machine_circuitboards.dm +++ b/code/game/objects/items/circuitboards/machine_circuitboards.dm @@ -1258,3 +1258,21 @@ /obj/item/stack/cable_coil = 1, /obj/item/stack/sheet/glass = 2) +/obj/item/circuitboard/machine/jukebox //atom edit, constructed circuit board + name = "jukebox circuit board" + build_path = /obj/machinery/jukebox/constructed + req_components = list( + /obj/item/stock_parts/manipulator = 1, + /obj/item/wallframe/intercom = 1, + /obj/item/stack/cable_coil = 1, + /obj/item/stack/sheet/glass = 1) + +/obj/item/circuitboard/machine/gramophone_recorder //atom edit, gramophone recorder circuit board + name = "disk recorder circuit board" + build_path = /obj/machinery/gramophone_recorder + req_components = list( + /obj/item/stock_parts/manipulator = 1, + /obj/item/stack/crafting/metalparts = 1, + /obj/item/taperecorder/empty = 1, + /obj/item/stack/sheet/mineral/wood = 1) + diff --git a/code/game/objects/items/devices/PDA/PDA.dm b/code/game/objects/items/devices/PDA/PDA.dm index d2a54af596b..f0d2d2fdb5b 100644 --- a/code/game/objects/items/devices/PDA/PDA.dm +++ b/code/game/objects/items/devices/PDA/PDA.dm @@ -48,6 +48,8 @@ GLOBAL_LIST_EMPTY(PDAs) var/font_index = 0 //This int tells DM which font is currently selected and lets DM know when the last font has been selected so that it can cycle back to the first font when "toggle font" is pressed again. var/font_mode = "font-family:monospace;" //The currently selected font. var/background_color = "#808000" //The currently selected background color. + var/mob/living/radio_holder = null + var/allow_music = FALSE #define FONT_MONO "font-family:monospace;" #define FONT_SHARE "font-family:\"Share Tech Mono\", monospace;letter-spacing:0px;" @@ -99,6 +101,9 @@ GLOBAL_LIST_EMPTY(PDAs) var/list/blocked_pdas var/list/saved_frequencies = list("Common" = FREQ_COMMON) + var/music_channel + var/TimerID + var/obj/item/record_disk/R /obj/item/pda/suicide_act(mob/living/carbon/user) var/deathMessage = msg_input(user) @@ -122,6 +127,11 @@ GLOBAL_LIST_EMPTY(PDAs) set_light(f_lum, f_pow, f_col) GLOB.PDAs += src + GLOB.radio_list += src //Big Iron. Adds the PDA to the global radio list + var/i + for(i = 1; i <= GLOB.radio_list.len; i++) + if(GLOB.radio_list[i] == src) + music_channel = i if(default_cartridge) cartridge = new default_cartridge(src) if(inserted_item) @@ -320,7 +330,10 @@ GLOBAL_LIST_EMPTY(PDAs) dat += "
  • [PDAIMG(notes)]Notekeeper
  • " dat += "
  • [PDAIMG(mail)]Messenger
  • " dat += "
  • [PDAIMG(signaler)]Radio
  • " - + if (R) + dat += "
  • Eject record disk
  • " //Big-iron + dat += "
  • Play record disk
  • " + dat += "
  • Stop record disk
  • " if (cartridge) if (cartridge.access & CART_MANIFEST) dat += "
  • [PDAIMG(notes)]View Crew Manifest
  • " @@ -397,7 +410,6 @@ GLOBAL_LIST_EMPTY(PDAs) dat += "[PDAIMG(mail)]Send / Receive: [toff == 1 ? "Off" : "On"] | " dat += "[PDAIMG(bell)]Set Ringtone | " dat += "[PDAIMG(mail)]Messages
    " - if(cartridge) dat += cartridge.message_header() @@ -468,6 +480,7 @@ GLOBAL_LIST_EMPTY(PDAs) dat += "+" dat += "+" dat += " | Save Frequency

    " + dat += "Allow music: [allow_music?"Allowed":"disallowed"]
    " if(saved_frequencies) dat += "Saved Frequencies" @@ -476,6 +489,25 @@ GLOBAL_LIST_EMPTY(PDAs) dat += "
  • [freq] ([format_frequency(saved_frequencies[freq])])" dat += " (Delete | Rename)
  • " dat += "" + if(9) + if(R) + stopMusic(user) + radio_holder = null + R.forceMove(get_turf(src)) + playsound(src, 'sound/effects/plastic_click.ogg', 100, 0) + R = null + else + to_chat(src.loc, "No record disk inserted!") + mode = 0 + + if(10) + playMusiclocal(user) + mode = 0 + + if(11) + stopMusic(user) + radio_holder = null + mode = 0 else//Else it links to the cart menu proc. Although, it really uses menu hub 4--menu 4 doesn't really exist as it simply redirects to hub. dat += cartridge.generate_menu() @@ -754,7 +786,10 @@ GLOBAL_LIST_EMPTY(PDAs) if(href_list["rspktoggle"]) radio.listening = !radio.listening Boop() - + if(href_list["allowmmusictoggle"]) + allow_music = !allow_music + stopMusic(radio_holder) + Boop() if(href_list["rfreq"]) var/new_frequency = (radio.frequency + text2num(href_list["rfreq"])) if (!radio.freerange || (radio.frequency < MIN_FREE_FREQ || radio.frequency > MAX_FREE_FREQ)) @@ -900,7 +935,7 @@ GLOBAL_LIST_EMPTY(PDAs) if (!signal.data["done"]) to_chat(user, span_notice("ERROR: Server isn't responding.")) if (!silent) - playsound(src, 'sound/machines/terminal_error.ogg', 15, 1) + playsound(src, 'sound/machines/terminal_error.ogg', 35, channel = music_channel) return var/target_text = signal.format_target() @@ -1093,6 +1128,15 @@ GLOBAL_LIST_EMPTY(PDAs) to_chat(user, span_notice("You insert [cartridge] into [src].")) update_icon() playsound(src, 'sound/machines/button.ogg', 50, 1) + if(istype(C, /obj/item/record_disk)) + if(R) + to_chat(user, "A record disk is already inserted!") + return + else + R = C + C.forceMove(src) + playsound(src, 'sound/effects/plastic_click.ogg', 100, 0) + playMusiclocal(user) else if(istype(C, /obj/item/card/id)) var/obj/item/card/id/idcard = C @@ -1219,6 +1263,9 @@ GLOBAL_LIST_EMPTY(PDAs) /obj/item/pda/Destroy() GLOB.PDAs -= src + GLOB.radio_list -= src //Big iron. Removes from global radio list + stopMusic(radio_holder) + radio_holder = null if(istype(id)) QDEL_NULL(id) if(istype(cartridge)) @@ -1318,6 +1365,45 @@ GLOBAL_LIST_EMPTY(PDAs) continue . += P +/obj/item/pda/proc/playMusiclocal(mob/living/user) + if(istype(src.loc, /mob/living)) + user = src.loc + if(item_flags & IN_INVENTORY) + if(allow_music) + playsound(user, R.R.song_path, 100, channel = music_channel) //plays the music to the user + radio_holder = user + to_chat(user, "You play the [R] on your PDA.") + else + to_chat(user, "The [src] is not allowed to play music!") + else + to_chat(user, "The [src] must be in your inventory to play music!") + +/obj/item/pda/proc/playmusic(music_filepath, name_of_music, music_volume) //Plays music at src using the filepath to the audio file. This proc is directly working with the bluespace radio station at radio_station.dm + var/atom/loc_layer = loc + while(istype(loc_layer, /atom/movable)) + if(!istype(loc_layer, /mob/living)) + loc_layer = loc_layer.loc + else + radio_holder = loc_layer + break + if(!loc_layer) //if loc is null then this proc doesn't need to continue + return + if(!istype(loc_layer, /mob/living)) //doesn't need to continue if not on a mob + return + + if(allow_music) //Music player is on + var/mob/living/M = loc_layer + if(istype(M) && M.client) + var/client/C = M.client + if(!(C.prefs.toggles & MUSIC_RADIO)) + return + stopMusic(radio_holder) //stop the previously playing song to make way for the new one + playsound(radio_holder, music_filepath, music_volume, channel = music_channel) //plays the music to the user + to_chat(radio_holder, "[src] beeps into your ears, 'Now playing: [name_of_music].' ") + +/obj/item/pda/proc/stopMusic(mob/user) + playsound(user, 'sound/machines/button.ogg', 50, channel = music_channel) + playsound(user, null, channel = music_channel) #undef PDA_SCANNER_NONE #undef PDA_SCANNER_MEDICAL diff --git a/code/game/objects/items/devices/radio/radio.dm b/code/game/objects/items/devices/radio/radio.dm index 575509963e2..85f722f42ad 100644 --- a/code/game/objects/items/devices/radio/radio.dm +++ b/code/game/objects/items/devices/radio/radio.dm @@ -47,6 +47,12 @@ var/linked_faction = FALSE // Which faction the radio is linked to. var/mob/living/carbon/linked_mob = null // Which mob the radio is checked out to. //fortuna addition end. radio management. + var/music_channel = null //The sound channel the music is playing on. + var/radio_music_file = "" //The file path to the music's audio file + var/music_toggle = TRUE //Toggles whether music will play or not. + var/music_name = "" //Used to display the name of currently playing music. + var/music_playing = FALSE + var/mob/living/radio_holder //stopmusic() will apply to this person /obj/item/radio/suicide_act(mob/living/user) user.visible_message(span_suicide("[user] starts bouncing [src] off [user.p_their()] head! It looks like [user.p_theyre()] trying to commit suicide!")) @@ -95,6 +101,7 @@ LAZYREMOVE(GLOB.legion_radios, src) if(FACTION_BROTHERHOOD) LAZYREMOVE(GLOB.bos_radios, src) + GLOB.radio_list -= src //Big-Iron, removes radio from radio list lmao remove_radio_all(src) //Just to be sure QDEL_NULL(wires) QDEL_NULL(keyslot) @@ -102,6 +109,18 @@ /obj/item/radio/Initialize() wires = new /datum/wires/radio(src) + var/obj/item/pda/pdloc = loc + if(!istype(src, /obj/item/radio/intercom) && !istype(pdloc)) //Intercoms playing music is useless + GLOB.radio_list += src //Big iron. Adds the radio to the global radio list for usage in radio_station.dm + var/i + for(i = 1; i <= GLOB.radio_list.len; i++) + if(GLOB.radio_list[i] == src) + music_channel = i //I hope that over 1,000 radios are never initialized. + /* Allow me to explain why. There are 1,024 usable channels. The top ~10 + are preserved for ambience, admin music, etc. The other 1,000 are unused (to my knowledge) + and so to allow radios to play their own music without inferefering with other sounds, I give + each radio their own channel to play music on. This way the user can also stop the music + playing from their radio (headsets, etc.) without stopping the music of someone else's radio. */ if(prison_radio) wires.cut(WIRE_TX) // OH GOD WHY secure_radio_connections = new @@ -157,6 +176,7 @@ data["broadcasting"] = broadcasting data["listening"] = listening + data["music_toggle"] = music_toggle data["frequency"] = frequency data["minFrequency"] = freerange ? MIN_FREE_FREQ : MIN_FREQ data["maxFrequency"] = freerange ? MAX_FREE_FREQ : MAX_FREQ @@ -228,6 +248,10 @@ else recalculateChannels() . = TRUE + if("streammusic") + music_toggle = !music_toggle + stopmusic(radio_holder) + . = TRUE /obj/item/radio/talk_into(atom/movable/M, message, channel, list/spans, datum/language/language) if(!spans) @@ -397,6 +421,102 @@ to_chat(user, span_notice("The radio can no longer be modified or attached!")) else return ..() + +/obj/item/radio/AltClick(mob/user) //Big Iron + ..() + if(!istype(user) || !Adjacent(user) || user.incapacitated()) + return + if(user.a_intent == INTENT_HARM) + if(music_toggle) + music_toggle = 0 + stopmusic(radio_holder) + to_chat(user, "[src]'s music player is now OFF. ") + else + music_toggle = 1 + to_chat(user, "[src]'s music player is now ON. ") + return + +/obj/item/radio/proc/avoiding_a_sleep(mob/living/user, music_filepath, name_of_music, music_volume) + music_name = name_of_music + to_chat(user, "[src] beeps into your ears, 'Now playing: [music_name].' ") + if(user.client) + var/mob/M = user + var/client/C = M.client + if(!(C.prefs.toggles & MUSIC_RADIO)) + to_chat(user, "[src] your preferences stopped [music_name] from playing!.' ") + return + music_playing = TRUE + playsound(user, music_filepath, music_volume, channel = music_channel) //plays the music to the user + update_icon() + +/obj/item/radio/proc/playmusic(music_filepath, name_of_music, music_volume) //Plays music at src using the filepath to the audio file. This proc is directly working with the bluespace radio station at radio_station.dm + radio_music_file = music_filepath + + var/atom/loc_layer = loc + while(istype(loc_layer, /atom/movable)) + if(!istype(loc_layer, /mob/living)) + loc_layer = loc_layer.loc + else + radio_holder = loc_layer + break + if(!loc_layer) //if loc is null then this proc doesn't need to continue + return + if(!istype(loc_layer, /mob/living)) //doesn't need to continue if not on a mob + return + + if(music_toggle == 1) //Music player is on + if(istype(src, /obj/item/radio/headset)) + var/mob/living/carbon/wearer = radio_holder + if(!(wearer.ears == src)) //only want headsets to play music if they're equipped + return + stopmusic(radio_holder) //stop the previously playing song to make way for the new one + addtimer(CALLBACK(src, .proc/avoiding_a_sleep, radio_holder, music_filepath, name_of_music, music_volume), 10) + +/obj/item/radio/proc/stopmusic(mob/living/user, music_turnoff_message_type) + if(music_playing) + music_playing = FALSE + update_icon() + playsound(user, null, channel = music_channel) + playsound(user, 'sound/machines/buzz-sigh.ogg', 50, channel = music_channel) + music_name = "" + switch(music_turnoff_message_type) + if(1) + audible_message("[src] beeps, '[src] removed, turning off music.' ") + if(2) + src.audible_message("[src] beeps, 'Music toggled off.' ") //Unused message + if(3) + src.audible_message("[src] beeps, 'Signal interrupted.' ") + music_playing = FALSE + +/obj/item/radio/dropped(mob/user) + ..() + addtimer(CALLBACK(src, .proc/droppedStopMusic, user), 3) + +/obj/item/radio/proc/droppedStopMusic(mob/user) + var/i + for(i = 1, i <= user.contents.len, i++) + if(user.contents[i] == src) + return + if(item_flags & IN_INVENTORY) + return + if(determineIfInMob(user) == TRUE) + return + stopmusic(user, 1) + +/obj/item/radio/proc/determineIfInMob(mob/user) + var/obj/itemholder = src + var/mob/M = src.loc + while(M && !istype(M, /mob/living)) + M = itemholder + if(!M) + return FALSE + itemholder = itemholder.loc + if(M == user) + return TRUE + else + return FALSE + +//Big-iron end /* /obj/item/radio/emp_act(severity) . = ..() diff --git a/code/game/objects/items/granters.dm b/code/game/objects/items/granters.dm index 7b82a86b82f..d7e83aa01d5 100644 --- a/code/game/objects/items/granters.dm +++ b/code/game/objects/items/granters.dm @@ -968,6 +968,13 @@ traitname = "hitting things" remarks = list("Grognak hit the Death Knight only once, but that was enough.", "Grognak is surprisingly agile, never committing too heavily on an attack, dancing between his enemies.", "Grognak isn't good at talking, but he knows it has its place. He has friends to talk for him.", "Other barbarians might change their weapons, but Grognak could never leave his beloved axe.") +/obj/item/book/granter/trait/specopguide + name = "Special Operation Guide" + desc = "A book about how to never miss again!." + granted_trait = TRAIT_INSANE_AIM + traitname = "perfect shooting" + remarks = list("Switching to your sidearm is always faster than reloading.", "Use a bola to slow down your target.", "A smoke grenade will make the enemy drop small item that they're holding", "Never chase an enemy alone even if you think you're winning.") + /obj/item/book/granter/trait/lowsurgery name = "First Aid Pamphlet" desc = "A flimsy collection of vital tips and tricks for the average American with a sudden injury." diff --git a/code/game/objects/items/stacks/crafting.dm b/code/game/objects/items/stacks/crafting.dm index 3dce0ce3a85..f3051260c2a 100644 --- a/code/game/objects/items/stacks/crafting.dm +++ b/code/game/objects/items/stacks/crafting.dm @@ -81,11 +81,14 @@ GLOBAL_LIST_INIT(metalparts_recipes, list(\ /obj/item/stack/crafting/electronicparts/five amount = 5 - -GLOBAL_LIST_INIT(electronicparts_recipes, list(\ - new/datum/stack_recipe("ion arrowhead", /obj/item/stack/arrowhead/ion, 1, 1, 1 SECONDS),\ - )) - +//BIG IRON EDIT start, make it so you can craft some circit boards with electronic parts +GLOBAL_LIST_INIT(electronicparts_recipes, list ( \ + new/datum/stack_recipe("Jukebox circuit board", /obj/item/circuitboard/machine/jukebox, 2), +)) +/obj/item/stack/crafting/electronicparts/get_main_recipes() + . = ..() + . += GLOB.electronicparts_recipes +//BIG IRON EDIT end /obj/item/stack/crafting/electronicparts/get_main_recipes() . = ..() . += GLOB.electronicparts_recipes diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm index af82d2cec91..39271b9adce 100644 --- a/code/game/objects/items/stacks/sheets/mineral.dm +++ b/code/game/objects/items/stacks/sheets/mineral.dm @@ -122,7 +122,7 @@ GLOBAL_LIST_INIT(diamond_recipes, list ( \ new/datum/stack_recipe("Captain Statue", /obj/structure/statue/diamond/captain, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("AI Hologram Statue", /obj/structure/statue/diamond/ai1, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("AI Core Statue", /obj/structure/statue/diamond/ai2, 5, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("diamond brick", /obj/item/ingot/diamond, 6, time = 100), +// new/datum/stack_recipe("diamond brick", /obj/item/blacksmith/ingot/diamond, 6, time = 100), \ not yet )) /obj/item/stack/sheet/mineral/diamond/get_main_recipes() @@ -158,7 +158,7 @@ GLOBAL_LIST_INIT(uranium_recipes, list ( \ new/datum/stack_recipe("uranium tile", /obj/item/stack/tile/mineral/uranium, 1, 4, 20), \ new/datum/stack_recipe("Nuke Statue", /obj/structure/statue/uranium/nuke, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("Engineer Statue", /obj/structure/statue/uranium/eng, 5, one_per_turf = 1, on_floor = 1), \ -// new/datum/stack_recipe("uranium ingot", /obj/item/ingot/uranium, 6, time = 100), \ please no + new/datum/stack_recipe("uranium ingot", /obj/item/blacksmith/ingot/uranium, 6, time = 100), \ )) /obj/item/stack/sheet/mineral/uranium/get_main_recipes() @@ -198,7 +198,7 @@ GLOBAL_LIST_INIT(plasma_recipes, list ( \ new/datum/stack_recipe("plasma door", /obj/structure/mineral_door/transparent/plasma, 10, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("plasma tile", /obj/item/stack/tile/mineral/plasma, 1, 4, 20), \ new/datum/stack_recipe("Scientist Statue", /obj/structure/statue/plasma/scientist, 5, one_per_turf = 1, on_floor = 1), \ -// new/datum/stack_recipe("plasma ingot", /obj/item/ingot/plasma, 6, time = 100), \ no +// new/datum/stack_recipe("plasma ingot", /obj/item/blacksmith/ingot/plasma, 6, time = 100), \ no )) /obj/item/stack/sheet/mineral/plasma/get_main_recipes() @@ -249,7 +249,7 @@ GLOBAL_LIST_INIT(gold_recipes, list ( \ new/datum/stack_recipe("RD Statue", /obj/structure/statue/gold/rd, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("Simple Crown", /obj/item/clothing/head/crown, 5), \ new/datum/stack_recipe("CMO Statue", /obj/structure/statue/gold/cmo, 5, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("gold ingot", /obj/item/ingot/gold, 6, time = 100), \ + new/datum/stack_recipe("gold ingot", /obj/item/blacksmith/ingot/gold, 6, time = 100), \ )) /obj/item/stack/sheet/mineral/gold/get_main_recipes() @@ -288,7 +288,7 @@ GLOBAL_LIST_INIT(silver_recipes, list ( \ new/datum/stack_recipe("Sec Officer Statue", /obj/structure/statue/silver/sec, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("Sec Borg Statue", /obj/structure/statue/silver/secborg, 5, one_per_turf = 1, on_floor = 1), \ new/datum/stack_recipe("Med Borg Statue", /obj/structure/statue/silver/medborg, 5, one_per_turf = 1, on_floor = 1), \ - new/datum/stack_recipe("silver ingot", /obj/item/ingot/silver, 6, time = 100), \ + new/datum/stack_recipe("silver ingot", /obj/item/blacksmith/ingot/silver, 6, time = 100), \ )) /obj/item/stack/sheet/mineral/silver/get_main_recipes() @@ -326,7 +326,7 @@ GLOBAL_LIST_INIT(silver_recipes, list ( \ GLOBAL_LIST_INIT(titanium_recipes, list ( \ new/datum/stack_recipe("titanium tile", /obj/item/stack/tile/mineral/titanium, 1, 4, 20), \ - new/datum/stack_recipe("titanic ingot", /obj/item/ingot/titanium, 6, time = 100), \ + new/datum/stack_recipe("titanic ingot", /obj/item/blacksmith/ingot/titanium, 6, time = 100), \ new/datum/stack_recipe("titanium arrowhead", /obj/item/stack/arrowhead/titanium, 2, 1, time = 2.5 SECONDS), \ new/datum/stack_recipe("bear trap", /obj/item/restraints/legcuffs/beartrap, 1, time = 50), \ /*new/datum/stack_recipe("high quality parts", /obj/item/stack/crafting/goodparts, 5, time = 50) \ these are easy enough to find*/ @@ -383,7 +383,7 @@ GLOBAL_LIST_INIT(plastitanium_recipes, list ( \ */ GLOBAL_LIST_INIT(adamantine_recipes, list( new /datum/stack_recipe("incomplete servant golem shell", /obj/item/golem_shell/servant, req_amount=1, res_amount=1), - new/datum/stack_recipe("adamant ingot", /obj/item/ingot/adamantine, 6, time = 100), \ + new/datum/stack_recipe("adamant ingot", /obj/item/blacksmith/ingot/adamantine, 6, time = 100), \ )) /obj/item/stack/sheet/mineral/adamantine diff --git a/code/game/objects/items/stacks/sheets/sheet_types.dm b/code/game/objects/items/stacks/sheets/sheet_types.dm index 7a66e3e2498..415dfdef0bd 100644 --- a/code/game/objects/items/stacks/sheets/sheet_types.dm +++ b/code/game/objects/items/stacks/sheets/sheet_types.dm @@ -27,8 +27,8 @@ GLOBAL_LIST_INIT(metal_recipes, list ( \ new/datum/stack_recipe("simple metal door", /obj/structure/simple_door/metal, 10, one_per_turf = TRUE, on_floor = TRUE), \ null, \ new/datum/stack_recipe("metal rod", /obj/item/stack/rods, 1, 2, 60), \ - new/datum/stack_recipe("iron ingot", /obj/item/ingot/iron, 6, time = 100), \ - /*new/datum/stack_recipe("metal parts", /obj/item/stack/crafting/metalparts, 5), \ very easy to find already*/ + new/datum/stack_recipe("iron ingot", /obj/item/blacksmith/ingot/iron, 6, time = 100), \ + new/datum/stack_recipe("metal parts", /obj/item/stack/crafting/metalparts, 5), \ new/datum/stack_recipe("length of chain", /obj/item/blacksmith/chain, 1, time = 50), \ new/datum/stack_recipe("metal arrowhead", /obj/item/stack/arrowhead/metal, 2, 1, time = 2.5 SECONDS), \ new/datum/stack_recipe("field arrowhead", /obj/item/stack/arrowhead/field, 1, 1, time = 1 SECONDS), \ @@ -353,17 +353,18 @@ GLOBAL_LIST_INIT(wood_recipes, list ( \ grind_results = list(/datum/reagent/cellulose = 20) walltype = /turf/closed/wall/mineral/wood -/obj/item/stack/sheet/mineral/wood/attackby(obj/item/W, mob/user, params) // NOTE: sheet_types.dm is where the WOOD stack lives. Maybe move this over there. +/obj/item/stack/sheet/mineral/wood/attackby(obj/item/W, mob/user, params) // Taken from /obj/item/stack/rods/attackby in [rods.dm] if(W.get_sharpness()) user.visible_message("[user] begins whittling [src] into a rod.", \ - span_notice("You begin whittling [src] into a rod, suitable as a weapon shaft."), \ - span_italic("You hear wood carving.")) - // 7 Second Timer - if(!do_after(user, 70, TRUE, src)) - return + span_notice("You begin whittling [src] into a rod, suitable as a weapon shaft.")) +// span_italic("You hear wood carving.")) didnt work on this Db for some reason + // 5 Second Timer + if(!do_after(user, 5 SECONDS, TRUE, src)) + to_chat(user,"You didn't finish your carving.") + return TRUE // Make stick - var/obj/item/blacksmith/woodrod/new_item = new(user.loc) + var/obj/item/blacksmith/woodenrod/new_item = new(user.loc) user.visible_message("[user] finishes carving a rod from the [src].", \ span_notice("You finish carving a rod from the [src].")) // Prepare to Put in Hands (if holding wood) @@ -598,9 +599,6 @@ GLOBAL_LIST_INIT(runed_metal_recipes, list ( \ new/datum/stack_recipe("forge", /obj/structure/destructible/cult/forge, 3, time = 40, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("archives", /obj/structure/destructible/cult/tome, 3, time = 40, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("altar", /obj/structure/destructible/cult/talisman, 3, time = 40, one_per_turf = TRUE, on_floor = TRUE), \ - new/datum/stack_recipe("anvil", /obj/structure/anvil/obtainable/narsie, 4, time = 40, one_per_turf = TRUE, on_floor = TRUE), \ - new/datum/stack_recipe("runic ingot", /obj/item/ingot/cult, 2, time = 100), \ - new/datum/stack_recipe("rune smith's hammer", /obj/item/melee/smith/hammer/narsie, 6), \ )) /obj/item/stack/sheet/runed_metal @@ -663,8 +661,6 @@ GLOBAL_LIST_INIT(brass_recipes, list ( \ new/datum/stack_recipe("brass bar stool", /obj/structure/chair/stool/bar/brass, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("brass stool", /obj/structure/chair/stool/brass, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("brass table frame", /obj/structure/table_frame/brass, 1, time = 5, one_per_turf = TRUE, on_floor = TRUE), \ - new/datum/stack_recipe("brass anvil", /obj/structure/anvil/obtainable/ratvar, 10, time = 15, one_per_turf = TRUE, on_floor = TRUE), \ - new/datum/stack_recipe("brass furnace", /obj/structure/furnace/infinite/ratvar, 10, time = 15, one_per_turf = TRUE, on_floor = TRUE), \ null, \ new/datum/stack_recipe("sender - pressure sensor", /obj/structure/destructible/clockwork/trap/trigger/pressure_sensor, 2, time = 20, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("sender - mech sensor", /obj/structure/destructible/clockwork/trap/trigger/pressure_sensor/mech, 2, time = 20, one_per_turf = TRUE, on_floor = TRUE), \ @@ -676,8 +672,6 @@ GLOBAL_LIST_INIT(brass_recipes, list ( \ new/datum/stack_recipe("receiver - power nullifier", /obj/structure/destructible/clockwork/trap/power_nullifier, 5, time = 20, one_per_turf = TRUE, on_floor = TRUE, placement_checks = STACK_CHECK_CARDINALS), \ null, \ new/datum/stack_recipe("brass flask", /obj/item/reagent_containers/food/drinks/bottle/holyoil/empty), \ - new/datum/stack_recipe("brass smith's hammer", /obj/item/melee/smith/hammer/ratvar, 6), \ - new/datum/stack_recipe("brass ingot", /obj/item/ingot/ratvar, 6, time = 100), \ )) /obj/item/stack/tile/brass @@ -734,9 +728,8 @@ GLOBAL_LIST_INIT(bronze_recipes, list ( \ new/datum/stack_recipe("bronze chair", /obj/structure/chair/bronze, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("bronze bar stool", /obj/structure/chair/stool/bar/bronze, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \ new/datum/stack_recipe("bronze stool", /obj/structure/chair/stool/bronze, 1, time = 0, one_per_turf = TRUE, on_floor = TRUE), \ - new/datum/stack_recipe("bronze anvil",/obj/structure/anvil/obtainable/bronze, 20, time = 110, one_per_turf = TRUE, on_floor = TRUE), \ null, - new/datum/stack_recipe("bronze ingot", /obj/item/ingot/bronze, 6, time = 100), \ + new/datum/stack_recipe("bronze ingot", /obj/item/blacksmith/ingot/bronze, 6, time = 100), \ new/datum/stack_recipe("bronze floor tiles", /obj/item/stack/tile/bronze, 1, 4, 20), \ )) diff --git a/code/game/objects/items/storage/belt.dm b/code/game/objects/items/storage/belt.dm index 8193d6b44b5..7a26ea0d7e3 100755 --- a/code/game/objects/items/storage/belt.dm +++ b/code/game/objects/items/storage/belt.dm @@ -207,6 +207,23 @@ new /obj/item/stack/medical/bone_gel(src) // Primitive medical belt, meant to be part of a ghetto surgery improvement at some point +/obj/item/storage/belt/utility/gardener/ComponentInitialize() + . = ..() + var/datum/component/storage/STR = GetComponent(/datum/component/storage) + var/static/list/can_hold = typecacheof(list( + /obj/item/shovel/spade, + /obj/item/cultivator, + /obj/item/hatchet, + /obj/item/book/manual/advice_farming, + /obj/item/reagent_containers/glass/bottle/nutrient, + /obj/item/reagent_containers/glass/bottle/killer, + /obj/item/reagent_containers/food/drinks/flask, + /obj/item/storage/bag/plants, // remove if it gets abused to breaking somehow + /obj/item/plant_analyzer, // out of place but mechanically useful for the foreseeable future, so included for QoL + )) + STR.can_hold = can_hold +/* +// Primitive medical belt, meant to be part of a ghetto surgery improvement at some point Newer version in Invicta /obj/item/storage/belt/medical/primitive name = "primitive medical toolbelt" desc = "This might look a bit like a toolbelt for a carpenter, but the items inside are meant to be used in surgery. No really." @@ -220,7 +237,7 @@ new /obj/item/hemostat(src) new /obj/item/weldingtool/basic(src) new /obj/item/bonesetter(src) - +*/ ////////////////// /// Generic belts @@ -275,6 +292,14 @@ icon_state = "militarywebbing" item_state = "militarywebbing" slot_flags = ITEM_SLOT_BELT + +// --------------------------------------------- +// BANDOLIER - since TG style bandolier was useless, now takes 3 boxes of shotgun ammo, or flasks, or grenades, or improvised bombs/molotovs +/obj/item/storage/belt/bandolier + name = "bandolier" + desc = "A bandolier for holding shotgun boxes, flasks, las musket cells or various grenades." + icon_state = "bandolier" + item_state = "bandolier" rad_flags = RAD_PROTECT_CONTENTS | RAD_NO_CONTAMINATE component_type = /datum/component/storage/concrete/belt/specialized/bandolier @@ -691,7 +716,18 @@ w_class = WEIGHT_CLASS_BULKY content_overlays = TRUE onmob_overlays = TRUE - slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_BACK + slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_NECK + fitting_swords = list( + /obj/item/melee/smith/wakizashi, + /obj/item/twohanded/smithed/katana, + /obj/item/melee/onehanded/machete, + /obj/item/melee/onehanded/club, + /obj/item/melee/classic_baton, + /obj/item/twohanded/fireaxe, + /obj/item/twohanded/baseball, + /obj/item/twohanded/sledgehammer/simple, + /obj/item/melee/transforming/energy/axe/protonaxe, + /obj/item/melee/powered/ripper) starting_sword = null /obj/item/storage/belt/sabre/heavy/ComponentInitialize() @@ -747,6 +783,8 @@ content_overlays = TRUE onmob_overlays = TRUE slot_flags = ITEM_SLOT_NECK + var/list/fitting_swords = list(/obj/item/melee/smith/sword, /obj/item/melee/baton/stunsword) + var/starting_sword = null /obj/item/storage/belt/sword/ComponentInitialize() . = ..() @@ -756,14 +794,15 @@ STR.max_combined_w_class = 3 STR.can_hold = typecacheof(list(/obj/item/melee, /obj/item/twohanded)) STR.quickdraw = TRUE - + // Instead of half-assed broken weaboo stuff lets have something that works. /obj/item/storage/belt/sword/twin name = "daishō" desc = "A set of sheathes and straps for carrying two curved japanese style swords." icon_state = "sheath_twin" item_state = "sheath_twin" - slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_BACK + fitting_swords = list(/obj/item/melee/smith/wakizashi, /obj/item/twohanded/smithed/katana, /obj/item/melee/bokken) + starting_sword = null /obj/item/storage/belt/sword/twin/ComponentInitialize() . = ..() diff --git a/code/game/objects/structures/crates_lockers/crates.dm b/code/game/objects/structures/crates_lockers/crates.dm index d81087c3a89..6dd99605b92 100644 --- a/code/game/objects/structures/crates_lockers/crates.dm +++ b/code/game/objects/structures/crates_lockers/crates.dm @@ -115,11 +115,15 @@ desc = "Low metal locker for personal effects." name = "footlocker" icon_state = "footlocker" + dense_when_open = FALSE /obj/structure/closet/crate/footchest desc = "A wooden chest with iron bands." name = "personal chest" icon_state = "footchest" + open_sound = 'modular_BD2/general/sound/creak.ogg' + close_sound = 'modular_BD2/general/sound/creak.ogg' + dense_when_open = FALSE /obj/structure/closet/crate/internals desc = "An internals crate." diff --git a/code/modules/WVM/items.dm b/code/modules/WVM/items.dm index b4123fa6be6..7c8266309c8 100644 --- a/code/modules/WVM/items.dm +++ b/code/modules/WVM/items.dm @@ -7,6 +7,10 @@ icon = 'icons/fallout/vehicles/small_vehicles.dmi' icon_state = "key-door" var/id = 0 + +/obj/item/key/vending/jukebox //ATOM EDIT used exclusively to open a jukebox + name = "Jukebox's Access Key" + desc = "a key to open the disk tray of a jukebox."//ATOM EDIT -end- /obj/item/key/vending/proc/set_name(newname) if(name != newname) diff --git a/code/modules/antagonists/cult/cult_structures.dm b/code/modules/antagonists/cult/cult_structures.dm index 22c298aded0..4a8c03ea33d 100644 --- a/code/modules/antagonists/cult/cult_structures.dm +++ b/code/modules/antagonists/cult/cult_structures.dm @@ -178,10 +178,10 @@ if(!iscultist(user)) to_chat(user, span_warning("The heat radiating from [src] pushes you back.")) return - if(istype(I, /obj/item/ingot)) - var/obj/item/ingot/notsword = I - to_chat(user, "You heat the [notsword] in the [src].") - notsword.workability = "shapeable" + if(istype(I, /obj/item/blacksmith/ingot)) + var/obj/item/blacksmith/ingot/workpiece = I + to_chat(user, "You heat the [workpiece] in the [src].") + workpiece.workability = "shapeable" /obj/structure/destructible/cult/pylon name = "pylon" diff --git a/code/modules/cargo/exports/materials.dm b/code/modules/cargo/exports/materials.dm index 3d92843d006..e6f378e4bff 100644 --- a/code/modules/cargo/exports/materials.dm +++ b/code/modules/cargo/exports/materials.dm @@ -85,7 +85,7 @@ material_id = /datum/material/adamantine message = "cm3 of pre-war ingots" export_types = list(/obj/item/stack/sheet/mineral/adamantine, - /obj/item/ingot/adamantine) + /obj/item/blacksmith/ingot/adamantine) /* /datum/export/material/prewar cost = 15 diff --git a/code/modules/cargo/packs/materials.dm b/code/modules/cargo/packs/materials.dm index 9fd21f609c3..45220606b48 100644 --- a/code/modules/cargo/packs/materials.dm +++ b/code/modules/cargo/packs/materials.dm @@ -67,9 +67,9 @@ name = "4 Pre-War Ingots" desc = "Ingots salvaged from a Pre-War factory, valuable in the right hands." cost = 2775 - contains = list(/obj/item/ingot/adamantine, - /obj/item/ingot/adamantine, - /obj/item/ingot/adamantine + contains = list(/obj/item/blacksmith/ingot/adamantine, + /obj/item/blacksmith/ingot/adamantine, + /obj/item/blacksmith/ingot/adamantine ) /datum/supply_pack/materials/weaponparts diff --git a/code/modules/cargo/packs/misc.dm b/code/modules/cargo/packs/misc.dm index efdcbb2915b..0da237737ca 100644 --- a/code/modules/cargo/packs/misc.dm +++ b/code/modules/cargo/packs/misc.dm @@ -16,9 +16,9 @@ /datum/supply_pack/misc/anvil name = "Anvil Crate" - desc = "An anvil in a crate. It's got wheels on it so you can move it." - cost = 2500 - contains = list(/obj/structure/anvil/obtainable/basic) + desc = "An anvil in a crate, we had to dig this out of the old warehouse. It's got wheels on it so you can move it." + cost = 7500 + contains = list(/obj/structure/blacksmith/anvil/obtainable) /datum/supply_pack/misc/artsupply name = "Art Supplies" diff --git a/code/modules/client/client_procs.dm b/code/modules/client/client_procs.dm index 62f07425097..1e14ba347d7 100644 --- a/code/modules/client/client_procs.dm +++ b/code/modules/client/client_procs.dm @@ -1,7 +1,7 @@ //////////// //SECURITY// //////////// -#define UPLOAD_LIMIT 1048576 //Restricts client uploads to the server to 1MB //Could probably do with being lower. +#define UPLOAD_LIMIT 4194304 //Restricts client uploads to the server to 1MB //Could probably do with being lower. BIG IRON EDIT changed it to 4mb,since 1mb is almost unusable GLOBAL_LIST_INIT(blacklisted_builds, list( "1407" = "bug preventing client display overrides from working leads to clients being able to see things/mobs they shouldn't be able to see", diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index 83f5560b91f..003f60d96d6 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -534,6 +534,7 @@ GLOBAL_LIST_EMPTY(preferences_datums) dat += "
    " dat += "Play Admin MIDIs: [(toggles & SOUND_MIDI) ? "Enabled":"Disabled"]
    " dat += "Play Lobby Music: [(toggles & SOUND_LOBBY) ? "Enabled":"Disabled"]
    " + dat += "Stream radio music: [(toggles & MUSIC_RADIO) ? "Enabled":"Disabled"]
    " dat += "See Pull Requests: [(chat_toggles & CHAT_PULLR) ? "Enabled":"Disabled"]
    " dat += "
    " if(user.client) @@ -1942,6 +1943,9 @@ GLOBAL_LIST_EMPTY(preferences_datums) if("ghost_ears") chat_toggles ^= CHAT_GHOSTEARS + if("music_streaming") + toggles ^= MUSIC_RADIO + if("ghost_sight") chat_toggles ^= CHAT_GHOSTSIGHT diff --git a/code/modules/client/preferences_toggles.dm b/code/modules/client/preferences_toggles.dm index f24e614d054..5344da7d931 100644 --- a/code/modules/client/preferences_toggles.dm +++ b/code/modules/client/preferences_toggles.dm @@ -234,6 +234,19 @@ TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, toggleprayersounds)() C?.tgui_panel?.stop_music() SSblackbox.record_feedback("nested tally", "preferences_verb", 1, list("Stop Self Sounds")) //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! +TOGGLE_CHECKBOX(/datum/verbs/menu/Settings/Sound, toggleradiomusic)() + set name = "Hear/Silence Radio Music" + set category = "Preferences" + set desc = "Hear music streamed by radio stations" + usr.client.prefs.toggles ^= MUSIC_RADIO + usr.client.prefs.save_preferences() + if(usr.client.prefs.toggles & MUSIC_RADIO) + to_chat(usr, "You will now hear songs through radios.") + else + to_chat(usr, "You will no longer hear sounds played in radios") + SSblackbox.record_feedback("nested tally", "preferences_verb", 1, list("Toggle Radio Music", "[usr.client.prefs.toggles & MUSIC_RADIO ? "Enabled" : "Disabled"]")) //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! +/datum/verbs/menu/Settings/Sound/toggleradiomusic/Get_checked(client/C) + return C.prefs.toggles & MUSIC_RADIO TOGGLE_CHECKBOX(/datum/verbs/menu/Settings, listen_ooc)() set name = "Show/Hide OOC" diff --git a/code/modules/clothing/gloves/f13gloves.dm b/code/modules/clothing/gloves/f13gloves.dm index a640df8eeda..87c65167779 100644 --- a/code/modules/clothing/gloves/f13gloves.dm +++ b/code/modules/clothing/gloves/f13gloves.dm @@ -155,19 +155,22 @@ ////////// /obj/item/clothing/gloves/legion - name = "leather gloves" - desc = "Fingerless leather gloves to improve grip." - icon = 'icons/fallout/clothing/gloves.dmi' - mob_overlay_icon = 'icons/fallout/onmob/clothes/hand.dmi' - icon_state = "legion_fingerless" - item_state = "legion_fingerless" + name = "fingerless gloves" + desc = "Improves the grip on a machete even when slick with blood, widely used by Legion warriors." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "gloves_fingerless" + item_state = "gloves_fingerless" + item_color = null //So they don't wash. transfer_prints = TRUE strip_delay = 40 equip_delay_other = 20 cold_protection = HANDS min_cold_protection_temperature = GLOVES_MIN_TEMP_PROTECT - armor = ARMOR_VALUE_LIGHT + /obj/item/clothing/gloves/legion/forgemaster name = "forgemaster gloves" @@ -182,9 +185,9 @@ /obj/item/clothing/gloves/legion/plated name = "plated gloves" - desc = "Leather gloves with metal reinforcement." - icon_state = "legion_plated" - item_state = "legion_plated" + desc = "Leather gloves with metal reinforcements." + icon_state = "gloves_plated" + item_state = "gloves_plated" transfer_prints = FALSE armor_tokens = list(ARMOR_MODIFIER_UP_MELEE_T1, ARMOR_MODIFIER_UP_ENV_T1, ARMOR_MODIFIER_UP_DT_T1) diff --git a/code/modules/clothing/head/f13factionhead.dm b/code/modules/clothing/head/f13factionhead.dm index 6a48e6d4137..c5368c9c924 100644 --- a/code/modules/clothing/head/f13factionhead.dm +++ b/code/modules/clothing/head/f13factionhead.dm @@ -341,9 +341,13 @@ obj/item/clothing/head/helmet/f13/enclave/usmcriot /obj/item/clothing/head/helmet/f13/legion/vet/explorer name = "legion scout hood" desc = "It's a leather hood with metal reinforcments and built in headphones to plug the radio into." - icon_state = "legion-explorer" - item_state = "legion-explorer" - armor_tokens = list() + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "helmet_explorer" + item_state = "helmet_explorer" + armor = list("melee" = 30, "bullet" = 25, "laser" = 5, "energy" = 10, "bomb" = 40, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) /obj/item/clothing/head/helmet/f13/legion/vet/combvexil name = "legion bear vexillarius helmet" @@ -376,6 +380,8 @@ obj/item/clothing/head/helmet/f13/enclave/usmcriot /obj/item/clothing/head/helmet/f13/legion/orator name = "laurel wreath" desc = "A laurel wreath is made of branches and leaves of the laurel, a type of evergreen shrub or small tree. This one appears to be out of metal,however. In Ancient Rome, it was worn on the head as a symbol of triumph." + icon = 'icons/fallout/clothing/hats.dmi' + mob_overlay_icon = 'icons/fallout/onmob/clothes/head.dmi' icon_state = "legion-orator" item_state = "legion-orator" flags_inv = null @@ -383,6 +389,8 @@ obj/item/clothing/head/helmet/f13/enclave/usmcriot /obj/item/clothing/head/helmet/f13/legion/recruit/decan name = "legion recruit decanus helmet" desc = "This reinforced leather helmet has a plume of black and dark red feathers." + icon = 'icons/fallout/clothing/hats.dmi' + mob_overlay_icon = 'icons/fallout/onmob/clothes/head.dmi' icon_state = "legion-decrec" item_state = "legion-decrec" armor_tokens = list(ARMOR_MODIFIER_UP_MELEE_T2) @@ -390,6 +398,8 @@ obj/item/clothing/head/helmet/f13/enclave/usmcriot /obj/item/clothing/head/helmet/f13/legion/prime/decan name = "legion prime decanus helmet" desc = "This reinforced leather helmet with a red peak has a plume of black feathers." + icon = 'icons/fallout/clothing/hats.dmi' + mob_overlay_icon = 'icons/fallout/onmob/clothes/head.dmi' item_state = "legion-decprime" icon_state = "legion-decprime" armor_tokens = list(ARMOR_MODIFIER_UP_MELEE_T1, ARMOR_MODIFIER_UP_DT_T1) @@ -462,11 +472,14 @@ obj/item/clothing/head/helmet/f13/enclave/usmcriot /obj/item/clothing/head/f13/servant name = "servant headwear" desc = "A simple uncoloured linen cloth wrapped around the head, the mark of a servant slave trained in household work." - icon = 'icons/fallout/clothing/hats.dmi' - mob_overlay_icon = 'icons/fallout/onmob/clothes/head.dmi' - icon_state = "legion-servant" - item_state = "legion-servant" - flags_inv = HIDEEARS + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "hat_servant" + item_state = "hat_servant" + dynamic_hair_suffix = "+generic" + flags_inv = null flags_cover = null /obj/item/clothing/head/f13/auxilia diff --git a/code/modules/clothing/outfits/standard.dm b/code/modules/clothing/outfits/standard.dm index 982694ec59a..6078534b5f3 100644 --- a/code/modules/clothing/outfits/standard.dm +++ b/code/modules/clothing/outfits/standard.dm @@ -187,7 +187,7 @@ head = /obj/item/clothing/head/centhat belt = /obj/item/gun/ballistic/revolver/m29/snub r_pocket = /obj/item/lighter - l_pocket = /obj/item/ammo_box/a357 + l_pocket = /obj/item/ammo_box/tube/m44 back = /obj/item/storage/backpack/satchel/leather id = /obj/item/card/id @@ -359,7 +359,7 @@ ears = /obj/item/radio/headset/headset_cent/alt backpack_contents = list(/obj/item/storage/box=1,\ - /obj/item/ammo_box/a357=1,\ + /obj/item/ammo_box/tube/m44=1,\ /obj/item/storage/firstaid/regular=1,\ /obj/item/storage/box/flashbangs=1,\ /obj/item/flashlight=1,\ @@ -402,25 +402,59 @@ name = "Debug outfit" uniform = /obj/item/clothing/under/misc/patriotsuit suit = /obj/item/clothing/suit/space/hardsuit/syndi/elite/debug - glasses = /obj/item/clothing/glasses/debug - ears = /obj/item/radio/headset/headset_cent/commander + glasses = /obj/item/clothing/glasses/hud/health/sunglasses + ears = /obj/item/radio/headset/headset_cent/alt mask = /obj/item/clothing/mask/gas/welding/up gloves = /obj/item/clothing/gloves/tackler/combat/insulated - l_pocket = /obj/item/gun/magic/wand/resurrection/debug - r_pocket = /obj/item/gun/magic/wand/death/debug shoes = /obj/item/clothing/shoes/magboots/advance/debug + belt = /obj/item/storage/belt/utility/full/engi id = /obj/item/card/id/debug - suit_store = /obj/item/tank/internals/oxygen + suit_store = /obj/item/tank/internals/emergency_oxygen/double back = /obj/item/storage/backpack/holding box = /obj/item/storage/box/debugtools - internals_slot = ITEM_SLOT_SUITSTORE + neck = /obj/item/storage/belt/shoulderholster/ranger4570bayonet + l_pocket = /obj/item/ammo_box/tube/m44 + r_pocket = /obj/item/gun/ballistic/revolver/m29/snub backpack_contents = list( /obj/item/melee/transforming/energy/axe=1,\ /obj/item/storage/part_replacer/bluespace/tier4=1,\ /obj/item/debug/human_spawner=1,\ + /obj/item/gun/magic/wand/death/debug=1,\ + /obj/item/gun/magic/wand/resurrection/debug=1,\ + /obj/item/clothing/glasses/debug=1,\ + /obj/item/gun/energy/pulse/pistol=1,\ + /obj/item/holosign_creator/security=1,\ + /obj/item/storage/firstaid/tactical/nukeop=1,\ + /obj/item/ammo_box/magazine/m473=2,\ + /obj/item/gun/ballistic/automatic/g11=1,\ ) -/datum/outfit/debug/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE) +/datum/outfit/debug/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE, client/preference_source) + if(visualsOnly) + return + ADD_TRAIT(H, TRAIT_XRAY_VISION, src) + ADD_TRAIT(H, TRAIT_PA_WEAR, src) + ADD_TRAIT(H, TRAIT_SURGERY_HIGH, src) + ADD_TRAIT(H, TRAIT_HARD_YARDS, src) + ADD_TRAIT(H, TRAIT_MEDICALEXPERT, src) + ADD_TRAIT(H, TRAIT_NIGHT_VISION, src) + ADD_TRAIT(H, TRAIT_NOLIMBDISABLE, src) + ADD_TRAIT(H, TRAIT_SILENT_STEP, src) + ADD_TRAIT(H, TRAIT_SHOCKIMMUNE, src) + ADD_TRAIT(H, TRAIT_PERFECT_ATTACKER, src) + if(H.mind) + H.mind.AddSpell(new /obj/effect/proc_holder/spell/terrifying_presence) + H.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift/golem) + H.mind.AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/knock) + H.mind.AddSpell(new /obj/effect/proc_holder/spell/voice_of_god) + + var/obj/item/implant/mindshield/L = new + L.implant(H, null, 1) + var/obj/item/card/id/W = H.wear_id + W.icon_state = "centcom" + W.access = get_all_accesses()//Obviously + W.assignment = "Chronicler" W.registered_name = H.real_name - W.update_label() + W.update_label(W.registered_name, W.assignment) + diff --git a/code/modules/clothing/spacesuits/hardsuit.dm b/code/modules/clothing/spacesuits/hardsuit.dm index 5dc228e2a88..c95f3ae5d3d 100644 --- a/code/modules/clothing/spacesuits/hardsuit.dm +++ b/code/modules/clothing/spacesuits/hardsuit.dm @@ -346,10 +346,14 @@ resistance_flags = FIRE_PROOF | ACID_PROOF /obj/item/clothing/head/helmet/space/hardsuit/syndi/elite/debug + name = "chronicler helmet" + armor = list("melee" = 99, "bullet" = 95, "laser" = 95, "energy" = 95, "bomb" = 95, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100, "wound" = 100) /obj/item/clothing/head/helmet/space/hardsuit/syndi/elite/debug/Initialize() . = ..() - soundloop.volume = 0 + do_sparks(7, FALSE, src)//spawns in, lightning effect also produced, what this mean is upto you + playsound(src, "sparks", 100, 1) + soundloop.volume = 0.5 /obj/item/clothing/suit/space/hardsuit/syndi/elite name = "elite syndicate hardsuit" @@ -364,8 +368,10 @@ mutantrace_variation = STYLE_DIGITIGRADE /obj/item/clothing/suit/space/hardsuit/syndi/elite/debug + name = "chronicler hardsuit" helmettype = /obj/item/clothing/head/helmet/space/hardsuit/syndi/elite/debug slowdown = 0 + armor = list("melee" = 99, "bullet" = 95, "laser" = 95, "energy" = 95, "bomb" = 95, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100, "wound" = 100) //The Owl Hardsuit /obj/item/clothing/head/helmet/space/hardsuit/syndi/owl diff --git a/code/modules/clothing/suits/armor.dm b/code/modules/clothing/suits/armor.dm index d80ea63ed2a..ec19304a4c6 100644 --- a/code/modules/clothing/suits/armor.dm +++ b/code/modules/clothing/suits/armor.dm @@ -383,11 +383,11 @@ Suits. 0-10 in its primary value, slowdown 0, various utility /obj/item/clothing/suit/armor/light/tribal/legion slowdown = 0 - allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) /obj/item/clothing/suit/armor/light/tribal slowdown = 0 - allowed = list(/obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) // Medium armor. 35-45 in its primary value, slowdown 0.1 @@ -401,11 +401,11 @@ Suits. 0-10 in its primary value, slowdown 0, various utility /obj/item/clothing/suit/armor/medium/legion slowdown = 0.05 - allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) /obj/item/clothing/suit/armor/medium/tribal slowdown = 0.05 - allowed = list(/obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) // Heavy armor. 50-65 in its primary value, slowdown 0.15 @@ -414,7 +414,7 @@ Suits. 0-10 in its primary value, slowdown 0, various utility icon = 'icons/fallout/clothing/armored_heavy.dmi' mob_overlay_icon = 'icons/fallout/onmob/clothes/armor_heavy.dmi' slowdown = 0.15 - allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) strip_delay = 50 /obj/item/clothing/suit/armor/heavy/legion diff --git a/code/modules/clothing/suits/f13factionarmor.dm b/code/modules/clothing/suits/f13factionarmor.dm index 2bba7f46bfb..d8e639678bf 100644 --- a/code/modules/clothing/suits/f13factionarmor.dm +++ b/code/modules/clothing/suits/f13factionarmor.dm @@ -189,7 +189,7 @@ icon_state = "legrecruit" item_state = "legarmor" body_parts_covered = CHEST|GROIN|ARMS|LEGS - allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/throwing_star/spear, /obj/item/restraints/legcuffs/bola, /obj/item/twohanded, /obj/item/melee/powered, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/throwing_star/spear, /obj/item/restraints/legcuffs/bola, /obj/item/twohanded, /obj/item/melee/powered, /obj/item/melee/smith, /obj/item/twohanded/smithed) armor = list("melee" = 30, "bullet" = 30, "laser" = 10, "energy" = 10, "bomb" = 15, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) slowdown = 0.05 pocket_storage_component_path = /datum/component/storage/concrete/pockets/tiny/legion @@ -205,22 +205,30 @@ /obj/item/clothing/suit/armor/legion/recruit name = "legion recruit armor" desc = "Well, it's better than nothing." - icon_state = "legion_recruit" - item_state = "legion_recruit" - armor = list("melee" = 33, "bullet" = 25, "laser" = 5, "energy" = 10, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "armor_recruit" + item_state = "armor_recruit" + armor = list("melee" = 30, "bullet" = 15, "laser" = 5, "energy" = 10, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) slowdown = 0.04 -/obj/item/clothing/suit/armor/legion/recruit/decan - name = "legion recruit armor" +/obj/item/clothing/suit/armor/f13/legion/recruit/decan + name = "legion recruit decanus armor" desc = "Recruit decanii receive slightly better protection than regular recruits. Slightly." armor = list("melee" = 45, "bullet" = 30, "laser" = 5, "energy" = 10, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) /obj/item/clothing/suit/armor/legion/prime name = "legion prime armor" desc = "Legion Primes have survived some skirmishes, and when promoted often recieve a set of armor, padded leather modeled on ancient baseball catcher uniforms and various plates of metal or boiled leather." - icon_state = "legion_prime" - item_state = "legion_prime" - armor = list("melee" = 45, "bullet" = 30, "laser" = 10, "energy" = 10, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "armor_prime" + item_state = "armor_prime" + armor = list("melee" = 40, "bullet" = 25, "laser" = 10, "energy" = 10, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) /obj/item/clothing/suit/armor/legion/prime/decan name = "legion prime decanus armor" @@ -243,11 +251,13 @@ /obj/item/clothing/suit/armor/legion/vet name = "legion veteran armor" desc = "Armor worn by veterans, salvaged bits of enemy armor and scrap metal often reinforcing the armor." - icon = 'icons/fallout/clothing/armored_medium.dmi' - mob_overlay_icon = 'icons/fallout/onmob/clothes/armor_medium.dmi' - icon_state = "legion_veteran" - item_state = "legion_veteran" - armor = list("melee" = 67, "bullet" = 37, "laser" = 25, "energy" = 15, "bomb" = 30, "bio" = 5, "rad" = 5, "fire" = 35, "acid" = 0, "wound" = 40) + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "armor_veteran" + item_state = "armor_veteran" + armor = list("melee" = 50, "bullet" = 30, "laser" = 10, "energy" = 15, "bomb" = 30, "bio" = 5, "rad" = 5, "fire" = 35, "acid" = 0, "wound" = 40) slowdown = 0.05 salvage_loot = list(/obj/item/stack/crafting/armor_plate = 4) // Slightly better armor @@ -265,20 +275,22 @@ /obj/item/clothing/suit/armor/legion/vet/explorer name = "legion scout armor" desc = "Armor based on layered strips of laminated linen and leather, the technique giving it surprising resilience for low weight." - icon = 'icons/fallout/clothing/armored_light.dmi' - mob_overlay_icon = 'icons/fallout/onmob/clothes/armor_light.dmi' - icon_state = "legion_explorer" - item_state = "legion_explorer" - armor = list("melee" = 45, "bullet" = 35, "laser" = 15, "energy" = 10, "bomb" = 40, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "armor_explorer" + item_state = "armor_explorer" + armor = list("melee" = 30, "bullet" = 25, "laser" = 5, "energy" = 10, "bomb" = 40, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) slowdown = 0.03 /obj/item/clothing/suit/armor/legion/vet/vexil name = "legion vexillarius armor" icon = 'icons/fallout/clothing/armored_medium.dmi' desc = " Worn by Vexillarius, this armor has been reinforced with circular metal plates on the chest and a back mounted pole for the flag of the Bull, making the wearer easy to see at a distance." - icon_state = "legion_vex" - item_state = "legion_vex" - armor = list("melee" = 70, "bullet" = 37, "laser" = 42, "energy" = 20, "bomb" = 25, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) + icon_state = "armor_vexillarius" + item_state = "armor_vexillarius" + armor = list("melee" = 50, "bullet" = 35, "laser" = 20, "energy" = 20, "bomb" = 25, "bio" = 20, "rad" = 20, "fire" = 25, "acid" = 0, "wound" = 40) slowdown = 0.12 /obj/item/clothing/suit/armor/legion/venator diff --git a/code/modules/clothing/suits/heavy_armor.dm b/code/modules/clothing/suits/heavy_armor.dm index 2e1cefd3af8..edd0991bf7f 100644 --- a/code/modules/clothing/suits/heavy_armor.dm +++ b/code/modules/clothing/suits/heavy_armor.dm @@ -61,7 +61,7 @@ icon_state = "tribal_heavy" item_state = "tribal_heavy" armor = list("melee" = 55, "bullet" = 20, "laser" = 25, "energy" = 20, "bomb" = 45, "bio" = 5, "rad" = 10, "fire" = 30, "acid" = 10) - allowed = list(/obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) ////////////////////////// // Salvaged Power Armor // @@ -183,7 +183,7 @@ name = "legion centurion armor" desc = "The Legion centurion armor is by far the strongest suit of armor available to Caesar's Legion. The armor is composed from other pieces of armor taken from that of the wearer's defeated opponents in combat." icon_state = "legion_centurion" - armor = list("melee" = 70, "bullet" = 50, "laser" = 35, "energy" = 35, "bomb" = 40, "bio" = 30, "rad" = 25, "fire" = 40, "acid" = 10) + armor = list("melee" = 70, "bullet" = 50, "laser" = 35, "energy" = 35, "bomb" = 40, "bio" = 30, "rad" = 25, "fire" = 40, "acid" = 10, "wound" = 55) /obj/item/clothing/suit/armor/heavy/legion/palacent name = "paladin-slayer centurion armor" @@ -239,7 +239,7 @@ icon_state = "tribal_power_armor" item_state = "tribal_power_armor" armor = list("melee" = 65, "bullet" = 65, "laser" = 45, "energy" = 40, "bomb" = 45, "bio" = 30, "rad" = 30, "fire" = 60, "acid" = 10) - allowed = list(/obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) /obj/item/clothing/suit/armor/heavy/environmental diff --git a/code/modules/clothing/suits/light_armor.dm b/code/modules/clothing/suits/light_armor.dm index 94306cb51a6..7207217a7b0 100644 --- a/code/modules/clothing/suits/light_armor.dm +++ b/code/modules/clothing/suits/light_armor.dm @@ -169,7 +169,7 @@ item_state = "tribal_outcast" heat_protection = CHEST | GROIN | LEGS| ARMS | HEAD armor = list("melee" = 30, "bullet" = 20, "laser" = 15, "energy" = 10, "bomb" = 5, "bio" = 0, "rad" = 0, "fire" = 15, "acid" = 0) - allowed = list(/obj/item/gun, /obj/item/kitchen, /obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/twohanded/spear, /obj/item/melee/smith, /obj/item/melee/smith/twohand + allowed = list(/obj/item/gun, /obj/item/kitchen, /obj/item/twohanded, /obj/item/melee/onehanded, /obj/item/twohanded/spear, /obj/item/melee/smith, /obj/item/twohanded/smithed ) /obj/item/clothing/suit/hooded/outcast diff --git a/code/modules/clothing/suits/medium_armor.dm b/code/modules/clothing/suits/medium_armor.dm index 3941cc72ef7..762f7a48f64 100644 --- a/code/modules/clothing/suits/medium_armor.dm +++ b/code/modules/clothing/suits/medium_armor.dm @@ -416,7 +416,7 @@ item_state = "mutie_heavy_metal" armor = list("melee" = 40, "bullet" = 30, "laser" = 15, "energy" = 15, "bomb" = 30, "bio" = 0, "rad" = 5, "fire" = 10, "acid" = 0) slowdown = 0.1 - allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/melee/smith/twohand) + allowed = list(/obj/item/gun, /obj/item/melee/onehanded, /obj/item/twohanded, /obj/item/melee/smith, /obj/item/twohanded/smithed) /obj/item/clothing/suit/armor/medium/motorball name = "motorball suit" diff --git a/code/modules/farming/farming_tools.dm b/code/modules/farming/farming_tools.dm index 2cd5a6a27f1..5b5af8df8a2 100644 --- a/code/modules/farming/farming_tools.dm +++ b/code/modules/farming/farming_tools.dm @@ -223,12 +223,13 @@ /obj/structure/closet/crate/wicker name = "basket" desc = "A handmade wicker basket." - icon = 'icons/fallout/farming/farming_tools.dmi' + icon = 'icons/obj/crates.dmi' icon_state = "basket" resistance_flags = FLAMMABLE - material_drop = /obj/item/stack/sheet/hay material_drop_amount = 15 - + open_sound = 'sound/effects/rustle3.ogg' + close_sound = 'sound/effects/rustle3.ogg' + material_drop = /obj/item/stack/sheet/hay // ------------------------------------ diff --git a/code/modules/jobs/job_types/legion.dm b/code/modules/jobs/job_types/legion.dm index e767ea12819..e8b62dd0dca 100644 --- a/code/modules/jobs/job_types/legion.dm +++ b/code/modules/jobs/job_types/legion.dm @@ -41,15 +41,14 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al H.mind.teach_crafting_recipe(/datum/crafting_recipe/bitterdrink5) /datum/outfit/job/CaesarsLegion/Legionnaire - belt = /obj/item/storage/belt/army/assault/legion + belt = /obj/item/storage/belt/military/legion ears = /obj/item/radio/headset/headset_legion - backpack = /obj/item/storage/backpack/explorer + backpack = /obj/item/storage/backpack/marching_satchel satchel = /obj/item/storage/backpack/satchel/explorer uniform = /obj/item/clothing/under/f13/legskirt shoes = /obj/item/clothing/shoes/f13/military/legion gloves = /obj/item/clothing/gloves/legion - box = /obj/item/storage/survivalkit/tribal - box_two = /obj/item/storage/survivalkit/medical/tribal + box = /obj/item/storage/survivalkit/legion_rations /datum/outfit/job/CaesarsLegion/Legionnaire/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE) ..() @@ -225,14 +224,14 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13centurion name = "Legion Centurion" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13centurion - id = /obj/item/card/id/dogtag/legcenturion - mask = /obj/item/clothing/mask/bandana/legion/legcenturion + id = /obj/item/card/id/dogtag/legion/centurion + mask = /obj/item/clothing/mask/bandana/legion/centurion ears = /obj/item/radio/headset/headset_legion/cent - neck = /obj/item/clothing/neck/mantle/legion + neck = /obj/item/storage/belt/holster gloves = /obj/item/clothing/gloves/legion/plated glasses = /obj/item/clothing/glasses/night/polarizing shoes = /obj/item/clothing/shoes/f13/military/plated - r_pocket = /obj/item/restraints/handcuffs + r_pocket = /obj/item/storage/survivalkit/medical/legion l_pocket = /obj/item/flashlight/lantern box = /obj/item/storage/survivalkit/tribal/chief box_two = /obj/item/storage/survivalkit/medical/tribal @@ -273,11 +272,15 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al head = /obj/item/clothing/head/helmet/f13/legion/centurion suit_store = /obj/item/gun/ballistic/automatic/pistol/pistol14 backpack_contents = list( - /obj/item/melee/powerfist/f13/goliath = 1, - /obj/item/ammo_box/magazine/m14mm = 3, + /obj/item/storage/belt/holster = 1, + /obj/item/gun/ballistic/automatic/pistol/pistol14 = 1, + /obj/item/ammo_box/magazine/m14mm = 2, + /obj/item/ammo_box/shotgun/slug = 1, + /obj/item/ammo_box/shotgun/magnum = 2, ) -// VETERAN DECANUS + +// ----------------- VETERAN DECANUS --------------------- /datum/job/CaesarsLegion/Legionnaire/f13decanvet title = "Legion Veteran Decanus" @@ -321,9 +324,9 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al ears = /obj/item/radio/headset/headset_legion/cent glasses = /obj/item/clothing/glasses/sunglasses/big shoes = /obj/item/clothing/shoes/f13/military/plated - r_pocket = /obj/item/flashlight/lantern - box = /obj/item/storage/survivalkit/tribal/chief - box_two = /obj/item/storage/survivalkit/medical/tribal + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern + backpack_contents = list( /obj/item/ammo_box/a357 = 1, /obj/item/gun/ballistic/revolver/colt357 = 1, @@ -420,14 +423,12 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al id = /obj/item/card/id/dogtag/legveteran suit = /obj/item/clothing/suit/armor/legion/prime/decan head = /obj/item/clothing/head/helmet/f13/legion/prime/decan - mask = /obj/item/clothing/mask/bandana/legion/legdecan - neck = /obj/item/storage/belt/shoulderholster - glasses = /obj/item/clothing/glasses/legiongoggles + mask = /obj/item/clothing/mask/bandana/legion + glasses = /obj/item/clothing/glasses/f13/goggles_sandstorm shoes = /obj/item/clothing/shoes/f13/military/plated - r_pocket = /obj/item/flashlight/lantern - l_pocket = /obj/item/restraints/handcuffs + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern box = /obj/item/storage/survivalkit/tribal/chief - box_two = /obj/item/storage/survivalkit/medical/tribal backpack_contents = list( /obj/item/melee/onehanded/machete/gladius = 1, // /obj/item/storage/bag/money/small/legofficers = 1, @@ -509,15 +510,13 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13decanrec name = "Legion Recruit Decanus" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13decanrec - id = /obj/item/card/id/dogtag/legveteran + id = /obj/item/card/id/dogtag/legion suit = /obj/item/clothing/suit/armor/legion/recruit/decan head = /obj/item/clothing/head/helmet/f13/legion/recruit/decan - mask = /obj/item/clothing/mask/bandana/legion/legdecan - neck = /obj/item/storage/belt/shoulderholster - glasses = /obj/item/clothing/glasses/legiongoggles - r_pocket = /obj/item/flashlight/lantern - box = /obj/item/storage/survivalkit/tribal/chief - box_two = /obj/item/storage/survivalkit/medical/tribal + mask = /obj/item/clothing/mask/bandana/legion + glasses = /obj/item/clothing/glasses/f13/goggles_sandstorm + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern backpack_contents = list( /obj/item/reagent_containers/pill/patch/healpoultice = 1, /obj/item/restraints/handcuffs = 1, @@ -594,13 +593,14 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13vexillarius name = "Vexillarius" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13vexillarius - id = /obj/item/card/id/dogtag/legveteran + id = /obj/item/card/id/dogtag/legion/veteran suit = /obj/item/clothing/suit/armor/legion/vet/vexil - mask = /obj/item/clothing/mask/bandana/legion/legvet - neck = /obj/item/storage/belt/shoulderholster + mask = /obj/item/clothing/mask/bandana/legion + neck = /obj/item/storage/belt/holster glasses = /obj/item/clothing/glasses/sunglasses gloves = /obj/item/clothing/gloves/legion/plated - r_pocket = /obj/item/flashlight/lantern + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern backpack_contents = list( /obj/item/reagent_containers/pill/patch/healpoultice = 1, /obj/item/restraints/handcuffs = 1, @@ -677,7 +677,7 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13explorer name = "Legion Explorer" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13explorer - id = /obj/item/card/id/dogtag/legprime + id = /obj/item/card/id/dogtag/legion/prime suit = /obj/item/clothing/suit/armor/legion/vet/explorer head = /obj/item/clothing/head/helmet/f13/legion/vet/explorer neck = /obj/item/storage/belt/shoulderholster @@ -690,6 +690,8 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al // /obj/item/storage/bag/money/small/legenlisted = 1, /obj/item/melee/onehanded/machete = 1, /obj/item/restraints/handcuffs = 1, + /obj/item/restraints/legcuffs/bola/tactical = 1, + /obj/item/storage/survivalkit/medical/legion = 1 ) /datum/outfit/loadout/expambusher @@ -758,14 +760,15 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/vetlegionnaire name = "Veteran Legionnaire" jobtype = /datum/job/CaesarsLegion/Legionnaire/vetlegionnaire - id = /obj/item/card/id/dogtag/legveteran - mask = /obj/item/clothing/mask/bandana/legion/legvet + id = /obj/item/card/id/dogtag/legion/veteran + mask = /obj/item/clothing/mask/bandana/legion head = /obj/item/clothing/head/helmet/f13/legion/vet neck = /obj/item/storage/belt/shoulderholster suit = /obj/item/clothing/suit/armor/legion/vet glasses = /obj/item/clothing/glasses/sunglasses shoes = /obj/item/clothing/shoes/f13/military/plated - r_pocket = /obj/item/flashlight/lantern + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern backpack_contents = list( /obj/item/reagent_containers/pill/patch/healpoultice = 1, // /obj/item/storage/bag/money/small/legenlisted = 1, @@ -843,14 +846,14 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13legionary name = "Prime Legionnaire" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13legionary - id = /obj/item/card/id/dogtag/legprime - mask = /obj/item/clothing/mask/bandana/legion/legprime + id = /obj/item/card/id/dogtag/legion/prime + mask = /obj/item/clothing/mask/bandana/legion head = /obj/item/clothing/head/helmet/f13/legion/prime - neck = /obj/item/storage/belt/shoulderholster + neck = /obj/item/storage/belt/holster suit = /obj/item/clothing/suit/armor/legion/prime - glasses = /obj/item/clothing/glasses/legiongoggles - r_pocket = /obj/item/flashlight/lantern - l_pocket = /obj/item/restraints/handcuffs + glasses = /obj/item/clothing/glasses/f13/goggles_sandstorm + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern backpack_contents = list( // /obj/item/storage/bag/money/small/legenlisted = 1, /obj/item/reagent_containers/pill/patch/healpoultice = 1, @@ -887,8 +890,9 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/job/CaesarsLegion/Legionnaire/f13recleg title = "Recruit Legionnaire" flag = F13RECRUITLEG - total_positions = 5 - spawn_positions = 5 + display_order = JOB_DISPLAY_ORDER_RECRUITLEG + total_positions = 6 + spawn_positions = 6 description = "You have recently come of age or been inducted into Caesar's Legion. You have absolutely no training, and are expected to follow every whim of the Decanii and your Centurion. Respect the soldiers of higher rank." supervisors = "the Decani and Centurion." display_order = JOB_DISPLAY_ORDER_RECRUITLEG @@ -916,13 +920,14 @@ Weapons Lever shotgun, Grease gun, Repeater carbines, Revolvers, simple guns al /datum/outfit/job/CaesarsLegion/Legionnaire/f13recleg name = "Recruit Legionnaire" jobtype = /datum/job/CaesarsLegion/Legionnaire/f13recleg - id = /obj/item/card/id/dogtag/legrecruit + id = /obj/item/card/id/dogtag/legion shoes = /obj/item/clothing/shoes/f13/military/leather suit = /obj/item/clothing/suit/armor/legion/recruit head = /obj/item/clothing/head/helmet/f13/legion/recruit - mask = /obj/item/clothing/mask/bandana/legion/legrecruit - glasses = /obj/item/clothing/glasses/legiongoggles - r_pocket = /obj/item/flashlight/lantern + mask = /obj/item/clothing/mask/bandana/legion/recruit + glasses = /obj/item/clothing/glasses/f13/goggles_sandstorm + r_pocket = /obj/item/storage/survivalkit/medical/legion + l_pocket = /obj/item/flashlight/lantern backpack_contents = list( // /obj/item/storage/bag/money/small/legenlisted = 1, /obj/item/reagent_containers/pill/healingpowder = 1, diff --git a/code/modules/jobs/job_types/oasis.dm b/code/modules/jobs/job_types/oasis.dm index 19c00608669..9ec6d10d08c 100644 --- a/code/modules/jobs/job_types/oasis.dm +++ b/code/modules/jobs/job_types/oasis.dm @@ -1170,7 +1170,7 @@ Mayor shoes = /obj/item/clothing/shoes/laceup backpack_contents = list(/obj/item/storage/fancy/cigarettes/cigpack_bigboss=1, /obj/item/storage/box/matches=1, - /obj/item/ingot/gold = 1, + /obj/item/blacksmith/ingot/gold = 1, ///obj/item/gun/ballistic/shotgun/automatic/combat/shotgunlever = 1 ) /*--------------------------------------------------------------*/ diff --git a/code/modules/jobs/job_types/wasteland.dm b/code/modules/jobs/job_types/wasteland.dm index de4a362379b..82e91abc2e2 100644 --- a/code/modules/jobs/job_types/wasteland.dm +++ b/code/modules/jobs/job_types/wasteland.dm @@ -620,7 +620,7 @@ Raider /obj/item/storage/belt/legholster, /obj/item/lighter/fusion = 1, /obj/item/toy/cards/deck = 1, - /obj/item/ingot/gold = 10, + /obj/item/blacksmith/ingot/gold = 10, /obj/item/storage/fancy/cigarettes/cigars/havana = 1, /obj/item/storage/box/dice = 1, /obj/item/storage/fancy/ringbox/silver = 1, diff --git a/code/modules/mining/ores_coins.dm b/code/modules/mining/ores_coins.dm index 37035638dbb..0422ee5d890 100644 --- a/code/modules/mining/ores_coins.dm +++ b/code/modules/mining/ores_coins.dm @@ -247,7 +247,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\ /obj/item/stack/ore/slag name = "slag" desc = "Completely useless." - icon = 'icons/fallout/objects/crafting/blacksmith.dmi' + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' icon_state = "slag" item_state = "slag" singular_name = "slag chunk" diff --git a/code/modules/mob/living/silicon/robot/robot_modules.dm b/code/modules/mob/living/silicon/robot/robot_modules.dm index ec819172f01..665f3427302 100644 --- a/code/modules/mob/living/silicon/robot/robot_modules.dm +++ b/code/modules/mob/living/silicon/robot/robot_modules.dm @@ -268,7 +268,6 @@ /obj/item/robot_module/standard name = "Standard" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/reagent_containers/borghypo/epi, @@ -294,7 +293,6 @@ /obj/item/robot_module/medical name = "Medical" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/healthanalyzer, @@ -345,7 +343,6 @@ /obj/item/robot_module/engineering name = "Engineering" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/borg/sight/meson, /obj/item/construction/rcd/borg, /obj/item/extinguisher, @@ -371,7 +368,6 @@ /obj/item/stack/rods/cyborg, /obj/item/stack/tile/plasteel/cyborg, /obj/item/stack/cable_coil/cyborg) - emag_modules = list(/obj/item/borg/stun) ratvar_modules = list( /obj/item/clockwork/slab/cyborg/engineer, /obj/item/clockwork/replica_fabricator/cyborg) @@ -399,11 +395,9 @@ /obj/item/robot_module/security name = "Security" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/restraints/handcuffs/cable/zipties, - /obj/item/melee/classic_baton/police, /obj/item/gun/energy/disabler/cyborg, /obj/item/clothing/mask/gas/sechailer/cyborg, /obj/item/pinpointer/crew) @@ -446,7 +440,6 @@ /obj/item/robot_module/peacekeeper name = "Peacekeeper" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/cookiesynth, @@ -488,7 +481,6 @@ /obj/item/robot_module/janitor name = "Janitor" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/screwdriver/cyborg, /obj/item/crowbar/cyborg, /obj/item/stack/tile/plasteel/cyborg, @@ -521,7 +513,6 @@ /obj/item/robot_module/butler name = "Service" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/reagent_containers/food/drinks/drinkingglass, @@ -606,7 +597,6 @@ /obj/item/robot_module/miner name = "Miner" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/borg/sight/meson, @@ -655,13 +645,11 @@ /obj/item/robot_module/gutsy name = "Gutsy" basic_modules = list( //Security borg - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/restraints/handcuffs/cable/zipties, /obj/item/borg/cyborghug, /obj/item/megaphone, - /obj/item/melee/classic_baton/police, /obj/item/gun/energy/laser/pistol/cyborg/gutsy, /obj/item/clothing/mask/gas/sechailer/cyborg, /obj/item/pinpointer/crew) @@ -705,7 +693,6 @@ obj/item/robot_module/assaultron/remove_module(obj/item/I, delete_after) /obj/item/robot_module/assaultron/medical name = "Medical Assaultron" basic_modules = list( - /obj/item/assembly/flash/cyborg, /obj/item/extinguisher/mini, /obj/item/crowbar/cyborg, /obj/item/healthanalyzer, diff --git a/code/modules/power/cell.dm b/code/modules/power/cell.dm index 552b062914c..6a71b962c57 100644 --- a/code/modules/power/cell.dm +++ b/code/modules/power/cell.dm @@ -282,6 +282,7 @@ /obj/item/stock_parts/cell/pulse/pistol //10 pulse shots name = "pulse pistol power cell" maxcharge = 2000 + self_recharge = 1 /obj/item/stock_parts/cell/high name = "high-capacity power cell" diff --git a/code/modules/reagents/chemistry/machinery/chem_master.dm b/code/modules/reagents/chemistry/machinery/chem_master.dm index ad08cb9c7f1..7748d860438 100644 --- a/code/modules/reagents/chemistry/machinery/chem_master.dm +++ b/code/modules/reagents/chemistry/machinery/chem_master.dm @@ -525,6 +525,7 @@ /obj/machinery/chem_master/primitive name = "alchemy table" desc = "A wooden table with various bone mortars and pistles, as well as other tools." + icon = 'modular_BD2/general/icons/alchemy.dmi' icon_state = "alchemy_table" primitive = TRUE use_power = FALSE diff --git a/code/modules/reagents/chemistry/recipes/slime_extracts.dm b/code/modules/reagents/chemistry/recipes/slime_extracts.dm index d45e201142f..f8a7816dc06 100644 --- a/code/modules/reagents/chemistry/recipes/slime_extracts.dm +++ b/code/modules/reagents/chemistry/recipes/slime_extracts.dm @@ -505,7 +505,7 @@ required_other = TRUE /datum/chemical_reaction/slime/adamantine/on_reaction(datum/reagents/holder) - new /obj/item/ingot/adamantine(get_turf(holder.my_atom)) + new /obj/item/blacksmith/ingot/adamantine(get_turf(holder.my_atom)) ..() //Bluespace diff --git a/code/modules/research/designs/autolathe_designs.dm b/code/modules/research/designs/autolathe_designs.dm index a7fe99a2002..dbd219512a3 100644 --- a/code/modules/research/designs/autolathe_designs.dm +++ b/code/modules/research/designs/autolathe_designs.dm @@ -349,6 +349,14 @@ build_path = /obj/item/shovel/spade category = list("initial","Misc") +/datum/design/handcuffs + name = "Handcuffs" + id = "handcuffs" + build_type = AUTOLATHE + materials = list(MAT_METAL = 500) + build_path = /obj/item/restraints/handcuffs + category = list("initial","Misc") + /datum/design/hatchet name = "Hatchet" id = "hatchet" @@ -817,3 +825,11 @@ materials = list(MAT_METAL = 300, MAT_GLASS = 150) build_path = /obj/item/key/collar category = list("initial", "Misc") + +/datum/design/record_disk //ATOM EDIT- start adds the record disk used to adding songs to be made in the autolathe + name = "Record disk" + id = "record_disk" + build_type = AUTOLATHE + materials = list(MAT_GLASS = 500) + build_path = /obj/item/record_disk + category = list("initial","Tools") //ATOM EDIT- end diff --git a/code/modules/research/designs/autolathe_desings/autolathe_designs_tcomms_and_misc.dm b/code/modules/research/designs/autolathe_desings/autolathe_designs_tcomms_and_misc.dm index cfd9327f3e1..65a7ddc7a12 100644 --- a/code/modules/research/designs/autolathe_desings/autolathe_designs_tcomms_and_misc.dm +++ b/code/modules/research/designs/autolathe_desings/autolathe_designs_tcomms_and_misc.dm @@ -130,6 +130,15 @@ category = list("initial","Misc","Tool Designs") departmental_flags = DEPARTMENTAL_FLAG_SERVICE +/datum/design/handcuffs + name = "Handcuffs" + id = "handcuffs" + build_type = AUTOLATHE | PROTOLATHE + materials = list(/datum/material/iron = 500) + build_path = /obj/item/restraints/handcuffs + category = list("initial","Misc","Tool Designs") + departmental_flags = DEPARTMENTAL_FLAG_SERVICE + /datum/design/hatchet name = "Hatchet" id = "hatchet" @@ -291,3 +300,11 @@ materials = list(/datum/material/iron = 6500, /datum/material/glass = 50) build_path = /obj/item/weaponcrafting/improvised_parts/trigger_assembly category = list("initial", "Misc") + +/datum/design/record_disk //ATOM EDIT- start adds the record disk used to adding songs to be made in the autolathe + name = "Record disk" + id = "record_disk" + build_type = AUTOLATHE + materials = list(/datum/material/glass = 500) + build_path = /obj/item/record_disk + category = list("initial","Misc") //ATOM EDIT -end- diff --git a/code/modules/research/designs/weapon_designs.dm b/code/modules/research/designs/weapon_designs.dm index 8ce4af0113f..bd07fe8dd83 100644 --- a/code/modules/research/designs/weapon_designs.dm +++ b/code/modules/research/designs/weapon_designs.dm @@ -403,6 +403,25 @@ departmental_flags = DEPARTMENTAL_FLAG_SECURITY */ + +/datum/design/rechargerrifle + name = "Recharger Rifle" + desc = "A locally produced copy of the recharger rifle. It's a bulky first-generation weapon designed to replenish its energy using radioactive decay." + id = "rechargerrifle" + build_type = PROTOLATHE + materials = list (/datum/material/iron = 8000, /datum/material/glass = 2000, /datum/material/uranium = 1000, /datum/material/gold = 500) + build_path = /obj/item/gun/energy/laser/wattz/recharger + category = list("Weapons") + +/datum/design/rechargerpistol + name = "Recharger Pistol" + desc = "A recharger pistol manufactured by the Followers of the Apocalpyse. As the name implies, it charges its capacitor banks over time using radioactive decay." + id = "rechargerpistol" + build_type = PROTOLATHE + materials = list (/datum/material/iron = 6000, /datum/material/glass = 1000, /datum/material/uranium = 2000, /datum/material/gold = 1000) + build_path = /obj/item/gun/energy/laser/wattz/recharger + category = list("Weapons") + /////////// //Grenades/ /////////// diff --git a/code/modules/research/techweb/nodes/biotech_nodes.dm b/code/modules/research/techweb/nodes/biotech_nodes.dm index ed543afe5bc..9b92a2e4b12 100644 --- a/code/modules/research/techweb/nodes/biotech_nodes.dm +++ b/code/modules/research/techweb/nodes/biotech_nodes.dm @@ -13,7 +13,7 @@ display_name = "Advanced Biotechnology" description = "Advanced Biotechnology" prereq_ids = list("biotech") - design_ids = list("crewpinpointer", "smoke_machine", "plasmarefiller", "limbgrower", "meta_beaker", "healthanalyzer_advanced", "harvester", "holobarrier_med", "defibrillator_compact", "pHmeter", "containmentbodybag") + design_ids = list("crewpinpointer", "plasmarefiller", "limbgrower", "meta_beaker", "healthanalyzer_advanced", "harvester", "holobarrier_med", "defibrillator_compact", "pHmeter", "containmentbodybag") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) /datum/techweb_node/bio_process diff --git a/code/modules/research/techweb/nodes/medical_nodes.dm b/code/modules/research/techweb/nodes/medical_nodes.dm index fae3832a71a..fb129252c9d 100644 --- a/code/modules/research/techweb/nodes/medical_nodes.dm +++ b/code/modules/research/techweb/nodes/medical_nodes.dm @@ -16,7 +16,7 @@ display_name = "Cryostasis Technology" description = "Smart freezing of objects to preserve them!" prereq_ids = list("adv_engi", "biotech") - design_ids = list("splitbeaker", "noreactsyringe", "cryotube", "cryo_Grenade") + design_ids = list("splitbeaker", "noreactsyringe", "cryotube") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2000) /* /datum/techweb_node/adv_defibrillator_tec diff --git a/code/modules/research/techweb/nodes/weaponry_nodes.dm b/code/modules/research/techweb/nodes/weaponry_nodes.dm index 56657fbc0c3..72be11ee530 100644 --- a/code/modules/research/techweb/nodes/weaponry_nodes.dm +++ b/code/modules/research/techweb/nodes/weaponry_nodes.dm @@ -5,7 +5,7 @@ display_name = "Weapon Development Technology" description = "Our researchers have found new to weaponize just about everything now." prereq_ids = list("engineering") - design_ids = list("pin_testing", "tele_shield", "mfc", "ec") + design_ids = list("pin_testing", "tele_shield", "mfc", "ec", "rechargerrifle") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 4000) /datum/techweb_node/adv_weaponry @@ -13,7 +13,7 @@ display_name = "Advanced Weapon Development Technology" description = "Our weapons are breaking the rules of reality by now." prereq_ids = list("adv_engi", "weaponry") - design_ids = list("pin_loyalty", "ecp", "bullet_shield") + design_ids = list("pin_loyalty", "ecp", "bullet_shield", "rechargerpistol") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 7500) /* /datum/techweb_node/electric_weapons diff --git a/code/modules/smithing/finished_items.dm b/code/modules/smithing/finished_items.dm deleted file mode 100644 index c627da5591a..00000000000 --- a/code/modules/smithing/finished_items.dm +++ /dev/null @@ -1,481 +0,0 @@ - -/obj/item/melee/smith - name = "base class obj/item/melee/smith" //tin. handles overlay and quality and shit. - desc = "cringe" - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "claymore" - lefthand_file = 'code/modules/smithing/icons/onmob/lefthand.dmi' - righthand_file = 'code/modules/smithing/icons/onmob/righthand.dmi' - mob_overlay_icon = 'code/modules/smithing/icons/onmob/slot.dmi' - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - total_mass = TOTAL_MASS_MEDIEVAL_WEAPON //yeah ok - slot_flags = ITEM_SLOT_BELT - w_class = WEIGHT_CLASS_NORMAL - force = WEAPON_FORCE_TOOL_SMALL - obj_flags = UNIQUE_RENAME - var/quality - var/overlay_state = "woodenrod" - var/mutable_appearance/overlay - //var/wielded_mult = 1 - -/obj/item/melee/smith/Initialize() - . = ..() - if(desc == "cringe") - desc = "A handmade [name]." - overlay = mutable_appearance(icon, overlay_state) - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - if(force < 0) - force = 0 - - -/obj/item/melee/smith/twohand - icon = 'code/modules/smithing/icons/blacksmith.dmi' - lefthand_file = 'code/modules/smithing/icons/onmob/lefthand.dmi' - righthand_file = 'code/modules/smithing/icons/onmob/righthand.dmi' - item_flags = NEEDS_PERMIT //it's a bigass sword/spear. beepsky is going to give you shit for it. - sharpness = SHARP_EDGED - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - force = WEAPON_FORCE_TOOL_LARGE - wielded_mult = WEAPON_SLASH_TWOHAND_MULT - w_class = WEIGHT_CLASS_BULKY - var/icon_prefix = null - -/obj/item/melee/smith/twohand/Initialize() - . = ..() - RegisterSignal(src, COMSIG_TWOHANDED_WIELD, PROC_REF(on_wield)) - RegisterSignal(src, COMSIG_TWOHANDED_UNWIELD, PROC_REF(on_unwield)) - -/obj/item/melee/smith/twohand/proc/on_wield(obj/item/source, mob/user) - wielded = TRUE - -/obj/item/melee/smith/twohand/proc/on_unwield(obj/item/source, mob/user) - wielded = FALSE - -/obj/item/melee/smith/twohand/update_icon_state() - icon_state = "[icon_prefix]" - -/obj/item/melee/smith/twohand/ComponentInitialize() - . = ..() - AddComponent(/datum/component/butchering, 100, 70) //decent in a pinch, but pretty bad. - AddElement(/datum/element/sword_point) - - - -////////////////////// -// // -// SMITHED TOOLS // -// // -////////////////////// - -// Blacksmithing hammer, not useful for anything else. -/obj/item/melee/smith/hammer - name = "smithing hammer" - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "hammer" - lefthand_file = 'icons/fallout/onmob/tools/tools_lefthand.dmi' - righthand_file = 'icons/fallout/onmob/tools/tools_righthand.dmi' - item_state = "hammer" - overlay_state = "hammerhandle" - var/qualitymod = 0 - -/obj/item/melee/smith/hammer/premade - quality = 3 - qualitymod = 1 - custom_materials = list(/datum/material/iron = 1000) - -// The true manual mining scanner, knock it on rock to scan. Could use a cooldown, can't be bothered to sort it. Lowest quality got too short range to test out. -/obj/item/mining_scanner/prospector - name = "prospectors pick" - desc = "A pick that can sound rocks to find mineral deposits." - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "prospect_smith" - lefthand_file = 'icons/fallout/onmob/tools/tools_lefthand.dmi' - righthand_file = 'icons/fallout/onmob/tools/tools_righthand.dmi' - item_state = "prospect_smith" - sharpness = SHARP_POINTY - -/obj/item/mining_scanner/prospector/Initialize() - ..() - var/mutable_appearance/overlay - desc = "A handmade [name]." - overlay = mutable_appearance(icon, "handle_prospect") - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - -/obj/item/mining_scanner/prospector/afterattack(atom/A, mob/living/user, proximity) - . = ..() - if(!proximity || IS_STAMCRIT(user)) - return - if(istype(A, /turf/closed/mineral)) - mineral_scan_pulse(get_turf(user), range) - playsound(src, 'sound/effects/Glassknock.ogg', 50, 1) - -/obj/item/mining_scanner/prospector/attack_self(mob/user) - return - -/obj/item/pickaxe/smithed - name = "pickaxe" - desc = "A pickaxe." - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "pickaxe" - lefthand_file = 'icons/fallout/onmob/tools/tools_lefthand.dmi' - righthand_file = 'icons/fallout/onmob/tools/tools_righthand.dmi' - item_state = "pickaxe" - slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_BACK - sharpness = SHARP_POINTY - -/obj/item/pickaxe/smithed/Initialize() - ..() - desc = "A handmade [name]." - var/mutable_appearance/overlay - overlay = mutable_appearance(icon, "handle_pickaxe") - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - if(force < 0) - force = 0 - -/obj/item/pickaxe/smithed/attack_self(mob/user) - to_chat(user, span_notice("Tool does not have a configureable dig range.")) - -/obj/item/shovel/smithed - name = "shovel" - desc = "A shovel." - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "shovel" - lefthand_file = 'icons/fallout/onmob/tools/tools_lefthand.dmi' - righthand_file = 'icons/fallout/onmob/tools/tools_righthand.dmi' - item_state = "shovel" - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - sharpness = SHARP_EDGED //it cuts through the earth - -/obj/item/shovel/smithed/Initialize() - ..() - desc = "A handmade [name]." - var/mutable_appearance/overlay - overlay = mutable_appearance(icon, "shovelhandle") - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - if(force < 0) - force = 0 - -// Smithed crowbars top out at 0.2 toolspeed max quality. Not bad. Not that useful either, its just a crowbar, still. -/obj/item/crowbar/smithed - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "crowbar_smith" - item_state = "crowbar" - toolspeed = 0.8 - force = WEAPON_FORCE_TOOL_LARGE - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - -/obj/item/crowbar/smithed/Initialize() - ..() - desc = "A handmade [name]." - var/mutable_appearance/overlay - overlay = mutable_appearance(icon, "handle_crowbar") - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - -// Crowbar-axe. Just a crowbar with more force and a homemade vibe. -/obj/item/crowbar/smithedunitool - name = "crowbaxe" - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "unitool_smith" - lefthand_file = 'code/modules/smithing/icons/onmob/lefthand.dmi' - righthand_file = 'code/modules/smithing/icons/onmob/righthand.dmi' - item_state = "unitool_smith" - sharpness = SHARP_EDGED - material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - force = WEAPON_FORCE_AXE_TOOL - -/obj/item/crowbar/smithedunitool/Initialize() - ..() - desc = "A bizarre combination of a crowbar and some sort of knifeblade." - var/mutable_appearance/overlay - overlay = mutable_appearance(icon, "handle_unitool") - overlay.appearance_flags = RESET_COLOR - add_overlay(overlay) - - - -////////////////////////// -// // -// ONEHANDED WEAPONS // -// // -////////////////////////// - -/obj/item/melee/smith/sword - name = "scrap sword" - icon_state = "sword_smith" - item_state = "sword_smith" - overlay_state = "hilt_sword" - armour_penetration = 0.1 - force = WEAPON_FORCE_SLASH_LARGE - sharpness = SHARP_EDGED - item_flags = NEEDS_PERMIT | ITEM_CAN_PARRY - block_parry_data = /datum/block_parry_data/captain_saber - w_class = WEIGHT_CLASS_BULKY - mob_overlay_icon = 'icons/fallout/onmob/clothes/belt.dmi' - layer = MOB_UPPER_LAYER - wound_bonus = WEAPON_SLASH_WOUND_ADD - //block_chance = 50 - -/obj/item/melee/smith/sword/spatha - name = "papercutter" - icon_state = "spatha_smith" - item_state = "spatha_smith" - overlay_state = "hilt_spatha" - -/obj/item/melee/smith/sword/sabre - name = "bumper sabre" - icon_state = "sabre_smith" - item_state = "sabre_smith" - overlay_state = "hilt_sabre" - -// go for the eyes Boo -/obj/item/melee/smith/dagger - name = "shiv" - icon_state = "dagger_smith" - overlay_state = "hilt_dagger" - w_class = WEIGHT_CLASS_SMALL - sharpness = SHARP_POINTY - force = WEAPON_FORCE_PIERCE_SMALL - hitsound = 'sound/weapons/rapierhit.ogg' - -/obj/item/melee/smith/dagger/attack(mob/living/carbon/M, mob/living/carbon/user) - if(!istype(M)) - return ..() - if(user.zone_selected == BODY_ZONE_PRECISE_EYES) - M.apply_damage(7, BRUTE, BODY_ZONE_HEAD) - return eyestab(M,user) - else - return ..() - -/obj/item/melee/smith/machete - name = "machete" - icon_state = "machete_smith" - overlay_state = "hilt_machete" - force = WEAPON_FORCE_SLASH_LARGE - sharpness = SHARP_EDGED - wound_bonus = WEAPON_SLASH_WOUND_ADD - -/obj/item/melee/smith/machete/gladius - name = "razorbar" - icon_state = "gladius_smith" - overlay_state = "hilt_gladius" - -/obj/item/melee/smith/machete/reforged - name = "mowerchete" - icon_state = "macheter_smith" - overlay_state = "hilt_macheter" - -/obj/item/melee/smith/wakizashi - name = "weedwhacker" - icon_state = "waki_smith" - overlay_state = "hilt_waki" - item_flags = NEEDS_PERMIT | ITEM_CAN_PARRY - force = WEAPON_FORCE_SLASH_SMALL - block_parry_data = /datum/block_parry_data/waki - hitsound = 'sound/weapons/rapierhit.ogg' - -/obj/item/melee/smith/wakizashi/Initialize() - if(prob(1)) - name = pick("weebwhacker", "weedhacker", "weebhacker", "weewhacker") - . = ..() - -/datum/block_parry_data/waki //like longbokken but worse reflect - parry_stamina_cost = 6 - parry_time_windup = 0 - parry_time_active = 15 //decent window - parry_time_spindown = 0 - parry_time_perfect = 2 - parry_time_perfect_leeway = 0.75 - parry_imperfect_falloff_percent = 7.5 - parry_efficiency_to_counterattack = 100 - parry_efficiency_considered_successful = 80 - parry_efficiency_perfect = 120 - parry_failed_stagger_duration = 3 SECONDS - parry_data = list(PARRY_COUNTERATTACK_MELEE_ATTACK_CHAIN = 1.9) - -// Mace - low damage, high AP (25, 0,4) -/obj/item/melee/smith/mace - name = "club" - icon_state = "mace_smith" - overlay_state = "shaft_mace" - force = WEAPON_FORCE_BLUNT_LARGE - wound_bonus = WEAPON_BLUNT_WOUND_ADD - -/obj/item/melee/smith/mace/attack(mob/living/M, mob/living/user) - . = ..() - if(!istype(M)) - return - M.apply_damage(15, STAMINA, "chest", M.run_armor_check("chest", "melee")) - - -////////////////////////// -// // -// TWOHANDED WEAPONS // -// // -////////////////////////// - -/obj/item/melee/smith/twohand/katana - name = "scraptana" - icon_state = "katana_smith" - icon_prefix = "katana_smith" - overlay_state = "hilt_katana" - force = WEAPON_FORCE_SLASH_LARGE - wielded_mult = WEAPON_SLASH_TWOHAND_MULT - item_flags = ITEM_CAN_PARRY | NEEDS_PERMIT - block_parry_data = /datum/block_parry_data/smithrapier - hitsound = 'sound/weapons/rapierhit.ogg' - slot_flags = ITEM_SLOT_BELT - layer = MOB_UPPER_LAYER - -/datum/block_parry_data/smithrapier //Old rapier code reused. parry into riposte. i am pretty sure this is going to be nearly fucking impossible to land. - parry_stamina_cost = 12 //dont miss - parry_time_active = 4 - parry_time_perfect = 2 - parry_time_perfect_leeway = 2 - parry_failed_stagger_duration = 3 SECONDS - parry_failed_clickcd_duration = 3 SECONDS - parry_time_windup = 0 - parry_time_spindown = 0 - parry_imperfect_falloff_percent = 0 - parry_efficiency_to_counterattack = 100 - parry_efficiency_considered_successful = 120 - parry_efficiency_perfect = 120 - parry_data = list(PARRY_COUNTERATTACK_MELEE_ATTACK_CHAIN = 4) - -// Heavy axe, 2H focused chopper 27/54. Can be worn on your back. -/obj/item/melee/smith/twohand/axe - name = "woodsplitter" - icon_state = "axe_smith" - icon_prefix = "axe_smith" - overlay_state = "shaft_axe" - total_mass = TOTAL_MASS_MEDIEVAL_WEAPON * 2 - force = WEAPON_FORCE_AXE_LARGE - wielded_mult = WEAPON_AXE_TWOHAND_MULT - slot_flags = ITEM_SLOT_BACK - layer = MOB_UPPER_LAYER - -/obj/item/melee/smith/twohand/axe/afterattack(atom/A, mob/living/user, proximity) - . = ..() - if(!proximity || !wielded || IS_STAMCRIT(user)) - return - if(istype(A, /obj/machinery/door) || istype(A, /obj/structure/simple_door) || istype(A, /obj/structure/barricade)) - var/obj/machinery/door/D = A - D.take_damage(force, BRUTE, "melee", 0) // DOORFUCKER 9000 - -/obj/item/melee/smith/twohand/axe/warhoned - name = "sledge axe" - icon_state = "warhoned_smith" - icon_prefix = "warhoned_smith" - overlay_state = "shaft_warhoned" - -/obj/item/melee/smith/twohand/axe/scrapblade - name = "homewrecker" - icon_state = "scrap_smith" - icon_prefix = "scrap_smith" - overlay_state = "hilt_scrap" - -/obj/item/melee/smith/twohand/spear - name = "rebar spear" - icon_state = "spear_smith" - icon_prefix = "spear_smith" - overlay_state = "shaft_spear" - max_reach = 2 - force = WEAPON_FORCE_PIERCE_LARGE - sharpness = SHARP_POINTY - -/obj/item/melee/smith/twohand/spear/lance - name = "rebar lance" - icon_state = "lance_smith" - icon_prefix = "lance_smith" - overlay_state = "shaft_lance" - - -////////////////////////// -// // -// THROWING WEAPONS // -// // -////////////////////////// - - -// Good throwing, thats about it (27, 40) -/obj/item/melee/smith/javelin - name = "rebar throwing spike" - icon_state = "javelin_smith" - overlay_state = "shaft_javelin" - item_state = "javelin_smith" - sharpness = SHARP_POINTY - embedding = list("pain_mult" = 2, "embed_chance" = 60, "fall_chance" = 20, "ignore_throwspeed_threshold" = TRUE) - force = WEAPON_FORCE_PIERCE_LARGE - sharpness = SHARP_POINTY - -// Smaller weaker javelin, easier to store/carry, less effective -/obj/item/melee/smith/throwingknife - name = "mower blade" - icon_state = "throwing_smith" - overlay_state = "handle_throwing" - item_state = "dagger_smith" - embedding = list("pain_mult" = 2, "embed_chance" = 50, "fall_chance" = 20, "ignore_throwspeed_threshold" = TRUE) - force = WEAPON_FORCE_PIERCE_SMALL - sharpness = SHARP_POINTY - - -// TG stuff - -//unique hammers -/obj/item/melee/smith/hammer/toolbox - name = "toolbox hammer" - desc = "A metal filled toolbox on a stick. Useable as a really shitty hammer." - w_class = WEIGHT_CLASS_BULKY - icon_state = "toolbox" - overlay_state = "hammerhandle" - qualitymod = 0 - -/obj/item/melee/smith/hammer/narsie - name = "runemetal hammer" - custom_materials = list(/datum/material/runedmetal = 12000) - desc = "A metal hammer inscribed with geometeric runes." - qualitymod = 1 - -/obj/item/melee/smith/hammer/narsie/attack(mob/living/target, mob/living/carbon/human/user) - if(!iscultist(user)) - user.DefaultCombatKnockdown(100) - user.dropItemToGround(src, TRUE) - user.visible_message(span_warning("A powerful force shoves [user] away from [target]!"), \ - span_cultlarge("\"You shouldn't be touching tools that aren't yours.\"")) - if(ishuman(user)) - var/mob/living/carbon/human/H = user - H.apply_damage(rand(force/2, force), BRUTE, pick(BODY_ZONE_L_ARM, BODY_ZONE_R_ARM)) - else - user.adjustBruteLoss(rand(force/2,force)) - return - ..() - -/obj/item/melee/smith/hammer/ratvar - name = "brass hammer" - custom_materials = list(/datum/material/bronze = 12000) - desc = "A brass hammer inscribed with... writing? You can't read it." - qualitymod = 1 - -/obj/item/melee/smith/hammer/ratvar/attack(mob/living/target, mob/living/carbon/human/user) - if(!is_servant_of_ratvar(user)) - user.DefaultCombatKnockdown(100) - user.dropItemToGround(src, TRUE) - user.visible_message(span_warning("A powerful force shoves [user] away from [target]!"), span_neovgre("\"You shouldn't be touching tools that aren't yours.\"")) - if(ishuman(user)) - var/mob/living/carbon/human/H = user - H.apply_damage(rand(force/2, force), BRUTE, pick(BODY_ZONE_L_ARM, BODY_ZONE_R_ARM)) - else - user.adjustBruteLoss(rand(force/2,force)) - return - ..() - -/obj/item/melee/smith/hammer/debug - name = "debugging hammer" - desc = "A DEBUGGING HAMMER!! EPIC!!." - qualitymod = 10 diff --git a/code/modules/smithing/furnace.dm b/code/modules/smithing/furnace.dm deleted file mode 100644 index c0949be9898..00000000000 --- a/code/modules/smithing/furnace.dm +++ /dev/null @@ -1,94 +0,0 @@ -/obj/structure/furnace - name = "furnace" - desc = "A furnace." - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "furnace0" - density = TRUE - anchored = TRUE - var/debug = FALSE //debugging only - var/working = TRUE - var/fueluse = 1 - light_system = MOVABLE_LIGHT - light_range = 2 - light_power = 0.75 - light_color = LIGHT_COLOR_FIRE - light_on = FALSE - var/datum/looping_sound/furnace/soundloop - -/obj/structure/furnace/Initialize() - . = ..() - create_reagents(250, TRANSPARENT) - START_PROCESSING(SSobj, src) - soundloop = new(list(src), FALSE) - -/obj/structure/furnace/Destroy() - STOP_PROCESSING(SSobj, src) - return ..() - -/obj/structure/furnace/process() - if(debug) - reagents.add_reagent(/datum/reagent/fuel, 1) - return TRUE - if(reagents.remove_reagent(/datum/reagent/fuel, fueluse)) - working = TRUE - soundloop.start() - set_light_on(TRUE) - if(icon_state == "furnace0") - icon_state = "furnace1" - - else - working = FALSE - soundloop.stop() - set_light_on(FALSE) - icon_state = "furnace0" - -/obj/structure/furnace/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/ingot)) - var/obj/item/ingot/notsword = I - if(working) - to_chat(user, "You heat the [notsword] in the [src].") - notsword.workability = "shapeable" - notsword.icon_state = "hot_ingot" - notsword.set_light_on(TRUE) - I.on_attack_hand(user) - else - to_chat(user, "The furnace isn't working!.") - else - . = ..() - -/obj/structure/furnace/wrench_act(mob/living/user, obj/item/I) - ..() - default_unfasten_wrench(user, I, 5) - return TRUE - -/obj/structure/furnace/attackby(obj/item/W, mob/user, params) - if(W.reagents) - W.reagents.trans_to(src, 250) - else - return ..() - -/obj/structure/furnace/plunger_act(obj/item/plunger/P, mob/living/user, reinforced) - to_chat(user, "You start furiously plunging [name].") - if(do_after(user, 30, target = src)) - to_chat(user, "You finish plunging the [name].") - reagents.reaction(get_turf(src), TOUCH) //splash on the floor - reagents.clear_reagents() - -/obj/structure/furnace/infinite - name = "fuelless furnace" - debug = TRUE - icon_state = "furnace1" - -/datum/looping_sound/furnace - mid_sounds = list(SOUND_LOOP_ENTRY('code/modules/smithing/sound/furnace1.ogg', 7 SECONDS, 1)) - volume = 40 - - -//tg holdover -/obj/structure/furnace/infinite/ratvar - name = "brass furnace" - desc = "A brass furnace. Powered by... something, but seems otherwise safe." //todo:sprites they're safe for noncultists because you're just putting ingots in them. also there';s a reason to steal them ig - -/obj/structure/furnace/infinite/narsie - name = "rune furnace" - desc = "A runed furnace. Powered by... something, but seems otherwise safe." diff --git a/code/modules/smithing/smithed_items.dm b/code/modules/smithing/smithed_items.dm deleted file mode 100644 index 89d466f246b..00000000000 --- a/code/modules/smithing/smithed_items.dm +++ /dev/null @@ -1,639 +0,0 @@ -/obj/item/smithing - name = "base class /obj/item/smithing" - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "unfinished" - material_flags = MATERIAL_COLOR | MATERIAL_ADD_PREFIX - var/quality = 0 //quality. Changed by the smithing process. - var/obj/item/finishingitem = /obj/item/blacksmith/woodrod //What this item needs to be hit by to create finalitem - var/obj/item/finalitem - var/artifact = FALSE - -/obj/item/ingot - name = "ingot" - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "ingot" - material_flags = MATERIAL_COLOR | MATERIAL_ADD_PREFIX - var/workability = 0 - light_system = MOVABLE_LIGHT - light_range = 1 - light_power = 0.4 - light_color = LIGHT_COLOR_FIRE - light_on = FALSE - -/obj/item/ingot/on_attack_hand(mob/user) - var/mob/living/carbon/human/H - if(workability != "shapeable") - return ..() - var/prot = 0 - if(ishuman(user)) - H = user - if(H.gloves) - var/obj/item/clothing/gloves/G = H.gloves - if(G.max_heat_protection_temperature) - prot = (G.max_heat_protection_temperature > 360) - else - prot = 0 - if(prot > 0 || HAS_TRAIT(user, TRAIT_RESISTHEAT) || HAS_TRAIT(user, TRAIT_RESISTHEATHANDS)) - to_chat(user, span_notice("You pick up the [src].")) - return ..() - else - to_chat(user, span_warning("You try to move the [src], but you burn your hand on it!")) - if(H) - var/obj/item/bodypart/affecting = H.get_bodypart("[(user.active_hand_index % 2 == 0) ? "r" : "l" ]_arm") - if(affecting && affecting.receive_damage( 0, 5 )) // 5 burn damage - H.update_damage_overlays() - var/list/hand_items = list(H.get_active_held_item(),H.get_inactive_held_item()) - if(src in hand_items) - H.dropItemToGround(src) - -/obj/item/ingot/iron - custom_materials = list(/datum/material/iron=12000) - -/obj/item/ingot/diamond - custom_materials = list(/datum/material/diamond=12000) //yeah ok - -/obj/item/ingot/uranium - custom_materials = list(/datum/material/uranium=12000) - -/obj/item/ingot/plasma - custom_materials = list(/datum/material/plasma=12000)//yeah ok - -/obj/item/ingot/gold - custom_materials = list(/datum/material/gold=12000) - -/obj/item/ingot/silver - custom_materials = list(/datum/material/silver=12000) - -/obj/item/ingot/titanium - custom_materials = list(/datum/material/titanium=12000) - -// Adapted to suit FO so it can be used. -/obj/item/ingot/adamantine - custom_materials = list(/datum/material/adamantine=12000) - name = "pre-war steel ingot" - desc = "Top quality steel from the old world." - material_flags = MATERIAL_COLOR - -/obj/item/ingot/cult - custom_materials = list(/datum/material/runedmetal=12000) - -/obj/item/ingot/bronze - custom_materials = list(/datum/material/bronze=12000) - -/obj/item/ingot/ratvar - custom_materials = list(/datum/material/brass=12000) - desc = "On closer inspection, what appears to be wholly-unsuitable-for-smithing brass is actually primarily replicant alloy. Nezbere must have switched it while you weren't looking." - -/obj/item/ingot/bone - custom_materials = list(/datum/material/bone=12000) - -/obj/item/smithing/attackby(obj/item/I, mob/user) - if(istype(I, finishingitem)) - qdel(I) - startfinish() - else - return ..() - -/obj/item/smithing/proc/startfinish() - dofinish() - -/obj/item/smithing/proc/dofinish() - var/qualname - switch(quality) - if(-INFINITY to -5) - qualname = "heinous" - if(-4 to -2) - qualname = "horrific" - if(-1 to -1) - qualname = "abysmal" - if(-1 to 1) - qualname = "shoddy" - if(0 to 3.5) - qualname = "crude" - if(3.5 to 5.5) - qualname = "makeshift" - if(5.5 to 7.5) - qualname = "average" - if(7.5 to 10) - qualname = "good" - if(10 to INFINITY) - qualname = "masterwork" //changed the descriptions so people know better where they're at on the quality scale - var/datum/material/mat = custom_materials[1] - finalitem.set_custom_materials(custom_materials) - mat = mat.name - if(artifact) - dwarfyartifact(finalitem, mat) - else - finalitem.name = "[qualname] [mat] [initial(finalitem.name)]" - finalitem.desc = "A [qualname] [initial(finalitem.name)]. Its quality is [quality]." - finalitem.forceMove(get_turf(src)) - qdel(src) - - -/obj/item/smithing/proc/dwarfyartifact(obj/item/finalitem, mat) - var/finaldesc = "A [initial(finalitem.name)] made of [mat], all craftsmanship is of the highest quality. It " - switch(pick(1,2,3,4,5)) - if(1) - finaldesc += "is encrusted with [pick("","synthetic ","multi-faceted ","magical ","sparkling ") + pick("rubies","emeralds","jade","opals","lapiz lazuli")]." - if(2) - finaldesc += "is laced with studs of [pick("gold","silver","aluminium","titanium")]." - if(3) - finaldesc += "is encircled with bands of [pick("durasteel","metallic hydrogen","ferritic-alloy","plasteel","duranium")]." - if(4) - finaldesc += "menaces with spikes of [pick("ytterbium","uranium","white pearl","black steel")]." - if(5) - finaldesc += "is encrusted with [pick("","synthetic ","multi-faceted ","magical ","sparkling ") + pick("rubies","emeralds","jade","opals","lapis lazuli")],laced with studs of [pick("gold","silver","aluminium","titanium")], encircled with bands of [pick("durasteel","metallic hydrogen","ferritic-alloy","plasteel","duranium")] and menaces with spikes of [pick("ytterbium","uranium","white pearl","black steel")]." - finalitem.desc = finaldesc - finalitem.name = pick("Delersibnir", "Nekolangrir", "Zanoreshik","Öntakrítin", "Nogzatan", "Vunomam", "Nazushagsaldôbar", "Sergeb", "Zafaldastot", "Vudnis", "Dostust", "Shotom", "Mugshith", "Angzak", "Oltud", "Deleratîs", "Nökornomal") //one of these is literally BLOOD POOL CREATE.iirc its Nazushagsaldôbar. - - -////////////////////////// -// // -// BLACKSMITH PARTS // -// // -////////////////////////// - -// Root item code -/obj/item/blacksmith - icon = 'code/modules/smithing/icons/blacksmith.dmi' - max_integrity = 50 - w_class = WEIGHT_CLASS_SMALL - -// Stick can be made by using a sharp tool on a piece of wood, less time wasted in crafting menu -/obj/item/blacksmith/woodrod - name = "wooden rod" - desc = "It's a rod, suitable for use of a handle of a tool. Also could serve as a weapon, in a pinch." - icon_state = "woodenrod" - force = 7 - resistance_flags = FLAMMABLE - -// Using leather strips on a wooden rod to make a sword handle -/obj/item/blacksmith/woodrod/attackby/(obj/item/W, mob/user, params) - if (istype(W, /obj/item/stack/sheet/leatherstrips)) - user.visible_message("[user] begins finishing the [src] into a sword handle.", \ - span_notice("You begin wrapping the [src] with leather strips, and shaping the wood into a sword handle."), \ - span_italic("You hear faint sounds of handcrafting.")) - // 6 Second Timer - if(!do_after(user, 60, TRUE, src)) - return - // Make stick - var/obj/item/blacksmith/swordhandle/new_item = new(user.loc) - user.visible_message("[user] finishes making a sword handle from the [src].", \ - span_notice("You finish making a sword handle from the [src].")) - qdel(src) - // Prepare to Put xin Hands (if holding wood) - var/obj/item/stack/sheet/leatherstrips/N = src - var/replace = (user.get_inactive_held_item() == N) - // Use up the strips - N.use(1) - // If stack depleted, put item in that hand (if it had one) - if (!N && replace) - user.put_in_hands(new_item) - else - . = ..() - - -/obj/item/blacksmith/swordhandle - name = "sword handle" - desc = "It's a wooden handle with leather strips, making it comfortable to hold." - icon_state = "swordhandle" - resistance_flags = FLAMMABLE - -/obj/item/blacksmith/chain - name = "length of chain" - desc = "It rattles and is pretty useless when not attached to stuff" - icon_state = "chain" - -////////////////////// -// // -// SMITHED TOOLS // -// METAL PARTS // -// // -////////////////////// - -/obj/item/smithing/hammerhead - name = "smithed hammer head" - finalitem = /obj/item/melee/smith/hammer - icon_state = "hammer" - -/obj/item/smithing/hammerhead/startfinish() - var/obj/item/melee/smith/hammer/finalforreal = new /obj/item/melee/smith/hammer(src) - finalforreal.force += quality/2 - finalforreal.qualitymod = quality/2 - finalitem = finalforreal - ..() - -/obj/item/smithing/shovelhead - name = "smithed shovel head" - finalitem = /obj/item/shovel/smithed - icon_state = "shovel" - -/obj/item/smithing/shovelhead/startfinish() - finalitem = new /obj/item/shovel/smithed(src) - finalitem.force += quality/2 - if(quality > 0) - finalitem.toolspeed = max(0.05,(1-(quality/10))) - else - finalitem.toolspeed *= max(1, (quality * -1)) - ..() - -/obj/item/smithing/pickaxehead - name = "smithed pickaxe head" - finalitem = /obj/item/pickaxe/smithed - icon_state = "pickaxe" - -/obj/item/smithing/pickaxehead/startfinish() - var/obj/item/pickaxe/smithed/finalforreal = new /obj/item/pickaxe/smithed(src) - finalforreal.force += quality/2 - if(quality > 0) - finalforreal.toolspeed = max(0.05,(1-(quality/10))) - else - finalforreal.toolspeed *= max(1, (quality * -1)) - finalforreal.digrange = 1 - switch(quality) - if(10 to INFINITY) - finalforreal.digrange = 2 - if(5 to 9) - finalforreal.digrange = 2 - if(3,4) - finalforreal.digrange = 1 - else - finalforreal.digrange = 1 //uncommented this section. I say let people who wanna mine have strong tools. - finalitem = finalforreal - ..() - -/obj/item/smithing/prospectingpickhead - name = "smithed prospector's pick head" - icon_state = "prospect_smith" - finalitem = /obj/item/mining_scanner/prospector - var/cooldown = null - var/range = null - - -/obj/item/smithing/prospectingpickhead/startfinish() - var/obj/item/mining_scanner/prospector/finalforreal = new /obj/item/mining_scanner/prospector(src) - finalforreal.range = 2 + quality - if(quality) - finalforreal.cooldown = 100/quality - finalforreal.force += quality - finalitem = finalforreal - ..() - - -/obj/item/smithing/crowbar - name = "unwrapped crowbar" - desc = "Add leather strips." - icon_state = "crowbar_smith" - finishingitem = /obj/item/stack/sheet/leatherstrips - finalitem = /obj/item/crowbar/smithed - -/obj/item/smithing/crowbar/startfinish() - var/obj/item/crowbar/smithed/finalforreal = new /obj/item/crowbar/smithed(src) - finalforreal.force += quality*2 //Bonk! -farmwizard - if(quality > 0) - finalforreal.toolspeed = max(0.05,(1-(quality/10))) - else - finalforreal.toolspeed *= max(1, (quality * -1)) - finalitem = finalforreal - ..() - -// Does not produce the expected result with force dependent on quality, instead just uses the base one. The finished item is a placeholder, it works though. -/obj/item/smithing/unitool - name = "unwrapped crowbaxe" - desc = "Add leather strips." - icon_state = "unitool_smith" - finishingitem = /obj/item/stack/sheet/leatherstrips - finalitem = /obj/item/crowbar/smithedunitool - -/obj/item/smithing/unitool/startfinish() - var/obj/item/crowbar/smithedunitool/finalforreal = new /obj/item/crowbar/smithedunitool(src) - finalforreal.force += quality*2.5 //It's a handaxe! - farmwizard - finalitem = finalforreal - ..() - - -/obj/item/smithing/knifeblade - name = "smithed knife blade" - icon_state = "knife_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/kitchen/knife - -/obj/item/smithing/knifeblade/startfinish() - var/obj/item/smithing/knifeblade/finalforreal = new /obj/item/smithing/knifeblade(src) - finalitem = new /obj/item/kitchen/knife(src) - finalforreal.force += quality*2 - finalitem = finalforreal - finalitem.icon = 'code/modules/smithing/icons/blacksmith.dmi' - finalitem.icon_state = "knife_smith" - finalitem.name = "kitchen knife" - finalitem.desc = "A handmade kitchen knife." - var/mutable_appearance/overlay = mutable_appearance('code/modules/smithing/icons/blacksmith.dmi', "hilt_knife") - overlay.appearance_flags = RESET_COLOR - finalitem.add_overlay(overlay) - if(finalitem.force < 0) - finalitem.force = 0 - finalitem.material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - ..() - - -////////////////////// -// // -// BLING // -// // -////////////////////// - -/obj/item/smithing/special - mob_overlay_icon = 'icons/fallout/onmob/items/miscellaneous.dmi' - gender = NEUTER - w_class = WEIGHT_CLASS_SMALL - -/obj/item/smithing/special/jewelry - icon_state = "ring" - item_state = "ring" - strip_delay = 20 - equip_delay_other = 40 - var/strip_mod = 1 //how much they alter stripping items time by, higher is quicker - var/strip_silence = TRUE - var/mood_event_on_equip = /datum/mood_event/equipped_ring/gold - -/obj/item/smithing/special/jewelry/ring - name = "ring" - slot_flags = ITEM_SLOT_GLOVES - attack_verb = list("proposed") - -/obj/item/smithing/special/jewelry/ring/equipped(mob/user, slot) - . = ..() - if (slot == SLOT_GLOVES && istype(user)) - SEND_SIGNAL(user, COMSIG_ADD_MOOD_EVENT, "ringbuff", mood_event_on_equip) - else - SEND_SIGNAL(user, COMSIG_CLEAR_MOOD_EVENT, "ringbuff") - -/obj/item/smithing/special/jewelry/ring/dropped(mob/user) - . = ..() - SEND_SIGNAL(user, COMSIG_CLEAR_MOOD_EVENT, "ringbuff") - - -/obj/item/clothing/shoes/ballandchain - name = "ball and chain" - desc = "An unpopular alternative to shoes." - icon = 'code/modules/smithing/icons/blacksmith.dmi' - icon_state = "ballandchain" - mob_overlay_icon = 'icons/fallout/onmob/items/miscellaneous.dmi' - item_state = "ballandchain" - strip_delay = 300 - equip_delay_other = 50 - can_be_tied = FALSE - w_class = WEIGHT_CLASS_BULKY - slowdown = 8 - material_flags = MATERIAL_COLOR | MATERIAL_ADD_PREFIX - hitsound = 'sound/weapons/chainhit.ogg' - var/quality = null - -/obj/item/clothing/shoes/ballandchain/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags) - if(loc == user && user.get_item_by_slot(SLOT_SHOES)) - playsound(usr.loc, 'sound/weapons/chainhit.ogg', 75, 1) - to_chat(user, span_warning("The ball and chain are too hard to remove by yourself! You'll need help taking this off!")) - return - return ..() - -/obj/item/smithing/ballandchain - name = "unchained ball" - desc = "Finish by attaching a chain to it." - icon_state = "ball" - finishingitem = /obj/item/blacksmith/chain - finalitem = /obj/item/clothing/shoes/ballandchain - -/obj/item/smithing/ballandchain/startfinish() - var/obj/item/smithing/ballandchain/finalforreal = new /obj/item/clothing/shoes/ballandchain(src) - finalitem = new /obj/item/clothing/shoes/ballandchain(src) - finalforreal.force += quality*2 - finalitem = finalforreal - finalitem.icon = 'code/modules/smithing/icons/blacksmith.dmi' - finalitem.icon_state = "ballandchain" - finalitem.name = "ball and chain" - finalitem.desc = "Makes the captive even more miserable." - finalitem.material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS - ..() - - -/////////////// -// NEW STUFF // -/////////////// - -/obj/item/smithing/swordblade - name = "sharpened longblade" - icon_state = "sword_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/sword - -/obj/item/smithing/swordblade/startfinish() - finalitem = new /obj/item/melee/smith/sword(src) - finalitem.force += quality*2.25 - finalitem.armour_penetration += quality*0.009 // 9% armor pen at max qual - ..() - -/obj/item/smithing/sabreblade - name = "scrap sabre blade" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/sword/sabre - icon_state = "sabre_smith" - -/obj/item/smithing/sabreblade/startfinish() - finalitem = new /obj/item/melee/smith/sword/sabre(src) - finalitem.force += quality*2 - finalitem.armour_penetration += quality*0.012 //13% armor pen at max qual - ..() - -/obj/item/smithing/spathablade - name = "papercutter blade" - icon_state = "spatha_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/sword/spatha - -/obj/item/smithing/spathablade/startfinish() - finalitem = new /obj/item/melee/smith/sword/spatha(src) - finalitem.force += quality*2.2 - ..() - -/obj/item/smithing/spearhead - name = "sharpened length of rebar" - finalitem = /obj/item/melee/smith/twohand/spear - icon_state = "spear_smith" - -/obj/item/smithing/spearhead/startfinish() - var/obj/item/melee/smith/twohand/spear/finalforreal = new /obj/item/melee/smith/twohand/spear(src) - finalforreal.force += quality*1.75 //they should do less damage than weapons that put you in melee range - finalforreal.wielded_icon = "[icon_state]2" - finalforreal.throwforce = finalforreal.force/10 - finalitem = finalforreal - ..() - - -/obj/item/smithing/lancehead - name = "pointy length of rebar" - finalitem = /obj/item/melee/smith/twohand/spear/lance - icon_state = "lance_smith" - -/obj/item/smithing/lancehead/startfinish() - var/obj/item/melee/smith/twohand/spear/lance/finalforreal = new /obj/item/melee/smith/twohand/spear/lance(src) - finalforreal.force += quality*1.75 - finalforreal.wielded_icon = "[icon_state]2" - finalforreal.throwforce = finalforreal.force/10 - finalitem = finalforreal - ..() - -// Axes & Choppers // -/obj/item/smithing/axehead - name = "smithed axehead" - icon_state = "axe_smith" - finalitem = /obj/item/melee/smith/twohand/axe - -/obj/item/smithing/axehead/startfinish() - var/obj/item/melee/smith/twohand/axe/finalforreal = new /obj/item/melee/smith/twohand/axe(src) - finalforreal.force += quality*1.5 // Adjusts damage, a maxed out wielded axe should do 70 damage - finalforreal.wielded_icon = "[icon_state]2" - finalitem = finalforreal - ..() - -/obj/item/smithing/warhonedhead - name = "sharpened wedge" - icon_state = "warhoned_smith" - finalitem = /obj/item/melee/smith/twohand/axe/warhoned - -/obj/item/smithing/warhonedhead/startfinish() - var/obj/item/melee/smith/twohand/axe/warhoned/finalforreal = new /obj/item/melee/smith/twohand/axe/warhoned(src) - finalforreal.force += quality*1.5 - finalforreal.wielded_icon = "[icon_state]2" - finalitem = finalforreal - ..() - -/obj/item/smithing/scrapblade - name = "jagged wedge" - icon_state = "scrap_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/twohand/axe/scrapblade - -/obj/item/smithing/scrapblade/startfinish() - var/obj/item/melee/smith/twohand/axe/scrapblade/finalforreal = new /obj/item/melee/smith/twohand/axe/scrapblade(src) - finalforreal.force += quality*1.5 - finalforreal.wielded_icon = "[icon_state]2" - finalitem = finalforreal - ..() - - -/obj/item/smithing/daggerblade - name = "spike" - icon_state = "dagger_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/dagger - -/obj/item/smithing/daggerblade/startfinish() - finalitem = new /obj/item/melee/smith/dagger(src) - finalitem.force += quality*1.5 //why tf the kitchen knife gets to be strong but not this thing? - finalitem.armour_penetration += quality*0.0375 // fucking 41% AP, an actual reason to use this thing - ..() - - -/obj/item/smithing/macheteblade - name = "sharpened blade" - icon_state = "machete_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/machete - -/obj/item/smithing/macheteblade/startfinish() - finalitem = new /obj/item/melee/smith/machete(src) - finalitem.force += quality*1.5 - ..() - - -/obj/item/smithing/gladiusblade - name = "razorbar" - icon_state = "gladius_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/machete/gladius - -/obj/item/smithing/gladiusblade/startfinish() - finalitem = new /obj/item/melee/smith/machete/gladius(src) - finalitem.force += quality*1.5 - ..() - - -/obj/item/smithing/macheterblade - name = "welded together lawnmower blades" - icon_state = "macheter_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/machete/reforged - -/obj/item/smithing/macheterblade/startfinish() - finalitem = new /obj/item/melee/smith/machete/reforged(src) - finalitem.force += quality*1.5 - ..() - -/obj/item/smithing/macehead - name = "heavy lump" - icon_state = "mace_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/mace - -/obj/item/smithing/macehead/startfinish() - finalitem = new /obj/item/melee/smith/mace(src) - finalitem.force += quality*2 - finalitem.armour_penetration += quality*0.05 //55% AP - ..() - - - -/obj/item/smithing/wakiblade - name = "shortblade" - icon_state = "waki_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/wakizashi - -/obj/item/smithing/wakiblade/startfinish() - finalitem = new /obj/item/melee/smith/wakizashi(src) - finalitem.force += quality*2 //Smaller so it fits in more places. Deals less damage. - ..() - - -/obj/item/smithing/katanablade - name = "longblade" - icon_state = "katana_smith" - finishingitem = /obj/item/blacksmith/swordhandle - finalitem = /obj/item/melee/smith/twohand/katana - -/obj/item/smithing/katanablade/startfinish() - var/obj/item/melee/smith/twohand/katana/finalforreal = new /obj/item/melee/smith/twohand/katana(src) - finalforreal.force += quality*2.5 //Brings unwielded katana to 42 Force, and 63 Force when wielded. - finalforreal.wielded_icon = "[icon_state]2" - finalitem = finalforreal - ..() - - -/obj/item/smithing/javelinhead - name = "streamlined rebar spike" - icon_state = "javelin_smith" - finalitem = /obj/item/melee/smith/javelin - -/obj/item/smithing/javelinhead/startfinish() - var/obj/item/melee/smith/javelin/finalforreal = new /obj/item/melee/smith/javelin(src) - finalforreal.force += quality*1.25 //These are meant for tossin, not melee-in - finalforreal.throwforce = finalforreal.force*1.5 - finalitem = finalforreal - ..() - - -/obj/item/smithing/throwingknife - name = "shortened lawnmower blade" - desc = "Add leather strips." - icon_state = "throwing_smith" - finishingitem = /obj/item/stack/sheet/leatherstrips - finalitem = /obj/item/melee/smith/throwingknife - -/obj/item/smithing/throwingknife/startfinish() - var/obj/item/melee/smith/throwingknife/finalforreal = new /obj/item/melee/smith/throwingknife(src) - finalforreal.force += quality*1.25 //Same here - finalforreal.throwforce = finalforreal.force*1.4 - finalitem = finalforreal - ..() - - diff --git a/config/config.txt b/config/config.txt index 4da05d87901..016e576b63b 100644 --- a/config/config.txt +++ b/config/config.txt @@ -12,7 +12,7 @@ $include plushies/defines.txt $include job_threats.txt $include policy.txt -# You can use the @ character at the beginning of a config option to lock it from being edited in-game +# You can use the @ er at the beginning of a config option to lock it from being edited in-game # Example usage: # @SERVERNAME tgstation # Which sets the SERVERNAME, and disallows admins from being able to change it using View Variables. diff --git a/hailmary.dme b/hailmary.dme index ce9aafc7746..d0a39029b25 100644 --- a/hailmary.dme +++ b/hailmary.dme @@ -3448,10 +3448,6 @@ #include "code\modules\shuttle\shuttle_creation\shuttle_creator_eye.dm" #include "code\modules\shuttle\shuttle_creation\shuttle_creator_overlay.dm" #include "code\modules\shuttle\shuttle_creation\shuttle_upgrades.dm" -#include "code\modules\smithing\anvil.dm" -#include "code\modules\smithing\finished_items.dm" -#include "code\modules\smithing\furnace.dm" -#include "code\modules\smithing\smithed_items.dm" #include "code\modules\spells\spell.dm" #include "code\modules\spells\spell_types\aimed.dm" #include "code\modules\spells\spell_types\area_teleport.dm" @@ -3869,4 +3865,13 @@ #include "interface\menu.dm" #include "interface\stylesheet.dm" #include "interface\skin.dmf" +#include "modular_BD2\blacksmith\code\additions.dm" +#include "modular_BD2\blacksmith\code\anvil.dm" +#include "modular_BD2\blacksmith\code\finished_items.dm" +#include "modular_BD2\blacksmith\code\furnace.dm" +#include "modular_BD2\blacksmith\code\smithed_items.dm" +#include "modular_BD2\general\code\modular_BD2.dm" +#include "modular_BD2\legio_invicta\code\legio_invicta.dm" +#include "modular_big-iron\code\game\machinery\radio_station.dm" +#include "modular_big-iron\code\game\objects\circuitboards\radio_station.dm" // END_INCLUDE diff --git a/icons/fallout/legacy.dmi b/icons/fallout/legacy.dmi new file mode 100644 index 00000000000..050f877deb0 Binary files /dev/null and b/icons/fallout/legacy.dmi differ diff --git a/icons/fallout/machines/autolathe.dmi b/icons/fallout/machines/autolathe.dmi new file mode 100644 index 00000000000..17bcf8dedcb Binary files /dev/null and b/icons/fallout/machines/autolathe.dmi differ diff --git a/icons/fallout/machines/reloadingbench.dmi b/icons/fallout/machines/reloadingbench.dmi new file mode 100644 index 00000000000..f35410a1a24 Binary files /dev/null and b/icons/fallout/machines/reloadingbench.dmi differ diff --git a/icons/fallout/objects/furniture/stationary.dmi b/icons/fallout/objects/furniture/stationary.dmi index 80f6feeef6b..462557590d1 100644 Binary files a/icons/fallout/objects/furniture/stationary.dmi and b/icons/fallout/objects/furniture/stationary.dmi differ diff --git a/icons/mob/inhands/items_lefthand.dmi b/icons/mob/inhands/items_lefthand.dmi index e2a80f99147..1729b701cad 100644 Binary files a/icons/mob/inhands/items_lefthand.dmi and b/icons/mob/inhands/items_lefthand.dmi differ diff --git a/icons/mob/inhands/items_righthand.dmi b/icons/mob/inhands/items_righthand.dmi index df9c4dd55a1..653934a0733 100644 Binary files a/icons/mob/inhands/items_righthand.dmi and b/icons/mob/inhands/items_righthand.dmi differ diff --git a/icons/obj/crates.dmi b/icons/obj/crates.dmi index 19fbc0be73e..a3343f8fb6f 100644 Binary files a/icons/obj/crates.dmi and b/icons/obj/crates.dmi differ diff --git a/icons/obj/machines/disk_recorder.dmi b/icons/obj/machines/disk_recorder.dmi new file mode 100644 index 00000000000..0f73c7ab035 Binary files /dev/null and b/icons/obj/machines/disk_recorder.dmi differ diff --git a/icons/obj/rack.dmi b/icons/obj/rack.dmi index 4dc7004be87..b7c3640e638 100644 Binary files a/icons/obj/rack.dmi and b/icons/obj/rack.dmi differ diff --git a/icons/obj/stationobjs.dmi b/icons/obj/stationobjs.dmi index f042f40cdff..f010c38e625 100644 Binary files a/icons/obj/stationobjs.dmi and b/icons/obj/stationobjs.dmi differ diff --git a/modular_BD2/blacksmith/README.md b/modular_BD2/blacksmith/README.md new file mode 100644 index 00000000000..7b583ebf0af --- /dev/null +++ b/modular_BD2/blacksmith/README.md @@ -0,0 +1,97 @@ +# Blacksmithing Fallout Edition v.1.4 +## Who made this module? +Pebbles the 2nd. Credits at the end. + +## What is this module? +Ancient TG smithing code remodeled, new art, lot of new code and concepts. Now called Blacksmithing to differentiate it, and to avoid mixing with the mutated alpha stuff floating around. Changelog at the end. + +Core principles: +- Ingame documentation, not code diving (advice book, new description system) +- Visual/audio feedback and mood important +- Files sorted and defines used +- All items should be useful in some way, trade offs, gimmicks added +- Recipes organized so similar sorts of items use similar recipes (the more cutting, the more folds etc) +- EVERYTHING must have icons AND inhands. No more terrible sword pikes. +- As little reliant on outdated external stuff as possible. So no Ratvar, Narsie stuff. +- Reduced duplication and redundancy. Forging should be made on a anvil. + +## Is it complete? +Sort of. It works, but the following was planned, before time and heart ran out. + +- Radial menus instead of the pop up menus +- Adding more gimmicks, mood modifiers, etc +- Balancing (depends on the codebase since armor and competition varies in the extreme, pretty damn obvious. Try adjusting in increments instead of doubling values on the fly.) +- Perfecting sizing (standardized icon sizes, partway there but not all the way) +- Quenching affecting quality (intended 3 ways, air cooled, maybe 30s timer, -1, water temper normal, oil temper +1) +- X and Y offsets dynamic so the long items (spears etc) can have the workpiece centered then moved to the finished position once dofinish is done +- Replacing forge mittens with tongs (having both useful would be optimal) + +If you plan on adding or changing stuff ADD changelog to the end of this readme. Adjust damage by changing the define values first, not by messing with the formulas, for obvious reasons. + +## Whats new? +So much its hard to list +Item quality much less impactful (this just means low quality items arent completely useless) + +Light & Sound: Whole bunch of overlays, lighting, sounds added to all steps of the process + +Steps: Heat ingot, place on anvil, hammer it, quench it, add finisher, done. + +Repathing: Items in the module mostly shifted to root /blacksmith in the path for easier mapping and finding them in the gamepanel for admins. They are part of the same system and its good they are easy to find. + +Forge mittens are sort of a stand-in for tongs, its what you use for touching hot metal, not any flimsy glove. + +Basic idea with the belt slot/back slot for weapons is that it makes sheath objects redundant, just make the correct slots for the item. + +Various effects added: Crusher harming ghoul mobs, axes extra damage to barricades, dagger eyestab (relies on the inheritance of eyecover objects to NOT be FUBAR to work well.), use of defines + +## Known issues + +The anvil refactor Gremling did solve some issues but sadly seems to have had some side-effects, the elusive overlay not being cut properly on live servers being the main one. I am not able to replicate the issue offline and so cannot see any solution to it currently. +(when a workpiece is finished sometimes the overlay remains on the anvil, and occasionally the same happens when quenching.) +Armor pieces made from smithing are not affected by quality and material currently. This is WAD but a bit crude. +Some tools do not inherit the force calculated on quality correctly, notes in finished items about this. + +## Some facts about the Blacksmith system + +* TG wikis will not help you very much, its been totally overhauled, even if the same framework is used. The Forgemasters Primer was written to replace the need for out of game guides. +* Materials do affect the end product in exactly the same way as in the old system, the difference here is the space replicant alloyed bronze has been replaced by "real" bronze so is no longer stronger than iron. This means for most weapons a maximum 10% boost in the raw force, or 20% using the non existent pre-war steel ingot. This has been true since day 1 of the beta, and anyone claiming otherwise is incorrect. +* Quality of hammer, and anvil, and the level of blacksmithing the user has all play a part in the final product quality, that in turn affects the base force and sometimes AP or other attributes such as pickaxe speed. +* End product stats are based on the finished_items.dm values, with material/qualitiy modifiers on top, so expect rapidly compounding values if you make big changes to the base stats, at least for wielded items which have various multipliers. + + +## Credits + +I wish to be clear. this module is my work, and it is a total rework of the entire old TG smithing systen, adding many features such as sound, sparks, text feedback, use of overlays, light system, etc, and replacing every asset. The visually similar system floating around on some servers that lack this module are based on my old beta stuff, they are incomplete and I can't really guarantee anything about them. All the designs are mine, the primer, mittens, so on, the concepts, mechanics, and assets (code copy paste with edits tho) used to make leather strips, to make wooden rods from planks, to make chains, the smithed armor, the plates, ad nauseum. It could not exist without the base TG smithing code however, I am not a coder, I do design and art, and edit/adapt existing code, so if you want to give the coder people props look below. For getting to finish it uninterrupted I'd like to thank Raptor and Lamasmaster. + +The base TG smithing code is still very much the core, made by lolman in 2019. +GremlingSS refactored the code in anvil.dm in 2022, wich was adapted and then used for this module. + +Sounds: A few edited base FO13 ones, but the anvil sounds were made by me, they are from royalty free sampling from videvo.net edited a lot in Audacity. + +Sprites: (basically I made all the art, TLDR) furnace, sandstone furnace, chain, leatherstrip, dagger, machete, gladius, macheter, waki, saw, sabre, sword, spatha, katana, spear, lance, trident, crusher, mace, univeral tool, axe, waraxe, scrapblade, javelin, bola, knife, hammer, sledgehammer, shovel, pickaxe, prospect, crowbar, ball and chain, ingot, anvil, tablevil, sandvil, overlays, blacksmith mittens, armor pieces, smithed armor, quenching through, metalworking bench - Pebbles the 2nd +(Waraxe is based on the Warhoned axe by Raptor, wich in turn was based on my fireaxe art but with a twist.) +sabre hilt, bowie blade, longsword(scraptana), ring, bola reuses a fair bit from legacy sprites, so inspiration credit to their makers which sadly is not known to me. The anvil outline loans heavily from the old one but the sprite is new. + +Since I'll not be around to maintain this forever feel free to edit for fixing issues I might have missed or whatever but please keep it documented and not shitty, thanks. +- Pebbles the 2nd + + +## Changelog + +v1.2 - Peb +- Added armor pieces, fixed some errors impacting labeling + +v1.3 - Peb +- Added smithed armor +- Adjusted some volumes, quality cutoff points in anvil.dm + +v1.4 - Peb +- New furnace art, metal and sandstone, with smoke and such. +- Added new sledgehammer art, so it matches the stuff in the module since its connected +- Added all missing inhands, spears now proper long +- Added some minor shading on a bunch of icons +- Adjusted pickaxe quality speed/range modifiers, was insanely good. +- Added the metal workbench + updated its art since it was made as a part of the module originally +- Changed notsword to workpiece because why God +- Refactored smithed twohanders so the correct art loads when wielded even in stupid Eris code + diff --git a/modular_BD2/blacksmith/code/additions.dm b/modular_BD2/blacksmith/code/additions.dm new file mode 100644 index 00000000000..e3ad4be726b --- /dev/null +++ b/modular_BD2/blacksmith/code/additions.dm @@ -0,0 +1,318 @@ + +#define GLOW_BRIGHT 2.5 +#define GLOW_MODERATE 0.75 +#define GLOW_WEAK 0.4 + +#define WOODEN_ROD /obj/item/blacksmith/woodenrod +#define SWORD_HANDLE /obj/item/blacksmith/swordhandle +#define LEATHER_STRIP /obj/item/stack/sheet/leatherstrips +#define CHAIN /obj/item/blacksmith/chain + +#define QUALITY_MODIFIER quality + +#define FORCE_SMITH_REACH 14 +#define FORCE_SMITH_LOW 18 +#define FORCE_SMITH_HIGH 23 + + +////////////////////////////////////// +// // +// QUENCHING TROUGH // +// // +////////////////////////////////////// + +/obj/structure/blacksmith/quenching + name = "quenching trough" + desc = "Water in a open box, for tempering hot metal in." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "quench" + max_integrity = 500 + density = TRUE + anchored = TRUE + var/toohot + +/obj/structure/blacksmith/quenching/attackby(obj/item/I, mob/user) + if(istype(I, /obj/item/smithing)) + var/obj/item/smithing/untempered = I + if(untempered.toohot == FALSE) + playsound(src, 'sound/effects/water_wade4.ogg',50, 1) + return + to_chat(user, "You temper the [untempered] by quenching it in the water. There is a loud hiss and a puff of steam.") + playsound(src, 'modular_BD2/blacksmith/sound/steam_whoosh.ogg', 40, TRUE) + flick("quench_boil",src) + var/datum/effect_system/steam_spread/puff = new /datum/effect_system/steam_spread/() + puff.effect_type = /obj/effect/particle_effect/steam + puff.set_up(2, 0, src) + puff.start() + if(!do_after(user, 15, TRUE, src)) + return + untempered.toohot = FALSE + untempered.istempered() + I.on_attack_hand(user) + else + . = ..() + +/obj/structure/blacksmith/quenching/attackby(obj/item/I, mob/user) + if(istype(I, /obj/item/blacksmith/ingot)) + var/obj/item/blacksmith/ingot/workpiece = I + if(workpiece.workability == FALSE) + playsound(src, 'modular_BD2/blacksmith/sound/water_splash2.ogg',50, 1) + return + to_chat(user, "You cool the [workpiece] in the water.") + playsound(src, 'modular_BD2/blacksmith/sound/steam_short.ogg',70, 1) + flick("quench_boil",src) + var/datum/effect_system/steam_spread/puff = new /datum/effect_system/steam_spread/() + puff.effect_type = /obj/effect/particle_effect/steam + puff.set_up(1, 0, src) + puff.start() + workpiece.workability = FALSE + workpiece.icon_state = "ingot" + workpiece.set_light_on(FALSE) + I.on_attack_hand(user) + else + . = ..() + +/* THESE THINGS ALREADY COPIED TO BASE CODE +// Bronze less retarded +/datum/material/bronze + strength_modifier = 1 + +/datum/material/adamantine + strength_modifier = 1.2 + + +// ------------ SLAG ------------------ Makes slag more suitable visually for the interactions with the anvil +/obj/item/stack/ore/slag + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' +*/ + +// ------------ BLACKSMITH MITTENS ------------------ Mittens, since finger gloves and heat insulation is a lame combo + +/obj/item/clothing/gloves/blacksmith_mittens + name = "forge mittens" + desc = "A pair of heavy duty leather mittens designed to protect the wearer when metalforging. Unsuited for tasks requiring manual dexterity." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "blacksmith_mittens" + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "blacksmith_mittens" + transfer_prints = FALSE + strip_delay = 10 + heat_protection = HANDS + max_heat_protection_temperature = GLOVES_MAX_TEMP_PROTECT + +/obj/item/clothing/gloves/blacksmith_mittens/equipped(mob/user, slot) + . = ..() + if(ishuman(user) && user.mind && slot == SLOT_HANDS) + ADD_TRAIT(user, TRAIT_CLUMSY, CLOTHING_TRAIT) + +/obj/item/clothing/gloves/blacksmith_mittens/dropped(mob/user) + . = ..() + REMOVE_TRAIT(user, TRAIT_CLUMSY, CLOTHING_TRAIT) + +/* COPIED TO BASE CODE +// ------------ SLEDGEHAMMER (SIMPLE) ------------------ Just a art redirect, since the sledgehammer/simple is integral to blacksmithing I want the art to match + +/obj/item/twohanded/sledgehammer/simple + name = "sledgehammer" + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + icon_state = "sledgehammer" + icon_prefix = "sledgehammer" + wielded_icon = "sledgehammer2" + qualitymod = 0 +*/ + +/////////////////////////////////// +// ADVICE FOR BLACKSMITH ROOKIES // +/////////////////////////////////// + +// Explains most things ingame so you dont have to code dive to learn. +/obj/item/book/manual/advice_blacksmith + name = "The Forgemasters Primer" + desc = "A thin book with some basic advice on how to use a hammer and anvil, copied by hand." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + icon_state = "advice_smithing" + author = "Forgemaster Gallius" + title = "Advice on Blacksmithing - For hotheaded whelps" + dat = {" + + + + + + +

    How to work a hammer and anvil and produce basic tools.

    + + The needed tools are: forging mittens, metal ingots, a furnace, wood planks, an anvil, quenching trough and a suitable hammer. +

    +

      +
    1. Forging mittens: Only very thick mittens are really reliable enough for touching red-hot metal. Make some from leather if you need to.
    2. +
    3. Metal ingots: Take the metal stack you want to work in your hand and fashion ingots from it. (inhand crafting)
    4. +
    5. Furnace: Needs fuel, welding fuel most commonly. Five measures of fuel burns fast but is enough to heat a couple ingots if you are fast.
    6. +
    7. Wooden bits: Cut down planks to rods with something sharp. Then cut leather to strips and wrap it around the rod for making a sword handle, or directly on the workpiece for some tools.
    8. +
    9. Metal bits: On occasion you might need some chain to complete your work, if so, take a metal sheet in your hand and make a length of chain from it. (inhand crafting)
    10. +
    11. Anvil: A solid anvil makes things easier. (crafting menu forging & blacksmithing)
    12. +
    13. Quenching trough: Basically a big tub of water, or oil. (crafting menu forging & blacksmithing)
    14. +
    15. Hammer: Most commonly a sledgehammer is used for the first work, which is making a better hammer. Craft one to get going. (crafting menu forging & blacksmithing)
    16. +
    +

    + +

    The process

    + +

    +

      +
    1. Heat the ingot, move it to the anvil.
    2. +
    3. Prepare the metal, weak, strong and heavy hits enhance the quality but overworking the metal will produce slag and you have to start over. Try a couple hits then move on to making the item if you have no other ideas.
    4. +
    5. Follow the secret smithing recipe for the item you want to make, the end result will depend on how much experience you have smithing, and the quality of your tools and preparations.
    6. +
    7. Quenching: when the hot metal piece is finished, you need to temper it in cold fluids in a trough to finish it, before adding fittings such as a wooden rod, sword handle, chain or leather strips.
    8. +
    9. The first item you make should be a good hammer, you might need to repeat the process and replace the previous hammer with a new one in steps. Try to have at least a masterworked iron hammer before moving on to other items to save you headache.
    10. +
    +

    + + +

    Some secret smithing recipes.

    + + These are some of the items that can be made with hot iron and a steady hand. Results are not always the same depending on the anvil used. +

    +

      +
    1. Hammer: (BPP) Bend the metal, then punch it like you would a profligates face until the hammerhead is done. Add a rod.
    2. +
    3. Shovel: (BUU) Bend the metal, then upset. Add a rod.
    4. +
    5. Crowbar: (BBB) Bend the metal until you got the crowbar done, then wrap it in leather strips. Better than the usual crowbars folks use nowadays.
    6. +
    7. Pickaxe: (BFF) Bend the metal, then fold it into shape twice, then add a wooden rod.
    8. +
    9. Prospecting pick: (BFS) Bend the metal, then fold it into shape and shrink it, then add a wooden rod. Useful for finding mineral deposits.
    10. +
    11. Kitchen knife: (BSD) Bend the metal, shrink and draw it, then add a knife handle. A perfect gift for women.
    12. +
    13. Universal tool: (BBU) Want a crowbar with a blade forgewelded on? Bend it twice, upset, then wrap it in leather strips when tempered.
    14. +
    15. Scrapsaw: (FFSU) Fold twice, shrink and upset, wrap it with a leather strip once tempered. If you want a ugly ass saw, here you go. You could probably try to catch a blade with it I guess.
    16. + +
    17. Rings: (SSS) Tiny things, my fingers hurt when I try to work it, but if you youngsters want to make one just shrink the metal to shape. Might cheer you up.
    18. +
    19. Ball and chain: (PBU) Punch the metal, bend and upset it. Add a chain and then snap it on the slaves leg, and laugh while they hobble about. Silly slave.
    20. +
    21. Armor piece: (PUP) Punch the metal, upset and punch some more holes. Use the metal together with leather to make armoured gauntlets and such.
    22. + +
    23. Bowie knife: (DFS) Draw fold and shrink it, add a sword handle and THIS is a knife.
    24. +
    25. Dagger: (DDS) Draw draw and shrink it, add a sword handle and you got a tiny little weapon.
    26. + +
    27. Machete: (FDF) Fold the metal, draw it, fold it more. Add handle.
    28. +
    29. Lawnmower machete: (FUF) Fold the metal, upset it and ugh..yeah, fold it more. Add handle.
    30. + +
    31. Sword: (FFDF) You must fold the metal some, then draw it and fold it again. Add a handle and you got a fine blade!
    32. +
    33. Sabre: (FFDD) You must fold the metal some, then draw it into a proper thin shape. Add a handle and you got a curved blade.
    34. + +
    35. Longsword: (FFFDD) Fold, fold, fold then draw twice.. Done right, you get a proper sharp sword, after adding a sword handle.
    36. +
    37. Katana: (FFFFF) Fold, fold, then FOLD SOME MORE. These curved swords look weird but are reasonably sharp I guess.
    38. +
    39. Wakizashi: (FFFS) Fold thrice and shrink it, add a handle and you got a small dinky blade.
    40. + +
    41. Mace: (UPU) Fold, draw, and fold twice, add a handle and you got a small dinky blade.
    42. +
    43. Scrap blade: (UDPP) Fold, draw, and fold twice, add a handle and you got a small dinky blade.
    44. + +
    45. Heavy axe: (UDSP) Upset the hot metal, draw it, shrink it, punch holes in it. Add a wooden rod, then go chop down some wood or enemies. Easy.
    46. +
    47. Crusher: (UUPP) Upset the hot metal, then use the puncher to make holes for the fittings. Add a wooden rod and crush those disgusting ghouls like twigs.
    48. + +
    49. Spear: (DDDF) Draw the metal thrice then fold it. Add a rod, and enjoy a simple but effective weapon.
    50. +
    51. Trident: (DDBF) Draw the metal thrice then fold it. Add a rod, and enjoy a simple but effective weapon.
    52. + +
    53. Javelin: (SDU) Shrink, draw, upset, add a wooden rod and throw it in someones face.
    54. +
    55. Throwing knife: (SDD) Shrink and draw the metal twice, then add leather strips and there you go.
    56. +
    57. Bola: (SUU) Shrink then upset twice, add a chain and you got a nice slavecatcher.
    58. + +
    59. For forgemasters trained in the east, you of course also know the ways to make our own weapons, that outsiders are unfit to touch, unless its tasting its edge.
    60. +
    61. Legion Spatha: (FFBF) You must fold the metal some, then bend it and fold some more. Add a handle and marvel at the beauty of the Legions finest blade!
    62. +
    63. Legion Lance: (DBDF) Draw the metal thrice then fold it. Add a rod, and enjoy a simple but effective weapon.
    64. +
    65. Legion Waraxe: (UDUP) Upset the hot metal, draw, upset, and punch it. Add a wooden rod, and behold the perfection of a Legion war axe.
    66. +
    67. Legion Gladius: (FBF) Fold the metal, bend it and ugh..yeah, fold it more. Add handle.
    68. + +
    +

    + If you need more metal for your work, stop being lazy and smelt the ores in a furnace then keep going! + Now go and make things of metal! + + + + "} + +/* COPIED TO BASE CODE +// ------------ METALWORKING BENCH ------------------ Part of the module, for metalworking that doesnt need a whole forge setup + +/obj/machinery/workbench/forge // should be repathed to worbench/metal + name = "metalworking bench" + desc = "A workbench with a drill press, a makeshift blowtorch setup, and various tools for making crude weapons and tools." + icon = 'modular_BD2/blacksmith/icons/workbench64x32.dmi' + icon_state = "bench_metal" +*/ + + +/* +// Stacking craftin items visual updater +/obj/item/stack/crafting/update_icon_state() + var/amount = get_amount() + if(amount <= 5) + icon_state = initial(icon_state) + else if(amount <= 25) + icon_state = "[initial(icon_state)]_2" + else + icon_state = "[initial(icon_state)]_3" + +// Adapted for the specific bullet remnant stacking +/obj/item/stack/crafting/powder/update_icon_state() + var/amount = get_amount() + if(amount <= 80) + icon_state = initial(icon_state) + else if(amount <= 160) + icon_state = "[initial(icon_state)]_2" + else + icon_state = "[initial(icon_state)]_3" +*/ + +// ------------ COAL & COKE ------------------ New base material and the sheet that can be used as fuel or ground for charcoal + +/datum/material/coal + name = "coal" + desc = "coal" + color = "#0a0a0a" + alpha = 150 + categories = list(MAT_CATEGORY_RIGID = TRUE, MAT_CATEGORY_BASE_RECIPES = FALSE) + sheet_type = /obj/item/stack/ore/coal + value_per_unit = 0.0050 + +/obj/item/stack/ore/coal // turns to coke when heated in a Furnace or ORM + name = "coal" + desc = "Pure coal needs heat-processing to become good fuel." + icon_state = "ore_coal" + singular_name = "lump of coal" + points = 2 + custom_materials = null + refined_type = /obj/item/stack/sheet/coke + merge_type = /obj/item/stack/ore/coal + resistance_flags = FLAMMABLE + +/obj/item/stack/sheet/coke // Can be used to fuel Furnaces, Campfires, Barrel Fires, Potbelly stoves, Fireplaces, or grind for charcoal + name = "coke" + desc = "Coke is what you get when you heat-treat coal. It's a good fuel for burning." + singular_name = "bag of coke" + icon_state = "sheet_coke" + custom_materials = null + throwforce = 2 + grind_results = list(/datum/reagent/medicine/charcoal = 5) + material_type = /datum/material/coal + merge_type = /obj/item/stack/sheet/coke + resistance_flags = FLAMMABLE + +/obj/item/stack/sheet/coke/twenty + amount = 20 + +/turf/closed/mineral/coal + mineralType = /obj/item/stack/ore/coal + spreadChance = 5 + spread = 1 + scan_state = "rock_Coal" + +// woodenrod production made, in sheet_types.dm /obj/item/stack/sheet/mineral/wood/attackby(obj/item/W, mob/user, params) diff --git a/code/modules/smithing/anvil.dm b/modular_BD2/blacksmith/code/anvil.dm similarity index 63% rename from code/modules/smithing/anvil.dm rename to modular_BD2/blacksmith/code/anvil.dm index 16957a532e5..0da17fd723f 100644 --- a/code/modules/smithing/anvil.dm +++ b/modular_BD2/blacksmith/code/anvil.dm @@ -3,45 +3,50 @@ #define WORKPIECE_FINISHED 3 #define WORKPIECE_SLAG 5 -//bend start\tools, maybe add more tools? -#define RECIPE_PICKAXE "bff" //bend fold fold -#define RECIPE_SHOVEL "buu" //bend upset upset #define RECIPE_HAMMER "bpp" //bend punch punch +#define RECIPE_SHOVEL "buu" //bend upset upset +#define RECIPE_PICKAXE "bff" //bend fold fold #define RECIPE_PROSPECTPICK "bfs" //bend fold shrink #define RECIPE_KITCHENKNIFE "bsd" //bend shrink draw #define RECIPE_CROWBAR "bbb" //bend bend bend #define RECIPE_UNITOOL "bbu" //bend bend upset +#define RECIPE_SCRAPSAW "ffsu" //fold fold shrink upset -//shrink start \maybe add armor here? #define RECIPE_RING "sss" //shrink shrink shrink - -//punch start \maybe add armor here? #define RECIPE_BALLANDCHAIN "pbu" //punch bend upset +#define RECIPE_ARMOR_PIECE "pup" //punch upset punch + +#define RECIPE_BOWIE "dfs" //draw fold shrink +#define RECIPE_DAGGER "dds" //draw draw shrink -//fold start \Swords need a buff or need their math exposed to players \ Will also add more comments later #define RECIPE_MACHETE "fdf" //fold draw fold -#define RECIPE_SABRE "ffdd" //fold fold draw draw +#define RECIPE_MACHREFORG "fuf" //fold upset fold lawnmower classic + #define RECIPE_SWORD "ffdf" // fold fold draw fold -#define RECIPE_WAKI "fffd" //fold fold fold draw +#define RECIPE_SABRE "ffdd" //fold fold draw draw + +#define RECIPE_LONGSWORD "fffdd" //fold fold fold draw draw #define RECIPE_KATANA "fffff" //fold fold fold fold fold -#define RECIPE_MACHREFORG "fddf" //fold draw draw fold +#define RECIPE_WAKI "fffs" //fold fold fold shrink -//upset start \Mostly 2h weapons, save for the mace #define RECIPE_MACE "upu" //upset punch upset +#define RECIPE_SCRAP "udpp" //upset draw shrink punch #define RECIPE_AXE "udsp" //upset draw shrink punch -#define RECIPE_SCRAP "udpp" //upset draw shrink punch \2h sword +#define RECIPE_CRUSHER "uupp" //upset upset punch punch + +#define RECIPE_SPEAR "dddf" //draw draw draw fold +#define RECIPE_TRIDENT "ddbf" //draw draw bend fold -//draw start \Maybe add a shield here? -#define RECIPE_DAGGER "dfs" //draw fold shrink -#define RECIPE_SPEAR "ddbf" //draw draw bend fold -#define RECIPE_JAVELIN "dbf" //draw bend fold -#define RECIPE_THROWING "dbd" //draw bend draw +#define RECIPE_JAVELIN "sdu" //shrink draw upset +#define RECIPE_THROWING "sdd" //shrink draw draw +#define RECIPE_BOLA "suu" //shrink upset upset -//Legion themed\ not exclusive to any anvil -#define RECIPE_LANCE "ddfp" //draw draw fold punch \spear reskin -#define RECIPE_GLADIUS "fbf" //fold bend fold \Machete reskin -#define RECIPE_SPATHA "ffbf" // fold fold bend fold \Sword Reskin -#define RECIPE_WARHONED "udup" //upset draw upset punch\ 2H axe reskin + +// LEGION SPECIFIC +#define RECIPE_GLADIUS "fbf" //fold bend fold +#define RECIPE_LANCE "dbdf" //draw bend fold fold LEGION +#define RECIPE_SPATHA "ffbf" // fold fold bend fold LEGION +#define RECIPE_WARAXE "udup" //upset draw upset punch LEGION GLOBAL_LIST_INIT(anvil_recipes, list( RECIPE_HAMMER = /obj/item/smithing/hammerhead, @@ -50,40 +55,49 @@ GLOBAL_LIST_INIT(anvil_recipes, list( RECIPE_PROSPECTPICK = /obj/item/smithing/prospectingpickhead, RECIPE_KITCHENKNIFE = /obj/item/smithing/knifeblade, RECIPE_CROWBAR = /obj/item/smithing/crowbar, + RECIPE_UNITOOL = /obj/item/smithing/unitool, RECIPE_RING = /obj/item/smithing/special/jewelry/ring, RECIPE_BALLANDCHAIN = /obj/item/smithing/ballandchain, + RECIPE_ARMOR_PIECE = /obj/item/smithing/armor_piece, RECIPE_DAGGER = /obj/item/smithing/daggerblade, + RECIPE_BOWIE = /obj/item/smithing/bowieblade, RECIPE_MACHETE = /obj/item/smithing/macheteblade, + RECIPE_MACHREFORG = /obj/item/smithing/macheterblade, RECIPE_SWORD = /obj/item/smithing/swordblade, RECIPE_SABRE = /obj/item/smithing/sabreblade, - RECIPE_WAKI = /obj/item/smithing/wakiblade, + RECIPE_LONGSWORD = /obj/item/smithing/longswordblade, RECIPE_KATANA = /obj/item/smithing/katanablade, + RECIPE_WAKI = /obj/item/smithing/wakiblade, + RECIPE_SCRAPSAW = /obj/item/smithing/scrapsaw, RECIPE_MACE = /obj/item/smithing/macehead, + RECIPE_SCRAP = /obj/item/smithing/scrapblade, RECIPE_AXE = /obj/item/smithing/axehead, + RECIPE_CRUSHER = /obj/item/smithing/crusherhead, RECIPE_SPEAR = /obj/item/smithing/spearhead, + RECIPE_TRIDENT = /obj/item/smithing/tridenthead, RECIPE_JAVELIN = /obj/item/smithing/javelinhead, RECIPE_THROWING = /obj/item/smithing/throwingknife, - RECIPE_UNITOOL = /obj/item/smithing/unitool, - RECIPE_MACHREFORG = /obj/item/smithing/macheterblade, - RECIPE_SCRAP = /obj/item/smithing/scrapblade, + RECIPE_BOLA = /obj/item/smithing/bola, RECIPE_GLADIUS = /obj/item/smithing/gladiusblade, RECIPE_SPATHA = /obj/item/smithing/spathablade, - RECIPE_WARHONED = /obj/item/smithing/warhonedhead, - RECIPE_LANCE = /obj/item/smithing/lancehead)) + RECIPE_WARAXE = /obj/item/smithing/waraxehead, + RECIPE_LANCE = /obj/item/smithing/lancehead, + )) + // Logic of smithing recipes: Tools start with bend and have 3 steps. 1h weapons have 3-4 steps. 2h weapons have 4-5 steps. Bigger bladed stuff start with a fold. Pointy stuff generally start with a draw. Unusual stuff migth start with upset. // Point of having a structure is obviously to help remember, not just keeping every recipe as pure rote memory with no internal logic. If you add more stuff and fuck this up and don't read comments I hope you get a prolapse. - Pebbles -/obj/structure/anvil - name = "anvil" - desc = "Base class of anvil. This shouldn't exist, but is useable." - icon = 'icons/fallout/objects/crafting/blacksmith.dmi' - icon_state = "anvil" +/obj/structure/blacksmith/anvil + name = "anvil template" + desc = "This should not be visible - please file a bug report." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' density = TRUE anchored = TRUE + max_integrity = 1000 light_system = MOVABLE_LIGHT light_range = 2 - light_power = 0.75 + light_power = GLOW_MODERATE light_color = LIGHT_COLOR_FIRE light_on = FALSE var/busy = FALSE //If someone is already interacting with this anvil @@ -92,21 +106,20 @@ GLOBAL_LIST_INIT(anvil_recipes, list( var/anvilquality = 0 var/currentquality = 0 //lolman? what the fuck do these vars do? var/currentsteps = 0 //even i don't know - var/outrightfailchance = 1 //todo: document this shit + var/outrightfailchance = 5 //todo: document this shit var/stepsdone = "" - var/rng = FALSE + var/rng = TRUE var/debug = FALSE //vv this if you want an artifact var/artifactrolled = FALSE - var/itemqualitymax = 20 //A quality 8 bronze spear does less damage than a regular bone spear from craftmenu, lol - + var/itemqualitymax = 10 -/obj/structure/anvil/Initialize(mapload) +/obj/structure/blacksmith/anvil/Initialize(mapload) . = ..() - RegisterSignal(src, COMSIG_CLICK_ALT, PROC_REF(ResetAnvil)) // emergency way to reset the anvil incase something goes wrong. + RegisterSignal(src, COMSIG_CLICK_ALT, .proc/ResetAnvil) // emergency way to reset the anvil incase something goes wrong. currentquality = anvilquality -/obj/structure/anvil/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/ingot)) // That's it we're refactoring this code because I can't im literally crying rn ; _; +/obj/structure/blacksmith/anvil/attackby(obj/item/I, mob/user) + if(istype(I, /obj/item/blacksmith/ingot)) // That's it we're refactoring this code because I can't im literally crying rn ; _; return HandleIngot(I, user) if(istype(I, /obj/item/melee/smith/hammer) || istype(I, /obj/item/twohanded/sledgehammer/simple)) // Hammer interactions: @@ -126,17 +139,17 @@ GLOBAL_LIST_INIT(anvil_recipes, list( return ..() -/obj/structure/anvil/proc/CheckBusy(mob/user) +/obj/structure/blacksmith/anvil/proc/CheckBusy(mob/user) var/mob/living/carbon/human/F = user return F.busy || busy -/obj/structure/anvil/proc/SetBusy(value, mob/living/carbon/human/H) +/obj/structure/blacksmith/anvil/proc/SetBusy(value, mob/living/carbon/human/H) if(H) H.busy = value busy = value -/obj/structure/anvil/proc/ResetAnvil() +/obj/structure/blacksmith/anvil/proc/ResetAnvil() set_light_on(FALSE) currentquality = initial(currentquality) stepsdone = "" @@ -144,23 +157,22 @@ GLOBAL_LIST_INIT(anvil_recipes, list( outrightfailchance = initial(outrightfailchance) artifactrolled = FALSE workpiece_state = FALSE - - cut_overlay(image(icon= 'icons/fallout/objects/crafting/blacksmith.dmi',icon_state="workpiece")) + cut_overlay(image(icon= 'modular_BD2/blacksmith/icons/blacksmith.dmi',icon_state="workpiece")) SetBusy(FALSE, null) -/obj/structure/anvil/proc/HandleIngot(obj/item/ingot/notsword, mob/user) +/obj/structure/blacksmith/anvil/proc/HandleIngot(obj/item/blacksmith/ingot/workpiece, mob/user) if(workpiece_state) to_chat(user, "There's already a workpiece! Finish it or take it off.") return FALSE - if(notsword.workability == "shapeable") + if(workpiece.workability == "shapeable") workpiece_state = WORKPIECE_PRESENT - workpiece_material = notsword.custom_materials - to_chat(user, "You place the [notsword] on the [src].") + workpiece_material = workpiece.custom_materials + to_chat(user, "You place the [workpiece] on the [src].") currentquality = initial(currentquality) if(workpiece_state == WORKPIECE_PRESENT) - add_overlay(image(icon= 'icons/fallout/objects/crafting/blacksmith.dmi',icon_state="workpiece")) + add_overlay(image(icon= 'modular_BD2/blacksmith/icons/blacksmith.dmi',icon_state="workpiece")) set_light_on(TRUE) var/skillmod = 0 @@ -168,24 +180,24 @@ GLOBAL_LIST_INIT(anvil_recipes, list( skillmod = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/2 currentquality += skillmod - qdel(notsword) + qdel(workpiece) else to_chat(user, "The ingot isn't workable yet!") return FALSE -/obj/structure/anvil/proc/do_shaping(mob/user, qualitychange) +/obj/structure/blacksmith/anvil/proc/do_shaping(mob/user, qualitychange) if(!iscarbon(user)) return - + SetBusy(TRUE, user) currentquality += qualitychange workpiece_state = WORKPIECE_INPROGRESS // set it so we're working on it. - + // Present choice selection. var/list/shapingsteps = list("weak hit", "strong hit", "heavy hit", "fold", "draw", "shrink", "bend", "punch", "upset") //weak/strong/heavy hit affect strength. All the other steps shape. var/stepdone = input(user, "How would you like to work the metal?") in shapingsteps - + // if user is not in range, remove business. if(!locate(src) in range(1, user)) @@ -193,74 +205,75 @@ GLOBAL_LIST_INIT(anvil_recipes, list( // Time it takes for us to uh...forge..? - var/steptime = 50 - switch(stepdone) + var/steptime = 45 // sounds edited to fit 4.5 seconds + switch(stepdone) // Have some more then if("weak hit") - playsound(src, 'code/modules/smithing/sound/anvil_weak.ogg',45) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_weak.ogg',100) user.visible_message("[user] carefully hammers out imperfections in the metal.", \ "You carefully hammer out imperfections in the metal.") if("strong hit") - playsound(src, 'code/modules/smithing/sound/anvil_strong.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_strong.ogg',100) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] hammers out imperfections in the metal.", \ "You hammer out imperfections in the metal.") if("heavy hit") - playsound(src, 'code/modules/smithing/sound/anvil_heavy.ogg',45) - do_smithing_sparks(2, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_heavy.ogg',100) + do_smithing_sparks(2, TRUE, src) user.visible_message("[user] forcefully hammers out imperfections in the metal.", \ "You forcefuly hammer out imperfections in the metal.") if("fold") - playsound(src, 'code/modules/smithing/sound/anvil_double1.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_double1.ogg',95) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] folds the metal.", \ "You fold the metal.") if("draw") - playsound(src, 'code/modules/smithing/sound/anvil_double2.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_double2.ogg',80) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] hammers both sides of the metal, drawing it out.", \ "You hammer both sides of the metal, drawing it out.") if("shrink") - playsound(src, 'code/modules/smithing/sound/anvil_rapid.ogg',45) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_rapid.ogg',100) do_smithing_sparks(1, TRUE, src) user.visible_message("[user] flattens the metal, shrinking it.", \ "You flatten the metal, shrinking it.") if("bend") - playsound(src, 'code/modules/smithing/sound/anvil_single1.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_single1.ogg',75) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] bends the metal, using the rounded end of the anvil.", \ "You bend the metal, using the rounded end of the anvil.") if("punch") - playsound(src, 'code/modules/smithing/sound/anvil_single2.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_single2.ogg',95) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] uses the puncher to make holes in the metal.", \ "You use the puncher to make holes in the metal.") if("upset") - playsound(src, 'code/modules/smithing/sound/anvil_double3.ogg',45) - do_smithing_sparks(1, TRUE, src) + playsound(src, 'modular_BD2/blacksmith/sound/anvil_double3.ogg',100) + do_smithing_sparks(1, TRUE, src) user.visible_message("[user] upsets the metal by hammering the thick end.", \ "You upset the metal by hammering the thick end.") - if(user.mind.skill_holder) // Skill modifier to make it faster at blacksmithing. - var/skillmod = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/8 + 1 //Makes this faster as EXP gain was lowered + if(user.mind.skill_holder) // Skill modifier to make it faster at blacksmithing. Limited to avoid going too far out of step with sounds. + var/skillmod = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/15 + 1 steptime = 50 / skillmod + if(!do_after(user, steptime, target = src)) return SetBusy(FALSE, user) - + // I hate this. // I'd rather die. switch(stepdone) if("weak hit") currentsteps += 1 - outrightfailchance += 5 + outrightfailchance += 4 currentquality += 1 if("strong hit") currentsteps += 2 - outrightfailchance += 9.5 + outrightfailchance += 8.5 currentquality += 2 if("heavy hit") currentsteps += 3 - outrightfailchance += 12.5 + outrightfailchance += 13 currentquality += 3 if("fold") stepsdone += "f" @@ -286,29 +299,23 @@ GLOBAL_LIST_INIT(anvil_recipes, list( stepsdone += "u" currentsteps += 1 currentquality -= 1 - - // Display message - user.show_message(span_notice("You [stepdone] the metal.")) - - // more sounds... uhhh... - //playsound(src, 'sound/effects/clang2.ogg',40, 2) - Keeping it commented for now. // sparkles~ - do_smithing_sparks(1, TRUE, src) - + do_smithing_sparks(1, TRUE, src) + // the stepsdone is a string of characters which are actions made. // Once it is more or equal to 3, call try finish. if(length(stepsdone) >= 3) tryfinish(user) - + SetBusy(FALSE, user) // Set it to false, cause we're done now some how. -/obj/structure/anvil/proc/tryfinish(mob/user) // Oh god before I prettify this code I just feel like I'm having a stroke at all this word garble. +/obj/structure/blacksmith/anvil/proc/tryfinish(mob/user) // Oh god before I prettify this code I just feel like I'm having a stroke at all this word garble. var/artifactchance = 0 - var/combinedqualitymax = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/4 + itemqualitymax //This is no longer as good. /2 divisor to /4 to make the max ~12 + var/combinedqualitymax = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/4 + itemqualitymax //This is no longer as good. /2 divisor to /4 to make the max ~12 if(!artifactrolled) // if there has not been a roll chance, do it now..? - artifactchance = (1+(user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/2))/1500 //Bumps this up as removal of high-tier smithing items and a decrease to their balance makes artifacts neccessary and worthwhile + artifactchance = (1+(user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing)/4))/2000 //Reduced. Artifacts are silly, fun on occasion but not meant be a balance crutch. Adjust base values until sweet spot instead ffs. //artifactrolled = TRUE --Disabled because this is a shitty mechanic. var/artifact = max(prob(artifactchance), debug) // If there is an artifact..? @@ -318,7 +325,7 @@ GLOBAL_LIST_INIT(anvil_recipes, list( if(user.mind.skill_holder) // Divide the failing chance based on the skillmodifier var/skillmod = user.mind.get_skill_level(/datum/skill/level/dwarfy/blacksmithing) / 10 + 1 finalfailchance = max(0, finalfailchance / skillmod) //lv 2 gives 20% less to fail, 3 30%, etc - + /////// // The two main conditionals @@ -326,9 +333,9 @@ GLOBAL_LIST_INIT(anvil_recipes, list( // I hate this. If you hit more than 10 times, or the final piece failed and you have no artifact. Why it gotta look so awkward. if((currentsteps > 10 || (rng && prob(finalfailchance))) && !artifact) - + to_chat(user, span_warning("You overwork the metal, causing it to turn into useless slag!")) - + new /obj/item/stack/ore/slag(get_turf(src)) // Spawn some slag ResetAnvil() // Resets it to be default. @@ -336,11 +343,11 @@ GLOBAL_LIST_INIT(anvil_recipes, list( if(user.mind.skill_holder) // give them some experience user.mind.auto_gain_experience(/datum/skill/level/dwarfy/blacksmithing, 50, 500000, silent = FALSE) //This shouldn't give you a full level until 3+ - return SetBusy(FALSE, user) - + return SetBusy(FALSE, user) + // IF YOU DIDN'T FUCK UP THE RECIPE for(var/i in GLOB.anvil_recipes) // for each recipes. - if(i == stepsdone) // if... "cum" == "bbu" idfk what the fuck am I looking at why isnt this a GLOB recipe list... + if(i == stepsdone) var/obj/item/smithing/finisheditem = GLOB.anvil_recipes[stepsdone] finisheditem = new finisheditem(get_turf(src)) // Lets just spawn the item in immediately! @@ -358,24 +365,12 @@ GLOBAL_LIST_INIT(anvil_recipes, list( else finisheditem.quality = min(currentquality, itemqualitymax) - // more switcheronies~ Adds a description - switch(finisheditem.quality) - if(-1000 to -8) - finisheditem.desc += "\nIt looks to be the most awfully made object you've ever seen." - if(-8) - finisheditem.desc += "\nIt looks to be the second most awfully made object you've ever seen." - if(-8 to 0) - finisheditem.desc += "\nIt looks to be barely passable as... whatever it's trying to pass for." - if(0 to 10) - finisheditem.desc += "\nIt looks to be totally average." - if(10 to INFINITY) - finisheditem.desc += "\nIt looks to be better than average." finisheditem.set_custom_materials(workpiece_material) var/stepexperience = currentsteps + finisheditem.quality - var/finalexperience = (150 *(stepexperience + finisheditem.quality))/6 //Makes powerlevelling late-game harder as it gives more bonuses here + var/finalexperience = (150 *(stepexperience + finisheditem.quality))/8 //Makes powerlevelling late-game harder as it gives more bonuses here if(user.mind.skill_holder) // give them some experience! if(currentquality <= 1) - user.mind.auto_gain_experience(/datum/skill/level/dwarfy/blacksmithing, 250, 500000, silent = FALSE) //Fixes speedleveling by just making hammers, somewhat. + user.mind.auto_gain_experience(/datum/skill/level/dwarfy/blacksmithing, 400, 500000, silent = FALSE) //Incentivises not spamming Slag else user.mind.auto_gain_experience(/datum/skill/level/dwarfy/blacksmithing, finalexperience, 500000, silent = FALSE) //Made more forgiving for lower levels and terrible anvils. @@ -390,112 +385,56 @@ GLOBAL_LIST_INIT(anvil_recipes, list( break + ////////////////////// // // // ANVILS // // // ////////////////////// -// Template -/obj/structure/anvil/obtainable - name = "anvil template. Punish those who makes this appear." - anvilquality = 0 - outrightfailchance = 5 - rng = TRUE - -// Best anvil, should be hard to find or make more -/obj/structure/anvil/obtainable/basic +// A proper steel anvil +/obj/structure/blacksmith/anvil/obtainable name = "anvil" desc = "Made from solid steel, you wont be moving this around any time soon." + icon_state = "anvil" anvilquality = -1 //This was causing balance problems to where you could get high levels of blacksmithing in 1-2 items - itemqualitymax = 6 //Do not change this. -// Don't make this craftable. -/obj/structure/anvil/obtainable/legion +// Best anvil +/obj/structure/blacksmith/anvil/obtainable/legion name = "anvil" desc = "A solid steel anvil with a stamped bull on it." icon_state = "legvil" anvilquality = 0 //DO NOT GIVE A +1 BONUS TO ANVILS WHEN THEY HAVE A MAXQAL OF 8, THIS ONLY ASKS FOR MAX TIER FORGED ITEMS - itemqualitymax = 8 //The legion and tribe rely mostly on melee weapons, so they should have the best anvil - anchored = TRUE -// Decent makeshift anvil, can break, mobile. Gets the exclusive scrap version of the machete and 2h chopper, as well as the universal tool instead of a crowbar -/obj/structure/anvil/obtainable/table +// Decent makeshift anvil, mobile. +/obj/structure/blacksmith/anvil/obtainable/table name = "table anvil" desc = "A reinforced table. Usable as an anvil, favored by mad wastelanders and the dregs of the wasteland. Can be loosened from its bolts and moved." icon_state = "tablevil" - anvilquality = -2 //WE SHOULD NOT HAVE CHANGED THIS. - itemqualitymax = 4 + anvilquality = -2 -/obj/structure/anvil/obtainable/table/wrench_act(mob/living/user, obj/item/I) +/obj/structure/blacksmith/anvil/obtainable/table/wrench_act(mob/living/user, obj/item/I) ..() default_unfasten_wrench(user, I, 5) return TRUE -/obj/structure/anvil/obtainable/table/do_shaping(mob/user, qualitychange) - if(prob(2)) - to_chat(user, "The [src] breaks under the strain!") - take_damage(max_integrity, attacked_by = user) - return FALSE - else - ..() - -// Worst craftable anvil, sturdy but limits the quality -/obj/structure/anvil/obtainable/sandstone +// Sandstone anvil +/obj/structure/blacksmith/anvil/obtainable/sandstone name = "sandstone brick anvil" desc = "A big block of sandstone. Useable as an anvil." custom_materials = list(/datum/material/sandstone=8000) icon_state = "sandvil" - anvilquality = 0 - itemqualitymax = 4 + anvilquality = -2 // Debug anvil for some reason -/obj/structure/anvil/debugsuper +/obj/structure/blacksmith/anvil/debugsuper name = "super ultra epic anvil of debugging." desc = "WOW. A DEBUG ITEM STRUCTURE. EPIC." icon_state = "anvil" anvilquality = 10 itemqualitymax = 9001 outrightfailchance = 0 - -// Remnant trash -/obj/structure/anvil/obtainable/bronze - name = "slab of bronze" - desc = "A big block of bronze. Useable as an anvil." - icon = 'icons/obj/smith.dmi' - custom_materials = list(/datum/material/bronze=8000) - icon_state = "ratvaranvil" - anvilquality = 0 - itemqualitymax = 5 //Its too easy to obtain it - -/obj/structure/anvil/obtainable/ratvar - name = "brass anvil" - desc = "A big block of what appears to be brass. Useable as an anvil, if whatever's holding the brass together lets you." - icon = 'icons/obj/smith.dmi' - custom_materials = list(/datum/material/bronze=8000) - icon_state = "ratvaranvil" - currentquality = 1 - itemqualitymax = 8 -/obj/structure/anvil/obtainable/ratvar/attackby(obj/item/I, mob/user) - if(is_servant_of_ratvar(user)) - return ..() - else - to_chat(user, span_neovgre("KNPXWN, QNJCQNW!")) //rot13 then rot22 if anyone wants to decode - -/obj/structure/anvil/obtainable/narsie - name = "runic anvil" - desc = "An anvil made of a strange, runic metal." - custom_materials = list(/datum/material/runedmetal=8000) - icon = 'icons/obj/smith.dmi' - icon_state = "evil" - currentquality = 1 - itemqualitymax = 8 - -/obj/structure/anvil/obtainable/narsie/attackby(obj/item/I, mob/user) - if(iscultist(user)) - return ..() - else - to_chat(user, span_narsiesmall("That is not yours to use!")) + rng = FALSE #undef WORKPIECE_PRESENT #undef WORKPIECE_INPROGRESS diff --git a/modular_BD2/blacksmith/code/finished_items.dm b/modular_BD2/blacksmith/code/finished_items.dm new file mode 100644 index 00000000000..a6312234a50 --- /dev/null +++ b/modular_BD2/blacksmith/code/finished_items.dm @@ -0,0 +1,844 @@ +////////////////////////////////////////// +// // +// SMITHED ITEMS BASE CODE // +// // +////////////////////////////////////////// +// Values in brackets [37/39 (40) AP 0.2 Parry] are one handed/wielded (thrown) armour piercing, and abilities, for quality 12 Iron weapons. + + +/obj/item/melee/smith + name = "base class obj/item/melee/smith" + desc = "cringe" + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + force = FORCE_SMITH_LOW + throwforce = THROWING_DECENT + wound_bonus = WOUNDING_BONUS_MODEST + wielded_mult = 1 + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + total_mass = TOTAL_MASS_MEDIEVAL_WEAPON + slot_flags = ITEM_SLOT_BELT + w_class = WEIGHT_CLASS_NORMAL + obj_flags = UNIQUE_RENAME + flags_1 = CONDUCT_1 + var/quality + var/overlay_state = "woodenrod" + var/mutable_appearance/overlay + var/wield_force = 15 + +/obj/item/melee/smith/Initialize() + . = ..() + if(desc == "cringe") + desc = "A handmade [name]." + overlay = mutable_appearance(icon, overlay_state) + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + if(force < 0) + force = 0 + + +/obj/item/twohanded/smithed // compatible with the Eris wield stuff + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + attack_speed = MELEE_SPEED_SLOW + force = FORCE_SMITH_LOW + throwforce = THROWING_POOR + sharpness = SHARP_EDGED + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + w_class = WEIGHT_CLASS_BULKY + wielded = FALSE + total_mass = (TOTAL_MASS_MEDIEVAL_WEAPON * 1.5) + max_integrity = 200 + flags_1 = CONDUCT_1 + var/wield_force + wielded_mult = 1.5 + var/mutable_appearance/overlay + var/overlay_state = "woodenrod" + var/x_offset = null + var/y_offset = null + +/obj/item/twohanded/smithed/Initialize() + . = ..() + overlay = mutable_appearance(icon, overlay_state) + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + if(force < 0) + force = 0 + + + +////////////////////// +// // +// SMITHED TOOLS // +// // +////////////////////// + +// -------- BLACKSMITHING HAMMER -------- // +/obj/item/melee/smith/hammer + name = "smithing hammer" + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "hammer" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "hammer" + overlay_state = "hammerhandle" + attack_speed = MELEE_SPEED_SLOWEST + force = WEAPON_FORCE_CLUB + slot_flags = ITEM_SLOT_BELT + wound_bonus = WOUNDING_BONUS_SMALL + var/qualitymod = 0 + +/obj/item/melee/smith/hammer/premade + quality = 3 + qualitymod = 1 + custom_materials = list(/datum/material/iron = 1000) + +// Debugging Hammer +/obj/item/melee/smith/hammer/debug + name = "debugging hammer" + desc = "A DEBUGGING HAMMER!! EPIC!!." + qualitymod = 10 + + +// -------- PROSPECTORS PICK -------- // Knock on rock to scan for minerals. Lowest quality too shitty to test. +/obj/item/mining_scanner/prospector + name = "prospectors pick" + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + obj_flags = UNIQUE_RENAME + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "prospect_smith" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "prospect_smith" + sharpness = SHARP_POINTY + slot_flags = ITEM_SLOT_BELT + +/obj/item/mining_scanner/prospector/Initialize() + ..() + var/mutable_appearance/overlay + desc = "A sounding pick, by tapping the rockface and listening to the reverberation, a skilled user can determine where to dig to find deposits of minerals." + overlay = mutable_appearance(icon, "handle_prospect") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + +/obj/item/mining_scanner/prospector/afterattack(atom/A, mob/living/user, proximity) + . = ..() + if(!proximity || IS_STAMCRIT(user)) + return + if(istype(A, /turf/closed/mineral)) + mineral_scan_pulse(get_turf(user), range) + playsound(src, 'modular_BD2/blacksmith/sound/pickaxe_2.ogg', 70, 1) + +/obj/item/mining_scanner/prospector/attack_self(mob/user) + return + + +// -------- SMITHED PICKAXE -------- // +/obj/item/pickaxe/smithed + name = "pickaxe" + desc = "A handmade pickaxe." + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + obj_flags = UNIQUE_RENAME + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "pickaxe" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "pickaxe" + slot_flags = ITEM_SLOT_BELT | ITEM_SLOT_BACK + sharpness = SHARP_POINTY + +/obj/item/pickaxe/smithed/Initialize() + ..() + desc = "A handmade [name]." + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "handle_pickaxe") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + if(force < 0) + force = 0 + +/obj/item/pickaxe/smithed/attack_self(mob/user) + to_chat(user, "Tool does not have a configureable dig range.") + + +// -------- SMITHED SHOVEL -------- // +/obj/item/shovel/smithed + name = "shovel" + desc = "A shovel." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "shovel" + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "shovel" + obj_flags = UNIQUE_RENAME + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + sharpness = SHARP_EDGED //it cuts through the earth + +/obj/item/shovel/smithed/Initialize() + ..() + desc = "A handmade [name]." + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "shovelhandle") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + if(force < 0) + force = 0 + + +// -------- SMITHED CROWBAR -------- // Tops out at 0.2 Toolspeed, which while very fast, is for a crowbar, so meh. TO DO Force qualmod +/obj/item/crowbar/smithed + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "crowbar_smith" + item_state = "crowbar" + obj_flags = UNIQUE_RENAME + toolspeed = 0.8 + force = 15 + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + +/obj/item/crowbar/smithed/Initialize() + ..() + desc = "A handmade [name]." + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "handle_crowbar") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + + +// -------- UNIVERSAL TOOL -------- // Crowbar with more force, wood chopping and butchering +/obj/item/crowbar/smithedunitool + name = "universal tool" + desc = "A bizarre combination of a crowbar and some sort of blade." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "unitool_smith" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + item_state = "unitool_smith" + obj_flags = UNIQUE_RENAME + sharpness = SHARP_POINTY + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + force = WEAPON_FORCE_CLUB + +/obj/item/crowbar/smithedunitool/Initialize() + ..() + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "handle_unitool") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + +/obj/item/crowbar/smithedunitool/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 150, 80) //terrible. just terrible. + +// -------- KITCHEN KNIFE -------- // +/obj/item/kitchen/knife/smithed + name = "kitchen knife" + desc = "A handmade kitchen knife, best suited to cut stuff that doesn't cut back." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "knife_smith" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + item_state = "knife_smith" + obj_flags = UNIQUE_RENAME + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + force = WEAPON_FORCE_KNIFE-2 + +/obj/item/kitchen/knife/smithed/Initialize() + . = ..() + AddComponent(/datum/component/butchering, 70, 100, 40) + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "hilt_knife") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + + + +////////////////////////// +// // +// OTHER ITEMS // +// // +////////////////////////// + +// ------------ BALL AND CHAIN ------------ // + +/obj/item/restraints/legcuffs/ballandchain + name = "ball and chain" + desc = "Use this to keep prisoners in line." + gender = PLURAL + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "ballandchain" + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + item_state = "ballandchain" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + throwforce = 10 + w_class = WEIGHT_CLASS_BULKY + slowdown = 4 + breakouttime = 1200 //Deciseconds = 30s = 0.5 minute + strip_delay = 100 + var/cuffsound = 'modular_BD2/blacksmith/sound/chain.ogg' + var/trashtype = null //for disposable cuffs + +/obj/item/restraints/legcuffs/ballandchain/attack(mob/living/carbon/C, mob/living/user) + if(!istype(C)) + return + + if(iscarbon(user) && (HAS_TRAIT(user, TRAIT_CLUMSY) && prob(50))) + to_chat(user, span_warning("Somehow I can't lock this...")) + return + + if(!C.legcuffed) + if(C.get_num_legs(FALSE) >= 1 || C.get_leg_ignore()) + C.visible_message(span_danger("[user] is trying to put [src.name] on [C]!"), \ + span_userdanger("[user] is trying to put [src.name] on [C]!")) + + playsound(loc, cuffsound, 50, 1, -2) + if(do_mob(user, C, 30) && (C.get_num_legs(FALSE) >= 1 || C.get_leg_ignore())) + if(iscyborg(user)) + apply_legcuffs(C, user, TRUE) + else + apply_legcuffs(C, user) + to_chat(user, span_notice("You clamp irons on [C].")) + SSblackbox.record_feedback("tally", "handcuffs", 1, type) + + log_combat(user, C, "clamped in irons") + else + to_chat(user, span_warning("You fail to clamp irons on [C]!")) + else + to_chat(user, span_warning("[C] doesn't have a leg...")) + +/obj/item/restraints/legcuffs/ballandchain/proc/apply_legcuffs(mob/living/carbon/target, mob/user, dispense = 0) + if(target.legcuffed) + return + + if(!user.temporarilyRemoveItemFromInventory(src) && !dispense) + return + + var/obj/item/restraints/legcuffs/ballandchain/cuffs = src + if(trashtype) + cuffs = new trashtype() + else if(dispense) + cuffs = new type() + + target.equip_to_slot(cuffs, SLOT_LEGCUFFED) + + if(trashtype && !dispense) + qdel(src) + return + + + +////////////////////////////////// +// // +// KNIVES // +// // +////////////////////////////////// + +// ------------ DAGGER ------------ // [Eyestab] +/obj/item/melee/smith/dagger + name = "dagger" + icon_state = "dagger_smith" + overlay_state = "hilt_dagger" + attack_speed = MELEE_SPEED_FAST + force = FORCE_SMITH_LOW + armour_penetration = PIERCING_MINOR + throwforce = THROWING_EFFECTIVE + w_class = WEIGHT_CLASS_SMALL + sharpness = SHARP_EDGED + hitsound = 'modular_BD2/blacksmith/sound/hit_knife.ogg' + + +// go for the eyes Boo +/obj/item/melee/smith/dagger/attack(mob/living/carbon/M, mob/living/carbon/user) + if(!istype(M)) + return ..() + if(user.zone_selected == BODY_ZONE_PRECISE_EYES) + M.apply_damage(7, BRUTE, BODY_ZONE_HEAD) + playsound(M, 'modular_BD2/blacksmith/sound/meatslap.ogg', 80, 1) + return eyestab(M,user) + else + return ..() + +/obj/item/melee/smith/dagger/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 100, 100, 10) + +// ------------ BOWIE KNIFE ------------ // [Eyestab] +/obj/item/melee/smith/dagger/bowie + name = "bowie knife" + icon_state = "bowie_smith" + overlay_state = "hilt_bowie" + force = (FORCE_SMITH_LOW+2) + + + +////////////////////////////////// +// // +// ONE HANDED SWORDS // +// // +////////////////////////////////// + +// ------------ MACHETE ------------ // [AP 0.1] +/obj/item/melee/smith/machete + name = "machete" + icon_state = "machete_smith" + overlay_state = "hilt_machete" + force = FORCE_SMITH_HIGH + armour_penetration = PIERCING_MINOR + wound_bonus = WOUNDING_BONUS_BIG + block_chance = 20 + sharpness = SHARP_EDGED + +/obj/item/melee/smith/machete/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 100, 85, 10) //decent in a pinch. + AddElement(/datum/element/sword_point) + +// ------------ GLADIUS ------------ // [AP 0.1] +/obj/item/melee/smith/machete/gladius + name = "gladius" + icon_state = "gladius_smith" + overlay_state = "hilt_gladius" + +// ------------ REFORGED MACHETE ------------ // [AP 0.1] +/obj/item/melee/smith/machete/reforged + name = "reforged machete" + icon_state = "macheter_smith" + overlay_state = "hilt_macheter" + + + +////////////////////////////////// +// // +// MIXED ONEHANDERS // +// // +////////////////////////////////// + +// ------------ WAKIZASHI ------------ // [Parry] +/obj/item/melee/smith/wakizashi + name = "wakizashi" + icon_state = "waki_smith" + overlay_state = "hilt_waki" + force = (FORCE_SMITH_HIGH-2) + block_chance = 5 + block_parry_data = /datum/block_parry_data/waki + sharpness = SHARP_EDGED + item_flags = ITEM_CAN_PARRY + hitsound = 'modular_BD2/blacksmith/sound/hit_sword.ogg' + +/datum/block_parry_data/waki + parry_stamina_cost = 50 + parry_time_windup = 0 + parry_time_active = 15 + parry_time_spindown = 0 + parry_time_perfect = 2 + parry_time_perfect_leeway = 0.75 + parry_imperfect_falloff_percent = 7.5 + parry_efficiency_to_counterattack = 100 + parry_efficiency_considered_successful = 80 + parry_efficiency_perfect = 120 + parry_failed_stagger_duration = 2 SECONDS + parry_data = list(PARRY_COUNTERATTACK_MELEE_ATTACK_CHAIN = 1) + +/obj/item/melee/smith/wakizashi/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 110, 70) //decent in a pinch, but pretty bad. + + +// ------------ SCRAP SAW ------------ // [Parry, stack damage experimental] +/obj/item/melee/smith/wakizashi/scrapsaw + name = "scrap saw" + icon_state = "saw_smith" + overlay_state = "handle_saw" + force = (FORCE_SMITH_HIGH-3) + wound_bonus = WOUNDING_BONUS_TINY + bare_wound_bonus = WOUNDING_BONUS_BIG + tool_behaviour = TOOL_SAW + toolspeed = 1 + hitsound = 'sound/effects/butcher.ogg' + var/bleed_stacks_per_hit = 3 + +/obj/item/melee/smith/wakizashi/scrapsaw/afterattack(atom/target, mob/user, proximity_flag, click_parameters) + . = ..() + if(!isliving(target) || !proximity_flag) + return + var/mob/living/M = target + if(!(M.mob_biotypes & MOB_ORGANIC)) + return + if(user.a_intent != INTENT_HARM) + var/datum/status_effect/stacking/saw_bleed/bloodletting/B = M.has_status_effect(/datum/status_effect/stacking/saw_bleed/bloodletting) + if(!B) + M.apply_status_effect(/datum/status_effect/stacking/saw_bleed/bloodletting, bleed_stacks_per_hit) + else + B.add_stacks(bleed_stacks_per_hit) + + +// ------------ MACE ------------ // +/obj/item/melee/smith/mace + name = "mace" + icon_state = "mace_smith" + overlay_state = "shaft_mace" + attack_speed = MELEE_SPEED_SLOW + force = (FORCE_SMITH_LOW+1) + armour_penetration = PIERCING_MAJOR + throwforce = THROWING_POOR + wound_bonus = WOUNDING_BONUS_HUGE + total_mass = (TOTAL_MASS_MEDIEVAL_WEAPON*1.2) + hitsound = 'modular_BD2/blacksmith/sound/hit_mace.ogg' + +/obj/item/melee/smith/mace/afterattack(mob/living/M, mob/living/user) + . = ..() + if(!istype(M)) + return + M.apply_damage(15, STAMINA, "chest", M.run_armor_check("chest", "melee")) + + + +////////////////////////////////// +// // +// ONE HANDED SWORDS // +// // +////////////////////////////////// + +// ------------ SWORD ------------ // [AP 0.1 Parry] +/obj/item/melee/smith/sword + name = "sword" + icon_state = "sword_smith" + item_state = "sword_smith" + overlay_state = "hilt_sword" + force = FORCE_SMITH_HIGH + armour_penetration = PIERCING_MINOR + wound_bonus = WOUNDING_BONUS_BIG + item_flags = ITEM_CAN_PARRY + block_chance = 10 + block_parry_data = /datum/block_parry_data/sword + w_class = WEIGHT_CLASS_BULKY + sharpness = SHARP_EDGED + +/datum/block_parry_data/sword + parry_stamina_cost = 50 + parry_time_windup = 0.5 + parry_time_active = 4 + parry_time_spindown = 1 + parry_time_perfect = 0.75 + parry_time_perfect_leeway = 0.75 + parry_imperfect_falloff_percent = 30 + parry_efficiency_perfect = 100 + parry_failed_stagger_duration = 3 SECONDS + parry_failed_clickcd_duration = 2 SECONDS + +/obj/item/melee/smith/sword/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 120, 70) //decent in a pinch, but pretty bad. + AddElement(/datum/element/sword_point) + + +// ------------ SPATHA ------------ // [AP 0.1 Parry] +/obj/item/melee/smith/sword/spatha + name = "spatha" + icon_state = "spatha_smith" + item_state = "spatha_smith" + overlay_state = "hilt_spatha" + block_chance = 14 + + +// ------------ SABRE ------------ // [AP 0.1 Parry] +/obj/item/melee/smith/sword/sabre + name = "sabre" + icon_state = "sabre_smith" + item_state = "sabre_smith" + overlay_state = "hilt_sabre" + force = (FORCE_SMITH_HIGH-1) + block_chance = 18 + block_parry_data = /datum/block_parry_data/smithsaber + +/datum/block_parry_data/smithsaber + parry_stamina_cost = 50 + parry_time_active = 8 + parry_time_perfect = 2 + parry_time_perfect_leeway = 2 + parry_failed_stagger_duration = 3 SECONDS + parry_failed_clickcd_duration = 3 SECONDS + parry_time_windup = 0 + parry_time_spindown = 0 + parry_imperfect_falloff_percent = 0 + parry_efficiency_to_counterattack = 100 + parry_efficiency_considered_successful = 100 + parry_efficiency_perfect = 120 + parry_data = list(PARRY_COUNTERATTACK_MELEE_ATTACK_CHAIN = 1) + + + +////////////////////////////////// +// // +// LONG SWORDS // +// // +////////////////////////////////// + +// ------------ KATANA ------------ // [AP 0.2 Parry] +/obj/item/twohanded/smithed/katana + name = "katana" + icon_state = "katana_smith" + icon_prefix = "katana_smith" + wielded_icon = "katana_smith" + overlay_state = "hilt_katana" + force = (FORCE_SMITH_HIGH-1) + armour_penetration = PIERCING_MODERATE + throwforce = THROWING_POOR + wound_bonus = WOUNDING_BONUS_BIG + wielded_mult = 1.25 + item_flags = ITEM_CAN_PARRY + block_chance = 15 + block_parry_data = /datum/block_parry_data/smithkatana + slot_flags = ITEM_SLOT_BELT + hitsound = 'modular_BD2/blacksmith/sound/hit_sword.ogg' + +/datum/block_parry_data/smithkatana + parry_stamina_cost = 50 + parry_time_active = 6 + parry_time_perfect = 3 + parry_time_perfect_leeway = 3 + parry_failed_stagger_duration = 3 SECONDS + parry_failed_clickcd_duration = 3 SECONDS + parry_time_windup = 0 + parry_time_spindown = 0 + parry_imperfect_falloff_percent = 0 + parry_efficiency_to_counterattack = 100 + parry_efficiency_considered_successful = 120 + parry_efficiency_perfect = 120 + parry_data = list(PARRY_COUNTERATTACK_MELEE_ATTACK_CHAIN = 1) + +/obj/item/twohanded/smithed/katana/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 130, 60) //pretty bad. + AddElement(/datum/element/sword_point) + + +// ------------ LONGSWORD ------------ // [AP 0.2 Parry] +/obj/item/twohanded/smithed/katana/longsword + name = "longsword" + icon_state = "longsword_smith" + icon_prefix = "longsword_smith" + wielded_icon = "longsword_smith" + overlay_state = "hilt_longsword" + + +// ------------ SCRAP BLADE ------------ // [AP 0.2 Parry] +/obj/item/twohanded/smithed/katana/scrapblade + name = "scrap blade" + icon_state = "scrap_smith" + icon_prefix = "scrap_smith" + wielded_icon = "scrap_smith" + overlay_state = "hilt_scrap" + attack_speed = MELEE_SPEED_SLOW + force = FORCE_SMITH_HIGH + +/obj/item/twohanded/smithed/katana/scrapblade/ComponentInitialize() + . = ..() + AddComponent(/datum/component/butchering, 110, 75) //decent in a pinch, but pretty bad. + + + +////////////////////////////////// +// // +// AXES // +// // +////////////////////////////////// + +// ------------ HEAVY AXE ------------ // [AP 0.1 Doorbusting] +/obj/item/twohanded/smithed/axe + name = "heavy axe" + icon_state = "axe_smith" + wielded_icon = "axe_smith" + icon_prefix = "axe_smith" + overlay_state = "shaft_axe" + force = FORCE_SMITH_LOW + armour_penetration = PIERCING_MODERATE + throwforce = THROWING_POOR + wound_bonus = WOUNDING_BONUS_BIG + total_mass = TOTAL_MASS_MEDIEVAL_WEAPON * 2 + slot_flags = ITEM_SLOT_BACK + +/obj/item/twohanded/smithed/axe/afterattack(atom/A, mob/living/user, proximity) + . = ..() + if(!proximity || !wielded || IS_STAMCRIT(user)) + return + if(istype(A, /obj/machinery/door)) + var/obj/machinery/door/D = A + D.take_damage(20, BRUTE, "melee", 0) + else if(istype(A, /obj/structure/simple_door)) + var/obj/structure/simple_door/M = A + M.take_damage(20, BRUTE, "melee", 0) + + +// ------------ LEGION WAR AXE ------------ // [AP 0.1 Doorbusting] +/obj/item/twohanded/smithed/axe/waraxe + name = "war axe" + icon_state = "waraxe_smith" + icon_prefix = "waraxe_smith" + wielded_icon = "waraxe_smith" + icon_prefix = "waraxe_smith" + overlay_state = "shaft_waraxe" + throwforce = THROWING_GOOD + +/obj/item/twohanded/smithed/axe/waraxe/afterattack(atom/A, mob/living/user, proximity) + . = ..() + if(!proximity || !wielded || IS_STAMCRIT(user)) + return + if(istype(A, /obj/machinery/door)) + var/obj/machinery/door/D = A + D.take_damage(20, BRUTE, "melee", 0) + else if(istype(A, /obj/structure/simple_door)) + var/obj/structure/simple_door/M = A + M.take_damage(20, BRUTE, "melee", 0) + + +// ------------ GHOUL CRUSHER ------------ // [Ghoul bonus] - for those dry twig like limbs, snap snap..(was meant to dislocate PC ghouls but code did not work properly so removed) +/obj/item/twohanded/smithed/crusher + name = "crusher" + desc = "Affectionally known as the ghoul crusher, this club is easiest to swing two handed." + icon_state = "crusher_smith" + icon_prefix = "crusher_smith" + wielded_icon = "crusher_smith" + icon_prefix = "crusher_smith" + overlay_state = "shaft_crusher" + attack_speed = MELEE_SPEED_SLOWER + force = FORCE_SMITH_LOW + armour_penetration = PIERCING_MAJOR + throwforce = THROWING_PATHETIC + wound_bonus = WOUNDING_BONUS_HUGE + sharpness = SHARP_NONE + slot_flags = ITEM_SLOT_BACK + total_mass = TOTAL_MASS_MEDIEVAL_WEAPON * 2 + hitsound = 'modular_BD2/blacksmith/sound/hit_mace.ogg' + +/obj/item/twohanded/smithed/crusher/afterattack(atom/A, mob/living/user, proximity) + . = ..() + if(!proximity || !wielded || IS_STAMCRIT(user)) + return + if(istype(A, /mob/living/simple_animal/hostile/ghoul)) + var/mob/living/simple_animal/hostile/ghoul/D = A + D.apply_damage(25, BRUTE) + + + +////////////////////////////////////// +// // +// POLEARMS // +// // +////////////////////////////////////// + +// ------------ SPEAR ------------ // [Reach] +/obj/item/twohanded/smithed/spear + name = "spear" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/64x64_lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/64x64_righthand.dmi' + icon_state = "spear_smith" + wielded_icon = "spear_smith" + icon_prefix = "spear_smith" + overlay_state = "shaft_spear" + force = FORCE_SMITH_REACH + throwforce = THROWING_GOOD + wielded_mult = 1.3 + max_reach = 2 + sharpness = SHARP_POINTY + inhand_x_dimension = 64 + inhand_y_dimension = 64 + + +// ------------ TRIDENT ------------ // [Reach Embed] +/obj/item/twohanded/smithed/spear/trident + name = "trident" + desc = "Made for spearing small lizard and fish, able to pin down the prey if thrown." + icon_state = "trident_smith" + wielded_icon = "trident_smith" + icon_prefix = "trident_smith" + overlay_state = "shaft_trident" + attack_speed = MELEE_SPEED_SLOW + force = (FORCE_SMITH_REACH+1) + embedding = list("pain_mult" = 2, "embed_chance" = 40, "fall_chance" = 30, "ignore_throwspeed_threshold" = TRUE) + armour_penetration = 0 + + +// ------------ LEGION LANCE ------------ // [Reach] +/obj/item/twohanded/smithed/spear/lance + name = "legion lance" + icon_state = "lance_smith" + wielded_icon = "lance_smith_wield" + icon_prefix = "lance_smith" + overlay_state = "shaft_lance" + + + +////////////////////////////////////////////////// +// // +// THROWING WEAPONS // +// // +////////////////////////////////////////////////// + +// ------------ JAVELIN ------------ // [Embed] +/obj/item/melee/smith/javelin + name = "javelin" + icon_state = "javelin_smith" + overlay_state = "shaft_javelin" + item_state = "javelin_smith" + force = FORCE_SMITH_REACH + armour_penetration = PIERCING_MODERATE + sharpness = SHARP_POINTY + embedding = list("pain_mult" = 2, "embed_chance" = 62, "fall_chance" = 20, "ignore_throwspeed_threshold" = TRUE) + +// ------------ THROWING KNIFE ------------ // [Embed] +/obj/item/melee/smith/throwingknife + name = "throwing knife" + icon_state = "throwing_smith" + overlay_state = "handle_throwing" + item_state = "dagger_smith" + force = FORCE_SMITH_REACH + armour_penetration = PIERCING_MINOR + embedding = list("pain_mult" = 2, "embed_chance" = 65, "fall_chance" = 20, "ignore_throwspeed_threshold" = TRUE) + w_class = WEIGHT_CLASS_SMALL + +// ------------ METAL BOLA ------------ // +/obj/item/restraints/legcuffs/bola/smithed + name = "bola" + desc = "All-metal bola for strong prey." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "bola_smith" + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + item_state = "bola_smith" + breakouttime = 40//5 more deciseconds than regular bola + material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + +/obj/item/restraints/legcuffs/bola/smithed/Initialize() + ..() + desc = "All-metal bola for strong prey." + var/mutable_appearance/overlay + overlay = mutable_appearance(icon, "chain_bola") + overlay.appearance_flags = RESET_COLOR + add_overlay(overlay) + + + +////////////////////////////////////////////// +// // +// SMITHED ARMOR // +// // +////////////////////////////////////////////// + +/obj/item/clothing/suit/armor/heavy/metal/smithed + name = "smithed metal armor" + desc = "A set of plates with leather straps, protecting some vital areas." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + icon_state = "smithed_armor_metal" + item_state = "smithed_armor_metal" diff --git a/modular_BD2/blacksmith/code/furnace.dm b/modular_BD2/blacksmith/code/furnace.dm new file mode 100644 index 00000000000..5822a6444cb --- /dev/null +++ b/modular_BD2/blacksmith/code/furnace.dm @@ -0,0 +1,109 @@ +// ----------------------- FURNACE ------------------------------- + +/obj/structure/blacksmith/furnace + name = "furnace" + desc = "A furnace with fume protection and good ventilation for stoking the fire. Used for heating metal ingots or smelting ores into sheets." + icon = 'modular_BD2/blacksmith/icons/furnace32x64.dmi' + icon_state = "furnace" + density = TRUE + anchored = TRUE + max_integrity = 700 + light_system = MOVABLE_LIGHT + light_range = 2 + light_power = GLOW_BRIGHT + light_color = LIGHT_COLOR_FIRE + light_on = FALSE + plane = GAME_PLANE // so the smoke isnt hidden by objects + var/debug = FALSE //debugging only + var/working = TRUE + var/fueluse = 1 + var/datum/looping_sound/furnace/soundloop + +/obj/structure/blacksmith/furnace/Initialize() + . = ..() + create_reagents(250, TRANSPARENT) + START_PROCESSING(SSobj, src) + soundloop = new(list(src)) + +/obj/structure/blacksmith/furnace/Destroy() + STOP_PROCESSING(SSobj, src) + return ..() + +/obj/structure/blacksmith/furnace/process() + if(debug) + reagents.add_reagent(/datum/reagent/fuel, 1) + return TRUE + if(reagents.remove_reagent(/datum/reagent/fuel, fueluse)) + working = TRUE + soundloop.start() + set_light_on(TRUE) + if(icon_state == "furnace") + icon_state = "furnace_stoked" + + else + working = FALSE + soundloop.stop() + set_light_on(FALSE) + icon_state = "furnace" + +/obj/structure/blacksmith/furnace/attackby(obj/item/I, mob/user) + if(istype(I, /obj/item/blacksmith/ingot)) + var/obj/item/blacksmith/ingot/workpiece = I + if(working) + if(do_after(user, 2 SECONDS, target = src)) + to_chat(user, "You heat the [workpiece] in the [src].") + workpiece.workability = "shapeable" + workpiece.icon_state = "hot_ingot" + workpiece.set_light_on(TRUE) + I.on_attack_hand(user) + else + to_chat(user, "The furnace isn't working!.") + return + if(istype(I, /obj/item/stack/ore)) + var/obj/item/stack/ore/G = I + if(working) + playsound(src, 'modular_BD2/blacksmith/sound/steam_short.ogg',80, 1) + if(do_after(user, 3 SECONDS, target = src)) + G.furnace_smelt() + else + to_chat(user, "The furnace isn't working!.") + return + if(I.reagents) + I.reagents.trans_to(src, 250) + return + if(istype(I, /obj/item/stack/sheet/coke/)) + var/obj/item/stack/sheet/coke/C = I + src.reagents.add_reagent(/datum/reagent/fuel, 5) + C.use(1) + to_chat(user, "You add some lumps of coke to the furnace.") + return + else + return ..() + +/obj/structure/blacksmith/furnace/plunger_act(obj/item/plunger/P, mob/living/user, reinforced) + to_chat(user, "You start furiously plunging [name].") + if(do_after(user, 3 SECONDS, target = src)) + to_chat(user, "You finish plunging the [name].") + reagents.reaction(get_turf(src), TOUCH) //splash on the floor + reagents.clear_reagents() + +/datum/looping_sound/furnace + mid_sounds = list('modular_BD2/blacksmith/sound/furnace1.ogg'=1) + mid_length = 7 SECONDS + volume = 80 + +/obj/item/stack/ore/proc/furnace_smelt() + if(isnull(refined_type)) + return + else + new refined_type(drop_location(),amount) + qdel(src) + + +// ----------------------- SANDSTONE FURNACE ------------------------------- + +/obj/structure/blacksmith/furnace/sandstone // can be built from sandstone, less economical but same effect + name = "sandstone furnace" + desc = "A simply made furnace, not as fuel-efficient as more advanced ones. Used for heating metal ingots." + icon = 'modular_BD2/blacksmith/icons/furnace_sandstone32x64.dmi' + fueluse = 2 diff --git a/modular_BD2/blacksmith/code/smithed_items.dm b/modular_BD2/blacksmith/code/smithed_items.dm new file mode 100644 index 00000000000..c51e0a2cb93 --- /dev/null +++ b/modular_BD2/blacksmith/code/smithed_items.dm @@ -0,0 +1,818 @@ +////////////////////////////////////////// +// // +// SMITHED ITEMS BASE CODE // +// // +////////////////////////////////////////// + +/obj/item/blacksmith + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + righthand_file = 'modular_BD2/blacksmith/icons/onmob/righthand.dmi' + lefthand_file = 'modular_BD2/blacksmith/icons/onmob/lefthand.dmi' + force = WEAPON_FORCE_BIG_TOOL + max_integrity = 40 + w_class = WEIGHT_CLASS_SMALL + +/obj/item/smithing + name = "base class /obj/item/smithing" + desc = "Attach a wooden rod." + icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + icon_state = "unfinished" + material_flags = MATERIAL_COLOR | MATERIAL_ADD_PREFIX + light_system = MOVABLE_LIGHT + light_range = 1 + light_power = GLOW_WEAK + light_color = LIGHT_COLOR_FIRE + light_on = FALSE + var/quality = 0 //quality. Changed by the smithing process. + var/obj/item/finishingitem = WOODEN_ROD //What this item needs to be hit by to create finalitem + var/obj/item/finalitem + var/artifact = FALSE + var/toohot = TRUE // Too hot to touch with bare hands, not tempered yet + +/obj/item/smithing/Initialize() + add_overlay(image(icon= 'modular_BD2/blacksmith/icons/blacksmith.dmi',icon_state="[icon_state]_hot")) + set_light_on(TRUE) + update_icon() + return ..() + +/obj/item/smithing/proc/istempered() + cut_overlay(image(icon= 'modular_BD2/blacksmith/icons/blacksmith.dmi',icon_state="[icon_state]_hot")) + set_light_on(FALSE) + update_icon() + return + +/obj/item/smithing/on_attack_hand(mob/user) + var/mob/living/carbon/human/H + if(toohot != TRUE) + return ..() + var/prot = 0 + if(ishuman(user)) + H = user + if(H.gloves) + var/obj/item/clothing/gloves/G = H.gloves + if(G.max_heat_protection_temperature) + prot = (G.max_heat_protection_temperature > 360) + else + prot = 0 + if(prot > 0 || HAS_TRAIT(user, TRAIT_RESISTHEAT) || HAS_TRAIT(user, TRAIT_RESISTHEATHANDS)) + to_chat(user, "You pick up the [src].") + return ..() + else + to_chat(user, "You try to move the [src], but you burn your hand on it!") + if(H) + var/obj/item/bodypart/affecting = H.get_bodypart("[(user.active_hand_index % 2 == 0) ? "r" : "l" ]_arm") + if(affecting && affecting.receive_damage( 0, 5 )) // 5 burn damage + H.update_damage_overlays() + playsound(src, 'modular_BD2/blacksmith/sound/burned.ogg', 15, 1) + var/list/hand_items = list(H.get_active_held_item(),H.get_inactive_held_item()) + if(src in hand_items) + H.dropItemToGround(src) + + +/obj/item/smithing/attackby(obj/item/I, mob/user) + if(toohot == TRUE) + to_chat(user, "You need to quench the [src] before finishing it!") + return + if(istype(I, LEATHER_STRIP)) + to_chat(user, "You start to wrap the leather strip around the [src].") + I.use(1) + playsound(src, 'modular_BD2/blacksmith/sound/latex.ogg', 70, 1) + if(!do_after(user, 30, TRUE, src)) + return + startfinish() + else if(istype(I, finishingitem)) + qdel(I) + to_chat(user, "You start to attach the handle and fittings to the [src].") + playsound(src, 'modular_BD2/blacksmith/sound/craft_3.ogg', 90, 1) + if(!do_after(user, 30, TRUE, src)) + return + startfinish() + user.put_in_hands(finalitem) + else + return ..() + + +/obj/item/smithing/proc/startfinish() + dofinish() + +/obj/item/smithing/proc/dofinish() + var/qualname + switch(quality) + if(-1000 to -5) + qualname = "awful" + if(-1000 to -2) + qualname = "shoddy" + if(-1000 to -1) + qualname = "poor" + if(-1 to 1) + qualname = "normal" + if(13 to INFINITY) + qualname = "legendary" + if(11 to 13) + qualname = "masterwork" + if(8 to 11) + qualname = "excellent" + if(5 to 8) + qualname = "good" + if(0 to 5) + qualname = "above-average" + var/datum/material/mat = custom_materials[1] + finalitem.set_custom_materials(custom_materials) + mat = mat.name + if(artifact) + dwarfyartifact(finalitem, mat) + else + finalitem.name = "[qualname] [mat] [initial(finalitem.name)]" + finalitem.forceMove(get_turf(src)) + qdel(src) + +// Artifcats. Still a Frankenstein uncurated mutated TG remnant with memery but whatever. +/obj/item/smithing/proc/dwarfyartifact(obj/item/finalitem, mat) + var/finaldesc = "A [initial(finalitem.name)] made of [mat], all craftsmanship is of the highest quality. It " + switch(pick(1,2,3,4,5)) + if(1) + finaldesc += "is encrusted with [pick("","fake ","multi-faceted ","radioactive ","plastic ") + pick("stickers","emeralds","jade","bottle caps","diamonds")]." + if(2) + finaldesc += "is laced with studs of [pick("gold","silver","aluminium","titanium")]." + if(3) + finaldesc += "is etched with pictographs of [pick("nuclear bombs","power-armored men","pinup-girls","the president","a hognose snake")]." + if(4) + finaldesc += "menaces with spikes of [pick("ceramite","uranium","plastic","blued steel")]." + if(5) + finaldesc += "is encrusted with [pick("","synthetic ","multi-faceted ","radioactive ","plastic ") + pick("rubies","dice","jade","opals","bottle caps")],laced with studs of [pick("gold","silver","aluminium","titanium")], encircled with bands of [pick("durasteel","metallic hydrogen","ferritic-alloy","plasteel","duranium")] and menaces with spikes of [pick("ytterbium","uranium","white pearl","black steel")]." + finalitem.desc = finaldesc + finalitem.name = pick("Mutants Choice", "Nuka Smash", "Gallius Rex","Fist of Fury", "The Big Bad", "Good Old Boy", "Serial Crusher", "Caesars Own", "Kiloton Deluxe", "Lämp", "Cosmic Knife Deluxe", "Master Superior", "Even Better", "The Mackintosh", "Oltud", "Deleratîs", "Nökornomal") //one of these is literally BLOOD POOL CREATE.iirc its Nazushagsaldôbar. + + +////////////////////////////////// +// // +// INGOTS // +// // +////////////////////////////////// + +/obj/item/blacksmith/ingot + name = "ingot" + icon_state = "ingot" + material_flags = MATERIAL_COLOR | MATERIAL_ADD_PREFIX + light_system = MOVABLE_LIGHT + light_range = 1 + light_power = GLOW_WEAK + light_color = LIGHT_COLOR_FIRE + light_on = FALSE + var/workability = FALSE + + +/obj/item/blacksmith/ingot/on_attack_hand(mob/user) + var/mob/living/carbon/human/H + if(workability != "shapeable") + return ..() + var/prot = 0 + if(ishuman(user)) + H = user + if(H.gloves) + var/obj/item/clothing/gloves/G = H.gloves + if(G.max_heat_protection_temperature) + prot = (G.max_heat_protection_temperature > 360) + else + prot = 0 + if(prot > 0 || HAS_TRAIT(user, TRAIT_RESISTHEAT) || HAS_TRAIT(user, TRAIT_RESISTHEATHANDS)) + to_chat(user, "You pick up the [src].") + return ..() + else + to_chat(user, "You try to move the [src], but you burn your hand on it!") + playsound(src, 'modular_BD2/blacksmith/sound/burned.ogg', 15, 1) + if(H) + var/obj/item/bodypart/affecting = H.get_bodypart("[(user.active_hand_index % 2 == 0) ? "r" : "l" ]_arm") + if(affecting && affecting.receive_damage( 0, 5 )) // 5 burn damage + H.update_damage_overlays() + var/list/hand_items = list(H.get_active_held_item(),H.get_inactive_held_item()) + if(src in hand_items) + H.dropItemToGround(src) + +/obj/item/blacksmith/ingot/iron + custom_materials = list(/datum/material/iron=12000) + +/obj/item/blacksmith/ingot/uranium + custom_materials = list(/datum/material/uranium=12000) + +/obj/item/blacksmith/ingot/gold + custom_materials = list(/datum/material/gold=12000) + +/obj/item/blacksmith/ingot/silver + custom_materials = list(/datum/material/silver=12000) + +/obj/item/blacksmith/ingot/titanium + custom_materials = list(/datum/material/titanium=12000) + +/obj/item/blacksmith/ingot/adamantine + custom_materials = list(/datum/material/adamantine=12000) + name = "pre-war steel ingot" + desc = "Top quality alloyed steel from the old world." + material_flags = MATERIAL_COLOR + +/obj/item/blacksmith/ingot/bronze + custom_materials = list(/datum/material/bronze=12000) + name = "bronze ingot" + desc = "Softer than iron." + + +////////////////////////////////// +// // +// BLACKSMITH FINISHERS // +// // +////////////////////////////////// + +// -------- WOODEN ROD -------- // +/obj/item/blacksmith/woodenrod + name = "wooden rod" + desc = "It's a rod, suitable for use of a handle of a tool. Also could serve as a weapon, in a pinch." + icon_state = "woodenrod" + resistance_flags = FLAMMABLE + +// Make a sword handle by wrapping leather strips on a rod +/obj/item/blacksmith/woodenrod/attackby/(obj/item/W, mob/user, params) + if (istype(W, LEATHER_STRIP)) + user.visible_message("[user] begins finishing the [src] into a sword handle.", \ + "You begin wrapping the [src] with leather strips, and shaping the wood into a sword handle.", \ + "You hear faint sounds of handcrafting.") + playsound(src, 'modular_BD2/blacksmith/sound/craft_3.ogg', 50, 1) + // 6 Second Timer + if(!do_after(user, 40, TRUE, src)) + return + // Make stick + var/obj/item/blacksmith/swordhandle/new_item = new(user.loc) + user.put_in_hands(new_item) + user.visible_message("[user] finishes making a sword handle from the [src].", \ + "You finish making a sword handle from the [src].") + qdel(src) + // Use up the strips + W.use(1) + else + . = ..() + +// -------- SWORD HANDLE -------- // +/obj/item/blacksmith/swordhandle + name = "sword handle" + desc = "It's a wooden handle with leather strips, making it comfortable to hold." + icon_state = "swordhandle" + resistance_flags = FLAMMABLE + +// -------- CHAIN -------- // +/obj/item/blacksmith/chain + name = "length of chain" + desc = "It rattles and is pretty useless when not attached to stuff" + icon_state = "chain" + hitsound = 'modular_BD2/blacksmith/sound/chain.ogg' + + +////////////////////////////// +// // +// SMITHED TOOLS // +// // +////////////////////////////// - Known issues - force not modified correctly by quality. Toolspeed works though. + +// -------- BLACKSMITH HAMMER -------- // +/obj/item/smithing/hammerhead + name = "smithed hammer head" + finalitem = /obj/item/melee/smith/hammer + icon_state = "hammer" + +/obj/item/smithing/hammerhead/startfinish() + var/obj/item/melee/smith/hammer/finalforreal = new /obj/item/melee/smith/hammer(src) + finalforreal.force += quality/4 + finalforreal.qualitymod = quality/2.5 + finalitem = finalforreal + ..() + +// -------- SHOVEL -------- // +/obj/item/smithing/shovelhead + name = "smithed shovel head" + finalitem = /obj/item/shovel/smithed + icon_state = "shovel" + +/obj/item/smithing/shovelhead/startfinish() + finalitem = new /obj/item/shovel/smithed(src) + finalitem.force += quality/2 + if(quality > 0) + finalitem.toolspeed = max(0.05,(1-(quality/10))) + else + finalitem.toolspeed *= max(1, (quality * -1)) + ..() + +// -------- PICKAXE -------- // +/obj/item/smithing/pickaxehead + name = "smithed pickaxe head" + finalitem = /obj/item/pickaxe/smithed + icon_state = "pickaxe" + +/obj/item/smithing/pickaxehead/startfinish() + var/obj/item/pickaxe/smithed/finalforreal = new /obj/item/pickaxe/smithed(src) + finalforreal.force += quality/2 + if(quality > 0) + finalforreal.toolspeed = max(0.05,(1-(quality/15))) + else + finalforreal.toolspeed *= max(1, (quality * -1)) + switch(quality) + if(13 to INFINITY) + finalforreal.digrange = 2 + if(3 to 13) + finalforreal.digrange = 1 + else + finalforreal.digrange = 1 + finalitem = finalforreal + ..() + +// -------- PROSPECTORS PICK -------- // +/obj/item/smithing/prospectingpickhead + name = "smithed prospector's pick head" + icon_state = "prospect_smith" + finalitem = /obj/item/mining_scanner/prospector + var/cooldown = null + var/range = null + +/obj/item/smithing/prospectingpickhead/startfinish() + var/obj/item/mining_scanner/prospector/finalforreal = new /obj/item/mining_scanner/prospector(src) + finalforreal.range = 2 + QUALITY_MODIFIER + if(quality) + finalforreal.cooldown = 100/quality + finalforreal.force += QUALITY_MODIFIER + finalitem = finalforreal + ..() + +// -------- CROWBAR -------- // +/obj/item/smithing/crowbar + name = "unwrapped crowbar" + desc = "Wrap with leather strips." + icon_state = "crowbar_smith" + finishingitem = LEATHER_STRIP + finalitem = /obj/item/crowbar/smithed + +/obj/item/smithing/crowbar/startfinish() + var/obj/item/crowbar/smithed/finalforreal = new /obj/item/crowbar/smithed(src) + finalforreal.force += QUALITY_MODIFIER + if(quality > 0) + finalforreal.toolspeed = max(0.05,(1-(quality/10))) + else + finalforreal.toolspeed *= max(1, (quality * -1)) + finalitem = finalforreal + ..() + +// -------- UNIVERSAL TOOL -------- // +/obj/item/smithing/unitool + name = "unwrapped universal tool" + desc = "Wrap with leather strips." + icon_state = "unitool_smith" + finishingitem = LEATHER_STRIP + finalitem = /obj/item/crowbar/smithedunitool + +/obj/item/smithing/unitool/startfinish() + var/obj/item/crowbar/smithedunitool/finalforreal = new /obj/item/crowbar/smithedunitool(src) + finalforreal.force += QUALITY_MODIFIER + finalitem = finalforreal + ..() + +// -------- KITCHEN KNIFE -------- // +/obj/item/smithing/knifeblade + name = "smithed knife blade" + desc = "Attach a sword handle." + icon_state = "knife_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/kitchen/knife/smithed + +/obj/item/smithing/knifeblade/startfinish() + var/obj/item/kitchen/knife/smithed/finalforreal = new /obj/item/kitchen/knife/smithed(src) + finalforreal.force = QUALITY_MODIFIER*3 + finalitem = finalforreal + ..() + + +////////////////////////////////////////////////// +// // +// BLING - smithed and finished both // +// // +////////////////////////////////////////////////// + +/obj/item/smithing/special + mob_overlay_icon = 'modular_BD2/blacksmith/icons/onmob/slot.dmi' + gender = NEUTER + w_class = WEIGHT_CLASS_SMALL + +/obj/item/smithing/special/jewelry + icon_state = "ring" + item_state = "ring" + obj_flags = UNIQUE_RENAME + strip_delay = 20 + equip_delay_other = 40 + var/strip_mod = 1 //how much they alter stripping items time by, higher is quicker + var/strip_silence = TRUE + var/mood_event_on_equip = /datum/mood_event/equipped_ring/gold + +// ------------ RING ------------ // +/obj/item/smithing/special/jewelry/ring + name = "ring" + desc = "A ring." + w_class = WEIGHT_CLASS_TINY + slot_flags = ITEM_SLOT_GLOVES + attack_verb = list("proposed") + +/obj/item/smithing/special/jewelry/ring/equipped(mob/user, slot) + . = ..() + if (slot == SLOT_GLOVES && istype(user)) + SEND_SIGNAL(user, COMSIG_ADD_MOOD_EVENT, "ringbuff", mood_event_on_equip) + else + SEND_SIGNAL(user, COMSIG_CLEAR_MOOD_EVENT, "ringbuff") + +/obj/item/smithing/special/jewelry/ring/dropped(mob/user) + . = ..() + SEND_SIGNAL(user, COMSIG_CLEAR_MOOD_EVENT, "ringbuff") + + +// ------------ BALL AND CHAIN ------------ // +/obj/item/smithing/ballandchain + name = "unchained ball" + desc = "Finish by attaching a chain to it." + icon_state = "ball" + finishingitem = CHAIN + finalitem = /obj/item/restraints/legcuffs/ballandchain + throwforce = 15 + throw_range = 2 + +/obj/item/smithing/ballandchain/startfinish() + var/obj/item/smithing/ballandchain/finalforreal = new /obj/item/restraints/legcuffs/ballandchain(src) + finalitem = new /obj/item/restraints/legcuffs/ballandchain(src) + finalforreal.force += QUALITY_MODIFIER*2 + finalitem = finalforreal + finalitem.icon = 'modular_BD2/blacksmith/icons/blacksmith.dmi' + finalitem.icon_state = "ballandchain" + finalitem.name = "ball and chain" + finalitem.desc = "Clamp it on the prisoners feet. They will need a long time to remove it themselves." + finalitem.material_flags = MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS + ..() + + +// ------------ ARMOR PIECES ------------ // - Obviously meant to be included in recipes to build metal armor instead of generic metal parts, at least for the less "scrap metal salvage" styled metal armors. Make it inherit material would be amusing. +/obj/item/smithing/armor_piece + name = "metal armor parts" + desc = "Metal worked to be used in making some sort of simple armor." + icon_state = "armor_piece_smith" + + +////////////////////////////////////////////////// +// // +// ONEHANDED WEAPONS // +// // +////////////////////////////////////////////////// + +// ------------ DAGGER ------------ // +/obj/item/smithing/daggerblade + name = "smithed dagger blade" + desc = "Attach a sword handle." + icon_state = "dagger_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/dagger + +/obj/item/smithing/daggerblade/startfinish() + finalitem = new /obj/item/melee/smith/dagger(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + +// ------------ BOWIE KNIFE ------------ // +/obj/item/smithing/bowieblade + name = "smithed bowie blade" + desc = "Attach a sword handle." + icon_state = "bowie_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/dagger/bowie + +/obj/item/smithing/bowieblade/startfinish() + finalitem = new /obj/item/melee/smith/dagger/bowie(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + + +// ------------ MACHETE ------------ // +/obj/item/smithing/macheteblade + name = "smithed machete blade" + desc = "Attach a sword handle." + icon_state = "machete_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/machete + +/obj/item/smithing/macheteblade/startfinish() + finalitem = new /obj/item/melee/smith/machete(src) + finalitem.force += QUALITY_MODIFIER + ..() + +// ------------ GLADIUS ------------ // +/obj/item/smithing/gladiusblade + name = "smithed gladius blade" + desc = "Attach a sword handle." + icon_state = "gladius_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/machete/gladius + +/obj/item/smithing/gladiusblade/startfinish() + finalitem = new /obj/item/melee/smith/machete/gladius(src) + finalitem.force += QUALITY_MODIFIER + ..() + +// ------------ REFORGED MACHETE ------------ // +/obj/item/smithing/macheterblade + name = "reforged machete blade" + desc = "Attach a sword handle." + icon_state = "macheter_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/machete/reforged + +/obj/item/smithing/macheterblade/startfinish() + finalitem = new /obj/item/melee/smith/machete/reforged(src) + finalitem.force += QUALITY_MODIFIER + ..() + + +// ------------ WAKIZASHI ------------ // +/obj/item/smithing/wakiblade + name = "smithed wakizashi blade" + desc = "Attach a sword handle." + icon_state = "waki_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/wakizashi + +/obj/item/smithing/wakiblade/startfinish() + finalitem = new /obj/item/melee/smith/wakizashi(src) + finalitem.force += QUALITY_MODIFIER + ..() + +// ------------ SCRAP SAW ------------ // +/obj/item/smithing/scrapsaw + name = "unfinished scrap saw" + desc = "Wrap it in leather strips." + icon_state = "saw_smith" + finishingitem = LEATHER_STRIP + finalitem = /obj/item/melee/smith/wakizashi/scrapsaw + +/obj/item/smithing/scrapsaw/startfinish() + finalitem = new /obj/item/melee/smith/wakizashi/scrapsaw(src) + finalitem.force += QUALITY_MODIFIER + ..() + + +// ------------ MACE ------------ // +/obj/item/smithing/macehead + name = "smithed macehead" + icon_state = "mace_smith" + finalitem = /obj/item/melee/smith/mace + +/obj/item/smithing/macehead/startfinish() + finalitem = new /obj/item/melee/smith/mace(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + + +// ------------ SWORD ------------ // +/obj/item/smithing/swordblade + name = "smithed swordblade" + desc = "Attach a sword handle." + icon_state = "sword_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/sword + +/obj/item/smithing/swordblade/startfinish() + finalitem = new /obj/item/melee/smith/sword(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + +// ------------ SPATHA ------------ // +/obj/item/smithing/spathablade + name = "smithed spathablade" + desc = "Attach a sword handle." + icon_state = "spatha_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/sword/spatha + +/obj/item/smithing/spathablade/startfinish() + finalitem = new /obj/item/melee/smith/sword/spatha(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + +// ------------ SABRE ------------ // +/obj/item/smithing/sabreblade + name = "smithed sabre blade" + desc = "Attach a sword handle." + finishingitem = SWORD_HANDLE + finalitem = /obj/item/melee/smith/sword/sabre + icon_state = "sabre_smith" + +/obj/item/smithing/sabreblade/startfinish() + finalitem = new /obj/item/melee/smith/sword/sabre(src) + finalitem.force += QUALITY_MODIFIER + finalitem.armour_penetration += QUALITY_MODIFIER*0.01 + ..() + + +////////////////////////////////////////////////// +// // +// TWOHANDED WEAPONS // +// // +////////////////////////////////////////////////// + +// ------------ KATANA ------------ // +/obj/item/smithing/katanablade + name = "smithed katana blade" + desc = "Attach a sword handle." + icon_state = "katana_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/twohanded/smithed/katana + +/obj/item/smithing/katanablade/startfinish() + var/obj/item/twohanded/smithed/katana/finalforreal = new /obj/item/twohanded/smithed/katana(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") // - icon_wielded basically makes the wield icon for direct click wield, sort of redundant if you change it to shift-x only + finalitem = finalforreal + ..() + +// ------------ LONG SWORDS ------------ // +/obj/item/smithing/longswordblade + name = "smithed longsword blade" + desc = "Attach a sword handle." + icon_state = "longsword_smith" + finishingitem = SWORD_HANDLE + finalitem = /obj/item/twohanded/smithed/katana/longsword + +/obj/item/smithing/longswordblade/startfinish() + var/obj/item/twohanded/smithed/katana/longsword/finalforreal = new /obj/item/twohanded/smithed/katana/longsword(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalitem = finalforreal + ..() + +// ------------ SCRAP BLADE ------------ // +/obj/item/smithing/scrapblade + name = "smithed scrap blade" + desc = "Wrap in leather strips." + icon_state = "scrap_smith" + finishingitem = LEATHER_STRIP + finalitem = /obj/item/twohanded/smithed/katana/scrapblade + +/obj/item/smithing/scrapblade/startfinish() + var/obj/item/twohanded/smithed/katana/scrapblade/finalforreal = new /obj/item/twohanded/smithed/katana/scrapblade(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalitem = finalforreal + ..() + + +// ------------ HEAVY AXE ------------ // +/obj/item/smithing/axehead + name = "smithed axehead" + icon_state = "axe_smith" + finalitem = /obj/item/twohanded/smithed/axe + +/obj/item/smithing/axehead/startfinish() + var/obj/item/twohanded/smithed/axe/finalforreal = new /obj/item/twohanded/smithed/axe(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalitem = finalforreal + ..() + finalitem.force += QUALITY_MODIFIER + +// ------------ WAR AXE ------------ // +/obj/item/smithing/waraxehead + name = "smithed war-axehead" + icon_state = "waraxe_smith" + finalitem = /obj/item/twohanded/smithed/axe/waraxe + +/obj/item/smithing/waraxehead/startfinish() + var/obj/item/twohanded/smithed/axe/waraxe/finalforreal = new /obj/item/twohanded/smithed/axe/waraxe(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalitem = finalforreal + ..() + +// ------------ GHOUL CRUSHER ------------ // - for those dry twig like limbs, snap snap. +/obj/item/smithing/crusherhead + name = "smithed crusher head" + finalitem = /obj/item/twohanded/smithed/crusher + icon_state = "crusher_smith" + +/obj/item/smithing/crusherhead/startfinish() + var/obj/item/twohanded/smithed/crusher/finalforreal = new /obj/item/twohanded/smithed/crusher(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalitem = finalforreal + ..() + + +// ------------ SPEAR ------------ // +/obj/item/smithing/spearhead + name = "smithed spearhead" + finalitem = /obj/item/twohanded/smithed/spear + icon_state = "spear_smith" + +/obj/item/smithing/spearhead/startfinish() + var/obj/item/twohanded/smithed/spear/finalforreal = new /obj/item/twohanded/smithed/spear(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalforreal.throwforce = finalforreal.force + finalitem = finalforreal + ..() + +// ------------ TRIDENT ------------ // +/obj/item/smithing/tridenthead + name = "smithed tridenthead" + finalitem = /obj/item/twohanded/smithed/spear/trident + icon_state = "trident_smith" + +/obj/item/smithing/tridenthead/startfinish() + var/obj/item/twohanded/smithed/spear/trident/finalforreal = new /obj/item/twohanded/smithed/spear/trident(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalforreal.throwforce = finalforreal.force + finalitem = finalforreal + ..() + +// ------------ LEGION LANCE ------------ // +/obj/item/smithing/lancehead + name = "smithed lancehead" + finalitem = /obj/item/twohanded/smithed/spear/lance + icon_state = "lance_smith" + +/obj/item/smithing/lancehead/startfinish() + var/obj/item/twohanded/smithed/spear/lance/finalforreal = new /obj/item/twohanded/smithed/spear/lance(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.wield_force = finalforreal.force*finalforreal.wielded_mult + finalforreal.AddComponent(/datum/component/two_handed, force_unwielded=finalforreal.force, force_wielded=finalforreal.wield_force, icon_wielded="[icon_state]_wield") + finalforreal.throwforce = finalforreal.force + finalitem = finalforreal + ..() + + +////////////////////////////////////////////////// +// // +// THROWING WEAPONS // +// // +////////////////////////////////////////////////// + +// ------------ THROWING KNIFE ------------ // +/obj/item/smithing/throwingknife + name = "unfinished throwing knife" + desc = "Add leather strips." + icon_state = "throwing_smith" + finishingitem = LEATHER_STRIP + finalitem = /obj/item/melee/smith/throwingknife + +/obj/item/smithing/throwingknife/startfinish() + var/obj/item/melee/smith/throwingknife/finalforreal = new /obj/item/melee/smith/throwingknife(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.throwforce = finalforreal.force*1.4 + finalitem = finalforreal + ..() + +// ------------ JAVELIN ------------ // +/obj/item/smithing/javelinhead + name = "smithed javelin head" + icon_state = "javelin_smith" + finalitem = /obj/item/melee/smith/javelin + +/obj/item/smithing/javelinhead/startfinish() + var/obj/item/melee/smith/javelin/finalforreal = new /obj/item/melee/smith/javelin(src) + finalforreal.force += QUALITY_MODIFIER + finalforreal.throwforce = finalforreal.force*1.5 + finalitem = finalforreal + ..() + +// ------------ METAL BOLA ------------ // +/obj/item/smithing/bola + name = "unfinished bola pieces" + desc = "Add a chain." + icon_state = "bola_smith" + finishingitem = CHAIN + finalitem = /obj/item/restraints/legcuffs/bola/smithed + +/obj/item/smithing/bola/startfinish() + var/obj/item/restraints/legcuffs/bola/smithed/finalforreal = new /obj/item/restraints/legcuffs/bola/smithed(src) + finalforreal.breakouttime+= QUALITY_MODIFIER + finalitem = finalforreal + ..() + +#undef WOODEN_ROD +#undef SWORD_HANDLE +#undef LEATHER_STRIP +#undef CHAIN +#undef QUALITY_MODIFIER +#undef GLOW_BRIGHT +#undef GLOW_MODERATE +#undef GLOW_WEAK diff --git a/modular_BD2/blacksmith/icons/blacksmith.dmi b/modular_BD2/blacksmith/icons/blacksmith.dmi new file mode 100644 index 00000000000..855e49b704d Binary files /dev/null and b/modular_BD2/blacksmith/icons/blacksmith.dmi differ diff --git a/modular_BD2/blacksmith/icons/furnace32x64.dmi b/modular_BD2/blacksmith/icons/furnace32x64.dmi new file mode 100644 index 00000000000..25d82a6971e Binary files /dev/null and b/modular_BD2/blacksmith/icons/furnace32x64.dmi differ diff --git a/modular_BD2/blacksmith/icons/furnace_sandstone32x64.dmi b/modular_BD2/blacksmith/icons/furnace_sandstone32x64.dmi new file mode 100644 index 00000000000..0ab922a21d0 Binary files /dev/null and b/modular_BD2/blacksmith/icons/furnace_sandstone32x64.dmi differ diff --git a/modular_BD2/blacksmith/icons/onmob/64x64_lefthand.dmi b/modular_BD2/blacksmith/icons/onmob/64x64_lefthand.dmi new file mode 100644 index 00000000000..bddbae1582c Binary files /dev/null and b/modular_BD2/blacksmith/icons/onmob/64x64_lefthand.dmi differ diff --git a/modular_BD2/blacksmith/icons/onmob/64x64_righthand.dmi b/modular_BD2/blacksmith/icons/onmob/64x64_righthand.dmi new file mode 100644 index 00000000000..cb9c824a3df Binary files /dev/null and b/modular_BD2/blacksmith/icons/onmob/64x64_righthand.dmi differ diff --git a/modular_BD2/blacksmith/icons/onmob/lefthand.dmi b/modular_BD2/blacksmith/icons/onmob/lefthand.dmi new file mode 100644 index 00000000000..0f4a0224612 Binary files /dev/null and b/modular_BD2/blacksmith/icons/onmob/lefthand.dmi differ diff --git a/modular_BD2/blacksmith/icons/onmob/righthand.dmi b/modular_BD2/blacksmith/icons/onmob/righthand.dmi new file mode 100644 index 00000000000..e588e230f49 Binary files /dev/null and b/modular_BD2/blacksmith/icons/onmob/righthand.dmi differ diff --git a/modular_BD2/blacksmith/icons/onmob/slot.dmi b/modular_BD2/blacksmith/icons/onmob/slot.dmi new file mode 100644 index 00000000000..fc2072e6ce1 Binary files /dev/null and b/modular_BD2/blacksmith/icons/onmob/slot.dmi differ diff --git a/modular_BD2/blacksmith/sound/anvil_double1.ogg b/modular_BD2/blacksmith/sound/anvil_double1.ogg new file mode 100644 index 00000000000..b4dfce5df2d Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_double1.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_double2.ogg b/modular_BD2/blacksmith/sound/anvil_double2.ogg new file mode 100644 index 00000000000..06440a4e13b Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_double2.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_double3.ogg b/modular_BD2/blacksmith/sound/anvil_double3.ogg new file mode 100644 index 00000000000..1982d02ccb0 Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_double3.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_heavy.ogg b/modular_BD2/blacksmith/sound/anvil_heavy.ogg new file mode 100644 index 00000000000..bf524d3451d Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_heavy.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_rapid.ogg b/modular_BD2/blacksmith/sound/anvil_rapid.ogg new file mode 100644 index 00000000000..89ba5ee960c Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_rapid.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_single1.ogg b/modular_BD2/blacksmith/sound/anvil_single1.ogg new file mode 100644 index 00000000000..55b07e0c702 Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_single1.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_single2.ogg b/modular_BD2/blacksmith/sound/anvil_single2.ogg new file mode 100644 index 00000000000..1336cdc1c09 Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_single2.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_strong.ogg b/modular_BD2/blacksmith/sound/anvil_strong.ogg new file mode 100644 index 00000000000..9f805f84fa5 Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_strong.ogg differ diff --git a/modular_BD2/blacksmith/sound/anvil_weak.ogg b/modular_BD2/blacksmith/sound/anvil_weak.ogg new file mode 100644 index 00000000000..9cb8768cf9c Binary files /dev/null and b/modular_BD2/blacksmith/sound/anvil_weak.ogg differ diff --git a/modular_BD2/blacksmith/sound/burned.ogg b/modular_BD2/blacksmith/sound/burned.ogg new file mode 100644 index 00000000000..832320ea01a Binary files /dev/null and b/modular_BD2/blacksmith/sound/burned.ogg differ diff --git a/modular_BD2/blacksmith/sound/chain.ogg b/modular_BD2/blacksmith/sound/chain.ogg new file mode 100644 index 00000000000..b836737da71 Binary files /dev/null and b/modular_BD2/blacksmith/sound/chain.ogg differ diff --git a/modular_BD2/blacksmith/sound/craft_3.ogg b/modular_BD2/blacksmith/sound/craft_3.ogg new file mode 100644 index 00000000000..907c8d338ab Binary files /dev/null and b/modular_BD2/blacksmith/sound/craft_3.ogg differ diff --git a/modular_BD2/blacksmith/sound/craft_4.ogg b/modular_BD2/blacksmith/sound/craft_4.ogg new file mode 100644 index 00000000000..e170af29e0c Binary files /dev/null and b/modular_BD2/blacksmith/sound/craft_4.ogg differ diff --git a/modular_BD2/blacksmith/sound/furnace1.ogg b/modular_BD2/blacksmith/sound/furnace1.ogg new file mode 100644 index 00000000000..ad8030797c9 Binary files /dev/null and b/modular_BD2/blacksmith/sound/furnace1.ogg differ diff --git a/modular_BD2/blacksmith/sound/hit_knife.ogg b/modular_BD2/blacksmith/sound/hit_knife.ogg new file mode 100644 index 00000000000..7588e0151c7 Binary files /dev/null and b/modular_BD2/blacksmith/sound/hit_knife.ogg differ diff --git a/modular_BD2/blacksmith/sound/hit_mace.ogg b/modular_BD2/blacksmith/sound/hit_mace.ogg new file mode 100644 index 00000000000..1314612cfe2 Binary files /dev/null and b/modular_BD2/blacksmith/sound/hit_mace.ogg differ diff --git a/modular_BD2/blacksmith/sound/hit_sword.ogg b/modular_BD2/blacksmith/sound/hit_sword.ogg new file mode 100644 index 00000000000..79ed5f47beb Binary files /dev/null and b/modular_BD2/blacksmith/sound/hit_sword.ogg differ diff --git a/modular_BD2/blacksmith/sound/latex.ogg b/modular_BD2/blacksmith/sound/latex.ogg new file mode 100644 index 00000000000..d9a602244e2 Binary files /dev/null and b/modular_BD2/blacksmith/sound/latex.ogg differ diff --git a/modular_BD2/blacksmith/sound/meatslap.ogg b/modular_BD2/blacksmith/sound/meatslap.ogg new file mode 100644 index 00000000000..3d8ea7df1ac Binary files /dev/null and b/modular_BD2/blacksmith/sound/meatslap.ogg differ diff --git a/modular_BD2/blacksmith/sound/pickaxe_2.ogg b/modular_BD2/blacksmith/sound/pickaxe_2.ogg new file mode 100644 index 00000000000..cab14d54747 Binary files /dev/null and b/modular_BD2/blacksmith/sound/pickaxe_2.ogg differ diff --git a/modular_BD2/blacksmith/sound/ripped.ogg b/modular_BD2/blacksmith/sound/ripped.ogg new file mode 100644 index 00000000000..e42e36ce97d Binary files /dev/null and b/modular_BD2/blacksmith/sound/ripped.ogg differ diff --git a/modular_BD2/blacksmith/sound/steam_short.ogg b/modular_BD2/blacksmith/sound/steam_short.ogg new file mode 100644 index 00000000000..1069f276767 Binary files /dev/null and b/modular_BD2/blacksmith/sound/steam_short.ogg differ diff --git a/modular_BD2/blacksmith/sound/steam_whoosh.ogg b/modular_BD2/blacksmith/sound/steam_whoosh.ogg new file mode 100644 index 00000000000..21c7975c084 Binary files /dev/null and b/modular_BD2/blacksmith/sound/steam_whoosh.ogg differ diff --git a/modular_BD2/blacksmith/sound/water_splash2.ogg b/modular_BD2/blacksmith/sound/water_splash2.ogg new file mode 100644 index 00000000000..7ba705f4991 Binary files /dev/null and b/modular_BD2/blacksmith/sound/water_splash2.ogg differ diff --git a/modular_BD2/fashion/README.md b/modular_BD2/fashion/README.md new file mode 100644 index 00000000000..05e8b70695a --- /dev/null +++ b/modular_BD2/fashion/README.md @@ -0,0 +1,39 @@ +# Fashion Fallout Edition +## Who made this module? +Pebbles the 2nd. Credits at the end. + +## What is this module? +All FO servers used the same old ancient set of hairs, parts going back 11 years and without any real direction. This module curates the content, adds some new hairstyles, removes some old ones, and redoes the majority of the existing ones to improve their quality and make them consistent. + +Core principles: +- Hair sorted like facial hair always has been, in categories. Makes it easier to find suitable hair for your character than looking through a long alphabetical list of arbitrarily named hairs. +- Entire lineup redone, old stuff kept when decent, redone if not, tons of edits, new stuff added. Hairs as well as facial hairs. +- Order, same in icon files as in .dms, no duplicates, no unused stuff. +- Collects cosmetics items +- Adds combs/brushes (mood boost, more for longer hairs) +- Adds handheld mirrors (applies makeup, small mood boost) +- Adds straight razor (shaves like a electric razor, only more post apoc, and slower so harder to grief with. Also can cut people up and generally fun) + +## Is it complete? +Yes. +Implementing the module might affect saved character profiles, it will certainly mess up any saved hairs and facial hairstyles 100% since the code saves user profiles by bitflags or something, so changing the order of the hairs in any way causes some annoyances. Something to be aware of, players can just reselect their hair and save and its fine so its no biggie. +Clothing will be affected by repaths/reorgs up-path to some degree. The reason to have them in the module is to keep the sets together, so it does not get spread out and lost. + +The Angel Eyes, Blondie, and Tuco sets are just spawners at the moment, can be added where appropriate. + +## Who dunnit +Some are my own concepts, others edited from minor to total reworks of legacy or other hairstyles from bay and elsewhere, names have been changed when needed to fit the system. Basically, 90% of the hairs got minor to major edits, but also build on the older work of various unknown people. +Comb/Brush code - sparklingsheep +Lipstick/razor code - AffectedArc07 +Handheld mirror & makeup, curating and redoing sprites and the rest- Pebbles the 2nd +Straight razor - Pebbles +Clothing: Burgundy suit minor edits for sleeves, a tiny bit of shade, jacket off state and brand new icon added. Credit to the original creator, its a very nice onmob. +Laceup shoes already has a perfect icon, but the onmobs were not good, so just made new ones. +Some recolors, Tucos hat is heavily edited Vaquero hat, the stetson is a recolored drillhat. +Angel Eyes uniform, shoes, suit, Tuco uniform, suit, shoes, Blondie uniform, shoes, suit, Outcast uniform, patched leather cloak, suit, 50s dress, picnic dress, Benny uniform, nurse uniform & hat - Pebbles. + +v.1.1 notes - Peb +* Added clothing sets & some spawners. Picnic dress, 50s dress, Nurse, Scarecrow, Angel Eyes, Blondie, Tuco, Benny, Burgundy, Tribal outcast +* Added new dynamic hair state: +hood (suitable for hoods/helmets that cover the back of the head but you want longer hairs to peek out.) +* Added new dynamic facial hair prefix: + hood (for where the chin is exposed), done in species.dm + diff --git a/modular_BD2/fashion/icons/clothing_fashion.dmi b/modular_BD2/fashion/icons/clothing_fashion.dmi new file mode 100644 index 00000000000..89c922188f5 Binary files /dev/null and b/modular_BD2/fashion/icons/clothing_fashion.dmi differ diff --git a/modular_BD2/fashion/icons/cosmetics.dmi b/modular_BD2/fashion/icons/cosmetics.dmi new file mode 100644 index 00000000000..c9e26322ec8 Binary files /dev/null and b/modular_BD2/fashion/icons/cosmetics.dmi differ diff --git a/modular_BD2/fashion/icons/onmob.dmi b/modular_BD2/fashion/icons/onmob.dmi new file mode 100644 index 00000000000..a03ea707ae1 Binary files /dev/null and b/modular_BD2/fashion/icons/onmob.dmi differ diff --git a/modular_BD2/fashion/icons/onmobleft.dmi b/modular_BD2/fashion/icons/onmobleft.dmi new file mode 100644 index 00000000000..c55105a3d3b Binary files /dev/null and b/modular_BD2/fashion/icons/onmobleft.dmi differ diff --git a/modular_BD2/fashion/icons/onmobright.dmi b/modular_BD2/fashion/icons/onmobright.dmi new file mode 100644 index 00000000000..88e94b12511 Binary files /dev/null and b/modular_BD2/fashion/icons/onmobright.dmi differ diff --git a/modular_BD2/fashion/sound/shaving.ogg b/modular_BD2/fashion/sound/shaving.ogg new file mode 100644 index 00000000000..22cf4d4ed9d Binary files /dev/null and b/modular_BD2/fashion/sound/shaving.ogg differ diff --git a/modular_BD2/general/code/modular_BD2.dm b/modular_BD2/general/code/modular_BD2.dm new file mode 100644 index 00000000000..24d34fe80d2 --- /dev/null +++ b/modular_BD2/general/code/modular_BD2.dm @@ -0,0 +1,1064 @@ +/* IN THIS FILE + * MATERIALS + * AUTOLATHES + * FALLOUT TOOLS + * WORKBENCHES + * STRUCTURES + * ITEMS +*/ + +////////////////////////////////////////////////// +// // +// // +// MATERIALS // +// // +// // +////////////////////////////////////////////////// + +// ------------ COAL & COKE ------------------ New base material and the sheet that can be used as fuel or ground for charcoal + +/datum/material/coal + name = "coal" + desc = "coal" + color = "#0a0a0a" + alpha = 150 + categories = list(MAT_CATEGORY_RIGID = TRUE, MAT_CATEGORY_BASE_RECIPES = FALSE) + sheet_type = /obj/item/stack/ore/coal + value_per_unit = 0.0050 + +/obj/item/stack/ore/coal // turns to coke when heated in a Furnace or ORM + name = "coal" + desc = "Pure coal needs heat-processing to become good fuel." + icon = 'modular_BD2/general/icons/stackable_items.dmi' + icon_state = "ore_coal" + singular_name = "lump of coal" + points = 2 + custom_materials = null + refined_type = /obj/item/stack/sheet/coke + merge_type = /obj/item/stack/ore/coal + resistance_flags = FLAMMABLE + +/obj/item/stack/sheet/coke // Can be used to fuel Furnaces, Campfires, Barrel Fires, Potbelly stoves, Fireplaces, or grind for charcoal + name = "coke" + desc = "Coke is what you get when you heat-treat coal. It's a good fuel for burning." + singular_name = "bag of coke" + icon = 'modular_BD2/general/icons/stackable_items.dmi' + icon_state = "sheet_coke" + custom_materials = null + throwforce = 2 + grind_results = list(/datum/reagent/medicine/charcoal = 5) + material_type = /datum/material/coal + merge_type = /obj/item/stack/sheet/coke + resistance_flags = FLAMMABLE + +/obj/item/stack/sheet/coke/twenty + amount = 20 + +/turf/closed/mineral/coal + mineralType = /obj/item/stack/ore/coal + spreadChance = 5 + spread = 1 + scan_state = "rock_Coal" +/* +UPDATED CODE TO ALLOW FOR COKE AS FUEL +/obj/machinery/grill/attackby(obj/item/I, mob/user) + if(istype(I, /obj/item/stack/sheet/mineral/coal) || I, /obj/item/stack/sheet/mineral/coke) || istype(I, /obj/item/stack/sheet/mineral/wood)) + var/obj/item/stack/S = I + var/stackamount = S.get_amount() + to_chat(user, span_notice("You put [stackamount] [I]s in [src].")) + if(istype(I, /obj/item/stack/sheet/mineral/coal) || I, /obj/item/stack/sheet/mineral/coke)) + grill_fuel += (500 * stackamount) + else + grill_fuel += (50 * stackamount) + S.use(stackamount) + update_icon() + return + if(I.resistance_flags & INDESTRUCTIBLE) + to_chat(user, span_warning("You don't feel it would be wise to grill [I]...")) + return ..() + if(istype(I, /obj/item/reagent_containers)) + if(istype(I, /obj/item/reagent_containers/food) && !istype(I, /obj/item/reagent_containers/food/drinks)) + if(HAS_TRAIT(I, TRAIT_NODROP) || (I.item_flags & (ABSTRACT | DROPDEL))) + return ..() + else if(!grill_fuel) + to_chat(user, span_notice("There is not enough fuel.")) + return + else if(!grilled_item && user.transferItemToLoc(I, src)) + grilled_item = I + to_chat(user, span_notice("You put the [grilled_item] on [src].")) + update_icon() + grill_loop.start() + return + else + if(I.reagents.has_reagent(/datum/reagent/consumable/monkey_energy)) + grill_fuel += (20 * (I.reagents.get_reagent_amount(/datum/reagent/consumable/monkey_energy))) + to_chat(user, span_notice("You pour the Monkey Energy in [src].")) + I.reagents.remove_reagent("monkey_energy", I.reagents.get_reagent_amount(/datum/reagent/consumable/monkey_energy)) + update_icon() + return + ..() +*/ +/* Added + icon = 'modular_BD2/general/icons/stackable_items.dmi' +to the below +/obj/item/stack/sheet/gold +/obj/item/stack/sheet/silver +/obj/item/stack/sheet/lead +/obj/item/stack/sheet/metal +/obj/item/stack/sheet/plasteel +/obj/item/stack/sheet/mineral/wood +/obj/item/stack/medical/gauze/improvised +/obj/item/stack/sheet/cloth +/obj/item/stack/sheet/plastic +/obj/item/stack/sheet/glass +/obj/item/stack/sheet/leatherstrips +/obj/item/stack/sheet/mineral/limestone +/obj/item/stack/sheet/mineral/concrete +/obj/item/stack/ore/blackpowder +/obj/item/stack/crafting/armor_plate +/obj/item/stack/crafting/metalparts +/obj/item/stack/crafting/goodparts +/obj/item/stack/crafting/electronicparts +/obj/item/stack/crafting/powder +*/ + +////////////////////////////////////////////////// +// // +// // +// AUTOLATHES // +// // +// // +////////////////////////////////////////////////// +/* +// ------------------------------- MANUAL AUTOLATHE ------------------------------ + +/obj/machinery/autolathe/manual + name = "manual lathe" + desc = "Produce simple items with manually cranked tools." + icon = 'modular_BD2/general/icons/autolathe_primitive.dmi' + icon_state = "autolathe" + use_power = NO_POWER_USE + circuit = /obj/item/circuitboard/machine/autolathe/manual + tooadvanced = FALSE + categories = list( + "Tools", + "Construction", + "Equipment", + "Medical", + "Misc", + "Dinnerware", + ) + base_print_speed = 30 + allowed_materials = list( + /datum/material/iron, + /datum/material/glass, + /datum/material/titanium, + /datum/material/bone, + /datum/material/lead + ) + stored_research = /datum/techweb/specialized/autounlocking/autolathe/manual + + +/obj/item/circuitboard/machine/autolathe/manual // not reinventing machine building entirely even if its dorky + name = "manual lathe kit" + +/datum/techweb/specialized/autounlocking/autolathe/manual + design_autounlock_buildtypes = AUTOLATHE_PRIMITIVE + allowed_buildtypes = AUTOLATHE_PRIMITIVE + + +// ------------------------------- MANUAL AUTOLATHE DESIGNS ------------------------------ + +/datum/design/hemostat_primitive + name = "Hemostat (primitive)" + id = "hemostat_primitive" + materials = list(/datum/material/iron = ONE_SHEET*2, /datum/material/bone = HALF_SHEET) + build_path = /obj/item/hemostat/tribal + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/cautery_primitive + name = "Cautery (primitive)" + id = "cautery_primitive" + materials = list(/datum/material/iron = ONE_SHEET*2, /datum/material/glass = HALF_SHEET) + build_path = /obj/item/cautery/primitive + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/razor + name = "Straight razor" + id = "straigth_razor" + materials = list(/datum/material/iron = ONE_SHEET*2, /datum/material/bone = HALF_SHEET) + build_path = /obj/item/melee/onehanded/straight_razor + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/retractor_primitive + name = "Retractor (primitive)" + id = "retractor_primitive" + materials = list(/datum/material/iron = ONE_SHEET*2, /datum/material/bone = HALF_SHEET) + build_path = /obj/item/retractor/tribal + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/bonesetter_primitive + name = "Bonesetter (primitive)" + id = "bonesetter_primitive" + materials = list(/datum/material/iron = ONE_SHEET*2, /datum/material/bone = HALF_SHEET) + build_path = /obj/item/bonesetter + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/handsaw + name = "Hand saw" + id = "handsaw" + materials = list(/datum/material/iron = ONE_SHEET*3) + build_path = /obj/item/circular_saw/primitive + category = list("initial", "Medical") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/lantern + name = "Lantern" + id = "lantern" + materials = list(/datum/material/lead = QUARTER_SHEET, /datum/material/glass = ONE_SHEET) + build_path = /obj/item/flashlight/lantern + category = list("initial","Equipment") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/binoculars + name = "Binoculars" + id = "binoculars" + materials = list(/datum/material/lead = ONE_SHEET*2, /datum/material/glass = ONE_SHEET*10) // leaded glass + build_path = /obj/item/binoculars + category = list("initial","Equipment") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/weldingtool_basic + name = "Welding tool" + id = "weldingtool_basic" + materials = list(/datum/material/iron = ONE_SHEET, /datum/material/glass = QUARTER_SHEET) + build_path = /obj/item/weldingtool/basic + category = list("initial","Tools") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/screwdriver_basic + name = "Screwdriver" + id = "screwdriver_basic" + materials = list(/datum/material/iron = QUARTER_SHEET) + build_path = /obj/item/screwdriver/basic + category = list("initial","Tools") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/wirecutters_basic + name = "Wirecutters" + id = "wirecutters_basic" + materials = list(/datum/material/iron = QUARTER_SHEET) + build_path = /obj/item/wirecutters/basic + category = list("initial","Tools") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/wrench_basic + name = "Wrench" + id = "wrench_basic" + materials = list(/datum/material/iron = HALF_SHEET) + build_path = /obj/item/wrench/basic + category = list("initial","Tools") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/crowbar_basic + name = "Crowbar" + id = "crowbar_basic" + materials = list(/datum/material/iron = HALF_SHEET) + build_path = /obj/item/crowbar/basic + category = list("initial","Tools") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/metal_parts + name = "Metal parts" + id = "metalparts" + materials = list(/datum/material/iron = ONE_SHEET*5) + build_path = /obj/item/stack/crafting/metalparts + category = list("initial","Construction") + build_type = AUTOLATHE_PRIMITIVE + maxstack = 50 + +/datum/design/hq_parts + name = "High quality parts" + id = "hqparts" + materials = list(/datum/material/titanium = ONE_SHEET*5) + build_path = /obj/item/stack/crafting/goodparts + category = list("initial","Construction") + build_type = AUTOLATHE_PRIMITIVE + maxstack = 50 + +/datum/design/titanium + name = "Titanium sheet" + id = "titanium_sheet" + build_type = AUTOLATHE_PRIMITIVE + materials = list(/datum/material/titanium = ONE_SHEET) + build_path = /obj/item/stack/sheet/metal + category = list("initial","Construction") + maxstack = 50 + +/datum/design/lead + name = "Lead sheet" + id = "lead" + build_type = AUTOLATHE | AUTOLATHE_PRIMITIVE + materials = list(/datum/material/lead = ONE_SHEET) + build_path = /obj/item/stack/sheet/lead + category = list("initial","Construction") + maxstack = 50 + +/datum/design/chain + name = "Length of chain" + id = "chain" + materials = list(/datum/material/iron = ONE_SHEET) + build_path = /obj/item/blacksmith/chain + category = list("initial","Construction") + build_type = AUTOLATHE_PRIMITIVE + +/datum/design/lunchbox + name = "Lunchbox" + id = "lunchbox" + build_type = AUTOLATHE_PRIMITIVE + materials = list(/datum/material/iron = ONE_SHEET) + build_path = /obj/item/crafting/lunchbox + category = list("initial", "Misc") + +/datum/design/beartrap + name = "Beartrap" + id = "beartrap" + build_type = AUTOLATHE_PRIMITIVE + materials = list(/datum/material/titanium = ONE_SHEET) + build_path = /obj/item/restraints/legcuffs/beartrap + category = list("initial", "Misc") + +/datum/design/coffeepot + name = "Coffeepot" + id = "coffeepot" + build_type = AUTOLATHE_PRIMITIVE + materials = list(/datum/material/iron = ONE_SHEET) + build_path = /obj/item/crafting/coffee_pot + category = list("initial", "Misc") + +// Also the following recipes has [] | AUTOLATHE_PRIMITIVE } added to build_type: /datum/design/lead, /datum/design/titanium, /datum/design/rods, /datum/design/metal, /datum/design/glass, /datum/design/rglass +// /datum/design/handlabeler, /datum/design/kitchen_knife, /datum/design/fork, /datum/design/beaker, /datum/design/large_beaker, /datum/design/bonesetter +// /datum/design/handcuffs, /datum/design/syringe, /datum/design/igniter, /datum/design/spraycan, /datum/design/extinguisher, /datum/design/welding_helmet, /datum/design/cable_coil +// /datum/design/toolbox, /datum/design/spraybottle, /datum/design/bucket, /datum/design/timer, /datum/design/tray, /datum/design/bowl, /datum/design/drinking_glass, /datum/design/shot_glass +// /datum/design/shaker, /datum/design/earmuffs +// #define AUTOLATHE_PRIMITIVE (1<<13) // ADD to defines machines.dm + + +// ------------------------------- MILITARY AUTOLATHE ------------------------------ + +/obj/machinery/autolathe/military + name = "military autolathe" + desc = "Ancient technology, still works." + icon = 'modular_BD2/general/icons/autolathe_military.dmi' + circuit = /obj/item/circuitboard/machine/autolathe/military + +/obj/item/circuitboard/machine/autolathe/military + name = "army lathe circuit board" + + +// ------------------------------- AMMOLATHE ------------------------------ + +/obj/machinery/autolathe/ammo + name = "reloading bench" + icon = 'modular_BD2/general/icons/ammo_lathe.dmi' + +/obj/machinery/autolathe/ammo/attackby(obj/item/O, mob/user, params) + if(!busy && !stat) + if(istype(O, /obj/item/storage/bag/casings)) + insert_things_from_bag(user, O) + return + if(istype(O, /obj/item/ammo_box)) + if(pre_insert_check(user, O)) + if(!insert_bullets_from_box(user, O)) + return + if(istype(O, /obj/item/gun/ballistic)) + if(pre_insert_check(user, O)) + if(!insert_magazine_from_gun(user, O)) + return + if(panel_open && accepts_books) + if(!simple && istype(O, /obj/item/book/granter/crafting_recipe/gunsmith_one)) + to_chat(user, "You upgrade [src] with simple ammunition schematics.") + simple = TRUE + add_overlay("book1") + qdel(O) + return + if(!basic && istype(O, /obj/item/book/granter/crafting_recipe/gunsmith_two)) + to_chat(user, "You upgrade [src] with basic ammunition schematics.") + basic = TRUE + add_overlay("book2") + qdel(O) + return + else if(!intermediate && istype(O, /obj/item/book/granter/crafting_recipe/gunsmith_three)) + to_chat(user, "You upgrade [src] with intermediate ammunition schematics.") + intermediate = TRUE + add_overlay("book3") + qdel(O) + return + else if(!advanced && istype(O, /obj/item/book/granter/crafting_recipe/gunsmith_four)) + to_chat(user, "You upgrade [src] with advanced ammunition schematics.") + advanced = TRUE + add_overlay("book4") + qdel(O) + return + return ..() + +/obj/machinery/autolathe/ammo/on_deconstruction() + ..() + if(simple) + new /obj/item/book/granter/crafting_recipe/gunsmith_one(src) + if(basic) + new /obj/item/book/granter/crafting_recipe/gunsmith_two(src) + if(intermediate) + new /obj/item/book/granter/crafting_recipe/gunsmith_three(src) + if(advanced) + new /obj/item/book/granter/crafting_recipe/gunsmith_four(src) + cut_overlays() + return + +/obj/machinery/autolathe/ammo/unlocked_basic/Initialize() + . = ..() + add_overlay("book2") + +/obj/machinery/autolathe/ammo/unlocked + simple = TRUE + basic = TRUE + intermediate = TRUE + advanced = TRUE + +/obj/machinery/autolathe/ammo/unlocked/Initialize() + . = ..() + add_overlay("book4") + + +////////////////////////////////////////////////// +// // +// // +// FALLOUT TOOLS // +// // +// // +////////////////////////////////////////////////// + +// ------------------------------- BASIC TOOLS ------------------------------ + +/obj/item/screwdriver/basic + name = "basic screwdriver" + desc = "Shoddy workmanship, but the tool is fully functional." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "screwdriver_basic" + item_state = "screwdriver_basic" + toolspeed = 1.1 + random_color = FALSE + +/obj/item/wrench/basic + name = "wrench (basic)" + desc = "No movable parts, just a simple wrench." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "wrench_basic" + item_state = "wrench_basic" + toolspeed = 1.2 + +/obj/item/crowbar/basic + name = "crowbar" + desc = "Made of poor quality steel and has a rough finish, but it does get the job done." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "crowbar_basic" + item_state = "crowbar_basic" + toolspeed = 1.5 + +/obj/item/wirecutters/basic + name = "basic wirecutters" + desc = "Almost sharp cutters, maded of various bits of scrap metal." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "wirecutters_basic" + item_state = "wirecutters_basic" + toolspeed = 1.3 + random_color = FALSE + +/obj/item/weldingtool/basic + name = "basic welding tool" + desc = "Has some small fuel leaks and looks like its just some rusty piece of junk, but somehow it works." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "welder_basic" + item_state = "welder_basic" + toolspeed = 1.1 + + +// ------------------------------- PRE-WAR TOOLS ------------------------------ Idea is not buildable, obviously, and about 50% better than standard tools. + +/obj/item/wirecutters/prewar + name = "wirecutters (prewar)" + desc = "High quality steel and precise mechanism." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "wirecutters_prewar" + item_state = "wirecutters_prewar" + toolspeed = 0.4 + random_color = FALSE + +/obj/item/wrench/prewar // obsolete due to power drill + name = "wrench (prewar)" + desc = "An torque locking tool thats very good for wrenching." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "wrench_prewar" + item_state = "wrench_prewar" + toolspeed = 0.5 + +/obj/item/screwdriver/prewar + name = "screwdriver (prewar)" + desc = "Polymer handle, blackened steel finish, its a high-quality tool for sure."" + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "screwdriver_prewar" + item_state = "screwdriver_prewar" + toolspeed = 0.5 + random_color = FALSE + +/obj/item/crowbar/prewar + name = "crowbar (prewar)" + desc = "Heat-resistant powder coating, smooth steel surfaces, its a high-quality tool for sure."" + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "crowbar_prewar" + item_state = "crowbar_prewar" + toolspeed = 0.8 + +/obj/item/screwdriver/power // obsolete due to power drill + icon = 'modular_BD2/general/icons/tools.dmi' + icon_state = "drill_screw" + item_state = "drill" + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + +/obj/item/wrench/power + icon = 'modular_BD2/general/icons/tools.dmi' + icon_state = "drill_bolt" + item_state = "drill" + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + +/obj/item/weldingtool/prewar + name = "welding tool (pre-war)" + desc = "Comfortable grip, large tank and precise cutting." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "welder_prewar" + item_state = "welder_prewar" + toolspeed = 0.7 + max_fuel = 40 + +/obj/item/metaldetector + name = "metal detector" + desc = "Detects buried metals in a 50 metre radius when activated." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "metaldetect" + + + +////////////////////////////////////////////////// +// // +// // +// WORKBENCHES // +// // +// // +////////////////////////////////////////////////// + +// ------------ METALWORKING BENCH ------------------ + +/obj/machinery/workbench/forge // should be repathed to worbench/metal + name = "metalworking bench" + desc = "A workbench with a drill press, a makeshift blowtorch setup, and various tools for making crude weapons and tools." + icon = 'modular_BD2/blacksmith/icons/workbench64x32.dmi' + icon_state = "bench_metal" + + +// ------------ WORKBENCH ------------------ + +/obj/machinery/workbench + desc = "A basic workbench with a full set of tools for simple to intermediate projects." + icon = 'modular_BD2/general/icons/workbench.dmi' + machine_tool_behaviour = list(TOOL_WORKBENCH, TOOL_CROWBAR, TOOL_SCREWDRIVER, TOOL_WIRECUTTER, TOOL_WRENCH) + drag_delay = 0.4 SECONDS // Heavy, slow to drag + + +// ------------ ADVANCED WORKBENCH ------------------ + +/obj/machinery/workbench/advanced + desc = "A large and advanced pre-war workbench to tackle any project! Comes with a full set of basic tools and a digital multitool." + icon = 'modular_BD2/general/icons/workbench.dmi' + machine_tool_behaviour = list(TOOL_AWORKBENCH, TOOL_WORKBENCH, TOOL_CROWBAR, TOOL_SCREWDRIVER, TOOL_WIRECUTTER, TOOL_WRENCH, TOOL_MULTITOOL) + +*/ + + +////////////////////////////////////////////////// +// // +// // +// STRUCTURES // +// // +// // +////////////////////////////////////////////////// + +/* Copied to base code + +/obj/structure/closet/crate/basic + icon = 'modular_BD2/general/icons/crates.dmi' + +// ------------ CRATES ------------------ + +/obj/structure/closet/crate/wicker + icon = 'icons/fallout/farming/farming_tools.dmi' + open_sound = 'sound/effects/rustle3.ogg' + close_sound = 'sound/effects/rustle3.ogg' + material_drop = /obj/item/stack/sheet/hay + +/obj/structure/closet/crate/footchest + icon = 'modular_BD2/general/icons/crates.dmi' + open_sound = 'modular_BD2/sound/creak.ogg' + close_sound = 'modular_BD2/sound/creak.ogg' + dense_when_open = FALSE +*/ + + +/* + +////////////////////////////////////////////////// +// // +// // +// ITEMS // +// // +// // +////////////////////////////////////////////////// + +// -------------------- TOOLBOX (PREWAR) ------------------ Meant to be loot possible to find in well preserved high tech places + +/obj/item/storage/toolbox/prewar + name = "toolbox (pre-war)" + desc = "Plastic toolbox, made long ago." + icon = 'modular_BD2/general/icons/tools.dmi' + righthand_file = 'modular_BD2/general/icons/righthand.dmi' + lefthand_file = 'modular_BD2/general/icons/lefthand.dmi' + icon_state = "toolbox_prewar" + item_state = "toolbox_prewar" + custom_materials = list(/datum/material/plastic = 500) + +/obj/item/storage/toolbox/prewar/PopulateContents() + new /obj/item/crowbar/prewar(src) + new /obj/item/wirecutters/prewar(src) + new /obj/item/wrench/prewar(src) + new /obj/item/weldingtool/prewar(src) + new /obj/item/screwdriver/prewar(src) + new /obj/item/multitool(src) + + +// ------------------------------- ABRAXO SPRAYBOTTLE ------------------------------ +// Abraxo spray is now made by adding Abraxo to a spray bottle, not taking a pinch of glass and snap your fingers. +// Abraxo my beloved. Slap it on spray bottle, clean away. + +/obj/item/reagent_containers/spray/empty/attackby(obj/item/C, mob/user, params) + if(istype(C, /obj/item/crafting/abraxo)) + user.visible_message("[user] begins filling the[src] with Abraxo solution.", \ + span_notice("You begin filling he [src] with Abraxo. Smells nice."), \ + span_italic("You hear faint bubbling sounds.")) + playsound(get_turf(src), 'modular_BD2/sound/abraxo.ogg', 100, TRUE) + if(!do_after(user, 40, TRUE, src)) + return + new /obj/item/reagent_containers/spray/cleaner(drop_location()) + qdel(src) + qdel(C) + return + return ..() + +/obj/item/reagent_containers/spray/empty + desc = "A spray bottle, with an unscrewable top. Meant to be filled with Abraxo for superior cleanliness." + icon = 'modular_BD2/general/icons/cleaning.dmi' + + +// ------------------------------- MATCHBOX FIX ------------------------------ + +/obj/item/storage/box/matches/attackby(obj/item/match/W as obj, mob/user as mob, params) + if(istype(W, /obj/item/match)) + if(prob(50)) + playsound(src, 'sound/f13items/matchstick_hit.ogg', 80, TRUE) + return + else + W.matchignite() + playsound(src, 'sound/f13items/matchstick_lit.ogg', 80, TRUE) + + + +// ------------ CRAFING STACKABLE ICON UPDATERS ------------------ +/obj/item/stack/crafting/update_icon_state() + var/amount = get_amount() + if(amount <= 5) + icon_state = initial(icon_state) + else if(amount <= 25) + icon_state = "[initial(icon_state)]_2" + else + icon_state = "[initial(icon_state)]_3" + +// Adapted for the specific bullet remnant stacking +/obj/item/stack/crafting/powder/update_icon_state() + var/amount = get_amount() + if(amount <= 80) + icon_state = initial(icon_state) + else if(amount <= 160) + icon_state = "[initial(icon_state)]_2" + else + icon_state = "[initial(icon_state)]_3" + + +// -------------------- CRAFTING RECIPES ------------------ + +/datum/crafting_recipe/broom + name = "Broom" + result = /obj/item/broom + time = 50 + reqs = list(/obj/item/stack/sheet/hay = 2, + /obj/item/stack/sheet/mineral/wood = 4) + category = CAT_CRAFTING + subcategory = CAT_TOOL + +/datum/crafting_recipe/mop + name = "Mop" + result = /obj/item/mop + time = 50 + reqs = list(/obj/item/stack/sheet/cloth = 2, + /obj/item/stack/sheet/mineral/wood = 4) + category = CAT_CRAFTING + subcategory = CAT_TOOL + + +// -------------------- ARMOR KIT CUSTOMIZATION ------------------ Because I like slapcrafting and Id like for my shoulder kit to be craftable + +/obj/item/clothing/suit/armor/light/kit/attackby(obj/item/C, mob/user, params) + if(istype(C, /obj/item/crafting/duct_tape)) + user.visible_message("[user] begins taping on some punky bits to the the [src].", \ + span_notice("You begin taping some punkish item on the [src]."), \ + span_italic("You hear someone tape stuff together.")) + playsound(src, 'sound/f13items/craft_2.ogg', 100, TRUE) + if(!do_after(user, 40, TRUE, src)) + return + new /obj/item/clothing/suit/armor/light/kit/punk(drop_location()) + qdel(src) + qdel(C) + return + if(istype(C, /obj/item/stack/sheet/metal)) + user.visible_message("[user] begins adding metal sheet to the the [src].", \ + span_notice("You begin attaching some metal sheet on the [src]."), \ + span_italic("You hear grunts as someone tries to bend metal with their hands.")) + playsound(src, 'sound/f13items/craft_2.ogg', 100, TRUE) + if(!do_after(user, 40, TRUE, src)) + return + new /obj/item/clothing/suit/armor/light/kit/plates(drop_location()) + qdel(src) + C.use(1) + return + if(C.tool_behaviour == TOOL_WIRECUTTER) + user.visible_message("[user] begins cutting new straps to wear [src] differently.", \ + span_notice("You begin cutting straps and readjusting the [src]."), \ + span_italic("You hear the snips of a wirecutter on fabric.")) + playsound(src, 'sound/weapons/slice.ogg', 50, TRUE) + if(!do_after(user, 40, TRUE, src)) + return + new /obj/item/clothing/suit/armor/light/kit/shoulder(drop_location()) + qdel(src) + return + return ..() + + +// -------------------- HAIR & BEARDS ------------------ +Files edited to make the new hair icon set work: +species.dm adjusted for new hair an beard suffixes + changed names. +hair_head.dm +hair_face.dm +*/ + +/obj/structure/rack/shelf_wood + name = "BUGGED VERSION, MURDER" + desc = "NO!!!." + +// TEMP FOR PORTING AND FUNCTIOANLITY + +// ------------------------ STRAIGHT RAZOR ------------------------------- // Pebbles straight razor. It borrows the razor code, edits some timers, adds sounds and slaps it on a melee weapon. +/obj/item/melee/onehanded/straight_razor + name = "straight razor" + desc = "For those smooth close shaves. Better aim for the mouth or the head, or else things might get messy. Could be used as a scalpel in a pinch." + icon = 'modular_BD2/fashion/icons/cosmetics.dmi' + righthand_file = 'modular_BD2/fashion/icons/onmobright.dmi' + lefthand_file = 'modular_BD2/fashion/icons/onmobleft.dmi' + icon_state = "straight_razor" + force = WEAPON_FORCE_BIG_TOOL + throwforce = THROWING_PATHETIC + wound_bonus = WOUNDING_MALUS_SHALLOW // crap against armor + bare_wound_bonus = WOUNDING_BONUS_BIG // bleeds a lot, despite its low damage + sharpness = SHARP_EDGED + total_mass = TOTAL_MASS_TINY_ITEM + w_class = WEIGHT_CLASS_TINY + tool_behaviour = TOOL_SCALPEL //ghetto surgery yay + toolspeed = 1.2 + +/obj/item/melee/onehanded/straight_razor/proc/manual_shave(mob/living/carbon/human/H, location = BODY_ZONE_PRECISE_MOUTH) + if(location == BODY_ZONE_PRECISE_MOUTH) + H.facial_hair_style = "Clean shave (Hairless)" + else + H.hair_style = "Skinhead" + + H.update_hair() + +/obj/item/melee/onehanded/straight_razor/attack(mob/M, mob/user) + if(ishuman(M)) + var/mob/living/carbon/human/H = M + var/location = user.zone_selected + if((location in list(BODY_ZONE_PRECISE_EYES, BODY_ZONE_PRECISE_MOUTH, BODY_ZONE_HEAD)) && !H.get_bodypart(BODY_ZONE_HEAD)) + to_chat(user, span_warning("[H] doesn't have a head!")) + return + if(location == BODY_ZONE_PRECISE_MOUTH) + if(!(FACEHAIR in H.dna.species.species_traits)) + to_chat(user, span_warning("There is no facial hair to shave!")) + return + if(!get_location_accessible(H, location)) + to_chat(user, span_warning("The mask is in the way!")) + return + if(H.facial_hair_style == "Clean shave (Hairless)") + to_chat(user, span_warning("Already clean-shaven!")) + return + + if(H == user) //shaving yourself + playsound(loc, 'modular_BD2/fashion/sound/shaving.ogg', 100, 1) // added + user.visible_message("[user] starts to shave [user.p_their()] facial hair with [src].", \ + span_notice("You take a moment to shave your facial hair with [src]...")) + if(do_after(user, 150, target = H)) + user.visible_message("[user] shaves [user.p_their()] facial hair clean with [src].", \ + span_notice("You finish shaving with [src]. Fast and clean!")) + manual_shave(H, location) + else + var/turf/H_loc = H.loc + playsound(loc, 'modular_BD2/fashion/sound/shaving.ogg', 100, 1) // added + user.visible_message(span_warning("[user] tries to shave [H]'s facial hair with [src]."), \ + span_notice("You start shaving [H]'s facial hair...")) + if(do_after(user, 100, target = H)) + if(H_loc == H.loc) + user.visible_message(span_warning("[user] shaves off [H]'s facial hair with [src]."), \ + span_notice("You shave [H]'s facial hair clean off.")) + manual_shave(H, location) + + else if(location == BODY_ZONE_HEAD) + if(!(HAIR in H.dna.species.species_traits)) + to_chat(user, span_warning("There is no hair to shave!")) + return + if(!get_location_accessible(H, location)) + to_chat(user, span_warning("The headgear is in the way!")) + return + if(H.hair_style == "Bald" || H.hair_style == "Mature (Balding)" || H.hair_style == "Clean shave (Hairless)") + to_chat(user, span_warning("There is not enough hair left to shave!")) + return + + if(H == user) //shaving yourself + playsound(loc, 'modular_BD2/fashion/sound/shaving.ogg', 100, 1) // added + user.visible_message("[user] starts to shave [user.p_their()] head with [src].", \ + span_notice("You start to shave your head with [src]...")) + if(do_after(user, 150, target = H)) //edited time + user.visible_message("[user] shaves [user.p_their()] head with [src].", \ + span_notice("You finish shaving with [src].")) + manual_shave(H, location) + else + var/turf/H_loc = H.loc + playsound(loc, 'modular_BD2/fashion/sound/shaving.ogg', 100, 1) // added + user.visible_message(span_warning("[user] tries to shave [H]'s head with [src]!"), \ + span_notice("You start shaving [H]'s head...")) + if(do_after(user, 150, target = H)) //edited time + if(H_loc == H.loc) + user.visible_message(span_warning("[user] shaves [H]'s head bald with [src]!"), \ + span_notice("You shave [H]'s head bald.")) + manual_shave(H, location) + else + ..() + else + ..() + + +////////////////////////////////////////// +// // +// // +// PRIMITIVE MEDICAL // +// // +// // +////////////////////////////////////////// + +// ------------------- BUTCHERS TABLE ----------------------------- + +/obj/structure/table/optable/primitive + name = "butchers table" + desc = "Used for painful, primitive medical procedures." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + + +// ------------------- PRIMITIVE SURGERY STUFF ----------------------------- Could use more janky ghetto stuff feeling, messing about in the wound datums maybe or whatnot. Currently basically reskins with a bit slower speed. + +/obj/item/cautery/primitive + name = "primitive cautery" + desc = "A welding device tuned down to cauterize wounds. Not very precise." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "cautery_primitive" + toolspeed = 1.5 + +/obj/item/circular_saw/primitive + name = "handsaw" + desc = "For sawing through wood or possibly bones." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "saw" + item_state = "saw" + lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi' + righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi' + hitsound = 'sound/effects/shovel_dig.ogg' + usesound = 'sound/effects/shovel_dig.ogg' + custom_materials = list(/datum/material/iron=2000) + toolspeed = 1.2 + wound_bonus = 0 + bare_wound_bonus = 10 + attack_verb = list("sawed", "scratched") + +/obj/item/stack/medical/bone_gel/superglue + name = "superglue (bonegel)" + singular_name = "superglue" + desc = "Good for gluing together broken bones!" + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "superglue" + lefthand_file = NONE + righthand_file = NONE + grind_results = NONE + +/obj/item/reagent_containers/medspray/sterilizine/honey + name = "medical honey (sterilizer)" + desc = "Pure honey has antiseptic properties, and probably works just as a sterilizing agent." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "sterilizer_honey" + apply_method = "smear" +// sound_squirt = 'modular_BD2/general/sound/honey.ogg' FIX LATER MARKED FOR DEATH + +/* Added to base code +sound_squirt +Added to proc/attempt_spray + playsound(src, sound_squirt, 50, 1, -6) +*/ + +// ------------------- PRIMITIVE MEDICAL BAG ----------------------------- + +/obj/item/storage/backpack/duffelbag/med/surgery/primitive + name = "surgical duffel bag" + desc = "A large duffel bag for holding extra medical supplies - this one seems to be designed for holding surgical tools." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "toolbag_primitive" + +/obj/item/storage/backpack/duffelbag/med/surgery/primitive/PopulateContents() + new /obj/item/melee/onehanded/straight_razor(src) + new /obj/item/hemostat/tribal(src) + new /obj/item/retractor/tribal(src) + new /obj/item/circular_saw/primitive(src) + new /obj/item/cautery/primitive(src) + new /obj/item/bonesetter(src) + new /obj/item/bedsheet/blanket(src) + new /obj/item/reagent_containers/medspray/sterilizine/honey(src) + new /obj/item/stack/sticky_tape/surgical(src) + new /obj/item/stack/medical/bone_gel/superglue(src) + +/obj/item/storage/backpack/duffelbag/med/surgery/primitive/anchored + name = "surgical toolset" + desc = "Large piece of felt with various surgical tools laid out." + icon_state = "surgicalset_primitive" + anchored = TRUE + + +// ------------------- PRIMITIVE IV DRIP ----------------------------- + +/obj/machinery/iv_drip/primitive + name = "wooden IV drip" + desc = "Simple frame for infusing liquids using gravity. Can't suck out fluids." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + anchored = TRUE + plane = GAME_PLANE + +/* +/obj/machinery/iv_drip/verb/toggle_mode() updated +added this to make the overlay actually work + var/mutable_appearance/filling_overlay = mutable_appearance('modular_BD2/icons/primitive_medical.dmi', "reagent") +*/ + + +// ------------------- PRIMITIVE DEFIB MOUNT ----------------------------- + +/obj/machinery/defibrillator_mount/primitive + desc = "Holds a primitive defibrillator." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "defibrillator_mount" + density = FALSE + use_power = FALSE + clamps_locked = TRUE + plane = GAME_PLANE + +/obj/machinery/defibrillator_mount/primitive/Initialize() //loaded subtype for mapping use + . = ..() + defib = new/obj/item/defibrillator/primitive(src) + update_overlays() + + +// ------------------- PRIMITIVE MEDICAL TOOLBELT ----------------------------- + +obj/item/storage/belt/medical/primitive + name = "primitive medical toolbelt" + desc = "This might look a bit like a toolbelt for a carpenter, but the items inside are meant to be used in surgery. No really." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "belt_blacksmith" + item_state = "belt_blacksmith" + +/obj/item/storage/belt/medical/primitive/PopulateContents() + new /obj/item/surgical_drapes(src) + new /obj/item/melee/onehanded/straight_razor(src) + new /obj/item/circular_saw/primitive(src) + new /obj/item/retractor/tribal(src) + new /obj/item/hemostat/tribal(src) + new /obj/item/cautery/primitive(src) + new /obj/item/bonesetter(src) + +/obj/item/hemostat/tribal + name = "primitive hemostat (flesh-poker)" + desc = "A pinching device made from bone to clamp bleedings with" + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "hemostat_primitive" + +/obj/item/retractor/tribal + name = "primitive retractor (skin-puller)" + desc = "Pries the flesh and bones open." + icon = 'modular_BD2/general/icons/primitive_medical.dmi' + icon_state = "retractor_primitive" + diff --git a/modular_BD2/general/icons/alchemy.dmi b/modular_BD2/general/icons/alchemy.dmi new file mode 100644 index 00000000000..5ee4427505c Binary files /dev/null and b/modular_BD2/general/icons/alchemy.dmi differ diff --git a/modular_BD2/general/icons/autolathe_military.dmi b/modular_BD2/general/icons/autolathe_military.dmi new file mode 100644 index 00000000000..f4b2edaddda Binary files /dev/null and b/modular_BD2/general/icons/autolathe_military.dmi differ diff --git a/modular_BD2/general/icons/autolathe_primitive.dmi b/modular_BD2/general/icons/autolathe_primitive.dmi new file mode 100644 index 00000000000..07807f80b3b Binary files /dev/null and b/modular_BD2/general/icons/autolathe_primitive.dmi differ diff --git a/modular_BD2/general/icons/door_barred.dmi b/modular_BD2/general/icons/door_barred.dmi new file mode 100644 index 00000000000..a47b46fdde3 Binary files /dev/null and b/modular_BD2/general/icons/door_barred.dmi differ diff --git a/modular_BD2/general/icons/primitive_medical.dmi b/modular_BD2/general/icons/primitive_medical.dmi new file mode 100644 index 00000000000..54976d5dc96 Binary files /dev/null and b/modular_BD2/general/icons/primitive_medical.dmi differ diff --git a/modular_BD2/general/icons/stackable_items.dmi b/modular_BD2/general/icons/stackable_items.dmi new file mode 100644 index 00000000000..58bd8e34276 Binary files /dev/null and b/modular_BD2/general/icons/stackable_items.dmi differ diff --git a/modular_BD2/general/icons/tileset_gravel.dmi b/modular_BD2/general/icons/tileset_gravel.dmi new file mode 100644 index 00000000000..ecbeca29802 Binary files /dev/null and b/modular_BD2/general/icons/tileset_gravel.dmi differ diff --git a/modular_BD2/general/icons/tileset_sonora.dmi b/modular_BD2/general/icons/tileset_sonora.dmi new file mode 100644 index 00000000000..e7ae0e6fd4c Binary files /dev/null and b/modular_BD2/general/icons/tileset_sonora.dmi differ diff --git a/modular_BD2/general/sound/abraxo.ogg b/modular_BD2/general/sound/abraxo.ogg new file mode 100644 index 00000000000..45640e91c38 Binary files /dev/null and b/modular_BD2/general/sound/abraxo.ogg differ diff --git a/modular_BD2/general/sound/creak.ogg b/modular_BD2/general/sound/creak.ogg new file mode 100644 index 00000000000..017c94e2d1e Binary files /dev/null and b/modular_BD2/general/sound/creak.ogg differ diff --git a/modular_BD2/general/sound/doorchainsoft_close.ogg b/modular_BD2/general/sound/doorchainsoft_close.ogg new file mode 100644 index 00000000000..22ec134833d Binary files /dev/null and b/modular_BD2/general/sound/doorchainsoft_close.ogg differ diff --git a/modular_BD2/general/sound/doorchainsoft_open.ogg b/modular_BD2/general/sound/doorchainsoft_open.ogg new file mode 100644 index 00000000000..f12c402e1ba Binary files /dev/null and b/modular_BD2/general/sound/doorchainsoft_open.ogg differ diff --git a/modular_BD2/general/sound/honey.ogg b/modular_BD2/general/sound/honey.ogg new file mode 100644 index 00000000000..d72e48177da Binary files /dev/null and b/modular_BD2/general/sound/honey.ogg differ diff --git a/modular_BD2/legio_invicta/README.md b/modular_BD2/legio_invicta/README.md new file mode 100644 index 00000000000..d22031a5025 --- /dev/null +++ b/modular_BD2/legio_invicta/README.md @@ -0,0 +1,22 @@ +# Legio Invicta v.1.0 + +## Who made this module? +Pebbles the 2nd. Credits at the end. + +## What is this module? +Legion art/assets, to improve quality and make maintaining it easier. + +Core principles: +- Icon, onmob sprites, inhands for all items, palette created and enforced, focus on the final coordinated appearance, not each item in a vacuum. + +## Is it complete? +Its as complete as I ever will make it, its my last thing I do for FO13 so enjoy. + +## Who dunnit +Vast majority of the content are my orignals, a portion is originally based on legacy concepts though, like the bandana general design, the base legion tunic also has to be included here. + +* The Legion cloak is based on a existing sprite and re-uses parts of two different sprites. Credit for the concept goes to the creators, who I sadly do not know the name of. +* couple melee weapons borrowing partly from legacy in either onmobs or icon (goliath icon partly, thermic lance onmob almost unchanged) +* medallions, legion belt, bandanas, leather boots, legion mantle based on legacy art, medallions and mantle borrows the most. +* 100& original (rugged holster, rocket hammer, ripper, spatha, gladius, machete, lawnmower machete, lance, training machete, marching satchel, survival package, medical kit, goggles, plated & fingerless gloves, plated boots, armors: recruit, prime, veteran, vex, praetorian, helmets: recruit, prime, vet, vex). Some are upgrades of my old stuff, reused a couple solutions I used on my khan spriteset for example. +* Vex helmet onmob reuses much of the legacy sprite, leather sandals too, even if onmob very different diff --git a/modular_BD2/legio_invicta/code/legio_invicta.dm b/modular_BD2/legio_invicta/code/legio_invicta.dm new file mode 100644 index 00000000000..97aa07ad21d --- /dev/null +++ b/modular_BD2/legio_invicta/code/legio_invicta.dm @@ -0,0 +1,1273 @@ +// This file basically redirects the art here without changing the rest of the values. If you reformat the armors or something obviously you will need to copy these paths to the new items for the correct art to display. +// Commented out stuff has been edited in the base files to redirect the art already. + + +// --------------------- ID & MEDALLIONS ------------------------- + +// /obj/item/card/id/dogtag/legrecruit obsolete +/obj/item/card/id/dogtag/legion + name = "recruit medallion" + desc = "A cheap metal disc stamped with the Legion's bull insignia." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "medallion_recruit" + item_state = null + assignment = "recruit medallion" + +// /obj/item/card/id/dogtag/legprime obsolete +/obj/item/card/id/dogtag/legion/prime + name = "prime medallion" + desc = "A silver disc stamped with the Legion's bull insignia." + icon_state = "medallion_prime" + assignment = "prime medallion" + +// /obj/item/card/id/dogtag/legveteran obsolete +/obj/item/card/id/dogtag/legion/veteran + name = "veteran medallion" + desc = "A silver disc stamped with the Legion's bull insignia and red honorific markings." + icon_state = "medallion_veteran" + assignment = "veteran medallion" + +// -/obj/item/card/id/dogtag/legcenturion obsolete +/obj/item/card/id/dogtag/legion/centurion + name = "centurion medallion" + desc = "A golden disc awarded to the most fierce men in the whole legion. If you are close enough to read the insignia you won't be alive much longer." + icon_state = "medallion_centurion" + assignment = "centurion medallion" + +// /obj/item/card/id/dogtag/legforgemaster obsolete +/obj/item/card/id/dogtag/legion/follower + name = "camp follower medallion" + desc = "A silver disc stamped with the Legion's Bull insignia." + icon_state = "medallion_recruit" + assignment = "camp follower medallion" + +// /obj/item/card/id/dogtag/legauxilia obsolete +/obj/item/card/id/dogtag/legion/follower/auxilia + name = "auxilia medallion" + desc = "A silver disc stamped with the Legion's Bull insignia." + icon_state = "medallion_prime" + assignment = "auxilia medallion" + +// /obj/item/card/id/dogtag/legorator obsolete +/obj/item/card/id/dogtag/legion/orator + name = "orator medallion" + desc = "A golden disc awarded to the one who is a dedicated ambassador for Caesar's Legion." + icon_state = "medallion_centurion" + assignment = "orator medallion" + +/obj/item/card/id/dogtag/legion/offduty + name = "off-duty medallion" + desc = "The wearer is free from his military duties this week." + + +// - /obj/item/card/id/legionbrand obsolete +/obj/item/card/id/legion_slave + name = "Legion slave brand" + desc = "Property of the Legion. Burned into the flesh with a cattle-iron." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "brand_slave" + assignment = "Slave brand" + uses_overlays = FALSE + +/obj/item/card/id/legion_slave/Initialize() + . = ..() + ADD_TRAIT(src, TRAIT_NODROP, TRAIT_GENERIC) + +// obsolete /obj/item/card/id/rusted/rustedmedallion +/obj/item/card/id/rusted/legion_exile + name = "rusted medallion" + desc = "This Legion medallion is rusted and worn, kept as a memento." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "medallion_exile" + + +// --------------------- GLOVES ----------------------------- +/* Already copied to main +/obj/item/clothing/gloves/legion + name = "fingerless gloves" + desc = "Improves the grip on a machete even when slick with blood, widely used by Legion warriors." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "gloves_fingerless" + item_state = "gloves_fingerless" + +/obj/item/clothing/gloves/legion/plated + name = "plated gloves" + desc = "Leather gloves with metal reinforcements." + icon_state = "gloves_plated" + item_state = "gloves_plated" +*/ + + +// --------------------- BANDANA ----------------------------- + +/obj/item/clothing/mask/bandana/legion + name = "red bandana" + desc = "Simple cloth bandana dyed red. Very common in the Legion." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "bandana_legion" + flags_inv = HIDEFACE + visor_flags_inv = HIDEFACE + adjusted_flags = null + actions_types = list(/datum/action/item_action/adjust) + +// /obj/item/clothing/mask/bandana/legion/legrecruit obsolete +/obj/item/clothing/mask/bandana/legion/recruit + name = "recruit bandana" + desc = "Bandana made from cheap cloth." + icon_state = "bandana_recruit" + +// /obj/item/clothing/mask/bandana/legion/camp obsolete +/obj/item/clothing/mask/bandana/legion/dark + name = "dark bandana" + desc = "Plain cotton bandana." + icon_state = "bandana_dark" + +/obj/item/clothing/mask/bandana/legion/centurion + name = "centurions bandana" + desc = "Made from fine cloth with a distinctive pattern." + icon_state = "bandana_centurion" + + + +// ------------------- GOGGLES ----------------------------- + +// Polarizing goggles. togglable, Nightvision goggles basically +/obj/item/clothing/glasses/night/polarizing // possibly it would be better to make this just flash protect or such, and keep NVG to NVG looking goggle thingies. Dunno. + name = "polarizing goggles" + desc = "Fancy goggles with rare polarizing glass from some old cache, usually reserved for commanders." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "goggles_polarizing" + item_state = "goggles_polarizing" + darkness_view = 12 + lighting_alpha = LIGHTING_PLANE_ALPHA_NV_TRAIT + glass_colour_type = /datum/client_colour/glass_colour/lightorange + actions_types = list(/datum/action/item_action/toggle) + visor_flags_inv = HIDEEYES + visor_flags_cover = MASKCOVERSEYES + visor_vars_to_toggle = VISOR_TINT | VISOR_DARKNESSVIEW + alternate_worn_layer = (HEAD_LAYER-0.1) // so its not hidden + +/obj/item/clothing/glasses/night/polarizing/attack_self(mob/user) + weldingvisortoggle(user) + +// /obj/item/clothing/glasses/legiongoggles obsolete. Togglable, gives some slight environment armor bonus I believe. +/obj/item/clothing/glasses/f13/goggles_sandstorm + name = "sandstorm goggles" + desc = "Simple, tight-fitting goggles that protect your eyes from dust and sand." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "goggles" + item_state = "goggles" + toggle_message = "You pull down the" + alt_toggle_message = "You push up the" + actions_types = list(/datum/action/item_action/toggle) + visor_flags_inv = HIDEEYES + visor_flags_cover = MASKCOVERSEYES + visor_vars_to_toggle = VISOR_TINT | VISOR_DARKNESSVIEW + alternate_worn_layer = (HEAD_LAYER-0.1) // so its not hidden + +/obj/item/clothing/glasses/f13/goggles_sandstorm/attack_self(mob/user) + weldingvisortoggle(user) + + +// ------------------- BELT ----------------------------- + +/obj/item/storage/belt/military/legion + name = "legion marching belt" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "belt_legion" + item_state = "belt_legion" + + +// ------------------- WEAPONS ----------------------------- + +/* Already copied to main +/obj/item/melee/onehanded/machete + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/beltslot.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "machete_lawnmower" + item_state = "machete_lawnmower" + +/obj/item/melee/onehanded/machete/spatha +/obj/item/melee/onehanded/machete/gladius +/obj/item/melee/onehanded/machete/training + +/obj/item/melee/onehanded/machete/forgedmachete + icon_state = "machete" + item_state = "machete" + +/obj/item/twohanded/sledgehammer/supersledge + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/backslot.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + +/obj/item/twohanded/spear/lance + name = "legion lance" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/64x64_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/64x64_lefthand.dmi' + icon_state = "lance" + icon_prefix = "lance" + wielded_icon = "lance_wield" + inhand_x_dimension = 64 + inhand_y_dimension = 64 + +/obj/item/melee/unarmed/powerfist/goliath + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + +/obj/item/twohanded/thermic_lance + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/backslot.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/64x64_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/64x64_lefthand.dmi' + +/obj/item/twohanded/sledgehammer/rockethammer +/obj/item/twohanded/fireaxe +/obj/item/melee/powered/ripper + +/obj/item/twohanded/chainsaw + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/backslot.dmi' + +/obj/item/clothing/glasses/f13/sunglasses + name = "sunglasses" + desc = "Makes the strong desert sun a lot more bearable. Some protection against blinding lights is a bonus." + icon = 'icons/fallout/clothing/glasses.dmi' + icon_state = "sun" + item_state = "sunglasses" + darkness_view = 1 + flash_protect = 1 + tint = 1 + glass_colour_type = /datum/client_colour/glass_colour/gray + +/obj/item/clothing/glasses/f13/sunglasses/big + icon_state = "bigsunglasses" + item_state = "bigsunglasses" + layer = (FACEMASK_LAYER-0.1) // only reason for this is to make it look good over bandana masks. + alternate_worn_layer = (FACEMASK_LAYER-0.1) +*/ + + + + +// ------------------- APRONS & MANTLES ----------------------------- +// same as medical apron but visually unique +/obj/item/clothing/neck/apron/medicus_legion + name = "medicus apron" + desc = "Waxed cotton apron with a red bull on it. Marks the wearer as a healer following the wisdom of Caesar. Has pockets for some small medical equipment." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "apron_medicus" + pocket_storage_component_path = /datum/component/storage/concrete/pockets/medical + +// same as normal labor apron but visually unique +/obj/item/clothing/neck/apron/labor/blacksmith_legion + name = "blacksmith's apron" + desc = "A heavy leather apron designed for protecting the user when metalforging and help carry some minor tools. Marked with a yellow bull." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "apron_blacksmith" + pocket_storage_component_path = /datum/component/storage/concrete/pockets/small +/* +/obj/item/clothing/neck/mantle/legion/treasurer + name = "treasurers mantle" + desc = "The grey and black mantle with gold thread trimming shows the wearer is entrusted with matters of money and records. Hidden inner pockets can store money, keys and documents safely, and a discrete sheath for a knife for self defence is also attached." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "mantle_treasurer" + item_state = "mantle_treasurer" + pocket_storage_component_path = /datum/component/storage/concrete/pockets/treasurer +*/ + +// Mantle for the Orator, also works as a holster since it occupies the accessory slot +/obj/item/clothing/neck/mantle/legion + name = "legion mantle" + desc = "A bull flag adapted to be worn, a honor not given to every warrior. Comes with a holster for a handgun." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "mantle_legion" + item_state = "mantle_legion" + layer = NECK_LAYER + +/obj/item/clothing/neck/mantle/legion/ComponentInitialize() + . = ..() + var/datum/component/storage/STR = GetComponent(/datum/component/storage) + STR.max_items = 1 + STR.max_w_class = WEIGHT_CLASS_NORMAL + STR.can_hold = typecacheof(list( + /obj/item/gun/ballistic/automatic/pistol, + /obj/item/gun/ballistic/revolver, + /obj/item/gun/energy/laser/solar, + /obj/item/gun/energy/laser/pistol, + /obj/item/gun/energy/laser/plasma/pistol, + /obj/item/gun/energy/laser/plasma/glock, + /obj/item/gun/energy/laser/plasma/glock/extended, + /obj/item/gun/energy/laser/wattz, + /obj/item/gun/energy/laser/wattz/magneto, + )) + + +// ------------------- KITS & BAGS & HOLSTERS ----------------------------- + +// Ration package is a paper container for food/misc survival stuff +/obj/item/storage/survivalkit/legion_rations + name = "ration package" + desc = "Waxed paper package with food and some minor accessories a warrior might need." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "survival_legion" + +/obj/item/storage/survivalkit/legion_rations/PopulateContents() + new /obj/item/storage/box/matches(src) + new /obj/item/reagent_containers/food/snacks/meatsalted(src) + new /obj/item/reagent_containers/food/snacks/breadhard(src) + new /obj/item/reagent_containers/food/drinks/flask/survival(src) + +// proc to make the quiver look empty when empty +/obj/item/storage/survivalkit/legion_rations/update_icon_state() + . = ..() + if(!contents.len) + icon_state = "[icon_state]_empty" + else + icon_state = initial(icon_state) + +// Leather pouch for medicines +/obj/item/storage/survivalkit/medical/legion + name = "medicine bag" + desc = "Medical kit compliant with the laws of Caesar." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "survival_medical" + +/obj/item/storage/survivalkit/medical/legion/PopulateContents() + new /obj/item/stack/medical/gauze/improvised(src) + new /obj/item/stack/medical/suture(src) + new /obj/item/stack/medical/mesh/aloe(src) + new /obj/item/reagent_containers/pill/patch/healpoultice(src) + +// proc to make the quiver look empty when empty +/obj/item/storage/survivalkit/medical/legion/update_icon_state() + . = ..() + if(!contents.len) + icon_state = "[icon_state]_empty" + else + icon_state = initial(icon_state) + +/obj/item/storage/survivalkit/medical/legion/advanced + desc = "Medical kit compliant with the laws of Caesar, of higher than average quality." + +/obj/item/storage/survivalkit/medical/legion/adv/PopulateContents() + new /obj/item/stack/medical/gauze(src) + new /obj/item/stack/medical/suture(src) + new /obj/item/stack/medical/mesh(src) + new /obj/item/reagent_containers/pill/bitterdrink(src) + +// new satchel style that doesnt clutter up the mob so much +/obj/item/storage/backpack/marching_satchel + name = "marching satchel" + desc = "A sturdy leather bag attacked to the belt, for carrying necessary supplies." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "satchel_marching" + item_state = "satchel_marching" + +/obj/item/storage/backpack/marching_satchel/update_icon_state() + . = ..() + if(!contents.len) + icon_state = "[icon_state]_empty" + else + icon_state = initial(icon_state) + +// new style of holsters that show when occupied +/obj/item/storage/belt/holster/rugged // some sort of overlay system for the filled holsters would be better naturally but lack the time to figure it out. + name = "rugged holster" + desc = "A plain holster for a revolver." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "holster_rugged" + item_state = "holster_rugged" + +// proc to make the holster look empty when empty +/obj/item/storage/belt/holster/rugged/update_icon_state() + . = ..() + if(!contents.len) + icon_state = "[icon_state]_empty" + else + icon_state = initial(icon_state) + +// some prefilled holsters +/obj/item/storage/belt/holster/rugged/revolver_357 + icon_state = "holster_rugged" + +/obj/item/storage/belt/holster/rugged/revolver_357/PopulateContents() + new /obj/item/gun/ballistic/revolver/colt357(src) + +/obj/item/storage/belt/holster/rugged/revolver_45 + icon_state = "holster_rugged_45" + +/obj/item/storage/belt/holster/rugged/revolver_45/PopulateContents() + new /obj/item/gun/ballistic/revolver/revolver45(src) + +/obj/item/storage/belt/holster/rugged/revolver_hunting + icon_state = "holster_rugged_hunting" + +/obj/item/storage/belt/holster/rugged/revolver_hunting/PopulateContents() + new /obj/item/gun/ballistic/revolver/hunting(src) + +/* copy pasted to base files +/obj/item/storage/belt/utility/waster + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "belt_blacksmith" + item_state = "belt_blacksmith" + +/obj/item/storage/backpack/spearquiver + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' +*/ + +// proc to make the quiver look empty when empty +/obj/item/storage/backpack/spearquiver/update_icon_state() + . = ..() + if(!contents.len) + icon_state = "[icon_state]_empty" + else + icon_state = initial(icon_state) + + +// ------------------- CRAFTING ----------------------------- + +/datum/crafting_recipe/blacksmith/smithed_armor_legion + name = "Legion metal armor set" + result = /obj/item/clothing/suit/armor/heavy/metal/smithed/legion + reqs = list( + /obj/item/smithing/armor_piece = 2, + /obj/item/stack/sheet/leather = 2, + ) + time = 200 + tools = list(TOOL_FORGE) + category = CAT_CRAFTING + subcategory = CAT_FORGING + always_available = FALSE + + + +////////////////////////////////////////// +// // +// // +// ARMOR // +// // +// // +////////////////////////////////////////// + +// ------------------- SUIT ----------------------------- + +/obj/item/clothing/suit/armor/light/legion + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + + +/obj/item/clothing/suit/armor/light/legion/recruit + icon_state = "armor_recruit" + +/obj/item/clothing/suit/armor/light/legion/prime + icon_state = "armor_prime" + +/obj/item/clothing/suit/armor/light/legion/explorer + icon_state = "armor_explorer" + +/obj/item/clothing/suit/armor/medium/legion + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + +/obj/item/clothing/suit/armor/medium/legion/vet + icon_state = "armor_veteran" + +/obj/item/clothing/suit/armor/medium/legion/vexil + icon_state = "armor_vexillarius" + +/obj/item/clothing/suit/armor/medium/legion/orator + name = "legion orator armor" + desc = "Similar in style to the armor praetorians wear." + icon_state = "armor_praetorian" +/* Not ready yet +/obj/item/clothing/suit/armor/medium/legion/centurion + icon_state = "armor_centurion" + +/obj/item/clothing/suit/armor/medium/legion/rangercent + icon_state = "armor_rangerhunter" + +/obj/item/clothing/suit/armor/heavy/legion + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + +/obj/item/clothing/suit/armor/heavy/legion/palacent + icon_state = "armor_paladinslayer" + +/obj/item/clothing/suit/armor/heavy/legion/legate + icon_state = "armor_legate" +*/ +/obj/item/clothing/suit/armor/heavy/metal/smithed/legion + name = "smithed legion armor" + desc = "A set of plates with leather straps, protecting some vital areas. This one is combined with football shoulder pads and marked with the red X of Caesars Legion." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "armor_smithed" + item_state = "armor_smithed" + + +// ------------------- HELMETS ----------------------------- + +/obj/item/clothing/head/helmet/f13/legion + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + +/obj/item/clothing/head/f13/servant + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + icon_state = "hat_servant" + item_state = "hat_servant" + dynamic_hair_suffix = "+generic" + flags_inv = null + flags_cover = null + +/obj/item/clothing/head/f13/servant/auxilia + name = "auxilia headwear" + desc = "A soft red cap with a black band, used by Auxilia outside camp." + icon_state = "hat_auxilia" + item_state = "hat_auxilia" + +/obj/item/clothing/head/helmet/f13/legion/recruit + icon_state = "helmet_recruit" + +/obj/item/clothing/head/helmet/f13/legion/prime + icon_state = "helmet_prime" + +/obj/item/clothing/head/helmet/f13/legion/explorer + icon_state = "helmet_explorer" + +/obj/item/clothing/head/helmet/f13/legion/vet + icon_state = "helmet_veteran" + +/obj/item/clothing/head/helmet/f13/legion/vet/vexil + icon_state = "helmet_vexillarius" + + + +////////////////////////////////////////// +// // +// // +// LEGION FURNITURE // +// // +// // +////////////////////////////////////////// + +// --------------------- RADIO CONTROL --------------------------- -meant to be wall mounted so not solid, and pixel shifted until it looks good on the specific wall + +/obj/machinery/radioterminal/legion/wallmounted + name = "Legion radio control" + desc = "Cobbled together radio master set for disabling lost radios." + icon = 'modular_BD2/legio_invicta/icons/icons_64x32_legion.dmi' + icon_state = "radio_wall_legion" + + +// ------------------- WARDROBE ----------------------------- + +/obj/machinery/smartfridge/bottlerack/wardrobe + name = "large clothing rack" + desc = "holds clothing and various acessories." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "wardrobe" + layer = ABOVE_OBJ_LAYER + max_n_of_items = 30 + +/obj/machinery/smartfridge/bottlerack/wardrobe/accept_check(obj/item/O) + if(istype(O, /obj/item/clothing/shoes) || istype(O, /obj/item/clothing/head) || istype(O, /obj/item/clothing/mask) || istype(O, /obj/item/clothing/under) || istype(O, /obj/item/clothing/glasses) || istype(O, /obj/item/clothing/gloves) || istype(O, /obj/item/storage/belt) || istype(O, /obj/item/clothing/neck)) + return TRUE + return FALSE + +/obj/machinery/smartfridge/bottlerack/wardrobe/update_icon_state() + SSvis_overlays.remove_vis_overlay(src, managed_vis_overlays) + if(!stat) + if(visible_contents) + switch(contents.len) + if(0) + icon_state = "[initial(icon_state)]" + if(1 to 5) + icon_state = "[initial(icon_state)]-1" + if(6 to 10) + icon_state = "[initial(icon_state)]-2" + if(11 to 16) + icon_state = "[initial(icon_state)]-3" + if(17 to 22) + icon_state = "[initial(icon_state)]-4" + if(23 to 30) + icon_state = "[initial(icon_state)]-5" + else + icon_state = "[initial(icon_state)]" + else + icon_state = "[initial(icon_state)]" + +// Preloaded Legion wardrobe +/obj/machinery/smartfridge/bottlerack/wardrobe/legion + initial_contents = list( + /obj/item/clothing/under/f13/legskirt = 3, + /obj/item/clothing/mask/bandana/legion/dark = 2, + /obj/item/clothing/head/f13/servant/auxilia = 1, + /obj/item/clothing/head/f13/servant = 1, + /obj/item/clothing/gloves/legion = 2, + /obj/item/clothing/gloves/blacksmith_mittens = 1, + /obj/item/clothing/neck/apron/labor = 1, + /obj/item/clothing/shoes/f13/military/legion = 3, + /obj/item/clothing/shoes/sandals_leather = 1, + /obj/item/storage/belt/military/legion = 1, + /obj/item/clothing/glasses/f13/goggles_sandstorm = 1) + + +// -------------- ARMORDROBE ----------------- + +/obj/machinery/smartfridge/bottlerack/wardrobe/armor + name = "armor hanging rack" + desc = "a place to hang your armor and helmet." + icon_state = "armordrobe" + max_n_of_items = 20 + +/obj/machinery/smartfridge/bottlerack/wardrobe/armor/accept_check(obj/item/O) + if(istype(O, /obj/item/clothing/shoes) || istype(O, /obj/item/clothing/suit/armor) || istype(O, /obj/item/clothing/head/helmet)) + return TRUE + return FALSE + +/obj/machinery/smartfridge/bottlerack/wardrobe/armor/update_icon_state() + SSvis_overlays.remove_vis_overlay(src, managed_vis_overlays) + if(!stat) + if(visible_contents) + switch(contents.len) + if(0) + icon_state = "[initial(icon_state)]" + if(1 to 3) + icon_state = "[initial(icon_state)]-1" + if(4 to 6) + icon_state = "[initial(icon_state)]-2" + if(7 to 10) + icon_state = "[initial(icon_state)]-3" + if(11 to 14) + icon_state = "[initial(icon_state)]-4" + if(15 to 20) + icon_state = "[initial(icon_state)]-5" + else + icon_state = "[initial(icon_state)]" + else + icon_state = "[initial(icon_state)]" + +// Preloaded Legion armor rack +/obj/machinery/smartfridge/bottlerack/wardrobe/armor/legion + initial_contents = list( + /obj/item/clothing/suit/armor/light/legion/recruit = 2, + /obj/item/clothing/head/helmet/f13/legion/recruit = 2) + + +// -------------- MELEE RACK ----------------- + +/obj/machinery/smartfridge/bottlerack/rack_melee + name = "melee weapon rack" + desc = "holds most melee and throwing weapons." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "rack_melee" + layer = ABOVE_OBJ_LAYER + max_n_of_items = 15 + +/obj/machinery/smartfridge/bottlerack/rack_melee/accept_check(obj/item/O) + if(istype(O, /obj/item/melee) || istype(O, /obj/item/shishkebabpack) || istype(O, /obj/item/throwing_star) || istype(O, /obj/item/restraints/legcuffs/bola) || istype(O, /obj/item/shovel) || istype(O, /obj/item/twohanded)) + return TRUE + return FALSE + +/obj/machinery/smartfridge/bottlerack/rack_melee/update_icon_state() + SSvis_overlays.remove_vis_overlay(src, managed_vis_overlays) + if(!stat) + if(visible_contents) + switch(contents.len) + if(0) + icon_state = "[initial(icon_state)]" + if(1 to 2) + icon_state = "[initial(icon_state)]-1" + if(3 to 5) + icon_state = "[initial(icon_state)]-2" + if(6 to 8) + icon_state = "[initial(icon_state)]-3" + if(9 to 12) + icon_state = "[initial(icon_state)]-4" + if(13 to 15) + icon_state = "[initial(icon_state)]-5" + else + icon_state = "[initial(icon_state)]" + else + icon_state = "[initial(icon_state)]" + +// Preloaded Legion melee rack +/obj/machinery/smartfridge/bottlerack/rack_melee/legion + initial_contents = list( + /obj/item/melee/onehanded/machete = 1, + /obj/item/restraints/legcuffs/bola = 1) + + +// -------------- OFFERING RACK----------------- +// Trophy rack for dogtags +/obj/machinery/smartfridge/bottlerack/legion_offering + name = "offerings to Mars" + desc = "Hang the dogtags of slain enemies and fallen brothers here so Mars can keep track." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "rack_trophy" + max_n_of_items = 12 + +/obj/machinery/smartfridge/bottlerack/legion_offering/accept_check(obj/item/O) + if(istype(O, /obj/item/card/id/dogtag)) + return TRUE + return FALSE + +/obj/machinery/smartfridge/bottlerack/legion_offering/update_icon_state() + SSvis_overlays.remove_vis_overlay(src, managed_vis_overlays) + if(!stat) + if(visible_contents) + switch(contents.len) + if(0) + icon_state = "[initial(icon_state)]" + if(1) + icon_state = "[initial(icon_state)]-1" + if(2) + icon_state = "[initial(icon_state)]-2" + if(3) + icon_state = "[initial(icon_state)]-3" + if(4) + icon_state = "[initial(icon_state)]-4" + if(5) + icon_state = "[initial(icon_state)]-5" + if(6) + icon_state = "[initial(icon_state)]-6" + if(7) + icon_state = "[initial(icon_state)]-7" + if(8) + icon_state = "[initial(icon_state)]-8" + if(9) + icon_state = "[initial(icon_state)]-9" + if(10) + icon_state = "[initial(icon_state)]-10" + if(11) + icon_state = "[initial(icon_state)]-11" + if(12) + icon_state = "[initial(icon_state)]-12" + else + icon_state = "[initial(icon_state)]" + else + icon_state = "[initial(icon_state)]" + + +// ------------------- BUST OF CAESAR ----------------------------- + +/obj/item/statuebust/legion + name = "a bust of the great leader" + desc = "Caesar, a magnificent man, depicted in some tacky imitation of marble." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "bust_legion" + + +// -------------- BATHTUB ----------------- - only mood function, just for RP. Would be better if mood boost just fired if not weaing anything in uniform slot, or unable to buckle if dressed. + +/obj/structure/chair/comfy/bathtub + name = "bathtub" + desc = "A relaxing bath in hot water, or a endurance test in freezing water, depending on how lazy you are." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "bathtub" + max_integrity = 200 + item_chair = null + resistance_flags = NONE + flags_1 = NODECONSTRUCT_1 + +/obj/structure/chair/comfy/bathtub/GetArmrest() + return mutable_appearance('modular_BD2/legio_invicta/icons/icons_legion.dmi', "bathtub_bathing") + +/obj/structure/chair/comfy/bathtub/post_buckle_mob(mob/living/M) + . = ..() + SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "bathed", /datum/mood_event/bathed) + handle_layer() + playsound(src, 'modular_BD2/blacksmith/sound/water_splash2.ogg',50, 1) + +/obj/structure/chair/comfy/bathtub/post_unbuckle_mob() + . = ..() + handle_layer() + playsound(src, 'modular_BD2/blacksmith/sound/water_splash2.ogg',50, 1) + +/datum/mood_event/bathed + description = span_nicegreen("A warm bath felt nice.") + mood_change = 4 + timeout = 9000 + + +// ------------------- SIGNS ----------------------------- + +/obj/structure/sign/legion + name = "war room" + desc = "For planning the next great victory!" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "sign" + layer = SIGN_LAYER + +/obj/structure/sign/legion/radio + name = "radio room" + desc = "Spare radios and radio linking equipment are kept here" + +/obj/structure/sign/legion/medicus + name = "medicus tent" + desc = "Caesar approves the methods used here. Degenerates not welcome." + icon_state = "sign_medicus" + layer = BELOW_MOB_LAYER + +/obj/structure/sign/legion/recruit + name = "recruit barracks" + desc = "The decanus sleeps with his men and keeps track of them." // Theyre definitively straight + icon_state = "sign_ground" + +/obj/structure/sign/legion/smithy + name = "smithy" + desc = "Where weapons are forged and tools stored" + +/obj/structure/sign/legion/armory + name = "armory" + desc = "Great amounts of weapons and equipment are stored here" + +/obj/structure/sign/legion/prime + name = "prime barracks" + desc = "Primes and their decanus live here" + icon_state = "sign_ground" + +/obj/structure/sign/legion/veteran + name = "veteran barracks" + desc = "Experienced troops live here in comparable comfort." + +/obj/structure/sign/legion/mess + name = "mess pavillion" + desc = "Food and a place to talk to brothers in arms." + icon_state = "sign_ground" + +/obj/structure/sign/legion/gym + name = "the temple" + desc = "Build your body or use it as a speaking platform." + +/obj/structure/sign/legion/latrine + name = "latrine" + desc = "Has a certain odor." + icon_state = "sign_ground" + +/obj/structure/sign/legion/mines + name = "mines" + desc = "Put slave here" + icon_state = "sign_chain" + +/obj/structure/sign/legion/prison + name = "prison" + desc = "Lets the prisoner enjoy the local climate without interfering roofing." + icon_state = "sign_ground" + +/obj/structure/sign/legion/storeroom + name = "storeroom" + desc = "a place to store low-value goods and slaving equipment." + +/obj/structure/sign/legion/records + name = "office of records" + desc = "Where the Treasurer and other nerds store paperwork about stores and payrolls, and maybe the treasury." + +/obj/structure/sign/legion/stronghold + name = "stronghold" + desc = "Main building, fortified." + +/obj/structure/sign/legion/guardhouse + name = "guardhouse" + desc = "Sit in the gloom and wait for something to happen." + + +// -------------- ID LOCKED DOORS BY RANK ----------------- + +/obj/machinery/door/unpowered/securedoor/legion/warroom + name = "war room" + req_access_txt = "254" // ACCESS_LEGION_CPMMAND + +/obj/machinery/door/unpowered/securedoor/legion/centurion + name = "centurions quarters" + req_access_txt = "264" // ACCESS_LEGION4 + + + +// -------------- STATUE OF MARS ----------------- +// more fitting mars statue for the Legion players +/obj/structure/statue/mars + name = "statue of mars" + desc = "A monument to masculine virtue, made out of plaster and wood with a thin bronze outer layer." + icon = 'modular_BD2/legio_invicta/icons/64x64_icons.dmi' + icon_state = "statue_mars" + anchored = TRUE + max_integrity = 1000 + material_drop_type = /obj/item/stack/sheet/bronze + impressiveness = 30 + plane = GAME_PLANE + layer = ABOVE_ALL_MOB_LAYER + +/obj/structure/statue/mars/examine(mob/user) + . = ..() + SEND_SIGNAL(user, COMSIG_ADD_MOOD_EVENT, "inspired_art", /datum/mood_event/inspired_art) + . += "What a inspiring sight." + +/datum/mood_event/inspired_art + description = span_nicegreen("I have seen something inspiring.") + mood_change = 1 + timeout = 9000 + + +// -------------- DECALS ----------------- + +/obj/structure/decoration/legion + name = "legion bull flag of high quality" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "decal_bull" + +/obj/structure/decoration/legion/spears + name = "decorative weapons" + icon_state = "decal_wallweapons" + +/obj/structure/decoration/legion/chains + name = "chains" + icon_state = "decal_chain1" + +/obj/structure/decoration/legion/chains2 + name = "chains" + icon_state = "decal_chain2" + +/obj/structure/decoration/legion/tentpole + name = "tentpole" + icon_state = "decal_tentpole" + +/obj/structure/decoration/legion/tentpole/rope + icon_state = "decal_tentpole_rope" + + +// -------------- HANDRAIL ----------------- + +/obj/structure/railing/handrail/legion + name = "handrail" + desc = "Wooden posts with connecting chain." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "handrail_legion" + +/obj/structure/railing/handrail/legion/underlayer + layer = BELOW_MOB_LAYER + +/obj/structure/railing/handrail/legion/overlayer + plane = GAME_PLANE + +/obj/structure/railing/handrail/legion/end + icon_state = "handrail_legion_end" + density = FALSE + +/obj/structure/railing/handrail/legion/entrance + icon_state = "handrail_legion_entrance" + layer = BELOW_MOB_LAYER // comment for underlayer effect + +/obj/structure/railing/handrail/legion/entrance/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags) + user.visible_message("[user] begins moving the chain of the [src].") + if(!do_after(user, 20, TRUE, src)) + return + else + playsound(get_turf(src), 'modular_BD2/general/sound/doorchainsoft_open.ogg', 60, TRUE) + if(density) + icon_state = "handrail_legion_entrance_open" + src.density = 0 + else + icon_state = "handrail_legion_entrance_close" + src.density = 1 + return ..() + + +////////////////////////////////////////// +// // +// // +// GENERIC MAPPING STUFF // +// // +// // +////////////////////////////////////////// + +/obj/structure/fireplace/preloaded + fuel_added = 1000 + +/* Added to base code +/obj/structure/campfire/stove + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + +added to end of campfire/attackby + else if(fired && istype(P, /obj/item/stack/medical/gauze/improvised)) + if(!ishuman(user)) + return + if(istype(P, /obj/item/stack/medical/gauze/improvised)) + var/obj/item/stack/medical/gauze/improvised/F = P + to_chat(user, "You start baking the [F.name].") + if(do_after(user, 30, target = src)) + F.microwave_act() +*/ + +// Finally time to add my old dirt alternative, ploughed dirt +/obj/machinery/hydroponics/soil/plowed //Just looks different + icon_state = "soil_plowexperiment" + +/obj/effect/overlay/darkwoodfancyedge + name = "wood edge" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "darkwood_fancyedge" + layer = WALL_PLANE + +// Matrix for slaves/prison +/turf/closed/indestructible/f13/matrix/slave //Less obtrusive matrix for prison + name = "mattress of despair" + desc = "This is incredibly filthy. Sleeping here means your spirit is broken, and you submit to be taken far away to a bleak future as a prisoner. Count as dead for respawning rules." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "despair" + + +// New roof for tent +/turf/open/floor/plating/f13/outside/roof/tent_leather + name = "leather tent roof" + icon = 'icons/fallout/turfs/walls/tents.dmi' + icon_state = "leather_roof" + +// shading under the pavillon +/obj/effect/turf_decal/shadow + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "shadow" + +// Floorshading testing +/obj/effect/turf_decal/shadow/floor + icon_state = "shadow_floor" + plane = GAME_PLANE + +// Wallshading testing +/obj/effect/shadow_wall + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "shadow_wall" + plane = GAME_PLANE + pixel_y = 32 + +// stairs platform to make it prettier +/turf/open/floor/f13/stairs_platform + name = "stairs" + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + icon_state = "stairs_platform" + color = "#A47449" + + + +// -------------- DOUBLE BARRED DOORS ----------------- + +/obj/structure/simple_door/metal/barred/left + icon = 'modular_BD2/general/icons/door_barred.dmi' + icon_state = "barred_left" + door_type = "barred_left" + open_sound = 'modular_BD2/general/sound/doorchainsoft_open.ogg' + close_sound = 'modular_BD2/general/sound/doorchainsoft_close.ogg' + +/obj/structure/simple_door/metal/barred/right + icon = 'modular_BD2/general/icons/door_barred.dmi' + icon_state = "barred_right" + door_type = "barred_right" + open_sound = 'modular_BD2/general/sound/doorchainsoft_open.ogg' + close_sound = 'modular_BD2/general/sound/doorchainsoft_close.ogg' + + +// -------------- PRE-STONE RINGED BONFIRE ----------------- + +/obj/structure/bonfire/safe + stones = TRUE // maybe this needs porting from Atom + density = TRUE + +/obj/structure/bonfire/safe/Initialize() + . = ..() + add_overlay("bonfire_stones") + + +/obj/structure/closet/crate/footlocker + dense_when_open = FALSE + +/obj/structure/closet/crate/footchest + dense_when_open = FALSE + + +// -------------- TURF STUFF ----------------- + +// // -------------- OUTSIDE DEAD DIRT ----------------- the shade used in the map, nature free, stamped dirt flooring +/turf/open/indestructible/ground/inside/dirt/stamped + icon = 'icons/fallout/turfs/dirt.dmi' + slowdown = 0.1 + flags_1 = null + +/turf/open/indestructible/ground/inside/dirt/stamped/outside // criminal solution but whatever. To have dead dirt outside. + sunlight_state = SUNLIGHT_SOURCE + +/turf/open/indestructible/ground/inside/dirt/stamped/outside/sand // ugly solution but whatever. To have undiggable sand for flooring in a pavillon + name = "packed sand" + icon = 'modular_BD2/general/icons/tileset_sonora.dmi' + icon_state = "desertsmooth" + +/obj/structure/flora/tree/wasteland/dark + color = "#5c5a57" + plane = GAME_PLANE + layer = ABOVE_ALL_MOB_LAYER + +/obj/structure/flora/tree/wasteland/dark/Initialize() + . = ..() + AddComponent(/datum/component/largetransparency, y_offset = 1) + +/obj/structure/flora/tree/african_acacia_dead + plane = GAME_PLANE + +/obj/structure/flora/tree/african_acacia_dead/Initialize() + . = ..() + AddComponent(/datum/component/largetransparency, y_offset = 1) + +// -------------- GRAVEL TILESET STUFF ----------------- + +/turf/open/indestructible/ground/outside/gravel + name = "gravel" + icon_state = "gravel" + icon = 'modular_BD2/general/icons/tileset_gravel.dmi' + +/turf/open/indestructible/ground/outside/gravel/edge + icon_state = "graveledge" + +/turf/open/indestructible/ground/outside/gravel/corner + icon_state = "gravelcorner" + +/obj/effect/turf_decal/gravel_edge + icon = 'modular_BD2/general/icons/tileset_gravel.dmi' + icon_state = "gravel_edge" + +/obj/effect/turf_decal/gravel_edge/corner // outer corner + icon_state = "gravel_corner" + +/obj/effect/turf_decal/gravel_edge/diagonal // inner corner alt + icon_state = "gravel_diagonal" + +// -------------- SONORA TILESET STUFF ----------------- + +/obj/effect/overlay/desert/sonora/edge + icon = 'modular_BD2/general/icons/tileset_sonora.dmi' + icon_state = "desertedge" + +/obj/effect/overlay/desert/sonora/edge/corner + icon_state = "desertcorner" + +/obj/effect/overlay/desert/sonora/edge/fade + icon_state = "desertfade" + +/turf/open/indestructible/ground/outside/desert/sonora + icon = 'modular_BD2/general/icons/tileset_sonora.dmi' + icon_state = "desertsmooth" + slowdown = 0.3 + footstep = FOOTSTEP_LOOSE_SAND + barefootstep = FOOTSTEP_LOOSE_SAND + clawfootstep = FOOTSTEP_LOOSE_SAND + +/turf/open/indestructible/ground/outside/desert/sonora/Initialize() + . = ..() + icon_state = "desertsmooth[rand(1,8)]" + +/turf/open/indestructible/ground/outside/desert/sonora/coarse + icon_state = "desertcoarse1" + slowdown = 0.4 + +/turf/open/indestructible/ground/outside/desert/sonora/coarse/Initialize() + . = ..() + icon_state = "desertcoarse[rand(1,16)]" + +/turf/open/indestructible/ground/outside/desert/sonora/rough + icon_state = "desertcracked1" + slowdown = 0.6 + + +/turf/open/floor/f13/wood/outside // outside platform with sunlight + sunlight_state = SUNLIGHT_SOURCE + +/obj/item/bedsheet/blanket + name = "blanket" + desc = "A undyed rough blanket." + icon_state = "blanket1" + +/obj/item/bedsheet/blanket2 + icon_state = "blanket2" + +/obj/item/storage/belt/military/legion + name = "legion marching belt" + desc = "A belt capable of holding various supplies a warrior might need. Comes with a red sash." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "belt_legion" + item_state = "belt_legion" + + +/obj/item/clothing/shoes/sandals_leather + name = "leather sandals" + desc = "Sandals with buckled leather straps on it. Good workmanship." + icon = 'modular_BD2/legio_invicta/icons/icons_legion.dmi' + mob_overlay_icon = 'modular_BD2/legio_invicta/icons/onmob_legion.dmi' + righthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi' + lefthand_file = 'modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi' + icon_state = "shoes_sandals" + item_state = "shoes_sandals" +// icon = 'icons/fallout/clothing/shoes.dmi' +// mob_overlay_icon = 'icons/fallout/onmob/clothes/shoe.dmi' +// icon_state = "legion_sandals" +// item_state = "legion_sandals" + strip_delay = 100 + equip_delay_other = 100 + permeability_coefficient = 0.9 + can_be_tied = FALSE diff --git a/modular_BD2/legio_invicta/icons/64x64_icons.dmi b/modular_BD2/legio_invicta/icons/64x64_icons.dmi new file mode 100644 index 00000000000..14714947cfc Binary files /dev/null and b/modular_BD2/legio_invicta/icons/64x64_icons.dmi differ diff --git a/modular_BD2/legio_invicta/icons/64x64_lefthand.dmi b/modular_BD2/legio_invicta/icons/64x64_lefthand.dmi new file mode 100644 index 00000000000..62683e11d3d Binary files /dev/null and b/modular_BD2/legio_invicta/icons/64x64_lefthand.dmi differ diff --git a/modular_BD2/legio_invicta/icons/64x64_righthand.dmi b/modular_BD2/legio_invicta/icons/64x64_righthand.dmi new file mode 100644 index 00000000000..a052b382ed4 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/64x64_righthand.dmi differ diff --git a/modular_BD2/legio_invicta/icons/backslot.dmi b/modular_BD2/legio_invicta/icons/backslot.dmi new file mode 100644 index 00000000000..fad5ec1b0b0 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/backslot.dmi differ diff --git a/modular_BD2/legio_invicta/icons/beltslot.dmi b/modular_BD2/legio_invicta/icons/beltslot.dmi new file mode 100644 index 00000000000..3036ffbe17d Binary files /dev/null and b/modular_BD2/legio_invicta/icons/beltslot.dmi differ diff --git a/modular_BD2/legio_invicta/icons/icons_64x32_legion.dmi b/modular_BD2/legio_invicta/icons/icons_64x32_legion.dmi new file mode 100644 index 00000000000..c0a8828d484 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/icons_64x32_legion.dmi differ diff --git a/modular_BD2/legio_invicta/icons/icons_legion.dmi b/modular_BD2/legio_invicta/icons/icons_legion.dmi new file mode 100644 index 00000000000..59f66301062 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/icons_legion.dmi differ diff --git a/modular_BD2/legio_invicta/icons/onmob_legion.dmi b/modular_BD2/legio_invicta/icons/onmob_legion.dmi new file mode 100644 index 00000000000..b162f0ff981 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/onmob_legion.dmi differ diff --git a/modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi b/modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi new file mode 100644 index 00000000000..b107b56dc82 Binary files /dev/null and b/modular_BD2/legio_invicta/icons/onmob_legion_lefthand.dmi differ diff --git a/modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi b/modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi new file mode 100644 index 00000000000..7c15e6b7dec Binary files /dev/null and b/modular_BD2/legio_invicta/icons/onmob_legion_righthand.dmi differ diff --git a/modular_big-iron/code/game/machinery/radio_station.dm b/modular_big-iron/code/game/machinery/radio_station.dm new file mode 100644 index 00000000000..96f31222836 --- /dev/null +++ b/modular_big-iron/code/game/machinery/radio_station.dm @@ -0,0 +1,156 @@ +//****************************************** +//WHEN ADDING NEW MUSIC, ADD THE MUSIC'S NAME TO _globalvars/lists/objects.dm global_music_list and then scroll down to the switch(music_name) part +//Make sure you put it in alphabetical order and also update the switch(music_file) part at the disk burner's attack_hand proc with whatever music you added +//****************************************** + +/obj/machinery/radio_station + name = "radio station" + desc = "A specially equipped radio station to broadcast music to every radio in a the waste. Comes pre-coded with over 30 songs!" + icon = 'icons/fallout/machines/radio.dmi' + icon_state = "gannets_machine21" + max_integrity = 150 + anchored = TRUE + density = TRUE + use_power = IDLE_POWER_USE + idle_power_usage = 2 + armor = list("melee" = 20, "bullet" = 20, "laser" = 20, "energy" = 20, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 20) + circuit = /obj/item/circuitboard/machine/radio_station + light_color = LIGHT_COLOR_GREEN + var/datum/track/selectedtrack = "None" //File path to the music's audio file + var/selectedtrackname = "none" +// var/datum/track = null //This is the name of the song, not the file name. This is what shows up at the top of the music selection. + var/list/music_list //List of music that can be played. Only the most based songs may be added. + var/cooldowntime + var/obj/item/record_disk/R //The record disk that's currently playing music + var/can_eject_disk = 1 + var/ready_to_delete = 0 //For Destroy() + var/brightness_on = 1 + var/volume = 35 //the volume that music plays at + +/obj/machinery/radio_station/Initialize() + . = ..() + music_list = SSjukeboxes.songs + update_icon() + +/obj/machinery/radio_station/attack_hand(mob/living/user) + ..() + var/machinesound = 'sound/machines/doorclick.ogg' + playsound(src, machinesound, 100, 1) + if(R) + if(can_eject_disk) + update_icon() + playsound(src, 'sound/effects/plastic_click.ogg', 100, 0) + R.forceMove(get_turf(src)) + R = null + stopRadioMusic() + return + else + to_chat(user, "You must wait to eject the record disk!") + return + + if(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF) + update_icon() + return + if(cooldowntime > world.time) + to_chat(user, "The broadcasting antenna needs time to recharge! It will be ready in [DisplayTimeText(cooldowntime - world.time)].") + return + var/list/songnames = list() + if(music_list.len) + for(var/i = 1, i <= music_list.len, i++) + var/datum/track/CT = music_list[i] + var/ctsn = "[CT.song_name]" + songnames += ctsn + var/datum/track/cooming = input(user, "Last played music: [selectedtrackname]", "Available Music") as null|anything in songnames + if(!user.Adjacent(src)) + to_chat(user, "You are too far away!") + return + if(!cooming) + return + if(cooldowntime > world.time) + to_chat(user, "The broadcasting antenna needs time to recharge! It will be ready in [DisplayTimeText(cooldowntime - world.time)].") + return + for(var/datum/track/S in music_list) + if(S.song_name == cooming)//agghggagaghaghah + selectedtrack = S.song_path + selectedtrackname = S.song_name + continue + playsound(src, machinesound, 100, 1) + playMusicToRadios(user) + +/obj/machinery/radio_station/attackby(obj/item/I, mob/living/user) + if(istype(I, /obj/item/record_disk)) + if(cooldowntime > world.time) + to_chat(user, "The broadcasting antenna needs time to recharge! It will be ready in [DisplayTimeText(cooldowntime - world.time)].") + return + if(!R) + R = I + I.forceMove(src) + playsound(src, 'sound/effects/plastic_click.ogg', 100, 0) + selectedtrack = R.R.song_path + if(R.R.song_name != "CUSTOM") + selectedtrack = R.R.song_path + selectedtrackname = R.R.song_name + else + selectedtrack = R.R.song_path + selectedtrackname = "A custom song!f" + playMusicToRadios(user) + return + else + to_chat(user, "There is already a record disk in the [src]!") + return + ..() + +/obj/machinery/radio_station/proc/playMusicToRadios(mob/living/user) + if(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF) + update_icon() + return + if(cooldowntime > world.time) + to_chat(user, "The broadcasting antenna needs time to recharge! It will be ready in [DisplayTimeText(cooldowntime - world.time)].") + return + + var/store_resistance_flags = resistance_flags + resistance_flags = INDESTRUCTIBLE //Need to do this so that it can't be destroyed before the music starts playing. + + can_eject_disk = 0 + cooldowntime = world.time + 500 + for(var/obj/item/radio/R in GLOB.radio_list) //Calls the playmusic() proc for every radio in radio_list (everyone) + R.playmusic(selectedtrack, selectedtrackname, volume) + for(var/obj/item/pda/R in GLOB.radio_list) //Calls the playmusic() proc for every radio in radio_list (everyone) + R.playmusic(selectedtrack, selectedtrackname, volume) + + src.audible_message("[src] beeps, 'Now broadcasting: [selectedtrackname]' ") + + resistance_flags = store_resistance_flags + + can_eject_disk = 1 + if(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF) //Need to check again in case the radio station is destroyed while this proc is in progress + update_icon() + stopRadioMusic() + return + + +/obj/machinery/radio_station/proc/stopRadioMusic() + var/i + for(i = 1; i <= GLOB.radio_list.len; i++) //This time it will stop the music for every radio listening to this radio station. + if(!istype(GLOB.radio_list[i], /obj/item/pda)) + GLOB.radio_list[i].stopmusic(GLOB.radio_list[i].radio_holder, 3) + +/obj/machinery/radio_station/Destroy() + stopRadioMusic() + ..() + +/obj/machinery/radio_station/update_icon() + ..() + if(!(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF)) + luminosity = 1 + set_light(brightness_on) + return + luminosity = 0 + set_light(0) + +/obj/machinery/radio_station/power_change() + . = ..() + if(stat & (NOPOWER|BROKEN) || . & EMP_PROTECT_SELF) + set_light(0) + else + set_light(brightness_on) diff --git a/modular_big-iron/code/game/objects/circuitboards/radio_station.dm b/modular_big-iron/code/game/objects/circuitboards/radio_station.dm new file mode 100644 index 00000000000..76af946c429 --- /dev/null +++ b/modular_big-iron/code/game/objects/circuitboards/radio_station.dm @@ -0,0 +1,6 @@ +/obj/item/circuitboard/machine/radio_station + name = "circuit board (radio station)" + build_path = /obj/machinery/radio_station + req_components = list( + /obj/item/stock_parts/cell = 1, + /obj/item/stock_parts/capacitor = 2) diff --git a/sound/effects/disk_tray.ogg b/sound/effects/disk_tray.ogg new file mode 100644 index 00000000000..ecbcba7195b Binary files /dev/null and b/sound/effects/disk_tray.ogg differ diff --git a/sound/effects/plastic_click.ogg b/sound/effects/plastic_click.ogg new file mode 100644 index 00000000000..cd30e3a549b Binary files /dev/null and b/sound/effects/plastic_click.ogg differ diff --git a/sound/effects/record_shatter.ogg b/sound/effects/record_shatter.ogg new file mode 100644 index 00000000000..1b122c1bf95 Binary files /dev/null and b/sound/effects/record_shatter.ogg differ diff --git a/tgui/packages/tgui/interfaces/Jukebox.js b/tgui/packages/tgui/interfaces/Jukebox.js index b23e55469b1..bc19343683d 100644 --- a/tgui/packages/tgui/interfaces/Jukebox.js +++ b/tgui/packages/tgui/interfaces/Jukebox.js @@ -11,12 +11,19 @@ export const Jukebox = (props, context) => { track_selected, track_length, track_beat, + disk_selected, + disk_selected_length, + disk_selected_beat, volume, } = data; const songs = flow([ sortBy( song => song.name), ])(data.songs || []); + const disks = flow([ + sortBy( + disk => disk.name), + ])(data.disks || []); return ( {

    act('toggle')} /> + <> +
    diff --git a/tgui/packages/tgui/interfaces/Radio.js b/tgui/packages/tgui/interfaces/Radio.js index b2b8e619826..eae69384e1d 100644 --- a/tgui/packages/tgui/interfaces/Radio.js +++ b/tgui/packages/tgui/interfaces/Radio.js @@ -18,6 +18,7 @@ export const Radio = (props, context) => { useCommand, subspace, subspaceSwitchable, + music_toggle, } = data; const tunedChannel = RADIO_CHANNELS .find(channel => channel.freq === frequency); @@ -80,6 +81,12 @@ export const Radio = (props, context) => { icon={broadcasting ? 'microphone' : 'microphone-slash'} selected={broadcasting} onClick={() => act('broadcast')} /> +