# Building a bubble puzzle game

**URL:** <https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112>\
**Category:** programming\
**Created:** [May 23, 2008, 8:43am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112 "2008-05-23T08:43:40Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![chup](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/chup/32/925_2.png) [@chup](https://forum.kirupa.com/u/chup)\
**Post date:** [May 23, 2008, 8:43am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/1 "2008-05-23T08:43:40Z")

</div>

Hi people, I need to build a game that is similar to bubble puzzle game play, but have no idea how to start.

Try googling but didn’t get any useful result.

Anyone know of any tutorial or reference on when I can draw on to build a flash game around the same game play of bubble puzzle?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![t0w](https://avatars.discourse-cdn.com/v4/letter/t/ac8455/32.png) [@t0w](https://forum.kirupa.com/u/t0w)\
**Post date:** [May 23, 2008, 9:31pm UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/2 "2008-05-23T21:31:42Z")

</div>

Link to what you are talking about or more explanation? How does this game function?

---

<div class="post-metadata">

**Author:** ![bpalermo](https://avatars.discourse-cdn.com/v4/letter/b/9dc877/32.png) [@bpalermo](https://forum.kirupa.com/u/bpalermo)\
**Post date:** [May 23, 2008, 10:20pm UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/3 "2008-05-23T22:20:08Z")

</div>

What is a Bubble Puzzle?

Did you mean ‘Bubble Bobble’?  
 ![](http://66.232.99.210/images/bubble-bobble-2-big.jpg)

‘Bubble Trouble’?  
 ![](http://forum.kirupa.com/uploads/kirupa/6894/ea84a247715b2245.jpg)

Or maybe ‘Bubble Bash’?  
 ![](http://bp0.blogger.com/_6CFzAgQ131w/RzsOsMMDODI/AAAAAAAAAEw/_1O2dSbkv6A/s400/bubble+bash+2.gif)

=)

---

<div class="post-metadata">

**Author:** ![rrh](https://avatars.discourse-cdn.com/v4/letter/r/67e7ee/32.png) [@rrh](https://forum.kirupa.com/u/rrh)\
**Post date:** [May 23, 2008, 10:59pm UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/4 "2008-05-23T22:59:35Z")

</div>

I think the latter. Look up Puzzle Bobble, aka. Bust-a-move. There’s also one called Snood.

I’m not aware of any tuts on that game.

---

<div class="post-metadata">

**Author:** ![chup](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/chup/32/925_2.png) [@chup](https://forum.kirupa.com/u/chup)\
**Post date:** [May 24, 2008, 4:05am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/5 "2008-05-24T04:05:02Z")

</div>

yeah bust a move, something like this link  
[http://www.ventoline.com/frozenbubble/bustamove640.html](http://www.ventoline.com/frozenbubble/bustamove640.html)

any idea how sld i start creating 1?

---

<div class="post-metadata">

**Author:** ![bluemagica](https://avatars.discourse-cdn.com/v4/letter/b/a4c791/32.png) [@bluemagica](https://forum.kirupa.com/u/bluemagica)\
**Post date:** [May 24, 2008, 4:59am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/6 "2008-05-24T04:59:04Z")

</div>

umm, it all depends on your level of programing actually…each ball when created needs to be “can\_check=true”; mode, and also it needs some properties like “ball\_id;ball\_color; ball\_num\_of\_hit; ball\_direction” etc…so on collision with another ball it sets its movement speed to 0, and if its movement speed is 0, then use a for loop, to go around it in every direction and if the ball it hits is of same color and num\_of\_hit in this ball or other is more than 2(colliding with two other) then just grab their id, and remove them. and if there is not enough collision, then set can\_check=false.

Thats the basic idea, now there are many ways to implement it.  
[http://openglgui.sourceforge.net/tetris\_tut5.html](http://openglgui.sourceforge.net/tetris_tut5.html) …that is not in actionscript, but if you go through the code and comments, you will understand the working.

---

<div class="post-metadata">

**Author:** ![neilmmm](https://avatars.discourse-cdn.com/v4/letter/n/ee7513/32.png) [@neilmmm](https://forum.kirupa.com/u/neilmmm)\
**Post date:** [May 25, 2008, 11:17pm UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/7 "2008-05-25T23:17:40Z")

</div>

sorry for hi jacking someone else’s thread

but making a bust-a-move game seems really quite fun

so of course it is very easy to attach a row bubbles, make each bubble a diiferent colour,give each bubble a colour var, offset each row, easy enough to fire a bubble with a colour

snapping the bubble to an isometric grid is tricky but i reckon i could do that

**but i am at a loss how to check the fired bubble to the bubbles it touches and then the ones that one touches that one to see if they have the same colour var - particularly as it isometric - and to see if 3 or more are the same colour -**

any ideas how to get started with this?

thanks neil

---

<div class="post-metadata">

**Author:** ![rrh](https://avatars.discourse-cdn.com/v4/letter/r/67e7ee/32.png) [@rrh](https://forum.kirupa.com/u/rrh)\
**Post date:** [May 26, 2008, 5:47am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/8 "2008-05-26T05:47:27Z")

</div>

Create an array and push your starting point onto it. For each of the six grid points surrounding that starting point, check if they 1) contain a matching bubble and 2) are not already on the array. If they are good, then do the same thing to them. (Push them onto the array and check the 6 spots around them.)

After this finishes, then you should have an array of the matching group.

---

<div class="post-metadata">

**Author:** ![neilmmm](https://avatars.discourse-cdn.com/v4/letter/n/ee7513/32.png) [@neilmmm](https://forum.kirupa.com/u/neilmmm)\
**Post date:** [May 26, 2008, 7:18pm UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/9 "2008-05-26T19:18:03Z")

</div>

thanks rrh ihad something like that in mind

just two thoughts

do you see the array as a multidimensional array - 1 element for each row

when one element checks, for eg, to the left and gets a match … when that one (the one on the left) it will of course match back to the right (a duplicate) how do you stop that?

neil

---

<div class="post-metadata">

**Author:** ![rrh](https://avatars.discourse-cdn.com/v4/letter/r/67e7ee/32.png) [@rrh](https://forum.kirupa.com/u/rrh)\
**Post date:** [May 27, 2008, 4:15am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/10 "2008-05-27T04:15:16Z")

</div>

You would have one array for the board. That could be 2-dimensional.

The array I was talking about would be only used for building a group of matching bubbles. To avoid double-counting is why you need to check if that bubble is already in the array.

---

<div class="post-metadata">

**Author:** ![neilmmm](https://avatars.discourse-cdn.com/v4/letter/n/ee7513/32.png) [@neilmmm](https://forum.kirupa.com/u/neilmmm)\
**Post date:** [May 27, 2008, 6:10am UTC](https://forum.kirupa.com/t/building-a-bubble-puzzle-game/261112/11 "2008-05-27T06:10:40Z")

</div>

ty rrh
