Merge branch 'master' into upstream-merge-8222

This commit is contained in:
Heroman
2022-02-19 18:41:29 +10:00
1251 changed files with 947582 additions and 38891 deletions
+1 -2
View File
@@ -10,8 +10,7 @@
..()
var/turf/T = get_turf(src)
var/obj/structure/closet/C = locate() in T
var/obj/item/stack/M = new type_to_spawn(C || T)
M.amount = M.max_amount //some stuff spawns with 60, we're still calling it fifty
var/obj/item/stack/M = new type_to_spawn(C || T, -1)
M.update_icon() // Some stacks have different sprites depending on how full they are.
return INITIALIZE_HINT_QDEL //Bye!
@@ -92,6 +92,10 @@
name = "stack of alien wood"
type_to_spawn = /obj/item/stack/material/wood/sif
/obj/fiftyspawner/hardwood
name = "stack of hardwood"
type_to_spawn = /obj/item/stack/material/wood/hard
/obj/fiftyspawner/log
name = "stack of logs"
type_to_spawn = /obj/item/stack/material/log
@@ -100,6 +104,10 @@
name = "stack of alien logs"
type_to_spawn = /obj/item/stack/material/log/sif
/obj/fiftyspawner/log/hard
name = "stack of hardwood logs"
type_to_spawn = /obj/item/stack/material/log/hard
/obj/fiftyspawner/cloth
name = "stack of cloth"
type_to_spawn = /obj/item/stack/material/cloth
@@ -312,9 +312,9 @@ var/list/name_to_material
place_sheet(target)
// Debris product. Used ALL THE TIME.
/datum/material/proc/place_sheet(var/turf/target)
/datum/material/proc/place_sheet(var/turf/target, amount)
if(stack_type)
return new stack_type(target)
return new stack_type(target, amount)
// As above.
/datum/material/proc/place_shard(var/turf/target)
@@ -39,44 +39,44 @@
new /datum/stack_recipe("red sofa right", /obj/structure/bed/chair/sofa/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("red sofa corner", /obj/structure/bed/chair/sofa/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa middle", /obj/structure/bed/chair/sofa/brown, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa left", /obj/structure/bed/chair/sofa/brown/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa right", /obj/structure/bed/chair/sofa/brown/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa corner", /obj/structure/bed/chair/sofa/brown/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa left", /obj/structure/bed/chair/sofa/left/brown, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa right", /obj/structure/bed/chair/sofa/right/brown, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("brown sofa corner", /obj/structure/bed/chair/sofa/corner/brown, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa middle", /obj/structure/bed/chair/sofa/teal, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa left", /obj/structure/bed/chair/sofa/teal/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa right", /obj/structure/bed/chair/sofa/teal/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa corner", /obj/structure/bed/chair/sofa/teal/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa left", /obj/structure/bed/chair/sofa/left/teal, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa right", /obj/structure/bed/chair/sofa/right/teal, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("teal sofa corner", /obj/structure/bed/chair/sofa/corner/teal, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa middle", /obj/structure/bed/chair/sofa/black, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa left", /obj/structure/bed/chair/sofa/black/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa right", /obj/structure/bed/chair/sofa/black/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa corner", /obj/structure/bed/chair/sofa/black/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa left", /obj/structure/bed/chair/sofa/left/black, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa right", /obj/structure/bed/chair/sofa/right/black, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("black sofa corner", /obj/structure/bed/chair/sofa/corner/black, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa middle", /obj/structure/bed/chair/sofa/green, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa left", /obj/structure/bed/chair/sofa/green/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa right", /obj/structure/bed/chair/sofa/green/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa corner", /obj/structure/bed/chair/sofa/green/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa left", /obj/structure/bed/chair/sofa/left/green, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa right", /obj/structure/bed/chair/sofa/right/green, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("green sofa corner", /obj/structure/bed/chair/sofa/corner/green, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa middle", /obj/structure/bed/chair/sofa/purp, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa left", /obj/structure/bed/chair/sofa/purp/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa right", /obj/structure/bed/chair/sofa/purp/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa corner", /obj/structure/bed/chair/sofa/purp/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa left", /obj/structure/bed/chair/sofa/left/purp, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa right", /obj/structure/bed/chair/sofa/right/purp, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("purple sofa corner", /obj/structure/bed/chair/sofa/corner/purp, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa middle", /obj/structure/bed/chair/sofa/blue, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa left", /obj/structure/bed/chair/sofa/blue/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa right", /obj/structure/bed/chair/sofa/blue/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa corner", /obj/structure/bed/chair/sofa/blue/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa left", /obj/structure/bed/chair/sofa/left/blue, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa right", /obj/structure/bed/chair/sofa/right/blue, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("blue sofa corner", /obj/structure/bed/chair/sofa/corner/blue, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa middle", /obj/structure/bed/chair/sofa/beige, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa left", /obj/structure/bed/chair/sofa/beige/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa right", /obj/structure/bed/chair/sofa/beige/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa corner", /obj/structure/bed/chair/sofa/beige/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa left", /obj/structure/bed/chair/sofa/left/beige, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa right", /obj/structure/bed/chair/sofa/right/beige, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("beige sofa corner", /obj/structure/bed/chair/sofa/corner/beige, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa middle", /obj/structure/bed/chair/sofa/lime, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa left", /obj/structure/bed/chair/sofa/lime/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa right", /obj/structure/bed/chair/sofa/lime/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa corner", /obj/structure/bed/chair/sofa/lime/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa left", /obj/structure/bed/chair/sofa/left/lime, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa right", /obj/structure/bed/chair/sofa/right/lime, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("lime sofa corner", /obj/structure/bed/chair/sofa/corner/lime, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa middle", /obj/structure/bed/chair/sofa/yellow, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa left", /obj/structure/bed/chair/sofa/yellow/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa right", /obj/structure/bed/chair/sofa/yellow/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa corner", /obj/structure/bed/chair/sofa/yellow/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa left", /obj/structure/bed/chair/sofa/left/yellow, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa right", /obj/structure/bed/chair/sofa/right/yellow, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("yellow sofa corner", /obj/structure/bed/chair/sofa/corner/yellow, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa middle", /obj/structure/bed/chair/sofa/orange, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa left", /obj/structure/bed/chair/sofa/orange/left, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa right", /obj/structure/bed/chair/sofa/orange/right, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa corner", /obj/structure/bed/chair/sofa/orange/corner, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa left", /obj/structure/bed/chair/sofa/left/orange, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa right", /obj/structure/bed/chair/sofa/right/orange, 1, one_per_turf = 1, on_floor = 1), \
new /datum/stack_recipe("orange sofa corner", /obj/structure/bed/chair/sofa/corner/orange, 1, one_per_turf = 1, on_floor = 1), \
)),
)
@@ -35,11 +35,11 @@
/datum/material/resin/generate_recipes()
recipes = list(
new /datum/stack_recipe("[display_name] door", /obj/structure/simple_door/resin, 10, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] barricade", /obj/effect/alien/resin/wall, 5, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] barricade", /obj/structure/alien/wall, 5, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] nest", /obj/structure/bed/nest, 2, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] wall girders", /obj/structure/girder/resin, 2, time = 5 SECONDS, one_per_turf = 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("crude [display_name] bandage", /obj/item/stack/medical/crude_pack, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] net", /obj/item/weapon/material/fishing_net, 10, time = 5 SECONDS, supplied_material = "[name]", pass_stack_color = TRUE),
new /datum/stack_recipe("[display_name] membrane", /obj/effect/alien/resin/membrane, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] membrane", /obj/structure/alien/membrane, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"),
new /datum/stack_recipe("[display_name] node", /obj/effect/alien/weeds/node, 1, time = 4 SECONDS, recycle_material = "[name]")
)
@@ -67,6 +67,29 @@
recipes -= r_recipe
continue
/datum/material/wood/hardwood
name = MAT_HARDWOOD
stack_type = /obj/item/stack/material/wood/hard
icon_colour = "#42291a"
icon_base = "stone"
icon_reinf = "reinf_stone"
integrity = 65 //a bit stronger than regular wood
hardness = 20
weight = 20 //likewise, heavier
/datum/material/wood/hardwood/generate_recipes()
..()
for(var/datum/stack_recipe/r_recipe in recipes)
if(r_recipe.title == "wood floor tile")
recipes -= r_recipe
continue
if(r_recipe.title == "wooden chair")
recipes -= r_recipe
continue
if(r_recipe.title == "wooden standup figure")
recipes -= r_recipe
continue
/datum/material/wood/log
name = MAT_LOG
display_name = "wood" // will lead to "wood log"
@@ -90,6 +113,11 @@
stack_origin_tech = list(TECH_MATERIAL = 2, TECH_BIO = 2)
stack_type = /obj/item/stack/material/log/sif
/datum/material/wood/log/hard
name = MAT_HARDLOG
icon_colour = "#6f432a"
stack_type = /obj/item/stack/material/log/hard
//VOREStation Addition Start
/datum/material/wood/stick
name = "wooden stick"
@@ -24,14 +24,14 @@
//Try locating an exisitng stack on the tile and add to there if possible
var/obj/item/stack/hairlesshide/H = null
for(var/obj/item/stack/hairlesshide/HS in user.loc) // Could be scraping something inside a locker, hence the .loc, not get_turf
if(HS.amount < HS.max_amount)
if(HS.get_amount() < HS.max_amount)
H = HS
break
// Either we found a valid stack, in which case increment amount,
// Or we need to make a new stack
if(istype(H))
H.amount++
H.add(1)
else
H = new /obj/item/stack/hairlesshide(user.loc)
@@ -21,14 +21,14 @@
for(var/i in 1 to wateramount)
var/obj/item/stack/wetleather/H = null
for(var/obj/item/stack/wetleather/HS in get_turf(src)) // Doesn't have a user, can't just use their loc
if(HS.amount < HS.max_amount)
if(HS.get_amount() < HS.max_amount)
H = HS
break
// Either we found a valid stack, in which case increment amount,
// Or we need to make a new stack
if(istype(H))
H.amount++
H.add(1)
else
H = new /obj/item/stack/wetleather(get_turf(src))
@@ -38,9 +38,8 @@
dry()
/obj/item/stack/wetleather/proc/dry()
var/obj/item/stack/material/leather/L = new(src.loc)
L.amount = amount
use(amount)
var/obj/item/stack/material/leather/L = new(src.loc, get_amount())
use(get_amount())
return L
/obj/item/stack/wetleather/transfer_to(obj/item/stack/S, var/tamount=null, var/type_verified)
@@ -41,7 +41,7 @@
drying = A
else // Drying something, add if possible
var/obj/item/stack/wetleather/W = A
W.transfer_to(drying, W.amount, TRUE)
W.transfer_to(drying, W.get_amount(), TRUE)
update_icon()
return TRUE
return ..()
@@ -50,9 +50,8 @@
if(drying)
var/obj/item/stack/S = drying
if(!drying.wetness) // If it's dry, make a stack of dry leather and prepare to put that in their hands
var/obj/item/stack/material/leather/L = new(src)
L.amount = drying.amount
drying.use(drying.amount)
var/obj/item/stack/material/leather/L = new(src, drying.get_amount())
drying.set_amount(0)
S = L
if(ishuman(user))
+14 -3
View File
@@ -13,6 +13,12 @@
color = "#0099cc"
default_type = MAT_SIFWOOD
/obj/item/stack/material/wood/hard
name = "hardwood plank"
color = "#42291a"
default_type = MAT_HARDWOOD
description_info = "Rich, lustrous hardwood, imported from offworld at moderate expense. Mostly used for luxurious furniture, and not very good for weapons or other structures."
/obj/item/stack/material/log
name = "log"
icon_state = "sheet-log"
@@ -32,6 +38,12 @@
color = "#0099cc"
plank_type = /obj/item/stack/material/wood/sif
/obj/item/stack/material/log/hard
name = "hardwood log"
default_type = MAT_HARDLOG
color = "#6f432a"
plank_type = /obj/item/stack/material/wood/hard
/obj/item/stack/material/log/attackby(var/obj/item/W, var/mob/user)
if(!istype(W) || W.force <= 0)
return ..()
@@ -47,10 +59,9 @@
existing_wood = M
break
var/obj/item/stack/material/wood/new_wood = new plank_type(user.loc)
new_wood.amount = 2
var/obj/item/stack/material/wood/new_wood = new plank_type(user.loc, 2)
if(existing_wood && new_wood.transfer_to(existing_wood))
to_chat(user, "<span class='notice'>You add the newly-formed wood to the stack. It now contains [existing_wood.amount] planks.</span>")
to_chat(user, "<span class='notice'>You add the newly-formed wood to the stack. It now contains [existing_wood.get_amount()] planks.</span>")
else
return ..()