mirror of
https://github.com/Zeal-Operating-System/ZealOS.git
synced 2025-01-30 16:16:04 +00:00
db32fdb367
Reformatted DolDoc files, adjusted sprites in documentation to reflect naming changes, corrected keybinding labels in AutoComplete window, fixed formatting error in Tips.DD. Added DVD Boot AHCI prototyping into Kernel, displays detected AHCI configuration and halts mid-boot. Small modifications to standard font, slight increase to mouse X and Y speed.
97 lines
No EOL
53 KiB
HolyC
Executable file
97 lines
No EOL
53 KiB
HolyC
Executable file
//Press <CTRL-t>.
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
$SP,"",BI=1$
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
//The sprite was created with <CTRL-r>.
|
||
|
||
U0 ElephantWalk()
|
||
{
|
||
I64 sc,
|
||
x = Fs->pix_width >> 1, y = Fs->pix_height >> 1, //Fs is current $LK,"CTask",A="MN:CTask"$ struct.
|
||
x_last = x;
|
||
|
||
AutoComplete;
|
||
WinBorder;
|
||
WinMax;
|
||
DocClear;
|
||
while (TRUE)
|
||
{
|
||
DCFill;
|
||
if (x > x_last)
|
||
{
|
||
DCSymmetrySet(, x, y, x, y - 1);
|
||
gr.dc->flags |= DCF_SYMMETRY | DCF_JUST_MIRROR;
|
||
}
|
||
else
|
||
gr.dc->flags &= ~(DCF_SYMMETRY | DCF_JUST_MIRROR);
|
||
x_last = x;
|
||
Sprite3ZB(gr.dc, x, y, 0, $IB,"<1>",BI=1$, Sin(8 * tS) / 4);//Use <CTRL-r> "Ptr to Sprite"
|
||
switch (KeyGet(&sc))
|
||
{
|
||
case 0:
|
||
switch (sc.u8[0])
|
||
{//Scan code $LK,"lowest byte",A="FI:::/Doc/CharOverview.DD"$
|
||
case SC_CURSOR_UP:
|
||
y -= 32;
|
||
if (y < 0)
|
||
y = Fs->pix_height;
|
||
break;
|
||
|
||
case SC_CURSOR_DOWN:
|
||
y += 32;
|
||
if (y > Fs->pix_height)
|
||
y = 0;
|
||
break;
|
||
|
||
case SC_CURSOR_LEFT:
|
||
x -= 32;
|
||
if (x < 0)
|
||
x = Fs->pix_width;
|
||
break;
|
||
|
||
case SC_CURSOR_RIGHT:
|
||
x += 32;
|
||
if (x > Fs->pix_width)
|
||
x = 0;
|
||
break;
|
||
}
|
||
break;
|
||
|
||
case CH_ESC:
|
||
case CH_SHIFT_ESC:
|
||
goto ew_done;
|
||
}
|
||
}
|
||
ew_done:
|
||
DCFill;
|
||
}
|
||
|
||
ElephantWalk;
|
||
|