From 2a35330fb70ed526bc2164ba37982844c66d28a2 Mon Sep 17 00:00:00 2001 From: Jon Atkins Date: Fri, 4 Jul 2014 19:37:19 +0100 Subject: [PATCH] and shortly after I removed the code that limited drawing of very short links... niantic chance the server and start returning them again! so probably better with this re-enabled --- code/map_data_render.js | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/code/map_data_render.js b/code/map_data_render.js index ac5c81b0..52304ca0 100644 --- a/code/map_data_render.js +++ b/code/map_data_render.js @@ -490,16 +490,14 @@ window.Render.prototype.getPortalClusterID = function(portal) { window.Render.prototype.linkVisible = function(link) { - // server now culls short links - so no point in IITC also doing it - return true; -// if (!this.bounds.intersects(link.getBounds())) { -// return false; -// } + if (!this.bounds.intersects(link.getBounds())) { + return false; + } -// var lengthSquared = this.getLinkPixelLengthSquared (link); + var lengthSquared = this.getLinkPixelLengthSquared (link); -// return lengthSquared >= this.LINK_VISIBLE_PIXEL_LENGTH*this.LINK_VISIBLE_PIXEL_LENGTH; + return lengthSquared >= this.LINK_VISIBLE_PIXEL_LENGTH*this.LINK_VISIBLE_PIXEL_LENGTH; }