Beekeeping 3.6 (#18592)

* Beekeeping 3.6

* qsdqsd

* qdqsdq

* grammar
This commit is contained in:
DeityLink
2018-06-25 14:06:46 +02:00
committed by jknpj
parent 149512df62
commit f3045d2b2d
11 changed files with 447 additions and 99 deletions

View File

@@ -693,6 +693,7 @@ SEE_PIXELS 256
#define BEE_OUT_FOR_ENEMIES 2
#define BEE_HEADING_HOME 3
#define BEE_SWARM 4
#define BEE_BUILDING 5
#define LOC_KITCHEN 0
#define LOC_ATMOS 1
@@ -713,6 +714,7 @@ SEE_PIXELS 256
#define VERM_ROACHES 7
#define VERM_GREMLINS 8
#define VERM_BEES 9
#define VERM_HORNETS 10
#define ROUNDSTART_LOGOUT_REPORT_TIME 6000 //Amount of time (in deciseconds) after the rounds starts, that the player disconnect report is issued.
@@ -1518,6 +1520,8 @@ var/proccalls = 1
#define BEESPECIES_NORMAL "bees"
#define BEESPECIES_VOX "chill bugs"
#define BEESPECIES_HORNET "hornets"
#define BEESPECIES_BLOOD "hell bugs"
//mob/proc/is_pacified()
#define VIOLENCE_SILENT 0

View File

@@ -273,6 +273,13 @@ var/list/uplink_items = list()
cost = 4
job = list("Botanist")
/datum/uplink_item/jobspecific/hornetqueen
name = "Hornet Queen Packet"
desc = "Place her into an apiary tray, add a few packs of BeezEez, then lay it inside your nemesis' office. Surprise guaranteed. Protective gear won't be enough to shield you reliably from these."
item = /obj/item/queen_bee/hornet
cost = 2
job = list("Botanist")
//Chef
/datum/uplink_item/jobspecific/specialsauce
name = "Chef Excellence's Special Sauce"

View File

@@ -134,6 +134,7 @@
H.equip_or_collect(new /obj/item/clothing/under/rank/botany(H), slot_w_uniform)
if("Beekeeper")
H.equip_or_collect(new /obj/item/clothing/under/rank/beekeeper(H), slot_w_uniform)
H.equip_or_collect(new /obj/item/queen_bee(H), slot_l_store)
if("Gardener")
H.equip_or_collect(new /obj/item/clothing/under/rank/gardener(H), slot_w_uniform)

View File

@@ -8,6 +8,7 @@
> angry-bee hive
*/
var/list/apiary_reservation = list()
/obj/machinery/apiary
name = "apiary tray"
@@ -101,13 +102,14 @@
else
to_chat(user, "<span class='danger'>The [species_name] are violent and exhausted, the hive's toxicity is reaching critical levels.</span>")
switch(reagents.total_volume)
if(30 to 60)
to_chat(user, "<span class='info'>Looks like there's a bit of [reagent_name(species.worker_product)] in it.</span>")
if(60 to 90)
to_chat(user, "<span class='info'>There's a decent amount of [reagent_name(species.worker_product)] dripping from it!</span>")
if(90 to INFINITY)
to_chat(user, "<span class='info'>It's full of [reagent_name(species.worker_product)]!</span>")
if (species.worker_product)
switch(reagents.total_volume)
if(30 to 60)
to_chat(user, "<span class='info'>Looks like there's a bit of [reagent_name(species.worker_product)] in it.</span>")
if(60 to 90)
to_chat(user, "<span class='info'>There's a decent amount of [reagent_name(species.worker_product)] dripping from it!</span>")
if(90 to INFINITY)
to_chat(user, "<span class='info'>It's full of [reagent_name(species.worker_product)]!</span>")
/obj/machinery/apiary/Cross(atom/movable/mover, turf/target, height=1.5, air_group = 0)
if(air_group || (height==0))
@@ -240,6 +242,7 @@
queen_bees_inside++
var/datum/bee/queen_bee/Q = B
if (Q.colonizing)
apiary_reservation.Remove(src)
nutrilevel = max(15,nutrilevel+15)
else
worker_bees_inside++
@@ -289,9 +292,9 @@
reagents.add_reagent(chemToAdd, amountToAdd * yieldmod)
if (!pollen.Find(S))
pollen.Add(S)
if (istype(B,/datum/bee/queen_bee))
if (istype(B,/datum/bee/queen_bee) && species.queen_product)
reagents.add_reagent(species.queen_product,0.75 * yieldmod)
else
else if (species.worker_product)
reagents.add_reagent(species.worker_product,0.75 * yieldmod)
reagents.add_reagent(SUGAR, 0.1 * yieldmod)
@@ -328,15 +331,17 @@
var/mob/living/simple_animal/bee/lastBees = getFromPool(/mob/living/simple_animal/bee,get_turf(src))
for(var/i = 1 to worker_bees_inside)
worker_bees_inside--
lastBees.addBee(new species.bee_type(src))
lastBees.addBee(new species.bee_type())
for(var/i = 1 to queen_bees_inside)
queen_bees_inside--
lastBees.addBee(new species.queen_type(src))
lastBees.addBee(new species.queen_type())
/obj/machinery/apiary/proc/exile_swarm(var/obj/machinery/apiary/A)
if (A == src)
if (A == src)//can't colonize our own apiary
return 0
if (A.queen_bees_inside > 0 || is_type_in_list(/datum/bee/queen_bee,A.bees_outside_hive))
if (A in apiary_reservation)//another queen has marked this one for herself
return 0
if (A.queen_bees_inside > 0 || locate(/datum/bee/queen_bee) in A.bees_outside_hive)//another queen made her way there somehow
return 0
var/mob/living/simple_animal/bee/B_mob = getFromPool(/mob/living/simple_animal/bee, get_turf(src), src)
var/datum/bee/queen_bee/new_queen = new species.queen_type(src)
@@ -347,8 +352,17 @@
B_mob.addBee(B)
worker_bees_inside--
new_queen.setHome(A)
A.reserve_apiary(B_mob)
return 1
/obj/machinery/apiary/proc/reserve_apiary(var/mob/living/simple_animal/bee/B_swarm)
apiary_reservation.Add(B_swarm)
spawn (300)
apiary_reservation.Remove(B_swarm)
if (B_swarm)//so we can't reach the apiary somehow? then we've become homeless
B_swarm.visible_message("<span class='notice'>A swarm has lost its way.</span>")
B_swarm.mood_change(BEE_ROAMING)
/obj/machinery/apiary/proc/angry_swarm(var/mob/M = null)
if (!species.angery)
return
@@ -362,7 +376,7 @@
B_mob.addBee(B)
worker_bees_inside--
bees_outside_hive.Add(B)
B.angerAt(M)
B_mob.mood_change(BEE_OUT_FOR_ENEMIES,M)
B_mob.update_icon()
@@ -451,10 +465,11 @@
worker_bees_inside--
bees_outside_hive.Add(B)
B_mob.addBee(B)
if (toxic > species.toxic_threshold_anger && prob(toxic/1.5))//if our beehive is full of toxicity, bees will become ANGRY
B.angerAt()
if (prob(species.aggressiveness) || (toxic > species.toxic_threshold_anger && prob(toxic/1.5)))//if our beehive is full of toxicity, bees will become ANGRY
B_mob.mood_change(BEE_OUT_FOR_ENEMIES)
else
B.goPollinate()
B_mob.mood_change(BEE_OUT_FOR_PLANTS)
B_mob.update_icon()
if(queen_bees_inside > 1 && worker_bees_inside >= 10)
for(var/obj/machinery/apiary/A in range(src,5))
@@ -465,37 +480,78 @@
///////////////////////////WILD BEEHIVES////////////////////////////
/obj/structure/wild_apiary
name = "wild bug hive"
icon = 'icons/obj/apiary_bees_etc.dmi'
icon_state = "apiary-wild-inprogress0"
density = 0
anchored = 1
var/base_icon_state = "apiary-wild-inprogress"
var/prefix = ""
var/remaining_work = 10
var/health = 20
/obj/structure/wild_apiary/New(turf/loc, var/p = "")
prefix = p
icon_state = "[prefix][base_icon_state]0"
/obj/structure/wild_apiary/proc/work()
remaining_work--
switch(remaining_work)
if (1 to 3)
icon_state = "[prefix][base_icon_state]2"
if (4 to 6)
icon_state = "[prefix][base_icon_state]1"
if (7 to 9)
icon_state = "[prefix][base_icon_state]0"
if (remaining_work<=0)
var/obj/machinery/apiary/wild/W = new /obj/machinery/apiary/wild(loc)
W.icon_state = "[prefix][W.icon_state]"
for (var/mob/living/simple_animal/bee/B_mob in loc)
if (B_mob.state == BEE_BUILDING)
for(var/datum/bee/B in B_mob.bees)
W.enterHive(B)
qdel(B_mob)
qdel(src)
/obj/structure/wild_apiary/bullet_act(var/obj/item/projectile/P)
..()
if(P.damage && P.damtype != HALLOSS)
health -= P.damage
updateHealth()
/obj/structure/wild_apiary/attackby(var/obj/item/O as obj, var/mob/user as mob)
if(..())
return
else if(O.force)
user.delayNextAttack(10)
to_chat(user,"<span class='warning'>You hit \the [src] with your [O].</span>")
if(O.hitsound)
playsound(src, O.hitsound, 50, 1, -1)
health -= O.force
updateHealth()
/obj/structure/wild_apiary/proc/updateHealth()
if(health <= 0)
visible_message("<span class='notice'>\The [src] falls apart.</span>")
qdel(src)
/obj/machinery/apiary/wild
name = "angry-bee hive"
name = "hive"
icon = 'icons/obj/apiary_bees_etc.dmi'
icon_state = "apiary-wild"
density = 1
anchored = 1
nutrilevel = 100
damage = 1.5
toxic = 25
nutrilevel = 15
cycledelay = 50
cycledelay = 100
//we'll allow those to start pumping out bees right away
queen_bees_inside = 1
worker_bees_inside = 20
wild = 1
var/health = 100
/obj/machinery/apiary/wild/New()
..()
reagents.add_reagent(ROYALJELLY,5)
reagents.add_reagent(HONEY,75)
reagents.add_reagent(NUTRIMENT, 4)
reagents.add_reagent(SUGAR, 16)
update_icon()
initialize()
/obj/machinery/apiary/wild/initialize()
species = bees_species[BEESPECIES_NORMAL]
/obj/machinery/apiary/wild/bullet_act(var/obj/item/projectile/P)
..()
if(P.damage && P.damtype != HALLOSS)
@@ -530,7 +586,42 @@
qdel(src)
/obj/machinery/apiary/wild/process()
/obj/machinery/apiary/wild/update_icon()
overlays.len = 0
return
/obj/machinery/apiary/wild/angry
name = "angry-bee hive"
icon = 'icons/obj/apiary_bees_etc.dmi'
icon_state = "apiary-wild"
density = 1
anchored = 1
nutrilevel = 100
damage = 1.5
toxic = 25
cycledelay = 50
//we'll allow those to start pumping out bees right away
queen_bees_inside = 1
worker_bees_inside = 20
wild = 1
health = 100
/obj/machinery/apiary/wild/angry/New()
..()
reagents.add_reagent(ROYALJELLY,5)
reagents.add_reagent(HONEY,75)
reagents.add_reagent(NUTRIMENT, 4)
reagents.add_reagent(SUGAR, 16)
update_icon()
initialize()
/obj/machinery/apiary/wild/angry/initialize()
species = bees_species[BEESPECIES_NORMAL]
/obj/machinery/apiary/wild/angry/process()
if(world.time > (lastcycle + cycledelay))
lastcycle = world.time
@@ -553,10 +644,30 @@
worker_bees_inside--
bees_outside_hive.Add(B)
B_mob.addBee(B)
B.angerAt()
B_mob.mood_change(BEE_OUT_FOR_ENEMIES)
B_mob.update_icon()
/obj/machinery/apiary/wild/update_icon()
overlays.len = 0
return
/obj/machinery/apiary/wild/angry/hornet
name = "deadly hornet hive"
icon = 'icons/obj/apiary_bees_etc.dmi'
icon_state = "hornet_apiary-wild"
density = 1
anchored = 1
nutrilevel = 100
damage = 1//hornets are already pretty dangerous by themselves.
toxic = 0
cycledelay = 50
//we'll allow those to start pumping out bees right away
queen_bees_inside = 1
worker_bees_inside = 20
wild = 1
health = 100
/obj/machinery/apiary/wild/angry/hornet/initialize()
species = bees_species[BEESPECIES_HORNET]
#undef MAX_BEES_PER_HIVE

View File

@@ -3590,6 +3590,7 @@
"roaches" = VERM_ROACHES,
"gremlins" = VERM_GREMLINS,
"bees" = VERM_BEES,
"hornets" = VERM_HORNETS,
)
var/ov = vermins[input("What vermin should infest the station?", "Vermin Infestation") in vermins]
var/ol = locations[input("Where should they spawn?", "Vermin Infestation") in locations]

