Dev Diary 018: Match 3 Invaders with new title screen and trails

Matt Barton's picture

Match 3 Invaders : now with cool trails!Match 3 Invaders : now with cool trails!It's been a long day of working on my game, mostly trying (and failing) to find out why it's still missing the occasional match. For awhile I wondered if it might be an issue with rigidbodies; that was a dead end. I next tried moving bits of code into lateupdate and such trying to see if that would help; nada. Finally I removed two "find" commands in the trigger event function. Since then, I've been unable to duplicate the error after about a half hour of beta testing. Sadly, I could just have gotten lucky, so I'm asking you guys to let me know if you encounter the bug again. I'd be willing to bet ten bucks that I'll get it the very next time I play it...But maybe not. I read on some tech forums that the "find" commands aren't very efficient, so I guess it's possible that they were delaying it just enough to cause the occasional miss.

I interviewed George Sanger ("The Fat Man") last week and he told me a fabulous story about M.U.L.E.. Apparently, Bunten was having a horrible time with a similar-sounding bug that made it very hard to get the mules lined up just right on the house. She finally gave up and explained that mules were ornery. Add a little animation of it running off the screen and suddenly that bug becomes a feature! Ornery mules...So I think it's about time to think about ornery invaders! Or perhaps the occasional dud projectile! Damn those cheap imports!

On a positive note, I just added what I consider a KILLER feature--trails on your projectiles! It sounds like a simple enough addition, but it really adds a lot (at least for my gameplay). Being able to see your trails gives it somewhat of a Tron or light cycles like feel--and it's just distracting enough to make the game more difficult, since you get hung up on trying to connect and don't notice that enemy bullet speeding towards your head!

I also added a scrolling background, one of the many things I learned how to do from 3D Buzz. I debated having it scroll faster as you progress, but I didn't really like that (seemed to make things a bit too busy). I opted for just enough scroll to be noticeable without being distracting.

Finally, I added some aliens to the title screen as a sort of lame attempt at an attract mode. I suppose if I were doing this for commercial purposes I'd want to extend that into a full demo mode.

I played around with Blender this morning, learning how to do UV maps. It's not nearly as straightforward as I hoped, but at least I have a better idea how it works. I don't really *need* it for this game, but it's going to be vital once I start getting into more complex models. That said, I was on the assets store today and noticed a featured 3D modeling app called "Game Draw Beta." That's got me intrigued, though I haven't looked into it yet (and that's unlikely given the $100 sticker price--for the beta!).

As always let me know what you think about the game and new stuff.

Unity Web Player | WebPlayer

Comments

Matt Barton
Matt Barton's picture
Offline
Joined: 01/16/2006
As predicted, I did manage to

As predicted, I did manage to get the bug again. But it took a long time...At least that's something--I must be getting closer to finding the problem, assuming I don't go with the aforementioned dud rockets solution.

n/a
TripHamer
TripHamer's picture
Offline
Joined: 07/31/2010
Ok, here's a bug:Level 1,

Ok, here's a bug:

Level 1, with the center column removed, I managed to get all the ones on the right to one color (blue). When I shot them they all exploded (normal behavior), however the one on the top left orphaned. Then I got one or two missed matches.

n/a
clok1966
Offline
Joined: 01/21/2009
I must say im amazed at your

I must say im amazed at your progress. I have a background in coding, have modded many games with editors and even did some quick Gamemaker stuff. But with all my know how (if you call it that) Unity and more complex game tools have felt so overwhelming i never get anywhere with them when I start from scratch. not only are you doing it from scratch you are doing "cross gameing" so its not just simple code pasting for you.

make me a bit jealous i must admit :) I can just relive the good old days when i had some artisitic ability (something i also have left behind and feel overwhlmed when i dable in).. while the net is amazing.. it can make one's own contrubutions seem so limited as there asre so many incredibly talanted people in the world.

Matt Barton
Matt Barton's picture
Offline
Joined: 01/16/2006
Thanks, clok, that's very

Thanks, clok, that's very nice of you. I'm pretty fast with typing and trying things, but I often get stuck.

I posted a question about this on the unity answers forum. We'll see what kind of response, if any, I get. I was browsing people who seemed to have similar problems, but none of the answers worked for me. I've got the problem narrowed down to that one function...

I've been thinking up some possible remedies. Instead of doing four different raycasts, I could try doing two--a big + shape, and then use raycastall to get an array of whatever it hits. I'm just not sure that'd be any faster or accurate.

People have been insisting that I could do ALL of it with some simple arrays, but I just don't see how.

n/a
clok1966
Offline
Joined: 01/21/2009
As you mentioned about a

As you mentioned about a "feature" in mule.. why not do the same as you say. if it get down to this issue (and i think i understand it as you end up with one lone enemy? if so jut some -if- coding and have a big ESCAPED! and have the enemy move off screen..

or is dude bullets? connection but the color isnt changeing?.. your idea of duds works for that as you mentioned.. if ity dont completly break the game.. I wouldnt think the DUD idea was to bad myslef.. :)

Matt Barton
Matt Barton's picture
Offline
Joined: 01/16/2006
I got some help from the

I got some help from the unity forums...One guy suggested it was a collider problem--maybe the rays were hitting holes. I can't really see that being an issue, but I made them bigger.

Another guy suggested it was something to do with the execution order, which I suspect as well. I tried moving the movement code into a late_update. That did seem to help, but didn't solve the issue. I also notice that the problem gets worse as the aliens move faster, so it really makes me think that's the root of the problem. By the time it's doing the raycasts, the aliens have moved far enough for it to miss.

n/a
Matt Barton
Matt Barton's picture
Offline
Joined: 01/16/2006
I added rigidbodies to the

I added rigidbodies to the aliens...That's not supposed to have any effect as far as I can tell from the documentation...Maybe it's just luck, but I've only had one missed match since I did it. (I uploaded the new version, so give it a go and let me know if you get a miss).

Oh, and I totally got the top score. Level 15 WAS INSANE.

n/a

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.