$duration » History » Version 7
Per Amundsen, 12/14/2019 08:16 AM
1 | 1 | Per Amundsen | _Added in 1.8.10_ |
---|---|---|---|
2 | |||
3 | 2 | Per Amundsen | *$duration* |
4 | 1 | Per Amundsen | |
5 | Returns the duration of the currently playing song in milliseconds. |
||
6 | |||
7 | 7 | Per Amundsen | _*AdiIRC only*._ |
8 | 1 | Per Amundsen | _Only works if Media Player is set to iTunes/MediaMonkey/Winamp and proper plugins are installed._ |
9 | 2 | Per Amundsen | |
10 | 5 | Per Amundsen | ----------------------------------------------------------------------------- |
11 | 2 | Per Amundsen | |
12 | *$duration(seconds,[N])* |
||
13 | |||
14 | Returns the specified number of seconds in a week/day/hour/minute/second format. |
||
15 | |||
16 | 6 | Per Amundsen | _See also [[$ctime]], [[$asctime]], [[$gmt]]._ |
17 | |||
18 | 2 | Per Amundsen | *Parameters* |
19 | |||
20 | 4 | Per Amundsen | seconds - Number of seconds or a [[$duration]] value to convert back into seconds. |
21 | 1 | Per Amundsen | N - If N = 2, the result does not include the seconds value. If N = 3, the result is in hh:nn:ss format. |
22 | 4 | Per Amundsen | |
23 | *Example* |
||
24 | |||
25 | <pre> |
||
26 | ; Print current date using $ctime. |
||
27 | //echo -ag $duration($ctime) |
||
28 | |||
29 | ; Do a reverse duration. |
||
30 | //echo -ag $duration(42wks 5days 11hrs 53mins 43secs) |
||
31 | </pre> |