Skip to content

Commit

Permalink
OpenDream compatibility (#251)
Browse files Browse the repository at this point in the history
* Unshadow builtin name `src`

* Remove unused changeling garbage

* Vampires aren't real

* Remove unused variable

* `/var/var` -> `/var`

* Xenoarcheology ain't real either

* PAIs don't have records like this anymore

* More unused shit

* Do not treat verbs as objects
  • Loading branch information
martinlyra authored Oct 22, 2023
1 parent 130d7d6 commit e2a72e7
Show file tree
Hide file tree
Showing 18 changed files with 27 additions and 237 deletions.
6 changes: 3 additions & 3 deletions code/_helpers/unsorted.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1054,13 +1054,13 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)

// get coordinates to an atom

/proc/coordinates(atom/src, jump_link = 0)
return src ? src.coordinates(jump_link) : "nullspace"

/atom/proc/coordinates(jump_link = 0)
var/turf/T = src.loc
return T ? "([T.x],[T.y],[T.z])[jump_link ? admin_jump_link(T) : ""]" : "nullspace"

/proc/coordinates(atom/source, jump_link = 0)
return source ? source.coordinates(jump_link) : "nullspace"

// get memory reference
/proc/REF(input)
return "\ref[input]"
26 changes: 0 additions & 26 deletions code/_onclick/hud/ability_screen_objects.dm
Original file line number Diff line number Diff line change
Expand Up @@ -247,35 +247,9 @@
if(my_mob.client)
toggle_open(2) //forces the icons to refresh on screen

//Changeling Abilities
/atom/movable/screen/ability/verb_based/changeling
icon_state = "ling_spell_base"
background_base_state = "ling"

/atom/movable/screen/movable/ability_master/proc/add_ling_ability(object_given, verb_given, name_given, ability_icon_given, arguments)
if(!object_given)
message_admins("ERROR: add_ling_ability() was not given an object in its arguments.")
if(!verb_given)
message_admins("ERROR: add_ling_ability() was not given a verb/proc in its arguments.")
if(get_ability_by_proc_ref(verb_given))
return // Duplicate
var/atom/movable/screen/ability/verb_based/changeling/A = new /atom/movable/screen/ability/verb_based/changeling()
A.ability_master = src
A.object_used = object_given
A.verb_to_call = verb_given
A.ability_icon_state = ability_icon_given
A.SetName(name_given)
if(arguments)
A.arguments_to_use = arguments
ability_objects.Add(A)
if(my_mob.client)
toggle_open(2) //forces the icons to refresh on screen


/////////Obj Abilities////////
//Buttons to trigger objects//
//////////////////////////////

/atom/movable/screen/ability/obj_based
var/obj/object = null

Expand Down
2 changes: 0 additions & 2 deletions code/datums/mind.dm
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@
var/has_been_rev = 0//Tracks if this mind has been a rev or not

var/faction //associated faction
var/datum/changeling/changeling //changeling holder
var/datum/vampire/vampire //vamp holder; really have to clean this up someday.

var/rev_cooldown = 0

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@
// BEGIN RESEARCH DATUMS

/datum/malf_research_ability/interdiction/recall_shuttle
ability = new/datum/game_mode/malfunction/verb/recall_shuttle()
ability = /datum/game_mode/malfunction/verb/recall_shuttle
price = 250
next = new/datum/malf_research_ability/interdiction/unlock_cyborg()
name = "T1 - Recall Shuttle"


/datum/malf_research_ability/interdiction/unlock_cyborg
ability = new/datum/game_mode/malfunction/verb/unlock_cyborg()
ability = /datum/game_mode/malfunction/verb/unlock_cyborg
price = 1000
next = new/datum/malf_research_ability/interdiction/hack_cyborg()
name = "T2 - Unlock Cyborg"


/datum/malf_research_ability/interdiction/hack_cyborg
ability = new/datum/game_mode/malfunction/verb/hack_cyborg()
ability = /datum/game_mode/malfunction/verb/hack_cyborg
price = 2000
next = new/datum/malf_research_ability/interdiction/hack_ai()
name = "T3 - Hack Cyborg"


/datum/malf_research_ability/interdiction/hack_ai
ability = new/datum/game_mode/malfunction/verb/hack_ai()
ability = /datum/game_mode/malfunction/verb/hack_ai
price = 4000
name = "T4 - Hack AI"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,34 +11,34 @@
// BEGIN RESEARCH DATUMS

/datum/malf_research_ability/manipulation/electrical_pulse
ability = new/datum/game_mode/malfunction/verb/electrical_pulse()
ability = /datum/game_mode/malfunction/verb/electrical_pulse
price = 250
next = new/datum/malf_research_ability/manipulation/reboot_camera()
name = "T1 - Electrical Pulse"


/datum/malf_research_ability/manipulation/reboot_camera
ability = new/datum/game_mode/malfunction/verb/reboot_camera()
ability = /datum/game_mode/malfunction/verb/reboot_camera
price = 1000
next = new/datum/malf_research_ability/manipulation/emergency_forcefield()
name = "T2 - Reboot Camera"


/datum/malf_research_ability/manipulation/emergency_forcefield
ability = new/datum/game_mode/malfunction/verb/emergency_forcefield()
ability = /datum/game_mode/malfunction/verb/emergency_forcefield
price = 2000
next = new/datum/malf_research_ability/manipulation/machine_overload()
name = "T3 - Emergency Forcefield"


