{"action":"opened","number":971,"pull_request":{"url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971","id":60632677,"html_url":"https://github.com/KSP-RO/RealismOverhaul/pull/971","diff_url":"https://github.com/KSP-RO/RealismOverhaul/pull/971.diff","patch_url":"https://github.com/KSP-RO/RealismOverhaul/pull/971.patch","issue_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/971","number":971,"state":"open","locked":false,"title":"Fix root rescale bug in ROMini + helper script.","user":{"login":"jmrd98","id":3410751,"avatar_url":"https://avatars.githubusercontent.com/u/3410751?v=3","gravatar_id":"","url":"https://api.github.com/users/jmrd98","html_url":"https://github.com/jmrd98","followers_url":"https://api.github.com/users/jmrd98/followers","following_url":"https://api.github.com/users/jmrd98/following{/other_user}","gists_url":"https://api.github.com/users/jmrd98/gists{/gist_id}","starred_url":"https://api.github.com/users/jmrd98/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmrd98/subscriptions","organizations_url":"https://api.github.com/users/jmrd98/orgs","repos_url":"https://api.github.com/users/jmrd98/repos","events_url":"https://api.github.com/users/jmrd98/events{/privacy}","received_events_url":"https://api.github.com/users/jmrd98/received_events","type":"User","site_admin":false},"body":"Hello!\r\nThanks to an unexpected snow day, I finally managed to do as I have been threatening to, which is to clean up and submit this code for a PR!\r\n\r\nSeveral things to note: \r\n\r\n- The \"fix\" here is to uncomment some existing code which was said to have failed in 1.0.4. It did indeed fail, such that while the models were rescaled correctly, the attach nodes were not. This is somewhat less then satisfactory from a gameplay standpoint.\r\n\r\n- By using this method, we avoid entirely bug where a root part scaled with rescaleFactor will revert to its original size on load/quickload.\r\n\r\n- This brings us to part two: The python script. This is a reimplemented shell script I posted on the forums a while ago. This script walks through a directory tree, opens each .cfg file found and does a regex match for any line starting with \"node\". We collect that into an internal list, remove duplicates, and sort it, yielding a list of every unique type of node_* in your Gamedata folder. We then feed that into a template for a MM script to rescale the nodes based on a chosen rescaleFactor. \r\nIt sounds complicated, but trust me, it works *very* well.\r\n\r\nThe usage is simple, simply run it from Gamedata/ (or KSP root, it doesn't care), and specify an output file for your generated MM config. Example: ./generateNodes.py Gamedata/zROMini/scaledNodes.cfg\r\nIt was written in python 2.7, but I honestly can't think of anything that would goof in python 3. (No promises, but let me know if it does, and i'll look into it.)\r\nIt should be perfectly content to run under windows thanks to the magic of python, as well!\r\n\r\n- Of further note: I have spent a fair amount of time going back and forth with procedural fairings vs rescaling. At the top of ROMini you will find a section of code intended to bring PF into line, but it seems to fail at this time. No errors result, just no... results result. I have left it in so that someone else may either find my silly mistake, or else please feel free to cut it from the patch if it is out of scope for this project. \r\nHowever, the main rescaling code explicitly excludes PF in order to make them work at all. The result is a game which has all it's dimensions seemlessly scaled by 1.6 in this implementation, but for the PF numbers. (They are unscaled, but working correctly in all other aspects.)\r\n\r\n- ... There is no last bullet point. \r\nThe code was a GREAT help to build off of, i'm sure I would be still on the starting blocks rescaling if I started from scratch. It seems quite stable in my testing. Balance wise, the only thing I would try to look at is the SRBs, but that is out of scope for this PR.\r\n\r\nI will leave it at that, as this note has gone on far too long! Licensing! The python script is for all practical purposes public domain, but CC-BY-4.0 as indicated in the guidelines works as well too.\r\n\r\nThanks all!","created_at":"2016-02-25T06:39:13Z","updated_at":"2016-02-25T06:39:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971/commits","review_comments_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971/comments","review_comment_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/comments{/number}","comments_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/971/comments","statuses_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/statuses/32b022b054bf1e4e78041a2a98df56d3370d970b","head":{"label":"jmrd98:master","ref":"master","sha":"32b022b054bf1e4e78041a2a98df56d3370d970b","user":{"login":"jmrd98","id":3410751,"avatar_url":"https://avatars.githubusercontent.com/u/3410751?v=3","gravatar_id":"","url":"https://api.github.com/users/jmrd98","html_url":"https://github.com/jmrd98","followers_url":"https://api.github.com/users/jmrd98/followers","following_url":"https://api.github.com/users/jmrd98/following{/other_user}","gists_url":"https://api.github.com/users/jmrd98/gists{/gist_id}","starred_url":"https://api.github.com/users/jmrd98/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmrd98/subscriptions","organizations_url":"https://api.github.com/users/jmrd98/orgs","repos_url":"https://api.github.com/users/jmrd98/repos","events_url":"https://api.github.com/users/jmrd98/events{/privacy}","received_events_url":"https://api.github.com/users/jmrd98/received_events","type":"User","site_admin":false},"repo":{"id":52484851,"name":"RealismOverhaul","full_name":"jmrd98/RealismOverhaul","owner":{"login":"jmrd98","id":3410751,"avatar_url":"https://avatars.githubusercontent.com/u/3410751?v=3","gravatar_id":"","url":"https://api.github.com/users/jmrd98","html_url":"https://github.com/jmrd98","followers_url":"https://api.github.com/users/jmrd98/followers","following_url":"https://api.github.com/users/jmrd98/following{/other_user}","gists_url":"https://api.github.com/users/jmrd98/gists{/gist_id}","starred_url":"https://api.github.com/users/jmrd98/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jmrd98/subscriptions","organizations_url":"https://api.github.com/users/jmrd98/orgs","repos_url":"https://api.github.com/users/jmrd98/repos","events_url":"https://api.github.com/users/jmrd98/events{/privacy}","received_events_url":"https://api.github.com/users/jmrd98/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jmrd98/RealismOverhaul","description":"Multipatch to KSP to give things realistic stats and sizes","fork":true,"url":"https://api.github.com/repos/jmrd98/RealismOverhaul","forks_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/forks","keys_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/teams","hooks_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/hooks","issue_events_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/issues/events{/number}","events_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/events","assignees_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/assignees{/user}","branches_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/branches{/branch}","tags_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/tags","blobs_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/git/refs{/sha}","trees_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/statuses/{sha}","languages_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/languages","stargazers_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/stargazers","contributors_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/contributors","subscribers_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/subscribers","subscription_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/subscription","commits_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/commits{/sha}","git_commits_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/git/commits{/sha}","comments_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/comments{/number}","issue_comment_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/issues/comments{/number}","contents_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/contents/{+path}","compare_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/merges","archive_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/downloads","issues_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/issues{/number}","pulls_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/pulls{/number}","milestones_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/milestones{/number}","notifications_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/labels{/name}","releases_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/releases{/id}","deployments_url":"https://api.github.com/repos/jmrd98/RealismOverhaul/deployments","created_at":"2016-02-25T00:34:30Z","updated_at":"2016-02-25T00:34:38Z","pushed_at":"2016-02-25T06:13:47Z","git_url":"git://github.com/jmrd98/RealismOverhaul.git","ssh_url":"git@github.com:jmrd98/RealismOverhaul.git","clone_url":"https://github.com/jmrd98/RealismOverhaul.git","svn_url":"https://github.com/jmrd98/RealismOverhaul","homepage":null,"size":32164,"stargazers_count":0,"watchers_count":0,"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":0,"default_branch":"master"}},"base":{"label":"KSP-RO:master","ref":"master","sha":"49855ab850763766688ccbed95c53ad634550cda","user":{"login":"KSP-RO","id":9563848,"avatar_url":"https://avatars.githubusercontent.com/u/9563848?v=3","gravatar_id":"","url":"https://api.github.com/users/KSP-RO","html_url":"https://github.com/KSP-RO","followers_url":"https://api.github.com/users/KSP-RO/followers","following_url":"https://api.github.com/users/KSP-RO/following{/other_user}","gists_url":"https://api.github.com/users/KSP-RO/gists{/gist_id}","starred_url":"https://api.github.com/users/KSP-RO/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KSP-RO/subscriptions","organizations_url":"https://api.github.com/users/KSP-RO/orgs","repos_url":"https://api.github.com/users/KSP-RO/repos","events_url":"https://api.github.com/users/KSP-RO/events{/privacy}","received_events_url":"https://api.github.com/users/KSP-RO/received_events","type":"Organization","site_admin":false},"repo":{"id":15660461,"name":"RealismOverhaul","full_name":"KSP-RO/RealismOverhaul","owner":{"login":"KSP-RO","id":9563848,"avatar_url":"https://avatars.githubusercontent.com/u/9563848?v=3","gravatar_id":"","url":"https://api.github.com/users/KSP-RO","html_url":"https://github.com/KSP-RO","followers_url":"https://api.github.com/users/KSP-RO/followers","following_url":"https://api.github.com/users/KSP-RO/following{/other_user}","gists_url":"https://api.github.com/users/KSP-RO/gists{/gist_id}","starred_url":"https://api.github.com/users/KSP-RO/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/KSP-RO/subscriptions","organizations_url":"https://api.github.com/users/KSP-RO/orgs","repos_url":"https://api.github.com/users/KSP-RO/repos","events_url":"https://api.github.com/users/KSP-RO/events{/privacy}","received_events_url":"https://api.github.com/users/KSP-RO/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/KSP-RO/RealismOverhaul","description":"Multipatch to KSP to give things realistic stats and sizes","fork":false,"url":"https://api.github.com/repos/KSP-RO/RealismOverhaul","forks_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/forks","keys_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/keys{/key_id}","collaborators_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/teams","hooks_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/hooks","issue_events_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/events{/number}","events_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/events","assignees_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/assignees{/user}","branches_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/branches{/branch}","tags_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/tags","blobs_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/git/refs{/sha}","trees_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/git/trees{/sha}","statuses_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/statuses/{sha}","languages_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/languages","stargazers_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/stargazers","contributors_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/contributors","subscribers_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/subscribers","subscription_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/subscription","commits_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/commits{/sha}","git_commits_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/git/commits{/sha}","comments_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/comments{/number}","issue_comment_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/comments{/number}","contents_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/contents/{+path}","compare_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/compare/{base}...{head}","merges_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/merges","archive_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/downloads","issues_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues{/number}","pulls_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls{/number}","milestones_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/milestones{/number}","notifications_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/labels{/name}","releases_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/releases{/id}","deployments_url":"https://api.github.com/repos/KSP-RO/RealismOverhaul/deployments","created_at":"2014-01-05T23:02:02Z","updated_at":"2016-02-04T10:41:08Z","pushed_at":"2016-02-25T06:33:44Z","git_url":"git://github.com/KSP-RO/RealismOverhaul.git","ssh_url":"git@github.com:KSP-RO/RealismOverhaul.git","clone_url":"https://github.com/KSP-RO/RealismOverhaul.git","svn_url":"https://github.com/KSP-RO/RealismOverhaul","homepage":null,"size":34266,"stargazers_count":54,"watchers_count":54,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":82,"mirror_url":null,"open_issues_count":67,"forks":82,"open_issues":67,"watchers":54,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971"},"html":{"href":"https://github.com/KSP-RO/RealismOverhaul/pull/971"},"issue":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/971"},"comments":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/issues/971/comments"},"review_comments":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971/comments"},"review_comment":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/pulls/971/commits"},"statuses":{"href":"https://api.github.com/repos/KSP-RO/RealismOverhaul/statuses/32b022b054bf1e4e78041a2a98df56d3370d970b"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":4,"additions":168,"deletions":49,"changed_files":2}}