# Somethings wrong with my \_root

**URL:** <https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255>\
**Category:** Uncategorized\
**Created:** [November 12, 2003, 12:50am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255 "2003-11-12T00:50:05Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![HeeT](https://avatars.discourse-cdn.com/v4/letter/h/e9a140/32.png) [@HeeT](https://forum.kirupa.com/u/HeeT)\
**Post date:** [November 12, 2003, 12:50am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/1 "2003-11-12T00:50:05Z")

</div>

ive searched the forums, and google, and nothing seems to be wrong:

[AS]on (rollOver) {  
\_root.oldman.gotoAndPlay(“1”);  
}  
[/AS]

the buttons are in their own movie clip, and so is oldman… i just cant figure it out :h:

thanks in advance

---

<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:** [November 12, 2003, 3:28am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/2 "2003-11-12T03:28:48Z")

</div>

make it like this  
\_root.the movie clip oldman is in.oldman.gotoAndPlay(“1”);  
remember \_root always and im mean ALWAYS refers to the main timeline.

---

<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:** [November 12, 2003, 11:31am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/3 "2003-11-12T11:31:40Z")

</div>

> \*Originally posted by Booyaka \*  
> \*\* \_root always and im mean ALWAYS refers to the main timeline. \*\*

Only if the \_root in question is on \_level0 e.g. if I load a sound clip into \_level3 and call \_root from within the loaded clip then it will reference \_level3 not \_level0

---

<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:** [November 13, 2003, 3:09am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/4 "2003-11-13T03:09:21Z")

</div>

oh yeah.  
lol doh  
nice catch jsk.

---

<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:** [November 13, 2003, 9:47pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/5 "2003-11-13T21:47:28Z")

</div>

> \_root.the movie clip oldman is in.oldman.gotoAndPlay(“1”);

well the thing is, oldman is the movie clip, oldman isnt really in anything cept oldman

---

<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:** [November 13, 2003, 9:57pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/6 "2003-11-13T21:57:24Z")

</div>

gotoAndPlay(“1”) will gotoAndPlay a frame label, and frames cannot be given labels that are just numbers.

gotoAndPlay(1) however will gotoAndPlay frame #1 of that clips timeline.

Hope this info helps.

---

<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:** [November 14, 2003, 12:17am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/7 "2003-11-14T00:17:58Z")

</div>

UUUURRRRRRRGGGGGGGGGGG!!!  
What does \_root do??? What are levels? The layers? I’ve looked in the references… but I still don’t get it! Someone  
please help me =(

---

<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:** [November 14, 2003, 12:28am UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/8 "2003-11-14T00:28:23Z")

</div>

[http://www.kirupa.com/developer/actionscript/tricks/root\_parent\_this.htm](http://www.kirupa.com/developer/actionscript/tricks/root_parent_this.htm)

Basically:

\_root = First timeline in the hierarchy

\_parent = 1 timeline up in the hierarchy from the timeline you are currently on

this = timeline you are currently on

---

<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:** [November 14, 2003, 12:53pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/9 "2003-11-14T12:53:11Z")

</div>

beta, thanks for that, its a good thing to know,  
but with or without the quotation marks, it still won’t work… i have the \_root command working other places in the site, but for some reason it wont work here

---

<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:** [November 14, 2003, 1:58pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/10 "2003-11-14T13:58:42Z")

</div>

Odd.

Can you post up a .fla so we can have a look?

BTW: As a recommendation as you get used to targeting, I recommend relative addressing using \_parent and such, this makes your code more portable and it will still work when you load that movie into another movie.

---

<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:** [November 14, 2003, 2:01pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/11 "2003-11-14T14:01:04Z")

</div>

yea sure, the .fla is real big and ugly right now ( far from done ) but ill have it up in a few minutes

---

<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:** [November 14, 2003, 2:17pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/12 "2003-11-14T14:17:02Z")

</div>

ok, here it is: [newsite17.fla](http://www.doosdesigns.com/newsite17.fla)

try making any button goto the oldman

---

<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:** [November 14, 2003, 2:22pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/13 "2003-11-14T14:22:44Z")

</div>

You never gave your oldman clip an instance name.

You need to right click on the stage and open the properties panel, and in there give it the instance name “oldman” (no quotes)

Instance names are incredibly useful because instead of it targeting a clip name, it targets the instance name, therefore you can have more than once instance of the clip out at 1 time and target them seperately.

---

<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:** [November 14, 2003, 2:45pm UTC](https://forum.kirupa.com/t/somethings-wrong-with-my--root/35255/14 "2003-11-14T14:45:48Z")

</div>

ah, i got the instance name confused with the movie clip name,  
thanks alot for the help :player:
