._name VS name

Hi ,
I am developing an application on flashcom. When I try to edit some flashcom component, I found some strange in the script.
In the connect function of AVPresence, there is code like:

this.username = username;
var pmc = this.component;

// CONFUSE these 2 lines
pmc._name = this._name;
pmc.name = pmc._name;
// CONFUSE

pmc.prefix = “FCAVPresence.” + pmc.name + “.”;
this.component = pmc;
this.component.soName = this._parent._name + “presence”;
this.component.connect(nc);

is it difference about .name and ._name???
what is the difference??

not a wizard here but as I see it…

‘name’ is a variable that has to get assigned a value.

‘_name’ is a property just as ‘_width’, ‘_scale’ or ‘_x’

O…the “name” is a variable only??

Yeah, name is no set feature in Flash so therefore it thinks it is just a regular variable.

_name is a property in Flash so you need to use that.

Trace this…

Create a movie clip on the stage… Give it the instance name “mc” (no quote).

Right click on the clip and open the actions panel.

Apply these actions…

onClipEvent (load) {
	trace(this.name);
	trace(this._name);
}

When you test the movie it will output…

undefined
mc

Now try this…

onClipEvent (load) {
	name = "Variable";
	trace(this.name);
	trace(this._name);
}

When you test the movie the output will be…

Variable
mc

Be careful listining to lostinbeta, he is a little self serving and misleading

*Originally posted by rynoe *
**Be careful listining to lostinbeta, he is a little self serving and misleading **

You know what <B>rynoe</B> I am tired of your crap. I don’t have a clue what you have against me, but it’s getting old. It isn’t my fault you are rude to new members.

Why you keep starting with me I don’t know, but frankly, I don’t really care man.

This is your first ban warning. It was discussed with the mods and agreed upon that if you keep instigating fights (given rights by kirupa himself after reading some of the arguments you caused), we have the right to ban you. So either clean up your act now or get out, the choice is yours and these are your only options. We dont tolerate @$$holes here thank you very much.

NOTE TO CATALAS: Rynoe is the forum trouble starter so don’t think this is the first time.