Hi there,
I have a running project, where I was wondering if there is an easy way to animate an timer on a bomb through the fonts node?
Any suggestions?
Many thanks,
Timer Clock with animating the channel in fonts node
1790 3 1-
- VTVADSMU
- Member
- 3 posts
- Joined: Nov. 2021
- Offline
-
- ajz3d
- Member
- 654 posts
- Joined: Aug. 2014
- Offline
-
- VTVADSMU
- Member
- 3 posts
- Joined: Nov. 2021
- Offline
Thanks for your suggestions! Is there any way to add kind of timecode in the text parameter?
ajz3d
Of course. One of the possible ways is to use Python expression inside the Text parameter.
For example:It must always return some value.target_seconds = 5 second = target_seconds + 1 - (hou.frame() / hou.fps()) if second > 0: return int(second) else: return 0
-
- ajz3d
- Member
- 654 posts
- Joined: Aug. 2014
- Offline
Python's time [docs.python.org] module might be a good starting point. And if you don't want to use it, you can accomplish the task with some math and string concatenation. There are a lot of examples on the Internet covering the creation of countdown timers in Python.
-
- Quick Links

