From WikiChip
Difference between revisions of "mirc/identifiers/$timezone"
Maroonbells (talk | contribs) (Add'l Info) |
(Incorrect reference to $daylight twice when meant $timezone) |
||
Line 13: | Line 13: | ||
* i.e. $gmt($ctime) == $asctime($calc($ctime + $timezone)), and $asctime($calc(0 + $timezone)) is "Thu Jan 01 00:00:00 1970" except for people whose $timezone is negative because $asctime does not accept negative time values. | * i.e. $gmt($ctime) == $asctime($calc($ctime + $timezone)), and $asctime($calc(0 + $timezone)) is "Thu Jan 01 00:00:00 1970" except for people whose $timezone is negative because $asctime does not accept negative time values. | ||
* When you change your computer's timezone, the file date/times change, but mIRC's $ctime does not. $file($mircexe).mtime remains the same regardless of $timezone and $daylight values. | * When you change your computer's timezone, the file date/times change, but mIRC's $ctime does not. $file($mircexe).mtime remains the same regardless of $timezone and $daylight values. | ||
− | * $timezone changes when $daylight changes, so you'll find $timezone + $daylight remain the same total. In USA Eastern, you'll find that during the winter, $ | + | * $timezone changes when $daylight changes, so you'll find $timezone + $daylight remain the same total. In USA Eastern, you'll find that during the winter, $timezone is 18000 and $daylight is 0. In summer during Daylight/Summertime, $timezone drops by 3600 to 14400, and $daylight increases from 0 to 3600. |
== Example == | == Example == |
Latest revision as of 11:44, 9 September 2018
Commands & Identifiers
Basics
Events
Matching Tools
Data Storage
Control Structures
GUI Scripting
Sockets
Advanced Scripting
Additional Resources
Security
Other
$timezone returns the current timezone setting in seconds. Positive is West/Earlier than UTC, negative is East/Later than UTC.
Synopsis[edit]
$timezone
Parameters[edit]
None
Properties[edit]
None
Notes[edit]
- $timezone contains the seconds to subtract from UTC to match your computer clock time.
- i.e. $gmt($ctime) == $asctime($calc($ctime + $timezone)), and $asctime($calc(0 + $timezone)) is "Thu Jan 01 00:00:00 1970" except for people whose $timezone is negative because $asctime does not accept negative time values.
- When you change your computer's timezone, the file date/times change, but mIRC's $ctime does not. $file($mircexe).mtime remains the same regardless of $timezone and $daylight values.
- $timezone changes when $daylight changes, so you'll find $timezone + $daylight remain the same total. In USA Eastern, you'll find that during the winter, $timezone is 18000 and $daylight is 0. In summer during Daylight/Summertime, $timezone drops by 3600 to 14400, and $daylight increases from 0 to 3600.
Example[edit]
//echo -a $timezone
Compatibility[edit]
Added: mIRC v5.1
Added on: 28 Aug 1997
Note: Unless otherwise stated, this was the date of original functionality.
Further enhancements may have been made in later versions.
See also[edit]
mIRC identifier list