tiggersgonnaeatme

This commit is contained in:
Aurorablade
2016-03-23 17:31:29 -04:00
parent ebd6214b42
commit db887489d3
39 changed files with 215 additions and 131 deletions
@@ -5,6 +5,22 @@
icon_state = "sheet-hide"
origin_tech = ""
var/global/list/datum/stack_recipe/human_recipes = list( \
new/datum/stack_recipe("bloated human costume", /obj/item/clothing/suit/bloated_human, 5, on_floor = 1), \
new/datum/stack_recipe("bloated human costume head", /obj/item/clothing/head/human_head, 5, on_floor = 1), \
)
/obj/item/stack/sheet/animalhide/human/New(var/loc, var/amount=null)
recipes = human_recipes
return ..()
/obj/item/stack/sheet/animalhide/generic
name = "generic skin"
desc = "A piece of generic skin."
singular_name = "generic skin piece"
icon_state = "sheet-hide"
origin_tech = null
/obj/item/stack/sheet/animalhide/corgi
name = "corgi hide"
desc = "The by-product of corgi farming."
@@ -51,6 +51,7 @@ var/global/list/datum/stack_recipe/metal_recipes = list ( \
new/datum/stack_recipe("wall girders", /obj/structure/girder, 2, time = 50, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("machine frame", /obj/machinery/constructable_frame/machine_frame, 5, time = 25, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("turret frame", /obj/machinery/porta_turret_construct, 5, time = 25, one_per_turf = 1, on_floor = 1), \
new/datum/stack_recipe("meatspike frame", /obj/structure/kitchenspike_frame, 5, time = 25, one_per_turf = 1, on_floor = 1), \
null, \
new/datum/stack_recipe_list("airlock assemblies", list( \
new/datum/stack_recipe("standard airlock assembly", /obj/structure/door_assembly, 4, time = 50, one_per_turf = 1, on_floor = 1), \
+114 -36
View File
@@ -1,5 +1,33 @@
//////Kitchen Spike
/obj/structure/kitchenspike_frame
name = "meatspike frame"
icon = 'icons/obj/kitchen.dmi'
icon_state = "spikeframe"
desc = "The frame of a meat spike."
density = 1
anchored = 0
/obj/structure/kitchenspike_frame/attackby(obj/item/I, mob/user, params)
add_fingerprint(user)
if(istype(I, /obj/item/weapon/wrench))
if(anchored)
user << "<span class='notice'>You unwrench [src] from the floor.</span>"
anchored = 0
else
user << "<span class='notice'>You wrench [src] into place.</span>"
anchored = 1
else if(istype(I, /obj/item/stack/rods))
var/obj/item/stack/rods/R = I
if(R.get_amount() >= 4)
R.use(4)
user << "<span class='notice'>You add spikes to the frame.</span>"
new /obj/structure/kitchenspike(src.loc,)
add_fingerprint(user)
qdel(src)
/obj/structure/kitchenspike
name = "a meat spike"
icon = 'icons/obj/kitchen.dmi'
@@ -7,54 +35,104 @@
desc = "A spike for collecting meat from animals."
density = 1
anchored = 1
var/meat = 0
var/occupied
var/meat_type
var/victim_name = "corpse"
buckle_lying = 0
can_buckle = 1
/obj/structure/kitchenspike/attackby(obj/item/weapon/grab/G as obj, mob/user as mob)
if(istype(G, /obj/item/weapon/crowbar))
if(!src.buckled_mob)
playsound(loc, 'sound/items/Crowbar.ogg', 100, 1)
if(do_after(user, 20, target = src))
user << "<span class='notice'>You pry the spikes out of the frame.</span>"
new /obj/item/stack/rods(loc, 4)
new /obj/structure/kitchenspike_frame(src.loc,)
add_fingerprint(user)
qdel(src)
else
user << "<span class='notice'>You can't do that while something's on the spike!</span>"
return
if(!istype(G, /obj/item/weapon/grab) || !G.affecting)
return
if(occupied)
if(buckled_mob)
user << "<span class = 'danger'>The spike already has something on it, finish collecting its meat first!</span>"
else
if(spike(G.affecting))
visible_message("<span class = 'danger'>[user] has forced [G.affecting] onto the spike, killing them instantly!</span>")
qdel(G.affecting)
qdel(G)
else
user << "<span class='danger'>They are too big for the spike, try something smaller!</span>"
if(istype(G.affecting, /mob/living/))
if(!buckled_mob)
if(do_mob(src, src, 120))
if(spike(G.affecting))
qdel(G)
user << "<span class='danger'>You can't use that on the spike!</span>"
return
/obj/structure/kitchenspike/proc/spike(var/mob/living/victim)
if(!istype(victim))
return
if(istype(victim, /mob/living/carbon/human))
var/mob/living/carbon/human/H = victim
if(!H.species.is_small)
return 0
meat_type = H.species.meat_type
icon_state = "spikebloody"
else if(istype(victim, /mob/living/carbon/alien))
meat_type = /obj/item/weapon/reagent_containers/food/snacks/xenomeat
icon_state = "spikebloodygreen"
else
return 0
victim_name = victim.name
occupied = 1
meat = 5
if(buckled_mob) //to prevent spam/queing up attacks
return 0
if(victim.buckled)
return 0
var/mob/living/H = victim
playsound(src.loc, "sound/effects/splat.ogg", 25, 1)
H.visible_message("<span class='danger'>[src] slams [victim] onto the meat spike!</span>", "<span class='userdanger'>[src] slams you onto the meat spike!</span>", "<span class='italics'>You hear a squishy wet noise.</span>")
H.loc = src.loc
H.emote("scream")
if(istype(H, /mob/living/carbon/human)) //So you don't get human blood when you spike a giant spidere
var/turf/simulated/pos = get_turf(H)
pos.add_blood_floor(H)
H.adjustBruteLoss(30)
H.buckled = src
H.dir = 2
buckled_mob = H
var/matrix/m180 = matrix()
m180.Turn(180)
animate(H, transform = m180, time = 3)
H.pixel_y = H.get_standard_pixel_y_offset(180)
return 1
/obj/structure/kitchenspike/attack_hand(mob/user as mob)
if(..() || !occupied)
return
meat--
new meat_type(get_turf(src))
if(src.meat > 1)
user << "You remove some meat from \the [victim_name]."
else if(src.meat == 1)
user << "You remove the last piece of meat from \the [victim_name]!"
icon_state = "spike"
occupied = 0
/obj/structure/kitchenspike/user_buckle_mob(mob/living/M, mob/living/user) //Don't want them getting put on the rack other than by spiking
return
/obj/structure/kitchenspike/user_unbuckle_mob(mob/living/carbon/human/user)
if(buckled_mob && buckled_mob.buckled == src)
var/mob/living/M = buckled_mob
if(M != user)
M.visible_message(\
"[user.name] tries to pull [M.name] free of the [src]!",\
"<span class='notice'>[user.name] is trying to pull you off of [src], opening up fresh wounds!</span>",\
"<span class='italics'>You hear a squishy wet noise.</span>")
if(!do_after(user, 300, target = src))
if(M && M.buckled)
M.visible_message(\
"[user.name] fails to free [M.name]!",\
"<span class='notice'>[user.name] fails to pull you off of [src].</span>")
return
else
M.visible_message(\
"<span class='warning'>[M.name] struggles to break free from the [src]!</span>",\
"<span class='notice'>You struggle to break free from the [src], exacerbating your wounds! (Stay still for two minutes.)</span>",\
"<span class='italics'>You hear a wet squishing noise..</span>")
M.adjustBruteLoss(30)
if(!do_after(M, 1200, target = src))
if(M && M.buckled)
M << "<span class='warning'>You fail to free yourself!</span>"
return
if(!M.buckled)
return
var/matrix/m180 = matrix(M.transform)
m180.Turn(180)
animate(M, transform = m180, time = 3)
M.pixel_y = M.get_standard_pixel_y_offset(180)
M.adjustBruteLoss(30)
src.visible_message(text("<span class='danger'>[M] falls free of the [src]!</span>"))
unbuckle_mob()
M.emote("scream")
M.AdjustWeakened(10)