if drawnline.count = nodes.count-1:
pick nodes, nodes.number = 0 (or whatever you first one is): set next node x to nodes.x etc
as subevent of the event where you set nextnode (which you should set to on touch start instead of is touching to save performance (even if it is very minor))
all nodes connected:
if drawnline.count = nodes.count-1: do stuff to show that game is completed
(note: won't work if the line is supposed to skip inbetween)
Thanks, but I've found a better solution for me: creating an End Node (counting the last node as the end node)
Also, I tried "On touched object" instead of "Is touching object" before, but the results were not what I wanted: I've had to release the touch after reaching a new Node in order to progress to the next one <img src="smileys/smiley2.gif" border="0" align="middle" />
Why not add an invisible dot at location one that can be connected from 6 in this example. then when that dot is connected go to your completion routine... window music flashing etc.....
Thank you <img src="smileys/smiley1.gif" border="0" align="middle" />
This is the "solution" that I thought first:
"One possible way would be to create the last node exactly under first node and finish the game when the user connects the last node, but I don't like it (sounds like weak implementation)."
Yes, making an End Node (counting the last node as the end node) is the best solution for me since the "drawings" will not connect always the last node with the first node.
I was so fixed to connect the last node with the first one so I overlooked this possibility <img src="smileys/smiley2.gif" border="0" align="middle" />