File size: 546 Bytes
806d4b5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
U8 *old_font=text.font;
// See ::/Kernel/FontStd.HC, ::/Demo/ScrnCodes.HC,
//::/Demo/ExtChars.HC, and ::/Demo/Graphics/FontEd.HC.
U64 waves[4]={
0x0011AA440011AA44,0x0022558800225588,
0x0044AA110044AA11,0x0088552200885522};
U0 AnimateEndCB()
{
text.font=old_font;
Exit;
}
U0 AnimateTask(I64)
{
I64 i;
U64 *font=MAlloc(256*8);
Fs->task_end_cb=&AnimateEndCB;
MemCpy(font,text.font,256*8);
text.font=font;
while (TRUE) {
font[CH_SPACE]=waves[i++&0x3];
Sleep(100);
}
}
Spawn(&AnimateTask,NULL,"Animate",,Fs);
TaskRep;
|