Merge pull request #68 from deertools/food-wand

Adds in the wand of gluttony
This commit is contained in:
GDLW
2023-02-19 02:07:16 +01:00
committed by GitHub
2 changed files with 55 additions and 0 deletions
+54
View File
@@ -0,0 +1,54 @@
/obj/item/gun/magic/wand/food
name = "wand of gluttony"
desc = "summons delicious fattening foods"
max_charges = 15
ammo_type = /obj/item/ammo_casing/magic/food
/obj/item/gun/magic/wand/food/overpowered //This is a more overpowered version of the item
name = "strong wand of gluttony"
max_charges = 100
ammo_type = /obj/item/ammo_casing/magic/food/strong
/obj/item/ammo_casing/magic/food
projectile_type = /obj/item/projectile/magic/food
/obj/item/ammo_casing/magic/food/strong
projectile_type = /obj/item/projectile/magic/food/strong
/obj/item/projectile/magic/food
name = "bolt of food"
pass_flags = PASSGLASS|PASSDOOR|PASSGRILLE
///What foods are able to be spawned by the wand?
var/list/spawnable_foods = list(
/obj/item/reagent_containers/food/snacks/burger/bigbite,
/obj/item/reagent_containers/food/snacks/donut/plain,
/obj/item/reagent_containers/food/snacks/donut/glaze,
/obj/item/reagent_containers/food/snacks/store/cake/cheese,
/obj/item/reagent_containers/food/snacks/store/cake/birthday,
/obj/item/reagent_containers/food/snacks/store/cake/chocolate,
/obj/item/reagent_containers/food/snacks/hotdog,
/obj/item/reagent_containers/food/snacks/pizza/margherita,
/obj/item/reagent_containers/food/snacks/pizza/meat,
)
///How much Lipoifier should be added to the spawned in food? Keep this at 10 maximum.
var/lipoifier_to_add = 5
/obj/item/projectile/magic/food/on_hit(atom/target, blocked)
. = ..()
var/turf/floor = get_turf(target)
if(!floor || iswallturf(floor))
return FALSE
var/food_to_spawn = pick(spawnable_foods)
var/obj/item/reagent_containers/food/snacks/spawned_food = new food_to_spawn(floor)
if(!spawned_food)
return FALSE
spawned_food.reagents.add_reagent(/datum/reagent/consumable/lipoifier, lipoifier_to_add)
return TRUE
/obj/item/projectile/magic/food/strong
name = "strong bolt of food"
lipoifier_to_add = 10
+1
View File
@@ -3075,6 +3075,7 @@
#include "GainStation13\code\machinery\feeding_tube.dm"
#include "GainStation13\code\mechanics\fatness.dm"
#include "GainStation13\code\mechanics\spells.dm"
#include "GainStation13\code\mechanics\wand.dm"
#include "GainStation13\code\modules\client\preferences\preferences.dm"
#include "GainStation13\code\modules\mob\living\emote.dm"
#include "GainStation13\code\modules\reagents\chemistry\reagents\consumable_reagents.dm"