Day 31- Rigid

Day 31- Rigid

Quote of the Day: “HIGHSCORE!”- Jeremy.

Music of the Day: Witcher 3 Soundtrack again. So epic.

So, remember all that stuff that I filled out for controls yesterday? Guess what I did AGAIN today! Because of the jump bug, we reverted to an older build, which meant that ALL of my progress from the last 2 days was completely wiped! Yay! Can you sense the absolute JOY AND EXHILARATION I FEEL? Man writing with sarcasm is harder than it looks. So yeah, I had to remake all of those inputs, along with re-doing all the projectile code I had changed. Thankfully, I had an inkling that the revert would happen, so before I left yesterday I made copies of all my scripts just in case. That little bit of foresight payed off pretty handily. Only took me about 15 minutes to get everything back to how I had it, which I was very thankful for. I got the projectile back to it’s state of shooting-but-not-really before I was ready for lunch and figured I was going to need to ask Alex what he had changed to make any more progress. I haven’t done a lunch picture in a while, so here you go, my microwavable Trader Joe’s Peanut Satay and a protein bar:IMG_0575.JPG

And yes, that is a 5 pound keg of gummy bears. We have 3 of them. They taste pretty mediocre.

Then I had a little bit of short-lived frustration. Jeremy said that he was experiencing a bug where powerups would just stop spawning after a little while. Obviously, that’s not the behavior we want, so once again I went searching for a problem that I had never seen happen before. Thankfully, the first test of finding a bug is almost always trying to recreate it, and try as I might, I wasn’t able to. This meant that it was a local problem on Jeremy’s version, potentially an extraneous line or file that had been slightly corrupted from all the moving on and off the server. Either way, no problem meant nothing to fix, so I went back to Timmy. I needed to take a break from the projectile for a while, because it was still being uncooperative. So I decided to fix a much smaller issue for consistency’s sake: his remains.

Every enemy in the game has remains that spawn and linger for a few seconds when they die. Gummies make a very satisfying squash noise and explode in a big mass of color when they die, and scatter their parts about in a small area. Roaches do much the same, just with a more skittery sound effect and a puke-colored explosion (yes it’s gross. But what other color suits a roach?). The prefab of an enemy is given the corresponding remains, and they are spawned in when it dies. After about 3-5 seconds they disappear as well, to reduce screen clutter. It’s just a way of giving the player visual feedback (and some measure of satisfaction) when they kill an enemy. However, Timmy had normal sized blue remains. Which meant you killed this giant 5-pound gummy bear boss, and were left with… some tiny little flecks of gummy. So I scaled it up to the same degree as Timmy, and now when he dies he throws massive chunks of gummy everywhere. It’s quite comical to watch a giant gummy arm explode into the air.

Then I made a breakthrough. When I was first messing with the gummy shot and couldn’t get it to work, I thought that it might be because each individual gummy bear in the wad also had a rigidbody that was messing with it, but seeing none of them I started to think of other ideas. Well, turns out I was right, I just didn’t go deep enough. In fact, every single part (head, torso, both arms, etc.) of a gummy bear has a rigidbody on it, so that when the shot explodes they can all be thrown outwards. Knowing this, I disabled them all and voila, the shot worked just like it should. With one small problem that I’m guessing you have also spotted. Now it couldn’t explode.  So I could either have the shot move as it was supposed to, or have it explode, but not both. Basically I was back to square one, just with slightly more knowledge. I experimented with turning the rigidbodies off while it was in the air (remember that every single gummy part has one, so that’s about 10 per gummy, and there are about 20 gummies in the wad), but of course rigidbodies don’t have the same easy “enable” method as every other component. Instead, they have methods called “Sleep” and “Wake up.” Seems like a non-issue right? Problem is, sleep only disables it for one frame. So it’s basically worthless to me, unless I wanted to be calling sleep on every single part in every single frame, which would quickly overload the computer. So again, back to square one.

If you’ve made it this far, congrats! That’s it. Why are you still here. There’s no special after prize. Shoo.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

For your efforts of scrolling all the way down here, you get the hidden after-prize: 10 Minibotz points. That’s right, I’m still keeping track of Minibotz points.

 

 

Advertisements

One thought on “Day 31- Rigid

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s