container question

Get help using Construct 2

Post » Sun Jan 26, 2014 8:41 pm

i made a sprite and a containerobject text
created a couple of sprites...

if i do an for each sprite > set text to sprite.var
it doesn't show the var..

is this because, the for each doesn't pick a sprite?
or is it because the picked sprite doesn't pick the containerobject?
ImageImage
B
70
S
21
G
7
Posts: 827
Reputation: 10,052

Post » Sun Jan 26, 2014 8:53 pm

you don't even have to pick sprites, for the container takes care of that.

this should work:

system trigger once - text set text : sprite.var

if sprite.var exists that is.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Sun Jan 26, 2014 9:26 pm

yes thankyou, i tried some things in a new project and it works,
for each wasnt the issue, but was indeed not needed

it must be something how i structured the events, on start i create a sub for loop to create the sprites, and then under the loop i target the text and this didnt work

if i drag it to the toplevel it works
ImageImage
B
70
S
21
G
7
Posts: 827
Reputation: 10,052


Return to How do I....?

Who is online

Users browsing this forum: DrKoala, irina, mindragon73, zenox98 and 22 guests