Advanced Usage of Instance Objects

Get help using Construct 2

Post » Tue May 29, 2012 5:10 am

I've passed two variables into an instance object.

InstanceName: Carrier
InstanceUID: 2

How do I combine that into an expression like this?

Set Position to:
MyObject.InstanceName(MyObject.InstanceUID).X
MyObject.InstanceName(MyObject.InstanceUID).Y

It should parse into something like: Carrier(2).X and Carrier(2).Y

But it's not taking it. I get a "Not a Behavior" error.

Let me know if this isn't making sense.

Thanks,

-TTaurian2012-05-29 05:10:53
Epic Space Online - Google it!
B
34
S
10
G
5
Posts: 165
Reputation: 6,637

Post » Tue May 29, 2012 1:35 pm

I'm not sure what you're trying to do - the 'InstanceName' expressions don't make much sense to me. Can you explain some more what you're attempting?

If you want to get expressions from an instance with a specific UID, add a subevent with a 'Pick by UID' condition, then in that event expressions will return results for that instance.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Tue May 29, 2012 5:22 pm

How do I pick a specific Instance by UID only? I have a number, I don't have the name of the object.

And if the UID number is unique, I shouldn't need the name of the object anyway.

When I create a sub event, I have to select the type of object first. How do I get around this and only find an instance by UID?

Taurian2012-05-29 17:25:12
Epic Space Online - Google it!
B
34
S
10
G
5
Posts: 165
Reputation: 6,637


Return to How do I....?

Who is online

Users browsing this forum: currypuff, makotto, Yahoo [Bot] and 22 guests