[MIRROR] Renames delta time to be a more obvious name [MDB IGNORE] (#20507)

* Renames delta time to be a more obvious name

* updates to our code

---------

Co-authored-by: oranges <email@oranges.net.nz>
Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-04-12 20:45:43 +01:00
committed by GitHub
co-authored by oranges Gandalf
parent 34b66981ce
commit 9a594755f3
540 changed files with 3418 additions and 3424 deletions
@@ -463,7 +463,7 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
return FALSE
// Process currently calls handle_power(), may be expanded in future if more things are added.
/obj/item/modular_computer/process(delta_time)
/obj/item/modular_computer/process(seconds_per_tick)
if(!enabled) // The computer is turned off
last_power_usage = 0
return
@@ -479,7 +479,7 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
if(idle_programs.program_state == PROGRAM_STATE_KILLED)
idle_threads.Remove(idle_programs)
continue
idle_programs.process_tick(delta_time)
idle_programs.process_tick(seconds_per_tick)
idle_programs.ntnet_status = get_ntnet_status()
if(idle_programs.requires_ntnet && !idle_programs.ntnet_status)
idle_programs.event_networkfailure(TRUE)
@@ -488,10 +488,10 @@ GLOBAL_LIST_EMPTY(TabletMessengers) // a list of all active messengers, similar
if(active_program.program_state == PROGRAM_STATE_KILLED)
active_program = null
else
active_program.process_tick(delta_time)
active_program.process_tick(seconds_per_tick)
active_program.ntnet_status = get_ntnet_status()
handle_power(delta_time) // Handles all computer power interaction
handle_power(seconds_per_tick) // Handles all computer power interaction
/**
* Displays notification text alongside a soundbeep when requested to by a program.
@@ -31,7 +31,7 @@
shutdown_computer(0)
// Handles power-related things, such as battery interaction, recharging, shutdown when it's discharged
/obj/item/modular_computer/proc/handle_power(delta_time)
/obj/item/modular_computer/proc/handle_power(seconds_per_tick)
var/power_usage = screen_on ? base_active_power_usage : base_idle_power_usage
if(use_power(power_usage))