-
Notifications
You must be signed in to change notification settings - Fork 0
/
TERMEGG.H
130 lines (111 loc) · 4.12 KB
/
TERMEGG.H
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
unsigned char EBuf[10];
unsigned char X,Y;
unsigned char EggText[]={
" \0x00"
" \0x00"
" \0x00"
" ³³³³³³³³³ \0x00"
" (()()())()) \0x00"
" ³ ÚÄ¿ ÚÄ¿ ³ \0x00"
" ³ ³0³ ³0³ ³ \0x00"
" ³ ÀÄÙ ÀÄÙ ³ \0x00"
" ³ ³ ³ \0x00"
" ³ ÄÁÄ ³ \0x00"
" ³ ÚÄÄÄÄÄ¿ ³ \0x00"
" ³ ÀÄÄÄÄÄÙ ³ \0x00"
" (ÄÄÄÄÂÄÄÄÄ) \0x00"
" ³ \0x00"
" ÚÄÅÄ¿ \0x00"
" ³ ³ ³ \0x00"
" ÚÙ ³ À¿ \0x00"
" ³ \0x00"
" ³ \0x00"
" ÚÁ¿ \0x00"
" ÚÙ À¿ \0x00"
" ÚÙ À¿ \0x00"
" \0x00"
" \0x00"
" \0x00"
};
// Direction=1 .. Nahoru
void RolScreen(unsigned char PocRadku, unsigned char Direction)
{
if(Direction) asm MOV AH,7;
else asm MOV AH,6;
asm{
MOV CL,0
MOV CH,0
MOV DL,79
MOV DH,24
MOV AL,PocRadku
MOV BH,0
INT 0x10
}
}
void GoAnim()
{
HideTextCursor();
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("À----ÄÙ\0x00");
gotoxy(41,18);cprintf("À-\0x00");
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("À-___-Ù\0x00");
gotoxy(41,18);cprintf("ÀÄÄ \0x00");
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("À_____Ù\0x00");
gotoxy(41,18);cprintf("ÀÄÄÙ \0x00");
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("À-___-Ù\0x00");
gotoxy(41,18);cprintf("ÀÄÄÄ \0x00");
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("À----ÄÙ\0x00");
gotoxy(41,18);cprintf("À- \0x00");
delay(200);
gotoxy(35,12);cprintf("ÚÄÄÄÄÄ¿\0x00");
gotoxy(35,12);cprintf("ÀÄÄÄÄÄÙ\0x00");
ShowTextCursor();
}
void Egg()
{
window(1,1,80,25);
SaveCursorPos(4);
GetScr(4,0,0,79,24);
textattr(15);
for(X=0; X<25; X++)
{
RolScreen(1,1);
gotoxy(1,1);
cprintf("%s",&EggText[(24-X)*80]);
delay(10);
}
GoAnim();
//GetKey();
delay(500);
for(X=0; X<25; X++)
{
RolScreen(1,1);
for(Y=0; Y<80; Y++)
{
pokeb(0xB800, Y*2 + 0*80*2, ScrBuf[4][Y*2 + (24-X)*80*2]);
pokeb(0xB800, Y*2 + 0*80*2 + 1, ScrBuf[4][Y*2 + (24-X)*80*2 + 1]);
}
delay(10);
}
LoadCursorPos(4);
}
void TestEgg(unsigned char Ch)
{
EBuf[6]=Ch;
for(X=0; X<6; X++)
{
EBuf[X]=EBuf[X+1];
if((EBuf[0]=='K')&(EBuf[1]=='o')&(EBuf[2]=='u')&(EBuf[3]=='t')&
(EBuf[4]=='a')&(EBuf[5]=='s'))
Egg();
}
}