From 9d2399ce9f0428df5123eb33328761050914853c Mon Sep 17 00:00:00 2001
From: Ghom <42542238+Ghommie@users.noreply.github.com>
Date: Fri, 15 May 2020 16:15:15 +0200
Subject: [PATCH] Removing unused files and fixing some stuff. (#12250)
---
code/game/objects/items/storage/toolbox.dm | 18 ++----
code/modules/events/pirates.dm | 11 ++--
.../food_and_drinks/food/snacks_pastry.dm | 2 +-
code/modules/mob/living/carbon/give.dm | 58 -------------------
.../living/simple_animal/hostile/creature.dm | 18 ------
.../autolathe_designs_tools.dm | 2 +-
6 files changed, 14 insertions(+), 95 deletions(-)
delete mode 100644 code/modules/mob/living/carbon/give.dm
delete mode 100644 code/modules/mob/living/simple_animal/hostile/creature.dm
diff --git a/code/game/objects/items/storage/toolbox.dm b/code/game/objects/items/storage/toolbox.dm
index 64e0a6b492..7e89ddbd8d 100644
--- a/code/game/objects/items/storage/toolbox.dm
+++ b/code/game/objects/items/storage/toolbox.dm
@@ -16,12 +16,17 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
attack_verb = list("robusted")
hitsound = 'sound/weapons/smash.ogg'
custom_materials = list(/datum/material/iron = 500)
- material_flags = MATERIAL_COLOR
var/latches = "single_latch"
var/has_latches = TRUE
var/can_rubberify = TRUE
rad_flags = RAD_PROTECT_CONTENTS | RAD_NO_CONTAMINATE //very protecc too
+/obj/item/storage/toolbox/greyscale
+ icon_state = "toolbox_default"
+ item_state = "toolbox_default"
+ can_rubberify = FALSE
+ material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS | MATERIAL_EFFECTS
+
/obj/item/storage/toolbox/Initialize(mapload)
if(has_latches)
if(prob(10))
@@ -48,7 +53,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
name = "emergency toolbox"
icon_state = "red"
item_state = "toolbox_red"
- material_flags = NONE
/obj/item/storage/toolbox/emergency/PopulateContents()
new /obj/item/crowbar/red(src)
@@ -73,7 +77,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
- material_flags = NONE
/obj/item/storage/toolbox/mechanical/PopulateContents()
new /obj/item/screwdriver(src)
@@ -102,7 +105,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
name = "electrical toolbox"
icon_state = "yellow"
item_state = "toolbox_yellow"
- material_flags = NONE
/obj/item/storage/toolbox/electrical/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
@@ -124,7 +126,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
desc = "A toolbox painted black with a red stripe. It looks more heavier than normal toolboxes."
force = 15
throwforce = 18
- material_flags = NONE
/obj/item/storage/toolbox/syndicate/ComponentInitialize()
. = ..()
@@ -144,7 +145,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
name = "mechanical toolbox"
icon_state = "blue"
item_state = "toolbox_blue"
- material_flags = NONE
/obj/item/storage/toolbox/drone/PopulateContents()
var/pickedcolor = pick("red","yellow","green","blue","pink","orange","cyan","white")
@@ -166,7 +166,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
w_class = WEIGHT_CLASS_HUGE
attack_verb = list("robusted", "crushed", "smashed")
can_rubberify = FALSE
- material_flags = NONE
var/fabricator_type = /obj/item/clockwork/replica_fabricator/scarab
/obj/item/storage/toolbox/brass/ComponentInitialize()
@@ -209,7 +208,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
w_class = WEIGHT_CLASS_HUGE //heyo no bohing this!
force = 18 //spear damage
can_rubberify = FALSE
- material_flags = NONE
/obj/item/storage/toolbox/plastitanium/afterattack(atom/A, mob/user, proximity)
. = ..()
@@ -225,7 +223,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
icon_state = "green"
item_state = "toolbox_green"
w_class = WEIGHT_CLASS_GIGANTIC //Holds more than a regular toolbox!
- material_flags = NONE
/obj/item/storage/toolbox/artistic/ComponentInitialize()
. = ..()
@@ -302,7 +299,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
icon_state = "gold"
item_state = "toolbox_gold"
has_latches = FALSE
- material_flags = NONE
/obj/item/storage/toolbox/gold_real/PopulateContents()
new /obj/item/screwdriver/nuke(src)
@@ -328,7 +324,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
force = 0
throwforce = 0
can_rubberify = FALSE
- material_flags = NONE
/obj/item/storage/toolbox/proc/rubberify()
name = "rubber [name]"
@@ -364,7 +359,6 @@ GLOBAL_LIST_EMPTY(rubber_toolbox_icons)
throwforce = 15
attack_verb = list("robusted", "bounced")
can_rubberify = FALSE //we are already the future.
- material_flags = NONE
/obj/item/storage/toolbox/rubber/Initialize()
icon_state = pick("blue", "red", "yellow", "green")
diff --git a/code/modules/events/pirates.dm b/code/modules/events/pirates.dm
index 8a693b77d2..b0b12f3944 100644
--- a/code/modules/events/pirates.dm
+++ b/code/modules/events/pirates.dm
@@ -63,7 +63,7 @@
if(!SSmapping.empty_space)
SSmapping.empty_space = SSmapping.add_new_zlevel("Empty Area For Pirates", list(ZTRAIT_LINKAGE = SELFLOOPING))
-
+
var/datum/map_template/shuttle/pirate/default/ship = new
var/x = rand(TRANSITIONEDGE,world.maxx - TRANSITIONEDGE - ship.width)
var/y = rand(TRANSITIONEDGE,world.maxy - TRANSITIONEDGE - ship.height)
@@ -159,11 +159,12 @@
active = FALSE
STOP_PROCESSING(SSobj,src)
-/obj/machinery/shuttle_scrambler/update_icon_state()
+/obj/machinery/shuttle_scrambler/update_overlays()
+ . = ..()
if(active)
- icon_state = "dominator-blue"
- else
- icon_state = "dominator"
+ var/mutable_appearance/M = mutable_appearance(icon, "dominator-overlay")
+ M.color = "#00FFFF"
+ . += M
/obj/machinery/shuttle_scrambler/Destroy()
toggle_off()
diff --git a/code/modules/food_and_drinks/food/snacks_pastry.dm b/code/modules/food_and_drinks/food/snacks_pastry.dm
index c5268380a1..48bd0f1da4 100644
--- a/code/modules/food_and_drinks/food/snacks_pastry.dm
+++ b/code/modules/food_and_drinks/food/snacks_pastry.dm
@@ -451,7 +451,7 @@
/obj/item/reagent_containers/food/snacks/donkpocket/initialize_cooked_food(obj/item/reagent_containers/food/snacks/donkpocket/S, cooking_efficiency = 1)
. = ..()
if(istype(S))
- desc = initial(desc) //reset the desc since will now cool down.
+ S.desc = initial(S.desc) //reset the desc since will now cool down.
for(var/R in S.bonus_reagents)
LAZYSET(S.cached_reagents_amount, R, S.reagents.get_reagent_amount(R))
S.previous_typepath = type
diff --git a/code/modules/mob/living/carbon/give.dm b/code/modules/mob/living/carbon/give.dm
deleted file mode 100644
index a712240622..0000000000
--- a/code/modules/mob/living/carbon/give.dm
+++ /dev/null
@@ -1,58 +0,0 @@
-/mob/living/verb/give()
- set category = "IC"
- set name = "Give"
- set src in oview(1) //Cannot handle giving shit to mobs on your own tile, but it's a small, small loss
-
- give_item(usr)
-
-/mob/living/proc/give_item(mob/living/carbon/user)
-
-
-/mob/living/carbon/give_item(mob/living/carbon/user)
- if(!istype(user))
- return
- if(src.stat == 2 || user.stat == 2 || src.client == null)
- return
- if(src.handcuffed)
- user << "Those hands are cuffed right now."
- return //Can't receive items while cuffed
- var/obj/item/I
- if(user.get_active_held_item() == null)
- user << "You don't have anything in your [get_held_index_name(get_held_index_of_item(I))] to give to [src]."
- return
- I = user.get_active_held_item()
- if(!I)
- return
- if(src == user) //Shouldn't happen
- user << "You tried to give yourself \the [I], but you didn't want it."
- return
- if(get_empty_held_index_for_side())
- switch(alert(src, "[user] wants to give you \a [I]?", , "Yes", "No"))
- if("Yes")
- if(!I)
- return
- if(!Adjacent(user))
- user <<"You need to stay still while giving an object."
- src << "[user] moved away."//What an asshole
-
- return
- if(user.get_active_held_item() != I)
- user << "You need to keep the item in your hand."
- src << "[user] has put \the [I] away!"
- return
- if(!get_empty_held_index_for_side())
- user << "Your hands are full."
- user << "Their hands are full."
- return
- if(!user.dropItemToGround(I))
- src << "[user] can't let go of \the [I]!"
- user << "You can't seem to let go of \the [I]."
- return
-
- src.put_in_hands(I)
- update_inv_hands()
- src.visible_message("[user] handed \the [I] to [src].")
- if("No")
- src.visible_message("[user] tried to hand \the [I] to [src] but \he didn't want it.")
- else
- user << "[src]'s hands are full."
diff --git a/code/modules/mob/living/simple_animal/hostile/creature.dm b/code/modules/mob/living/simple_animal/hostile/creature.dm
deleted file mode 100644
index bba37f94af..0000000000
--- a/code/modules/mob/living/simple_animal/hostile/creature.dm
+++ /dev/null
@@ -1,18 +0,0 @@
-/mob/living/simple_animal/hostile/creature
- name = "creature"
- desc = "A sanity-destroying otherthing."
- icon_state = "otherthing"
- icon_living = "otherthing"
- icon_dead = "otherthing-dead"
- health = 80
- maxHealth = 80
- obj_damage = 100
- melee_damage_lower = 25
- melee_damage_upper = 50
- attacktext = "chomps"
- attack_sound = 'sound/weapons/bite.ogg'
- faction = list("creature")
- speak_emote = list("screams")
- gold_core_spawnable = HOSTILE_SPAWN
- atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
- minbodytemp = 0
diff --git a/code/modules/research/designs/autolathe_desings/autolathe_designs_tools.dm b/code/modules/research/designs/autolathe_desings/autolathe_designs_tools.dm
index f6c31a9808..330dfb8f8a 100644
--- a/code/modules/research/designs/autolathe_desings/autolathe_designs_tools.dm
+++ b/code/modules/research/designs/autolathe_desings/autolathe_designs_tools.dm
@@ -139,7 +139,7 @@
id = "tool_box"
build_type = AUTOLATHE
materials = list(MAT_CATEGORY_RIGID = 500)
- build_path = /obj/item/storage/toolbox
+ build_path = /obj/item/storage/toolbox/greyscale
category = list("initial","Tools")
/datum/design/spraycan