{"action":"created","issue":{"url":"https://api.github.com/repos/minetest/minetest/issues/3973","repository_url":"https://api.github.com/repos/minetest/minetest","labels_url":"https://api.github.com/repos/minetest/minetest/issues/3973/labels{/name}","comments_url":"https://api.github.com/repos/minetest/minetest/issues/3973/comments","events_url":"https://api.github.com/repos/minetest/minetest/issues/3973/events","html_url":"https://github.com/minetest/minetest/pull/3973","id":147065441,"number":3973,"title":"Mgvalleys: Don't let cavegen place biome nodes everywhere","user":{"login":"paramat","id":3686677,"avatar_url":"https://avatars.githubusercontent.com/u/3686677?v=3","gravatar_id":"","url":"https://api.github.com/users/paramat","html_url":"https://github.com/paramat","followers_url":"https://api.github.com/users/paramat/followers","following_url":"https://api.github.com/users/paramat/following{/other_user}","gists_url":"https://api.github.com/users/paramat/gists{/gist_id}","starred_url":"https://api.github.com/users/paramat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paramat/subscriptions","organizations_url":"https://api.github.com/users/paramat/orgs","repos_url":"https://api.github.com/users/paramat/repos","events_url":"https://api.github.com/users/paramat/events{/privacy}","received_events_url":"https://api.github.com/users/paramat/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/minetest/minetest/labels/@%20Mapgen","name":"@ Mapgen","color":"009800"},{"url":"https://api.github.com/repos/minetest/minetest/labels/One%20approval","name":"One approval","color":"207de5"},{"url":"https://api.github.com/repos/minetest/minetest/labels/WIP","name":"WIP","color":"aa3000"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/minetest/minetest/milestones/7","html_url":"https://github.com/minetest/minetest/milestones/0.4.14","labels_url":"https://api.github.com/repos/minetest/minetest/milestones/7/labels","id":1601315,"number":7,"title":"0.4.14","description":"This milestone for issues which should get resolved before the 0.4.14 release.","creator":{"login":"kahrl","id":630411,"avatar_url":"https://avatars.githubusercontent.com/u/630411?v=3","gravatar_id":"","url":"https://api.github.com/users/kahrl","html_url":"https://github.com/kahrl","followers_url":"https://api.github.com/users/kahrl/followers","following_url":"https://api.github.com/users/kahrl/following{/other_user}","gists_url":"https://api.github.com/users/kahrl/gists{/gist_id}","starred_url":"https://api.github.com/users/kahrl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kahrl/subscriptions","organizations_url":"https://api.github.com/users/kahrl/orgs","repos_url":"https://api.github.com/users/kahrl/repos","events_url":"https://api.github.com/users/kahrl/events{/privacy}","received_events_url":"https://api.github.com/users/kahrl/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":59,"state":"open","created_at":"2016-02-23T23:07:27Z","updated_at":"2016-04-11T07:17:46Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2016-04-08T23:43:24Z","updated_at":"2016-04-12T01:35:23Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/minetest/minetest/pulls/3973","html_url":"https://github.com/minetest/minetest/pull/3973","diff_url":"https://github.com/minetest/minetest/pull/3973.diff","patch_url":"https://github.com/minetest/minetest/pull/3973.patch"},"body":"Fix use of 'air_above' bool so that biome\r\nnodes are only placed in tunnel floors\r\nMinor code improvements\r\n'Continue' when massive cave air is placed\r\n//////////////////////////////\r\n\r\nSame issue as #3885 but now fixed in mgvalleys.\r\nTested.\r\n"},"comment":{"url":"https://api.github.com/repos/minetest/minetest/issues/comments/208657703","html_url":"https://github.com/minetest/minetest/pull/3973#issuecomment-208657703","issue_url":"https://api.github.com/repos/minetest/minetest/issues/3973","id":208657703,"user":{"login":"paramat","id":3686677,"avatar_url":"https://avatars.githubusercontent.com/u/3686677?v=3","gravatar_id":"","url":"https://api.github.com/users/paramat","html_url":"https://github.com/paramat","followers_url":"https://api.github.com/users/paramat/followers","following_url":"https://api.github.com/users/paramat/following{/other_user}","gists_url":"https://api.github.com/users/paramat/gists{/gist_id}","starred_url":"https://api.github.com/users/paramat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paramat/subscriptions","organizations_url":"https://api.github.com/users/paramat/orgs","repos_url":"https://api.github.com/users/paramat/repos","events_url":"https://api.github.com/users/paramat/events{/privacy}","received_events_url":"https://api.github.com/users/paramat/received_events","type":"User","site_admin":false},"created_at":"2016-04-12T01:35:23Z","updated_at":"2016-04-12T01:35:23Z","body":"Updated and tested.\r\n\r\nAs requested removed unnecessary:\r\n```\r\n\t\t\tif (c == CONTENT_AIR) {\r\n\t\t\t\tcontinue;\r\n```\r\nAlso optimised structure from:\r\n```\r\n\t\t\t} else if (d1 * d2 > 0.3f && ndef->get(c).is_ground_content) {\r\n\t\t\t\t............\r\n\t\t\t} else if (air_above && (c == biome->c_filler || c == biome->c_stone)) {\r\n\t\t\t\t............\r\n\t\t\t\tair_above = false;\r\n\t\t\t\tunderground = true;\r\n\t\t\t} else if (c == biome->c_filler || c == biome->c_stone) {\r\n\t\t\t\tair_above = false;\r\n\t\t\t\tunderground = true;\r\n\t\t\t} else {\r\n\t\t\t\tair_above = false;\r\n\t\t\t}\r\n```\r\nto:\r\n```\r\n\t\t\tif (d1 * d2 > 0.3f && ndef->get(c).is_ground_content) {\r\n\t\t\t\t.............\r\n\t\t\t} else if (c == biome->c_filler || c == biome->c_stone) {\r\n\t\t\t\tif (tunnel_air_above) {\r\n\t\t\t\t\t..............\r\n\t\t\t\t}\r\n\r\n\t\t\t\ttunnel_air_above = false;\r\n\t\t\t\tunderground = true;\r\n\t\t\t} else {\r\n\t\t\t\ttunnel_air_above = false;\r\n\t\t\t}\r\n```"}}