{"action":"created","comment":{"url":"https://api.github.com/repos/runelite/runelite/pulls/comments/168931520","pull_request_review_id":97383689,"id":168931520,"diff_hunk":"@@ -0,0 +1,113 @@\n+/*\n+ * Copyright (c) 2018 Abex\n+ * All rights reserved.\n+ *\n+ * Redistribution and use in source and binary forms, with or without\n+ * modification, are permitted provided that the following conditions are met:\n+ *\n+ * 1. Redistributions of source code must retain the above copyright notice, this\n+ *    list of conditions and the following disclaimer.\n+ * 2. Redistributions in binary form must reproduce the above copyright notice,\n+ *    this list of conditions and the following disclaimer in the documentation\n+ *    and/or other materials provided with the distribution.\n+ *\n+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND\n+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\n+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\n+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR\n+ * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n+ * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\n+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\n+ * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS\n+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n+ */\n+package net.runelite.client.plugins.kourendlibrary;\n+\n+import java.util.HashSet;\n+import java.util.Set;\n+import lombok.Getter;\n+import lombok.RequiredArgsConstructor;\n+\n+@RequiredArgsConstructor\n+class Bookcase\n+{\n+\t@Getter\n+\tprivate final Point3D location;\n+\n+\t@Getter\n+\tprivate final int index;\n+\n+\t@Getter\n+\tprivate boolean isBookSet;\n+\n+\t/**\n+\t * Book in this bookcase as found by the player.\n+\t * Will be correct as long as isBookSet is true, unless the library has reset;\n+\t */\n+\t@Getter\n+\tprivate Book book;\n+\n+\t/**\n+\t * Books that can be in this slot. Will only be populated if library.state != SolvedState.NO_DATA\n+\t */\n+\t@Getter\n+\tprivate Set<Book> possibleBooks = new HashSet<>();\n+\n+\tpublic void clearBook()\n+\t{\n+\t\tbook = null;\n+\t\tisBookSet = false;\n+\t}\n+\n+\tpublic void setBook(Book book)\n+\t{\n+\t\tthis.book = book;\n+\t\tthis.isBookSet = true;\n+\t}\n+\n+\tpublic String getLocationString()\n+\t{\n+\t\tStringBuilder b = new StringBuilder();\n+\n+\t\tboolean north = location.getY() > 3815;\n+\t\tboolean west = location.getX() < 1625;\n+\t\tif (north && west)\n+\t\t{\n+\t\t\tb.append(\"Northwest\");\n+\t\t}\n+\t\telse if (north)\n+\t\t{\n+\t\t\tb.append(\"Northeast\");\n+\t\t}\n+\t\telse if (west)\n+\t\t{\n+\t\t\tb.append(\"Southwest\");\n+\t\t}\n+\t\telse\n+\t\t{\n+\t\t\tb.append(\"Center\");\n+\t\t}\n+\n+\t\tb.append(\" \");\n+\n+\t\tswitch (location.getZ())\n+\t\t{\n+\t\t\tcase 0:\n+\t\t\t\tb.append(\"ground floor\");\n+\t\t\t\tbreak;\n+\t\t\tcase 1:\n+\t\t\t\tb.append(\"middle floor\");\n+\t\t\t\tbreak;\n+\t\t\tcase 2:\n+\t\t\t\tb.append(\"top floor\");\n+\t\t\t\tbreak;\n+\t\t}\n+\n+\t\tif (KourendLibraryPlugin.debug)","path":"runelite-client/src/main/java/net/runelite/client/plugins/kourendlibrary/Bookcase.java","position":107,"original_position":107,"commit_id":"ef98a4c69377e7820ac495b7e385bcfe8e64d4d6","original_commit_id":"ef98a4c69377e7820ac495b7e385bcfe8e64d4d6","user":{"login":"deathbeam","id":5115805,"avatar_url":"https://avatars3.githubusercontent.com/u/5115805?v=4","gravatar_id":"","url":"https://api.github.com/users/deathbeam","html_url":"https://github.com/deathbeam","followers_url":"https://api.github.com/users/deathbeam/followers","following_url":"https://api.github.com/users/deathbeam/following{/other_user}","gists_url":"https://api.github.com/users/deathbeam/gists{/gist_id}","starred_url":"https://api.github.com/users/deathbeam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deathbeam/subscriptions","organizations_url":"https://api.github.com/users/deathbeam/orgs","repos_url":"https://api.github.com/users/deathbeam/repos","events_url":"https://api.github.com/users/deathbeam/events{/privacy}","received_events_url":"https://api.github.com/users/deathbeam/received_events","type":"User","site_admin":false},"body":"This should probably be romoved?","created_at":"2018-02-17T20:03:07Z","updated_at":"2018-02-17T20:27:54Z","html_url":"https://github.com/runelite/runelite/pull/612#discussion_r168931520","pull_request_url":"https://api.github.com/repos/runelite/runelite/pulls/612","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/runelite/runelite/pulls/comments/168931520"},"html":{"href":"https://github.com/runelite/runelite/pull/612#discussion_r168931520"},"pull_request":{"href":"https://api.github.com/repos/runelite/runelite/pulls/612"}}},"pull_request":{"url":"https://api.github.com/repos/runelite/runelite/pulls/612","id":169774920,"html_url":"https://github.com/runelite/runelite/pull/612","diff_url":"https://github.com/runelite/runelite/pull/612.diff","patch_url":"https://github.com/runelite/runelite/pull/612.patch","issue_url":"https://api.github.com/repos/runelite/runelite/issues/612","number":612,"state":"open","locked":false,"title":"[WIP] Add kourend library plugin","user":{"login":"Abextm","id":12366911,"avatar_url":"https://avatars2.githubusercontent.com/u/12366911?v=4","gravatar_id":"","url":"https://api.github.com/users/Abextm","html_url":"https://github.com/Abextm","followers_url":"https://api.github.com/users/Abextm/followers","following_url":"https://api.github.com/users/Abextm/following{/other_user}","gists_url":"https://api.github.com/users/Abextm/gists{/gist_id}","starred_url":"https://api.github.com/users/Abextm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Abextm/subscriptions","organizations_url":"https://api.github.com/users/Abextm/orgs","repos_url":"https://api.github.com/users/Abextm/repos","events_url":"https://api.github.com/users/Abextm/events{/privacy}","received_events_url":"https://api.github.com/users/Abextm/received_events","type":"User","site_admin":false},"body":"Adds a plugin predicting where books are in the Arceuus House library.\r\n\r\nFixes #477 \r\n\r\nhttps://www.youtube.com/watch?v=lsIdemA7q7A\r\n\r\nAs of now this still needs some UI and detection changes, but the core prediction logic is correct to my knowledge.","created_at":"2018-02-17T08:45:08Z","updated_at":"2018-02-17T20:27:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8ea3e3435ddaf2477069380231dd5768c96e174d","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":771846940,"url":"https://api.github.com/repos/runelite/runelite/labels/feature-request","name":"feature-request","color":"fbca04","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/runelite/runelite/pulls/612/commits","review_comments_url":"https://api.github.com/repos/runelite/runelite/pulls/612/comments","review_comment_url":"https://api.github.com/repos/runelite/runelite/pulls/comments{/number}","comments_url":"https://api.github.com/repos/runelite/runelite/issues/612/comments","statuses_url":"https://api.github.com/repos/runelite/runelite/statuses/ef98a4c69377e7820ac495b7e385bcfe8e64d4d6","head":{"label":"Abextm:kourend-library","ref":"kourend-library","sha":"ef98a4c69377e7820ac495b7e385bcfe8e64d4d6","user":{"login":"Abextm","id":12366911,"avatar_url":"https://avatars2.githubusercontent.com/u/12366911?v=4","gravatar_id":"","url":"https://api.github.com/users/Abextm","html_url":"https://github.com/Abextm","followers_url":"https://api.github.com/users/Abextm/followers","following_url":"https://api.github.com/users/Abextm/following{/other_user}","gists_url":"https://api.github.com/users/Abextm/gists{/gist_id}","starred_url":"https://api.github.com/users/Abextm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Abextm/subscriptions","organizations_url":"https://api.github.com/users/Abextm/orgs","repos_url":"https://api.github.com/users/Abextm/repos","events_url":"https://api.github.com/users/Abextm/events{/privacy}","received_events_url":"https://api.github.com/users/Abextm/received_events","type":"User","site_admin":false},"repo":{"id":116477461,"name":"runelite","full_name":"Abextm/runelite","owner":{"login":"Abextm","id":12366911,"avatar_url":"https://avatars2.githubusercontent.com/u/12366911?v=4","gravatar_id":"","url":"https://api.github.com/users/Abextm","html_url":"https://github.com/Abextm","followers_url":"https://api.github.com/users/Abextm/followers","following_url":"https://api.github.com/users/Abextm/following{/other_user}","gists_url":"https://api.github.com/users/Abextm/gists{/gist_id}","starred_url":"https://api.github.com/users/Abextm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Abextm/subscriptions","organizations_url":"https://api.github.com/users/Abextm/orgs","repos_url":"https://api.github.com/users/Abextm/repos","events_url":"https://api.github.com/users/Abextm/events{/privacy}","received_events_url":"https://api.github.com/users/Abextm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Abextm/runelite","description":"Open source Old School RuneScape client","fork":true,"url":"https://api.github.com/repos/Abextm/runelite","forks_url":"https://api.github.com/repos/Abextm/runelite/forks","keys_url":"https://api.github.com/repos/Abextm/runelite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Abextm/runelite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Abextm/runelite/teams","hooks_url":"https://api.github.com/repos/Abextm/runelite/hooks","issue_events_url":"https://api.github.com/repos/Abextm/runelite/issues/events{/number}","events_url":"https://api.github.com/repos/Abextm/runelite/events","assignees_url":"https://api.github.com/repos/Abextm/runelite/assignees{/user}","branches_url":"https://api.github.com/repos/Abextm/runelite/branches{/branch}","tags_url":"https://api.github.com/repos/Abextm/runelite/tags","blobs_url":"https://api.github.com/repos/Abextm/runelite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Abextm/runelite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Abextm/runelite/git/refs{/sha}","trees_url":"https://api.github.com/repos/Abextm/runelite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Abextm/runelite/statuses/{sha}","languages_url":"https://api.github.com/repos/Abextm/runelite/languages","stargazers_url":"https://api.github.com/repos/Abextm/runelite/stargazers","contributors_url":"https://api.github.com/repos/Abextm/runelite/contributors","subscribers_url":"https://api.github.com/repos/Abextm/runelite/subscribers","subscription_url":"https://api.github.com/repos/Abextm/runelite/subscription","commits_url":"https://api.github.com/repos/Abextm/runelite/commits{/sha}","git_commits_url":"https://api.github.com/repos/Abextm/runelite/git/commits{/sha}","comments_url":"https://api.github.com/repos/Abextm/runelite/comments{/number}","issue_comment_url":"https://api.github.com/repos/Abextm/runelite/issues/comments{/number}","contents_url":"https://api.github.com/repos/Abextm/runelite/contents/{+path}","compare_url":"https://api.github.com/repos/Abextm/runelite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Abextm/runelite/merges","archive_url":"https://api.github.com/repos/Abextm/runelite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Abextm/runelite/downloads","issues_url":"https://api.github.com/repos/Abextm/runelite/issues{/number}","pulls_url":"https://api.github.com/repos/Abextm/runelite/pulls{/number}","milestones_url":"https://api.github.com/repos/Abextm/runelite/milestones{/number}","notifications_url":"https://api.github.com/repos/Abextm/runelite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Abextm/runelite/labels{/name}","releases_url":"https://api.github.com/repos/Abextm/runelite/releases{/id}","deployments_url":"https://api.github.com/repos/Abextm/runelite/deployments","created_at":"2018-01-06T11:28:25Z","updated_at":"2018-01-06T11:28:30Z","pushed_at":"2018-02-17T08:41:24Z","git_url":"git://github.com/Abextm/runelite.git","ssh_url":"git@github.com:Abextm/runelite.git","clone_url":"https://github.com/Abextm/runelite.git","svn_url":"https://github.com/Abextm/runelite","homepage":"https://runelite.net","size":31437,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"runelite:master","ref":"master","sha":"3c0ed83125506f59654596880a98110e37f1e5a7","user":{"login":"runelite","id":13814776,"avatar_url":"https://avatars1.githubusercontent.com/u/13814776?v=4","gravatar_id":"","url":"https://api.github.com/users/runelite","html_url":"https://github.com/runelite","followers_url":"https://api.github.com/users/runelite/followers","following_url":"https://api.github.com/users/runelite/following{/other_user}","gists_url":"https://api.github.com/users/runelite/gists{/gist_id}","starred_url":"https://api.github.com/users/runelite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/runelite/subscriptions","organizations_url":"https://api.github.com/users/runelite/orgs","repos_url":"https://api.github.com/users/runelite/repos","events_url":"https://api.github.com/users/runelite/events{/privacy}","received_events_url":"https://api.github.com/users/runelite/received_events","type":"Organization","site_admin":false},"repo":{"id":57461213,"name":"runelite","full_name":"runelite/runelite","owner":{"login":"runelite","id":13814776,"avatar_url":"https://avatars1.githubusercontent.com/u/13814776?v=4","gravatar_id":"","url":"https://api.github.com/users/runelite","html_url":"https://github.com/runelite","followers_url":"https://api.github.com/users/runelite/followers","following_url":"https://api.github.com/users/runelite/following{/other_user}","gists_url":"https://api.github.com/users/runelite/gists{/gist_id}","starred_url":"https://api.github.com/users/runelite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/runelite/subscriptions","organizations_url":"https://api.github.com/users/runelite/orgs","repos_url":"https://api.github.com/users/runelite/repos","events_url":"https://api.github.com/users/runelite/events{/privacy}","received_events_url":"https://api.github.com/users/runelite/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/runelite/runelite","description":"Open source Old School RuneScape client","fork":false,"url":"https://api.github.com/repos/runelite/runelite","forks_url":"https://api.github.com/repos/runelite/runelite/forks","keys_url":"https://api.github.com/repos/runelite/runelite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/runelite/runelite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/runelite/runelite/teams","hooks_url":"https://api.github.com/repos/runelite/runelite/hooks","issue_events_url":"https://api.github.com/repos/runelite/runelite/issues/events{/number}","events_url":"https://api.github.com/repos/runelite/runelite/events","assignees_url":"https://api.github.com/repos/runelite/runelite/assignees{/user}","branches_url":"https://api.github.com/repos/runelite/runelite/branches{/branch}","tags_url":"https://api.github.com/repos/runelite/runelite/tags","blobs_url":"https://api.github.com/repos/runelite/runelite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/runelite/runelite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/runelite/runelite/git/refs{/sha}","trees_url":"https://api.github.com/repos/runelite/runelite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/runelite/runelite/statuses/{sha}","languages_url":"https://api.github.com/repos/runelite/runelite/languages","stargazers_url":"https://api.github.com/repos/runelite/runelite/stargazers","contributors_url":"https://api.github.com/repos/runelite/runelite/contributors","subscribers_url":"https://api.github.com/repos/runelite/runelite/subscribers","subscription_url":"https://api.github.com/repos/runelite/runelite/subscription","commits_url":"https://api.github.com/repos/runelite/runelite/commits{/sha}","git_commits_url":"https://api.github.com/repos/runelite/runelite/git/commits{/sha}","comments_url":"https://api.github.com/repos/runelite/runelite/comments{/number}","issue_comment_url":"https://api.github.com/repos/runelite/runelite/issues/comments{/number}","contents_url":"https://api.github.com/repos/runelite/runelite/contents/{+path}","compare_url":"https://api.github.com/repos/runelite/runelite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/runelite/runelite/merges","archive_url":"https://api.github.com/repos/runelite/runelite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/runelite/runelite/downloads","issues_url":"https://api.github.com/repos/runelite/runelite/issues{/number}","pulls_url":"https://api.github.com/repos/runelite/runelite/pulls{/number}","milestones_url":"https://api.github.com/repos/runelite/runelite/milestones{/number}","notifications_url":"https://api.github.com/repos/runelite/runelite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/runelite/runelite/labels{/name}","releases_url":"https://api.github.com/repos/runelite/runelite/releases{/id}","deployments_url":"https://api.github.com/repos/runelite/runelite/deployments","created_at":"2016-04-30T20:48:02Z","updated_at":"2018-02-17T17:33:08Z","pushed_at":"2018-02-17T20:10:33Z","git_url":"git://github.com/runelite/runelite.git","ssh_url":"git@github.com:runelite/runelite.git","clone_url":"https://github.com/runelite/runelite.git","svn_url":"https://github.com/runelite/runelite","homepage":"https://runelite.net","size":31346,"stargazers_count":139,"watchers_count":139,"language":"Java","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":91,"mirror_url":null,"archived":false,"open_issues_count":103,"license":{"key":"bsd-2-clause","name":"BSD 2-Clause \"Simplified\" License","spdx_id":"BSD-2-Clause","url":"https://api.github.com/licenses/bsd-2-clause"},"forks":91,"open_issues":103,"watchers":139,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/runelite/runelite/pulls/612"},"html":{"href":"https://github.com/runelite/runelite/pull/612"},"issue":{"href":"https://api.github.com/repos/runelite/runelite/issues/612"},"comments":{"href":"https://api.github.com/repos/runelite/runelite/issues/612/comments"},"review_comments":{"href":"https://api.github.com/repos/runelite/runelite/pulls/612/comments"},"review_comment":{"href":"https://api.github.com/repos/runelite/runelite/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/runelite/runelite/pulls/612/commits"},"statuses":{"href":"https://api.github.com/repos/runelite/runelite/statuses/ef98a4c69377e7820ac495b7e385bcfe8e64d4d6"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"deathbeam"}}