{"action":"created","comment":{"url":"https://api.github.com/repos/tgstation/tgstation/pulls/comments/71301724","id":71301724,"diff_hunk":"@@ -62,4 +67,116 @@\n \t\t\tadjustBruteLoss(100)\n \n \t\tif(3)\n-\t\t\tadjustBruteLoss(50)\n\\ No newline at end of file\n+\t\t\tadjustBruteLoss(50)\n+\n+\n+\n+/mob/living/simple_animal/hostile/megafauna/proc/grant_achievement(medaltype,scoretype)\n+\n+\tif(medal_type == \"Boss\")\t//Don't award medals if the medal type isn't set\n+\t\treturn\n+\n+\tfor(var/mob/living/L in view(7,src))\n+\t\tif(L.stat)\n+\t\t\tcontinue\n+\t\tif(L.client)\n+\t\t\tvar/client/C = L.client\n+\t\t\tvar/suffixm = BOSS_KILL_MEDAL\n+\t\t\tUnlockMedal(\"Boss [suffixm]\",C)\n+\t\t\tUnlockMedal(\"[medaltype] [suffixm]\",C)\n+\t\t\tSetScore(BOSS_SCORE,C,1)\n+\t\t\tSetScore(score_type,C,1)\n+\n+/proc/UnlockMedal(medal,client/player)\n+\n+\tif(!player || !medal)\n+\t\treturn\n+\tif(global.medal_hub && global.medal_pass && global.medals_enabled)\n+\t\tspawn()\n+\t\t\tvar/result = world.SetMedal(medal, player, global.medal_hub, global.medal_pass)\n+\t\t\tif(isnull(result))\n+\t\t\t\tglobal.medals_enabled = FALSE\n+\t\t\t\tlog_game(\"MEDAL ERROR: Could not contact hub to award medal:[medal] player:[player.ckey]\")\n+\t\t\t\tmessage_admins(\"Error! Failed to contact hub to award [medal] medal to [player.ckey]!\")","path":"code/modules/mob/living/simple_animal/hostile/megafauna/megafauna.dm","position":63,"original_position":55,"commit_id":"a117772f95714a1593cce4901c77e1f3070743a6","original_commit_id":"e79cebbbefebc564ec4df4b3ce725977b68802ac","user":{"login":"MrStonedOne","id":7069733,"avatar_url":"https://avatars.githubusercontent.com/u/7069733?v=3","gravatar_id":"","url":"https://api.github.com/users/MrStonedOne","html_url":"https://github.com/MrStonedOne","followers_url":"https://api.github.com/users/MrStonedOne/followers","following_url":"https://api.github.com/users/MrStonedOne/following{/other_user}","gists_url":"https://api.github.com/users/MrStonedOne/gists{/gist_id}","starred_url":"https://api.github.com/users/MrStonedOne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrStonedOne/subscriptions","organizations_url":"https://api.github.com/users/MrStonedOne/orgs","repos_url":"https://api.github.com/users/MrStonedOne/repos","events_url":"https://api.github.com/users/MrStonedOne/events{/privacy}","received_events_url":"https://api.github.com/users/MrStonedOne/received_events","type":"User","site_admin":false},"body":"Make this a proc, database has a proc around connecting to the database, so this should be one too. ","created_at":"2016-07-19T09:27:51Z","updated_at":"2016-07-19T09:27:51Z","html_url":"https://github.com/tgstation/tgstation/pull/19382#discussion_r71301724","pull_request_url":"https://api.github.com/repos/tgstation/tgstation/pulls/19382","_links":{"self":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/comments/71301724"},"html":{"href":"https://github.com/tgstation/tgstation/pull/19382#discussion_r71301724"},"pull_request":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/19382"}}},"pull_request":{"url":"https://api.github.com/repos/tgstation/tgstation/pulls/19382","id":77899622,"html_url":"https://github.com/tgstation/tgstation/pull/19382","diff_url":"https://github.com/tgstation/tgstation/pull/19382.diff","patch_url":"https://github.com/tgstation/tgstation/pull/19382.patch","issue_url":"https://api.github.com/repos/tgstation/tgstation/issues/19382","number":19382,"state":"open","locked":false,"title":"Adds Byond medals and leaderboards for megafauna kills.","user":{"login":"Shadowlight213","id":9410002,"avatar_url":"https://avatars.githubusercontent.com/u/9410002?v=3","gravatar_id":"","url":"https://api.github.com/users/Shadowlight213","html_url":"https://github.com/Shadowlight213","followers_url":"https://api.github.com/users/Shadowlight213/followers","following_url":"https://api.github.com/users/Shadowlight213/following{/other_user}","gists_url":"https://api.github.com/users/Shadowlight213/gists{/gist_id}","starred_url":"https://api.github.com/users/Shadowlight213/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shadowlight213/subscriptions","organizations_url":"https://api.github.com/users/Shadowlight213/orgs","repos_url":"https://api.github.com/users/Shadowlight213/repos","events_url":"https://api.github.com/users/Shadowlight213/events{/privacy}","received_events_url":"https://api.github.com/users/Shadowlight213/received_events","type":"User","site_admin":false},"body":"Closes #19360\r\nSame system, but it uses the byond hub medals as well as the scoreboard.\r\n\r\n:cl:\r\nadd: Players will now receive an achievement for killing their first megafauna after this point.\r\nadd: Additionally, megafauna kills are now tracked on a hub page. Rack up those kills for first place!\r\n/:cl:","created_at":"2016-07-19T00:07:51Z","updated_at":"2016-07-19T09:27:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d5cd9399bb9decff850f5e75771dbbd440c1de44","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/tgstation/tgstation/pulls/19382/commits","review_comments_url":"https://api.github.com/repos/tgstation/tgstation/pulls/19382/comments","review_comment_url":"https://api.github.com/repos/tgstation/tgstation/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tgstation/tgstation/issues/19382/comments","statuses_url":"https://api.github.com/repos/tgstation/tgstation/statuses/a117772f95714a1593cce4901c77e1f3070743a6","head":{"label":"Shadowlight213:Hubchievments","ref":"Hubchievments","sha":"a117772f95714a1593cce4901c77e1f3070743a6","user":{"login":"Shadowlight213","id":9410002,"avatar_url":"https://avatars.githubusercontent.com/u/9410002?v=3","gravatar_id":"","url":"https://api.github.com/users/Shadowlight213","html_url":"https://github.com/Shadowlight213","followers_url":"https://api.github.com/users/Shadowlight213/followers","following_url":"https://api.github.com/users/Shadowlight213/following{/other_user}","gists_url":"https://api.github.com/users/Shadowlight213/gists{/gist_id}","starred_url":"https://api.github.com/users/Shadowlight213/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shadowlight213/subscriptions","organizations_url":"https://api.github.com/users/Shadowlight213/orgs","repos_url":"https://api.github.com/users/Shadowlight213/repos","events_url":"https://api.github.com/users/Shadowlight213/events{/privacy}","received_events_url":"https://api.github.com/users/Shadowlight213/received_events","type":"User","site_admin":false},"repo":{"id":32113084,"name":"-tg-station","full_name":"Shadowlight213/-tg-station","owner":{"login":"Shadowlight213","id":9410002,"avatar_url":"https://avatars.githubusercontent.com/u/9410002?v=3","gravatar_id":"","url":"https://api.github.com/users/Shadowlight213","html_url":"https://github.com/Shadowlight213","followers_url":"https://api.github.com/users/Shadowlight213/followers","following_url":"https://api.github.com/users/Shadowlight213/following{/other_user}","gists_url":"https://api.github.com/users/Shadowlight213/gists{/gist_id}","starred_url":"https://api.github.com/users/Shadowlight213/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Shadowlight213/subscriptions","organizations_url":"https://api.github.com/users/Shadowlight213/orgs","repos_url":"https://api.github.com/users/Shadowlight213/repos","events_url":"https://api.github.com/users/Shadowlight213/events{/privacy}","received_events_url":"https://api.github.com/users/Shadowlight213/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Shadowlight213/-tg-station","description":"/tg/'s SS13 branch","fork":true,"url":"https://api.github.com/repos/Shadowlight213/-tg-station","forks_url":"https://api.github.com/repos/Shadowlight213/-tg-station/forks","keys_url":"https://api.github.com/repos/Shadowlight213/-tg-station/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Shadowlight213/-tg-station/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Shadowlight213/-tg-station/teams","hooks_url":"https://api.github.com/repos/Shadowlight213/-tg-station/hooks","issue_events_url":"https://api.github.com/repos/Shadowlight213/-tg-station/issues/events{/number}","events_url":"https://api.github.com/repos/Shadowlight213/-tg-station/events","assignees_url":"https://api.github.com/repos/Shadowlight213/-tg-station/assignees{/user}","branches_url":"https://api.github.com/repos/Shadowlight213/-tg-station/branches{/branch}","tags_url":"https://api.github.com/repos/Shadowlight213/-tg-station/tags","blobs_url":"https://api.github.com/repos/Shadowlight213/-tg-station/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Shadowlight213/-tg-station/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Shadowlight213/-tg-station/git/refs{/sha}","trees_url":"https://api.github.com/repos/Shadowlight213/-tg-station/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Shadowlight213/-tg-station/statuses/{sha}","languages_url":"https://api.github.com/repos/Shadowlight213/-tg-station/languages","stargazers_url":"https://api.github.com/repos/Shadowlight213/-tg-station/stargazers","contributors_url":"https://api.github.com/repos/Shadowlight213/-tg-station/contributors","subscribers_url":"https://api.github.com/repos/Shadowlight213/-tg-station/subscribers","subscription_url":"https://api.github.com/repos/Shadowlight213/-tg-station/subscription","commits_url":"https://api.github.com/repos/Shadowlight213/-tg-station/commits{/sha}","git_commits_url":"https://api.github.com/repos/Shadowlight213/-tg-station/git/commits{/sha}","comments_url":"https://api.github.com/repos/Shadowlight213/-tg-station/comments{/number}","issue_comment_url":"https://api.github.com/repos/Shadowlight213/-tg-station/issues/comments{/number}","contents_url":"https://api.github.com/repos/Shadowlight213/-tg-station/contents/{+path}","compare_url":"https://api.github.com/repos/Shadowlight213/-tg-station/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Shadowlight213/-tg-station/merges","archive_url":"https://api.github.com/repos/Shadowlight213/-tg-station/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Shadowlight213/-tg-station/downloads","issues_url":"https://api.github.com/repos/Shadowlight213/-tg-station/issues{/number}","pulls_url":"https://api.github.com/repos/Shadowlight213/-tg-station/pulls{/number}","milestones_url":"https://api.github.com/repos/Shadowlight213/-tg-station/milestones{/number}","notifications_url":"https://api.github.com/repos/Shadowlight213/-tg-station/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Shadowlight213/-tg-station/labels{/name}","releases_url":"https://api.github.com/repos/Shadowlight213/-tg-station/releases{/id}","deployments_url":"https://api.github.com/repos/Shadowlight213/-tg-station/deployments","created_at":"2015-03-13T01:10:41Z","updated_at":"2016-01-12T00:23:32Z","pushed_at":"2016-07-19T05:32:49Z","git_url":"git://github.com/Shadowlight213/-tg-station.git","ssh_url":"git@github.com:Shadowlight213/-tg-station.git","clone_url":"https://github.com/Shadowlight213/-tg-station.git","svn_url":"https://github.com/Shadowlight213/-tg-station","homepage":"http://www.tgstation13.org/","size":633089,"stargazers_count":0,"watchers_count":0,"language":"DM","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":"tgstation:master","ref":"master","sha":"fd93196a7d267eedffe03a87130f5eba4fb9822d","user":{"login":"tgstation","id":1363778,"avatar_url":"https://avatars.githubusercontent.com/u/1363778?v=3","gravatar_id":"","url":"https://api.github.com/users/tgstation","html_url":"https://github.com/tgstation","followers_url":"https://api.github.com/users/tgstation/followers","following_url":"https://api.github.com/users/tgstation/following{/other_user}","gists_url":"https://api.github.com/users/tgstation/gists{/gist_id}","starred_url":"https://api.github.com/users/tgstation/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgstation/subscriptions","organizations_url":"https://api.github.com/users/tgstation/orgs","repos_url":"https://api.github.com/users/tgstation/repos","events_url":"https://api.github.com/users/tgstation/events{/privacy}","received_events_url":"https://api.github.com/users/tgstation/received_events","type":"Organization","site_admin":false},"repo":{"id":3234987,"name":"tgstation","full_name":"tgstation/tgstation","owner":{"login":"tgstation","id":1363778,"avatar_url":"https://avatars.githubusercontent.com/u/1363778?v=3","gravatar_id":"","url":"https://api.github.com/users/tgstation","html_url":"https://github.com/tgstation","followers_url":"https://api.github.com/users/tgstation/followers","following_url":"https://api.github.com/users/tgstation/following{/other_user}","gists_url":"https://api.github.com/users/tgstation/gists{/gist_id}","starred_url":"https://api.github.com/users/tgstation/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tgstation/subscriptions","organizations_url":"https://api.github.com/users/tgstation/orgs","repos_url":"https://api.github.com/users/tgstation/repos","events_url":"https://api.github.com/users/tgstation/events{/privacy}","received_events_url":"https://api.github.com/users/tgstation/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tgstation/tgstation","description":"the /tg/station branch of SS13","fork":false,"url":"https://api.github.com/repos/tgstation/tgstation","forks_url":"https://api.github.com/repos/tgstation/tgstation/forks","keys_url":"https://api.github.com/repos/tgstation/tgstation/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tgstation/tgstation/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tgstation/tgstation/teams","hooks_url":"https://api.github.com/repos/tgstation/tgstation/hooks","issue_events_url":"https://api.github.com/repos/tgstation/tgstation/issues/events{/number}","events_url":"https://api.github.com/repos/tgstation/tgstation/events","assignees_url":"https://api.github.com/repos/tgstation/tgstation/assignees{/user}","branches_url":"https://api.github.com/repos/tgstation/tgstation/branches{/branch}","tags_url":"https://api.github.com/repos/tgstation/tgstation/tags","blobs_url":"https://api.github.com/repos/tgstation/tgstation/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tgstation/tgstation/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tgstation/tgstation/git/refs{/sha}","trees_url":"https://api.github.com/repos/tgstation/tgstation/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tgstation/tgstation/statuses/{sha}","languages_url":"https://api.github.com/repos/tgstation/tgstation/languages","stargazers_url":"https://api.github.com/repos/tgstation/tgstation/stargazers","contributors_url":"https://api.github.com/repos/tgstation/tgstation/contributors","subscribers_url":"https://api.github.com/repos/tgstation/tgstation/subscribers","subscription_url":"https://api.github.com/repos/tgstation/tgstation/subscription","commits_url":"https://api.github.com/repos/tgstation/tgstation/commits{/sha}","git_commits_url":"https://api.github.com/repos/tgstation/tgstation/git/commits{/sha}","comments_url":"https://api.github.com/repos/tgstation/tgstation/comments{/number}","issue_comment_url":"https://api.github.com/repos/tgstation/tgstation/issues/comments{/number}","contents_url":"https://api.github.com/repos/tgstation/tgstation/contents/{+path}","compare_url":"https://api.github.com/repos/tgstation/tgstation/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tgstation/tgstation/merges","archive_url":"https://api.github.com/repos/tgstation/tgstation/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tgstation/tgstation/downloads","issues_url":"https://api.github.com/repos/tgstation/tgstation/issues{/number}","pulls_url":"https://api.github.com/repos/tgstation/tgstation/pulls{/number}","milestones_url":"https://api.github.com/repos/tgstation/tgstation/milestones{/number}","notifications_url":"https://api.github.com/repos/tgstation/tgstation/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tgstation/tgstation/labels{/name}","releases_url":"https://api.github.com/repos/tgstation/tgstation/releases{/id}","deployments_url":"https://api.github.com/repos/tgstation/tgstation/deployments","created_at":"2012-01-21T17:32:47Z","updated_at":"2016-07-16T19:33:15Z","pushed_at":"2016-07-19T05:32:50Z","git_url":"git://github.com/tgstation/tgstation.git","ssh_url":"git@github.com:tgstation/tgstation.git","clone_url":"https://github.com/tgstation/tgstation.git","svn_url":"https://github.com/tgstation/tgstation","homepage":"http://www.tgstation13.org/","size":911335,"stargazers_count":307,"watchers_count":307,"language":"DM","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1098,"mirror_url":null,"open_issues_count":776,"forks":1098,"open_issues":776,"watchers":307,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/19382"},"html":{"href":"https://github.com/tgstation/tgstation/pull/19382"},"issue":{"href":"https://api.github.com/repos/tgstation/tgstation/issues/19382"},"comments":{"href":"https://api.github.com/repos/tgstation/tgstation/issues/19382/comments"},"review_comments":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/19382/comments"},"review_comment":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tgstation/tgstation/pulls/19382/commits"},"statuses":{"href":"https://api.github.com/repos/tgstation/tgstation/statuses/a117772f95714a1593cce4901c77e1f3070743a6"}}}}
{"actor":{"display_login":"MrStonedOne"}}