{"action":"created","comment":{"url":"https://api.github.com/repos/Segs/Segs/pulls/comments/191056883","pull_request_review_id":123564867,"id":191056883,"diff_hunk":"@@ -365,18 +365,29 @@ void GameHandler::on_map_req(MapServerAddrRequest *ev)\n     }\n \n     QString map_path = cd.m_mapName;\n-    switch(ev->m_mapnumber)\n+\n+    if (!map_path.isEmpty())\n     {\n-        case 0:\n-        if(map_path.isEmpty())\n-            map_path = \"maps/city_zones/city_00_01/city_00_01.txt\";\n-        break;\n-        case 1: // atlas park\n-            map_path = \"maps/city_zones/city_01_01/city_01_01.txt\";\n-        break;\n-        case 29:\n-            map_path = \"maps/city_zones/city_01_03/city_01_03.txt\";\n-        break;\n+        switch(checkMap(map_path))\n+        {\n+            case Outbreak: map_path = \"maps/city_zones/city_00_01/city_00_01.txt\"; break;\n+            case AtlasPark: map_path = \"maps/city_zones/city_01_01/city_01_01.txt\"; break;\n+        }\n+    }\n+    else\n+    {\n+        switch(ev->m_mapnumber)","path":"Projects/CoX/Servers/GameServer/GameHandler.cpp","position":26,"original_position":26,"commit_id":"5c9e3ba9a2652fcecde3f3334fc379c81b2b366f","original_commit_id":"5c9e3ba9a2652fcecde3f3334fc379c81b2b366f","user":{"login":"broxen","id":10159505,"avatar_url":"https://avatars2.githubusercontent.com/u/10159505?v=4","gravatar_id":"","url":"https://api.github.com/users/broxen","html_url":"https://github.com/broxen","followers_url":"https://api.github.com/users/broxen/followers","following_url":"https://api.github.com/users/broxen/following{/other_user}","gists_url":"https://api.github.com/users/broxen/gists{/gist_id}","starred_url":"https://api.github.com/users/broxen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/broxen/subscriptions","organizations_url":"https://api.github.com/users/broxen/orgs","repos_url":"https://api.github.com/users/broxen/repos","events_url":"https://api.github.com/users/broxen/events{/privacy}","received_events_url":"https://api.github.com/users/broxen/received_events","type":"User","site_admin":false},"body":"In the future we'll have some sort of global vector of map values sorted by IDX that we can switch against.","created_at":"2018-05-26T19:30:29Z","updated_at":"2018-05-26T19:32:55Z","html_url":"https://github.com/Segs/Segs/pull/409#discussion_r191056883","pull_request_url":"https://api.github.com/repos/Segs/Segs/pulls/409","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/Segs/Segs/pulls/comments/191056883"},"html":{"href":"https://github.com/Segs/Segs/pull/409#discussion_r191056883"},"pull_request":{"href":"https://api.github.com/repos/Segs/Segs/pulls/409"}}},"pull_request":{"url":"https://api.github.com/repos/Segs/Segs/pulls/409","id":187633776,"html_url":"https://github.com/Segs/Segs/pull/409","diff_url":"https://github.com/Segs/Segs/pull/409.diff","patch_url":"https://github.com/Segs/Segs/pull/409.patch","issue_url":"https://api.github.com/repos/Segs/Segs/issues/409","number":409,"state":"open","locked":false,"title":"Issue #271 - Automatically Updating Characters in Database","user":{"login":"eos428","id":38433056,"avatar_url":"https://avatars2.githubusercontent.com/u/38433056?v=4","gravatar_id":"","url":"https://api.github.com/users/eos428","html_url":"https://github.com/eos428","followers_url":"https://api.github.com/users/eos428/followers","following_url":"https://api.github.com/users/eos428/following{/other_user}","gists_url":"https://api.github.com/users/eos428/gists{/gist_id}","starred_url":"https://api.github.com/users/eos428/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eos428/subscriptions","organizations_url":"https://api.github.com/users/eos428/orgs","repos_url":"https://api.github.com/users/eos428/repos","events_url":"https://api.github.com/users/eos428/events{/privacy}","received_events_url":"https://api.github.com/users/eos428/received_events","type":"User","site_admin":false},"body":"Issue #271\r\n\r\nGoal: Characters can be automatically updated without slash commands /save and /charupdate\r\n\r\nFiles changed:\r\n\r\n**WorldSimulation.cpp**\r\n\r\n- In World::update, inside the for loop with entities, update the player characters every n seconds (in this case, 5 secs)\r\n- charUpdateDb(e) is a placeholder atm\r\n\r\n**Entity.cpp and .h**\r\n- Added a function to check the if the player has a valid DbStoreFlag\r\n\r\nTo-do and/or wishlists:\r\n- (To confirm with others) Call GameDbSyncContext::performUpdate based on the DbStoreFlag, and put the required data into the structs as parameters\r\n- Modify slashCommand.cpp so that they actually update the database","created_at":"2018-05-12T18:22:02Z","updated_at":"2018-05-26T19:32:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"941fa53c4cc5901223f39a226c9a497e99a9006b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":28453034,"url":"https://api.github.com/repos/Segs/Segs/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"milestone":null,"commits_url":"https://api.github.com/repos/Segs/Segs/pulls/409/commits","review_comments_url":"https://api.github.com/repos/Segs/Segs/pulls/409/comments","review_comment_url":"https://api.github.com/repos/Segs/Segs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Segs/Segs/issues/409/comments","statuses_url":"https://api.github.com/repos/Segs/Segs/statuses/5c9e3ba9a2652fcecde3f3334fc379c81b2b366f","head":{"label":"eos428:master","ref":"master","sha":"5c9e3ba9a2652fcecde3f3334fc379c81b2b366f","user":{"login":"eos428","id":38433056,"avatar_url":"https://avatars2.githubusercontent.com/u/38433056?v=4","gravatar_id":"","url":"https://api.github.com/users/eos428","html_url":"https://github.com/eos428","followers_url":"https://api.github.com/users/eos428/followers","following_url":"https://api.github.com/users/eos428/following{/other_user}","gists_url":"https://api.github.com/users/eos428/gists{/gist_id}","starred_url":"https://api.github.com/users/eos428/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eos428/subscriptions","organizations_url":"https://api.github.com/users/eos428/orgs","repos_url":"https://api.github.com/users/eos428/repos","events_url":"https://api.github.com/users/eos428/events{/privacy}","received_events_url":"https://api.github.com/users/eos428/received_events","type":"User","site_admin":false},"repo":{"id":129771017,"name":"Segs","full_name":"eos428/Segs","owner":{"login":"eos428","id":38433056,"avatar_url":"https://avatars2.githubusercontent.com/u/38433056?v=4","gravatar_id":"","url":"https://api.github.com/users/eos428","html_url":"https://github.com/eos428","followers_url":"https://api.github.com/users/eos428/followers","following_url":"https://api.github.com/users/eos428/following{/other_user}","gists_url":"https://api.github.com/users/eos428/gists{/gist_id}","starred_url":"https://api.github.com/users/eos428/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eos428/subscriptions","organizations_url":"https://api.github.com/users/eos428/orgs","repos_url":"https://api.github.com/users/eos428/repos","events_url":"https://api.github.com/users/eos428/events{/privacy}","received_events_url":"https://api.github.com/users/eos428/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/eos428/Segs","description":":muscle: SEGS - Super Entity Game Server","fork":true,"url":"https://api.github.com/repos/eos428/Segs","forks_url":"https://api.github.com/repos/eos428/Segs/forks","keys_url":"https://api.github.com/repos/eos428/Segs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eos428/Segs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eos428/Segs/teams","hooks_url":"https://api.github.com/repos/eos428/Segs/hooks","issue_events_url":"https://api.github.com/repos/eos428/Segs/issues/events{/number}","events_url":"https://api.github.com/repos/eos428/Segs/events","assignees_url":"https://api.github.com/repos/eos428/Segs/assignees{/user}","branches_url":"https://api.github.com/repos/eos428/Segs/branches{/branch}","tags_url":"https://api.github.com/repos/eos428/Segs/tags","blobs_url":"https://api.github.com/repos/eos428/Segs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eos428/Segs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eos428/Segs/git/refs{/sha}","trees_url":"https://api.github.com/repos/eos428/Segs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eos428/Segs/statuses/{sha}","languages_url":"https://api.github.com/repos/eos428/Segs/languages","stargazers_url":"https://api.github.com/repos/eos428/Segs/stargazers","contributors_url":"https://api.github.com/repos/eos428/Segs/contributors","subscribers_url":"https://api.github.com/repos/eos428/Segs/subscribers","subscription_url":"https://api.github.com/repos/eos428/Segs/subscription","commits_url":"https://api.github.com/repos/eos428/Segs/commits{/sha}","git_commits_url":"https://api.github.com/repos/eos428/Segs/git/commits{/sha}","comments_url":"https://api.github.com/repos/eos428/Segs/comments{/number}","issue_comment_url":"https://api.github.com/repos/eos428/Segs/issues/comments{/number}","contents_url":"https://api.github.com/repos/eos428/Segs/contents/{+path}","compare_url":"https://api.github.com/repos/eos428/Segs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eos428/Segs/merges","archive_url":"https://api.github.com/repos/eos428/Segs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eos428/Segs/downloads","issues_url":"https://api.github.com/repos/eos428/Segs/issues{/number}","pulls_url":"https://api.github.com/repos/eos428/Segs/pulls{/number}","milestones_url":"https://api.github.com/repos/eos428/Segs/milestones{/number}","notifications_url":"https://api.github.com/repos/eos428/Segs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eos428/Segs/labels{/name}","releases_url":"https://api.github.com/repos/eos428/Segs/releases{/id}","deployments_url":"https://api.github.com/repos/eos428/Segs/deployments","created_at":"2018-04-16T16:07:03Z","updated_at":"2018-05-26T17:30:28Z","pushed_at":"2018-05-26T17:30:26Z","git_url":"git://github.com/eos428/Segs.git","ssh_url":"git@github.com:eos428/Segs.git","clone_url":"https://github.com/eos428/Segs.git","svn_url":"https://github.com/eos428/Segs","homepage":"http://segs.nemerle.eu","size":24094,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"Segs:master","ref":"master","sha":"22bd68abc2151c73bef8211f5e2009a0130a98a2","user":{"login":"Segs","id":3596609,"avatar_url":"https://avatars1.githubusercontent.com/u/3596609?v=4","gravatar_id":"","url":"https://api.github.com/users/Segs","html_url":"https://github.com/Segs","followers_url":"https://api.github.com/users/Segs/followers","following_url":"https://api.github.com/users/Segs/following{/other_user}","gists_url":"https://api.github.com/users/Segs/gists{/gist_id}","starred_url":"https://api.github.com/users/Segs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Segs/subscriptions","organizations_url":"https://api.github.com/users/Segs/orgs","repos_url":"https://api.github.com/users/Segs/repos","events_url":"https://api.github.com/users/Segs/events{/privacy}","received_events_url":"https://api.github.com/users/Segs/received_events","type":"Organization","site_admin":false},"repo":{"id":8205781,"name":"Segs","full_name":"Segs/Segs","owner":{"login":"Segs","id":3596609,"avatar_url":"https://avatars1.githubusercontent.com/u/3596609?v=4","gravatar_id":"","url":"https://api.github.com/users/Segs","html_url":"https://github.com/Segs","followers_url":"https://api.github.com/users/Segs/followers","following_url":"https://api.github.com/users/Segs/following{/other_user}","gists_url":"https://api.github.com/users/Segs/gists{/gist_id}","starred_url":"https://api.github.com/users/Segs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Segs/subscriptions","organizations_url":"https://api.github.com/users/Segs/orgs","repos_url":"https://api.github.com/users/Segs/repos","events_url":"https://api.github.com/users/Segs/events{/privacy}","received_events_url":"https://api.github.com/users/Segs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Segs/Segs","description":":muscle: SEGS - Super Entity Game Server","fork":false,"url":"https://api.github.com/repos/Segs/Segs","forks_url":"https://api.github.com/repos/Segs/Segs/forks","keys_url":"https://api.github.com/repos/Segs/Segs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Segs/Segs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Segs/Segs/teams","hooks_url":"https://api.github.com/repos/Segs/Segs/hooks","issue_events_url":"https://api.github.com/repos/Segs/Segs/issues/events{/number}","events_url":"https://api.github.com/repos/Segs/Segs/events","assignees_url":"https://api.github.com/repos/Segs/Segs/assignees{/user}","branches_url":"https://api.github.com/repos/Segs/Segs/branches{/branch}","tags_url":"https://api.github.com/repos/Segs/Segs/tags","blobs_url":"https://api.github.com/repos/Segs/Segs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Segs/Segs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Segs/Segs/git/refs{/sha}","trees_url":"https://api.github.com/repos/Segs/Segs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Segs/Segs/statuses/{sha}","languages_url":"https://api.github.com/repos/Segs/Segs/languages","stargazers_url":"https://api.github.com/repos/Segs/Segs/stargazers","contributors_url":"https://api.github.com/repos/Segs/Segs/contributors","subscribers_url":"https://api.github.com/repos/Segs/Segs/subscribers","subscription_url":"https://api.github.com/repos/Segs/Segs/subscription","commits_url":"https://api.github.com/repos/Segs/Segs/commits{/sha}","git_commits_url":"https://api.github.com/repos/Segs/Segs/git/commits{/sha}","comments_url":"https://api.github.com/repos/Segs/Segs/comments{/number}","issue_comment_url":"https://api.github.com/repos/Segs/Segs/issues/comments{/number}","contents_url":"https://api.github.com/repos/Segs/Segs/contents/{+path}","compare_url":"https://api.github.com/repos/Segs/Segs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Segs/Segs/merges","archive_url":"https://api.github.com/repos/Segs/Segs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Segs/Segs/downloads","issues_url":"https://api.github.com/repos/Segs/Segs/issues{/number}","pulls_url":"https://api.github.com/repos/Segs/Segs/pulls{/number}","milestones_url":"https://api.github.com/repos/Segs/Segs/milestones{/number}","notifications_url":"https://api.github.com/repos/Segs/Segs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Segs/Segs/labels{/name}","releases_url":"https://api.github.com/repos/Segs/Segs/releases{/id}","deployments_url":"https://api.github.com/repos/Segs/Segs/deployments","created_at":"2013-02-14T19:15:30Z","updated_at":"2018-05-26T16:02:02Z","pushed_at":"2018-05-26T17:30:28Z","git_url":"git://github.com/Segs/Segs.git","ssh_url":"git@github.com:Segs/Segs.git","clone_url":"https://github.com/Segs/Segs.git","svn_url":"https://github.com/Segs/Segs","homepage":"http://segs.io/","size":24051,"stargazers_count":51,"watchers_count":51,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":28,"mirror_url":null,"archived":false,"open_issues_count":55,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":28,"open_issues":55,"watchers":51,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Segs/Segs/pulls/409"},"html":{"href":"https://github.com/Segs/Segs/pull/409"},"issue":{"href":"https://api.github.com/repos/Segs/Segs/issues/409"},"comments":{"href":"https://api.github.com/repos/Segs/Segs/issues/409/comments"},"review_comments":{"href":"https://api.github.com/repos/Segs/Segs/pulls/409/comments"},"review_comment":{"href":"https://api.github.com/repos/Segs/Segs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Segs/Segs/pulls/409/commits"},"statuses":{"href":"https://api.github.com/repos/Segs/Segs/statuses/5c9e3ba9a2652fcecde3f3334fc379c81b2b366f"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"broxen"}}