I indeed have read about containers, but got it the wrong way. By saying take one object, create a container and then add more objects, I thought it was kinda sub-events, one being parent, so my (wrong) underdtanding was:
-if I destroy troop (parent), arrow gets destroyed
-if I destroy arrow (child), troop stays.
So nothing about it. Just behaving as a regular group. Lesson learned!
No Worries mate
The issue about "calling" arrows is a matter of idiom. I meant that I could pick an arrow based on its troop IID and viceversa. They should be supposed to have the same IID. So if I have global variable ActiveTroop set to Troop.IID on touching that troop, picking its arrow would be pick nTH (ActiveTroop). It may serve for picking both troops and arrows without adding another variable, let's say ActiveArrow. Just thinking in advanced for future functions. Or some way of doing the arrow drag&drop method.
The purpose of the containers is to avoid what you trying to do "Adding More conditions" to pick the Arrow linked
This is how it works
if you Pick a Troop the Arrow gets Picked swell automatically
or
if you Pick an Arrow the Trop gets Picked swell automatically
so meaning if I pick a Trop I can straight away make Actions to Arrow as is on a container and C2/C3 knows to which arrow I'm talking about
Example I can do this:
Pick Troop By (Whatever Method you like)
Action: Set Arrow to (Whatever you like to Do)
you see I didn't need to Pick the Arrow by Variables or IID because comes automatically Picked with the Troop, they are always together and they get destroyed together and they get Picked together
Or I can do the vice-versa also:
Pick Arrow By (Whatever Method you like)
Action: Set Troop to (Whatever you like to Do)
you see I don't Pick any Trop by Variables or IID
If you don't want to use Containers and you prefer Picking by Variables I recommend the simplest method and secure by storing the UIDs on an "Instance Variable"
Create an instance Variable on Arrow, Example lets call it "Parent" as a variable Type a Number so you will do
On start of Layout:
For Each Troop:>>>>Action: Create Arrow >>>>Arrow Set "Parent" to Troop UID
Now you have linked them and if you need to Pick Arrow linked to a Troop you Do
Pick Troop By (Whatever Method you like)
Second Condition: Arrow.Parent = Troop UID >>>>>> Do your Actions
That's it
Picking by Nth they way you do is gonna give only troubles, Read Tutorials as I advise you they don't take long to finish them
When I talked about creating, I was stating the case in which I didn't add instances on the layout, yet creating them with events on runtime. To make sure their arrows are created in the same order and share IID. In my capx, there are two troops but only one arrow, so the other arrow has to be created 'by the container'.
I see what you mean