/datum/malf_research_ability/manipulation/machine_overload
ability = new/datum/game_mode/malfunction/verb/machine_overload()
ability = /datum/game_mode/malfunction/verb/machine_overload
price = 4000
next = new/datum/malf_research_ability/manipulation/machine_upgrade()
name = "T4 - Machine Overload"

/datum/malf_research_ability/manipulation/machine_upgrade
ability = new/datum/game_mode/malfunction/verb/machine_upgrade()
ability = /datum/game_mode/malfunction/verb/machine_upgrade
price = 4000
name = "T5 - Machine Upgrade"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,28 +10,28 @@
// BEGIN RESEARCH DATUMS

/datum/malf_research_ability/networking/basic_hack
ability = new/datum/game_mode/malfunction/verb/basic_encryption_hack()
ability = /datum/game_mode/malfunction/verb/basic_encryption_hack
price = 25 // Until you have this ability your CPU generation sucks, therefore it's very cheap.
next = new/datum/malf_research_ability/networking/advanced_hack()
name = "T1 - Basic Encryption Hack"


/datum/malf_research_ability/networking/advanced_hack
ability = new/datum/game_mode/malfunction/verb/advanced_encryption_hack()
ability = /datum/game_mode/malfunction/verb/advanced_encryption_hack
price = 1000
next = new/datum/malf_research_ability/networking/elite_hack()
name = "T2 - Advanced Encryption Hack"


/datum/malf_research_ability/networking/elite_hack
ability = new/datum/game_mode/malfunction/verb/elite_encryption_hack()
ability = /datum/game_mode/malfunction/verb/elite_encryption_hack
price = 2000
next = new/datum/malf_research_ability/networking/system_override()
name = "T3 - Elite Encryption Hack"


/datum/malf_research_ability/networking/system_override
ability = new/datum/game_mode/malfunction/verb/system_override()
ability = /datum/game_mode/malfunction/verb/system_override
price = 4000
name = "T4 - System Override"

Expand Down Expand Up @@ -216,4 +216,4 @@
command_announcement.Announce("Our system administrators just reported that we've been locked out from your control network. Whoever did this now has full access to [GLOB.using_map.station_name]'s systems.", "Network Administration Center")
user.hack_can_fail = 0
user.system_override = 2
user.verbs += new/datum/game_mode/malfunction/verb/ai_destroy_station()
user.verbs += /datum/game_mode/malfunction/verb/ai_destroy_station
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@
// BEGIN RESEARCH DATUMS

/datum/malf_research_ability/passive/intellicard_interception
ability = new/datum/game_mode/malfunction/verb/intellicard_interception()
ability = /datum/game_mode/malfunction/verb/intellicard_interception
price = 250
next = new/datum/malf_research_ability/passive/subtle_algorithms()
name = "T1 - Intellicard Interception"


/datum/malf_research_ability/passive/subtle_algorithms
ability = new/datum/game_mode/malfunction/verb/subtle_algorithms()
ability = /datum/game_mode/malfunction/verb/subtle_algorithms
price = 1000
next = new/datum/malf_research_ability/passive/relay_suppression()
name = "T2 - Subtle Algorithms"
Expand Down
155 changes: 0 additions & 155 deletions code/game/mecha/equipment/tools/unused_tools.dm

This file was deleted.

6 changes: 3 additions & 3 deletions code/modules/detectivework/forensics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ var/const/FINGERPRINT_COMPLETE = 6
return stringpercent(print) <= FINGERPRINT_COMPLETE

/atom/var/list/suit_fibers
/atom/var/var/list/fingerprints
/atom/var/var/list/fingerprintshidden
/atom/var/var/fingerprintslast
/atom/var/list/fingerprints
/atom/var/list/fingerprintshidden
/atom/var/fingerprintslast
/obj/item/var/list/trace_DNA
/mob/living/carbon/human/var/gunshot_residue
/obj/item/clothing/var/gunshot_residue
Expand Down
1 change: 0 additions & 1 deletion code/modules/materials/materials_ore.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
randpixel = 8
w_class = 2
var/material/material
var/datum/geosample/geologic_data

/obj/item/weapon/ore/get_material()
return material
Expand Down
8 changes: 4 additions & 4 deletions code/modules/mob/living/silicon/ai/malf.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
hacked_apcs = list()
recalc_cpu()

verbs += new/datum/game_mode/malfunction/verb/ai_select_hardware()
verbs += new/datum/game_mode/malfunction/verb/ai_select_research()
verbs += new/datum/game_mode/malfunction/verb/ai_help()
verbs += /datum/game_mode/malfunction/verb/ai_select_hardware
verbs += /datum/game_mode/malfunction/verb/ai_select_research
verbs += /datum/game_mode/malfunction/verb/ai_help

log_ability_use(src, "became malfunctioning AI")
// And greet user with some OOC info.
Expand Down Expand Up @@ -137,4 +137,4 @@
if(system_override == 1)
stat("SYSTEM OVERRIDE INITIATED")
else if(system_override == 2)
stat("SYSTEM OVERRIDE COMPLETED")
stat("SYSTEM OVERRIDE COMPLETED")
Loading

0 comments on commit e2a72e7

Please sign in to comment.