mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
[READY] SNAKES! (#34724)
* actual phobia created * (LAST ATTEMPT) Adds Snakes 🆑 Togopal add: Snakes! They hunt vermin on the station! add: They can be purchased in cargo. /🆑 Mice can be a problem in late round random events, and I figured releasing a bunch of snakes in maintenance would be a more long-term solution than constantly running around with a crowbar when you hear them. Now with updated sprites! (I apologize heavily for uploading this three times. I was unaware I was using an older fork, as this was my first attempt at modifying the code.) * curator gets trauma! and fixes to snek trauma * fixes the travis error silly frog * Reduces the cost of a normal snake crate in Cargo. Adds retaliation to snakes upon being attacked, removes venom from regular snakes. I A * quick fix * quick fix 2 * fixes the cargo contains = list * go away TRAVIS * changes the name of the snake cargo crate of regular snakes to avoid confusion * Updates how some snake mechanics works Makes them actually retaliate, code is still sort of buggy though * Some orange fixes * Fix snakes on this motherfucking plane * The thing oranges said
This commit is contained in:
@@ -11,7 +11,7 @@ SUBSYSTEM_DEF(traumas)
|
|||||||
#define PHOBIA_FILE "phobia.json"
|
#define PHOBIA_FILE "phobia.json"
|
||||||
|
|
||||||
/datum/controller/subsystem/traumas/Initialize()
|
/datum/controller/subsystem/traumas/Initialize()
|
||||||
phobia_types = list("spiders", "space", "security", "clowns", "greytide", "lizards", "skeletons")
|
phobia_types = list("spiders", "space", "security", "clowns", "greytide", "lizards", "skeletons", "snakes")
|
||||||
|
|
||||||
phobia_words = list("spiders" = strings(PHOBIA_FILE, "spiders"),
|
phobia_words = list("spiders" = strings(PHOBIA_FILE, "spiders"),
|
||||||
"space" = strings(PHOBIA_FILE, "space"),
|
"space" = strings(PHOBIA_FILE, "space"),
|
||||||
@@ -20,11 +20,13 @@ SUBSYSTEM_DEF(traumas)
|
|||||||
"greytide" = strings(PHOBIA_FILE, "greytide"),
|
"greytide" = strings(PHOBIA_FILE, "greytide"),
|
||||||
"lizards" = strings(PHOBIA_FILE, "lizards"),
|
"lizards" = strings(PHOBIA_FILE, "lizards"),
|
||||||
"skeletons" = strings(PHOBIA_FILE, "skeletons"),
|
"skeletons" = strings(PHOBIA_FILE, "skeletons"),
|
||||||
|
"snakes" = strings(PHOBIA_FILE, "snakes")
|
||||||
)
|
)
|
||||||
|
|
||||||
phobia_mobs = list("spiders" = typecacheof(list(/mob/living/simple_animal/hostile/poison/giant_spider)),
|
phobia_mobs = list("spiders" = typecacheof(list(/mob/living/simple_animal/hostile/poison/giant_spider)),
|
||||||
"security" = typecacheof(list(/mob/living/simple_animal/bot/secbot)),
|
"security" = typecacheof(list(/mob/living/simple_animal/bot/secbot)),
|
||||||
"lizards" = typecacheof(list(/mob/living/simple_animal/hostile/lizard))
|
"lizards" = typecacheof(list(/mob/living/simple_animal/hostile/lizard)),
|
||||||
|
"snakes" = typecacheof(list(/mob/living/simple_animal/hostile/retaliate/poison/snake))
|
||||||
)
|
)
|
||||||
|
|
||||||
phobia_objs = list("spiders" = typecacheof(list(/obj/structure/spider)),
|
phobia_objs = list("spiders" = typecacheof(list(/obj/structure/spider)),
|
||||||
|
|||||||
@@ -1035,6 +1035,14 @@
|
|||||||
contains = list(/mob/living/simple_animal/hostile/retaliate/goat)
|
contains = list(/mob/living/simple_animal/hostile/retaliate/goat)
|
||||||
crate_name = "goat crate"
|
crate_name = "goat crate"
|
||||||
|
|
||||||
|
/datum/supply_pack/organic/critter/snake
|
||||||
|
name = "Snake Crate"
|
||||||
|
cost = 3000
|
||||||
|
contains = list(/mob/living/simple_animal/hostile/retaliate/poison/snake,
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/snake,
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/snake)
|
||||||
|
crate_name = "snake crate"
|
||||||
|
|
||||||
/datum/supply_pack/organic/critter/chick
|
/datum/supply_pack/organic/critter/chick
|
||||||
name = "Chicken Crate"
|
name = "Chicken Crate"
|
||||||
cost = 2000
|
cost = 2000
|
||||||
|
|||||||
@@ -152,7 +152,7 @@ Curator
|
|||||||
return
|
return
|
||||||
|
|
||||||
H.grant_all_languages(omnitongue=TRUE)
|
H.grant_all_languages(omnitongue=TRUE)
|
||||||
|
H.gain_trauma(/datum/brain_trauma/mild/phobia, FALSE, "snakes") //why does it have to be snakes...
|
||||||
/*
|
/*
|
||||||
Lawyer
|
Lawyer
|
||||||
*/
|
*/
|
||||||
|
|||||||
61
code/modules/mob/living/simple_animal/friendly/snake.dm
Normal file
61
code/modules/mob/living/simple_animal/friendly/snake.dm
Normal file
@@ -0,0 +1,61 @@
|
|||||||
|
/mob/living/simple_animal/hostile/retaliate/poison
|
||||||
|
var/poison_per_bite = 0
|
||||||
|
var/poison_type = "toxin"
|
||||||
|
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/AttackingTarget()
|
||||||
|
. = ..()
|
||||||
|
if(. && isliving(target))
|
||||||
|
var/mob/living/L = target
|
||||||
|
if(L.reagents && !poison_per_bite == 0)
|
||||||
|
L.reagents.add_reagent(poison_type, poison_per_bite)
|
||||||
|
return .
|
||||||
|
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/snake
|
||||||
|
name = "snake"
|
||||||
|
desc = "A slithery snake. These legless reptiles are the bane of mice and adventurers alike."
|
||||||
|
icon_state = "snake"
|
||||||
|
icon_living = "snake"
|
||||||
|
icon_dead = "snake_dead"
|
||||||
|
speak_emote = list("hisses")
|
||||||
|
health = 20
|
||||||
|
maxHealth = 20
|
||||||
|
attacktext = "bites"
|
||||||
|
melee_damage_lower = 5
|
||||||
|
melee_damage_upper = 6
|
||||||
|
response_help = "pets"
|
||||||
|
response_disarm = "shoos"
|
||||||
|
response_harm = "steps on"
|
||||||
|
faction = list("hostile")
|
||||||
|
ventcrawler = VENTCRAWLER_ALWAYS
|
||||||
|
density = FALSE
|
||||||
|
pass_flags = PASSTABLE | PASSMOB
|
||||||
|
mob_size = MOB_SIZE_SMALL
|
||||||
|
gold_core_spawnable = FRIENDLY_SPAWN
|
||||||
|
obj_damage = 0
|
||||||
|
environment_smash = ENVIRONMENT_SMASH_NONE
|
||||||
|
|
||||||
|
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/snake/ListTargets(atom/the_target)
|
||||||
|
. = oview(vision_range, targets_from) //get list of things in vision range
|
||||||
|
var/list/living_mobs = list()
|
||||||
|
var/list/mice = list()
|
||||||
|
for (var/HM in .)
|
||||||
|
//Yum a tasty mouse
|
||||||
|
if(istype(HM, /mob/living/simple_animal/mouse))
|
||||||
|
mice += HM
|
||||||
|
if(isliving(HM))
|
||||||
|
living_mobs += HM
|
||||||
|
|
||||||
|
// if no tasty mice to chase, lets chase any living mob enemies in our vision range
|
||||||
|
if(length(mice) == 0)
|
||||||
|
//Filter living mobs (in range mobs) by those we consider enemies (retaliate behaviour)
|
||||||
|
return living_mobs & enemies
|
||||||
|
return mice
|
||||||
|
|
||||||
|
/mob/living/simple_animal/hostile/retaliate/poison/snake/AttackingTarget()
|
||||||
|
if(istype(target, /mob/living/simple_animal/mouse))
|
||||||
|
visible_message("<span class='notice'>[name] consumes [target] in a single gulp!</span>", "<span class='notice'>You consume [target] in a single gulp!</span>")
|
||||||
|
QDEL_NULL(target)
|
||||||
|
adjustBruteLoss(-2)
|
||||||
|
else
|
||||||
|
return ..()
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 193 KiB After Width: | Height: | Size: 199 KiB |
@@ -59,5 +59,18 @@
|
|||||||
"calcium",
|
"calcium",
|
||||||
"the ride never ends",
|
"the ride never ends",
|
||||||
"doot"
|
"doot"
|
||||||
|
],
|
||||||
|
|
||||||
|
"snakes": [
|
||||||
|
"snake",
|
||||||
|
"snek",
|
||||||
|
"hiss",
|
||||||
|
"snecko",
|
||||||
|
"boop",
|
||||||
|
"slither",
|
||||||
|
"fangs",
|
||||||
|
"anaconda",
|
||||||
|
"viper",
|
||||||
|
"python"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -1881,6 +1881,7 @@
|
|||||||
#include "code\modules\mob\living\simple_animal\friendly\penguin.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\penguin.dm"
|
||||||
#include "code\modules\mob\living\simple_animal\friendly\pet.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\pet.dm"
|
||||||
#include "code\modules\mob\living\simple_animal\friendly\sloth.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\sloth.dm"
|
||||||
|
#include "code\modules\mob\living\simple_animal\friendly\snake.dm"
|
||||||
#include "code\modules\mob\living\simple_animal\friendly\drone\_drone.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\drone\_drone.dm"
|
||||||
#include "code\modules\mob\living\simple_animal\friendly\drone\drones_as_items.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\drone\drones_as_items.dm"
|
||||||
#include "code\modules\mob\living\simple_animal\friendly\drone\extra_drone_types.dm"
|
#include "code\modules\mob\living\simple_animal\friendly\drone\extra_drone_types.dm"
|
||||||
|
|||||||
Reference in New Issue
Block a user