From 2e5da846a0f3931f108dc2144432672400afd7c9 Mon Sep 17 00:00:00 2001 From: fkloft Date: Fri, 21 Mar 2014 22:30:32 +0100 Subject: [PATCH] Remove CHAT_MIN_RANGE --- code/chat.js | 6 +----- main.js | 4 ---- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/code/chat.js b/code/chat.js index 50cb8fec..bdb69446 100644 --- a/code/chat.js +++ b/code/chat.js @@ -41,9 +41,7 @@ window.chat._oldBBox = null; window.chat.genPostData = function(isFaction, storageHash, getOlderMsgs) { if(typeof isFaction !== 'boolean') throw('Need to know if public or faction chat.'); - // get window bounds, and extend to the minimum chat radius - chat._localRangeCircle.setLatLng(map.getCenter()); - var b = map.getBounds().extend(chat._localRangeCircle.getBounds()); + var b = map.getBounds(); // set a current bounding box if none set so far if (!chat._oldBBox) chat._oldBBox = b; @@ -574,8 +572,6 @@ window.chat.keepScrollPosition = function(box, scrollBefore, isOldMsgs) { // window.chat.setup = function() { - window.chat._localRangeCircle = L.circle(map.getCenter(), CHAT_MIN_RANGE*1000); - if (localStorage['iitc-chat-tab']) { var t = $(''+localStorage['iitc-chat-tab']+''); window.chat.chooseAnchor(t); diff --git a/main.js b/main.js index f07ccd52..6a4146ff 100644 --- a/main.js +++ b/main.js @@ -142,10 +142,6 @@ window.MAX_IDLE_TIME = 4*60; // stop updating map after 4min idling window.PRECACHE_PLAYER_NAMES_ZOOM = 17; // zoom level to start pre-resolving player names window.HIDDEN_SCROLLBAR_ASSUMED_WIDTH = 20; window.SIDEBAR_WIDTH = 300; -// chat messages are requested for the visible viewport. On high zoom -// levels this gets pretty pointless, so request messages in at least a -// X km radius. -window.CHAT_MIN_RANGE = 6; // this controls how far data is being drawn outside the viewport. Set // it 0 to only draw entities that intersect the current view. A value // of one will render an area twice the size of the viewport (or some-