View File

@@ -48,7 +48,7 @@
var/list/spawn_types = list()
var/max_number = 4
vermin = pick(VERM_MICE, VERM_LIZARDS, VERM_SPIDERS, VERM_SLIMES, VERM_BATS, VERM_BORERS, VERM_MIMICS, VERM_ROACHES, VERM_GREMLINS, VERM_BEES)
vermin = pick(VERM_MICE, VERM_LIZARDS, VERM_SPIDERS, VERM_SLIMES, VERM_BATS, VERM_BORERS, VERM_MIMICS, VERM_ROACHES, VERM_GREMLINS, VERM_BEES, VERM_HORNETS)
if (override_vermin)
vermin = override_vermin
@@ -88,9 +88,13 @@
vermstring = "gremlins"
max_number = 4 //2 to 4
if(VERM_BEES)
spawn_types = /obj/machinery/apiary/wild
spawn_types = /obj/machinery/apiary/wild/angry
vermstring = "angry bees"
max_number = 2
if(VERM_HORNETS)
spawn_types = /obj/machinery/apiary/wild/angry/hornet
vermstring = "deadly hornets"
max_number = 1
var/number = rand(2, max_number)

View File

@@ -10,6 +10,7 @@
var/state = BEE_ROAMING
var/fatigue = 0//increases after a successful pollination or when searching for flowers in vain
var/bored = 0//increases when searching for enemies in vain
var/exhaustion = 0//increases when roaming without a queen
var/corpse = /obj/effect/decal/cleanable/bee
var/toxins = 0
var/datum/bee_species/species = null

