Kitchen Sprites Tweak (#15991)
* Kitchen Sprites Tweak * Colour Change; Blank Sprite Removal * Minor Tweak * Beekeeping * Sprite Name Fix * CL * Beehive Assembly; Bee Net * Merge Conflict Resolution
@@ -885,7 +885,6 @@
|
||||
#include "code\game\objects\effects\temporary_visuals\temporary_visual.dm"
|
||||
#include "code\game\objects\items\airbubble.dm"
|
||||
#include "code\game\objects\items\apc_frame.dm"
|
||||
#include "code\game\objects\items\bees_items.dm"
|
||||
#include "code\game\objects\items\blueprints.dm"
|
||||
#include "code\game\objects\items\bodybag.dm"
|
||||
#include "code\game\objects\items\canvas.dm"
|
||||
@@ -1986,6 +1985,7 @@
|
||||
#include "code\modules\hydroponics\beekeeping\beehive.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\honey_extractor.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\honey_frame.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\items.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\net.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\smoker.dm"
|
||||
#include "code\modules\hydroponics\beekeeping\wax.dm"
|
||||
@@ -2006,7 +2006,6 @@
|
||||
#include "code\modules\hydroponics\spreading\spreading_growth.dm"
|
||||
#include "code\modules\hydroponics\spreading\spreading_response.dm"
|
||||
#include "code\modules\hydroponics\trays\tray.dm"
|
||||
#include "code\modules\hydroponics\trays\tray_apiary.dm"
|
||||
#include "code\modules\hydroponics\trays\tray_process.dm"
|
||||
#include "code\modules\hydroponics\trays\tray_reagents.dm"
|
||||
#include "code\modules\hydroponics\trays\tray_soil.dm"
|
||||
|
||||
@@ -1,3 +1,17 @@
|
||||
/obj/item/beehive_assembly
|
||||
name = "beehive assembly"
|
||||
desc = "Contains everything you need to build a beehive."
|
||||
icon = 'icons/obj/beekeeping.dmi'
|
||||
icon_state = "beehive_assembly"
|
||||
|
||||
/obj/item/beehive_assembly/attack_self(var/mob/user)
|
||||
to_chat(user, SPAN_NOTICE("You start assembling \the [src]..."))
|
||||
if(do_after(user, 30))
|
||||
user.visible_message(SPAN_NOTICE("\The [user] constructs a beehive."), SPAN_NOTICE("You construct a beehive."))
|
||||
new /obj/machinery/beehive(get_turf(user))
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/machinery/beehive
|
||||
name = "beehive"
|
||||
icon = 'icons/obj/beekeeping.dmi'
|
||||
@@ -193,21 +207,7 @@
|
||||
//what's left over
|
||||
var/mob/living/simple_animal/bee/B = new(pick(spawn_turfs), src)
|
||||
B.strength = bees_to_release
|
||||
B.icon_state = "bees[B.strength]"
|
||||
B.icon_state = "bh_bees[B.strength]"
|
||||
B.feral = angry
|
||||
B.update_icon()
|
||||
bees_to_release = 0
|
||||
|
||||
/obj/item/beehive_assembly
|
||||
name = "beehive assembly"
|
||||
desc = "Contains everything you need to build a beehive."
|
||||
icon = 'icons/obj/apiary_bees_etc.dmi'
|
||||
icon_state = "apiary"
|
||||
|
||||
/obj/item/beehive_assembly/attack_self(var/mob/user)
|
||||
to_chat(user, SPAN_NOTICE("You start assembling \the [src]..."))
|
||||
if(do_after(user, 30))
|
||||
user.visible_message(SPAN_NOTICE("\The [user] constructs a beehive."), SPAN_NOTICE("You construct a beehive."))
|
||||
new /obj/machinery/beehive(get_turf(user))
|
||||
qdel(src)
|
||||
return
|
||||
bees_to_release = 0
|
||||
@@ -1,30 +1,3 @@
|
||||
|
||||
/obj/item/queen_bee
|
||||
name = "queen bee packet"
|
||||
desc = "Place her into an apiary so she can get busy."
|
||||
icon = 'icons/obj/seeds.dmi'
|
||||
icon_state = "vine2"
|
||||
w_class = ITEMSIZE_TINY
|
||||
|
||||
|
||||
|
||||
/obj/item/apiary
|
||||
name = "moveable apiary"
|
||||
icon = 'icons/obj/apiary_bees_etc.dmi'
|
||||
icon_state = "apiary_item"
|
||||
item_state = "giftbag"
|
||||
w_class = ITEMSIZE_HUGE
|
||||
|
||||
/obj/item/beezeez
|
||||
name = "bottle of BeezEez"
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-1"
|
||||
|
||||
/obj/item/beezeez/Initialize() // Better than hardsprited in stuff.
|
||||
var/mutable_appearance/filling = mutable_appearance('icons/obj/reagentfillings.dmi', "[icon_state]-100")
|
||||
filling.color = COLOR_BLUE
|
||||
add_overlay(filling)
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/honeycomb
|
||||
name = "honeycomb"
|
||||
icon_state = "honeycomb"
|
||||
@@ -43,17 +16,17 @@
|
||||
author = "Beekeeper Dave"
|
||||
title = "The Ins and Outs of Apiculture - A Precise Art"
|
||||
dat = {"<html>
|
||||
<head>
|
||||
<head>
|
||||
<style>
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
h2 {font-size: 15px; margin: 15px 0px 5px;}
|
||||
li {margin: 2px 0px 2px 15px;}
|
||||
ul {margin: 5px; padding: 0px;}
|
||||
ol {margin: 5px; padding: 0px 15px;}
|
||||
body {font-size: 13px; font-family: Verdana;}
|
||||
h1 {font-size: 18px; margin: 15px 0px 5px;}
|
||||
h2 {font-size: 15px; margin: 15px 0px 5px;}
|
||||
li {margin: 2px 0px 2px 15px;}
|
||||
ul {margin: 5px; padding: 0px;}
|
||||
ol {margin: 5px; padding: 0px 15px;}
|
||||
body {font-size: 13px; font-family: Verdana;}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Raising Bees</h1>
|
||||
|
||||
Bees require their hive to be built near plants in order to feed on them, so construct it somewhere in a garden. Insert the honey frames so they can start preparing honey.<br>
|
||||
@@ -65,8 +38,6 @@
|
||||
Don't forget to wear a thick suit, a biosuit is included for your safety. Bee stings can hurt <br>
|
||||
|
||||
And last but not least, prepare for future expansion. Your bees will grow fast, and at some point you'll find the hive full. You can construct a second one and frames for it with enough wood.
|
||||
</body>
|
||||
</html>
|
||||
"}
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
"}
|
||||
@@ -1,7 +1,7 @@
|
||||
/obj/item/bee_net
|
||||
name = "bee net"
|
||||
desc = "A net for catching rogue bees."
|
||||
icon = 'icons/obj/apiary_bees_etc.dmi'
|
||||
icon = 'icons/obj/beekeeping.dmi'
|
||||
icon_state = "bee_net"
|
||||
item_state = "bee_net"
|
||||
var/caught_bees = 0
|
||||
|
||||
@@ -1,239 +0,0 @@
|
||||
//http://www.youtube.com/watch?v=-1GadTfGFvU
|
||||
//i could have done these as just an ordinary plant, but fuck it - there would have been too much snowflake code
|
||||
|
||||
/obj/machinery/apiary
|
||||
name = "apiary tray"
|
||||
icon = 'icons/obj/hydroponics_machines.dmi'
|
||||
icon_state = "hydrotray3"
|
||||
density = 1
|
||||
anchored = 1
|
||||
var/nutrilevel = 0
|
||||
var/yieldmod = 1
|
||||
var/mut = 1
|
||||
var/toxic = 0
|
||||
var/dead = 0
|
||||
var/health = -1
|
||||
var/maxhealth = 100
|
||||
var/lastcycle = 0
|
||||
var/cycledelay = 100
|
||||
var/harvestable_honey = 0
|
||||
var/beezeez = 0
|
||||
var/swarming = 0
|
||||
|
||||
var/bees_in_hive = 0
|
||||
var/list/owned_bee_swarms = list()
|
||||
var/hydrotray_type = /obj/machinery/portable_atmospherics/hydroponics
|
||||
|
||||
//overwrite this after it's created if the apiary needs a custom machinery sprite
|
||||
/obj/machinery/apiary/Initialize()
|
||||
..()
|
||||
add_overlay(image('icons/obj/apiary_bees_etc.dmi', icon_state = "apiary"))
|
||||
|
||||
/obj/machinery/apiary/bullet_act(var/obj/item/projectile/Proj) //Works with the Somatoray to modify plant variables.
|
||||
if(istype(Proj ,/obj/item/projectile/energy/floramut))
|
||||
mut++
|
||||
else if(istype(Proj ,/obj/item/projectile/energy/florayield))
|
||||
if(!yieldmod)
|
||||
yieldmod += 1
|
||||
else if (prob(1/(yieldmod * yieldmod) *100))//This formula gives you diminishing returns based on yield. 100% with 1 yield, decreasing to 25%, 11%, 6, 4, 2...
|
||||
yieldmod += 1
|
||||
else
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/machinery/apiary/attackby(var/obj/item/O as obj, var/mob/user as mob)
|
||||
if(istype(O, /obj/item/queen_bee))
|
||||
if(health > 0)
|
||||
to_chat(user, "<span class='warning'>There is already a queen in there.</span>")
|
||||
else
|
||||
health = 10
|
||||
nutrilevel += 10
|
||||
user.drop_from_inventory(O,get_turf(src))
|
||||
qdel(O)
|
||||
to_chat(user, "<span class='notice'>You carefully insert the queen into [src], she gets busy making a hive.</span>")
|
||||
bees_in_hive = 0
|
||||
else if(istype(O, /obj/item/beezeez))
|
||||
beezeez += 100
|
||||
nutrilevel += 10
|
||||
user.drop_from_inventory(O,get_turf(src))
|
||||
qdel(O)
|
||||
if(health > 0)
|
||||
to_chat(user, "<span class='notice'>You insert [O] into [src]. A relaxed humming appears to pick up.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You insert [O] into [src]. Now it just needs some bees.</span>")
|
||||
qdel(O)
|
||||
else if(istype(O, /obj/item/material/minihoe))
|
||||
if(health > 0)
|
||||
to_chat(user, "<span class='danger'>You begin to dislodge the apiary from the tray, the bees don't like that.</span>")
|
||||
angry_swarm(user)
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You begin to dislodge the dead apiary from the tray.</span>")
|
||||
if(O.use_tool(src, user, 50, volume = 50))
|
||||
new hydrotray_type(src.loc)
|
||||
new /obj/item/apiary(src.loc)
|
||||
to_chat(user, "<span class='warning'>You dislodge the apiary from the tray.</span>")
|
||||
qdel(src)
|
||||
else if(istype(O, /obj/item/bee_net))
|
||||
var/obj/item/bee_net/N = O
|
||||
if(N.caught_bees > 0)
|
||||
to_chat(user, "<span class='notice'>You empty the bees into the apiary.</span>")
|
||||
bees_in_hive += N.caught_bees
|
||||
N.caught_bees = 0
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There are no more bees in the net.</span>")
|
||||
else if(istype(O, /obj/item/reagent_containers/glass))
|
||||
var/obj/item/reagent_containers/glass/G = O
|
||||
if(harvestable_honey > 0)
|
||||
if(health > 0)
|
||||
to_chat(user, "<span class='warning'>You begin to harvest the honey. The bees don't seem to like it.</span>")
|
||||
angry_swarm(user)
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You begin to harvest the honey.</span>")
|
||||
if(O.use_tool(src, user, 50, volume = 50))
|
||||
G.reagents.add_reagent(/singleton/reagent/nutriment/honey,harvestable_honey)
|
||||
harvestable_honey = 0
|
||||
to_chat(user, "<span class='notice'>You successfully harvest the honey.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There is no honey left to harvest.</span>")
|
||||
else
|
||||
angry_swarm(user)
|
||||
..()
|
||||
|
||||
/obj/machinery/apiary/CanPass(atom/movable/mover, turf/target, height=0, air_group=0)
|
||||
if(air_group || (height==0)) return 1
|
||||
|
||||
if(istype(mover) && mover.checkpass(PASSTABLE))
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
|
||||
/obj/machinery/apiary/process()
|
||||
|
||||
if(swarming > 0)
|
||||
swarming -= 1
|
||||
if(swarming <= 0)
|
||||
for(var/mob/living/simple_animal/bee/B in src.loc)
|
||||
bees_in_hive += B.strength
|
||||
qdel(B)
|
||||
else if(bees_in_hive < 10)
|
||||
for(var/mob/living/simple_animal/bee/B in src.loc)
|
||||
bees_in_hive += B.strength
|
||||
qdel(B)
|
||||
|
||||
if(world.time > (lastcycle + cycledelay))
|
||||
lastcycle = world.time
|
||||
if(health < 0)
|
||||
return
|
||||
|
||||
//magical bee formula
|
||||
if(beezeez > 0)
|
||||
beezeez -= 1
|
||||
|
||||
nutrilevel += 2
|
||||
health += 1
|
||||
toxic = max(0, toxic - 1)
|
||||
|
||||
//handle nutrients
|
||||
nutrilevel -= bees_in_hive / 10 + owned_bee_swarms.len / 5
|
||||
if(nutrilevel > 0)
|
||||
bees_in_hive += 1 * yieldmod
|
||||
if(health < maxhealth)
|
||||
health++
|
||||
else
|
||||
//nutrilevel is less than 1, so we're effectively subtracting here
|
||||
health += max(nutrilevel - 1, round(-health / 2))
|
||||
bees_in_hive += max(nutrilevel - 1, round(-bees_in_hive / 2))
|
||||
if(owned_bee_swarms.len)
|
||||
var/mob/living/simple_animal/bee/B = pick(owned_bee_swarms)
|
||||
B.target_turf = get_turf(src)
|
||||
|
||||
//clear out some toxins
|
||||
if(toxic > 0)
|
||||
toxic -= 1
|
||||
health -= 1
|
||||
|
||||
if(health <= 0)
|
||||
return
|
||||
|
||||
//make a bit of honey
|
||||
if(harvestable_honey < 50)
|
||||
harvestable_honey += 0.5
|
||||
|
||||
//make some new bees
|
||||
if(bees_in_hive >= 10 && prob(bees_in_hive * 10))
|
||||
var/mob/living/simple_animal/bee/B = new(get_turf(src), src)
|
||||
owned_bee_swarms.Add(B)
|
||||
B.mut = mut
|
||||
B.toxic = toxic
|
||||
bees_in_hive -= 1
|
||||
|
||||
//find some plants, harvest
|
||||
for(var/obj/machinery/portable_atmospherics/hydroponics/H in view(7, src))
|
||||
if(H.seed && !H.dead && prob(owned_bee_swarms.len * 10))
|
||||
src.nutrilevel++
|
||||
H.nutrilevel++
|
||||
if(mut < H.mutation_mod - 1)
|
||||
mut = H.mutation_mod - 1
|
||||
else if(mut > H.mutation_mod - 1)
|
||||
H.mutation_mod = mut
|
||||
|
||||
//flowers give us pollen (nutrients)
|
||||
/* - All plants should be giving nutrients to the hive.
|
||||
if(H.myseed.type == /obj/item/seeds/harebell || H.myseed.type == /obj/item/seeds/sunflowerseed)
|
||||
src.nutrilevel++
|
||||
H.nutrilevel++
|
||||
*/
|
||||
//have a few beneficial effects on nearby plants
|
||||
if(prob(10))
|
||||
H.lastcycle -= 5
|
||||
if(prob(10))
|
||||
H.seed.set_trait(TRAIT_ENDURANCE,max(H.seed.get_trait(TRAIT_ENDURANCE)*1.5,H.seed.get_trait(TRAIT_ENDURANCE)+1))
|
||||
if(H.toxins && prob(10))
|
||||
H.toxins = min(0, H.toxins - 1)
|
||||
toxic++
|
||||
|
||||
/obj/machinery/apiary/proc/die()
|
||||
if(owned_bee_swarms.len)
|
||||
var/mob/living/simple_animal/bee/B = pick(owned_bee_swarms)
|
||||
B.target_turf = get_turf(src)
|
||||
B.strength -= 1
|
||||
if(B.strength <= 0)
|
||||
qdel(B)
|
||||
else if(B.strength <= 5)
|
||||
B.icon_state = "bees[B.strength]"
|
||||
bees_in_hive = 0
|
||||
health = 0
|
||||
|
||||
/obj/machinery/apiary/proc/angry_swarm(var/mob/M)
|
||||
for(var/mob/living/simple_animal/bee/B in owned_bee_swarms)
|
||||
B.feral = 25
|
||||
B.target_mob = M
|
||||
|
||||
swarming = 25
|
||||
|
||||
while(bees_in_hive > 0)
|
||||
var/spawn_strength = bees_in_hive
|
||||
if(bees_in_hive >= 5)
|
||||
spawn_strength = 6
|
||||
|
||||
var/mob/living/simple_animal/bee/B = new(get_turf(src), src)
|
||||
B.target_mob = M
|
||||
B.strength = spawn_strength
|
||||
B.feral = 25
|
||||
B.mut = mut
|
||||
B.toxic = toxic
|
||||
bees_in_hive -= spawn_strength
|
||||
|
||||
/obj/machinery/apiary/verb/harvest_honeycomb()
|
||||
set src in oview(1)
|
||||
set name = "Harvest honeycomb"
|
||||
set category = "Object"
|
||||
|
||||
while(health > 15)
|
||||
health -= 15
|
||||
var/obj/item/reagent_containers/food/snacks/honeycomb/H = new(src.loc)
|
||||
if(toxic > 0)
|
||||
H.reagents.add_reagent(/singleton/reagent/toxin, toxic)
|
||||
|
||||
to_chat(usr, "<span class='notice'>You harvest the honeycomb from the hive. There is a wild buzzing!</span>")
|
||||
angry_swarm(usr)
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
/mob/living/simple_animal/bee
|
||||
name = "bees"
|
||||
icon = 'icons/obj/apiary_bees_etc.dmi'
|
||||
icon = 'icons/obj/beekeeping.dmi'
|
||||
icon_state = "bees1"
|
||||
icon_dead = "bees1"
|
||||
mob_size = 0.5
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
author: SleepyGemmy, atteria
|
||||
|
||||
delete-after: True
|
||||
|
||||
changes:
|
||||
- imageadd: "Tweaked some kitchen sprites."
|
||||
- imageadd: "Resprited the beekeeping sprites."
|
||||
|
Before Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 3.0 KiB |
|
Before Width: | Height: | Size: 209 KiB After Width: | Height: | Size: 209 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 11 KiB |