mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-22 12:29:46 +01:00
Merge remote-tracking branch 'bay12-upstream/master' into development
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
default_material = "wood"
|
||||
force_divisor = 1.1 // 22 when wielded with weight 20 (steel)
|
||||
unwielded_force_divisor = 0.7 // 15 when unwielded based on above.
|
||||
slot_flags = SLOT_BACK
|
||||
|
||||
//Predefined materials go here.
|
||||
/obj/item/weapon/material/twohanded/baseballbat/metal/New(var/newloc)
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
force_divisor = 0.1 // 6 when wielded with hardness 60 (steel)
|
||||
thrown_force_divisor = 0.25 // 5 when thrown with weight 20 (steel)
|
||||
var/loaded //Descriptive string for currently loaded food object.
|
||||
var/scoop_food = 1
|
||||
|
||||
/obj/item/weapon/material/kitchen/utensil/New()
|
||||
..()
|
||||
@@ -37,14 +38,19 @@
|
||||
if (reagents.total_volume > 0)
|
||||
reagents.trans_to_mob(M, reagents.total_volume, CHEM_INGEST)
|
||||
if(M == user)
|
||||
if(!M.can_eat(loaded))
|
||||
return
|
||||
M.visible_message("<span class='notice'>\The [user] eats some [loaded] from \the [src].</span>")
|
||||
else
|
||||
user.visible_message("<span class='warning'>\The [user] begins to feed \the [M]!</span>")
|
||||
if(!(M.can_force_feed(user, loaded) && do_mob(user, M, 5 SECONDS)))
|
||||
return
|
||||
M.visible_message("<span class='notice'>\The [user] feeds some [loaded] to \the [M] with \the [src].</span>")
|
||||
playsound(M.loc,'sound/items/eatfood.ogg', rand(10,40), 1)
|
||||
overlays.Cut()
|
||||
return
|
||||
else
|
||||
user << "<span class='warning'>You don't have anything on \the [src].</span>" //if we have help intent and no food scooped up DON'T STAB OURSELVES WITH THE FORK GODDAMNIT
|
||||
user << "<span class='warning'>You don't have anything on \the [src].</span>" //if we have help intent and no food scooped up DON'T STAB OURSELVES WITH THE FORK
|
||||
return
|
||||
|
||||
/obj/item/weapon/material/kitchen/utensil/fork
|
||||
@@ -75,6 +81,18 @@
|
||||
desc = "A knife for eating with. Can cut through any food."
|
||||
icon_state = "knife"
|
||||
force_divisor = 0.1 // 6 when wielded with hardness 60 (steel)
|
||||
scoop_food = 0
|
||||
|
||||
// Identical to the tactical knife but nowhere near as stabby.
|
||||
// Kind of like the toy esword compared to the real thing.
|
||||
/obj/item/weapon/material/kitchen/utensil/knife/boot
|
||||
name = "boot knife"
|
||||
desc = "A small fixed-blade knife for putting inside a boot."
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "tacknife"
|
||||
item_state = "knife"
|
||||
applies_material_colour = 0
|
||||
unbreakable = 1
|
||||
|
||||
/obj/item/weapon/material/kitchen/utensil/knife/attack(target as mob, mob/living/user as mob)
|
||||
if ((CLUMSY in user.mutations) && prob(50))
|
||||
@@ -83,13 +101,6 @@
|
||||
return
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/material/kitchen/utensil/knife/attack(target as mob, mob/living/user as mob)
|
||||
if ((CLUMSY in user.mutations) && prob(50))
|
||||
user << "<span class='warning'>You somehow managed to cut yourself with \the [src].</span>"
|
||||
user.take_organ_damage(20)
|
||||
return
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/material/kitchen/utensil/knife/plastic
|
||||
default_material = "plastic"
|
||||
|
||||
@@ -109,7 +120,8 @@
|
||||
/obj/item/weapon/material/kitchen/rollingpin/attack(mob/living/M as mob, mob/living/user as mob)
|
||||
if ((CLUMSY in user.mutations) && prob(50))
|
||||
user << "<span class='warning'>\The [src] slips out of your hand and hits your head.</span>"
|
||||
user.drop_from_inventory(src)
|
||||
user.take_organ_damage(10)
|
||||
user.Paralyse(2)
|
||||
return
|
||||
return ..()
|
||||
return ..()
|
||||
|
||||
@@ -62,12 +62,6 @@
|
||||
attack_verb = list("slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
|
||||
unbreakable = 1
|
||||
|
||||
/obj/item/weapon/material/knife/suicide_act(mob/user)
|
||||
viewers(user) << pick("\red <b>[user] is slitting \his wrists with the [src.name]! It looks like \he's trying to commit suicide.</b>", \
|
||||
"\red <b>[user] is slitting \his throat with the [src.name]! It looks like \he's trying to commit suicide.</b>", \
|
||||
"\red <b>[user] is slitting \his stomach open with the [src.name]! It looks like \he's trying to commit seppuku.</b>")
|
||||
return (BRUTELOSS)
|
||||
|
||||
/obj/item/weapon/material/knife/hook
|
||||
name = "meat hook"
|
||||
desc = "A sharp, metal hook what sticks into things."
|
||||
|
||||
@@ -64,9 +64,8 @@
|
||||
processing_objects -= src
|
||||
..()
|
||||
|
||||
/obj/item/weapon/material/attack()
|
||||
if(!..())
|
||||
return
|
||||
/obj/item/weapon/material/apply_hit_effect()
|
||||
..()
|
||||
if(!unbreakable)
|
||||
if(material.is_brittle())
|
||||
health = 0
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
/obj/item/weapon/material/hatchet/tacknife
|
||||
name = "tactical knife"
|
||||
desc = "You'd be killing loads of people if this was Medal of Valor: Heroes of Nyx."
|
||||
desc = "You'd be killing loads of people if this was Medal of Valor: Heroes of Space."
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "tacknife"
|
||||
item_state = "knife"
|
||||
@@ -44,7 +44,6 @@
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "hoe"
|
||||
item_state = "hoe"
|
||||
flags = CONDUCT | NOBLUDGEON
|
||||
force_divisor = 0.25 // 5 with weight 20 (steel)
|
||||
thrown_force_divisor = 0.25 // as above
|
||||
w_class = 2
|
||||
@@ -61,7 +60,6 @@
|
||||
throw_speed = 1
|
||||
throw_range = 3
|
||||
w_class = 4
|
||||
flags = NOSHIELD
|
||||
slot_flags = SLOT_BACK
|
||||
origin_tech = "materials=2;combat=2"
|
||||
attack_verb = list("chopped", "sliced", "cut", "reaped")
|
||||
|
||||
@@ -16,11 +16,6 @@
|
||||
unbreakable = 1 //It's already broken.
|
||||
drops_debris = 0
|
||||
|
||||
/obj/item/weapon/material/shard/suicide_act(mob/user)
|
||||
viewers(user) << pick("\red <b>[user] is slitting \his wrists with \the [src]! It looks like \he's trying to commit suicide.</b>", \
|
||||
"\red <b>[user] is slitting \his throat with \the [src]! It looks like \he's trying to commit suicide.</b>")
|
||||
return (BRUTELOSS)
|
||||
|
||||
/obj/item/weapon/material/shard/set_material(var/new_material)
|
||||
..(new_material)
|
||||
if(!istype(material))
|
||||
@@ -61,26 +56,39 @@
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/material/shard/Crossed(AM as mob|obj)
|
||||
..()
|
||||
if(isliving(AM))
|
||||
var/mob/M = AM
|
||||
|
||||
if(M.buckled) //wheelchairs, office chairs, rollerbeds
|
||||
return
|
||||
|
||||
M << "<span class='danger'>You step on \the [src]!</span>"
|
||||
playsound(src.loc, 'sound/effects/glass_step.ogg', 50, 1) // not sure how to handle metal shards with sounds
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if(H.species.flags & IS_SYNTHETIC || (H.species.siemens_coefficient<0.5) || (H.species.name == "Vaurca")) //Thick skin.
|
||||
if(H.species.siemens_coefficient<0.5 || H.get_species() == "Vaurca") //Thick skin.
|
||||
return
|
||||
|
||||
if( !H.shoes && ( !H.wear_suit || !(H.wear_suit.body_parts_covered & FEET) ) )
|
||||
var/obj/item/organ/external/affecting = H.get_organ(pick("l_foot", "r_foot"))
|
||||
if(affecting.status & ORGAN_ROBOT)
|
||||
if( H.shoes || ( H.wear_suit && (H.wear_suit.body_parts_covered & FEET) ) )
|
||||
return
|
||||
|
||||
var/list/check = list("l_foot", "r_foot")
|
||||
while(check.len)
|
||||
var/picked = pick(check)
|
||||
var/obj/item/organ/external/affecting = H.get_organ(picked)
|
||||
if(affecting)
|
||||
if(affecting.status & ORGAN_ROBOT)
|
||||
return
|
||||
if(affecting.take_damage(5, 0))
|
||||
H.UpdateDamageIcon()
|
||||
H.updatehealth()
|
||||
if(!(H.species.flags & NO_PAIN))
|
||||
H.Weaken(3)
|
||||
return
|
||||
if(affecting.take_damage(5, 0))
|
||||
H.UpdateDamageIcon()
|
||||
H.updatehealth()
|
||||
if(!(H.species && (H.species.flags & NO_PAIN)))
|
||||
H.Weaken(3)
|
||||
..()
|
||||
check -= picked
|
||||
return
|
||||
|
||||
// Preset types - left here for the code that uses them
|
||||
/obj/item/weapon/material/shard/shrapnel/New(loc)
|
||||
|
||||
@@ -12,12 +12,13 @@
|
||||
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
|
||||
/obj/item/weapon/material/sword/IsShield()
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/material/sword/suicide_act(mob/user)
|
||||
viewers(user) << "<span class='danger'>[user] is falling on the [src.name]! It looks like \he's trying to commit suicide.</span>"
|
||||
return(BRUTELOSS)
|
||||
/obj/item/weapon/material/sword/handle_shield(mob/user, var/damage, atom/damage_source = null, mob/attacker = null, var/def_zone = null, var/attack_text = "the attack")
|
||||
|
||||
if(default_parry_check(user, attacker, damage_source) && prob(50))
|
||||
user.visible_message("<span class='danger'>\The [user] parries [attack_text] with \the [src]!</span>")
|
||||
playsound(user.loc, 'sound/weapons/punchmiss.ogg', 50, 1)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/material/sword/katana
|
||||
name = "katana"
|
||||
@@ -26,10 +27,6 @@
|
||||
item_state = "katana"
|
||||
slot_flags = SLOT_BELT | SLOT_BACK
|
||||
|
||||
/obj/item/weapon/material/sword/katana/suicide_act(mob/user)
|
||||
viewers(user) << "<span class='danger'>[user] is slitting \his stomach open with the [src.name]! It looks like \he's trying to commit seppuku.</span>"
|
||||
return(BRUTELOSS)
|
||||
|
||||
/obj/item/weapon/material/sword/rapier
|
||||
name = "rapier"
|
||||
desc = "A slender, fancy and sharply pointed sword."
|
||||
|
||||
@@ -71,6 +71,14 @@
|
||||
O.unwield()
|
||||
return unwield()
|
||||
|
||||
//Allow a small chance of parrying melee attacks when wielded - maybe generalize this to other weapons someday
|
||||
/obj/item/weapon/material/twohanded/handle_shield(mob/user, var/damage, atom/damage_source = null, mob/attacker = null, var/def_zone = null, var/attack_text = "the attack")
|
||||
if(wielded && default_parry_check(user, attacker, damage_source) && prob(15))
|
||||
user.visible_message("<span class='danger'>\The [user] parries [attack_text] with \the [src]!</span>")
|
||||
playsound(user.loc, 'sound/weapons/punchmiss.ogg', 50, 1)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/weapon/material/twohanded/update_icon()
|
||||
icon_state = "[base_icon][wielded]"
|
||||
item_state = icon_state
|
||||
@@ -84,7 +92,7 @@
|
||||
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(H.species.is_small)
|
||||
if(issmall(H))
|
||||
user << "<span class='warning'>It's too heavy for you to wield fully.</span>"
|
||||
return
|
||||
else
|
||||
@@ -168,51 +176,6 @@
|
||||
var/obj/effect/plant/P = A
|
||||
P.die_off()
|
||||
|
||||
/*
|
||||
/*
|
||||
* Double-Bladed Energy Swords - Cheridan
|
||||
*/
|
||||
// Not sure what to do with this one, it won't work nicely with the material system,
|
||||
// but I don't want to copypaste all the twohanded procs..
|
||||
/obj/item/weapon/material/twohanded/dualsaber
|
||||
icon_state = "dualsaber0"
|
||||
base_icon = "dualsaber"
|
||||
name = "double-bladed energy sword"
|
||||
desc = "Handle with care."
|
||||
force = 3
|
||||
throwforce = 5.0
|
||||
throw_speed = 1
|
||||
throw_range = 5
|
||||
w_class = 2.0
|
||||
force_wielded = 30
|
||||
wieldsound = 'sound/weapons/saberon.ogg'
|
||||
unwieldsound = 'sound/weapons/saberoff.ogg'
|
||||
flags = NOSHIELD
|
||||
origin_tech = "magnets=3;syndicate=4"
|
||||
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")
|
||||
sharp = 1
|
||||
edge = 1
|
||||
applies_material_colour = 0
|
||||
|
||||
/obj/item/weapon/material/twohanded/dualsaber/attack(target as mob, mob/living/user as mob)
|
||||
..()
|
||||
if((CLUMSY in user.mutations) && (wielded) &&prob(40))
|
||||
user << "\red You twirl around a bit before losing your balance and impaling yourself on the [src]."
|
||||
user.take_organ_damage(20,25)
|
||||
return
|
||||
if((wielded) && prob(50))
|
||||
spawn(0)
|
||||
for(var/i in list(1,2,4,8,4,2,1,2,4,8,4,2))
|
||||
user.set_dir(i)
|
||||
sleep(1)
|
||||
|
||||
/obj/item/weapon/material/twohanded/dualsaber/IsShield()
|
||||
if(wielded)
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
*/
|
||||
|
||||
//spears, bay edition
|
||||
/obj/item/weapon/material/twohanded/spear
|
||||
icon_state = "spearglass0"
|
||||
@@ -228,7 +191,6 @@
|
||||
throw_speed = 3
|
||||
edge = 1
|
||||
sharp = 1
|
||||
flags = NOSHIELD
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
attack_verb = list("attacked", "poked", "jabbed", "torn", "gored")
|
||||
default_material = "glass"
|
||||
|
||||
Reference in New Issue
Block a user