mirror of
https://github.com/CHOMPstation/CHOMPstation.git
synced 2026-08-24 20:46:29 +01:00
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:
@@ -47,7 +47,7 @@
|
||||
qdel(active_dummy)
|
||||
active_dummy = null
|
||||
usr << "<span class='notice'>You deactivate the [src].</span>"
|
||||
var/obj/effect/overlay/T = PoolOrNew(/obj/effect/overlay, get_turf(src))
|
||||
var/obj/effect/overlay/T = new /obj/effect/overlay(get_turf(src))
|
||||
T.icon = 'icons/effects/effects.dmi'
|
||||
flick("emppulse",T)
|
||||
spawn(8) qdel(T)
|
||||
@@ -55,7 +55,7 @@
|
||||
playsound(get_turf(src), 'sound/effects/pop.ogg', 100, 1, -6)
|
||||
var/obj/O = new saved_item(src)
|
||||
if(!O) return
|
||||
var/obj/effect/dummy/chameleon/C = PoolOrNew(/obj/effect/dummy/chameleon, usr.loc)
|
||||
var/obj/effect/dummy/chameleon/C = new /obj/effect/dummy/chameleon(usr.loc)
|
||||
C.activate(O, usr, saved_icon, saved_icon_state, saved_overlays, src)
|
||||
qdel(O)
|
||||
usr << "<span class='notice'>You activate the [src].</span>"
|
||||
|
||||
@@ -107,7 +107,7 @@
|
||||
spawn(0)
|
||||
if(!src || !reagents.total_volume) return
|
||||
|
||||
var/obj/effect/effect/water/W = PoolOrNew(/obj/effect/effect/water, get_turf(src))
|
||||
var/obj/effect/effect/water/W = new /obj/effect/effect/water(get_turf(src))
|
||||
var/turf/my_target
|
||||
if(a <= the_targets.len)
|
||||
my_target = the_targets[a]
|
||||
|
||||
@@ -86,7 +86,7 @@
|
||||
if(ptank)
|
||||
ptank.loc = T
|
||||
ptank = null
|
||||
PoolOrNew(/obj/item/stack/rods, T)
|
||||
new /obj/item/stack/rods(T)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
|
||||
/obj/item/weapon/grenade/smokebomb/New()
|
||||
..()
|
||||
src.smoke = PoolOrNew(/datum/effect/effect/system/smoke_spread/bad)
|
||||
src.smoke = new /datum/effect/effect/system/smoke_spread/bad()
|
||||
src.smoke.attach(src)
|
||||
|
||||
/obj/item/weapon/grenade/smokebomb/Destroy()
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
. = ..()
|
||||
|
||||
if(.)
|
||||
var/datum/effect/effect/system/spark_spread/spark_system = PoolOrNew(/datum/effect/effect/system/spark_spread)
|
||||
var/datum/effect/effect/system/spark_spread/spark_system = new /datum/effect/effect/system/spark_spread()
|
||||
spark_system.set_up(5, 0, user.loc)
|
||||
spark_system.start()
|
||||
playsound(user.loc, 'sound/weapons/blade1.ogg', 50, 1)
|
||||
|
||||
Reference in New Issue
Block a user