Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traitor Stuff and Misc Stuff #470

Merged
merged 10 commits into from
Oct 22, 2023
6 changes: 6 additions & 0 deletions code/datums/uplink/stealthy_and_inconspicuous_weapons.dm
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@
item_cost = 20
path = /obj/item/pen/reagent/sleepy

/datum/uplink_item/item/stealthy_weapons/fakescalp
name = "Injection Scalpel"
desc = "This 'scalpel' will inject a chemical of choice into the bloodstream of an unsuspecting patient, either it be a surgery or assault. WARNING: Not for use as a scalpel, poison not included."
item_cost = 15
path = /obj/item/material/knife/reagent/fakescalp

/datum/uplink_item/item/stealthy_weapons/syringegun
name = "Disguised Syringe Gun"
desc = "A syringe gun disguised as an electronic cigarette with 4 darts included in the box. Chemicals not included!"
Expand Down
6 changes: 6 additions & 0 deletions code/game/antagonist/station/traitor.dm
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
GLOBAL_DATUM_INIT(traitors, /datum/antagonist/traitor, new)

/proc/istraitor(var/mob/player)
if(!GLOB.traitors || !player.mind)
return 0
if(player.mind in GLOB.traitors.current_antagonists)
return 1
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved

// Inherits most of its vars from the base datum.
/datum/antagonist/traitor
id = MODE_TRAITOR
Expand Down
1 change: 1 addition & 0 deletions code/game/machinery/alarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@
req_access.Cut()
to_chat(user, SPAN_NOTICE("You short out \the [src]'s scanner circuit, removing the access requirements!"))
sparks(2, 1, src)
emagged = 1
return 1
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved
return

Expand Down
1 change: 1 addition & 0 deletions code/game/machinery/rotating_alarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
active_power_usage = 0
anchored = TRUE

obj_flags = OBJ_FLAG_ANCHORABLE | OBJ_FLAG_ROTATABLE
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved
var/on = FALSE
var/low_alarm = FALSE
var/construct_type = /obj/machinery/light_construct
Expand Down
45 changes: 29 additions & 16 deletions code/game/objects/items/weapons/grenades/grenade.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,21 @@
throw_range = 20
obj_flags = OBJ_FLAG_CONDUCTIBLE
slot_flags = SLOT_BELT
var/emagged = FALSE
var/active = 0
var/det_time = 50
var/fail_det_time = 5 // If you are clumsy and fail, you get this time.
var/arm_sound = 'sound/weapons/armbomb.ogg'

/obj/item/grenade/emag_act(remaining_charges, mob/user, emag_source)
. = ..()
if(!emagged)
to_chat(user, SPAN_NOTICE("You short out \the [src]'s timer, it is now permanently set for instant detonation!"))
sparks(2, 1, src)
det_time = 1
emagged = 1
return 1
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved

/obj/item/grenade/proc/clown_check(var/mob/living/user)
if((MUTATION_CLUMSY in user.mutations) && prob(50))
to_chat(user, "<span class='warning'>Huh? How does this thing work?</span>")
Expand Down Expand Up @@ -61,23 +71,26 @@
T.hotspot_expose(700,125)

/obj/item/grenade/attackby(obj/item/W as obj, mob/user as mob)
if(isScrewdriver(W))
switch(det_time)
if (1)
det_time = 10
to_chat(user, "<span class='notice'>You set the [name] for 1 second detonation time.</span>")
if (10)
det_time = 30
to_chat(user, "<span class='notice'>You set the [name] for 3 second detonation time.</span>")
if (30)
det_time = 50
to_chat(user, "<span class='notice'>You set the [name] for 5 second detonation time.</span>")
if (50)
det_time = 1
to_chat(user, "<span class='notice'>You set the [name] for instant detonation.</span>")
add_fingerprint(user)
if(!emagged)
if(isScrewdriver(W))
switch(det_time)
if (1)
det_time = 10
to_chat(user, "<span class='notice'>You set the [name] for 1 second detonation time.</span>")
if (10)
det_time = 30
to_chat(user, "<span class='notice'>You set the [name] for 3 second detonation time.</span>")
if (30)
det_time = 50
to_chat(user, "<span class='notice'>You set the [name] for 5 second detonation time.</span>")
if (50)
det_time = 1
to_chat(user, "<span class='notice'>You set the [name] for instant detonation.</span>")
else
to_chat(user, SPAN_WARNING("\The [src] refuses the change!"))
add_fingerprint(user)
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved
..()

