Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions code/__DEFINES/role_preferences.dm
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
#define ROLE_DRONE "Drone"
#define ROLE_DEATHSQUAD "Deathsquad"
#define ROLE_LAVALAND "Lavaland"
#define ROLE_INTERNAL_AFFAIRS "Internal Affairs Agent"
#define ROLE_FUGITIVE "Fugitive"
#define ROLE_SHADOWLING "Shadowling" // Yogs
#define ROLE_VAMPIRE "Vampire" // Yogs
Expand Down Expand Up @@ -87,7 +86,6 @@ GLOBAL_LIST_INIT(special_roles, list(
ROLE_BROTHER = /datum/antagonist/brother,
ROLE_BRAINWASHED = /datum/antagonist/brainwashed,
ROLE_OBSESSED = /datum/antagonist/obsessed,
ROLE_INTERNAL_AFFAIRS = /datum/antagonist/traitor/internal_affairs,
ROLE_FUGITIVE = /datum/antagonist/fugitive,
ROLE_SHADOWLING = /datum/antagonist/shadowling, // Yogs
ROLE_VAMPIRE = /datum/antagonist/vampire, // Yogs
Expand Down
78 changes: 78 additions & 0 deletions code/datums/status_effects/agent_pinpointer.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
#define PINPOINTER_MINIMUM_RANGE 15
#define PINPOINTER_EXTRA_RANDOM_RANGE 10
#define PINPOINTER_PING_TIME (4 SECONDS)

/atom/movable/screen/alert/status_effect/agent_pinpointer
name = "Target Integrated Pinpointer"
desc = "Even stealthier than a normal implant, it points to any assassination target you have."
icon = 'icons/obj/device.dmi'
icon_state = "pinon"

/datum/status_effect/agent_pinpointer
id = "agent_pinpointer"
duration = -1
tick_interval = PINPOINTER_PING_TIME
alert_type = /atom/movable/screen/alert/status_effect/agent_pinpointer
///The minimum range to start pointing towards your target.
var/minimum_range = PINPOINTER_MINIMUM_RANGE
///How fuzzy will the pinpointer be, messing with it pointing to your target.
var/range_fuzz_factor = PINPOINTER_EXTRA_RANDOM_RANGE
///The range until you're considered 'close'
var/range_mid = 8
///The range until you're considered 'too far away'
var/range_far = 16
///The target we are pointing towards, refreshes every tick.
var/mob/scan_target

/datum/status_effect/agent_pinpointer/tick()
if(!owner)
qdel(src)
return
scan_for_target()
point_to_target()

///Show the distance and direction of a scanned target
/datum/status_effect/agent_pinpointer/proc/point_to_target()
if(!scan_target)
linked_alert.icon_state = "pinonnull"
return

var/turf/here = get_turf(owner)
var/turf/there = get_turf(scan_target)

if(here.z != there.z)
linked_alert.icon_state = "pinonnull"
return
if(get_dist_euclidian(here,there) <= minimum_range + rand(0, range_fuzz_factor))
linked_alert.icon_state = "pinondirect"
return
linked_alert.setDir(get_dir(here, there))

var/dist = (get_dist(here, there))
if(dist >= 1 && dist <= range_mid)
linked_alert.icon_state = "pinonclose"
else if(dist > range_mid && dist <= range_far)
linked_alert.icon_state = "pinonmedium"
else if(dist > range_far)
linked_alert.icon_state = "pinonfar"

///Attempting to locate a nearby target to scan and point towards.
/datum/status_effect/agent_pinpointer/proc/scan_for_target()
scan_target = null
if(!owner && !owner.mind)
return
for(var/datum/objective/assassinate/objective_datums as anything in owner.mind.get_all_objectives())
if(!objective_datums.target || !objective_datums.target.current || objective_datums.target.current.stat == DEAD)
continue
var/mob/tracked_target = objective_datums.target.current
//JUUUST in case.
if(!tracked_target)
continue

//Catch the first one we find, then stop. We want to point to the most recent one we've got.
scan_target = tracked_target
break

#undef PINPOINTER_EXTRA_RANDOM_RANGE
#undef PINPOINTER_MINIMUM_RANGE
#undef PINPOINTER_PING_TIME
11 changes: 0 additions & 11 deletions code/game/gamemodes/objective.dm
Original file line number Diff line number Diff line change
Expand Up @@ -274,14 +274,6 @@ GLOBAL_LIST_EMPTY(objectives)
if(target && target.current != original)
return TRUE

/datum/objective/assassinate/internal
var/stolen = 0 //Have we already eliminated this target?

/datum/objective/assassinate/internal/update_explanation_text()
..()
if(target && !target.current)
explanation_text = "Assassinate [target.name], who was obliterated."

/datum/objective/mutiny
name = "mutiny"
var/target_role_type=FALSE
Expand Down Expand Up @@ -1059,9 +1051,6 @@ GLOBAL_LIST_EMPTY(possible_items_special)
to_chat(admin, span_warning("No active AIs with minds!"))
update_explanation_text()

/datum/objective/destroy/internal
var/stolen = FALSE //Have we already eliminated this target?

/datum/objective/steal_n_of_type
name = "steal five of"
explanation_text = "Steal some items!"
Expand Down
100 changes: 0 additions & 100 deletions code/game/gamemodes/traitor/internal_affairs.dm

This file was deleted.

22 changes: 0 additions & 22 deletions code/modules/admin/secrets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -330,28 +330,6 @@
message_admins(span_adminnotice("[key_name_admin(mob_user)] used everyone is a traitor secret. Objective is [objective]"))
log_admin("[key_name(mob_user)] used everyone is a traitor secret. Objective is [objective]")

if("iaa_all")
if(!check_rights_for(rights, R_FUN))
return
if(!SSticker.HasRoundStarted())
tgui_alert(mob_user, "The game hasn't started yet!")
return
SSblackbox.record_feedback("nested tally", "admin_secrets_fun_used", 1, list("IAA All"))
for(var/mob/living/H in GLOB.player_list)
if(!(ishuman(H)))
continue
if(H.stat == DEAD || !H.client || !H.mind || ispAI(H))
continue
if(is_special_character(H))
continue
var/list/badjobs = list("Security Officer", "Warden", "Detective", "AI", "Cyborg", "Captain", "Head of Personnel", "Head of Security")
if(H.mind.assigned_role in badjobs)
continue
var/datum/antagonist/traitor/internal_affairs/T = new()
H.mind.add_antag_datum(T)
message_admins(span_adminnotice("[key_name_admin(mob_user)] used everyone is a iaa secret."))
log_admin("[key_name(mob_user)] used everyone is a iaa secret.")

if("changebombcap")
if(!check_rights_for(rights, R_FUN))
return
Expand Down
2 changes: 1 addition & 1 deletion code/modules/admin/sql_ban_system.dm
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@
"Ghost and Other Roles" = list(ROLE_BRAINWASHED, ROLE_DEATHSQUAD, ROLE_DRONE, ROLE_FUGITIVE, ROLE_HOLOPARASITE, ROLE_HORROR, ROLE_LAVALAND, ROLE_MIND_TRANSFER, ROLE_POSIBRAIN, ROLE_SENTIENCE, ROLE_MOUSE, ROLE_GOLEM, ROLE_GHOSTBEACON),
"Antagonist Positions" = list(ROLE_ABDUCTOR, ROLE_ALIEN, ROLE_BLOB,
ROLE_BLOODSUCKER, ROLE_BROTHER, ROLE_CHANGELING, ROLE_CULTIST,
ROLE_FUGITIVE, ROLE_HOLOPARASITE, ROLE_INTERNAL_AFFAIRS, ROLE_MALF,
ROLE_FUGITIVE, ROLE_HOLOPARASITE, ROLE_MALF,
ROLE_MONKEY, ROLE_MONSTERHUNTER, ROLE_NINJA, ROLE_OPERATIVE,
ROLE_REV, ROLE_REVENANT, ROLE_SINFULDEMON,
ROLE_REV_HEAD, ROLE_SERVANT_OF_RATVAR, ROLE_SYNDICATE,
Expand Down
Loading