{"action":"opened","number":1612,"pull_request":{"url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612","id":92278679,"html_url":"https://github.com/TeamPorcupine/ProjectPorcupine/pull/1612","diff_url":"https://github.com/TeamPorcupine/ProjectPorcupine/pull/1612.diff","patch_url":"https://github.com/TeamPorcupine/ProjectPorcupine/pull/1612.patch","issue_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/1612","number":1612,"state":"open","locked":false,"title":"[WIP] Roombased Pathfinding","user":{"login":"koosemose","id":6334643,"avatar_url":"https://avatars.githubusercontent.com/u/6334643?v=3","gravatar_id":"","url":"https://api.github.com/users/koosemose","html_url":"https://github.com/koosemose","followers_url":"https://api.github.com/users/koosemose/followers","following_url":"https://api.github.com/users/koosemose/following{/other_user}","gists_url":"https://api.github.com/users/koosemose/gists{/gist_id}","starred_url":"https://api.github.com/users/koosemose/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/koosemose/subscriptions","organizations_url":"https://api.github.com/users/koosemose/orgs","repos_url":"https://api.github.com/users/koosemose/repos","events_url":"https://api.github.com/users/koosemose/events{/privacy}","received_events_url":"https://api.github.com/users/koosemose/received_events","type":"User","site_admin":false},"body":"Primarily this implements astar pathfinding based on the groomGraph, making use of GoalEvaluators and Heuristics similar to what is used for tile based path finding.\r\n\r\nIt has similar helper functions living in Pathfinder, and is currently used to find closest inventory and furniture of certain types, as it only needs to pathfind through a smaller number of nodes (rooms instead of tiles) it is drastically faster. Pathfinding for both now find the closest room with the wanted object and then determines which inventory/furniture is closest and returns a tile based path to that. Even though it's technically pathfinding twice, it is still drastically faster to do a dijkstra on the roomGraph, and then use that to find a particular inventory and get a non-dijkstra tile path to the inventory.\r\n\r\nAspects that are missing that I would like to implement before this is ready (If you have any thoughts on how these can be implemented, feel free to share):\r\n[] Way to measure distance between rooms (that doesn't require iterating through each tile in a room and doing some measurements to determine a center, as that would be too slow to use in pathfinding)\r\n[] Have Room Pathfinding check smaller rooms first, this would allow it to avoid going outside when there is inventory/furniture in a room that's just as close.","created_at":"2016-11-04T03:26:14Z","updated_at":"2016-11-04T03:26:14Z","closed_at":null,"merged_at":null,"merge_commit_sha":"79ffed8182d0e13f267448018e9fe06cb8ac2dd2","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612/commits","review_comments_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612/comments","review_comment_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/comments{/number}","comments_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/1612/comments","statuses_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/statuses/bccb19e4d7df7c91295a0c393450c56a65f4c791","head":{"label":"koosemose:Roombased-Pathfinding","ref":"Roombased-Pathfinding","sha":"bccb19e4d7df7c91295a0c393450c56a65f4c791","user":{"login":"koosemose","id":6334643,"avatar_url":"https://avatars.githubusercontent.com/u/6334643?v=3","gravatar_id":"","url":"https://api.github.com/users/koosemose","html_url":"https://github.com/koosemose","followers_url":"https://api.github.com/users/koosemose/followers","following_url":"https://api.github.com/users/koosemose/following{/other_user}","gists_url":"https://api.github.com/users/koosemose/gists{/gist_id}","starred_url":"https://api.github.com/users/koosemose/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/koosemose/subscriptions","organizations_url":"https://api.github.com/users/koosemose/orgs","repos_url":"https://api.github.com/users/koosemose/repos","events_url":"https://api.github.com/users/koosemose/events{/privacy}","received_events_url":"https://api.github.com/users/koosemose/received_events","type":"User","site_admin":false},"repo":{"id":66144748,"name":"ProjectPorcupine","full_name":"koosemose/ProjectPorcupine","owner":{"login":"koosemose","id":6334643,"avatar_url":"https://avatars.githubusercontent.com/u/6334643?v=3","gravatar_id":"","url":"https://api.github.com/users/koosemose","html_url":"https://github.com/koosemose","followers_url":"https://api.github.com/users/koosemose/followers","following_url":"https://api.github.com/users/koosemose/following{/other_user}","gists_url":"https://api.github.com/users/koosemose/gists{/gist_id}","starred_url":"https://api.github.com/users/koosemose/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/koosemose/subscriptions","organizations_url":"https://api.github.com/users/koosemose/orgs","repos_url":"https://api.github.com/users/koosemose/repos","events_url":"https://api.github.com/users/koosemose/events{/privacy}","received_events_url":"https://api.github.com/users/koosemose/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/koosemose/ProjectPorcupine","description":"Project Porcupine: A Base-Building Game...in Space!","fork":true,"url":"https://api.github.com/repos/koosemose/ProjectPorcupine","forks_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/forks","keys_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/teams","hooks_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/hooks","issue_events_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/issues/events{/number}","events_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/events","assignees_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/assignees{/user}","branches_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/branches{/branch}","tags_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/tags","blobs_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/git/refs{/sha}","trees_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/statuses/{sha}","languages_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/languages","stargazers_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/stargazers","contributors_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/contributors","subscribers_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/subscribers","subscription_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/subscription","commits_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/commits{/sha}","git_commits_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/git/commits{/sha}","comments_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/comments{/number}","issue_comment_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/issues/comments{/number}","contents_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/contents/{+path}","compare_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/merges","archive_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/downloads","issues_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/issues{/number}","pulls_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/pulls{/number}","milestones_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/milestones{/number}","notifications_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/labels{/name}","releases_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/releases{/id}","deployments_url":"https://api.github.com/repos/koosemose/ProjectPorcupine/deployments","created_at":"2016-08-20T12:06:45Z","updated_at":"2016-08-20T12:06:47Z","pushed_at":"2016-11-04T03:14:03Z","git_url":"git://github.com/koosemose/ProjectPorcupine.git","ssh_url":"git@github.com:koosemose/ProjectPorcupine.git","clone_url":"https://github.com/koosemose/ProjectPorcupine.git","svn_url":"https://github.com/koosemose/ProjectPorcupine","homepage":null,"size":31941,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"TeamPorcupine:master","ref":"master","sha":"cfc1c5d732e489dae88fdab9115ba42ca3c078d8","user":{"login":"TeamPorcupine","id":1299665,"avatar_url":"https://avatars.githubusercontent.com/u/1299665?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamPorcupine","html_url":"https://github.com/TeamPorcupine","followers_url":"https://api.github.com/users/TeamPorcupine/followers","following_url":"https://api.github.com/users/TeamPorcupine/following{/other_user}","gists_url":"https://api.github.com/users/TeamPorcupine/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamPorcupine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamPorcupine/subscriptions","organizations_url":"https://api.github.com/users/TeamPorcupine/orgs","repos_url":"https://api.github.com/users/TeamPorcupine/repos","events_url":"https://api.github.com/users/TeamPorcupine/events{/privacy}","received_events_url":"https://api.github.com/users/TeamPorcupine/received_events","type":"Organization","site_admin":false},"repo":{"id":65837532,"name":"ProjectPorcupine","full_name":"TeamPorcupine/ProjectPorcupine","owner":{"login":"TeamPorcupine","id":1299665,"avatar_url":"https://avatars.githubusercontent.com/u/1299665?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamPorcupine","html_url":"https://github.com/TeamPorcupine","followers_url":"https://api.github.com/users/TeamPorcupine/followers","following_url":"https://api.github.com/users/TeamPorcupine/following{/other_user}","gists_url":"https://api.github.com/users/TeamPorcupine/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamPorcupine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamPorcupine/subscriptions","organizations_url":"https://api.github.com/users/TeamPorcupine/orgs","repos_url":"https://api.github.com/users/TeamPorcupine/repos","events_url":"https://api.github.com/users/TeamPorcupine/events{/privacy}","received_events_url":"https://api.github.com/users/TeamPorcupine/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TeamPorcupine/ProjectPorcupine","description":"Project Porcupine: A Base-Building Game...in Space!","fork":false,"url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine","forks_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/forks","keys_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/teams","hooks_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/hooks","issue_events_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/events{/number}","events_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/events","assignees_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/assignees{/user}","branches_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/branches{/branch}","tags_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/tags","blobs_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/git/refs{/sha}","trees_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/statuses/{sha}","languages_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/languages","stargazers_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/stargazers","contributors_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/contributors","subscribers_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/subscribers","subscription_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/subscription","commits_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/commits{/sha}","git_commits_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/git/commits{/sha}","comments_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/comments{/number}","issue_comment_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/comments{/number}","contents_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/contents/{+path}","compare_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/merges","archive_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/downloads","issues_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues{/number}","pulls_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls{/number}","milestones_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/milestones{/number}","notifications_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/labels{/name}","releases_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/releases{/id}","deployments_url":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/deployments","created_at":"2016-08-16T16:52:06Z","updated_at":"2016-11-03T03:19:53Z","pushed_at":"2016-11-04T03:26:15Z","git_url":"git://github.com/TeamPorcupine/ProjectPorcupine.git","ssh_url":"git@github.com:TeamPorcupine/ProjectPorcupine.git","clone_url":"https://github.com/TeamPorcupine/ProjectPorcupine.git","svn_url":"https://github.com/TeamPorcupine/ProjectPorcupine","homepage":null,"size":72761,"stargazers_count":365,"watchers_count":365,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":403,"mirror_url":null,"open_issues_count":114,"forks":403,"open_issues":114,"watchers":365,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612"},"html":{"href":"https://github.com/TeamPorcupine/ProjectPorcupine/pull/1612"},"issue":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/1612"},"comments":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/issues/1612/comments"},"review_comments":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612/comments"},"review_comment":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/pulls/1612/commits"},"statuses":{"href":"https://api.github.com/repos/TeamPorcupine/ProjectPorcupine/statuses/bccb19e4d7df7c91295a0c393450c56a65f4c791"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":8,"additions":460,"deletions":27,"changed_files":5}}
{"actor":{"display_login":"koosemose"}}