{"action":"created","comment":{"url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/comments/204101735","pull_request_review_id":139124493,"id":204101735,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwNDEwMTczNQ==","diff_hunk":"@@ -0,0 +1,59 @@\n+//\n+//  SKSpriteNodeExtensions.swift\n+//  SwifterSwift\n+//\n+//  Created by Robbie Moyer on 7/20/18.\n+//  Copyright © 2018 SwifterSwift\n+//\n+\n+#if canImport(SpriteKit)\n+import SpriteKit\n+\n+// MARK: - Methods\n+public extension SKSpriteNode {\n+    /// SwifterSwift: Creates and runs an action that animates changes to a sprite’s texture,\n+    /// possibly resizing the sprite. When the action executes, the sprite’s texture property\n+    /// animates through the textures in the texture atlas. The total duration of the action is\n+    /// the number of textures multiplied by the `timePerFrame`.\n+    ///\n+    /// **Note**\n+    ///\n+    /// If the restore parameter is true and this action is removed from a node before it completes,\n+    /// then node’s texture is still restored. This differs from the default behavior of removing an action.\n+    ///\n+    /// - Parameters:\n+    ///   - atlasName: The name of the texture atlas, without the `.atlas` or `.spriteatlas` extension.\n+    ///   - seconds: The amount of time, in seconds, that each texture is displayed.\n+    ///   - resize: If `true`, the sprite is resized to match each new texture. If `false`, the size of the sprite remains at a constant size.\n+    ///   - restore:\n+    ///\n+    ///     * If `true`:\n+    ///\n+    ///       When the action completes, the sprite’s texture is restored to the texture it had\n+    ///       before the action completed. (If the resize parameter is true, the sprite is resized\n+    ///       to match the size of the original texture.)\n+    ///\n+    ///     * If `false`:\n+    ///\n+    ///       When the action completes, the sprite’s texture remains set to the final texture in the array.\n+    ///\n+    ///   - completion: The block to run when the animation is complete.\n+    public func animate(\n+        withAtlasNamed atlasName: String,\n+        timePerFrame seconds: TimeInterval,\n+        resize: Bool,\n+        restore: Bool,\n+        completion: (() -> Void)? = nil) {\n+        \n+        let textureAtlas = SKTextureAtlas(named: atlasName)\n+        \n+        let textures = textureAtlas.textureNames\n+            .sorted()\n+            .map({ SKTexture(imageNamed: $0) })","path":"Sources/Extensions/SpriteKit/SKSpriteNodeExtensions.swift","position":52,"original_position":52,"commit_id":"9a8030140a8b54a2a7c640f8ee910f1536c648e1","original_commit_id":"9a8030140a8b54a2a7c640f8ee910f1536c648e1","user":{"login":"guykogus","id":924764,"node_id":"MDQ6VXNlcjkyNDc2NA==","avatar_url":"https://avatars2.githubusercontent.com/u/924764?v=4","gravatar_id":"","url":"https://api.github.com/users/guykogus","html_url":"https://github.com/guykogus","followers_url":"https://api.github.com/users/guykogus/followers","following_url":"https://api.github.com/users/guykogus/following{/other_user}","gists_url":"https://api.github.com/users/guykogus/gists{/gist_id}","starred_url":"https://api.github.com/users/guykogus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/guykogus/subscriptions","organizations_url":"https://api.github.com/users/guykogus/orgs","repos_url":"https://api.github.com/users/guykogus/repos","events_url":"https://api.github.com/users/guykogus/events{/privacy}","received_events_url":"https://api.github.com/users/guykogus/received_events","type":"User","site_admin":false},"body":"Again you can remove parentheses. I feel like we should be using SwiftLint to check for these :)\r\n```Swift\r\n.map { SKTexture(imageNamed: $0) }\r\n```","created_at":"2018-07-20T16:36:30Z","updated_at":"2018-07-20T16:38:08Z","html_url":"https://github.com/SwifterSwift/SwifterSwift/pull/522#discussion_r204101735","pull_request_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/comments/204101735"},"html":{"href":"https://github.com/SwifterSwift/SwifterSwift/pull/522#discussion_r204101735"},"pull_request":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522"}}},"pull_request":{"url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522","id":202893592,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAyODkzNTky","html_url":"https://github.com/SwifterSwift/SwifterSwift/pull/522","diff_url":"https://github.com/SwifterSwift/SwifterSwift/pull/522.diff","patch_url":"https://github.com/SwifterSwift/SwifterSwift/pull/522.patch","issue_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/522","number":522,"state":"open","locked":false,"title":"Added more SpriteKit extensions","user":{"login":"moyerr","id":9791664,"node_id":"MDQ6VXNlcjk3OTE2NjQ=","avatar_url":"https://avatars1.githubusercontent.com/u/9791664?v=4","gravatar_id":"","url":"https://api.github.com/users/moyerr","html_url":"https://github.com/moyerr","followers_url":"https://api.github.com/users/moyerr/followers","following_url":"https://api.github.com/users/moyerr/following{/other_user}","gists_url":"https://api.github.com/users/moyerr/gists{/gist_id}","starred_url":"https://api.github.com/users/moyerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moyerr/subscriptions","organizations_url":"https://api.github.com/users/moyerr/orgs","repos_url":"https://api.github.com/users/moyerr/repos","events_url":"https://api.github.com/users/moyerr/events{/privacy}","received_events_url":"https://api.github.com/users/moyerr/received_events","type":"User","site_admin":false},"body":"Helping out with Issue #303.\r\n\r\n<!--- Provide a general summary of your changes in the Title above -->\r\n\r\n## Checklist\r\n<!--- Please go over all the following points, and put an `x` in all the boxes that apply. -->\r\n<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->\r\n\r\n\r\n- [x] I checked the [**Contributing Guidelines**](https://github.com/SwifterSwift/SwifterSwift/blob/master/CONTRIBUTING.md) before creating this request.\r\n- [x] New extensions are written in Swift 4.\r\n- [x] New extensions support iOS 8.0+ / tvOS 9.0+ / macOS 10.10+ / watchOS 2.0+.\r\n- [ ] I have added tests for new extensions, and they passed.\r\n- [x] All extensions have a **clear** comments explaining their functionality, all parameters and return type in English.\r\n- [x] All extensions are declared as **public**.\r\n- [x] I have added a [changelog](https://github.com/SwifterSwift/SwifterSwift/blob/master/CHANGELOG_GUIDELINES.md) entry describing my changes.","created_at":"2018-07-20T16:08:38Z","updated_at":"2018-07-20T16:38:08Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6b11d94314d35b904a8f60332ccc8b98f4fbb30b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522/commits","review_comments_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522/comments","review_comment_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/522/comments","statuses_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/statuses/9a8030140a8b54a2a7c640f8ee910f1536c648e1","head":{"label":"moyerr:spritekit-extensions","ref":"spritekit-extensions","sha":"9a8030140a8b54a2a7c640f8ee910f1536c648e1","user":{"login":"moyerr","id":9791664,"node_id":"MDQ6VXNlcjk3OTE2NjQ=","avatar_url":"https://avatars1.githubusercontent.com/u/9791664?v=4","gravatar_id":"","url":"https://api.github.com/users/moyerr","html_url":"https://github.com/moyerr","followers_url":"https://api.github.com/users/moyerr/followers","following_url":"https://api.github.com/users/moyerr/following{/other_user}","gists_url":"https://api.github.com/users/moyerr/gists{/gist_id}","starred_url":"https://api.github.com/users/moyerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moyerr/subscriptions","organizations_url":"https://api.github.com/users/moyerr/orgs","repos_url":"https://api.github.com/users/moyerr/repos","events_url":"https://api.github.com/users/moyerr/events{/privacy}","received_events_url":"https://api.github.com/users/moyerr/received_events","type":"User","site_admin":false},"repo":{"id":121800332,"node_id":"MDEwOlJlcG9zaXRvcnkxMjE4MDAzMzI=","name":"SwifterSwift","full_name":"moyerr/SwifterSwift","owner":{"login":"moyerr","id":9791664,"node_id":"MDQ6VXNlcjk3OTE2NjQ=","avatar_url":"https://avatars1.githubusercontent.com/u/9791664?v=4","gravatar_id":"","url":"https://api.github.com/users/moyerr","html_url":"https://github.com/moyerr","followers_url":"https://api.github.com/users/moyerr/followers","following_url":"https://api.github.com/users/moyerr/following{/other_user}","gists_url":"https://api.github.com/users/moyerr/gists{/gist_id}","starred_url":"https://api.github.com/users/moyerr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moyerr/subscriptions","organizations_url":"https://api.github.com/users/moyerr/orgs","repos_url":"https://api.github.com/users/moyerr/repos","events_url":"https://api.github.com/users/moyerr/events{/privacy}","received_events_url":"https://api.github.com/users/moyerr/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/moyerr/SwifterSwift","description":"A handy collection of more than 500 native Swift extensions to boost your productivity.","fork":true,"url":"https://api.github.com/repos/moyerr/SwifterSwift","forks_url":"https://api.github.com/repos/moyerr/SwifterSwift/forks","keys_url":"https://api.github.com/repos/moyerr/SwifterSwift/keys{/key_id}","collaborators_url":"https://api.github.com/repos/moyerr/SwifterSwift/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/moyerr/SwifterSwift/teams","hooks_url":"https://api.github.com/repos/moyerr/SwifterSwift/hooks","issue_events_url":"https://api.github.com/repos/moyerr/SwifterSwift/issues/events{/number}","events_url":"https://api.github.com/repos/moyerr/SwifterSwift/events","assignees_url":"https://api.github.com/repos/moyerr/SwifterSwift/assignees{/user}","branches_url":"https://api.github.com/repos/moyerr/SwifterSwift/branches{/branch}","tags_url":"https://api.github.com/repos/moyerr/SwifterSwift/tags","blobs_url":"https://api.github.com/repos/moyerr/SwifterSwift/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/moyerr/SwifterSwift/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/moyerr/SwifterSwift/git/refs{/sha}","trees_url":"https://api.github.com/repos/moyerr/SwifterSwift/git/trees{/sha}","statuses_url":"https://api.github.com/repos/moyerr/SwifterSwift/statuses/{sha}","languages_url":"https://api.github.com/repos/moyerr/SwifterSwift/languages","stargazers_url":"https://api.github.com/repos/moyerr/SwifterSwift/stargazers","contributors_url":"https://api.github.com/repos/moyerr/SwifterSwift/contributors","subscribers_url":"https://api.github.com/repos/moyerr/SwifterSwift/subscribers","subscription_url":"https://api.github.com/repos/moyerr/SwifterSwift/subscription","commits_url":"https://api.github.com/repos/moyerr/SwifterSwift/commits{/sha}","git_commits_url":"https://api.github.com/repos/moyerr/SwifterSwift/git/commits{/sha}","comments_url":"https://api.github.com/repos/moyerr/SwifterSwift/comments{/number}","issue_comment_url":"https://api.github.com/repos/moyerr/SwifterSwift/issues/comments{/number}","contents_url":"https://api.github.com/repos/moyerr/SwifterSwift/contents/{+path}","compare_url":"https://api.github.com/repos/moyerr/SwifterSwift/compare/{base}...{head}","merges_url":"https://api.github.com/repos/moyerr/SwifterSwift/merges","archive_url":"https://api.github.com/repos/moyerr/SwifterSwift/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/moyerr/SwifterSwift/downloads","issues_url":"https://api.github.com/repos/moyerr/SwifterSwift/issues{/number}","pulls_url":"https://api.github.com/repos/moyerr/SwifterSwift/pulls{/number}","milestones_url":"https://api.github.com/repos/moyerr/SwifterSwift/milestones{/number}","notifications_url":"https://api.github.com/repos/moyerr/SwifterSwift/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/moyerr/SwifterSwift/labels{/name}","releases_url":"https://api.github.com/repos/moyerr/SwifterSwift/releases{/id}","deployments_url":"https://api.github.com/repos/moyerr/SwifterSwift/deployments","created_at":"2018-02-16T21:01:35Z","updated_at":"2018-07-20T14:13:32Z","pushed_at":"2018-07-20T16:28:02Z","git_url":"git://github.com/moyerr/SwifterSwift.git","ssh_url":"git@github.com:moyerr/SwifterSwift.git","clone_url":"https://github.com/moyerr/SwifterSwift.git","svn_url":"https://github.com/moyerr/SwifterSwift","homepage":"https://swifterswift.com","size":14185,"stargazers_count":0,"watchers_count":0,"language":"Swift","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"SwifterSwift:master","ref":"master","sha":"817a58012f2fbc6d297c99092949c45c37a8609f","user":{"login":"SwifterSwift","id":25029478,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MDI5NDc4","avatar_url":"https://avatars2.githubusercontent.com/u/25029478?v=4","gravatar_id":"","url":"https://api.github.com/users/SwifterSwift","html_url":"https://github.com/SwifterSwift","followers_url":"https://api.github.com/users/SwifterSwift/followers","following_url":"https://api.github.com/users/SwifterSwift/following{/other_user}","gists_url":"https://api.github.com/users/SwifterSwift/gists{/gist_id}","starred_url":"https://api.github.com/users/SwifterSwift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SwifterSwift/subscriptions","organizations_url":"https://api.github.com/users/SwifterSwift/orgs","repos_url":"https://api.github.com/users/SwifterSwift/repos","events_url":"https://api.github.com/users/SwifterSwift/events{/privacy}","received_events_url":"https://api.github.com/users/SwifterSwift/received_events","type":"Organization","site_admin":false},"repo":{"id":64705781,"node_id":"MDEwOlJlcG9zaXRvcnk2NDcwNTc4MQ==","name":"SwifterSwift","full_name":"SwifterSwift/SwifterSwift","owner":{"login":"SwifterSwift","id":25029478,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MDI5NDc4","avatar_url":"https://avatars2.githubusercontent.com/u/25029478?v=4","gravatar_id":"","url":"https://api.github.com/users/SwifterSwift","html_url":"https://github.com/SwifterSwift","followers_url":"https://api.github.com/users/SwifterSwift/followers","following_url":"https://api.github.com/users/SwifterSwift/following{/other_user}","gists_url":"https://api.github.com/users/SwifterSwift/gists{/gist_id}","starred_url":"https://api.github.com/users/SwifterSwift/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SwifterSwift/subscriptions","organizations_url":"https://api.github.com/users/SwifterSwift/orgs","repos_url":"https://api.github.com/users/SwifterSwift/repos","events_url":"https://api.github.com/users/SwifterSwift/events{/privacy}","received_events_url":"https://api.github.com/users/SwifterSwift/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SwifterSwift/SwifterSwift","description":"A handy collection of more than 500 native Swift extensions to boost your productivity.","fork":false,"url":"https://api.github.com/repos/SwifterSwift/SwifterSwift","forks_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/forks","keys_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/teams","hooks_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/hooks","issue_events_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/events{/number}","events_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/events","assignees_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/assignees{/user}","branches_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/branches{/branch}","tags_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/tags","blobs_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/git/refs{/sha}","trees_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/statuses/{sha}","languages_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/languages","stargazers_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/stargazers","contributors_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/contributors","subscribers_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/subscribers","subscription_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/subscription","commits_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/commits{/sha}","git_commits_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/git/commits{/sha}","comments_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/comments{/number}","issue_comment_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/comments{/number}","contents_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/contents/{+path}","compare_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/merges","archive_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/downloads","issues_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues{/number}","pulls_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls{/number}","milestones_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/milestones{/number}","notifications_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/labels{/name}","releases_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/releases{/id}","deployments_url":"https://api.github.com/repos/SwifterSwift/SwifterSwift/deployments","created_at":"2016-08-01T22:25:24Z","updated_at":"2018-07-20T16:04:31Z","pushed_at":"2018-07-20T16:11:38Z","git_url":"git://github.com/SwifterSwift/SwifterSwift.git","ssh_url":"git@github.com:SwifterSwift/SwifterSwift.git","clone_url":"https://github.com/SwifterSwift/SwifterSwift.git","svn_url":"https://github.com/SwifterSwift/SwifterSwift","homepage":"https://swifterswift.com","size":14185,"stargazers_count":5740,"watchers_count":5740,"language":"Swift","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":588,"mirror_url":null,"archived":false,"open_issues_count":15,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":588,"open_issues":15,"watchers":5740,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522"},"html":{"href":"https://github.com/SwifterSwift/SwifterSwift/pull/522"},"issue":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/522"},"comments":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/issues/522/comments"},"review_comments":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522/comments"},"review_comment":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/pulls/522/commits"},"statuses":{"href":"https://api.github.com/repos/SwifterSwift/SwifterSwift/statuses/9a8030140a8b54a2a7c640f8ee910f1536c648e1"}},"author_association":"NONE"}}
{"actor":{"display_login":"guykogus"}}