Sonic Boom

Today I was finally able to figure out my secondary powerup. It now 1) spawns rarely, 2) is a multi-directional projectile, and 3) has a working powerup icon. I realized that a very important missing piece of my code was the script for the shield behavior itself…which I didn’t figure out until the 100th error message that I was trying to use a parameter as if it was a function (note: this is a red flag that I was assuming the code had more information than you’ve written). The biggest takeaway from today’s work is that everything that has a specific, independent behavior, needs a script for that behavior. I will get better at this with practice and time.

Wham!

Dan helped me with a tip that I should test my code in the update- I had to make sure the code was actually getting called. Once I saw this and my projectile still wasn’t moving, I had the realization that I need to write a script for the projectile’s behavior.

My next issue was to figure out to spawn the secondary powerup rarely. The Google suggestion that worked for me was making a separate IEnumerator function for both the “normal” and “rare” powerups, so that I could put separate time constraints on how often the spawn manager needed to instantiate the different types of powerups. I put a debug.log in the script after each instantiation to make sure this was happening, and it was.

Making sure the rare powerup actually spawns rarely.

Tomorrow will be dedicated to the camera shake, for which there seems to be a lot of community code online (hence why I decided to save this phase I requirement for last); Or at least that’s what I hope.

Positive Affirmation: Coding C# and Unity come easily and effortlessly to me, that I can understand it quickly, teach it to anyone and create anything I want. Coding is fun, relaxing and extremely enjoyable for me.

Stay well friends,

Kristin

--

--

--

Astrologer turned Software Developer who is aiming for the stars to land on the moon. Kristin the Developer is the Celestial Sleuth.

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Why I don’t use AWS

Creating an Account Vending Machine with Service Catalog

The product owner: the single-person bottleneck

Guidelines for Picking the Right Software Project Partner

Want To Get Paid To Code From Home? Start With A Roadmap

A look into Heptabase’s split writing experience

You Should be Prototyping without Assets

Vim is the last editor you will ever use

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Kristin

Kristin

Astrologer turned Software Developer who is aiming for the stars to land on the moon. Kristin the Developer is the Celestial Sleuth.

More from Medium

The True Issues Confronting American Education

Not A Series To Get Pumped About

I am an adult

Offer is not just an offer.