Skip to content

Commit

Permalink
Traitor Stuff and Misc Stuff (#470)
Browse files Browse the repository at this point in the history
* poor

* hidden scalpel

* four I HATE MYLIFE

* fix

* egor suggestion

Co-authored-by: EgorDinamit <[email protected]>

* fixed EPICLY

* i agree this is better :))))))))

Co-authored-by: EgorDinamit <[email protected]>

* fiks issues

* boopie peepie

* Revert "boopie peepie"

This reverts commit 93068c2.

---------

Co-authored-by: EgorDinamit <[email protected]>
  • Loading branch information
casualspacestation14enjoyer and EgorDinamit authored Oct 22, 2023
1 parent 47df84c commit bbcc17f
Show file tree
Hide file tree
Showing 7 changed files with 93 additions and 20 deletions.
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, chemicals 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
7 changes: 7 additions & 0 deletions code/game/antagonist/station/traitor.dm
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
GLOBAL_DATUM_INIT(traitors, /datum/antagonist/traitor, new)

/proc/istraitor(mob/player)
if(!GLOB.traitors || !player.mind)
return FALSE
if(player.mind in GLOB.traitors.current_antagonists)
return TRUE
return FALSE

// Inherits most of its vars from the base datum.
/datum/antagonist/traitor
id = MODE_TRAITOR
Expand Down
3 changes: 2 additions & 1 deletion code/game/machinery/alarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,8 @@
req_access.Cut()
to_chat(user, SPAN_NOTICE("You short out \the [src]'s scanner circuit, removing the access requirements!"))
sparks(2, 1, src)
return 1
emagged = TRUE
return TRUE
return

/obj/machinery/alarm/proc/handle_heating_cooling(var/datum/gas_mixture/environment)
Expand Down
43 changes: 28 additions & 15 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 = TRUE
return TRUE

/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 @@ -62,22 +72,25 @@

/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)
switch(det_time)
if (1)
det_time = 10
to_chat(user, SPAN_NOTICE("You set the [name] for 1 second detonation time."))
if (10)
det_time = 30
to_chat(user, SPAN_NOTICE("You set the [name] for 3 second detonation time."))
if (30)
det_time = 50
to_chat(user, SPAN_NOTICE("You set the [name] for 5 second detonation time."))
if (50)
det_time = 1
to_chat(user, SPAN_NOTICE("You set the [name] for instant detonation."))
else
to_chat(user, SPAN_WARNING("\The [src] refuses the change!"))
add_fingerprint(user)
..()

/obj/item/grenade/attack_hand()
walk(src, null, null)
..()
..()
46 changes: 46 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,49 @@
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
var/amount_to_transfer = 1 // the amount of chems to transfer between attacks
var/volume = 30
origin_tech = list(TECH_MATERIAL = 2, TECH_ESOTERIC = 5)

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

/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 == INJECTION_PORT) //this is a knife meant for combat, we are not gonna inject
return
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, 1, CHEM_BLOOD) //we transfer only 1 unit because slashing doesnt generally make you stay in the wound long
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"
max_force = 7 //already kills people with chems, why make it op?
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)
3 changes: 2 additions & 1 deletion code/modules/overmap/ships/computers/helm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,8 @@ 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)
return 1
emagged = TRUE
return TRUE
return

/**
Expand Down

0 comments on commit bbcc17f

Please sign in to comment.