Optimization/Rewrite of Radiation Controller

* The performance of the radiation controller as-is was not fast enough for inclusion in production servers, but it has some nice featuers, so rewrote it to be more performant.
* Instead of storing the radiation strength for every turf, we only store the sources of radiation, and calculate the strength only for mobs who might be in range.
   * Old method was ray-tracing to every turf in range whether anything was there to be irradiated or not.  Could be hundreds of turfs.  New method only lazily calcualtes strength at a turf if we actually need to know it.   Often times this is zero turfs if nobody is standing in engineering.
  * Removed the automatic processing of objects with "rad_power" set.  Objects are responsible for calling the repository to create/update their radiation sources.   Saves some extra overhead that in practice was redundant with other process controllers.
  * Also tweaked to be more respectful of qdel'd objects and added some comments.
This commit is contained in:
Leshana
2017-05-25 18:43:56 -04:00
parent b1250a4391
commit 34c73dab69
16 changed files with 172 additions and 150 deletions
+1 -1
View File
@@ -559,4 +559,4 @@ var/list/mining_overlay_cache = list()
if(mineral_name && (mineral_name in ore_data))
mineral = ore_data[mineral_name]
UpdateMineral()
update_icon()
update_icon()