{"action":"created","comment":{"url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/comments/68700343","id":68700343,"diff_hunk":"@@ -0,0 +1,156 @@\n+package xyz.openmodloader.dictionary;\n+\n+import net.minecraft.block.Block;\n+import net.minecraft.inventory.InventoryCrafting;\n+import net.minecraft.item.Item;\n+import net.minecraft.item.ItemStack;\n+import net.minecraft.item.crafting.IRecipe;\n+import net.minecraft.world.World;\n+\n+import java.util.*;\n+\n+public class ShapedMaterialRecipe implements IRecipe {\n+    private static final Set<ItemStackWrapper> EMPTY_SINGLETON = Collections.singleton(new ItemStackWrapper());\n+    private final List<Set<ItemStackWrapper>> items;\n+    private final ItemStack output;\n+    private final int size;\n+    private int width;\n+    private int height;\n+\n+    public ShapedMaterialRecipe(ItemStack output, Object... input) {\n+        this.output = output;\n+\n+        int index = 0;\n+        width = 0;\n+        height = 0;\n+        StringBuilder sb = new StringBuilder();\n+\n+        if (input[index] instanceof String[]) {\n+            for (String s : (String[]) input[index++]) {\n+                ++height;\n+                width = s.length();\n+                sb.append(s);\n+            }\n+        } else {\n+            while (input[index] instanceof String) {\n+                String s = (String) input[index++];\n+                ++height;\n+                width = s.length();\n+                sb.append(s);\n+            }\n+        }\n+\n+        String shape = sb.toString();\n+\n+        HashMap<Character, Set<ItemStackWrapper>> map = new HashMap<>();\n+\n+        while (index < input.length) {","path":"src/main/java/xyz/openmodloader/dictionary/ShapedMaterialRecipe.java","position":47,"original_position":47,"commit_id":"c0518b8daf32789eca0fe151371ea5235acf75a1","original_commit_id":"c0518b8daf32789eca0fe151371ea5235acf75a1","user":{"login":"phase","id":7685133,"avatar_url":"https://avatars.githubusercontent.com/u/7685133?v=3","gravatar_id":"","url":"https://api.github.com/users/phase","html_url":"https://github.com/phase","followers_url":"https://api.github.com/users/phase/followers","following_url":"https://api.github.com/users/phase/following{/other_user}","gists_url":"https://api.github.com/users/phase/gists{/gist_id}","starred_url":"https://api.github.com/users/phase/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phase/subscriptions","organizations_url":"https://api.github.com/users/phase/orgs","repos_url":"https://api.github.com/users/phase/repos","events_url":"https://api.github.com/users/phase/events{/privacy}","received_events_url":"https://api.github.com/users/phase/received_events","type":"User","site_admin":false},"body":"Moving some of this out of the constructor would be nice. 60 lines is a little much.","created_at":"2016-06-28T05:44:49Z","updated_at":"2016-06-28T05:44:49Z","html_url":"https://github.com/OpenModLoader/OpenModLoader/pull/60#discussion_r68700343","pull_request_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60","_links":{"self":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/comments/68700343"},"html":{"href":"https://github.com/OpenModLoader/OpenModLoader/pull/60#discussion_r68700343"},"pull_request":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60"}}},"pull_request":{"url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60","id":75418754,"html_url":"https://github.com/OpenModLoader/OpenModLoader/pull/60","diff_url":"https://github.com/OpenModLoader/OpenModLoader/pull/60.diff","patch_url":"https://github.com/OpenModLoader/OpenModLoader/pull/60.patch","issue_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/60","number":60,"state":"open","locked":false,"title":"Rewrite material recipes.","user":{"login":"MrIbby","id":7306503,"avatar_url":"https://avatars.githubusercontent.com/u/7306503?v=3","gravatar_id":"","url":"https://api.github.com/users/MrIbby","html_url":"https://github.com/MrIbby","followers_url":"https://api.github.com/users/MrIbby/followers","following_url":"https://api.github.com/users/MrIbby/following{/other_user}","gists_url":"https://api.github.com/users/MrIbby/gists{/gist_id}","starred_url":"https://api.github.com/users/MrIbby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrIbby/subscriptions","organizations_url":"https://api.github.com/users/MrIbby/orgs","repos_url":"https://api.github.com/users/MrIbby/repos","events_url":"https://api.github.com/users/MrIbby/events{/privacy}","received_events_url":"https://api.github.com/users/MrIbby/received_events","type":"User","site_admin":false},"body":" Add Dictionaries class to prevent deadlock.\r\n\r\nTODO: Fix bug regarding ItemStacks registered with wildcard metadata","created_at":"2016-06-28T05:03:54Z","updated_at":"2016-06-28T05:44:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"32539c093fbbab48d594b9ed1a2f94f4229bb95a","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60/commits","review_comments_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60/comments","review_comment_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/60/comments","statuses_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/statuses/c0518b8daf32789eca0fe151371ea5235acf75a1","head":{"label":"MrIbby:dictionary","ref":"dictionary","sha":"c0518b8daf32789eca0fe151371ea5235acf75a1","user":{"login":"MrIbby","id":7306503,"avatar_url":"https://avatars.githubusercontent.com/u/7306503?v=3","gravatar_id":"","url":"https://api.github.com/users/MrIbby","html_url":"https://github.com/MrIbby","followers_url":"https://api.github.com/users/MrIbby/followers","following_url":"https://api.github.com/users/MrIbby/following{/other_user}","gists_url":"https://api.github.com/users/MrIbby/gists{/gist_id}","starred_url":"https://api.github.com/users/MrIbby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrIbby/subscriptions","organizations_url":"https://api.github.com/users/MrIbby/orgs","repos_url":"https://api.github.com/users/MrIbby/repos","events_url":"https://api.github.com/users/MrIbby/events{/privacy}","received_events_url":"https://api.github.com/users/MrIbby/received_events","type":"User","site_admin":false},"repo":{"id":62027844,"name":"OpenModLoader","full_name":"MrIbby/OpenModLoader","owner":{"login":"MrIbby","id":7306503,"avatar_url":"https://avatars.githubusercontent.com/u/7306503?v=3","gravatar_id":"","url":"https://api.github.com/users/MrIbby","html_url":"https://github.com/MrIbby","followers_url":"https://api.github.com/users/MrIbby/followers","following_url":"https://api.github.com/users/MrIbby/following{/other_user}","gists_url":"https://api.github.com/users/MrIbby/gists{/gist_id}","starred_url":"https://api.github.com/users/MrIbby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MrIbby/subscriptions","organizations_url":"https://api.github.com/users/MrIbby/orgs","repos_url":"https://api.github.com/users/MrIbby/repos","events_url":"https://api.github.com/users/MrIbby/events{/privacy}","received_events_url":"https://api.github.com/users/MrIbby/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/MrIbby/OpenModLoader","description":"A next gen minecraft mod loader for minecraft 1.10 and above","fork":true,"url":"https://api.github.com/repos/MrIbby/OpenModLoader","forks_url":"https://api.github.com/repos/MrIbby/OpenModLoader/forks","keys_url":"https://api.github.com/repos/MrIbby/OpenModLoader/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MrIbby/OpenModLoader/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MrIbby/OpenModLoader/teams","hooks_url":"https://api.github.com/repos/MrIbby/OpenModLoader/hooks","issue_events_url":"https://api.github.com/repos/MrIbby/OpenModLoader/issues/events{/number}","events_url":"https://api.github.com/repos/MrIbby/OpenModLoader/events","assignees_url":"https://api.github.com/repos/MrIbby/OpenModLoader/assignees{/user}","branches_url":"https://api.github.com/repos/MrIbby/OpenModLoader/branches{/branch}","tags_url":"https://api.github.com/repos/MrIbby/OpenModLoader/tags","blobs_url":"https://api.github.com/repos/MrIbby/OpenModLoader/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MrIbby/OpenModLoader/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MrIbby/OpenModLoader/git/refs{/sha}","trees_url":"https://api.github.com/repos/MrIbby/OpenModLoader/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MrIbby/OpenModLoader/statuses/{sha}","languages_url":"https://api.github.com/repos/MrIbby/OpenModLoader/languages","stargazers_url":"https://api.github.com/repos/MrIbby/OpenModLoader/stargazers","contributors_url":"https://api.github.com/repos/MrIbby/OpenModLoader/contributors","subscribers_url":"https://api.github.com/repos/MrIbby/OpenModLoader/subscribers","subscription_url":"https://api.github.com/repos/MrIbby/OpenModLoader/subscription","commits_url":"https://api.github.com/repos/MrIbby/OpenModLoader/commits{/sha}","git_commits_url":"https://api.github.com/repos/MrIbby/OpenModLoader/git/commits{/sha}","comments_url":"https://api.github.com/repos/MrIbby/OpenModLoader/comments{/number}","issue_comment_url":"https://api.github.com/repos/MrIbby/OpenModLoader/issues/comments{/number}","contents_url":"https://api.github.com/repos/MrIbby/OpenModLoader/contents/{+path}","compare_url":"https://api.github.com/repos/MrIbby/OpenModLoader/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MrIbby/OpenModLoader/merges","archive_url":"https://api.github.com/repos/MrIbby/OpenModLoader/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MrIbby/OpenModLoader/downloads","issues_url":"https://api.github.com/repos/MrIbby/OpenModLoader/issues{/number}","pulls_url":"https://api.github.com/repos/MrIbby/OpenModLoader/pulls{/number}","milestones_url":"https://api.github.com/repos/MrIbby/OpenModLoader/milestones{/number}","notifications_url":"https://api.github.com/repos/MrIbby/OpenModLoader/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MrIbby/OpenModLoader/labels{/name}","releases_url":"https://api.github.com/repos/MrIbby/OpenModLoader/releases{/id}","deployments_url":"https://api.github.com/repos/MrIbby/OpenModLoader/deployments","created_at":"2016-06-27T05:31:37Z","updated_at":"2016-06-27T05:31:38Z","pushed_at":"2016-06-28T05:02:19Z","git_url":"git://github.com/MrIbby/OpenModLoader.git","ssh_url":"git@github.com:MrIbby/OpenModLoader.git","clone_url":"https://github.com/MrIbby/OpenModLoader.git","svn_url":"https://github.com/MrIbby/OpenModLoader","homepage":"http://openmodloader.xyz/","size":2823,"stargazers_count":0,"watchers_count":0,"language":"Java","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":"OpenModLoader:master","ref":"master","sha":"de3331b8a00c0ae03b419ede64658f4f29be94db","user":{"login":"OpenModLoader","id":20051910,"avatar_url":"https://avatars.githubusercontent.com/u/20051910?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenModLoader","html_url":"https://github.com/OpenModLoader","followers_url":"https://api.github.com/users/OpenModLoader/followers","following_url":"https://api.github.com/users/OpenModLoader/following{/other_user}","gists_url":"https://api.github.com/users/OpenModLoader/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenModLoader/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenModLoader/subscriptions","organizations_url":"https://api.github.com/users/OpenModLoader/orgs","repos_url":"https://api.github.com/users/OpenModLoader/repos","events_url":"https://api.github.com/users/OpenModLoader/events{/privacy}","received_events_url":"https://api.github.com/users/OpenModLoader/received_events","type":"Organization","site_admin":false},"repo":{"id":61618132,"name":"OpenModLoader","full_name":"OpenModLoader/OpenModLoader","owner":{"login":"OpenModLoader","id":20051910,"avatar_url":"https://avatars.githubusercontent.com/u/20051910?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenModLoader","html_url":"https://github.com/OpenModLoader","followers_url":"https://api.github.com/users/OpenModLoader/followers","following_url":"https://api.github.com/users/OpenModLoader/following{/other_user}","gists_url":"https://api.github.com/users/OpenModLoader/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenModLoader/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenModLoader/subscriptions","organizations_url":"https://api.github.com/users/OpenModLoader/orgs","repos_url":"https://api.github.com/users/OpenModLoader/repos","events_url":"https://api.github.com/users/OpenModLoader/events{/privacy}","received_events_url":"https://api.github.com/users/OpenModLoader/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenModLoader/OpenModLoader","description":"A next gen minecraft mod loader for minecraft 1.10 and above","fork":false,"url":"https://api.github.com/repos/OpenModLoader/OpenModLoader","forks_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/forks","keys_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/teams","hooks_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/hooks","issue_events_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/events{/number}","events_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/events","assignees_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/assignees{/user}","branches_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/branches{/branch}","tags_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/tags","blobs_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/languages","stargazers_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/stargazers","contributors_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/contributors","subscribers_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/subscribers","subscription_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/subscription","commits_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/contents/{+path}","compare_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/merges","archive_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/downloads","issues_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues{/number}","pulls_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/labels{/name}","releases_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/releases{/id}","deployments_url":"https://api.github.com/repos/OpenModLoader/OpenModLoader/deployments","created_at":"2016-06-21T08:53:39Z","updated_at":"2016-06-27T16:24:25Z","pushed_at":"2016-06-28T05:03:54Z","git_url":"git://github.com/OpenModLoader/OpenModLoader.git","ssh_url":"git@github.com:OpenModLoader/OpenModLoader.git","clone_url":"https://github.com/OpenModLoader/OpenModLoader.git","svn_url":"https://github.com/OpenModLoader/OpenModLoader","homepage":"http://openmodloader.xyz/","size":3058,"stargazers_count":42,"watchers_count":42,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":13,"mirror_url":null,"open_issues_count":11,"forks":13,"open_issues":11,"watchers":42,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60"},"html":{"href":"https://github.com/OpenModLoader/OpenModLoader/pull/60"},"issue":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/60"},"comments":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/issues/60/comments"},"review_comments":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/pulls/60/commits"},"statuses":{"href":"https://api.github.com/repos/OpenModLoader/OpenModLoader/statuses/c0518b8daf32789eca0fe151371ea5235acf75a1"}}}}
{"actor":{"display_login":"phase"}}