{"action":"created","comment":{"url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/comments/74704935","id":74704935,"diff_hunk":"@@ -667,11 +690,42 @@ private void spawnCitizen(CitizenData data)\n \n             entity.setPosition(spawnPoint.getX(), spawnPoint.getY(), spawnPoint.getZ());\n             world.spawnEntityInWorld(entity);\n+            \n+            checkAchievements();\n \n             markCitizensDirty();\n         }\n     }\n+    \n+    /**\n+     * Checks if the achievements are valid\n+     * \n+     */\n+    private void checkAchievements()\n+    {\n+        // Get the colonies owner UUID\n+        final UUID uuidOwner = this.getPermissions().getOwner();\n+        // the colonies size\n+        final int size = this.citizens.size();\n+        \n+        EntityPlayer owner = ServerUtils.getPlayerOnServerFromUUID(uuidOwner);","path":"src/main/java/com/minecolonies/colony/Colony.java","position":77,"original_position":77,"commit_id":"fc2db862a099b16d77ceaaa53879704402c3fcee","original_commit_id":"fc2db862a099b16d77ceaaa53879704402c3fcee","user":{"login":"cltnschlosser","id":1498529,"avatar_url":"https://avatars.githubusercontent.com/u/1498529?v=3","gravatar_id":"","url":"https://api.github.com/users/cltnschlosser","html_url":"https://github.com/cltnschlosser","followers_url":"https://api.github.com/users/cltnschlosser/followers","following_url":"https://api.github.com/users/cltnschlosser/following{/other_user}","gists_url":"https://api.github.com/users/cltnschlosser/gists{/gist_id}","starred_url":"https://api.github.com/users/cltnschlosser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cltnschlosser/subscriptions","organizations_url":"https://api.github.com/users/cltnschlosser/orgs","repos_url":"https://api.github.com/users/cltnschlosser/repos","events_url":"https://api.github.com/users/cltnschlosser/events{/privacy}","received_events_url":"https://api.github.com/users/cltnschlosser/received_events","type":"User","site_admin":false},"body":"I'd prefer if we made a getOwner method in Colony that returned the owner EntityPlayer, and then we could call getOwner().triggerAchievement and we could only be getting the owner if we need to.","created_at":"2016-08-14T16:40:30Z","updated_at":"2016-08-14T16:40:30Z","html_url":"https://github.com/Minecolonies/minecolonies/pull/12#discussion_r74704935","pull_request_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12","_links":{"self":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/comments/74704935"},"html":{"href":"https://github.com/Minecolonies/minecolonies/pull/12#discussion_r74704935"},"pull_request":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12"}}},"pull_request":{"url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12","id":81222058,"html_url":"https://github.com/Minecolonies/minecolonies/pull/12","diff_url":"https://github.com/Minecolonies/minecolonies/pull/12.diff","patch_url":"https://github.com/Minecolonies/minecolonies/pull/12.patch","issue_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/12","number":12,"state":"open","locked":false,"title":"Closes #11","user":{"login":"Kostronor","id":644950,"avatar_url":"https://avatars.githubusercontent.com/u/644950?v=3","gravatar_id":"","url":"https://api.github.com/users/Kostronor","html_url":"https://github.com/Kostronor","followers_url":"https://api.github.com/users/Kostronor/followers","following_url":"https://api.github.com/users/Kostronor/following{/other_user}","gists_url":"https://api.github.com/users/Kostronor/gists{/gist_id}","starred_url":"https://api.github.com/users/Kostronor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kostronor/subscriptions","organizations_url":"https://api.github.com/users/Kostronor/orgs","repos_url":"https://api.github.com/users/Kostronor/repos","events_url":"https://api.github.com/users/Kostronor/events{/privacy}","received_events_url":"https://api.github.com/users/Kostronor/received_events","type":"User","site_admin":false},"body":"This is just so we track the progress of achievements\r\n","created_at":"2016-08-13T17:54:43Z","updated_at":"2016-08-14T16:40:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"eeefe9b9b79ff7c6c74be32a3ec8d03be429b3e5","assignee":{"login":"Isfirs","id":2435878,"avatar_url":"https://avatars.githubusercontent.com/u/2435878?v=3","gravatar_id":"","url":"https://api.github.com/users/Isfirs","html_url":"https://github.com/Isfirs","followers_url":"https://api.github.com/users/Isfirs/followers","following_url":"https://api.github.com/users/Isfirs/following{/other_user}","gists_url":"https://api.github.com/users/Isfirs/gists{/gist_id}","starred_url":"https://api.github.com/users/Isfirs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Isfirs/subscriptions","organizations_url":"https://api.github.com/users/Isfirs/orgs","repos_url":"https://api.github.com/users/Isfirs/repos","events_url":"https://api.github.com/users/Isfirs/events{/privacy}","received_events_url":"https://api.github.com/users/Isfirs/received_events","type":"User","site_admin":false},"assignees":[{"login":"Isfirs","id":2435878,"avatar_url":"https://avatars.githubusercontent.com/u/2435878?v=3","gravatar_id":"","url":"https://api.github.com/users/Isfirs","html_url":"https://github.com/Isfirs","followers_url":"https://api.github.com/users/Isfirs/followers","following_url":"https://api.github.com/users/Isfirs/following{/other_user}","gists_url":"https://api.github.com/users/Isfirs/gists{/gist_id}","starred_url":"https://api.github.com/users/Isfirs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Isfirs/subscriptions","organizations_url":"https://api.github.com/users/Isfirs/orgs","repos_url":"https://api.github.com/users/Isfirs/repos","events_url":"https://api.github.com/users/Isfirs/events{/privacy}","received_events_url":"https://api.github.com/users/Isfirs/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/Minecolonies/minecolonies/milestones/1","html_url":"https://github.com/Minecolonies/minecolonies/milestones/Material%20Handling","labels_url":"https://api.github.com/repos/Minecolonies/minecolonies/milestones/1/labels","id":1940358,"number":1,"title":"Material Handling","description":"","creator":{"login":"Kostronor","id":644950,"avatar_url":"https://avatars.githubusercontent.com/u/644950?v=3","gravatar_id":"","url":"https://api.github.com/users/Kostronor","html_url":"https://github.com/Kostronor","followers_url":"https://api.github.com/users/Kostronor/followers","following_url":"https://api.github.com/users/Kostronor/following{/other_user}","gists_url":"https://api.github.com/users/Kostronor/gists{/gist_id}","starred_url":"https://api.github.com/users/Kostronor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kostronor/subscriptions","organizations_url":"https://api.github.com/users/Kostronor/orgs","repos_url":"https://api.github.com/users/Kostronor/repos","events_url":"https://api.github.com/users/Kostronor/events{/privacy}","received_events_url":"https://api.github.com/users/Kostronor/received_events","type":"User","site_admin":false},"open_issues":6,"closed_issues":0,"state":"open","created_at":"2016-08-13T17:38:27Z","updated_at":"2016-08-14T11:38:57Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12/commits","review_comments_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12/comments","review_comment_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/12/comments","statuses_url":"https://api.github.com/repos/Minecolonies/minecolonies/statuses/fc2db862a099b16d77ceaaa53879704402c3fcee","head":{"label":"Minecolonies:MINECOL-77-achievements","ref":"MINECOL-77-achievements","sha":"fc2db862a099b16d77ceaaa53879704402c3fcee","user":{"login":"Minecolonies","id":5167336,"avatar_url":"https://avatars.githubusercontent.com/u/5167336?v=3","gravatar_id":"","url":"https://api.github.com/users/Minecolonies","html_url":"https://github.com/Minecolonies","followers_url":"https://api.github.com/users/Minecolonies/followers","following_url":"https://api.github.com/users/Minecolonies/following{/other_user}","gists_url":"https://api.github.com/users/Minecolonies/gists{/gist_id}","starred_url":"https://api.github.com/users/Minecolonies/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Minecolonies/subscriptions","organizations_url":"https://api.github.com/users/Minecolonies/orgs","repos_url":"https://api.github.com/users/Minecolonies/repos","events_url":"https://api.github.com/users/Minecolonies/events{/privacy}","received_events_url":"https://api.github.com/users/Minecolonies/received_events","type":"Organization","site_admin":false},"repo":{"id":65616760,"name":"minecolonies","full_name":"Minecolonies/minecolonies","owner":{"login":"Minecolonies","id":5167336,"avatar_url":"https://avatars.githubusercontent.com/u/5167336?v=3","gravatar_id":"","url":"https://api.github.com/users/Minecolonies","html_url":"https://github.com/Minecolonies","followers_url":"https://api.github.com/users/Minecolonies/followers","following_url":"https://api.github.com/users/Minecolonies/following{/other_user}","gists_url":"https://api.github.com/users/Minecolonies/gists{/gist_id}","starred_url":"https://api.github.com/users/Minecolonies/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Minecolonies/subscriptions","organizations_url":"https://api.github.com/users/Minecolonies/orgs","repos_url":"https://api.github.com/users/Minecolonies/repos","events_url":"https://api.github.com/users/Minecolonies/events{/privacy}","received_events_url":"https://api.github.com/users/Minecolonies/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Minecolonies/minecolonies","description":null,"fork":false,"url":"https://api.github.com/repos/Minecolonies/minecolonies","forks_url":"https://api.github.com/repos/Minecolonies/minecolonies/forks","keys_url":"https://api.github.com/repos/Minecolonies/minecolonies/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Minecolonies/minecolonies/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Minecolonies/minecolonies/teams","hooks_url":"https://api.github.com/repos/Minecolonies/minecolonies/hooks","issue_events_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/events{/number}","events_url":"https://api.github.com/repos/Minecolonies/minecolonies/events","assignees_url":"https://api.github.com/repos/Minecolonies/minecolonies/assignees{/user}","branches_url":"https://api.github.com/repos/Minecolonies/minecolonies/branches{/branch}","tags_url":"https://api.github.com/repos/Minecolonies/minecolonies/tags","blobs_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/refs{/sha}","trees_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Minecolonies/minecolonies/statuses/{sha}","languages_url":"https://api.github.com/repos/Minecolonies/minecolonies/languages","stargazers_url":"https://api.github.com/repos/Minecolonies/minecolonies/stargazers","contributors_url":"https://api.github.com/repos/Minecolonies/minecolonies/contributors","subscribers_url":"https://api.github.com/repos/Minecolonies/minecolonies/subscribers","subscription_url":"https://api.github.com/repos/Minecolonies/minecolonies/subscription","commits_url":"https://api.github.com/repos/Minecolonies/minecolonies/commits{/sha}","git_commits_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/commits{/sha}","comments_url":"https://api.github.com/repos/Minecolonies/minecolonies/comments{/number}","issue_comment_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/comments{/number}","contents_url":"https://api.github.com/repos/Minecolonies/minecolonies/contents/{+path}","compare_url":"https://api.github.com/repos/Minecolonies/minecolonies/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Minecolonies/minecolonies/merges","archive_url":"https://api.github.com/repos/Minecolonies/minecolonies/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Minecolonies/minecolonies/downloads","issues_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues{/number}","pulls_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls{/number}","milestones_url":"https://api.github.com/repos/Minecolonies/minecolonies/milestones{/number}","notifications_url":"https://api.github.com/repos/Minecolonies/minecolonies/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Minecolonies/minecolonies/labels{/name}","releases_url":"https://api.github.com/repos/Minecolonies/minecolonies/releases{/id}","deployments_url":"https://api.github.com/repos/Minecolonies/minecolonies/deployments","created_at":"2016-08-13T12:45:38Z","updated_at":"2016-08-13T20:53:33Z","pushed_at":"2016-08-14T15:09:48Z","git_url":"git://github.com/Minecolonies/minecolonies.git","ssh_url":"git@github.com:Minecolonies/minecolonies.git","clone_url":"https://github.com/Minecolonies/minecolonies.git","svn_url":"https://github.com/Minecolonies/minecolonies","homepage":null,"size":6104,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":21,"forks":1,"open_issues":21,"watchers":2,"default_branch":"develop"}},"base":{"label":"Minecolonies:develop","ref":"develop","sha":"b5af315f6a290c2d60f1a5888cb2f022c6ec936f","user":{"login":"Minecolonies","id":5167336,"avatar_url":"https://avatars.githubusercontent.com/u/5167336?v=3","gravatar_id":"","url":"https://api.github.com/users/Minecolonies","html_url":"https://github.com/Minecolonies","followers_url":"https://api.github.com/users/Minecolonies/followers","following_url":"https://api.github.com/users/Minecolonies/following{/other_user}","gists_url":"https://api.github.com/users/Minecolonies/gists{/gist_id}","starred_url":"https://api.github.com/users/Minecolonies/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Minecolonies/subscriptions","organizations_url":"https://api.github.com/users/Minecolonies/orgs","repos_url":"https://api.github.com/users/Minecolonies/repos","events_url":"https://api.github.com/users/Minecolonies/events{/privacy}","received_events_url":"https://api.github.com/users/Minecolonies/received_events","type":"Organization","site_admin":false},"repo":{"id":65616760,"name":"minecolonies","full_name":"Minecolonies/minecolonies","owner":{"login":"Minecolonies","id":5167336,"avatar_url":"https://avatars.githubusercontent.com/u/5167336?v=3","gravatar_id":"","url":"https://api.github.com/users/Minecolonies","html_url":"https://github.com/Minecolonies","followers_url":"https://api.github.com/users/Minecolonies/followers","following_url":"https://api.github.com/users/Minecolonies/following{/other_user}","gists_url":"https://api.github.com/users/Minecolonies/gists{/gist_id}","starred_url":"https://api.github.com/users/Minecolonies/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Minecolonies/subscriptions","organizations_url":"https://api.github.com/users/Minecolonies/orgs","repos_url":"https://api.github.com/users/Minecolonies/repos","events_url":"https://api.github.com/users/Minecolonies/events{/privacy}","received_events_url":"https://api.github.com/users/Minecolonies/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Minecolonies/minecolonies","description":null,"fork":false,"url":"https://api.github.com/repos/Minecolonies/minecolonies","forks_url":"https://api.github.com/repos/Minecolonies/minecolonies/forks","keys_url":"https://api.github.com/repos/Minecolonies/minecolonies/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Minecolonies/minecolonies/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Minecolonies/minecolonies/teams","hooks_url":"https://api.github.com/repos/Minecolonies/minecolonies/hooks","issue_events_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/events{/number}","events_url":"https://api.github.com/repos/Minecolonies/minecolonies/events","assignees_url":"https://api.github.com/repos/Minecolonies/minecolonies/assignees{/user}","branches_url":"https://api.github.com/repos/Minecolonies/minecolonies/branches{/branch}","tags_url":"https://api.github.com/repos/Minecolonies/minecolonies/tags","blobs_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/refs{/sha}","trees_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Minecolonies/minecolonies/statuses/{sha}","languages_url":"https://api.github.com/repos/Minecolonies/minecolonies/languages","stargazers_url":"https://api.github.com/repos/Minecolonies/minecolonies/stargazers","contributors_url":"https://api.github.com/repos/Minecolonies/minecolonies/contributors","subscribers_url":"https://api.github.com/repos/Minecolonies/minecolonies/subscribers","subscription_url":"https://api.github.com/repos/Minecolonies/minecolonies/subscription","commits_url":"https://api.github.com/repos/Minecolonies/minecolonies/commits{/sha}","git_commits_url":"https://api.github.com/repos/Minecolonies/minecolonies/git/commits{/sha}","comments_url":"https://api.github.com/repos/Minecolonies/minecolonies/comments{/number}","issue_comment_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues/comments{/number}","contents_url":"https://api.github.com/repos/Minecolonies/minecolonies/contents/{+path}","compare_url":"https://api.github.com/repos/Minecolonies/minecolonies/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Minecolonies/minecolonies/merges","archive_url":"https://api.github.com/repos/Minecolonies/minecolonies/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Minecolonies/minecolonies/downloads","issues_url":"https://api.github.com/repos/Minecolonies/minecolonies/issues{/number}","pulls_url":"https://api.github.com/repos/Minecolonies/minecolonies/pulls{/number}","milestones_url":"https://api.github.com/repos/Minecolonies/minecolonies/milestones{/number}","notifications_url":"https://api.github.com/repos/Minecolonies/minecolonies/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Minecolonies/minecolonies/labels{/name}","releases_url":"https://api.github.com/repos/Minecolonies/minecolonies/releases{/id}","deployments_url":"https://api.github.com/repos/Minecolonies/minecolonies/deployments","created_at":"2016-08-13T12:45:38Z","updated_at":"2016-08-13T20:53:33Z","pushed_at":"2016-08-14T15:09:48Z","git_url":"git://github.com/Minecolonies/minecolonies.git","ssh_url":"git@github.com:Minecolonies/minecolonies.git","clone_url":"https://github.com/Minecolonies/minecolonies.git","svn_url":"https://github.com/Minecolonies/minecolonies","homepage":null,"size":6104,"stargazers_count":2,"watchers_count":2,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":21,"forks":1,"open_issues":21,"watchers":2,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12"},"html":{"href":"https://github.com/Minecolonies/minecolonies/pull/12"},"issue":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/issues/12"},"comments":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/issues/12/comments"},"review_comments":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12/comments"},"review_comment":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/pulls/12/commits"},"statuses":{"href":"https://api.github.com/repos/Minecolonies/minecolonies/statuses/fc2db862a099b16d77ceaaa53879704402c3fcee"}}}}
{"actor":{"display_login":"cltnschlosser"}}