{"action":"created","comment":{"url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/comments/66350233","id":66350233,"diff_hunk":"@@ -0,0 +1,144 @@\n+$(document).ready(function(){\n+  var num=1,\n+      aleat,\n+      btnClicked,\n+      typeofGame,\n+      allColors=['green','red','blue','yellow'],\n+      rightSequence=[],\n+      personSequence=[],\n+      order=0,\n+      storeColInf ={\n+        \"red\": 1,\n+        \"green\": 2,\n+        \"blue\": 3,\n+        \"yellow\": 4   \n+      };\n+\n+  changeColorDisplay('none');\n+  setBtnFun('disabled');\n+\n+  $('.starter').on(\"click\", function(){\n+    typeofGame = $(this).attr('id')\n+    if (typeofGame=='strict'){\n+      $(\"#strictActive\").addClass('strictActive');\n+    }\n+    setBtnFun('disabled');\n+    continueGame();\n+  });  \n+\n+  $(\".color\").on(\"click\", function(){\n+    var idClicked = $(this).attr('id');\n+    order++;\n+    lightSound(''+idClicked+'');\n+    personSequence.push(idClicked);\n+    verify(''+idClicked+'');  \n+  });\n+\n+  $(\"#number\").on(\"errou\", function(event, callback){\n+    $(\"#number\").html(\"--\");\n+    setTimeout(function(){\n+      callback();\n+      $(\"#number\").html(num);\n+    },1500);\n+  });\n+\n+  $('.offBtn').on('click', function(){\n+    $(\".offBtn\").toggleClass(\"onBtn\");\n+    if ($('.offBtn').hasClass('onBtn')){ //se tiver on\n+      setBtnFun(false);\n+    } else{\n+      changeColorDisplay('none');\n+      setBtnFun('disabled')\n+      reset('all');\n+      $(\"#number\").html(' ');\n+      $(\"#strictActive\").removeClass('strictActive');\n+    }\n+  });\n+\n+  function playAudio (color,number, callback){\n+    return  new Howl({\n+      urls: ['https://s3.amazonaws.com/freecodecamp/simonSound'+number+'.mp3'],\n+      volume: 0.5,\n+      onend: function() {\n+        $(\"#\"+color).removeClass(\"\"+color+'active');\n+        if (callback){\n+          callback();\n+        }\n+      }\n+    });  \n+  }\n+\n+  function continueGame(){\n+    aleat=Math.floor((Math.random() * 4));\n+    rightSequence.push(allColors[aleat]);\n+    changeColorDisplay('none');\n+    doit();\n+  }\n+\n+  function doit(){\n+    $(\"#number\").html(num);\n+    var counter=0; //define um contador para cada chamada;\n+    for (var i in rightSequence){\n+      var color=rightSequence[i];\n+      timing(lightSound, 800 * ++counter, color);","path":"script.js","position":83,"original_position":83,"commit_id":"18f7da8b827d811e688d2b5e53c8ed8019ee2781","original_commit_id":"18f7da8b827d811e688d2b5e53c8ed8019ee2781","user":{"login":"halissonvit","id":379034,"avatar_url":"https://avatars.githubusercontent.com/u/379034?v=3","gravatar_id":"","url":"https://api.github.com/users/halissonvit","html_url":"https://github.com/halissonvit","followers_url":"https://api.github.com/users/halissonvit/followers","following_url":"https://api.github.com/users/halissonvit/following{/other_user}","gists_url":"https://api.github.com/users/halissonvit/gists{/gist_id}","starred_url":"https://api.github.com/users/halissonvit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/halissonvit/subscriptions","organizations_url":"https://api.github.com/users/halissonvit/orgs","repos_url":"https://api.github.com/users/halissonvit/repos","events_url":"https://api.github.com/users/halissonvit/events{/privacy}","received_events_url":"https://api.github.com/users/halissonvit/received_events","type":"User","site_admin":false},"body":"what does 800 mean? create a variable ","created_at":"2016-06-08T22:13:38Z","updated_at":"2016-06-08T22:13:38Z","html_url":"https://github.com/branquinhoaa/simon-game/pull/1#discussion_r66350233","pull_request_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/comments/66350233"},"html":{"href":"https://github.com/branquinhoaa/simon-game/pull/1#discussion_r66350233"},"pull_request":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1","id":72644764,"html_url":"https://github.com/branquinhoaa/simon-game/pull/1","diff_url":"https://github.com/branquinhoaa/simon-game/pull/1.diff","patch_url":"https://github.com/branquinhoaa/simon-game/pull/1.patch","issue_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/1","number":1,"state":"open","locked":false,"title":"first code version","user":{"login":"branquinhoaa","id":15239141,"avatar_url":"https://avatars.githubusercontent.com/u/15239141?v=3","gravatar_id":"","url":"https://api.github.com/users/branquinhoaa","html_url":"https://github.com/branquinhoaa","followers_url":"https://api.github.com/users/branquinhoaa/followers","following_url":"https://api.github.com/users/branquinhoaa/following{/other_user}","gists_url":"https://api.github.com/users/branquinhoaa/gists{/gist_id}","starred_url":"https://api.github.com/users/branquinhoaa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/branquinhoaa/subscriptions","organizations_url":"https://api.github.com/users/branquinhoaa/orgs","repos_url":"https://api.github.com/users/branquinhoaa/repos","events_url":"https://api.github.com/users/branquinhoaa/events{/privacy}","received_events_url":"https://api.github.com/users/branquinhoaa/received_events","type":"User","site_admin":false},"body":"Simon's code first version to improve.","created_at":"2016-06-06T00:07:24Z","updated_at":"2016-06-08T22:13:38Z","closed_at":null,"merged_at":null,"merge_commit_sha":"01d3ee961ecf392ed3f304e1b05973c9a0a6629a","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1/commits","review_comments_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1/comments","review_comment_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/comments{/number}","comments_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/1/comments","statuses_url":"https://api.github.com/repos/branquinhoaa/simon-game/statuses/18f7da8b827d811e688d2b5e53c8ed8019ee2781","head":{"label":"branquinhoaa:code-game","ref":"code-game","sha":"18f7da8b827d811e688d2b5e53c8ed8019ee2781","user":{"login":"branquinhoaa","id":15239141,"avatar_url":"https://avatars.githubusercontent.com/u/15239141?v=3","gravatar_id":"","url":"https://api.github.com/users/branquinhoaa","html_url":"https://github.com/branquinhoaa","followers_url":"https://api.github.com/users/branquinhoaa/followers","following_url":"https://api.github.com/users/branquinhoaa/following{/other_user}","gists_url":"https://api.github.com/users/branquinhoaa/gists{/gist_id}","starred_url":"https://api.github.com/users/branquinhoaa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/branquinhoaa/subscriptions","organizations_url":"https://api.github.com/users/branquinhoaa/orgs","repos_url":"https://api.github.com/users/branquinhoaa/repos","events_url":"https://api.github.com/users/branquinhoaa/events{/privacy}","received_events_url":"https://api.github.com/users/branquinhoaa/received_events","type":"User","site_admin":false},"repo":{"id":60475834,"name":"simon-game","full_name":"branquinhoaa/simon-game","owner":{"login":"branquinhoaa","id":15239141,"avatar_url":"https://avatars.githubusercontent.com/u/15239141?v=3","gravatar_id":"","url":"https://api.github.com/users/branquinhoaa","html_url":"https://github.com/branquinhoaa","followers_url":"https://api.github.com/users/branquinhoaa/followers","following_url":"https://api.github.com/users/branquinhoaa/following{/other_user}","gists_url":"https://api.github.com/users/branquinhoaa/gists{/gist_id}","starred_url":"https://api.github.com/users/branquinhoaa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/branquinhoaa/subscriptions","organizations_url":"https://api.github.com/users/branquinhoaa/orgs","repos_url":"https://api.github.com/users/branquinhoaa/repos","events_url":"https://api.github.com/users/branquinhoaa/events{/privacy}","received_events_url":"https://api.github.com/users/branquinhoaa/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/branquinhoaa/simon-game","description":"","fork":false,"url":"https://api.github.com/repos/branquinhoaa/simon-game","forks_url":"https://api.github.com/repos/branquinhoaa/simon-game/forks","keys_url":"https://api.github.com/repos/branquinhoaa/simon-game/keys{/key_id}","collaborators_url":"https://api.github.com/repos/branquinhoaa/simon-game/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/branquinhoaa/simon-game/teams","hooks_url":"https://api.github.com/repos/branquinhoaa/simon-game/hooks","issue_events_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/events{/number}","events_url":"https://api.github.com/repos/branquinhoaa/simon-game/events","assignees_url":"https://api.github.com/repos/branquinhoaa/simon-game/assignees{/user}","branches_url":"https://api.github.com/repos/branquinhoaa/simon-game/branches{/branch}","tags_url":"https://api.github.com/repos/branquinhoaa/simon-game/tags","blobs_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/refs{/sha}","trees_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/trees{/sha}","statuses_url":"https://api.github.com/repos/branquinhoaa/simon-game/statuses/{sha}","languages_url":"https://api.github.com/repos/branquinhoaa/simon-game/languages","stargazers_url":"https://api.github.com/repos/branquinhoaa/simon-game/stargazers","contributors_url":"https://api.github.com/repos/branquinhoaa/simon-game/contributors","subscribers_url":"https://api.github.com/repos/branquinhoaa/simon-game/subscribers","subscription_url":"https://api.github.com/repos/branquinhoaa/simon-game/subscription","commits_url":"https://api.github.com/repos/branquinhoaa/simon-game/commits{/sha}","git_commits_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/commits{/sha}","comments_url":"https://api.github.com/repos/branquinhoaa/simon-game/comments{/number}","issue_comment_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/comments{/number}","contents_url":"https://api.github.com/repos/branquinhoaa/simon-game/contents/{+path}","compare_url":"https://api.github.com/repos/branquinhoaa/simon-game/compare/{base}...{head}","merges_url":"https://api.github.com/repos/branquinhoaa/simon-game/merges","archive_url":"https://api.github.com/repos/branquinhoaa/simon-game/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/branquinhoaa/simon-game/downloads","issues_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues{/number}","pulls_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls{/number}","milestones_url":"https://api.github.com/repos/branquinhoaa/simon-game/milestones{/number}","notifications_url":"https://api.github.com/repos/branquinhoaa/simon-game/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/branquinhoaa/simon-game/labels{/name}","releases_url":"https://api.github.com/repos/branquinhoaa/simon-game/releases{/id}","deployments_url":"https://api.github.com/repos/branquinhoaa/simon-game/deployments","created_at":"2016-06-05T18:59:42Z","updated_at":"2016-06-05T18:59:42Z","pushed_at":"2016-06-08T21:09:57Z","git_url":"git://github.com/branquinhoaa/simon-game.git","ssh_url":"git@github.com:branquinhoaa/simon-game.git","clone_url":"https://github.com/branquinhoaa/simon-game.git","svn_url":"https://github.com/branquinhoaa/simon-game","homepage":null,"size":22,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"branquinhoaa:master","ref":"master","sha":"65c44fc13ff342cbd64a4296f3c372488d478fbc","user":{"login":"branquinhoaa","id":15239141,"avatar_url":"https://avatars.githubusercontent.com/u/15239141?v=3","gravatar_id":"","url":"https://api.github.com/users/branquinhoaa","html_url":"https://github.com/branquinhoaa","followers_url":"https://api.github.com/users/branquinhoaa/followers","following_url":"https://api.github.com/users/branquinhoaa/following{/other_user}","gists_url":"https://api.github.com/users/branquinhoaa/gists{/gist_id}","starred_url":"https://api.github.com/users/branquinhoaa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/branquinhoaa/subscriptions","organizations_url":"https://api.github.com/users/branquinhoaa/orgs","repos_url":"https://api.github.com/users/branquinhoaa/repos","events_url":"https://api.github.com/users/branquinhoaa/events{/privacy}","received_events_url":"https://api.github.com/users/branquinhoaa/received_events","type":"User","site_admin":false},"repo":{"id":60475834,"name":"simon-game","full_name":"branquinhoaa/simon-game","owner":{"login":"branquinhoaa","id":15239141,"avatar_url":"https://avatars.githubusercontent.com/u/15239141?v=3","gravatar_id":"","url":"https://api.github.com/users/branquinhoaa","html_url":"https://github.com/branquinhoaa","followers_url":"https://api.github.com/users/branquinhoaa/followers","following_url":"https://api.github.com/users/branquinhoaa/following{/other_user}","gists_url":"https://api.github.com/users/branquinhoaa/gists{/gist_id}","starred_url":"https://api.github.com/users/branquinhoaa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/branquinhoaa/subscriptions","organizations_url":"https://api.github.com/users/branquinhoaa/orgs","repos_url":"https://api.github.com/users/branquinhoaa/repos","events_url":"https://api.github.com/users/branquinhoaa/events{/privacy}","received_events_url":"https://api.github.com/users/branquinhoaa/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/branquinhoaa/simon-game","description":"","fork":false,"url":"https://api.github.com/repos/branquinhoaa/simon-game","forks_url":"https://api.github.com/repos/branquinhoaa/simon-game/forks","keys_url":"https://api.github.com/repos/branquinhoaa/simon-game/keys{/key_id}","collaborators_url":"https://api.github.com/repos/branquinhoaa/simon-game/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/branquinhoaa/simon-game/teams","hooks_url":"https://api.github.com/repos/branquinhoaa/simon-game/hooks","issue_events_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/events{/number}","events_url":"https://api.github.com/repos/branquinhoaa/simon-game/events","assignees_url":"https://api.github.com/repos/branquinhoaa/simon-game/assignees{/user}","branches_url":"https://api.github.com/repos/branquinhoaa/simon-game/branches{/branch}","tags_url":"https://api.github.com/repos/branquinhoaa/simon-game/tags","blobs_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/refs{/sha}","trees_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/trees{/sha}","statuses_url":"https://api.github.com/repos/branquinhoaa/simon-game/statuses/{sha}","languages_url":"https://api.github.com/repos/branquinhoaa/simon-game/languages","stargazers_url":"https://api.github.com/repos/branquinhoaa/simon-game/stargazers","contributors_url":"https://api.github.com/repos/branquinhoaa/simon-game/contributors","subscribers_url":"https://api.github.com/repos/branquinhoaa/simon-game/subscribers","subscription_url":"https://api.github.com/repos/branquinhoaa/simon-game/subscription","commits_url":"https://api.github.com/repos/branquinhoaa/simon-game/commits{/sha}","git_commits_url":"https://api.github.com/repos/branquinhoaa/simon-game/git/commits{/sha}","comments_url":"https://api.github.com/repos/branquinhoaa/simon-game/comments{/number}","issue_comment_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues/comments{/number}","contents_url":"https://api.github.com/repos/branquinhoaa/simon-game/contents/{+path}","compare_url":"https://api.github.com/repos/branquinhoaa/simon-game/compare/{base}...{head}","merges_url":"https://api.github.com/repos/branquinhoaa/simon-game/merges","archive_url":"https://api.github.com/repos/branquinhoaa/simon-game/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/branquinhoaa/simon-game/downloads","issues_url":"https://api.github.com/repos/branquinhoaa/simon-game/issues{/number}","pulls_url":"https://api.github.com/repos/branquinhoaa/simon-game/pulls{/number}","milestones_url":"https://api.github.com/repos/branquinhoaa/simon-game/milestones{/number}","notifications_url":"https://api.github.com/repos/branquinhoaa/simon-game/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/branquinhoaa/simon-game/labels{/name}","releases_url":"https://api.github.com/repos/branquinhoaa/simon-game/releases{/id}","deployments_url":"https://api.github.com/repos/branquinhoaa/simon-game/deployments","created_at":"2016-06-05T18:59:42Z","updated_at":"2016-06-05T18:59:42Z","pushed_at":"2016-06-08T21:09:57Z","git_url":"git://github.com/branquinhoaa/simon-game.git","ssh_url":"git@github.com:branquinhoaa/simon-game.git","clone_url":"https://github.com/branquinhoaa/simon-game.git","svn_url":"https://github.com/branquinhoaa/simon-game","homepage":null,"size":22,"stargazers_count":0,"watchers_count":0,"language":null,"has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1"},"html":{"href":"https://github.com/branquinhoaa/simon-game/pull/1"},"issue":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/issues/1"},"comments":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/branquinhoaa/simon-game/statuses/18f7da8b827d811e688d2b5e53c8ed8019ee2781"}}}}
{"actor":{"display_login":"halissonvit"}}