# Shinning & replay

**URL:** <https://forum.kirupa.com/t/shinning-replay/57315>\
**Category:** Uncategorized\
**Created:** [July 12, 2004, 10:01am UTC](https://forum.kirupa.com/t/shinning-replay/57315 "2004-07-12T10:01:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jins](https://avatars.discourse-cdn.com/v4/letter/j/9de053/32.png) [@Jins](https://forum.kirupa.com/u/Jins)\
**Post date:** [July 12, 2004, 10:01am UTC](https://forum.kirupa.com/t/shinning-replay/57315/1 "2004-07-12T10:01:10Z")

</div>

hi all, wat should i write for the as to recount the number of btn have been clicked??cos this is used in a replay btn. i have btn for user to click n count how many time the btn have been clicked n show out the match image, so now another btn (replay)to let the user to see again the image so what should i write in the replay btn’s as to let the count of the times of btn have been clicked start . cos what i done now it can’t start to count again it just plus the number i have clicked for the btn.

Let’s say if the image just only have 3 so tat when i finish clicked 3 times all the image ady showed n now i click the replay btn but wat i get is wrong cos in the output box it still counting the number i have been click for the btn so it show 4,5,… it can’t start count again.

anyone who know pls tell me .

thanks

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 13, 2004, 10:34pm UTC](https://forum.kirupa.com/t/shinning-replay/57315/2 "2004-07-13T22:34:49Z")

</div>

try this:

count = 0;  
btn1.onPress = function () {  
//where btn1 is the name of ur button   
count++;

```
if (count &gt;= 3 ) {
count = 0;

```

}  
}

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 14, 2004, 1:24am UTC](https://forum.kirupa.com/t/shinning-replay/57315/3 "2004-07-14T01:24:04Z")

</div>

i have 2 types of button : 1 i using finger button tat cover all the page ,2 is using number 1,2,n3 button .

so the finger btn’s as is

```auto
  
on (rollOver) { 
   Mouse.hide(); 
   startDrag("track", true); 
} 
on (rollOut) { 
   Mouse.show(); 
   stopDrag(); 
   setProperty("track", _x, "850"); 
   setProperty("track", _y, "650"); 
} 
on (release) { 
   count++; 
   trace(count); 
   if (count == 0) { 
	  tellTarget ("1") { 
		 gotoAndPlay(1); 
	  } 
	   
   } 
   if (count == 1) { 
	  unloadMovie("1"); 
	  tellTarget ("1a") { 
		 gotoAndPlay(2); 
	  } 
	  b1.onRelease = function() { 
		 (count == 1); 
	  }; 
   } 
   if (count == 2) { 
	  gotoAndPlay(11); 
	  unloadMovie("1a"); 
	  tellTarget ("1b") { 
		 gotoAndPlay(2); 
	  } 
	  b2.onRelease = function() { 
		 (count == 2); 
	  }; 
   } 
   if (count == 3) { 
	  gotoAndStop(13); 
	  unloadMovie("1b"); 
	  tellTarget ("1c") { 
		 gotoAndPlay(2); 
	  } 
	  b3.onRelease = function() { 
		 (count == 3); 
	  }; 
   } 
} 

```

this is what i write for number(number 3’s btn name as b3) btn’s as

```auto
 
on (release) { 
   gotoAndStop(13); 
   count++; 
   trace(count); 
   count == 3; 
   unloadMovie("1b"); 
   tellTarget ("1c") { 
	  gotoAndPlay(2); 
   } 
} 
 

```

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 14, 2004, 2:20am UTC](https://forum.kirupa.com/t/shinning-replay/57315/4 "2004-07-14T02:20:52Z")

</div>

can u post ur fla?

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 14, 2004, 4:48am UTC](https://forum.kirupa.com/t/shinning-replay/57315/5 "2004-07-14T04:48:42Z")

</div>

hi, i try ur code in the replay btn n i add a line of code tat is delete.count();  
cos i think want to give it delete the count then start count again but it just can show me the number of the count only but it can load the movieclip.

G-shock,the fla file is too big can i send to ur mail??
