#13 | 26-8-24 | Code Modularity
Hello!
Progress on this project has stagnated. I intend to change that while I'm still on summer vacation, only one more week.
Now, onto today's subject. I got stuck on the idea I should make my spawning script modular and was severely disheartened when my first attempts failed. I tried to use scripteable objects and separate scripts for each wave, which didn't work.
Now, I have found a solution that works: lists.
Lists are expandable and the size can be changed easily, with the click of a button. For each new wave I write into the wave spawner script, there will be a new item (variable) in each list for it. Example pictured below:
In order to create a new wave, all I have to do is copy-paste the coroutine, rename it, and add new items to the lists (wave[], enemyWaveQuantity[]) and change their variables.
Modularity and expandability is incredibly important in creating an organized game. I also like to be very organized (in contradiction to my room) when building games or sorting files.
Thanks for reading!
Get Dead Alert
Dead Alert
Top down 2D survival shooter!
Status | Released |
Author | Ice Diamond Studio |
More posts
- #16 | 14-09-24 | Postmortem Addendum90 days ago
- #15 | 11-09-24 | Postmortem94 days ago
- #14 | 06-09-24 | PSA98 days ago
- #12 | 24-08-24 | Larger MapAug 24, 2024
- #11 | 20-08-24 | Beta PlanAug 20, 2024
- #10 | 19-08-24 | Alpha BuildAug 20, 2024
- #9 | 18-08-24 | Wave SystemAug 19, 2024
- #8 | 16-08-24 | Shop SystemAug 16, 2024
- #7 | 15-08-24 | MVP Build & PlanningAug 15, 2024
Leave a comment
Log in with itch.io to leave a comment.