# Do while condition is false, or someting like that?

**URL:** <https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401>\
**Category:** Uncategorized\
**Created:** [October 6, 2002, 4:00pm UTC](https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401 "2002-10-06T16:00:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sintax321](https://avatars.discourse-cdn.com/v4/letter/s/d78d45/32.png) [@sintax321](https://forum.kirupa.com/u/sintax321)\
**Post date:** [October 6, 2002, 4:00pm UTC](https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401/1 "2002-10-06T16:00:37Z")

</div>

I trying to build a loop so that One MC won’t play untill the other MC has \_visible = false. This delay would alow my one MC to play it’s close animation before the next called for MC would play its opening animation. I will PM a zipped FLa to anyone who wants to see the set up I have so far.

PS I tried:  
do{  
\_root.loading.\_visible = true;  
while{(\_root.window1.\_visible = true)  
\_root.window2.\_visible = true;  
\_root.window2. gotoAndPlay (2);

And it caused my compuer to come up with a warning saying the code would take a long time to execute do you want to abort.:-\

---

<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:** [October 6, 2002, 4:31pm UTC](https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401/2 "2002-10-06T16:31:01Z")

</div>

I would just use  
if(mymovieclip.\_visible = false) {  
do something;  
}  
=):crazy:

---

<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:** [October 6, 2002, 5:10pm UTC](https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401/3 "2002-10-06T17:10:34Z")

</div>

will that make it loop until the condition is met?

---

<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:** [October 6, 2002, 5:32pm UTC](https://forum.kirupa.com/t/do-while-condition-is-false-or-someting-like-that/6401/4 "2002-10-06T17:32:31Z")

</div>

Put the test in an enterFrame. If you put it in a do while loop, you’ll stay on the same frame all the time, hence the error message.

pom :asian:
