Removes the datum pool, as it is not performant.

* Creating new objects is cheap, in fact comparable to the cost of getting it out of the pool, so it doesn't help there.
* Placing items in the pool is far more expensive than letting them garbage collect due to the resetting of vars and such.
This commit is contained in:
Leshana
2017-05-03 20:39:59 -04:00
parent 3c9698c53d
commit 44ff1a70c6
55 changed files with 92 additions and 217 deletions

View File

@@ -32,11 +32,6 @@
my_mob.client.screen -= src
my_mob = null
/obj/screen/movable/ability_master/ResetVars()
..("ability_objects", args)
remove_all_abilities()
// ability_objects = list()
/obj/screen/movable/ability_master/MouseDrop()
if(showing)
return

View File

@@ -20,7 +20,7 @@
return null
if(!screen)
screen = PoolOrNew(type)
screen = new type()
screen.icon_state = "[initial(screen.icon_state)][severity]"
screen.severity = severity

View File

@@ -23,10 +23,6 @@
spell_holder.client.screen -= src
spell_holder = null
/obj/screen/movable/spell_master/ResetVars()
..("spell_objects", args)
spell_objects = list()
/obj/screen/movable/spell_master/MouseDrop()
if(showing)
return
@@ -93,7 +89,7 @@
if(spell.spell_flags & NO_BUTTON) //no button to add if we don't get one
return
var/obj/screen/spell/newscreen = PoolOrNew(/obj/screen/spell)
var/obj/screen/spell/newscreen = new /obj/screen/spell()
newscreen.spellmaster = src
newscreen.spell = spell

View File

@@ -149,7 +149,7 @@ var/const/tk_maxrange = 15
/obj/item/tk_grab/proc/apply_focus_overlay()
if(!focus) return
var/obj/effect/overlay/O = PoolOrNew(/obj/effect/overlay, locate(focus.x,focus.y,focus.z))
var/obj/effect/overlay/O = new /obj/effect/overlay(locate(focus.x,focus.y,focus.z))
O.name = "sparkles"
O.anchored = 1
O.density = 0