View Full Version : easy breezy: replaceing symbols
annoying n00b
08-09-2003, 01:00 AM
say we have two symbols, and i want to replace them with each other along the time line.
both are linked for export, or however you say it.
i tried this: sub1.attachMovie("Symbol 2", "sub2", 0)
sub2.attachMovie("Symbol 1", "sub1", 0)
but that puts symbol 2 in a depth called _level0.sub1.sub2
i also just tried loadMovie("Symbol 2", sub1) but that was a catastrophy.
..sooo... how do i go about replacing them?
(and why do i find it easier to load external movieclips than replace internal ones?)
Billy T
08-09-2003, 04:09 AM
first method should work fine
if you attach clip B to clip A at the same depth that clip C was previously attached then clip C should be replaced
why what does it do?
also, not sure if spaces in your linkage names are a good idea...might be fine though
cheers
annoying n00b
08-09-2003, 04:47 AM
clip C..?
O_O
...
it works! thanks!
i was just using two clips, A to attach B. having three clips is a git more logical i guess :P
it makes a pretty ugly address, it as long as it works i guess.
annoying n00b
08-09-2003, 06:33 AM
ok, things are getting crazy again.
on the main timeline is a symbol called "preb". it's called preb because it's the pre-button. the symbol that will bring to life the set of buttons that it is to load.
the code is simple.preb.attachMovie("rest", buttons, 0); but it produces strange results. in the "rest" clip is a series of buttons. rest clip has a trace(this) statement (is that the right word?) so i could figure out the address. the result is _level0.preb. ... when i looked at the object list to find the buttons, i get things like Button: Target="_level0.preb..button_info"
why are those two periods there? because of them i can't address the buttons in things like onRelease statements.
i tried _level0.preb.button_info.onRelease = function() { but that doens't work. and if i try putting those two dots in there i get the error Expected a field name after '.' operator.
... ::cries::
Billy T
08-09-2003, 07:06 AM
try
preb.attachMovie("rest", "buttons", 0);
cheers
annoying n00b
08-09-2003, 07:28 AM
:D
sillly me, i should have seen that...
|
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.