mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-31 20:11:56 +00:00
* Initial work * more * ass * wsedfwedff * asss * test * stuff * fuck * sss a * kms * asdadwedwdfwefwef * start * test * dwwdew * ewefwfef * Redemption machine (#8) * Redemption machine * Removes debug messages * changes * fuckmyshitup * coin mint works with new material shenanigans (#10) * Auto stash before merge of "materials" and "origin/materials" * woops * furnace (#11) * autolathe manufacturing of toolboxes * eggs in a basket * some small changes * matcolors * documentation * more documentation and effects * done * Color man bad (#12) * fixes designs * ass * more fixes * fuck me * firestacks adder * epic fixes * fixes designs * DONE DIDDILY DOO * removes category macro * ch-ch-ch-changes * fixes some stuff * Fixes display of ore values (#9) * Redemption machine * Removes debug messages * Re-adds value display * Replaces the fire stacking component with an element instead (#13) * fixes examine * fixes ligma bugs * double ligma boofus * fix * misses some defines * fixes ORM * Update code/datums/components/material_container.dm Co-Authored-By: Emmett Gaines <ninjanomnom@gmail.com> * fixes * Makes glass objects weaker (#14) * Makes glass objects weaker * uses correct proc * fixes shit * honk honk * better * oh shit oh fuck * fixes * fuck ORMs * fixes the biogen * documentation * ass (#15) * component * changes * ass * ass * doc * Auto stash before merge of "materials-plasmacomponent" and "origin/materials-plasmacomponent" * fixes rounding * fixed
142 lines
5.4 KiB
Plaintext
142 lines
5.4 KiB
Plaintext
/obj/item/screwdriver
|
|
name = "screwdriver"
|
|
desc = "You can be totally screwy with this."
|
|
icon = 'icons/obj/tools.dmi'
|
|
icon_state = "screwdriver_map"
|
|
item_state = "screwdriver"
|
|
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
|
|
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
|
|
flags_1 = CONDUCT_1
|
|
slot_flags = ITEM_SLOT_BELT
|
|
force = 5
|
|
w_class = WEIGHT_CLASS_TINY
|
|
throwforce = 5
|
|
throw_speed = 3
|
|
throw_range = 5
|
|
materials = list(/datum/material/iron=75)
|
|
attack_verb = list("stabbed")
|
|
hitsound = 'sound/weapons/bladeslice.ogg'
|
|
usesound = list('sound/items/screwdriver.ogg', 'sound/items/screwdriver2.ogg')
|
|
tool_behaviour = TOOL_SCREWDRIVER
|
|
toolspeed = 1
|
|
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 50, "acid" = 30)
|
|
var/random_color = TRUE //if the screwdriver uses random coloring
|
|
var/static/list/screwdriver_colors = list(
|
|
"blue" = rgb(24, 97, 213),
|
|
"red" = rgb(255, 0, 0),
|
|
"pink" = rgb(213, 24, 141),
|
|
"brown" = rgb(160, 82, 18),
|
|
"green" = rgb(14, 127, 27),
|
|
"cyan" = rgb(24, 162, 213),
|
|
"yellow" = rgb(255, 165, 0)
|
|
)
|
|
|
|
/obj/item/screwdriver/suicide_act(mob/user)
|
|
user.visible_message("<span class='suicide'>[user] is stabbing [src] into [user.p_their()] [pick("temple", "heart")]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return(BRUTELOSS)
|
|
|
|
/obj/item/screwdriver/Initialize()
|
|
. = ..()
|
|
if(random_color) //random colors!
|
|
icon_state = "screwdriver"
|
|
var/our_color = pick(screwdriver_colors)
|
|
add_atom_colour(screwdriver_colors[our_color], FIXED_COLOUR_PRIORITY)
|
|
update_icon()
|
|
if(prob(75))
|
|
pixel_y = rand(0, 16)
|
|
|
|
/obj/item/screwdriver/update_icon()
|
|
if(!random_color) //icon override
|
|
return
|
|
cut_overlays()
|
|
var/mutable_appearance/base_overlay = mutable_appearance(icon, "screwdriver_screwybits")
|
|
base_overlay.appearance_flags = RESET_COLOR
|
|
add_overlay(base_overlay)
|
|
|
|
/obj/item/screwdriver/worn_overlays(isinhands = FALSE, icon_file)
|
|
. = list()
|
|
if(isinhands && random_color)
|
|
var/mutable_appearance/M = mutable_appearance(icon_file, "screwdriver_head")
|
|
M.appearance_flags = RESET_COLOR
|
|
. += M
|
|
|
|
/obj/item/screwdriver/get_belt_overlay()
|
|
if(random_color)
|
|
var/mutable_appearance/body = mutable_appearance('icons/obj/clothing/belt_overlays.dmi', "screwdriver")
|
|
var/mutable_appearance/head = mutable_appearance('icons/obj/clothing/belt_overlays.dmi', "screwdriver_head")
|
|
body.color = color
|
|
head.add_overlay(body)
|
|
return head
|
|
else
|
|
return mutable_appearance('icons/obj/clothing/belt_overlays.dmi', icon_state)
|
|
|
|
/obj/item/screwdriver/attack(mob/living/carbon/M, mob/living/carbon/user)
|
|
if(!istype(M))
|
|
return ..()
|
|
if(user.zone_selected != BODY_ZONE_PRECISE_EYES && user.zone_selected != BODY_ZONE_HEAD)
|
|
return ..()
|
|
if(HAS_TRAIT(user, TRAIT_PACIFISM))
|
|
to_chat(user, "<span class='warning'>You don't want to harm [M]!</span>")
|
|
return
|
|
if(HAS_TRAIT(user, TRAIT_CLUMSY) && prob(50))
|
|
M = user
|
|
return eyestab(M,user)
|
|
|
|
/obj/item/screwdriver/brass
|
|
name = "brass screwdriver"
|
|
desc = "A screwdriver made of brass. The handle feels freezing cold."
|
|
resistance_flags = FIRE_PROOF | ACID_PROOF
|
|
icon_state = "screwdriver_brass"
|
|
item_state = "screwdriver_brass"
|
|
toolspeed = 0.5
|
|
random_color = FALSE
|
|
|
|
/obj/item/screwdriver/abductor
|
|
name = "alien screwdriver"
|
|
desc = "An ultrasonic screwdriver."
|
|
icon = 'icons/obj/abductor.dmi'
|
|
icon_state = "screwdriver_a"
|
|
item_state = "screwdriver_nuke"
|
|
usesound = 'sound/items/pshoom.ogg'
|
|
toolspeed = 0.1
|
|
random_color = FALSE
|
|
|
|
/obj/item/screwdriver/abductor/get_belt_overlay()
|
|
return mutable_appearance('icons/obj/clothing/belt_overlays.dmi', "screwdriver_nuke")
|
|
|
|
/obj/item/screwdriver/power
|
|
name = "hand drill"
|
|
desc = "A simple powered hand drill. It's fitted with a screw bit."
|
|
icon_state = "drill_screw"
|
|
item_state = "drill"
|
|
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
|
|
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
|
|
materials = list(/datum/material/iron=150,/datum/material/silver=50,/datum/material/titanium=25) //done for balance reasons, making them high value for research, but harder to get
|
|
force = 8 //might or might not be too high, subject to change
|
|
w_class = WEIGHT_CLASS_SMALL
|
|
throwforce = 8
|
|
throw_speed = 2
|
|
throw_range = 3//it's heavier than a screw driver/wrench, so it does more damage, but can't be thrown as far
|
|
attack_verb = list("drilled", "screwed", "jabbed","whacked")
|
|
hitsound = 'sound/items/drill_hit.ogg'
|
|
usesound = 'sound/items/drill_use.ogg'
|
|
toolspeed = 0.7
|
|
random_color = FALSE
|
|
|
|
/obj/item/screwdriver/power/suicide_act(mob/user)
|
|
user.visible_message("<span class='suicide'>[user] is putting [src] to [user.p_their()] temple. It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return(BRUTELOSS)
|
|
|
|
/obj/item/screwdriver/power/attack_self(mob/user)
|
|
playsound(get_turf(user),'sound/items/change_drill.ogg',50,1)
|
|
var/obj/item/wrench/power/b_drill = new /obj/item/wrench/power(drop_location())
|
|
to_chat(user, "<span class='notice'>You attach the bolt driver bit to [src].</span>")
|
|
qdel(src)
|
|
user.put_in_active_hand(b_drill)
|
|
|
|
/obj/item/screwdriver/cyborg
|
|
name = "powered screwdriver"
|
|
desc = "An electrical screwdriver, designed to be both precise and quick."
|
|
usesound = 'sound/items/drill_use.ogg'
|
|
toolspeed = 0.5
|