mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 19:47:22 +01:00
Reduces Stat Calls
This commit is contained in:
@@ -49,8 +49,17 @@
|
||||
description_holders["icon"] = "[bicon(A)]"
|
||||
description_holders["desc"] = A.desc
|
||||
|
||||
// Byond seemingly calls stat, each tick.
|
||||
// Calling things each tick can get expensive real quick.
|
||||
// So we slow this down a little.
|
||||
// See: http://www.byond.com/docs/ref/info.html#/client/proc/Stat
|
||||
/client/Stat()
|
||||
. = ..()
|
||||
if(holder)
|
||||
sleep(1)
|
||||
else
|
||||
sleep(5)
|
||||
stoplag()
|
||||
if(usr && statpanel("Examine"))
|
||||
stat(null,"[description_holders["icon"]] <font size='5'>[description_holders["name"]]</font>") //The name, written in big letters.
|
||||
stat(null,"[description_holders["desc"]]") //the default examine text.
|
||||
|
||||
@@ -153,14 +153,10 @@
|
||||
return has_fine_manipulation
|
||||
|
||||
/mob/living/carbon/alien/Stat()
|
||||
|
||||
..()
|
||||
statpanel("Status")
|
||||
stat(null, "Intent: [a_intent]")
|
||||
stat(null, "Move Mode: [m_intent]")
|
||||
|
||||
..()
|
||||
|
||||
|
||||
show_stat_emergency_shuttle_eta()
|
||||
|
||||
/mob/living/carbon/alien/SetStunned(amount, updating = 1, force = 0)
|
||||
|
||||
@@ -893,11 +893,11 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
|
||||
..()
|
||||
|
||||
/mob/living/carbon/Stat()
|
||||
..()
|
||||
if(statpanel("Status"))
|
||||
var/obj/item/organ/internal/xenos/plasmavessel/vessel = get_int_organ(/obj/item/organ/internal/xenos/plasmavessel)
|
||||
if(vessel)
|
||||
stat(null, "Plasma Stored: [vessel.stored_plasma]/[vessel.max_plasma]")
|
||||
..()
|
||||
|
||||
/mob/living/carbon/get_all_slots()
|
||||
return list(l_hand,
|
||||
|
||||
@@ -144,11 +144,11 @@
|
||||
|
||||
// This adds the basic clock, shuttle recall timer, and malf_ai info to all silicon lifeforms
|
||||
/mob/living/silicon/Stat()
|
||||
..()
|
||||
if(statpanel("Status"))
|
||||
show_stat_station_time()
|
||||
show_stat_emergency_shuttle_eta()
|
||||
show_system_integrity()
|
||||
..()
|
||||
|
||||
//Silicon mob language procs
|
||||
|
||||
|
||||
@@ -67,9 +67,9 @@
|
||||
return
|
||||
|
||||
/mob/new_player/Stat()
|
||||
..()
|
||||
if((!ticker) || ticker.current_state == GAME_STATE_PREGAME)
|
||||
statpanel("Lobby") // First tab during pre-game.
|
||||
..()
|
||||
|
||||
statpanel("Status")
|
||||
if(client.statpanel == "Status" && ticker)
|
||||
|
||||
Reference in New Issue
Block a user