# Snap

**URL:** https://forum.kirupa.com/t/snap/279285
**Category:** flash
**Created:** [January 12, 2009, 10:13pm UTC](https://forum.kirupa.com/t/snap/279285 "2009-01-12T22:13:26Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![randomagain](https://avatars.discourse-cdn.com/v4/letter/r/35a633/32.png) [@randomagain](https://forum.kirupa.com/u/randomagain)
#### Post date: [January 12, 2009, 10:13pm UTC](https://forum.kirupa.com/t/snap/279285/1 "2009-01-12T22:13:26Z")

</div>

Any niffy suggestion on creating a snap game?

I want the press button to detect the last button pressed and if the shapes match, make them do something…obviously.

I think I’m going at it the wrong way.

I need to stick a “triange” id into the button/mc then if compares that and then if there is a match works then… right?

```auto
if(zum>1 && zum<=3){
        
        ab[cb] = i
        cb=cb+
    }
    if(zum>3 &&zum<5){
        ac[cc] = i
        cc=cc+
    }
    if(zum>5 &&zum<7){
        ad[cd] = i
        cd=cd+
    }
    if(zum>7 &&zum<9){
        ae[ce] = i
        ce=ce+
    }
    if(zum>9 &&zum<11){
        af[cf] = i
        cf=cf+
    }
    if(zum>11 &&zum<13){
        ag[cg] = i
        cg=cg+
    }
    if(zum>13 &&zum<15){
        ah[ch] = i
        ch=ch+
    }
    if(zum>15 &&zum<17){
        ai[ci] = i
        ci=ci+
    }
    if(zum>17 &&zum<19){
        aj[cj] = i
        cj=cj+
    }
    if(zum>19 &&zum<21){
        ak[ck] = i
        ck=ck+
    }
    if(zum>21 &&zum<23){
        al[cl] = i
        cl=cl+
    }

```
