From 649432b8f8963f58bb57c7deb2c5070bd066bbe6 Mon Sep 17 00:00:00 2001 From: xscreach Date: Tue, 25 Jul 2023 03:28:58 +0200 Subject: [PATCH] prevent portal data without timestamp (0) clash with placeholder timestamp (now -1) --- core/code/map_data_render.js | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/core/code/map_data_render.js b/core/code/map_data_render.js index e12fedf8d..4367a5a3c 100644 --- a/core/code/map_data_render.js +++ b/core/code/map_data_render.js @@ -244,14 +244,15 @@ window.Render.prototype.createPlaceholderPortalEntity = function (guid, latE6, l timestamp = timestamp || 0; var ent = [ - guid, //ent[0] = guid - 0, //ent[1] = timestamp - zero will mean any other source of portal data will have a higher timestamp - //ent[2] = an array with the entity data - [ 'p', //0 - a portal - team, //1 - team - latE6, //2 - lat - lngE6 //3 - lng - ] + guid, // ent[0] = guid + -1, // ent[1] = timestamp - zero will mean any other source of portal data will have a higher timestamp + // ent[2] = an array with the entity data + [ + 'p', // 0 - a portal + team, // 1 - team + latE6, // 2 - lat + lngE6, // 3 - lng + ], ]; // placeholder portals don't have a useful timestamp value - so the standard code that checks for updated