View File

@@ -7,6 +7,8 @@
#define BOREDOM_TO_RETURN 30//once reached, the bee will head back to its hive
#define EXHAUSTION_TO_DIE 600//once reached, the bee will begin to die
#define MAX_BEES_PER_SWARM 20//explicit
/*
@@ -76,6 +78,7 @@
var/obj/machinery/portable_atmospherics/hydroponics/target_plant = null
var/list/visited_plants = list()
var/datum/bee_species/bee_species = null
var/turf/building = null
pass_flags = PASSTABLE
turns_per_move = 6
density = 0
@@ -249,8 +252,8 @@
for (var/datum/bee/BEE in bees)
total_brute += BEE.damage
total_toxic += BEE.toxic
current_physical_damage = total_brute/2//1 regular bee = 0.5 brute; 20 regular bees = 10 brute; 20 mutated(2 damage) bees = 20 brute;
current_poison_damage = bees.len + (total_toxic/bees.len)/100//1 regular bee = 1 tox; 20 regular bees = 20 tox; 20 intoxicated(100 toxic) bees = 40 tox;
current_physical_damage = (total_brute/2)*bee_species.damage_coef//1 regular bee = 0.5 brute; 20 regular bees = 10 brute; 20 mutated(2 damage) bees = 20 brute;
current_poison_damage = (bees.len + (total_toxic/bees.len)/100)*bee_species.toxic_coef//1 regular bee = 1 tox; 20 regular bees = 20 tox; 20 intoxicated(100 toxic) bees = 40 tox;
update_icon()
/mob/living/simple_animal/bee/proc/panic_attack(mob/damagesource)
@@ -258,13 +261,15 @@
return
for(var/mob/living/simple_animal/bee/B in range(src,3))
if (B.state == BEE_SWARM || calmed > 0)
return
if (B.state == BEE_SWARM || B.state == BEE_BUILDING || B.calmed > 0)
continue
//only their friends from the same apiary will answer their call. homeless bees will also help each others.
if (B.home == home)
B.state = BEE_OUT_FOR_ENEMIES
B.target = damagesource
B.mood_change(BEE_OUT_FOR_ENEMIES,damagesource)
if (state == BEE_SWARM || state == BEE_BUILDING || calmed > 0)
mood_change(BEE_OUT_FOR_ENEMIES,damagesource)
/mob/living/simple_animal/bee/proc/add_plants(var/list/new_plants)
if(!new_plants || new_plants.len <= 0) return
@@ -290,6 +295,9 @@
qdel(src)
return
if (!bee_species.slow && !target)
walk(src,0)
if(stat != DEAD)
//SUFFERING FROM HIGH TOXICITY
if (((current_poison_damage - bees.len)/bees.len*100) > bee_species.toxic_threshold_death)
@@ -318,15 +326,11 @@
fighters.Add(B)
if (swarmers.len > 0) // this intent comes from a queen, and thus overrides the intents of every other bee in the swarm
for (var/datum/bee/B in bees)
B.state = BEE_SWARM
B.home = destination
home = destination
state = BEE_SWARM
mood_change(BEE_SWARM,null,destination)
if (home_goers.len > 0)
if (home_goers.len == bees.len)
state = BEE_HEADING_HOME
mood_change(BEE_HEADING_HOME)
else
var/mob/living/simple_animal/bee/B_mob = getFromPool(/mob/living/simple_animal/bee,T)
@@ -338,7 +342,7 @@
if (pollinaters.len > 0)
if (pollinaters.len == bees.len)
state = BEE_OUT_FOR_PLANTS
mood_change(BEE_OUT_FOR_PLANTS)
else
var/mob/living/simple_animal/bee/B_mob = getFromPool(/mob/living/simple_animal/bee,T)
@@ -349,7 +353,7 @@
B_mob.updateState = 1
if (fighters.len > 0)
state = BEE_OUT_FOR_ENEMIES
mood_change(BEE_OUT_FOR_ENEMIES)
//CALMING BEES
@@ -368,12 +372,7 @@
for(var/this_type in calmers)
var/obj/effect/check_effect = locate(this_type) in src.loc
if(check_effect && (check_effect.reagents.has_reagent(WATER) || check_effect.reagents.has_reagent(HOLYWATER)))
calmed = 6
if (state == BEE_OUT_FOR_ENEMIES)
src.visible_message("<span class='notice'>The bees calm down!</span>")
for(var/datum/bee/B in bees)
B.state = BEE_HEADING_HOME
state = BEE_HEADING_HOME
calming()
break
@@ -411,11 +410,25 @@
var/bio_block = min(worn_helmet.armor["bio"],30)
var/perm_block = 30-30*worn_helmet.permeability_coefficient
sting_prob -= max(bio_block,perm_block) // Is your helmet sealed? I can't get to 30% of your body.
if(prob(sting_prob))
var/brute_damage = current_physical_damage
var/tox_damage = current_poison_damage
var/direct = 1 + prob(sting_prob)
if (direct < 2)
if (prob(bee_species.pierce_chance))
brute_damage = brute_damage*bee_species.pierce_damage/100
tox_damage = tox_damage*bee_species.pierce_damage/100
else
direct = 0
if (direct)
M.apply_damage(current_physical_damage, BRUTE)
M.apply_damage(current_poison_damage, TOX)
M.visible_message("<span class='warning'>\The [src] are stinging \the [M]!</span>", "<span class='warning'>You have been stung by \the [src]!</span>")
if (direct > 1)
M.visible_message("<span class='warning'>\The [src] are stinging \the [M]!</span>", "<span class='warning'>You have been stung by \the [src]!</span>")
else
M.visible_message("<span class='warning'>\The [src] are stinging \the [M] through their protection!</span>", "<span class='warning'>You have been stung by \the [src] through your protection!</span>")
M.flash_pain()
else
M.visible_message("<span class='notice'>\The [M]'s protection shields them from \the [src]!</span>", "<span class='warning'>Your protection shields you from \the [src]!</span>")
//MAKING NOISE
if(prob(1))
@@ -434,6 +447,9 @@
if(B_mob.home != home)
continue
if(B_mob.bee_species != bee_species)
continue
//no more than 20 bees per swarm to avoid people abusing their damage
if(bees.len + B_mob.bees.len > MAX_BEES_PER_SWARM)
continue
@@ -459,27 +475,31 @@
updateDamage()
//SPREADING OUT
if(bees.len > 1 && pollinating <= 0 && prob(bees.len*2) && state != BEE_SWARM && state != BEE_HEADING_HOME)
var/mob/living/simple_animal/bee/B_mob = getFromPool(/mob/living/simple_animal/bee,get_turf(src))
var/datum/bee/B = pick(bees)
B_mob.addBee(B)
bees.Remove(B)
B_mob.calmed = calmed
B_mob.state = state
B_mob.target = target
B_mob.update_icon()
B_mob.home = home
B_mob.add_plants(visited_plants)
step_rand(B_mob)
updateDamage()
if(bees.len > 1 && pollinating <= 0 && prob(bees.len*2) && state != BEE_SWARM && state != BEE_BUILDING && state != BEE_HEADING_HOME)
var/queen = 0
for (var/single_B in bees)
if (istype(single_B,/datum/bee/queen_bee))
queen = 1
break
if (state != BEE_ROAMING || !queen)//homeless bees spread out if there's no queen among them
var/mob/living/simple_animal/bee/B_mob = getFromPool(/mob/living/simple_animal/bee,get_turf(src))
var/datum/bee/B = pick(bees)
B_mob.addBee(B)
bees.Remove(B)
B_mob.calmed = calmed
B_mob.mood_change(state,target,home)
B_mob.update_icon()
B_mob.add_plants(visited_plants)
step_rand(B_mob)
updateDamage()
//REACHING FOR MOBS
if(state == BEE_OUT_FOR_ENEMIES)
var/turf/target_turf = null
var/turf/target_turf = null//we have a target!
if(target && (target in view(src,7)) && target.stat != DEAD)
target_turf = get_turf(target)
wander = 0
else
else//no target? let's find one!
target = null
var/list/nearbyMobs = list()
for(var/mob/living/G in view(src,7))
@@ -505,11 +525,21 @@
else
for (var/datum/bee/B in bees)
B.bored++
if (B.bored > BOREDOM_TO_RETURN && B.home && !B.home.wild)
B.homeCall()
if (B.bored > BOREDOM_TO_RETURN)
if (B.home)
if (!B.home.wild)
B.homeCall()
else
mood_change(BEE_ROAMING)
for (var/datum/bee/B_single in bees)
B_single.bored = 0
break
if(target_turf)
step_to(src, target_turf)
if(target_turf)//got a target? let's move toward them now.
if (bee_species.slow)
step_to(src, target_turf)//1 step per Life()
else
walk_to(src, target, 0, 2)
if(src.loc == target_turf)
wander = 1
@@ -568,21 +598,103 @@
home.enterHive(B)
qdel(src)
else
visible_message("<span class='notice'>A swarm has lost its way.</span>")
home = null
state = BEE_ROAMING
mood_change(BEE_ROAMING)
else
state = BEE_ROAMING
visible_message("<span class='notice'>A swarm has lost its way.</span>")
home = null
mood_change(BEE_ROAMING)
//BEING LOST
if(state == BEE_ROAMING)
wander = 1
if (home && home.loc)
state = BEE_HEADING_HOME
for (var/datum/bee/B in bees)
B.home = null
home = null
//if there's a queen among us, let's gather a following
var/datum/bee/queen_bee/queen = null
for (var/D in bees)
if (istype(D,/datum/bee/queen_bee))
queen = D
if (queen)
if (bees.len < 11)
var/turf/T = get_turf(loc)
for(var/mob/living/simple_animal/bee/B in range(src,3))
if (bee_species == B.bee_species && B.state == BEE_ROAMING && B.loc != T)
step_to(B, T)//come closer, the GROUPING segment above should take care of the merging after a moment.
else
//once there's enough of us, let's find a new home
for(var/obj/machinery/apiary/A in range(src,3))
if (exile_swarm(A))
mood_change(BEE_SWARM,null,A)
A.reserve_apiary(src)
queen.colonizing = 1
update_icon()
return
//and if there isn't any decent home nearby...let's build one!
var/list/available_turfs = list()
for (var/turf/simulated/floor/T in range(src,2))
if(!T.has_dense_content() && !(locate(/obj/structure/wild_apiary) in T))
available_turfs.Add(T)
building = pick(available_turfs)
if (building)
mood_change(BEE_BUILDING)
else
for (var/datum/bee/B in bees)
B.exhaustion++
if (B.exhaustion > EXHAUSTION_TO_DIE)
adjustBruteLoss(1)
if (state == BEE_ROAMING && home && home.loc)
mood_change(BEE_HEADING_HOME)
//BUILDING A WILD APIARY
if(state == BEE_BUILDING)
wander = 0
if(building)
if (building != loc)
step_to(src, building)
else
var/obj/structure/wild_apiary/W = locate() in building
if (W)
W.work()
else
new /obj/structure/wild_apiary(loc,bee_species.prefix)
update_icon()
/mob/living/simple_animal/bee/proc/exile_swarm(var/obj/machinery/apiary/A)
if (A in apiary_reservation)//another queen has marked this one for herself
return 0
if (A.queen_bees_inside > 0 || locate(/datum/bee/queen_bee) in A.bees_outside_hive)//another queen made her way there somehow
return 0
return 1
/mob/living/simple_animal/bee/proc/mood_change(var/new_mood,var/new_target=null,var/new_home=null)
for(var/datum/bee/B in bees)
B.state = new_mood
if (new_home)
B.home = new_home
state = new_mood
if (new_target)
target = new_target
if (new_home)
home = new_home
/mob/living/simple_animal/bee/proc/calming()
calmed = 6
if (state == BEE_OUT_FOR_ENEMIES)
src.visible_message("<span class='notice'>The bees calm down!</span>")
mood_change(BEE_HEADING_HOME)
////////////////////////////////UPDATE ICON/////////////////////////////////
/mob/living/simple_animal/bee/update_icon()
@@ -632,7 +744,7 @@
if(bees.len <= 1)
gender = NEUTER
name = "[prefix]bee"
name = "[prefix][common]"
for (var/D in bees)
if (istype(D,/datum/bee/queen_bee))
name = "[prefix] queen [common]"
@@ -663,9 +775,8 @@
var/datum/bee/B = new()
B.toxic = 50
B.damage = 2
B.state = BEE_OUT_FOR_ENEMIES
state = BEE_OUT_FOR_ENEMIES
addBee(B)
mood_change(BEE_OUT_FOR_ENEMIES)
update_icon()
//BEE-IEFCASE
@@ -675,9 +786,8 @@
var/datum/bee/B = new()
B.toxic = 50
B.damage = 2
B.state = BEE_OUT_FOR_ENEMIES
addBee(B)
state = BEE_OUT_FOR_ENEMIES
mood_change(BEE_OUT_FOR_ENEMIES)
update_icon()
#undef TIME_TO_POLLINATE

View File

@@ -65,9 +65,18 @@
var/maxbodytemp = 360
var/corpse = /obj/effect/decal/cleanable/bee
//////////////////////////////////////
// VOX BEES //
//////////////////////////////////////
var/slow = 1
var/damage_coef = 1
var/toxic_coef = 1
var/pierce_chance = 0//100 = always pierce through protection
var/pierce_damage = 0//100 = deals 100 of the damage if pierce procs
var/aggressiveness = 0//100 = always aggressive when coming out of hive
//////////////////////////////////////==================================================================================================================================
// VOX BEES ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////==================================================================================================================================
/datum/bee_species/chill
name = "apis chiliverax"
@@ -94,6 +103,9 @@
maxbodytemp = 400
corpse = /obj/effect/decal/cleanable/bee/chill
damage_coef = 0
toxic_coef = 0
/////////////////BUG DATUM
/datum/bee/chill
corpse = /obj/effect/decal/cleanable/bee/chill
@@ -155,3 +167,96 @@
B.colonizing = 1//so it can start a colony if someone places it in an empty hive
addBee(B)
update_icon()
//////////////////////////////////////==================================================================================================================================
// HORNETS ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//////////////////////////////////////==================================================================================================================================
/datum/bee_species/hornet
name = "vespa crabro"
common_name = BEESPECIES_HORNET
prefix = "hornet_"
worker_product = null
queen_product = ROYALJELLY
toxic_reagents = list()
angery = 1
toxic_threshold_anger = 90//unless you're really pushing it
max_queen_inside = 1
queen_wanders = 0
bee_type = /datum/bee/hornet
queen_type = /datum/bee/queen_bee/hornet
corpse = /obj/effect/decal/cleanable/bee/hornet
slow = 0
damage_coef = 3
toxic_coef = 0.75
pierce_chance = 20
pierce_damage = 40
aggressiveness = 100
/////////////////BUG DATUM
/datum/bee/hornet
corpse = /obj/effect/decal/cleanable/bee/hornet
/datum/bee/hornet/New()
..()
species = bees_species[BEESPECIES_HORNET]
/////////////////QUEEN BUG DATUM
/datum/bee/queen_bee/hornet
corpse = /obj/effect/decal/cleanable/bee/queen_bee/hornet
/datum/bee/queen_bee/hornet/New()
..()
species = bees_species[BEESPECIES_HORNET]
/////////////////QUEEN BUG PACKET
/obj/item/queen_bee/hornet
name = "hornet queen packet"
desc = "Place her into an apiary so she can get busy. Why would you do that though? It's a terrible idea!"
icon = 'icons/obj/apiary_bees_etc.dmi'
icon_state = "hornet_queen_larvae"
w_class = W_CLASS_TINY
species = null
/obj/item/queen_bee/hornet/New()
..()
initialize()
/obj/item/queen_bee/hornet/initialize()
species = bees_species[BEESPECIES_HORNET]
/////////////////BUG CORPSES
/obj/effect/decal/cleanable/bee/hornet
name = "dead hornet"
desc = "This one stung for the last time."
icon_state = "hornet_bee_dead"
/obj/effect/decal/cleanable/bee/queen_bee/hornet
name = "dead hornet queen"
icon_state = "hornet_queen_bee_dead"
/////////////////TYPES FOR CASUAL SPAWNS
/mob/living/simple_animal/bee/adminSpawned_hornet/New(loc, var/obj/machinery/apiary/new_home)
..()
initialize()
/mob/living/simple_animal/bee/adminSpawned_hornet/initialize()
var/datum/bee/hornet/B = new()
addBee(B)
update_icon()
/mob/living/simple_animal/bee/adminSpawnedQueen_hornet/New(loc, var/obj/machinery/apiary/new_home)
..()
initialize()
/mob/living/simple_animal/bee/adminSpawnedQueen_hornet/initialize()
var/datum/bee/queen_bee/hornet/B = new()
B.colonizing = 1//so it can start a colony if someone places it in an empty hive
addBee(B)
update_icon()

View File

@@ -528,6 +528,10 @@
var/mob/living/simple_animal/hostile/slime/S = M
S.calm()
if(istype(M,/mob/living/simple_animal/bee))
var/mob/living/simple_animal/bee/B = M
B.calming()
/datum/reagent/lube
name = "Space Lube"
id = LUBE
@@ -3491,7 +3495,7 @@
reagent_state = LIQUID
nutriment_factor = 5 * REAGENTS_METABOLISM
color = "#731008" //rgb: 115, 16, 8
/datum/reagent/mustard
name = "Mustard"
id = MUSTARD
@@ -3499,7 +3503,7 @@
reagent_state = LIQUID
nutriment_factor = 3 * REAGENTS_METABOLISM
color = "#cccc33" //rgb: 204, 204, 51
/datum/reagent/relish
name = "Relish"
id = RELISH

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

After

Width:  |  Height:  |  Size: 56 KiB