Jump to content

Vops For Loop


Recommended Posts

Hi, I am trying to add an attribute within a for loop in vops. I use the expression `strcat("partner_","")` to combine the two strings but this is where my problem comes. For the second string I want to have the current for loop iteration. I created an integer outside of the for loop and add 1 every time it goes through loop. How can I access this value in the for loop? I tried hooking it to a float to vector and refrencing it using ch() but that didn't work.

Is there an expression to access the inputs and outputs of vops nodes (the sub-input inside the for loop)?

Edited by stephenl
Link to comment
Share on other sites

Thanks for the link, I didn't know that initial value was the current iteration. How can I access the initial value as an attribute name? I can't wire the value to the attribute name input because I need a prefix and it is the wrong data type anyways. I try ch("../initial_i") and initial_f, but they both return zero because the access the set values of the for loop not the iteration, but I know the initial value in the subnet input returns the correct number because i tested it. I might be able to do it by adding a custom parameter to the addattribute and making it able to be connected (seems impossible) or by accessing the subnet input values but like I've said they dont appear in ch()

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...