/obj/item/grenade/attack_hand()
walk(src, null, null)
..()
..()
44 changes: 44 additions & 0 deletions code/game/objects/items/weapons/material/knives.dm
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,47 @@
name = "lightweight utility knife"
desc = "A lightweight utility knife made out of a steel alloy."
icon_state = "titanium"

//Reagent Knives

/obj/item/material/knife/reagent
atom_flags = ATOM_FLAG_OPEN_CONTAINER
origin_tech = list(TECH_MATERIAL = 2, TECH_ESOTERIC = 5)

/obj/item/material/knife/reagent/New()
..()
create_reagents(30)

/obj/item/material/knife/reagent/attack(mob/living/M, mob/user, var/target_zone)
if(!istype(M))
return

. = ..()

var/allow = M.can_inject(user, target_zone)
if(user.a_intent == I_HURT) //prevents it from injecting reagents WITHOUT attacking (reagents get injected but no harm is done to the target)
if(allow)
if(allow == INJECTION_PORT) //this is a knife meant for combat, we are not gonna inject
return
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved
if(reagents.total_volume)
if(M.reagents)
var/should_admin_log = reagents.should_admin_log()
var/contained_reagents = reagents.get_reagents()
var/trans = reagents.trans_to_mob(M, 4, CHEM_BLOOD) //we transfer only 4 units because slashing doesnt generally make you stay in the wound long
EgorDinamit marked this conversation as resolved.
Show resolved Hide resolved
if(should_admin_log)
admin_inject_log(user, M, src, contained_reagents, trans)


/obj/item/material/knife/reagent/fakescalp
name = "scalpel"
desc = "A tiny and extremely sharp steel cutting tool used for surgery, dissection, autopsy, and very precise cuts. The cornerstone of any surgical procedure."
icon = 'icons/obj/surgery.dmi'
icon_state = "scalpel"
applies_material_colour = 0 //does not rename it to "steel scalpel" so we can hide it :)))))))
applies_material_name = 0 //does not recolor it, makes it indistinguishable from a real scalpel.
origin_tech = list(TECH_MATERIAL = 2, TECH_ESOTERIC = 5)

/obj/item/material/knife/reagent/fakescalp/examine(mob/user, distance)
. = ..()
if(istraitor(user) || user.skill_check(SKILL_MEDICAL, SKILL_TRAINED) || user.skill_check(SKILL_DEVICES, SKILL_TRAINED))
to_chat(user, "That doesn't look like a normal scalpel.")
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@
hard_drive.store_file(new /datum/computer_file/program/wordprocessor())
hard_drive.store_file(new /datum/computer_file/program/records())
hard_drive.store_file(new /datum/computer_file/program/newscast())
if(prob(50)) //harmless tax software
hard_drive.store_file(new /datum/computer_file/program/uplink())
hard_drive.store_file(new /datum/computer_file/program/uplink()) //this shit was long overdue, its now for everyone, DEATH TO METAGAME
var/datum/extension/interactive/ntos/os = get_extension(src, /datum/extension/interactive/ntos)
if(os)
os.set_autorun("emailc")
Expand Down Expand Up @@ -86,4 +85,4 @@

/obj/item/modular_computer/pda/captain/install_default_hardware()
..()
scanner = new /obj/item/stock_parts/computer/scanner/paper(src)
scanner = new /obj/item/stock_parts/computer/scanner/paper(src)
1 change: 1 addition & 0 deletions code/modules/overmap/ships/computers/helm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@ LEGACY_RECORD_STRUCTURE(all_waypoints, waypoint)
req_access.Cut()
to_chat(user, SPAN_NOTICE("You short out \the [src]'s internal circuitry, removing the access requirements!"))
sparks(2, 1, src)
emagged = 1
return 1
casualspacestation14enjoyer marked this conversation as resolved.
Show resolved Hide resolved
return

Expand Down
Binary file modified icons/obj/bureaucracy.dmi
Binary file not shown.