mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 11:10:47 +00:00
61 lines
1.6 KiB
Text
61 lines
1.6 KiB
Text
|
// From http://wiki.eduke32.com/wiki/How_to_make_a_clock (author: The Commander)
|
||
|
// with modifications
|
||
|
|
||
|
gamevar sec 0 0
|
||
|
gamevar min 0 0
|
||
|
gamevar hour 0 0
|
||
|
gamevar mday 0 0
|
||
|
gamevar mon 0 0
|
||
|
gamevar year 0 0
|
||
|
gamevar wday 0 0
|
||
|
gamevar yday 0 0
|
||
|
|
||
|
onevent EVENT_DISPLAYREST
|
||
|
gettimedate sec min hour mday mon year wday yday
|
||
|
|
||
|
ifvarl hour 20 ifvarg hour 9
|
||
|
digitalnumberz 2992 285 16 hour 0 0 0 0 0 xdim ydim 65536
|
||
|
|
||
|
ifvarg hour 19
|
||
|
digitalnumberz 2992 282 16 hour 0 0 0 0 0 xdim ydim 65536
|
||
|
|
||
|
ifvarl hour 10
|
||
|
{
|
||
|
digitalnumberz 2992 288 16 hour 0 0 0 0 0 xdim ydim 65536
|
||
|
rotatesprite 269 16 65536 0 2992 0 0 0 0 0 xdim ydim
|
||
|
}
|
||
|
|
||
|
ifvarg min 9
|
||
|
digitalnumberz 2992 308 16 min 0 0 0 0 0 xdim ydim 65536
|
||
|
|
||
|
ifvarl min 10
|
||
|
{
|
||
|
digitalnumberz 2992 315 16 min 0 0 0 0 0 xdim ydim 65536
|
||
|
rotatesprite 296 16 65536 0 2992 0 0 0 0 0 xdim ydim
|
||
|
}
|
||
|
|
||
|
gametextz STARTALPHANUM 20 20 1 0 0 0 0 0 xdim ydim 32768
|
||
|
endevent
|
||
|
|
||
|
|
||
|
// Following code by Hendricks266, from
|
||
|
// http://forums.duke4.net/topic/1093-what-are-you-working-on-for-duke-right-now/page__view__findpost__p__152626
|
||
|
|
||
|
gamevar zoom 0 0
|
||
|
|
||
|
definequote 10000 abcdefghijklm
|
||
|
definequote 10001 nopqrstuvwxyz
|
||
|
|
||
|
onevent EVENT_DISPLAYREST
|
||
|
setvarvar zoom totalclock
|
||
|
modvar zoom 240
|
||
|
mulvar zoom 8192
|
||
|
divvar zoom 15
|
||
|
|
||
|
digitalnumberz DIGITALNUM 160 5 1234567890 0 0 16 windowx1 windowy1 windowx2 windowy2 zoom
|
||
|
|
||
|
gametextz STARTALPHANUM 320 30 10000 0 0 16 windowx1 windowy1 windowx2 windowy2 zoom
|
||
|
|
||
|
rotatesprite 160 70 zoom 0 SPINNINGNUKEICON 0 0 0 windowx1 windowy1 windowx2 windowy2
|
||
|
endevent
|