{"action":"created","comment":{"url":"https://api.github.com/repos/cuberite/cuberite/pulls/comments/38815102","id":38815102,"diff_hunk":"@@ -1046,12 +1046,21 @@ void cPlayer::Respawn(void)\n \tm_LifetimeTotalXp = 0;\n \t// ToDo: send score to client? How?\n \n-\tm_ClientHandle->SendRespawn(GetWorld()->GetDimension(), true);\n+\tm_ClientHandle->SendRespawn(dimOverworld, true);\n \n \t// Extinguish the fire:\n \tStopBurning();\n \n-\tTeleportToCoords(GetLastBedPos().x, GetLastBedPos().y, GetLastBedPos().z);\n+\tcWorld *world = GetWorld();\n+\tif (world->GetDimension() != dimOverworld)\n+\t{\n+\t\tworld = cRoot::Get()->CreateAndInitializeWorld(world->GetLinkedOverworldName(), dimOverworld, world->GetLinkedOverworldName(), false);","path":"src/Entities/Player.cpp","position":14,"original_position":14,"commit_id":"83813b049b5b0636e255725e0ddb7d6815cc00ff","original_commit_id":"83813b049b5b0636e255725e0ddb7d6815cc00ff","user":{"login":"madmaxoft","id":4388386,"avatar_url":"https://avatars.githubusercontent.com/u/4388386?v=3","gravatar_id":"","url":"https://api.github.com/users/madmaxoft","html_url":"https://github.com/madmaxoft","followers_url":"https://api.github.com/users/madmaxoft/followers","following_url":"https://api.github.com/users/madmaxoft/following{/other_user}","gists_url":"https://api.github.com/users/madmaxoft/gists{/gist_id}","starred_url":"https://api.github.com/users/madmaxoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/madmaxoft/subscriptions","organizations_url":"https://api.github.com/users/madmaxoft/orgs","repos_url":"https://api.github.com/users/madmaxoft/repos","events_url":"https://api.github.com/users/madmaxoft/events{/privacy}","received_events_url":"https://api.github.com/users/madmaxoft/received_events","type":"User","site_admin":false},"body":"I think the proper solution here would be to simply get the linked world by name, and only move to that world if available. If the world is not available, then it hasn't been configured by the admin (imagine a Nether-only server, for example) and the player should then stay in the Nether.","created_at":"2015-09-05T21:48:51Z","updated_at":"2015-09-05T21:48:51Z","html_url":"https://github.com/cuberite/cuberite/pull/2462#discussion_r38815102","pull_request_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2462","_links":{"self":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/comments/38815102"},"html":{"href":"https://github.com/cuberite/cuberite/pull/2462#discussion_r38815102"},"pull_request":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2462"}}},"pull_request":{"url":"https://api.github.com/repos/cuberite/cuberite/pulls/2462","id":44241374,"html_url":"https://github.com/cuberite/cuberite/pull/2462","diff_url":"https://github.com/cuberite/cuberite/pull/2462.diff","patch_url":"https://github.com/cuberite/cuberite/pull/2462.patch","issue_url":"https://api.github.com/repos/cuberite/cuberite/issues/2462","number":2462,"state":"open","locked":false,"title":"Now the player always respawns at the overworld, when he dies.","user":{"login":"bibo38","id":1812304,"avatar_url":"https://avatars.githubusercontent.com/u/1812304?v=3","gravatar_id":"","url":"https://api.github.com/users/bibo38","html_url":"https://github.com/bibo38","followers_url":"https://api.github.com/users/bibo38/followers","following_url":"https://api.github.com/users/bibo38/following{/other_user}","gists_url":"https://api.github.com/users/bibo38/gists{/gist_id}","starred_url":"https://api.github.com/users/bibo38/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bibo38/subscriptions","organizations_url":"https://api.github.com/users/bibo38/orgs","repos_url":"https://api.github.com/users/bibo38/repos","events_url":"https://api.github.com/users/bibo38/events{/privacy}","received_events_url":"https://api.github.com/users/bibo38/received_events","type":"User","site_admin":false},"body":"Fixes #2454 ","created_at":"2015-09-04T17:18:40Z","updated_at":"2015-09-05T21:48:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a84d1777e1011f3aa8182a7588674c4b7ade7cd2","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2462/commits","review_comments_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2462/comments","review_comment_url":"https://api.github.com/repos/cuberite/cuberite/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cuberite/cuberite/issues/2462/comments","statuses_url":"https://api.github.com/repos/cuberite/cuberite/statuses/83813b049b5b0636e255725e0ddb7d6815cc00ff","head":{"label":"bibo38:respawnfix","ref":"respawnfix","sha":"83813b049b5b0636e255725e0ddb7d6815cc00ff","user":{"login":"bibo38","id":1812304,"avatar_url":"https://avatars.githubusercontent.com/u/1812304?v=3","gravatar_id":"","url":"https://api.github.com/users/bibo38","html_url":"https://github.com/bibo38","followers_url":"https://api.github.com/users/bibo38/followers","following_url":"https://api.github.com/users/bibo38/following{/other_user}","gists_url":"https://api.github.com/users/bibo38/gists{/gist_id}","starred_url":"https://api.github.com/users/bibo38/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bibo38/subscriptions","organizations_url":"https://api.github.com/users/bibo38/orgs","repos_url":"https://api.github.com/users/bibo38/repos","events_url":"https://api.github.com/users/bibo38/events{/privacy}","received_events_url":"https://api.github.com/users/bibo38/received_events","type":"User","site_admin":false},"repo":{"id":32388940,"name":"Cuberite","full_name":"bibo38/Cuberite","owner":{"login":"bibo38","id":1812304,"avatar_url":"https://avatars.githubusercontent.com/u/1812304?v=3","gravatar_id":"","url":"https://api.github.com/users/bibo38","html_url":"https://github.com/bibo38","followers_url":"https://api.github.com/users/bibo38/followers","following_url":"https://api.github.com/users/bibo38/following{/other_user}","gists_url":"https://api.github.com/users/bibo38/gists{/gist_id}","starred_url":"https://api.github.com/users/bibo38/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bibo38/subscriptions","organizations_url":"https://api.github.com/users/bibo38/orgs","repos_url":"https://api.github.com/users/bibo38/repos","events_url":"https://api.github.com/users/bibo38/events{/privacy}","received_events_url":"https://api.github.com/users/bibo38/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bibo38/Cuberite","description":"A performant C++ Minecraft Server","fork":true,"url":"https://api.github.com/repos/bibo38/Cuberite","forks_url":"https://api.github.com/repos/bibo38/Cuberite/forks","keys_url":"https://api.github.com/repos/bibo38/Cuberite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bibo38/Cuberite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bibo38/Cuberite/teams","hooks_url":"https://api.github.com/repos/bibo38/Cuberite/hooks","issue_events_url":"https://api.github.com/repos/bibo38/Cuberite/issues/events{/number}","events_url":"https://api.github.com/repos/bibo38/Cuberite/events","assignees_url":"https://api.github.com/repos/bibo38/Cuberite/assignees{/user}","branches_url":"https://api.github.com/repos/bibo38/Cuberite/branches{/branch}","tags_url":"https://api.github.com/repos/bibo38/Cuberite/tags","blobs_url":"https://api.github.com/repos/bibo38/Cuberite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bibo38/Cuberite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bibo38/Cuberite/git/refs{/sha}","trees_url":"https://api.github.com/repos/bibo38/Cuberite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bibo38/Cuberite/statuses/{sha}","languages_url":"https://api.github.com/repos/bibo38/Cuberite/languages","stargazers_url":"https://api.github.com/repos/bibo38/Cuberite/stargazers","contributors_url":"https://api.github.com/repos/bibo38/Cuberite/contributors","subscribers_url":"https://api.github.com/repos/bibo38/Cuberite/subscribers","subscription_url":"https://api.github.com/repos/bibo38/Cuberite/subscription","commits_url":"https://api.github.com/repos/bibo38/Cuberite/commits{/sha}","git_commits_url":"https://api.github.com/repos/bibo38/Cuberite/git/commits{/sha}","comments_url":"https://api.github.com/repos/bibo38/Cuberite/comments{/number}","issue_comment_url":"https://api.github.com/repos/bibo38/Cuberite/issues/comments{/number}","contents_url":"https://api.github.com/repos/bibo38/Cuberite/contents/{+path}","compare_url":"https://api.github.com/repos/bibo38/Cuberite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bibo38/Cuberite/merges","archive_url":"https://api.github.com/repos/bibo38/Cuberite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bibo38/Cuberite/downloads","issues_url":"https://api.github.com/repos/bibo38/Cuberite/issues{/number}","pulls_url":"https://api.github.com/repos/bibo38/Cuberite/pulls{/number}","milestones_url":"https://api.github.com/repos/bibo38/Cuberite/milestones{/number}","notifications_url":"https://api.github.com/repos/bibo38/Cuberite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bibo38/Cuberite/labels{/name}","releases_url":"https://api.github.com/repos/bibo38/Cuberite/releases{/id}","created_at":"2015-03-17T11:15:30Z","updated_at":"2015-06-25T08:52:53Z","pushed_at":"2015-09-05T20:09:37Z","git_url":"git://github.com/bibo38/Cuberite.git","ssh_url":"git@github.com:bibo38/Cuberite.git","clone_url":"https://github.com/bibo38/Cuberite.git","svn_url":"https://github.com/bibo38/Cuberite","homepage":"mc-server.org","size":76520,"stargazers_count":1,"watchers_count":1,"language":"C","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":1,"default_branch":"master"}},"base":{"label":"cuberite:master","ref":"master","sha":"4463eed82606634bf2b9e423b0cd0e5dd129af77","user":{"login":"cuberite","id":8973961,"avatar_url":"https://avatars.githubusercontent.com/u/8973961?v=3","gravatar_id":"","url":"https://api.github.com/users/cuberite","html_url":"https://github.com/cuberite","followers_url":"https://api.github.com/users/cuberite/followers","following_url":"https://api.github.com/users/cuberite/following{/other_user}","gists_url":"https://api.github.com/users/cuberite/gists{/gist_id}","starred_url":"https://api.github.com/users/cuberite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cuberite/subscriptions","organizations_url":"https://api.github.com/users/cuberite/orgs","repos_url":"https://api.github.com/users/cuberite/repos","events_url":"https://api.github.com/users/cuberite/events{/privacy}","received_events_url":"https://api.github.com/users/cuberite/received_events","type":"Organization","site_admin":false},"repo":{"id":11693709,"name":"cuberite","full_name":"cuberite/cuberite","owner":{"login":"cuberite","id":8973961,"avatar_url":"https://avatars.githubusercontent.com/u/8973961?v=3","gravatar_id":"","url":"https://api.github.com/users/cuberite","html_url":"https://github.com/cuberite","followers_url":"https://api.github.com/users/cuberite/followers","following_url":"https://api.github.com/users/cuberite/following{/other_user}","gists_url":"https://api.github.com/users/cuberite/gists{/gist_id}","starred_url":"https://api.github.com/users/cuberite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cuberite/subscriptions","organizations_url":"https://api.github.com/users/cuberite/orgs","repos_url":"https://api.github.com/users/cuberite/repos","events_url":"https://api.github.com/users/cuberite/events{/privacy}","received_events_url":"https://api.github.com/users/cuberite/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cuberite/cuberite","description":"A performant C++ Minecraft compatible game server","fork":false,"url":"https://api.github.com/repos/cuberite/cuberite","forks_url":"https://api.github.com/repos/cuberite/cuberite/forks","keys_url":"https://api.github.com/repos/cuberite/cuberite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cuberite/cuberite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cuberite/cuberite/teams","hooks_url":"https://api.github.com/repos/cuberite/cuberite/hooks","issue_events_url":"https://api.github.com/repos/cuberite/cuberite/issues/events{/number}","events_url":"https://api.github.com/repos/cuberite/cuberite/events","assignees_url":"https://api.github.com/repos/cuberite/cuberite/assignees{/user}","branches_url":"https://api.github.com/repos/cuberite/cuberite/branches{/branch}","tags_url":"https://api.github.com/repos/cuberite/cuberite/tags","blobs_url":"https://api.github.com/repos/cuberite/cuberite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cuberite/cuberite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cuberite/cuberite/git/refs{/sha}","trees_url":"https://api.github.com/repos/cuberite/cuberite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cuberite/cuberite/statuses/{sha}","languages_url":"https://api.github.com/repos/cuberite/cuberite/languages","stargazers_url":"https://api.github.com/repos/cuberite/cuberite/stargazers","contributors_url":"https://api.github.com/repos/cuberite/cuberite/contributors","subscribers_url":"https://api.github.com/repos/cuberite/cuberite/subscribers","subscription_url":"https://api.github.com/repos/cuberite/cuberite/subscription","commits_url":"https://api.github.com/repos/cuberite/cuberite/commits{/sha}","git_commits_url":"https://api.github.com/repos/cuberite/cuberite/git/commits{/sha}","comments_url":"https://api.github.com/repos/cuberite/cuberite/comments{/number}","issue_comment_url":"https://api.github.com/repos/cuberite/cuberite/issues/comments{/number}","contents_url":"https://api.github.com/repos/cuberite/cuberite/contents/{+path}","compare_url":"https://api.github.com/repos/cuberite/cuberite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cuberite/cuberite/merges","archive_url":"https://api.github.com/repos/cuberite/cuberite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cuberite/cuberite/downloads","issues_url":"https://api.github.com/repos/cuberite/cuberite/issues{/number}","pulls_url":"https://api.github.com/repos/cuberite/cuberite/pulls{/number}","milestones_url":"https://api.github.com/repos/cuberite/cuberite/milestones{/number}","notifications_url":"https://api.github.com/repos/cuberite/cuberite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cuberite/cuberite/labels{/name}","releases_url":"https://api.github.com/repos/cuberite/cuberite/releases{/id}","created_at":"2013-07-26T19:56:59Z","updated_at":"2015-09-03T13:53:11Z","pushed_at":"2015-09-05T20:12:00Z","git_url":"git://github.com/cuberite/cuberite.git","ssh_url":"git@github.com:cuberite/cuberite.git","clone_url":"https://github.com/cuberite/cuberite.git","svn_url":"https://github.com/cuberite/cuberite","homepage":"http://cuberite.org","size":167338,"stargazers_count":726,"watchers_count":726,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":230,"mirror_url":null,"open_issues_count":387,"forks":230,"open_issues":387,"watchers":726,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2462"},"html":{"href":"https://github.com/cuberite/cuberite/pull/2462"},"issue":{"href":"https://api.github.com/repos/cuberite/cuberite/issues/2462"},"comments":{"href":"https://api.github.com/repos/cuberite/cuberite/issues/2462/comments"},"review_comments":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2462/comments"},"review_comment":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2462/commits"},"statuses":{"href":"https://api.github.com/repos/cuberite/cuberite/statuses/83813b049b5b0636e255725e0ddb7d6815cc00ff"}}}}