{"action":"created","comment":{"url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/comments/169524483","pull_request_review_id":98063546,"id":169524483,"diff_hunk":"@@ -0,0 +1,84 @@\n+#include \"PlayerControllerComponent.hpp\"\n+\n+#include \"IO/Window.hpp\"\n+#include \"IO/Mouse.hpp\"\n+#include \"IO/Keyboard.hpp\"\n+#include \"Component/SpatialComponents/SpatialComponent.hpp\"\n+#include \"Component/CameraComponents/CameraComponent.hpp\"\n+#include \"Component/SpatialComponents/PhysicsComponents.hpp\"\n+#include \"Component/PostCollisionComponents/GroundComponent.hpp\"\n+#include \"System/SpatialSystem.hpp\"\n+\n+\n+\n+PlayerControllerComponent::PlayerControllerComponent(float lookSpeed, float moveSpeed, float jumpSpeed) :\n+    m_spatial(nullptr),\n+    m_newtonian(nullptr),\n+    m_camera(nullptr),\n+    m_lookSpeed(lookSpeed),\n+    m_moveSpeed(moveSpeed),\n+    m_jumpSpeed(jumpSpeed),\n+    m_enabled(true)\n+{}\n+\n+void PlayerControllerComponent::init(GameObject & go) {\n+    Component::init(go);\n+    if (!(m_spatial = gameObject()->getComponentByType<SpatialComponent>())) assert(false);\n+    if (!(m_newtonian = gameObject()->getComponentByType<NewtonianComponent>())) assert(false);\n+    if (!(m_ground = gameObject()->getComponentByType<GroundComponent>())) assert(false);\n+    if (!(m_camera = gameObject()->getComponentByType<CameraComponent>())) assert(false);\n+}\n+\n+void PlayerControllerComponent::update(float dt) {\n+    if (!m_enabled) {\n+        return;\n+    }\n+    if (Window::isImGuiEnabled()) {","path":"src/Engine/Component/PlayerComponents/PlayerControllerComponent.cpp","position":36,"original_position":36,"commit_id":"6d1a880e67c95aa21fb0d7dc6ab31497dd4da4df","original_commit_id":"6d1a880e67c95aa21fb0d7dc6ab31497dd4da4df","user":{"login":"Daskie","id":5835795,"avatar_url":"https://avatars2.githubusercontent.com/u/5835795?v=4","gravatar_id":"","url":"https://api.github.com/users/Daskie","html_url":"https://github.com/Daskie","followers_url":"https://api.github.com/users/Daskie/followers","following_url":"https://api.github.com/users/Daskie/following{/other_user}","gists_url":"https://api.github.com/users/Daskie/gists{/gist_id}","starred_url":"https://api.github.com/users/Daskie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Daskie/subscriptions","organizations_url":"https://api.github.com/users/Daskie/orgs","repos_url":"https://api.github.com/users/Daskie/repos","events_url":"https://api.github.com/users/Daskie/events{/privacy}","received_events_url":"https://api.github.com/users/Daskie/received_events","type":"User","site_admin":false},"body":"right, i mean when imgui is open but the mouse is not over one of the panes. Oftentimes you want to look at something while tweaking imgui, which means you want it in the middle of the screen, which is very hard when moving your mouse from the center of the screen to the imgui pane rotates the camera.","created_at":"2018-02-21T02:59:28Z","updated_at":"2018-02-21T02:59:28Z","html_url":"https://github.com/jaafersheriff/BattleRoyale/pull/35#discussion_r169524483","pull_request_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/comments/169524483"},"html":{"href":"https://github.com/jaafersheriff/BattleRoyale/pull/35#discussion_r169524483"},"pull_request":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35"}},"in_reply_to_id":169492007},"pull_request":{"url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35","id":170155523,"html_url":"https://github.com/jaafersheriff/BattleRoyale/pull/35","diff_url":"https://github.com/jaafersheriff/BattleRoyale/pull/35.diff","patch_url":"https://github.com/jaafersheriff/BattleRoyale/pull/35.patch","issue_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/35","number":35,"state":"open","locked":false,"title":"Physics, player/camera seperation, messaging, fixes galore","user":{"login":"Daskie","id":5835795,"avatar_url":"https://avatars2.githubusercontent.com/u/5835795?v=4","gravatar_id":"","url":"https://api.github.com/users/Daskie","html_url":"https://github.com/Daskie","followers_url":"https://api.github.com/users/Daskie/followers","following_url":"https://api.github.com/users/Daskie/following{/other_user}","gists_url":"https://api.github.com/users/Daskie/gists{/gist_id}","starred_url":"https://api.github.com/users/Daskie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Daskie/subscriptions","organizations_url":"https://api.github.com/users/Daskie/orgs","repos_url":"https://api.github.com/users/Daskie/repos","events_url":"https://api.github.com/users/Daskie/events{/privacy}","received_events_url":"https://api.github.com/users/Daskie/received_events","type":"User","site_admin":false},"body":"Message.hpp has a small writeup on how to use messaging.\r\nPhysics. Things can have velocities, be accelerated, etc. So gravity, friction, jumping.\r\nThere's the idea of \"the ground\" now. It's possible to know if something's \"on the ground\" and what the normal of that ground is.\r\nThe player and the camera now have separate orientations, where the orientation of the camera is defined in spherical coordinates and is relative to the player's orientation.\r\nThere's a separate free-cam object that can be toggled.\r\nEngineApp, Scene, and Systems are now static classes. They were singletons for awhile, but singletons are icky.\r\nA million other things i'm sure. I'll need to talk to you guys about some of it.\r\n","created_at":"2018-02-20T10:42:43Z","updated_at":"2018-02-21T02:59:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fe2efdbcf1a137bd0ea595b055e7930924f200d2","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35/commits","review_comments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35/comments","review_comment_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/35/comments","statuses_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/statuses/6d1a880e67c95aa21fb0d7dc6ab31497dd4da4df","head":{"label":"jaafersheriff:devq_feature","ref":"devq_feature","sha":"6d1a880e67c95aa21fb0d7dc6ab31497dd4da4df","user":{"login":"jaafersheriff","id":8008854,"avatar_url":"https://avatars3.githubusercontent.com/u/8008854?v=4","gravatar_id":"","url":"https://api.github.com/users/jaafersheriff","html_url":"https://github.com/jaafersheriff","followers_url":"https://api.github.com/users/jaafersheriff/followers","following_url":"https://api.github.com/users/jaafersheriff/following{/other_user}","gists_url":"https://api.github.com/users/jaafersheriff/gists{/gist_id}","starred_url":"https://api.github.com/users/jaafersheriff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaafersheriff/subscriptions","organizations_url":"https://api.github.com/users/jaafersheriff/orgs","repos_url":"https://api.github.com/users/jaafersheriff/repos","events_url":"https://api.github.com/users/jaafersheriff/events{/privacy}","received_events_url":"https://api.github.com/users/jaafersheriff/received_events","type":"User","site_admin":false},"repo":{"id":118297768,"name":"BattleRoyale","full_name":"jaafersheriff/BattleRoyale","owner":{"login":"jaafersheriff","id":8008854,"avatar_url":"https://avatars3.githubusercontent.com/u/8008854?v=4","gravatar_id":"","url":"https://api.github.com/users/jaafersheriff","html_url":"https://github.com/jaafersheriff","followers_url":"https://api.github.com/users/jaafersheriff/followers","following_url":"https://api.github.com/users/jaafersheriff/following{/other_user}","gists_url":"https://api.github.com/users/jaafersheriff/gists{/gist_id}","starred_url":"https://api.github.com/users/jaafersheriff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaafersheriff/subscriptions","organizations_url":"https://api.github.com/users/jaafersheriff/orgs","repos_url":"https://api.github.com/users/jaafersheriff/repos","events_url":"https://api.github.com/users/jaafersheriff/events{/privacy}","received_events_url":"https://api.github.com/users/jaafersheriff/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jaafersheriff/BattleRoyale","description":null,"fork":false,"url":"https://api.github.com/repos/jaafersheriff/BattleRoyale","forks_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/forks","keys_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/teams","hooks_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/hooks","issue_events_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/events{/number}","events_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/events","assignees_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/assignees{/user}","branches_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/branches{/branch}","tags_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/tags","blobs_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/refs{/sha}","trees_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/statuses/{sha}","languages_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/languages","stargazers_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/stargazers","contributors_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/contributors","subscribers_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/subscribers","subscription_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/subscription","commits_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/commits{/sha}","git_commits_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/commits{/sha}","comments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/comments{/number}","issue_comment_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/comments{/number}","contents_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/contents/{+path}","compare_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/merges","archive_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/downloads","issues_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues{/number}","pulls_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls{/number}","milestones_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/milestones{/number}","notifications_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/labels{/name}","releases_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/releases{/id}","deployments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/deployments","created_at":"2018-01-21T02:24:49Z","updated_at":"2018-01-21T02:25:04Z","pushed_at":"2018-02-21T02:30:18Z","git_url":"git://github.com/jaafersheriff/BattleRoyale.git","ssh_url":"git@github.com:jaafersheriff/BattleRoyale.git","clone_url":"https://github.com/jaafersheriff/BattleRoyale.git","svn_url":"https://github.com/jaafersheriff/BattleRoyale","homepage":null,"size":54562,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":3,"license":null,"forks":1,"open_issues":3,"watchers":0,"default_branch":"master"}},"base":{"label":"jaafersheriff:master","ref":"master","sha":"bbf7e4ec70b10bd7cb46177e914b49f2bac66c54","user":{"login":"jaafersheriff","id":8008854,"avatar_url":"https://avatars3.githubusercontent.com/u/8008854?v=4","gravatar_id":"","url":"https://api.github.com/users/jaafersheriff","html_url":"https://github.com/jaafersheriff","followers_url":"https://api.github.com/users/jaafersheriff/followers","following_url":"https://api.github.com/users/jaafersheriff/following{/other_user}","gists_url":"https://api.github.com/users/jaafersheriff/gists{/gist_id}","starred_url":"https://api.github.com/users/jaafersheriff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaafersheriff/subscriptions","organizations_url":"https://api.github.com/users/jaafersheriff/orgs","repos_url":"https://api.github.com/users/jaafersheriff/repos","events_url":"https://api.github.com/users/jaafersheriff/events{/privacy}","received_events_url":"https://api.github.com/users/jaafersheriff/received_events","type":"User","site_admin":false},"repo":{"id":118297768,"name":"BattleRoyale","full_name":"jaafersheriff/BattleRoyale","owner":{"login":"jaafersheriff","id":8008854,"avatar_url":"https://avatars3.githubusercontent.com/u/8008854?v=4","gravatar_id":"","url":"https://api.github.com/users/jaafersheriff","html_url":"https://github.com/jaafersheriff","followers_url":"https://api.github.com/users/jaafersheriff/followers","following_url":"https://api.github.com/users/jaafersheriff/following{/other_user}","gists_url":"https://api.github.com/users/jaafersheriff/gists{/gist_id}","starred_url":"https://api.github.com/users/jaafersheriff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaafersheriff/subscriptions","organizations_url":"https://api.github.com/users/jaafersheriff/orgs","repos_url":"https://api.github.com/users/jaafersheriff/repos","events_url":"https://api.github.com/users/jaafersheriff/events{/privacy}","received_events_url":"https://api.github.com/users/jaafersheriff/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jaafersheriff/BattleRoyale","description":null,"fork":false,"url":"https://api.github.com/repos/jaafersheriff/BattleRoyale","forks_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/forks","keys_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/teams","hooks_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/hooks","issue_events_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/events{/number}","events_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/events","assignees_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/assignees{/user}","branches_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/branches{/branch}","tags_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/tags","blobs_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/refs{/sha}","trees_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/statuses/{sha}","languages_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/languages","stargazers_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/stargazers","contributors_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/contributors","subscribers_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/subscribers","subscription_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/subscription","commits_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/commits{/sha}","git_commits_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/git/commits{/sha}","comments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/comments{/number}","issue_comment_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/comments{/number}","contents_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/contents/{+path}","compare_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/merges","archive_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/downloads","issues_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues{/number}","pulls_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls{/number}","milestones_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/milestones{/number}","notifications_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/labels{/name}","releases_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/releases{/id}","deployments_url":"https://api.github.com/repos/jaafersheriff/BattleRoyale/deployments","created_at":"2018-01-21T02:24:49Z","updated_at":"2018-01-21T02:25:04Z","pushed_at":"2018-02-21T02:30:18Z","git_url":"git://github.com/jaafersheriff/BattleRoyale.git","ssh_url":"git@github.com:jaafersheriff/BattleRoyale.git","clone_url":"https://github.com/jaafersheriff/BattleRoyale.git","svn_url":"https://github.com/jaafersheriff/BattleRoyale","homepage":null,"size":54562,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":3,"license":null,"forks":1,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35"},"html":{"href":"https://github.com/jaafersheriff/BattleRoyale/pull/35"},"issue":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/35"},"comments":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/issues/35/comments"},"review_comments":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35/comments"},"review_comment":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/pulls/35/commits"},"statuses":{"href":"https://api.github.com/repos/jaafersheriff/BattleRoyale/statuses/6d1a880e67c95aa21fb0d7dc6ab31497dd4da4df"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"Daskie"}}