{"action":"created","comment":{"url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/comments/55931816","id":55931816,"diff_hunk":"@@ -0,0 +1,267 @@\n+/**\n+ * vim: set ts=4 :\n+ * =============================================================================\n+ * SourceMod (C)2004-2008 AlliedModders LLC.  All rights reserved.\n+ * =============================================================================\n+ *\n+ * This file is part of the SourceMod/SourcePawn SDK.\n+ *\n+ * This program is free software; you can redistribute it and/or modify it under\n+ * the terms of the GNU General Public License, version 3.0, as published by the\n+ * Free Software Foundation.\n+ *\n+ * This program is distributed in the hope that it will be useful, but WITHOUT\n+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS\n+ * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more\n+ * details.\n+ *\n+ * You should have received a copy of the GNU General Public License along with\n+ * this program.  If not, see <http://www.gnu.org/licenses/>.\n+ *\n+ * As a special exception, AlliedModders LLC gives you permission to link the\n+ * code of this program (as well as its derivative works) to \"Half-Life 2,\" the\n+ * \"Source Engine,\" the \"SourcePawn JIT,\" and any Game MODs that run on software\n+ * by the Valve Corporation.  You must obey the GNU General Public License in\n+ * all respects for all other code used.  Additionally, AlliedModders LLC grants\n+ * this exception to all derivative works.  AlliedModders LLC defines further\n+ * exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),\n+ * or <http://www.sourcemod.net/license.php>.\n+ *\n+ * Version: $Id$\n+ */\n+\n+#if defined _nd_stocks_included_\n+  #endinput\n+#endif\n+#define _nd_stocks_included_\n+\n+/* The team name constants */\n+enum NDTeam \n+{\n+\tNDTeam_Unassigned = 0,\n+    \tNDTeam_Spec,\n+    \tNDTeam_Consort,\n+    \tNDTeam_Empire\n+};\n+\n+/**\n+ * Gets the team of a given player\n+ *\n+ * @param client\t\tClient index.\n+ * @return\t\t\tThe client's team as a NDTeam enum\n+ * @error\t\t\tInvalid client index or client not ingame.\n+ */\n+\n+stock NDTeam GetClientNDTeam(int client) { return view_as<NDTeam>(GetClientTeam(client)); }\n+\n+/**\n+ * Gets the name of a given team index\n+ *\n+ * @param team\t\t\tTeam index.\n+ * @return\t\t\tThe name of the team or \"Unknown\" on invalid team index\n+ * @error\t\t\tInvalid team index.\n+ */\n+\n+stock char ND_GetTeamName(int team)\n+{\n+\tchar TeamName[12];\n+\t\n+\tswitch(team)\n+\t{\n+\t\tcase NDTeam_Empire: \tTeamName = \"Empire\";\n+\t\tcase NDTeam_Consort: \tTeamName = \"Consortium\";\n+\t\tcase NDTeam_Spec:\tTeamName = \"Spectate\";\n+\t\tcase NDTeam_Unassigned:\tTeamName = \"Unassigned\";\n+\t\tdefault: \t\tTeamName = \"Unknown\";\n+\t}\n+\t\n+\treturn TeamName;\n+}\n+\n+/** \n+ * Retreives the level of a given client index\n+ *\n+ * @param client\t\tClient index.\n+ * @return\t\t\tThe level of the client or some value less than 2\n+ * @error\t\t\tUnloaded level or level less than 2.\n+ */\n+ \n+stock int ND_GetPlayerRank(int client)\n+{\n+\treturn GetEntProp(GetPlayerResourceEntity(), Prop_Send, \"m_iPlayerRank\", 1, client);\n+}\n+\n+/** \n+ * Retreives the current score of a given client index\n+ *\n+ * @param client\t\tClient index.\n+ * @return\t\t\tThe current score of the client\n+ */\n+\n+stock int ND_GetPlayerScore(int client)\n+{\n+\treturn GetEntProp(GetPlayerResourceEntity(), Prop_Send, \"m_iScore\", 1, client);\n+}\n+\n+/* Player Class Functions */\n+\n+//main player class enum\n+enum ND_MainClasses\n+{\n+\tND_MainClass_Assault = 0,\n+\tND_MainClass_Exo,\n+\tND_MainClass_Stealth,\n+\tND_MainClass_Support\n+};\n+\n+/* Sub Classes */\n+#define ND_ASSAULT_CLASS_INFANTRY \t0\n+#define ND_ASSAULT_CLASS_GRENDIER \t1\n+#define ND_ASSAULT_CLASS_SNIPER \t2\n+\n+#define ND_EXO_CLASS_SUPRESSION\t\t0\n+#define ND_EXO_CLASS_SEIGEKIT \t\t1\n+\n+#define ND_STEALTH_CLASS_ASSASSIN\t0\n+#define ND_STEALTH_CLASS_SNIPER \t1\n+#define ND_STEALTH_CLASS_SABATUER \t2","path":"plugins/include/nd_stocks.inc","position":127,"original_position":127,"commit_id":"fc26bf5b9189192c838dbdfc7c0b9a87fdc783ca","original_commit_id":"fc26bf5b9189192c838dbdfc7c0b9a87fdc783ca","user":{"login":"yedpodtrzitko","id":162526,"avatar_url":"https://avatars.githubusercontent.com/u/162526?v=3","gravatar_id":"","url":"https://api.github.com/users/yedpodtrzitko","html_url":"https://github.com/yedpodtrzitko","followers_url":"https://api.github.com/users/yedpodtrzitko/followers","following_url":"https://api.github.com/users/yedpodtrzitko/following{/other_user}","gists_url":"https://api.github.com/users/yedpodtrzitko/gists{/gist_id}","starred_url":"https://api.github.com/users/yedpodtrzitko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yedpodtrzitko/subscriptions","organizations_url":"https://api.github.com/users/yedpodtrzitko/orgs","repos_url":"https://api.github.com/users/yedpodtrzitko/repos","events_url":"https://api.github.com/users/yedpodtrzitko/events{/privacy}","received_events_url":"https://api.github.com/users/yedpodtrzitko/received_events","type":"User","site_admin":false},"body":"saboteur","created_at":"2016-03-13T03:59:59Z","updated_at":"2016-03-13T03:59:59Z","html_url":"https://github.com/alliedmodders/sourcemod/pull/487#discussion_r55931816","pull_request_url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487","_links":{"self":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/comments/55931816"},"html":{"href":"https://github.com/alliedmodders/sourcemod/pull/487#discussion_r55931816"},"pull_request":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487"}}},"pull_request":{"url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487","id":62128319,"html_url":"https://github.com/alliedmodders/sourcemod/pull/487","diff_url":"https://github.com/alliedmodders/sourcemod/pull/487.diff","patch_url":"https://github.com/alliedmodders/sourcemod/pull/487.patch","issue_url":"https://api.github.com/repos/alliedmodders/sourcemod/issues/487","number":487,"state":"open","locked":false,"title":"Add Nuclear Dawn Stock Functions","user":{"login":"stickz","id":9171157,"avatar_url":"https://avatars.githubusercontent.com/u/9171157?v=3","gravatar_id":"","url":"https://api.github.com/users/stickz","html_url":"https://github.com/stickz","followers_url":"https://api.github.com/users/stickz/followers","following_url":"https://api.github.com/users/stickz/following{/other_user}","gists_url":"https://api.github.com/users/stickz/gists{/gist_id}","starred_url":"https://api.github.com/users/stickz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stickz/subscriptions","organizations_url":"https://api.github.com/users/stickz/orgs","repos_url":"https://api.github.com/users/stickz/repos","events_url":"https://api.github.com/users/stickz/events{/privacy}","received_events_url":"https://api.github.com/users/stickz/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-03-08T20:08:13Z","updated_at":"2016-03-13T03:59:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"27cf557ca21e93db0e86f8a8ca9f9e75915c4b34","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487/commits","review_comments_url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487/comments","review_comment_url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alliedmodders/sourcemod/issues/487/comments","statuses_url":"https://api.github.com/repos/alliedmodders/sourcemod/statuses/fc26bf5b9189192c838dbdfc7c0b9a87fdc783ca","head":{"label":"stickz:master","ref":"master","sha":"fc26bf5b9189192c838dbdfc7c0b9a87fdc783ca","user":{"login":"stickz","id":9171157,"avatar_url":"https://avatars.githubusercontent.com/u/9171157?v=3","gravatar_id":"","url":"https://api.github.com/users/stickz","html_url":"https://github.com/stickz","followers_url":"https://api.github.com/users/stickz/followers","following_url":"https://api.github.com/users/stickz/following{/other_user}","gists_url":"https://api.github.com/users/stickz/gists{/gist_id}","starred_url":"https://api.github.com/users/stickz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stickz/subscriptions","organizations_url":"https://api.github.com/users/stickz/orgs","repos_url":"https://api.github.com/users/stickz/repos","events_url":"https://api.github.com/users/stickz/events{/privacy}","received_events_url":"https://api.github.com/users/stickz/received_events","type":"User","site_admin":false},"repo":{"id":46825291,"name":"sourcemod","full_name":"stickz/sourcemod","owner":{"login":"stickz","id":9171157,"avatar_url":"https://avatars.githubusercontent.com/u/9171157?v=3","gravatar_id":"","url":"https://api.github.com/users/stickz","html_url":"https://github.com/stickz","followers_url":"https://api.github.com/users/stickz/followers","following_url":"https://api.github.com/users/stickz/following{/other_user}","gists_url":"https://api.github.com/users/stickz/gists{/gist_id}","starred_url":"https://api.github.com/users/stickz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stickz/subscriptions","organizations_url":"https://api.github.com/users/stickz/orgs","repos_url":"https://api.github.com/users/stickz/repos","events_url":"https://api.github.com/users/stickz/events{/privacy}","received_events_url":"https://api.github.com/users/stickz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/stickz/sourcemod","description":"SourceMod - Source Engine Scripting and Administration","fork":true,"url":"https://api.github.com/repos/stickz/sourcemod","forks_url":"https://api.github.com/repos/stickz/sourcemod/forks","keys_url":"https://api.github.com/repos/stickz/sourcemod/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stickz/sourcemod/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stickz/sourcemod/teams","hooks_url":"https://api.github.com/repos/stickz/sourcemod/hooks","issue_events_url":"https://api.github.com/repos/stickz/sourcemod/issues/events{/number}","events_url":"https://api.github.com/repos/stickz/sourcemod/events","assignees_url":"https://api.github.com/repos/stickz/sourcemod/assignees{/user}","branches_url":"https://api.github.com/repos/stickz/sourcemod/branches{/branch}","tags_url":"https://api.github.com/repos/stickz/sourcemod/tags","blobs_url":"https://api.github.com/repos/stickz/sourcemod/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stickz/sourcemod/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stickz/sourcemod/git/refs{/sha}","trees_url":"https://api.github.com/repos/stickz/sourcemod/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stickz/sourcemod/statuses/{sha}","languages_url":"https://api.github.com/repos/stickz/sourcemod/languages","stargazers_url":"https://api.github.com/repos/stickz/sourcemod/stargazers","contributors_url":"https://api.github.com/repos/stickz/sourcemod/contributors","subscribers_url":"https://api.github.com/repos/stickz/sourcemod/subscribers","subscription_url":"https://api.github.com/repos/stickz/sourcemod/subscription","commits_url":"https://api.github.com/repos/stickz/sourcemod/commits{/sha}","git_commits_url":"https://api.github.com/repos/stickz/sourcemod/git/commits{/sha}","comments_url":"https://api.github.com/repos/stickz/sourcemod/comments{/number}","issue_comment_url":"https://api.github.com/repos/stickz/sourcemod/issues/comments{/number}","contents_url":"https://api.github.com/repos/stickz/sourcemod/contents/{+path}","compare_url":"https://api.github.com/repos/stickz/sourcemod/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stickz/sourcemod/merges","archive_url":"https://api.github.com/repos/stickz/sourcemod/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stickz/sourcemod/downloads","issues_url":"https://api.github.com/repos/stickz/sourcemod/issues{/number}","pulls_url":"https://api.github.com/repos/stickz/sourcemod/pulls{/number}","milestones_url":"https://api.github.com/repos/stickz/sourcemod/milestones{/number}","notifications_url":"https://api.github.com/repos/stickz/sourcemod/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stickz/sourcemod/labels{/name}","releases_url":"https://api.github.com/repos/stickz/sourcemod/releases{/id}","deployments_url":"https://api.github.com/repos/stickz/sourcemod/deployments","created_at":"2015-11-24T23:34:23Z","updated_at":"2016-03-08T20:06:35Z","pushed_at":"2016-03-12T20:56:01Z","git_url":"git://github.com/stickz/sourcemod.git","ssh_url":"git@github.com:stickz/sourcemod.git","clone_url":"https://github.com/stickz/sourcemod.git","svn_url":"https://github.com/stickz/sourcemod","homepage":"http://www.sourcemod.net/","size":34958,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"alliedmodders:master","ref":"master","sha":"19bcc8417d78005579715c9946f5ed9fa5e42ce6","user":{"login":"alliedmodders","id":6601917,"avatar_url":"https://avatars.githubusercontent.com/u/6601917?v=3","gravatar_id":"","url":"https://api.github.com/users/alliedmodders","html_url":"https://github.com/alliedmodders","followers_url":"https://api.github.com/users/alliedmodders/followers","following_url":"https://api.github.com/users/alliedmodders/following{/other_user}","gists_url":"https://api.github.com/users/alliedmodders/gists{/gist_id}","starred_url":"https://api.github.com/users/alliedmodders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alliedmodders/subscriptions","organizations_url":"https://api.github.com/users/alliedmodders/orgs","repos_url":"https://api.github.com/users/alliedmodders/repos","events_url":"https://api.github.com/users/alliedmodders/events{/privacy}","received_events_url":"https://api.github.com/users/alliedmodders/received_events","type":"Organization","site_admin":false},"repo":{"id":20145274,"name":"sourcemod","full_name":"alliedmodders/sourcemod","owner":{"login":"alliedmodders","id":6601917,"avatar_url":"https://avatars.githubusercontent.com/u/6601917?v=3","gravatar_id":"","url":"https://api.github.com/users/alliedmodders","html_url":"https://github.com/alliedmodders","followers_url":"https://api.github.com/users/alliedmodders/followers","following_url":"https://api.github.com/users/alliedmodders/following{/other_user}","gists_url":"https://api.github.com/users/alliedmodders/gists{/gist_id}","starred_url":"https://api.github.com/users/alliedmodders/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alliedmodders/subscriptions","organizations_url":"https://api.github.com/users/alliedmodders/orgs","repos_url":"https://api.github.com/users/alliedmodders/repos","events_url":"https://api.github.com/users/alliedmodders/events{/privacy}","received_events_url":"https://api.github.com/users/alliedmodders/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/alliedmodders/sourcemod","description":"SourceMod - Source Engine Scripting and Administration","fork":false,"url":"https://api.github.com/repos/alliedmodders/sourcemod","forks_url":"https://api.github.com/repos/alliedmodders/sourcemod/forks","keys_url":"https://api.github.com/repos/alliedmodders/sourcemod/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alliedmodders/sourcemod/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alliedmodders/sourcemod/teams","hooks_url":"https://api.github.com/repos/alliedmodders/sourcemod/hooks","issue_events_url":"https://api.github.com/repos/alliedmodders/sourcemod/issues/events{/number}","events_url":"https://api.github.com/repos/alliedmodders/sourcemod/events","assignees_url":"https://api.github.com/repos/alliedmodders/sourcemod/assignees{/user}","branches_url":"https://api.github.com/repos/alliedmodders/sourcemod/branches{/branch}","tags_url":"https://api.github.com/repos/alliedmodders/sourcemod/tags","blobs_url":"https://api.github.com/repos/alliedmodders/sourcemod/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alliedmodders/sourcemod/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alliedmodders/sourcemod/git/refs{/sha}","trees_url":"https://api.github.com/repos/alliedmodders/sourcemod/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alliedmodders/sourcemod/statuses/{sha}","languages_url":"https://api.github.com/repos/alliedmodders/sourcemod/languages","stargazers_url":"https://api.github.com/repos/alliedmodders/sourcemod/stargazers","contributors_url":"https://api.github.com/repos/alliedmodders/sourcemod/contributors","subscribers_url":"https://api.github.com/repos/alliedmodders/sourcemod/subscribers","subscription_url":"https://api.github.com/repos/alliedmodders/sourcemod/subscription","commits_url":"https://api.github.com/repos/alliedmodders/sourcemod/commits{/sha}","git_commits_url":"https://api.github.com/repos/alliedmodders/sourcemod/git/commits{/sha}","comments_url":"https://api.github.com/repos/alliedmodders/sourcemod/comments{/number}","issue_comment_url":"https://api.github.com/repos/alliedmodders/sourcemod/issues/comments{/number}","contents_url":"https://api.github.com/repos/alliedmodders/sourcemod/contents/{+path}","compare_url":"https://api.github.com/repos/alliedmodders/sourcemod/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alliedmodders/sourcemod/merges","archive_url":"https://api.github.com/repos/alliedmodders/sourcemod/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alliedmodders/sourcemod/downloads","issues_url":"https://api.github.com/repos/alliedmodders/sourcemod/issues{/number}","pulls_url":"https://api.github.com/repos/alliedmodders/sourcemod/pulls{/number}","milestones_url":"https://api.github.com/repos/alliedmodders/sourcemod/milestones{/number}","notifications_url":"https://api.github.com/repos/alliedmodders/sourcemod/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alliedmodders/sourcemod/labels{/name}","releases_url":"https://api.github.com/repos/alliedmodders/sourcemod/releases{/id}","deployments_url":"https://api.github.com/repos/alliedmodders/sourcemod/deployments","created_at":"2014-05-25T02:58:39Z","updated_at":"2016-03-02T20:23:13Z","pushed_at":"2016-03-12T20:56:02Z","git_url":"git://github.com/alliedmodders/sourcemod.git","ssh_url":"git@github.com:alliedmodders/sourcemod.git","clone_url":"https://github.com/alliedmodders/sourcemod.git","svn_url":"https://github.com/alliedmodders/sourcemod","homepage":"http://www.sourcemod.net/","size":39498,"stargazers_count":183,"watchers_count":183,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":94,"mirror_url":null,"open_issues_count":20,"forks":94,"open_issues":20,"watchers":183,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487"},"html":{"href":"https://github.com/alliedmodders/sourcemod/pull/487"},"issue":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/issues/487"},"comments":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/issues/487/comments"},"review_comments":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487/comments"},"review_comment":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/pulls/487/commits"},"statuses":{"href":"https://api.github.com/repos/alliedmodders/sourcemod/statuses/fc26bf5b9189192c838dbdfc7c0b9a87fdc783ca"}}}}