PDA

View Full Version : accessing objects within instances of components


daveash
08-12-2003, 11:52 AM
I have my stage, that has an instance of the avpresence component on it,

Basically there are several webcams, all share the same properties but I want one to be different

Right, I can get to some objects within the property using the following code:

_root.mainwebcam_cc.sit_button._x = 10; _root.mainwebcam_cc.sit_button._y = 132;

_root.mainwebcam_cc.seat_video._width = 180; _root.mainwebcam_cc.seat_video._height = 135;

mainwebcam_cc is the instance and sit_button and seat_video are objects within the component, be it buttons or movie clips

There are objects I want to move on the 3rd frame within the timeline (it may or may not get to frame 3 depending on certain things but if it does, I want to be able to move the objects) the above methods don't work, is there something else I need to do?

For example, camBtn_mc appears on frame 3 within the component but

_root.mainwebcam_cc.camBtn_mc._x = 10; doesn't do anything from on the main timeline

I have to do this outside of the component as if I try and position stuff from within the component it affects all instances and not just the one I need to concentrate on.

Dave