Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update portal counts plugin to integrate with draw tools and uniques #371

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

erikchristiansson
Copy link

Display count of unvisited and uncaptured portals if the uniques plugin is installed.

If any polygons are draw, only count portals in the polygons.

@modos189 modos189 added enhancement New feature or request plugin labels Jul 3, 2020
@modos189 modos189 self-assigned this Jul 3, 2020
Copy link
Contributor

@modos189 modos189 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest not to convert coordinates to string when passing a variable to function. And specify a link to description of function. That's what I did in comments to PR.

plugins/portal-counts.js Outdated Show resolved Hide resolved
plugins/portal-counts.js Outdated Show resolved Hide resolved
plugins/portal-counts.js Outdated Show resolved Hide resolved
plugins/portal-counts.js Outdated Show resolved Hide resolved
plugins/portal-counts.js Outdated Show resolved Hide resolved
erikchristiansson and others added 5 commits July 12, 2020 19:46
Co-authored-by: Alexander Danilov <[email protected]>
Co-authored-by: Alexander Danilov <[email protected]>
Co-authored-by: Alexander Danilov <[email protected]>
Co-authored-by: Alexander Danilov <[email protected]>
Co-authored-by: Alexander Danilov <[email protected]>
@erikchristiansson
Copy link
Author

I suggest not to convert coordinates to string when passing a variable to function. And specify a link to description of function. That's what I did in comments to PR.

Good suggestions! All proposed changes merged.

modos189
modos189 previously approved these changes Jul 12, 2020
// Determine if a point is inside of a polygon.
// ray-casting algorithm based on
// https://observablehq.com/@tmcw/understanding-point-in-polygon
window.plugin.portalcounts.portalinpolygon = function(portal,LatLngsObjectsArray) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@modos189

  1. Shouldn't we include some pip algorithm in IITC api? It is used in many plugins already.
  2. I'm going to open separate issue to discuss another opportunity: what if we provide general portal-filtering API?
    For example, it'd be possible to use more convenient region selection tools, like these: Idea: region selection utility #27

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be great if common functions were included in API. We can replace this code when corresponding API appears

@modos189 modos189 force-pushed the master branch 3 times, most recently from a34b800 to 7b9edd5 Compare December 12, 2020 07:21
@johnd0e
Copy link
Contributor

johnd0e commented Mar 15, 2021

@erikchristiansson
Perhaps this now need to be updated to use intel portal history

@johnd0e johnd0e dismissed modos189’s stale review March 15, 2021 09:46

intel portal history not supported yet

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants