Objects name in family?

For questions about using Classic.

Post » Tue Aug 23, 2011 11:34 pm

I am wondering if there is a way to use an objects name as a family event somehow,like for example:
Blue: Object name is "Player"
-Blue: "Destroy"
and if so. how.

Thanks in advance.
B
6
S
1
G
1
Posts: 69
Reputation: 1,019

Post » Wed Aug 24, 2011 12:06 am

Pretty sure theres no event that lets you retrieve the name of an object. In the layout editor you could just give the object a string variable with the initial string being its name. Then compare the variable in the event sheet to do whatever.
B
141
S
68
G
17
Posts: 1,769
Reputation: 20,124

Post » Wed Aug 24, 2011 5:57 pm

You can do it with OID which is unique for each object type. When you get the OID of a family you get the OID of it's actual type.

ex:
+ Blue: Pick by Blue.OID Equal to Sprite.OID
-> Blue: Destroy
B
88
S
30
G
89
Posts: 5,113
Reputation: 60,337

Post » Thu Aug 25, 2011 12:10 am

Ah i see. Cool, thanks !
B
6
S
1
G
1
Posts: 69
Reputation: 1,019


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests