Get text from instance

Get help using Construct 2

Post » Mon May 14, 2012 9:21 pm

Hey guys,
I'm looking for a way to get text from an instance of a text object (by iid or uid)... ?
Thx
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987

Post » Mon May 14, 2012 9:30 pm

Use the condition "System -> Pick nth instance", and the expression TextObject.Text to get the text from the instance.

Edit: Quick .capxNimtrix2012-05-14 21:34:52
B
27
S
8
G
8
Posts: 903
Reputation: 8,452

Post » Mon May 14, 2012 11:00 pm

The index is available to all objects text(index).text. IE text2 set text to text1(text2.iid).text....
And lions and tigers, and bears, oh my.
Image ImageImage
B
169
S
50
G
173
Posts: 8,316
Reputation: 110,276

Post » Tue May 15, 2012 5:19 pm

if you know the name of the text instance you want to get it from just use its name?
B
13
S
5
G
2
Posts: 306
Reputation: 3,262

Post » Tue May 15, 2012 5:45 pm

Thanks all of you guys.
The newt's solution was the one I needed.
Solved ;)
Passionate developer

If my work helped you to make your project, please consider making a donation :)
B
44
S
12
G
14
Posts: 631
Reputation: 10,987


Return to How do I....?

Who is online

Users browsing this forum: 25games, Ashley, mcscooter, TRMG and 33 guests