vendredi 3 février 2017

AS3 - Interactive Bingo Grid

I'm working on a Flash project that will be used to display numbers that are called for a game of Bingo. A person will control the board being displayed to a live audience by clicking on one of 75 "covered" tiles. Upon click of a tile (ex: button1), 3 things need to happen:

1) the click triggers a short MovieClip (ex: Number1) animation that takes up most of the screen showing "1"

2) the MovieClip (Number1) unloads itself and we see the grid again

3) The tile covering the "1" on the grid is removed so that we see which numbers have been called

I have the following code that is working correctly to remove the individual [!tiles upon click:

button1.addEventListener (MouseEvent.CLICK, Reveal1);
function Reveal1(event:MouseEvent) {

if (button1.alpha == 1){
  button1.alpha = 0;} else {button1.alpha = 1}

What is the simplest way for me to load/unload a MovieClip for each of the 75 numbers when their respective tiles are clicked?

enter image description here

Aucun commentaire:

Enregistrer un commentaire