mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-27 07:08:55 +01:00
Merge pull request #1809 from Darlantanis/RacoonsAndImplants
Backup Implanter, Raccoons
This commit is contained in:
@@ -120,6 +120,12 @@
|
||||
searchedby += user.ckey
|
||||
I.forceMove(get_turf(src))
|
||||
to_chat(H,"<span class='notice'>You found \a [I]!</span>")
|
||||
//CHOMPedit begin
|
||||
var/disturbed_sleep = rand(1,100) //spawning of mobs, for now only the trash panda.
|
||||
if(disturbed_sleep <= 5)
|
||||
new /mob/living/simple_mob/animal/passive/raccoon_ch(get_turf(user), name)
|
||||
visible_message("A raccoon jumps out of the trash!.")
|
||||
//CHOMPedit end
|
||||
|
||||
else
|
||||
return ..()
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
//raccoon
|
||||
/mob/living/simple_mob/animal/passive/raccoon_ch
|
||||
name = "raccoon"
|
||||
desc = "A raccoon, also known as a trash panda."
|
||||
tt_desc = "E purgamentum raccoonus"
|
||||
icon = 'icons/mob/animal_ch.dmi'
|
||||
icon_state = "raccoon"
|
||||
item_state = "raccoon"
|
||||
icon_living = "raccoon"
|
||||
icon_dead = "raccoon_dead"
|
||||
|
||||
ai_holder_type = /datum/ai_holder/simple_mob/passive/raccoon_ch
|
||||
say_list_type = /datum/say_list/raccoon_ch
|
||||
|
||||
see_in_dark = 6
|
||||
|
||||
response_help = "pets"
|
||||
response_disarm = "gently pushes aside"
|
||||
response_harm = "kicks"
|
||||
|
||||
min_oxy = 16 //Require atleast 16kPA oxygen
|
||||
minbodytemp = 223 //Below -50 Degrees Celsius
|
||||
maxbodytemp = 323 //Above 50 Degrees Celsius
|
||||
|
||||
meat_amount = 1
|
||||
meat_type = /obj/item/weapon/reagent_containers/food/snacks/meat
|
||||
|
||||
|
||||
/datum/say_list/raccoon_ch
|
||||
speak = list("HSSSSS")
|
||||
emote_see = list("shakes their head", "shivers","grooms self", "nibbles on some trash")
|
||||
emote_hear = list("purrs")
|
||||
|
||||
/datum/ai_holder/simple_mob/passive/raccoon_ch
|
||||
flee_when_dying = TRUE
|
||||
dying_threshold = 0.9
|
||||
speak_chance = 1
|
||||
@@ -0,0 +1,69 @@
|
||||
//Infinite use implanter. Feel free to make proper sprites for it or whatnot.
|
||||
//I guess this would make more sense as a machine but there's all that extra machine code it doesn't need.
|
||||
/obj/structure/backup_implanter_ch
|
||||
name = "\improper Backup implanter"
|
||||
icon = 'icons/obj/computer3.dmi'
|
||||
icon_state = "laptop-gun"
|
||||
desc = "After discovering clients constantly lacked staff to replace implants, Vey-Medical designed this version capable of creating implants on demand."
|
||||
anchored = TRUE
|
||||
|
||||
/obj/structure/backup_implanter_ch/New()
|
||||
..()
|
||||
germ_level = 0
|
||||
|
||||
//Click to get implant.
|
||||
/obj/structure/backup_implanter_ch/attack_hand(mob/user)
|
||||
..()
|
||||
|
||||
if(!istype(user, /mob/living/carbon))
|
||||
return
|
||||
|
||||
if(user)
|
||||
user.visible_message("<span class='notice'>[user] is injecting a backup implant into [user].</span>")
|
||||
|
||||
user.setClickCooldown(DEFAULT_QUICK_COOLDOWN)
|
||||
|
||||
if(do_after(user, 2.5 SECONDS))
|
||||
|
||||
if(user && src)
|
||||
|
||||
//Create the actual implant.
|
||||
var/obj/item/weapon/implant/backup/imp = new(src.contents)
|
||||
imp.germ_level = 0
|
||||
|
||||
//Implant the implant.
|
||||
if(imp.handle_implant(user, user.zone_sel.selecting))
|
||||
imp.post_implant(user)
|
||||
add_attack_logs(user, user, "Implanted backup implant")
|
||||
user.visible_message("<span class='notice'>[user] has been backup implanted by [user].</span>")
|
||||
|
||||
//If implanting somehow fails, delete the implant.
|
||||
else
|
||||
qdel(imp)
|
||||
|
||||
/obj/structure/backup_implanter_ch/attackby(obj/item/O, mob/user)
|
||||
if(O.is_wrench())
|
||||
|
||||
if(anchored)
|
||||
to_chat(user, "<span class='notice'>You start to unwrench the implanter.</span>")
|
||||
playsound(src, O.usesound, 50, 1)
|
||||
|
||||
if(do_after(user, 15 * O.toolspeed))
|
||||
to_chat(user, "<span class='notice'>You unwrench the implanter.</span>")
|
||||
anchored = FALSE
|
||||
return
|
||||
else
|
||||
return
|
||||
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You start to wrench the implanter into place.</span>")
|
||||
playsound(src, O.usesound, 50, 1)
|
||||
|
||||
if(do_after(user, 15 * O.toolspeed))
|
||||
|
||||
to_chat(user, "<span class='notice'>You wrench the implanter into place.</span>")
|
||||
anchored = TRUE
|
||||
return
|
||||
else
|
||||
return
|
||||
..()
|
||||
Reference in New Issue
Block a user