Files
GS13NG/code/modules/research/xenobiology/crossbreeding/_clothing.dm
T
2020-07-20 11:25:17 -07:00

144 lines
5.3 KiB
Plaintext

/*
Slimecrossing Armor
Armor added by the slimecrossing system.
Collected here for clarity.
*/
//Rebreather mask - Chilling Blue
/obj/item/clothing/mask/nobreath
name = "rebreather mask"
desc = "A transparent mask, resembling a conventional breath mask, but made of bluish slime. Seems to lack any air supply tube, though."
icon_state = "slime"
item_state = "slime"
body_parts_covered = NONE
w_class = WEIGHT_CLASS_SMALL
gas_transfer_coefficient = 0
permeability_coefficient = 0.5
flags_cover = MASKCOVERSMOUTH
resistance_flags = NONE
/obj/item/clothing/mask/nobreath/equipped(mob/living/carbon/human/user, slot)
. = ..()
if(slot == SLOT_WEAR_MASK)
ADD_TRAIT(user, TRAIT_NOBREATH, "breathmask_[REF(src)]")
user.failed_last_breath = FALSE
user.clear_alert("not_enough_oxy")
user.apply_status_effect(/datum/status_effect/rebreathing)
/obj/item/clothing/mask/nobreath/dropped(mob/living/carbon/human/user)
..()
REMOVE_TRAIT(user, TRAIT_NOBREATH, "breathmask_[REF(src)]")
user.remove_status_effect(/datum/status_effect/rebreathing)
/obj/item/clothing/glasses/prism_glasses
name = "prism glasses"
desc = "The lenses seem to glow slightly, and reflect light into dazzling colors."
icon = 'icons/obj/slimecrossing.dmi'
icon_state = "prismglasses"
actions_types = list(/datum/action/item_action/change_prism_colour, /datum/action/item_action/place_light_prism)
var/glasses_color = "#FFFFFF"
/obj/item/clothing/glasses/prism_glasses/item_action_slot_check(slot)
if(slot == SLOT_GLASSES)
return TRUE
/obj/structure/light_prism
name = "light prism"
desc = "A shining crystal of semi-solid light. Looks fragile."
icon = 'icons/obj/slimecrossing.dmi'
icon_state = "lightprism"
density = FALSE
anchored = TRUE
max_integrity = 10
/obj/structure/light_prism/Initialize(mapload, var/newcolor)
. = ..()
color = newcolor
light_color = newcolor
set_light(5)
/obj/structure/light_prism/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
to_chat(user, "<span class='notice'>You dispel [src]</span>")
qdel(src)
/datum/action/item_action/change_prism_colour
name = "Adjust Prismatic Lens"
icon_icon = 'icons/obj/slimecrossing.dmi'
button_icon_state = "prismcolor"
/datum/action/item_action/change_prism_colour/Trigger()
if(!IsAvailable())
return
var/obj/item/clothing/glasses/prism_glasses/glasses = target
var/new_color = input(owner, "Choose the lens color:", "Color change",glasses.glasses_color) as color|null
if(!new_color)
return
glasses.glasses_color = new_color
/datum/action/item_action/place_light_prism
name = "Fabricate Light Prism"
icon_icon = 'icons/obj/slimecrossing.dmi'
button_icon_state = "lightprism"
/datum/action/item_action/place_light_prism/Trigger()
if(!IsAvailable())
return
var/obj/item/clothing/glasses/prism_glasses/glasses = target
if(locate(/obj/structure/light_prism) in get_turf(owner))
to_chat(owner, "<span class='warning'>There isn't enough ambient energy to fabricate another light prism here.</span>")
return
if(istype(glasses))
if(!glasses.glasses_color)
to_chat(owner, "<span class='warning'>The lens is oddly opaque...</span>")
return
to_chat(owner, "<span class='notice'>You channel nearby light into a glowing, ethereal prism.</span>")
new /obj/structure/light_prism(get_turf(owner), glasses.glasses_color)
/obj/item/clothing/head/peaceflower
name = "heroine bud"
desc = "An extremely addictive flower, full of peace magic."
icon = 'icons/obj/slimecrossing.dmi'
icon_state = "peaceflower"
item_state = "peaceflower"
slot_flags = ITEM_SLOT_HEAD
body_parts_covered = NONE
dynamic_hair_suffix = ""
force = 0
throwforce = 0
w_class = WEIGHT_CLASS_TINY
throw_speed = 1
throw_range = 3
/obj/item/clothing/head/peaceflower/equipped(mob/living/carbon/human/user, slot)
. = ..()
if(slot == SLOT_HEAD)
ADD_TRAIT(user, TRAIT_PACIFISM, "peaceflower_[REF(src)]")
/obj/item/clothing/head/peaceflower/dropped(mob/living/carbon/human/user)
..()
REMOVE_TRAIT(user, TRAIT_PACIFISM, "peaceflower_[REF(src)]")
/obj/item/clothing/head/peaceflower/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(iscarbon(user))
var/mob/living/carbon/C = user
if(src == C.head)
to_chat(user, "<span class='warning'>You feel at peace. <b style='color:pink'>Why would you want anything else?</b></span>")
return
return ..()
/obj/item/clothing/suit/armor/heavy/adamantine
name = "adamantine armor"
desc = "A full suit of adamantine plate armor. Impressively resistant to damage, but weighs about as much as you do."
icon_state = "adamsuit"
item_state = "adamsuit"
flags_inv = NONE
obj_flags = IMMUTABLE_SLOW
slowdown = 4
var/hit_reflect_chance = 10 // Citadel Change: because 40% chance of bouncing lasers back into peoples faces isn't good.
armor = list("melee" = 70, "bullet" = 70, "laser" = 40, "energy" = 40, "bomb" = 80, "bio" = 80, "rad" = 80, "fire" = 70, "acid" = 90) //Citadel Change to avoid immortal Xenobiologists.
/obj/item/clothing/suit/armor/heavy/adamantine/run_block(mob/living/owner, atom/object, damage, attack_text, attack_type, armour_penetration, mob/attacker, def_zone, final_block_chance, list/block_return)
if(is_energy_reflectable_projectile(object) && prob(hit_reflect_chance))
return BLOCK_SUCCESS | BLOCK_REDIRECTED | BLOCK_SHOULD_REDIRECT | BLOCK_PHYSICAL_INTERNAL
return ..()