Jump to content
nguyenvuquocan

Get An Attribute equal to Frame

Recommended Posts

Hi all master . I have a question . For example , i have a point , this point unhide at Frame 173 or 250 or a random frame . How can i get an attribute equal at this Frame ?. And if i have many points , how can i get it for every points ?  .

Please check image in bellow . 
Thank you . 
Untitledb3de13dc619a61ad.png

Edited by nguyenvuquocan

Share this post


Link to post
Share on other sites

Hi, not a pro but you can add a attribute wrangle and initialize a new attribute with an empty parameter (remember to create the channel by press that button on the right side). Then under the channel type in $F to fill in the attribute.

Share this post


Link to post
Share on other sites

Not sure if this is what you are asking but if you want to save a frame or time when something happens for the first time this is a simple way to do it:

Let say you want to save the frame when a point reaches a certain height. First set  with attribute create or wrangle:

i@theFrame = -1;

then in another wrangle:

if(i@theFrame<0 && @P.y> someHeight) @theFrame = @Frame;

the theFrame attrib will only be set to hold the frame number one time: when the is greater than the threshold and it hasn't already been set

Share this post


Link to post
Share on other sites
On 1/5/2021 at 7:51 AM, lugnut said:

Not sure if this is what you are asking but if you want to save a frame or time when something happens for the first time this is a simple way to do it:

Let say you want to save the frame when a point reaches a certain height. First set  with attribute create or wrangle:


i@theFrame = -1;

then in another wrangle:


if(i@theFrame<0 && @P.y> someHeight) @theFrame = @Frame;

the theFrame attrib will only be set to hold the frame number one time: when the is greater than the threshold and it hasn't already been set

Thank for help bro . But @Frame is alway change . 
 I mean if i hava a point , this point has an attribute : A . And when Frame < 50  A = 0 . when Frame >= 50 A = 1 . And when A = 1 , has an attribute B and this attribute return 50. 
Sorry because my skill english so bad :'(  .  Hope you understand what i say . 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×