Pick by UID Not Working

Get help using Construct 2

Post » Thu Oct 17, 2013 6:35 am

Here is my issue: I am trying to pick instances using values of their UID that I have stored in an array, but no instances are ever picked.

This is the code I have so far, which is supposed to work as so:

Player clicks glyph A, if there are any B glyphs to the right or left, change those to C glyphs.



I have found out that reading the value of the array at position (X, 1) reads properly and I can set its value, however, the "pick instance" function never picks an instance and thus the proper frame of animation is never set (which represents a "change" in the glyph).

I have tried commenting the deletion of the index at Level.CurX, but that has no effect on the object I am trying to delete.

In fact, nothing seems to make it pick even incorrect glyphs by their UID, as I noted when I tried to simply destroy the instances to see if there was anything happening.

The reason I have not linked any files is because there is nothing else to note that would have an effect on the code there. Every bit of what I am trying to do goes in that section.

Any suggestions?
ImageImageImageImage
B
62
S
19
G
51
Posts: 633
Reputation: 30,826

Post » Thu Oct 17, 2013 6:41 am

Pick all glyph before you pick specified instance again.

Explanation:
On click: glyph 1 is picked (SOL has 1 glyph instance)
-glyph 1 destroy
--no glyph in SOL
---try picking by uid (which will look through the SOL which is empty)

I hope my explanation is correctc4sp3r892013-10-17 06:47:36
B
17
S
8
G
4
Posts: 93
Reputation: 3,190

Post » Thu Oct 17, 2013 6:47 am

Oh! I think I get it now. :) I will try again in the morning when my head is clear. Thanks for the tip!
ImageImageImageImage
B
62
S
19
G
51
Posts: 633
Reputation: 30,826


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 5 guests