Grasshopper

algorithmic modeling for Rhino

trigger timer component on user event (boolean?)

Hi,

I hoping to get some insight as to how can I run the timer component based on an user event (button pressed, boolean, etc) or if there is a similar component to timer that will make other components fire at a specific time/event.

I currently have the UDP sender(gHowl node) broadcasting messages at a set intervals set in the timer component, however it would be best if I could only broadcast when the user has change something in the model rather then send it all the time.

Is this something possible?

Thank you

G

Views: 4006

Replies to This Discussion

It's possible, certainly, but any specific code would really depend on the sort of change you wish to respond to. Can you narrow it down to one specific example?

Thank you, yes. 

This is what I currently have .                                                                                                       Ideally the Boolean received from the udp listener would trigger or fire  the runtime component. I guess what I'm asking is for a mechanism to fire or make the UDP component to run once or for x mount of time

Another example could be that the UDP component only runs when the geometry has changed or modified.

I would really appreciate your help.

Thanks

Any help on this would be greatly appreciated!

hold on. i guess i have a Solution for this. im using something similar packed in a Plug-in i'm developing... some time is needed to extract the code...

Here's a simple script for toggling the "Locked" flag on all timers on the canvas (which will enable/disable the timers updating using a Boolean toggle). Might help..

Attachments:

Thank you Anders for taking the time to share this. 

I will try your definition and share the results

Here we go...
Let me know if its useful...

Category:  "Params" -> "Util"


NOTE: The Timer has to be connected to the component to work...

Attachments:

Thank you Ortler for taking the time to share this. 

I will try your definition and share the results. I will make sure to provide any feedback on your plugin

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service