
Welcome Guest
|
#1
|
||||
|
||||
|
I make a MovieClip A , it contain action below .
Actionscript:
onClipEvent (load) {
xm=0
ym=0
alive=0
_visible = false;
}
onClipEvent (enterFrame) {
if (alive) {
_visible = true;
this._x = this._x+xm
this._y = this._x+ym
if(this._x>600){
alive = 0}
} else {
_visible = false;
}
}********************************************** And I make another MovieClip B to duplicate the above MovieClip , and give some variable to the new duplicate Movie , like "alive" ,"xm" , "ym" . See the script below . Actionscript:
onClipEvent (enterFrame) {
xmov = 10;
ymov = 10;
if (Key.isDown(Key.SPACE)) {
count += 1;
_root.star.duplicateMovieClip("starr"+count, count);
_root["starr"+count]._x = this._x;
_root["starr"+count]._y = this._y;
if (_root["starr"+count].alive == 0) {
with (_root["starr"+count]) {
xm = xmov;
ym = ymov;
alive = 1;
_root["starr"+count]._x = this._x;
_root["starr"+count]._y = this._y;
}
}
}
}************************************************** But I get a problem , the MovieClip B can't give "alive" , "xm" ,"ym" to the duplucate MovieClip . And I can't get the duplucate MovieClip with "_root["starr"+count].alive" . How can i send var to duplucate MovieClip from MovieClip B and get duplucate MovieClip variable with MovieClip B ![]() Thank You !!! Download file |
«
Previous Thread
|
Next Thread
»
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| linking buttons. help, going crazy | time808 | Newbies |
1 | 08-18-2004 09:58 PM |
| Why does my game lag like crazy | lumps2385 | Flash MX ActionScript |
2 | 03-19-2004 06:25 PM |
| Crazy Elk Games | CrazyElk | Cool Sites |
1 | 03-28-2003 08:13 PM |
| crazy idea ??? | Pepper | Newbies |
4 | 11-15-2002 03:53 PM |
| crazy pop menu - trble with get url | asif_rn | Flash 5 Actionscript |
2 | 08-18-2001 07:25 AM |





