iitc-project / ingress-intel-total-conversion

ingress.com/intel total conversion user script with some new features. Should allow easier extension of the intel map.
http://iitc.jonatkins.com/
ISC License
989 stars 552 forks source link

Bug in cross links. #1085

Open Cluuey opened 8 years ago

Cluuey commented 8 years ago

I've noticed I'm getting links showing as cross links which aren't. Not sure how long the links will stay up so this could be hard to fix unless you look quickly.

It works fine on normal intel so I'll past a link here to normal intel and then you can import it into IITC after you know where to look. ;-)

https://www.ingress.com/intel?ll=-36.27860013544234,150.60882568359375&z=9&pls=-37.342376,148.700603,-36.242674,149.131549

Cluuey commented 8 years ago

So I've been asked to provide more info although I can't see any other comments here.

"Plz more details like: Link1 = from portal1 to portal 2 Link2 = from portal3 to portal 4"

The link in the first post gives you the two portals but I'll provide a portal link: https://www.ingress.com/intel?ll=-37.342376,148.700603&z=17&pll=-37.342376,148.700603 If you draw a line from that to just about any portal, I haven't tested them all as I see no point, other than this portal: https://www.ingress.com/intel?ll=-37.223108,149.292838&z=17&pll=-37.223108,149.292838 The link between that portal and this one comes up as a cross link: https://www.ingress.com/intel?ll=-18.865113,-159.755631&z=14&pll=-18.846971,-159.757914

Interestingly you can't go to that portal and see the link in IITC but you can on normal intel.

This might have something to do with the date line?

Cluuey commented 8 years ago

We've only got a limited time window to look into this, those links won't stay up forever. Chatting with other local agents, who've also noticed the bug, they also think it is a date line quirk. The thinking is that the cross links plugin isn't drawing the short version of the link but drawing it going the other way around the globe. This makes sense as they highlight for other drawn links but you don't notice it as you're not zoomed out that far.

mxxcon commented 8 years ago

A screenshot would be helpful to see what exactly you are seeing..

Yes, IITC is known to have issues working through that line. IIRC that's the limitation of leaflet library it uses. It does look like it's drawing a link the long way around the world..

McBen commented 8 years ago

simple test code:

    var a0 = new L.LatLng(149.292838, -37.223108);
    var a1 = new L.LatLng(-159.757914, -18.846971);

    var b0 = new L.LatLng(149.131549, -36.242674);
    var b1 = new L.LatLng(148.700603 , -37.342376);

    it('should not cross', function () {
      var is_crossing = greatCircleArcIntersect(a0,a1,b0,b1);
      is_crossing.should.be.equal(false);
    });
Cluuey commented 8 years ago

So is this something which can't be fixed? Should I just close the ticket?

ltanzos commented 7 years ago

Drew a line from the current shard portal in Changchun, China to the shard target portal in Cleveland, OH, USA. The link passes over the Arctic Sea (north). The line only shows when I'm viewing China, not when I'm viewing Cleveland. Cross links are all south of it. image