![]() |
|
||||||||||
|
|||||
|
Регистрация: Aug 2004
Сообщений: 31
|
Работает ли attachMovie() внутри муви клипа ?
----------- menu_2 = new Array (); for (w=1;w<=10;w++) { sy+=21; menu_2[w]=_root.attachMovie("button", "butt"+w, depth2++); menu_2[w]._y=sy; menu_2[w]._x=220; } ------------ |
|
|||||
|
Регистрация: Aug 2004
Сообщений: 31
|
В смысле ? =(
|
|
|||||
|
Негуру
администратор
Регистрация: Jan 2000
Адрес: Кёнигсберг in Moscow
Сообщений: 21,883
Записей в блоге: 7
|
Ты читал в хелпе описание attachMovie? Если читал то должен был заметить, что данный метод ничего не возвращает.
А ты пытаешь его присвоить какойто переменной ))) Вернее засунуть в массив не понятно что, да еще этому массиву координаты задать. |
|
|||||
|
Регистрация: Aug 2004
Сообщений: 31
|
Он возвращает путь к мувику
|
|
|||||
|
Регистрация: Aug 2004
Сообщений: 31
|
Да, но вопрос - почему это не работает внутри мувика ?
|
|
|||||
|
.
|
MovieClip.attachMovie()
Availability
Flash Player 5.
Usage
my_mc.attachMovie(idName, newName, depth [, initObject])
Parameters
idName The linkage name of the movie clip symbol in the library to attach to a movie clip on the Stage. This is the name entered in the Identifier field in the Linkage Properties dialog box.
newname A unique instance name for the movie clip being attached to the movie clip.
depth An integer specifying the depth level where the SWF file is placed.
initObject (Supported for Flash Player 6 and later) An object containing properties with which to populate the newly attached movie clip. This parameter allows dynamically created movie clips to receive clip parameters. If initObject is not an object, it is ignored. All properties of initObject are copied into the new instance. The properties specified with initObject are available to the constructor function. This parameter is optional.
Returns
A reference to the newly created instance.
Description
Method; takes a symbol from the library and attaches it to the SWF file on the Stage specified by my_mc. Use removeMovieClip() or unloadMovie() to remove a SWF file attached with attachMovie().
Example
The following example attaches the symbol with the linkage identifier "circle" to the movie clip instance, which is on the Stage in the SWF file.
on (release) {
thing.attachMovie( "circle", "circle1", 2 );
}
See also
MovieClip.removeMovieClip(), MovieClip.unloadMovie(), Object.registerClass(), removeMovieClip()
|
|
|||||
|
Регистрация: Aug 2004
Сообщений: 31
|
for (w=1;w<=10;w++) { }
Потому что их 10ть И с ними потом тоже надо что то делать |
![]() |
Часовой пояс GMT +4, время: 00:35. |
|
|
« Предыдущая тема | Следующая тема » |
|
|