Template:tally time
From Homestar Runner Wiki
This template is used for tallying total time in a group of toons.
Usage:
{{ tally time | countername | number_of_seconds }}
- where countername is the name of the counter being used. This parameter is required.
- and number_of_seconds is the number of total length of the toon in seconds.
The template will do two things with this information:
- The counter countername will be incremented by number_of_seconds seconds. This counter will then be used to keep track of the total number of seconds for all toons in the group.
- The value number_of_seconds will be converted to "hh:mm:ss" format using the {{format seconds}} template.
IMPORTANT:
Please be sure to first reset the counter using the {{hresetcount}} template before making any calls to this template in order for this process to work correctly. This template initializes two counters: one to keep track of time in seconds and one to keep track of the total number of toon entries (used in calculating average running time). Both counters are initialized to 0. Here is the syntax:
{{hresetcount | countername | tally=1 }}
- Note that the
tally=1
parameter is mandatory! This tells the template that we need to initialize tally counters. For the countername the template will create a counter called countername_tally to track the total number of seconds and a counter called countername_count to track the total number of toon entries. - Multiple counters may be initialized using the {{hresetcount}} template. See {{hcount}} for more information.
Example:
{{hresetcount|sample|tally=1}} * {{tally time|sample|60}} * {{tally time|sample|33}} * {{tally time|sample|72}} * {{tally time|sample|192}} * Total time: {{display time|seconds}} seconds ({{display time|total}} in hh:mm:ss) {{dot}} Average: {{display time|average_seconds}} seconds ({{display time|average}} in hh:mm:ss) * Compare to the original mechanism {{--}} Total time: {{#count:sample_tally|0}} seconds / {{format seconds|{{#count:sample_tally|0}}}} for {{#count:sample_count|0}} entries
- 1:00
- 0:33
- 1:12
- 3:12
- Total time: 357 seconds (5:57 in hh:mm:ss) · Average: 89 seconds (1:29 in hh:mm:ss)
- Compare to the original mechanism — Total time: 357 seconds / 5:57 for 4 entries
See Also
- {{display time}} — Used to display various total values from tallies gathered by this template.
- {{format seconds}}
- {{hcount}}
- Counter function usage