Posted by ShADe on 1/20/2000, 11:22 pm
, in reply to "ShADes Thread"
203.57.68.13
:00446C61 8B45FC mov eax, dword ptr [ebp-04] ;todays date
:00446C64 8B55F0 mov edx, dword ptr [ebp-10] ;date from registry
:00446C67 2BC2 sub eax, edx ;result in eax
:00446C69 B9CA000000 mov ecx, 000000CA ;202d
:00446C6E 33D2 xor edx, edx ;clear edx
:00446C70 F7F1 div ecx ;resultofsub/202
:00446C72 8BC8 mov ecx, eax ;copy result into ecx
:00446C74 890DF68D4A00 mov dword ptr [004A8DF6],ecx ;save result here too
:00446C7A 83F91E cmp ecx, 0000001E ;compare result with 30
:00446C7D 0F9EC0 setle al
:00446C80 83E001 and eax, 00000001Usage: DIV src
Modifies flags: (AF,CF,OF,PF,SF,ZF undefined)
Unsigned binary division of accumulator by source. If the source
divisor is a byte value then AX is divided by "src" and the quotient
is placed in AL and the remainder in AH. If source operand is a word
value, then DX:AX is divided by "src" and the quotient is stored in AX
and the remainder in DX.
Therefore 1 day =202d so 202/24hrs= 8.41666/60mins =0.14027*7= 0.981So every increment of the date format is 7 mins.
Give or take a few milli secs.A program just needs to consist of GetSystemTimeAsFileTime and saving it to the registry.
I am not going to do this part.