String.FormattedTime
From GMod Wiki
| Function | |
| Syntax |
String.FormattedTime( String TimeInSeconds, String Format ) Where is this used? |
| Description: | |
| Given a time in seconds, returns formatted time. | |
| Returns: | String FormattedTime |
| Part of Library: | String |
| Realm: |
|
| BBCode Link: | [b][url=http://wiki.garrysmod.com/?title=String.FormattedTime]String.FormattedTime [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
| Description | One of many examples of how to use string.FormattedTime |
|---|---|
| Used on | |
| Code | string.FormattedTime( 123.456, "%02i:%02i:%02i") |
| Output | "02:03:45" |
| Description | One of many examples of how to use string.FormattedTime |
|---|---|
| Used on | |
| Code | string.FormattedTime( 123.456, "%02i:%02i") |
| Output | "02:03" |
| Description | One of many examples of how to use string.FormattedTime |
|---|---|
| Used on | |
| Code | string.FormattedTime( 123.456, "%2i:%02i") |
| Output | "2:03" |
| Description | One of many examples of how to use string.FormattedTime |
|---|---|
| Used on | |
| Code | string.FormattedTime( 123.456 ) |
| Output | {h = 0, m = 2, s = 3, ms = 45} |