{"action":"created","comment":{"url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/comments/219716928","pull_request_review_id":157957608,"id":219716928,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxOTcxNjkyOA==","diff_hunk":"@@ -0,0 +1,42 @@\n+﻿using System.Collections;\r\n+using System.Collections.Generic;\r\n+using UnityEngine;\r\n+\r\n+public class WaveSpawner : MonoBehaviour {\r\n+\r\n+    [SerializeField] List<WaveConfig> waveConfigs;\r\n+    [SerializeField] int startingWave = 0;\r\n+    ObjectPooler enemyPool;\r\n+\r\n+\t// Use this for initialization\r\n+\tIEnumerator Start () {\r\n+        enemyPool = ObjectPooler.instance;\r\n+        yield return StartCoroutine(SpawnAllWaves());\r\n+\t}\r\n+\r\n+    private IEnumerator SpawnAllWaves()\r\n+    {\r\n+        for (int i = startingWave; i < waveConfigs.Count; i++)\r\n+        {\r\n+            WaveConfig currentWave = waveConfigs[i];\r\n+            yield return StartCoroutine(SpawnWave(currentWave));\r\n+        }\r\n+    }\r\n+\t\r\n+\tprivate IEnumerator SpawnWave(WaveConfig waveConfig)\r\n+    {\r\n+        int numberOfEnemies = waveConfig.NumberOfEnemies;\r\n+        for (int i = 0; i < numberOfEnemies; i++)\r\n+        {\r\n+            GameObject obj = enemyPool.GetPooledObject(\"Enemy\");\r","path":"Assets/_Scripts/WaveSpawner.cs","position":31,"original_position":31,"commit_id":"4beef83f97502a106c435d8894f85a8a6e23370d","original_commit_id":"4beef83f97502a106c435d8894f85a8a6e23370d","user":{"login":"thomastianlu","id":8942070,"node_id":"MDQ6VXNlcjg5NDIwNzA=","avatar_url":"https://avatars1.githubusercontent.com/u/8942070?v=4","gravatar_id":"","url":"https://api.github.com/users/thomastianlu","html_url":"https://github.com/thomastianlu","followers_url":"https://api.github.com/users/thomastianlu/followers","following_url":"https://api.github.com/users/thomastianlu/following{/other_user}","gists_url":"https://api.github.com/users/thomastianlu/gists{/gist_id}","starred_url":"https://api.github.com/users/thomastianlu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thomastianlu/subscriptions","organizations_url":"https://api.github.com/users/thomastianlu/orgs","repos_url":"https://api.github.com/users/thomastianlu/repos","events_url":"https://api.github.com/users/thomastianlu/events{/privacy}","received_events_url":"https://api.github.com/users/thomastianlu/received_events","type":"User","site_admin":false},"body":"See my other comment about passing in strings","created_at":"2018-09-24T00:11:45Z","updated_at":"2018-09-24T00:11:45Z","html_url":"https://github.com/kylemazza/Bullet-Hell/pull/2#discussion_r219716928","pull_request_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/comments/219716928"},"html":{"href":"https://github.com/kylemazza/Bullet-Hell/pull/2#discussion_r219716928"},"pull_request":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2"}}},"pull_request":{"url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2","id":214159874,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE0MTU5ODc0","html_url":"https://github.com/kylemazza/Bullet-Hell/pull/2","diff_url":"https://github.com/kylemazza/Bullet-Hell/pull/2.diff","patch_url":"https://github.com/kylemazza/Bullet-Hell/pull/2.patch","issue_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/2","number":2,"state":"open","locked":false,"title":"Waves n pathing","user":{"login":"kylemazza","id":25045577,"node_id":"MDQ6VXNlcjI1MDQ1NTc3","avatar_url":"https://avatars2.githubusercontent.com/u/25045577?v=4","gravatar_id":"","url":"https://api.github.com/users/kylemazza","html_url":"https://github.com/kylemazza","followers_url":"https://api.github.com/users/kylemazza/followers","following_url":"https://api.github.com/users/kylemazza/following{/other_user}","gists_url":"https://api.github.com/users/kylemazza/gists{/gist_id}","starred_url":"https://api.github.com/users/kylemazza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylemazza/subscriptions","organizations_url":"https://api.github.com/users/kylemazza/orgs","repos_url":"https://api.github.com/users/kylemazza/repos","events_url":"https://api.github.com/users/kylemazza/events{/privacy}","received_events_url":"https://api.github.com/users/kylemazza/received_events","type":"User","site_admin":false},"body":"Okay, **in summary**:\r\n- Added a WaveConfig scriptable object that contains some of the data for a wave.\r\n- Added each WaveConfig to the GameManager via a WaveSpawner script which simply loops through the waves once via coroutines.\r\n- Added AnimationControllers with Animations for the pathing of a wave, which is included into the WaveConfig.\r\n- Made a generic object pooler class which runs off a single instance, and generates multiple pools that can be accessed via tags.\r\n- Made a BulletEmitter script which...emits bullets...(my idea with this was to be able to separate bullet patterns from the enemy itself, allowing bullets to spawn independently of enemies, or something like that. It's easier to explain with a picture, but I can explain when we talk again, plus I have questions about how to approach this)\r\n\r\n**Questions that I have:**\r\n- Is there a better way to animate pathing? I know that it can be done via math equations, but I wasn't sure how to combine mathematical functions to make more complex paths (i.e. straight line - into circle - into sweeping arc)\r\n- Is there a better way to use animation to do pathing? The way I did it feels a little bit inexact (I used curves mostly).\r\n- How can I spawn multiple waves at the same time? I figured I could just have multiple WaveSpawners running coroutines concurrently alongside each other, but I wasn't sure if that was a good way to go.\r\n- Right now the bullets just fire straight down, attached to the enemy instance. I wasn't sure how to approach more intricate patterns/multiple bullets firing off of a single enemy in multiple directions. I was thinking of having multiple BulletEmitters nested under a parent object, nested under an enemy instance. Then, the BulletEmitters simply fire off bullets in a direction, but can rotate or translate or do weirder stuff. But I feel maybe I'm overthinking/overcomplicating it.\r\n\r\nThanks for helping out so far, sorry this past week or so has been pretty slow with adjusting to school schedule and trying to change all of my classes.","created_at":"2018-09-09T19:11:34Z","updated_at":"2018-09-24T00:11:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f9eb90cfabc5288e9cfe81d1f8aeab3091887ee4","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2/commits","review_comments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2/comments","review_comment_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/2/comments","statuses_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/statuses/4beef83f97502a106c435d8894f85a8a6e23370d","head":{"label":"kylemazza:waves-n-pathing","ref":"waves-n-pathing","sha":"4beef83f97502a106c435d8894f85a8a6e23370d","user":{"login":"kylemazza","id":25045577,"node_id":"MDQ6VXNlcjI1MDQ1NTc3","avatar_url":"https://avatars2.githubusercontent.com/u/25045577?v=4","gravatar_id":"","url":"https://api.github.com/users/kylemazza","html_url":"https://github.com/kylemazza","followers_url":"https://api.github.com/users/kylemazza/followers","following_url":"https://api.github.com/users/kylemazza/following{/other_user}","gists_url":"https://api.github.com/users/kylemazza/gists{/gist_id}","starred_url":"https://api.github.com/users/kylemazza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylemazza/subscriptions","organizations_url":"https://api.github.com/users/kylemazza/orgs","repos_url":"https://api.github.com/users/kylemazza/repos","events_url":"https://api.github.com/users/kylemazza/events{/privacy}","received_events_url":"https://api.github.com/users/kylemazza/received_events","type":"User","site_admin":false},"repo":{"id":145074630,"node_id":"MDEwOlJlcG9zaXRvcnkxNDUwNzQ2MzA=","name":"Bullet-Hell","full_name":"kylemazza/Bullet-Hell","private":false,"owner":{"login":"kylemazza","id":25045577,"node_id":"MDQ6VXNlcjI1MDQ1NTc3","avatar_url":"https://avatars2.githubusercontent.com/u/25045577?v=4","gravatar_id":"","url":"https://api.github.com/users/kylemazza","html_url":"https://github.com/kylemazza","followers_url":"https://api.github.com/users/kylemazza/followers","following_url":"https://api.github.com/users/kylemazza/following{/other_user}","gists_url":"https://api.github.com/users/kylemazza/gists{/gist_id}","starred_url":"https://api.github.com/users/kylemazza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylemazza/subscriptions","organizations_url":"https://api.github.com/users/kylemazza/orgs","repos_url":"https://api.github.com/users/kylemazza/repos","events_url":"https://api.github.com/users/kylemazza/events{/privacy}","received_events_url":"https://api.github.com/users/kylemazza/received_events","type":"User","site_admin":false},"html_url":"https://github.com/kylemazza/Bullet-Hell","description":null,"fork":false,"url":"https://api.github.com/repos/kylemazza/Bullet-Hell","forks_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/forks","keys_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/teams","hooks_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/hooks","issue_events_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/events{/number}","events_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/events","assignees_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/assignees{/user}","branches_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/branches{/branch}","tags_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/tags","blobs_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/refs{/sha}","trees_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/statuses/{sha}","languages_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/languages","stargazers_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/stargazers","contributors_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/contributors","subscribers_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/subscribers","subscription_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/subscription","commits_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/commits{/sha}","git_commits_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/commits{/sha}","comments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/comments{/number}","issue_comment_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/comments{/number}","contents_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/contents/{+path}","compare_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/merges","archive_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/downloads","issues_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues{/number}","pulls_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls{/number}","milestones_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/milestones{/number}","notifications_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/labels{/name}","releases_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/releases{/id}","deployments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/deployments","created_at":"2018-08-17T05:13:48Z","updated_at":"2018-09-05T00:33:49Z","pushed_at":"2018-09-09T19:11:35Z","git_url":"git://github.com/kylemazza/Bullet-Hell.git","ssh_url":"git@github.com:kylemazza/Bullet-Hell.git","clone_url":"https://github.com/kylemazza/Bullet-Hell.git","svn_url":"https://github.com/kylemazza/Bullet-Hell","homepage":null,"size":30918,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"kylemazza:master","ref":"master","sha":"008ea919c5672cc83e86baa7b77e24033516b454","user":{"login":"kylemazza","id":25045577,"node_id":"MDQ6VXNlcjI1MDQ1NTc3","avatar_url":"https://avatars2.githubusercontent.com/u/25045577?v=4","gravatar_id":"","url":"https://api.github.com/users/kylemazza","html_url":"https://github.com/kylemazza","followers_url":"https://api.github.com/users/kylemazza/followers","following_url":"https://api.github.com/users/kylemazza/following{/other_user}","gists_url":"https://api.github.com/users/kylemazza/gists{/gist_id}","starred_url":"https://api.github.com/users/kylemazza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylemazza/subscriptions","organizations_url":"https://api.github.com/users/kylemazza/orgs","repos_url":"https://api.github.com/users/kylemazza/repos","events_url":"https://api.github.com/users/kylemazza/events{/privacy}","received_events_url":"https://api.github.com/users/kylemazza/received_events","type":"User","site_admin":false},"repo":{"id":145074630,"node_id":"MDEwOlJlcG9zaXRvcnkxNDUwNzQ2MzA=","name":"Bullet-Hell","full_name":"kylemazza/Bullet-Hell","private":false,"owner":{"login":"kylemazza","id":25045577,"node_id":"MDQ6VXNlcjI1MDQ1NTc3","avatar_url":"https://avatars2.githubusercontent.com/u/25045577?v=4","gravatar_id":"","url":"https://api.github.com/users/kylemazza","html_url":"https://github.com/kylemazza","followers_url":"https://api.github.com/users/kylemazza/followers","following_url":"https://api.github.com/users/kylemazza/following{/other_user}","gists_url":"https://api.github.com/users/kylemazza/gists{/gist_id}","starred_url":"https://api.github.com/users/kylemazza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kylemazza/subscriptions","organizations_url":"https://api.github.com/users/kylemazza/orgs","repos_url":"https://api.github.com/users/kylemazza/repos","events_url":"https://api.github.com/users/kylemazza/events{/privacy}","received_events_url":"https://api.github.com/users/kylemazza/received_events","type":"User","site_admin":false},"html_url":"https://github.com/kylemazza/Bullet-Hell","description":null,"fork":false,"url":"https://api.github.com/repos/kylemazza/Bullet-Hell","forks_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/forks","keys_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/teams","hooks_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/hooks","issue_events_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/events{/number}","events_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/events","assignees_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/assignees{/user}","branches_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/branches{/branch}","tags_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/tags","blobs_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/refs{/sha}","trees_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/statuses/{sha}","languages_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/languages","stargazers_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/stargazers","contributors_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/contributors","subscribers_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/subscribers","subscription_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/subscription","commits_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/commits{/sha}","git_commits_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/git/commits{/sha}","comments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/comments{/number}","issue_comment_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/comments{/number}","contents_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/contents/{+path}","compare_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/merges","archive_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/downloads","issues_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues{/number}","pulls_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls{/number}","milestones_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/milestones{/number}","notifications_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/labels{/name}","releases_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/releases{/id}","deployments_url":"https://api.github.com/repos/kylemazza/Bullet-Hell/deployments","created_at":"2018-08-17T05:13:48Z","updated_at":"2018-09-05T00:33:49Z","pushed_at":"2018-09-09T19:11:35Z","git_url":"git://github.com/kylemazza/Bullet-Hell.git","ssh_url":"git@github.com:kylemazza/Bullet-Hell.git","clone_url":"https://github.com/kylemazza/Bullet-Hell.git","svn_url":"https://github.com/kylemazza/Bullet-Hell","homepage":null,"size":30918,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2"},"html":{"href":"https://github.com/kylemazza/Bullet-Hell/pull/2"},"issue":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/2"},"comments":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/kylemazza/Bullet-Hell/statuses/4beef83f97502a106c435d8894f85a8a6e23370d"}},"author_association":"OWNER"}}
{"actor":{"display_login":"thomastianlu"}}