{"action":"created","comment":{"url":"https://api.github.com/repos/cuberite/cuberite/pulls/comments/41743223","id":41743223,"diff_hunk":"@@ -0,0 +1,112 @@\n+\n+\n+#include \"Globals.h\"\n+\n+#include \"IncrementalRedstoneSimulator.h\"\n+#include \"RedstoneHandlerFactory.h\"\n+#include \"Chunk.h\"\n+\n+\n+\n+\n+\n+void cIncrementalRedstoneSimulator::SimulateChunk(std::chrono::milliseconds a_Dt, int a_ChunkX, int a_ChunkZ, cChunk * a_Chunk)\n+{\n+\treturn;\n+}\n+\n+\n+\n+\n+\n+void cIncrementalRedstoneSimulator::Simulate(float a_dt)\n+{\n+\tfor (auto & DelayInfo : m_Data.m_MechanismDelays)\n+\t{\n+\t\tstd::get<1>(DelayInfo.second)++;","path":"src/Simulator/IncrementalRedstoneSimulator/IncrementalRedstoneSimulator.cpp","position":26,"original_position":26,"commit_id":"cd0e330ff6deab372b3adc4e4c06ce1723e1e9b7","original_commit_id":"cd0e330ff6deab372b3adc4e4c06ce1723e1e9b7","user":{"login":"worktycho","id":2102806,"avatar_url":"https://avatars.githubusercontent.com/u/2102806?v=3","gravatar_id":"","url":"https://api.github.com/users/worktycho","html_url":"https://github.com/worktycho","followers_url":"https://api.github.com/users/worktycho/followers","following_url":"https://api.github.com/users/worktycho/following{/other_user}","gists_url":"https://api.github.com/users/worktycho/gists{/gist_id}","starred_url":"https://api.github.com/users/worktycho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/worktycho/subscriptions","organizations_url":"https://api.github.com/users/worktycho/orgs","repos_url":"https://api.github.com/users/worktycho/repos","events_url":"https://api.github.com/users/worktycho/events{/privacy}","received_events_url":"https://api.github.com/users/worktycho/received_events","type":"User","site_admin":false},"body":"Also, if you change elapsed ticks into ticks left and count down, you can get rid of the Delayticks field.","created_at":"2015-10-12T10:26:17Z","updated_at":"2015-10-12T10:26:17Z","html_url":"https://github.com/cuberite/cuberite/pull/2542#discussion_r41743223","pull_request_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2542","_links":{"self":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/comments/41743223"},"html":{"href":"https://github.com/cuberite/cuberite/pull/2542#discussion_r41743223"},"pull_request":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2542"}}},"pull_request":{"url":"https://api.github.com/repos/cuberite/cuberite/pulls/2542","id":47356739,"html_url":"https://github.com/cuberite/cuberite/pull/2542","diff_url":"https://github.com/cuberite/cuberite/pull/2542.diff","patch_url":"https://github.com/cuberite/cuberite/pull/2542.patch","issue_url":"https://api.github.com/repos/cuberite/cuberite/issues/2542","number":2542,"state":"open","locked":false,"title":"Reorganised the redstone simulator","user":{"login":"tigerw","id":2939130,"avatar_url":"https://avatars.githubusercontent.com/u/2939130?v=3","gravatar_id":"","url":"https://api.github.com/users/tigerw","html_url":"https://github.com/tigerw","followers_url":"https://api.github.com/users/tigerw/followers","following_url":"https://api.github.com/users/tigerw/following{/other_user}","gists_url":"https://api.github.com/users/tigerw/gists{/gist_id}","starred_url":"https://api.github.com/users/tigerw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tigerw/subscriptions","organizations_url":"https://api.github.com/users/tigerw/orgs","repos_url":"https://api.github.com/users/tigerw/repos","events_url":"https://api.github.com/users/tigerw/events{/privacy}","received_events_url":"https://api.github.com/users/tigerw/received_events","type":"User","site_admin":false},"body":"-> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan!\r\n\r\n* Uses classes and inheritance now\r\n* Speed should be improved\r\n\r\nOriginal PR: #2313\r\nRefactor request reference: #2144 \r\n\r\nFixes #1416 (it mentioned the redstone simulator as its target)\r\n*Nearly* fixes #1589, but not quite because of bugs\r\nFixes #2234\r\nFixes #2235\r\n\r\nSee Tycho? I *did* keep that promise of refactoring :)\r\nAnd admittedly, this new structure is generally better.\r\n","created_at":"2015-10-10T23:57:24Z","updated_at":"2015-10-12T10:26:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9c0a625205b274d273c106f5d786e791d7a5aad6","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2542/commits","review_comments_url":"https://api.github.com/repos/cuberite/cuberite/pulls/2542/comments","review_comment_url":"https://api.github.com/repos/cuberite/cuberite/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cuberite/cuberite/issues/2542/comments","statuses_url":"https://api.github.com/repos/cuberite/cuberite/statuses/cd0e330ff6deab372b3adc4e4c06ce1723e1e9b7","head":{"label":"Haxi52:pinkstone","ref":"pinkstone","sha":"cd0e330ff6deab372b3adc4e4c06ce1723e1e9b7","user":{"login":"Haxi52","id":10181722,"avatar_url":"https://avatars.githubusercontent.com/u/10181722?v=3","gravatar_id":"","url":"https://api.github.com/users/Haxi52","html_url":"https://github.com/Haxi52","followers_url":"https://api.github.com/users/Haxi52/followers","following_url":"https://api.github.com/users/Haxi52/following{/other_user}","gists_url":"https://api.github.com/users/Haxi52/gists{/gist_id}","starred_url":"https://api.github.com/users/Haxi52/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Haxi52/subscriptions","organizations_url":"https://api.github.com/users/Haxi52/orgs","repos_url":"https://api.github.com/users/Haxi52/repos","events_url":"https://api.github.com/users/Haxi52/events{/privacy}","received_events_url":"https://api.github.com/users/Haxi52/received_events","type":"User","site_admin":false},"repo":{"id":37829214,"name":"cuberite","full_name":"Haxi52/cuberite","owner":{"login":"Haxi52","id":10181722,"avatar_url":"https://avatars.githubusercontent.com/u/10181722?v=3","gravatar_id":"","url":"https://api.github.com/users/Haxi52","html_url":"https://github.com/Haxi52","followers_url":"https://api.github.com/users/Haxi52/followers","following_url":"https://api.github.com/users/Haxi52/following{/other_user}","gists_url":"https://api.github.com/users/Haxi52/gists{/gist_id}","starred_url":"https://api.github.com/users/Haxi52/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Haxi52/subscriptions","organizations_url":"https://api.github.com/users/Haxi52/orgs","repos_url":"https://api.github.com/users/Haxi52/repos","events_url":"https://api.github.com/users/Haxi52/events{/privacy}","received_events_url":"https://api.github.com/users/Haxi52/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Haxi52/cuberite","description":"A performant C++ Minecraft compatible game server","fork":true,"url":"https://api.github.com/repos/Haxi52/cuberite","forks_url":"https://api.github.com/repos/Haxi52/cuberite/forks","keys_url":"https://api.github.com/repos/Haxi52/cuberite/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Haxi52/cuberite/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Haxi52/cuberite/teams","hooks_url":"https://api.github.com/repos/Haxi52/cuberite/hooks","issue_events_url":"https://api.github.com/repos/Haxi52/cuberite/issues/events{/number}","events_url":"https://api.github.com/repos/Haxi52/cuberite/events","assignees_url":"https://api.github.com/repos/Haxi52/cuberite/assignees{/user}","branches_url":"https://api.github.com/repos/Haxi52/cuberite/branches{/branch}","tags_url":"https://api.github.com/repos/Haxi52/cuberite/tags","blobs_url":"https://api.github.com/repos/Haxi52/cuberite/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Haxi52/cuberite/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Haxi52/cuberite/git/refs{/sha}","trees_url":"https://api.github.com/repos/Haxi52/cuberite/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Haxi52/cuberite/statuses/{sha}","languages_url":"https://api.github.com/repos/Haxi52/cuberite/languages","stargazers_url":"https://api.github.com/repos/Haxi52/cuberite/stargazers","contributors_url":"https://api.github.com/repos/Haxi52/cuberite/contributors","subscribers_url":"https://api.github.com/repos/Haxi52/cuberite/subscribers","subscription_url":"https://api.github.com/repos/Haxi52/cuberite/subscription","commits_url":"https://api.github.com/repos/Haxi52/cuberite/commits{/sha}","git_commits_url":"https://api.github.com/repos/Haxi52/cuberite/git/commits{/sha}","comments_url":"https://api.github.com/repos/Haxi52/cuberite/comments{/number}","issue_comment_url":"https://api.github.com/repos/Haxi52/cuberite/issues/comments{/number}","contents_url":"https://api.github.com/repos/Haxi52/cuberite/contents/{+path}","compare_url":"https://api.github.com/repos/Haxi52/cuberite/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Haxi52/cuberite/merges","archive_url":"https://api.github.com/repos/Haxi52/cuberite/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Haxi52/cuberite/downloads","issues_url":"https://api.github.com/repos/Haxi52/cuberite/issues{/number}","pulls_url":"https://api.github.com/repos/Haxi52/cuberite/pulls{/number}","milestones_url":"https://api.github.com/repos/Haxi52/cuberite/milestones{/number}","notifications_url":"https://api.github.com/repos/Haxi52/cuberite/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Haxi52/cuberite/labels{/name}","releases_url":"https://api.github.com/repos/Haxi52/cuberite/releases{/id}","created_at":"2015-06-21T22:47:11Z","updated_at":"2015-06-21T22:47:15Z","pushed_at":"2015-10-11T21:22:46Z","git_url":"git://github.com/Haxi52/cuberite.git","ssh_url":"git@github.com:Haxi52/cuberite.git","clone_url":"https://github.com/Haxi52/cuberite.git","svn_url":"https://github.com/Haxi52/cuberite","homepage":"http://cuberite.org","size":77955,"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":"cuberite:master","ref":"master","sha":"f6cd03db536ce0765631622f4a43c5dab8891ba8","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-10-11T12:34:44Z","pushed_at":"2015-10-12T09:17:56Z","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":169382,"stargazers_count":737,"watchers_count":737,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":237,"mirror_url":null,"open_issues_count":398,"forks":237,"open_issues":398,"watchers":737,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2542"},"html":{"href":"https://github.com/cuberite/cuberite/pull/2542"},"issue":{"href":"https://api.github.com/repos/cuberite/cuberite/issues/2542"},"comments":{"href":"https://api.github.com/repos/cuberite/cuberite/issues/2542/comments"},"review_comments":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2542/comments"},"review_comment":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cuberite/cuberite/pulls/2542/commits"},"statuses":{"href":"https://api.github.com/repos/cuberite/cuberite/statuses/cd0e330ff6deab372b3adc4e4c06ce1723e1e9b7"}}}}