mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-28 06:28:01 +01:00
Simple mob port [IDB IGNORE] (#18236)
* first adjustements * few more * construct * next * next set * next * next * next * next * next * . * last non modular set * make it compile * . * . * change that * synx * teamush * override fix * TEAMUSH * adds organ sell element * adds pick color * get rid of these chompcomments * removes chomp comments * Update gaslamp_vr.dm * zipgun * zip and synx * fixes synx * Update topic.dm * move the trash verbs * . * . * . * port * Update rakshasa_trap.dm * Update slug.dm --------- Co-authored-by: C.L. <killer65311@gmail.com> Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com>
This commit is contained in:
@@ -33,6 +33,8 @@
|
||||
var/list/mutagenic_reagents // Reagents considered uniquely 'mutagenic' by a plant.
|
||||
var/list/toxic_reagents // Reagents considered uniquely 'toxic' by a plant.
|
||||
|
||||
var/ai_mob_product = 0 //This variable determines whether or not a mob product is meant to be ai-controlled. If set to 0, mob products die without a player to control them.
|
||||
|
||||
/datum/seed/New()
|
||||
|
||||
set_trait(TRAIT_IMMUTABLE, 0) // If set, plant will never mutate. If -1, plant is highly mutable.
|
||||
|
||||
@@ -42,3 +42,76 @@
|
||||
|
||||
/datum/seed/gnomes
|
||||
harvest_sound = 'sound/items/hooh.ogg'
|
||||
|
||||
/datum/seed/pitcher_plant //Pitcher plant
|
||||
name = PLANT_PITCHERPLANT
|
||||
seed_name = PLANT_PITCHERPLANT
|
||||
seed_noun = "pits"
|
||||
display_name = "pitcher shoots"
|
||||
can_self_harvest = 1
|
||||
apply_color_to_mob = FALSE
|
||||
has_mob_product = /mob/living/simple_mob/vore/pitcher_plant
|
||||
ai_mob_product = 1
|
||||
|
||||
/datum/seed/pitcher_plant/New() //No custom icons yet. No spread trait yet even though pitcher fruit can be planted outside of a tray as I've not tied that to hydroponics code.
|
||||
..()
|
||||
set_trait(TRAIT_IMMUTABLE,1)
|
||||
set_trait(TRAIT_CARNIVOROUS,1)
|
||||
set_trait(TRAIT_MATURATION,8)
|
||||
set_trait(TRAIT_PRODUCTION,6)
|
||||
set_trait(TRAIT_WATER_CONSUMPTION,6)
|
||||
set_trait(TRAIT_YIELD,1)
|
||||
set_trait(TRAIT_POTENCY,10)
|
||||
set_trait(TRAIT_PRODUCT_ICON,"corn")
|
||||
set_trait(TRAIT_PRODUCT_COLOUR,"#a839a2")
|
||||
set_trait(TRAIT_PLANT_COLOUR,"#5b6f43")
|
||||
set_trait(TRAIT_PLANT_ICON,"ambrosia")
|
||||
|
||||
// Tea plants/variants.
|
||||
/datum/seed/tea
|
||||
name = PLANT_TEA
|
||||
seed_name = PLANT_TEA
|
||||
display_name = "tea plant"
|
||||
chems = list(REAGENT_ID_TEAMUSH = list(3,10))
|
||||
mutants = null
|
||||
kitchen_tag = PLANT_TEA
|
||||
|
||||
/datum/seed/tea/New()
|
||||
..()
|
||||
set_trait(TRAIT_HARVEST_REPEAT,1)
|
||||
set_trait(TRAIT_MATURATION,5)
|
||||
set_trait(TRAIT_PRODUCTION,5)
|
||||
set_trait(TRAIT_YIELD,6)
|
||||
set_trait(TRAIT_POTENCY,20)
|
||||
set_trait(TRAIT_PRODUCT_ICON,"tea")
|
||||
set_trait(TRAIT_PRODUCT_COLOUR,"#b7e496")
|
||||
set_trait(TRAIT_PLANT_COLOUR,"#b7e496")
|
||||
set_trait(TRAIT_PLANT_ICON,"bush4")
|
||||
set_trait(TRAIT_IDEAL_HEAT, 298)
|
||||
set_trait(TRAIT_IDEAL_LIGHT, 7)
|
||||
set_trait(TRAIT_WATER_CONSUMPTION, 6)
|
||||
set_trait(TRAIT_NUTRIENT_CONSUMPTION, 0.25)
|
||||
|
||||
/datum/seed/hardlightseed //WIP: havent ported the mob and such yet, best someone more keen on these mobs does it - Jack
|
||||
name = PLANT_NULLHARDLIGHT
|
||||
seed_name = "Biomechanical Hardlight generator seed"
|
||||
display_name = "Biomechanical Hardlight stem"
|
||||
mutants = null
|
||||
can_self_harvest = 1
|
||||
has_mob_product = /mob/living/simple_mob/animal/synx/ai/pet/holo
|
||||
ai_mob_product = 1
|
||||
|
||||
/datum/seed/hardlightseed/New()
|
||||
..()
|
||||
set_trait(TRAIT_IMMUTABLE,1) //Normal genetics wont be able to do much with the mechanical parts, its more a machine than a real plant
|
||||
set_trait(TRAIT_MATURATION,1)
|
||||
set_trait(TRAIT_PRODUCTION,1)
|
||||
set_trait(TRAIT_YIELD,1)
|
||||
set_trait(TRAIT_POTENCY,1)
|
||||
set_trait(TRAIT_PRODUCT_ICON,"alien4")
|
||||
set_trait(TRAIT_PRODUCT_COLOUR,"#00FFFF")
|
||||
set_trait(TRAIT_PLANT_COLOUR,"#00FFFF")
|
||||
set_trait(TRAIT_PLANT_ICON,"alien4") //spooky pods
|
||||
set_trait(TRAIT_IDEAL_HEAT, 283)
|
||||
set_trait(TRAIT_NUTRIENT_CONSUMPTION, 0)
|
||||
set_trait(TRAIT_WATER_CONSUMPTION, 0)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// The following procs are used to grab players for mobs produced by a seed (mostly for dionaea).
|
||||
/datum/seed/proc/handle_living_product(var/mob/living/host)
|
||||
|
||||
if(!host || !istype(host)) return
|
||||
if(!host || !istype(host) || ai_mob_product) return
|
||||
|
||||
if(apply_color_to_mob)
|
||||
host.color = traits[TRAIT_PRODUCT_COLOUR]
|
||||
|
||||
@@ -363,3 +363,9 @@ GLOBAL_LIST_BOILERPLATE(all_seed_packs, /obj/item/seeds)
|
||||
|
||||
/obj/item/seeds/megashroom
|
||||
seed_type = PLANT_MEGAM
|
||||
|
||||
/obj/item/seeds/teaseed
|
||||
seed_type = PLANT_TEA
|
||||
|
||||
/obj/item/seeds/pitcherseed
|
||||
seed_type = PLANT_PITCHERPLANT
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#define AGE_MOD_MAX 10 // Define for age_mod sanity check as a define to allow for easy tweaking.
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics
|
||||
name = "hydroponics tray"
|
||||
desc = "A tray usually full of fluid for growing plants."
|
||||
@@ -30,6 +32,7 @@
|
||||
var/toxins = 0 // Toxicity in the tray?
|
||||
var/mutation_level = 0 // When it hits 100, the plant mutates.
|
||||
var/tray_light = 1 // Supplied lighting.
|
||||
var/age_mod = 0 // Variable for chems which speed up plant growth. On average, every 3 age mod reduces growing time by 2.5 minutes.
|
||||
|
||||
// Mechanical concerns.
|
||||
var/health = 0 // Plant health.
|
||||
@@ -133,6 +136,10 @@
|
||||
REAGENT_ID_MUTAGEN = 15
|
||||
)
|
||||
|
||||
var/static/list/age_reagents = list(
|
||||
REAGENT_ID_PITCHERNECTAR = 1
|
||||
)
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/AltClick(var/mob/living/user)
|
||||
if(!istype(user))
|
||||
return
|
||||
@@ -308,6 +315,9 @@
|
||||
else if(toxic_reagents[R.id])
|
||||
toxins += toxic_reagents[R.id] * reagent_total
|
||||
|
||||
if(age_reagents[R.id])
|
||||
age_mod += age_reagents[R.id] * reagent_total
|
||||
|
||||
//Handle some general level adjustments. These values are independent of plants existing.
|
||||
if(weedkiller_reagents[R.id])
|
||||
weedlevel -= weedkiller_reagents[R.id] * reagent_total
|
||||
@@ -359,6 +369,7 @@
|
||||
age = 0
|
||||
sampled = 0
|
||||
mutation_mod = 0
|
||||
age_mod = 0
|
||||
|
||||
check_health()
|
||||
return
|
||||
@@ -377,6 +388,7 @@
|
||||
age = 0
|
||||
yield_mod = 0
|
||||
mutation_mod = 0
|
||||
age_mod = 0
|
||||
|
||||
to_chat(user, span_filter_notice("You remove the dead plant."))
|
||||
lastproduce = 0
|
||||
@@ -396,6 +408,7 @@
|
||||
|
||||
dead = 0
|
||||
age = 0
|
||||
age_mod = 0
|
||||
health = seed.get_trait(TRAIT_ENDURANCE)
|
||||
lastcycle = world.time
|
||||
harvest = 0
|
||||
@@ -472,6 +485,7 @@
|
||||
pestlevel = max(0,min(pestlevel,10))
|
||||
weedlevel = max(0,min(weedlevel,10))
|
||||
toxins = max(0,min(toxins,10))
|
||||
age_mod = max(0,min(age_mod,AGE_MOD_MAX)) // age_mod sanity check
|
||||
|
||||
/obj/machinery/portable_atmospherics/hydroponics/proc/mutate_species()
|
||||
|
||||
@@ -707,3 +721,5 @@
|
||||
closed_system = !closed_system
|
||||
to_chat(user, span_filter_notice("You [closed_system ? "close" : "open"] the tray's lid."))
|
||||
update_icon()
|
||||
|
||||
#undef AGE_MOD_MAX
|
||||
|
||||
@@ -38,7 +38,11 @@
|
||||
return
|
||||
|
||||
// Advance plant age.
|
||||
if(prob(30)) age += 1 * HYDRO_SPEED_MULTIPLIER
|
||||
if(prob(30))
|
||||
age += 1 * HYDRO_SPEED_MULTIPLIER
|
||||
if(age_mod >= 1) //Age reagents double the speed of plant growth in sufficient quantities
|
||||
age += 1 * HYDRO_SPEED_MULTIPLIER
|
||||
age_mod -= 1
|
||||
|
||||
//Highly mutable plants have a chance of mutating every tick.
|
||||
if(seed.get_trait(TRAIT_IMMUTABLE) == -1)
|
||||
|
||||
Reference in New Issue
Block a user