{"action":"created","comment":{"url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/comments/43875352","id":43875352,"diff_hunk":"@@ -0,0 +1,175 @@\n+package application.engine.game_object;\n+\n+import application.util.Vector2;\n+import javafx.geometry.Point2D;\n+\n+/**\n+ * The body describes an objects dimensional properties, such as height, width and position. Without a body an object cannot be on a map.\n+ * @author Gruppe6\n+ *\n+ */\n+public class Body \n+{\n+    public GameObject gameObject;\n+    private Point2D position;\n+    private double height;\n+    private double width;\n+    private Vector2 orientation;\n+    private Geometry type;\n+\n+    public enum Geometry\n+    {\n+        CIRCLE, RECTANGLE; \n+        private static final Geometry[] types = Geometry.values();\n+        public static Geometry getType(int index)\n+        {\n+            return types[index];\n+        }\n+    }\n+\n+    /**\n+     *  Creates a body for the object.\n+     * @param gameObject The game object that this body is a composition of/belongs to.\n+     * @param position The position of the game objects body on a map.\n+     * @param width The width of the game objects body on a map.\n+     * @param height The height of the game objects body on a map.\n+     * @param type The type of body, i.e. rectangular or circle etc.\n+     */\n+    public Body(GameObject gameObject, Point2D position, double width, double height, Geometry type)\n+    {\n+        this.type = type;\n+        this.gameObject = gameObject;\n+        this.position = position;\n+        this.width = width;\n+        this.height = height;\n+        this.orientation = new Vector2(0, 0);\n+    }\n+\n+    /**\n+     * The position of the top left corner of this body.\n+     * @return Returns the position of the top left corner of this body.\n+     */\n+    public Point2D getPosition()\n+    {\n+        return position;\n+    }\n+\n+    /**\n+     * Sets the center position of this body.\n+     * @param position The new center position of this body.\n+     */\n+    public void setCenter(Point2D position)\n+    {\n+        this.position = new Point2D(position.getX() - width / 2, position.getY() - height / 2);\n+    }\n+\n+    /**\n+     * Sets the top left corner position of this body.\n+     * @param position The new top left corner position of this body.\n+     */\n+    public void setPosition(Point2D position)\n+    {\n+        this.position = position;\n+    }\n+\n+    /**\n+     * The center position of this body.\n+     * @return Returns the current center position of this body.\n+     */\n+    public Point2D getCenter()\n+    {\n+        return new Point2D((position.getX() + (width / 2)), position.getY() + (height / 2));\n+    }\n+\n+    /**\n+     * The height of this body.\n+     * @return Returns the current height of this body.\n+     */\n+    public double getHeight()\n+    {\n+        return height;\n+    }\n+\n+    /**\n+     * Sets the height of this body\n+     * @param height The new height of this body. \n+     */\n+    public void setHeight(double height)\n+    {\n+        this.height = height;\n+    }\n+\n+    /**\n+     * The width of this body.\n+     * @return Returns the current width of this body.\n+     */\n+    public double getWidth()\n+    {\n+        return width;\n+    }\n+    \n+    /**\n+     * Sets the width of this body.\n+     * @param width The new width of this body.\n+     */\n+    public void setWidth(double width)\n+    {\n+        this.width = width;\n+    }\n+\n+    /**\n+     * The orientation of this body described as a vector.\n+     * @return Returns the orientation of this body as a vector.\n+     */\n+    public Vector2 getOrientation()\n+    {\n+        return orientation;\n+    }\n+\n+    /**\n+     * Sets the orientation of this body as a vector.\n+     * @param orientation The new vector to describe the orientation of this boy.\n+     */\n+    public void setOrientation(Vector2 orientation)\n+    {\n+        this.orientation = orientation;\n+    }\n+\n+    /**\n+     * Increases the current position of this body.\n+     * @param xIncrease The amount to add to the current x value of the body.\n+     * @param yIncrease The amount to add to the current y value of the body.\n+     */\n+    public void increasePosition(double xIncrease, double yIncrease)","path":"src/application/engine/game_object/Body.java","position":143,"original_position":143,"commit_id":"c6d06b192b0bb24481d85bf71e5693af624b210c","original_commit_id":"c6d06b192b0bb24481d85bf71e5693af624b210c","user":{"login":"LuqJensen","id":2790839,"avatar_url":"https://avatars.githubusercontent.com/u/2790839?v=3","gravatar_id":"","url":"https://api.github.com/users/LuqJensen","html_url":"https://github.com/LuqJensen","followers_url":"https://api.github.com/users/LuqJensen/followers","following_url":"https://api.github.com/users/LuqJensen/following{/other_user}","gists_url":"https://api.github.com/users/LuqJensen/gists{/gist_id}","starred_url":"https://api.github.com/users/LuqJensen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LuqJensen/subscriptions","organizations_url":"https://api.github.com/users/LuqJensen/orgs","repos_url":"https://api.github.com/users/LuqJensen/repos","events_url":"https://api.github.com/users/LuqJensen/events{/privacy}","received_events_url":"https://api.github.com/users/LuqJensen/received_events","type":"User","site_admin":false},"body":"i still would like to see the method name changed as well as the parameters names","created_at":"2015-11-04T12:38:08Z","updated_at":"2015-11-04T12:38:08Z","html_url":"https://github.com/LuqJensen/Ball-of-Duty/pull/28#discussion_r43875352","pull_request_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28","_links":{"self":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/comments/43875352"},"html":{"href":"https://github.com/LuqJensen/Ball-of-Duty/pull/28#discussion_r43875352"},"pull_request":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28"}}},"pull_request":{"url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28","id":49676826,"html_url":"https://github.com/LuqJensen/Ball-of-Duty/pull/28","diff_url":"https://github.com/LuqJensen/Ball-of-Duty/pull/28.diff","patch_url":"https://github.com/LuqJensen/Ball-of-Duty/pull/28.patch","issue_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/28","number":28,"state":"open","locked":false,"title":"Cleaned up client. Javadoc added.","user":{"login":"Ploug","id":8784205,"avatar_url":"https://avatars.githubusercontent.com/u/8784205?v=3","gravatar_id":"","url":"https://api.github.com/users/Ploug","html_url":"https://github.com/Ploug","followers_url":"https://api.github.com/users/Ploug/followers","following_url":"https://api.github.com/users/Ploug/following{/other_user}","gists_url":"https://api.github.com/users/Ploug/gists{/gist_id}","starred_url":"https://api.github.com/users/Ploug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ploug/subscriptions","organizations_url":"https://api.github.com/users/Ploug/orgs","repos_url":"https://api.github.com/users/Ploug/repos","events_url":"https://api.github.com/users/Ploug/events{/privacy}","received_events_url":"https://api.github.com/users/Ploug/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-11-04T11:25:44Z","updated_at":"2015-11-04T12:38:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c2e76620302f1665b076d12294b74af7a2b3f994","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28/commits","review_comments_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28/comments","review_comment_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/comments{/number}","comments_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/28/comments","statuses_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/statuses/c6d06b192b0bb24481d85bf71e5693af624b210c","head":{"label":"Ploug:master","ref":"master","sha":"c6d06b192b0bb24481d85bf71e5693af624b210c","user":{"login":"Ploug","id":8784205,"avatar_url":"https://avatars.githubusercontent.com/u/8784205?v=3","gravatar_id":"","url":"https://api.github.com/users/Ploug","html_url":"https://github.com/Ploug","followers_url":"https://api.github.com/users/Ploug/followers","following_url":"https://api.github.com/users/Ploug/following{/other_user}","gists_url":"https://api.github.com/users/Ploug/gists{/gist_id}","starred_url":"https://api.github.com/users/Ploug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ploug/subscriptions","organizations_url":"https://api.github.com/users/Ploug/orgs","repos_url":"https://api.github.com/users/Ploug/repos","events_url":"https://api.github.com/users/Ploug/events{/privacy}","received_events_url":"https://api.github.com/users/Ploug/received_events","type":"User","site_admin":false},"repo":{"id":43125621,"name":"Ball-of-Duty","full_name":"Ploug/Ball-of-Duty","owner":{"login":"Ploug","id":8784205,"avatar_url":"https://avatars.githubusercontent.com/u/8784205?v=3","gravatar_id":"","url":"https://api.github.com/users/Ploug","html_url":"https://github.com/Ploug","followers_url":"https://api.github.com/users/Ploug/followers","following_url":"https://api.github.com/users/Ploug/following{/other_user}","gists_url":"https://api.github.com/users/Ploug/gists{/gist_id}","starred_url":"https://api.github.com/users/Ploug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Ploug/subscriptions","organizations_url":"https://api.github.com/users/Ploug/orgs","repos_url":"https://api.github.com/users/Ploug/repos","events_url":"https://api.github.com/users/Ploug/events{/privacy}","received_events_url":"https://api.github.com/users/Ploug/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Ploug/Ball-of-Duty","description":"","fork":true,"url":"https://api.github.com/repos/Ploug/Ball-of-Duty","forks_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/forks","keys_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/teams","hooks_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/hooks","issue_events_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/issues/events{/number}","events_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/events","assignees_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/assignees{/user}","branches_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/branches{/branch}","tags_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/tags","blobs_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/git/refs{/sha}","trees_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/statuses/{sha}","languages_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/languages","stargazers_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/stargazers","contributors_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/contributors","subscribers_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/subscribers","subscription_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/subscription","commits_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/commits{/sha}","git_commits_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/git/commits{/sha}","comments_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/comments{/number}","issue_comment_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/issues/comments{/number}","contents_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/contents/{+path}","compare_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/merges","archive_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/downloads","issues_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/issues{/number}","pulls_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/pulls{/number}","milestones_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/milestones{/number}","notifications_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/labels{/name}","releases_url":"https://api.github.com/repos/Ploug/Ball-of-Duty/releases{/id}","created_at":"2015-09-25T09:08:36Z","updated_at":"2015-10-15T11:26:31Z","pushed_at":"2015-11-04T11:21:02Z","git_url":"git://github.com/Ploug/Ball-of-Duty.git","ssh_url":"git@github.com:Ploug/Ball-of-Duty.git","clone_url":"https://github.com/Ploug/Ball-of-Duty.git","svn_url":"https://github.com/Ploug/Ball-of-Duty","homepage":null,"size":5298,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"LuqJensen:master","ref":"master","sha":"a241e4ccf8b06a0b3de56a7aa1349ca74ed7c3de","user":{"login":"LuqJensen","id":2790839,"avatar_url":"https://avatars.githubusercontent.com/u/2790839?v=3","gravatar_id":"","url":"https://api.github.com/users/LuqJensen","html_url":"https://github.com/LuqJensen","followers_url":"https://api.github.com/users/LuqJensen/followers","following_url":"https://api.github.com/users/LuqJensen/following{/other_user}","gists_url":"https://api.github.com/users/LuqJensen/gists{/gist_id}","starred_url":"https://api.github.com/users/LuqJensen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LuqJensen/subscriptions","organizations_url":"https://api.github.com/users/LuqJensen/orgs","repos_url":"https://api.github.com/users/LuqJensen/repos","events_url":"https://api.github.com/users/LuqJensen/events{/privacy}","received_events_url":"https://api.github.com/users/LuqJensen/received_events","type":"User","site_admin":false},"repo":{"id":43121123,"name":"Ball-of-Duty","full_name":"LuqJensen/Ball-of-Duty","owner":{"login":"LuqJensen","id":2790839,"avatar_url":"https://avatars.githubusercontent.com/u/2790839?v=3","gravatar_id":"","url":"https://api.github.com/users/LuqJensen","html_url":"https://github.com/LuqJensen","followers_url":"https://api.github.com/users/LuqJensen/followers","following_url":"https://api.github.com/users/LuqJensen/following{/other_user}","gists_url":"https://api.github.com/users/LuqJensen/gists{/gist_id}","starred_url":"https://api.github.com/users/LuqJensen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LuqJensen/subscriptions","organizations_url":"https://api.github.com/users/LuqJensen/orgs","repos_url":"https://api.github.com/users/LuqJensen/repos","events_url":"https://api.github.com/users/LuqJensen/events{/privacy}","received_events_url":"https://api.github.com/users/LuqJensen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/LuqJensen/Ball-of-Duty","description":"","fork":false,"url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty","forks_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/forks","keys_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/keys{/key_id}","collaborators_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/teams","hooks_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/hooks","issue_events_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/events{/number}","events_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/events","assignees_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/assignees{/user}","branches_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/branches{/branch}","tags_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/tags","blobs_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/git/refs{/sha}","trees_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/git/trees{/sha}","statuses_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/statuses/{sha}","languages_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/languages","stargazers_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/stargazers","contributors_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/contributors","subscribers_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/subscribers","subscription_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/subscription","commits_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/commits{/sha}","git_commits_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/git/commits{/sha}","comments_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/comments{/number}","issue_comment_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/comments{/number}","contents_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/contents/{+path}","compare_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/compare/{base}...{head}","merges_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/merges","archive_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/downloads","issues_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues{/number}","pulls_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls{/number}","milestones_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/milestones{/number}","notifications_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/labels{/name}","releases_url":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/releases{/id}","created_at":"2015-09-25T08:27:29Z","updated_at":"2015-10-14T21:32:33Z","pushed_at":"2015-11-04T11:25:44Z","git_url":"git://github.com/LuqJensen/Ball-of-Duty.git","ssh_url":"git@github.com:LuqJensen/Ball-of-Duty.git","clone_url":"https://github.com/LuqJensen/Ball-of-Duty.git","svn_url":"https://github.com/LuqJensen/Ball-of-Duty","homepage":null,"size":5576,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":1,"forks":5,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28"},"html":{"href":"https://github.com/LuqJensen/Ball-of-Duty/pull/28"},"issue":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/28"},"comments":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/issues/28/comments"},"review_comments":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28/comments"},"review_comment":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/pulls/28/commits"},"statuses":{"href":"https://api.github.com/repos/LuqJensen/Ball-of-Duty/statuses/c6d06b192b0bb24481d85bf71e5693af624b210c"}}}}