mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 05:00:55 +01:00
Merge pull request #28435 from lzimann/typecaches
Changes a lot of is_type_in_list to use a typecache
This commit is contained in:
@@ -50,6 +50,9 @@
|
||||
/obj/item/weapon/reagent_containers/food/snacks/grown/ambrosia/deus,
|
||||
/obj/item/weapon/reagent_containers/food/snacks/grown/wheat)
|
||||
|
||||
/obj/item/weapon/grown/log/Initialize()
|
||||
. = ..()
|
||||
accepted = typecacheof(accepted)
|
||||
|
||||
/obj/item/weapon/grown/log/attackby(obj/item/weapon/W, mob/user, params)
|
||||
if(W.sharpness)
|
||||
@@ -66,7 +69,7 @@
|
||||
to_chat(user, "<span class='notice'>You add the newly-formed [plank_name] to the stack. It now contains [plank.amount] [plank_name].</span>")
|
||||
qdel(src)
|
||||
|
||||
if(is_type_in_list(W,accepted))
|
||||
if(is_type_in_typecache(W,accepted))
|
||||
var/obj/item/weapon/reagent_containers/food/snacks/grown/leaf = W
|
||||
if(leaf.dry)
|
||||
user.show_message("<span class='notice'>You wrap \the [W] around the log, turning it into a torch!</span>")
|
||||
|
||||
Reference in New Issue
Block a user