curses 1.4.5 → 1.4.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/push_gem.yml +48 -0
- data/History.md +3 -0
- data/curses.gemspec +1 -1
- metadata +8 -247
- data/vendor/PDCurses/.gitignore +0 -47
- data/vendor/PDCurses/.travis.yml +0 -49
- data/vendor/PDCurses/CMakeLists.txt +0 -68
- data/vendor/PDCurses/HISTORY.md +0 -2036
- data/vendor/PDCurses/IMPLEMNT.md +0 -327
- data/vendor/PDCurses/Makefile +0 -27
- data/vendor/PDCurses/README.md +0 -77
- data/vendor/PDCurses/acs_defs.h +0 -265
- data/vendor/PDCurses/appveyor.yml +0 -218
- data/vendor/PDCurses/cmake/README.md +0 -71
- data/vendor/PDCurses/cmake/build_dependencies.cmake +0 -178
- data/vendor/PDCurses/cmake/build_options.cmake +0 -25
- data/vendor/PDCurses/cmake/dll_version.cmake +0 -26
- data/vendor/PDCurses/cmake/gen_config_header.cmake +0 -43
- data/vendor/PDCurses/cmake/get_version.cmake +0 -17
- data/vendor/PDCurses/cmake/make_uninstall.cmake +0 -19
- data/vendor/PDCurses/cmake/project_common.cmake +0 -121
- data/vendor/PDCurses/cmake/resource.in.cmake +0 -52
- data/vendor/PDCurses/cmake/sdl2_ttf/CMakeLists.txt +0 -83
- data/vendor/PDCurses/cmake/target_arch.cmake +0 -36
- data/vendor/PDCurses/cmake/version.in.cmake +0 -73
- data/vendor/PDCurses/cmake/watcom_open_dos16_toolchain.cmake +0 -96
- data/vendor/PDCurses/cmake/watcom_open_dos32_toolchain.cmake +0 -106
- data/vendor/PDCurses/cmake/watcom_open_os2v2_toolchain.cmake +0 -105
- data/vendor/PDCurses/curses.h +0 -1846
- data/vendor/PDCurses/curspriv.h +0 -134
- data/vendor/PDCurses/demos/README.md +0 -25
- data/vendor/PDCurses/demos/firework.c +0 -144
- data/vendor/PDCurses/demos/newtest.c +0 -581
- data/vendor/PDCurses/demos/ozdemo.c +0 -447
- data/vendor/PDCurses/demos/ptest.c +0 -283
- data/vendor/PDCurses/demos/rain.c +0 -157
- data/vendor/PDCurses/demos/testcurs.c +0 -1607
- data/vendor/PDCurses/demos/tui.c +0 -1048
- data/vendor/PDCurses/demos/tui.h +0 -65
- data/vendor/PDCurses/demos/tuidemo.c +0 -233
- data/vendor/PDCurses/demos/version.c +0 -61
- data/vendor/PDCurses/demos/worm.c +0 -432
- data/vendor/PDCurses/demos/xmas.c +0 -955
- data/vendor/PDCurses/dos/CMakeLists.txt +0 -47
- data/vendor/PDCurses/dos/Makefile +0 -105
- data/vendor/PDCurses/dos/Makefile.bcc +0 -83
- data/vendor/PDCurses/dos/Makefile.dmc +0 -257
- data/vendor/PDCurses/dos/Makefile.msc +0 -113
- data/vendor/PDCurses/dos/Makefile.wcc +0 -107
- data/vendor/PDCurses/dos/README.md +0 -51
- data/vendor/PDCurses/dos/bccdos.lrf +0 -9
- data/vendor/PDCurses/dos/mscdos.lrf +0 -50
- data/vendor/PDCurses/dos/pdcclip.c +0 -132
- data/vendor/PDCurses/dos/pdcdisp.c +0 -135
- data/vendor/PDCurses/dos/pdcdos.h +0 -194
- data/vendor/PDCurses/dos/pdcgetsc.c +0 -98
- data/vendor/PDCurses/dos/pdckbd.c +0 -513
- data/vendor/PDCurses/dos/pdcscrn.c +0 -785
- data/vendor/PDCurses/dos/pdcsetsc.c +0 -101
- data/vendor/PDCurses/dos/pdcutil.c +0 -212
- data/vendor/PDCurses/libobjs.mif +0 -26
- data/vendor/PDCurses/makedist.mif +0 -20
- data/vendor/PDCurses/man/Makefile +0 -37
- data/vendor/PDCurses/man/README.md +0 -21
- data/vendor/PDCurses/man/intro.md +0 -361
- data/vendor/PDCurses/man/manext.c +0 -119
- data/vendor/PDCurses/man/sdl.md +0 -152
- data/vendor/PDCurses/man/sdl2.md +0 -58
- data/vendor/PDCurses/man/x11.md +0 -407
- data/vendor/PDCurses/ncurses/CMakeLists.txt +0 -66
- data/vendor/PDCurses/ncurses/README.md +0 -26
- data/vendor/PDCurses/ncurses/makefile +0 -29
- data/vendor/PDCurses/os2/CMakeLists.txt +0 -41
- data/vendor/PDCurses/os2/Makefile +0 -132
- data/vendor/PDCurses/os2/Makefile.bcc +0 -90
- data/vendor/PDCurses/os2/Makefile.wcc +0 -43
- data/vendor/PDCurses/os2/README.md +0 -43
- data/vendor/PDCurses/os2/iccos2.lrf +0 -50
- data/vendor/PDCurses/os2/iccos2.mak +0 -256
- data/vendor/PDCurses/os2/pdcclip.c +0 -188
- data/vendor/PDCurses/os2/pdcdisp.c +0 -93
- data/vendor/PDCurses/os2/pdcgetsc.c +0 -89
- data/vendor/PDCurses/os2/pdckbd.c +0 -521
- data/vendor/PDCurses/os2/pdcos2.h +0 -55
- data/vendor/PDCurses/os2/pdcscrn.c +0 -449
- data/vendor/PDCurses/os2/pdcsetsc.c +0 -112
- data/vendor/PDCurses/os2/pdcutil.c +0 -52
- data/vendor/PDCurses/panel.h +0 -56
- data/vendor/PDCurses/pdcurses/README.md +0 -25
- data/vendor/PDCurses/pdcurses/addch.c +0 -693
- data/vendor/PDCurses/pdcurses/addchstr.c +0 -245
- data/vendor/PDCurses/pdcurses/addstr.c +0 -240
- data/vendor/PDCurses/pdcurses/attr.c +0 -359
- data/vendor/PDCurses/pdcurses/beep.c +0 -68
- data/vendor/PDCurses/pdcurses/bkgd.c +0 -223
- data/vendor/PDCurses/pdcurses/border.c +0 -411
- data/vendor/PDCurses/pdcurses/clear.c +0 -159
- data/vendor/PDCurses/pdcurses/color.c +0 -298
- data/vendor/PDCurses/pdcurses/debug.c +0 -109
- data/vendor/PDCurses/pdcurses/delch.c +0 -96
- data/vendor/PDCurses/pdcurses/deleteln.c +0 -211
- data/vendor/PDCurses/pdcurses/deprec.c +0 -27
- data/vendor/PDCurses/pdcurses/getch.c +0 -417
- data/vendor/PDCurses/pdcurses/getstr.c +0 -474
- data/vendor/PDCurses/pdcurses/getyx.c +0 -139
- data/vendor/PDCurses/pdcurses/inch.c +0 -127
- data/vendor/PDCurses/pdcurses/inchstr.c +0 -214
- data/vendor/PDCurses/pdcurses/initscr.c +0 -367
- data/vendor/PDCurses/pdcurses/inopts.c +0 -324
- data/vendor/PDCurses/pdcurses/insch.c +0 -271
- data/vendor/PDCurses/pdcurses/insstr.c +0 -264
- data/vendor/PDCurses/pdcurses/instr.c +0 -246
- data/vendor/PDCurses/pdcurses/kernel.c +0 -259
- data/vendor/PDCurses/pdcurses/keyname.c +0 -157
- data/vendor/PDCurses/pdcurses/mouse.c +0 -438
- data/vendor/PDCurses/pdcurses/move.c +0 -57
- data/vendor/PDCurses/pdcurses/outopts.c +0 -159
- data/vendor/PDCurses/pdcurses/overlay.c +0 -214
- data/vendor/PDCurses/pdcurses/pad.c +0 -260
- data/vendor/PDCurses/pdcurses/panel.c +0 -633
- data/vendor/PDCurses/pdcurses/printw.c +0 -126
- data/vendor/PDCurses/pdcurses/refresh.c +0 -279
- data/vendor/PDCurses/pdcurses/scanw.c +0 -578
- data/vendor/PDCurses/pdcurses/scr_dump.c +0 -213
- data/vendor/PDCurses/pdcurses/scroll.c +0 -101
- data/vendor/PDCurses/pdcurses/slk.c +0 -591
- data/vendor/PDCurses/pdcurses/termattr.c +0 -182
- data/vendor/PDCurses/pdcurses/terminfo.c +0 -217
- data/vendor/PDCurses/pdcurses/touch.c +0 -163
- data/vendor/PDCurses/pdcurses/util.c +0 -312
- data/vendor/PDCurses/pdcurses/window.c +0 -569
- data/vendor/PDCurses/sdl1/Makefile +0 -129
- data/vendor/PDCurses/sdl1/Makefile.mng +0 -110
- data/vendor/PDCurses/sdl1/README.md +0 -31
- data/vendor/PDCurses/sdl1/deffont.h +0 -385
- data/vendor/PDCurses/sdl1/deficon.h +0 -23
- data/vendor/PDCurses/sdl1/pdcclip.c +0 -131
- data/vendor/PDCurses/sdl1/pdcdisp.c +0 -373
- data/vendor/PDCurses/sdl1/pdcgetsc.c +0 -30
- data/vendor/PDCurses/sdl1/pdckbd.c +0 -405
- data/vendor/PDCurses/sdl1/pdcscrn.c +0 -414
- data/vendor/PDCurses/sdl1/pdcsdl.h +0 -31
- data/vendor/PDCurses/sdl1/pdcsetsc.c +0 -64
- data/vendor/PDCurses/sdl1/pdcutil.c +0 -40
- data/vendor/PDCurses/sdl1/sdltest.c +0 -79
- data/vendor/PDCurses/sdl2/CMakeLists.txt +0 -76
- data/vendor/PDCurses/sdl2/Makefile +0 -135
- data/vendor/PDCurses/sdl2/Makefile.vc +0 -164
- data/vendor/PDCurses/sdl2/README.md +0 -34
- data/vendor/PDCurses/sdl2/deffont.h +0 -385
- data/vendor/PDCurses/sdl2/deficon.h +0 -23
- data/vendor/PDCurses/sdl2/pdcclip.c +0 -93
- data/vendor/PDCurses/sdl2/pdcdisp.c +0 -534
- data/vendor/PDCurses/sdl2/pdcgetsc.c +0 -30
- data/vendor/PDCurses/sdl2/pdckbd.c +0 -480
- data/vendor/PDCurses/sdl2/pdcscrn.c +0 -443
- data/vendor/PDCurses/sdl2/pdcsdl.h +0 -33
- data/vendor/PDCurses/sdl2/pdcsetsc.c +0 -67
- data/vendor/PDCurses/sdl2/pdcutil.c +0 -39
- data/vendor/PDCurses/sdl2/sdltest.c +0 -81
- data/vendor/PDCurses/term.h +0 -48
- data/vendor/PDCurses/version.mif +0 -7
- data/vendor/PDCurses/vt/CMakeLists.txt +0 -28
- data/vendor/PDCurses/vt/Makefile +0 -135
- data/vendor/PDCurses/vt/Makefile.bcc +0 -111
- data/vendor/PDCurses/vt/Makefile.dmc +0 -258
- data/vendor/PDCurses/vt/Makefile.vc +0 -144
- data/vendor/PDCurses/vt/Makefile.wcc +0 -107
- data/vendor/PDCurses/vt/README.md +0 -64
- data/vendor/PDCurses/vt/pdcclip.c +0 -20
- data/vendor/PDCurses/vt/pdcdisp.c +0 -284
- data/vendor/PDCurses/vt/pdcgetsc.c +0 -27
- data/vendor/PDCurses/vt/pdckbd.c +0 -394
- data/vendor/PDCurses/vt/pdcscrn.c +0 -434
- data/vendor/PDCurses/vt/pdcsetsc.c +0 -45
- data/vendor/PDCurses/vt/pdcutil.c +0 -43
- data/vendor/PDCurses/vt/pdcvt.h +0 -16
- data/vendor/PDCurses/watcom.mif +0 -68
- data/vendor/PDCurses/wincon/CMakeLists.txt +0 -27
- data/vendor/PDCurses/wincon/Makefile.bcc +0 -88
- data/vendor/PDCurses/wincon/Makefile.dmc +0 -256
- data/vendor/PDCurses/wincon/Makefile.lcc +0 -273
- data/vendor/PDCurses/wincon/Makefile.mng +0 -176
- data/vendor/PDCurses/wincon/Makefile.vc +0 -144
- data/vendor/PDCurses/wincon/Makefile.wcc +0 -51
- data/vendor/PDCurses/wincon/README.md +0 -85
- data/vendor/PDCurses/wincon/pdcclip.c +0 -174
- data/vendor/PDCurses/wincon/pdcdisp.c +0 -143
- data/vendor/PDCurses/wincon/pdcgetsc.c +0 -55
- data/vendor/PDCurses/wincon/pdckbd.c +0 -786
- data/vendor/PDCurses/wincon/pdcscrn.c +0 -717
- data/vendor/PDCurses/wincon/pdcsetsc.c +0 -91
- data/vendor/PDCurses/wincon/pdcurses.ico +0 -0
- data/vendor/PDCurses/wincon/pdcurses.rc +0 -28
- data/vendor/PDCurses/wincon/pdcutil.c +0 -41
- data/vendor/PDCurses/wincon/pdcwin.h +0 -31
- data/vendor/PDCurses/wingui/CMakeLists.txt +0 -27
- data/vendor/PDCurses/wingui/Makefile.bcc +0 -85
- data/vendor/PDCurses/wingui/Makefile.dmc +0 -259
- data/vendor/PDCurses/wingui/Makefile.lcc +0 -273
- data/vendor/PDCurses/wingui/Makefile.mng +0 -171
- data/vendor/PDCurses/wingui/Makefile.vc +0 -144
- data/vendor/PDCurses/wingui/Makefile.wcc +0 -51
- data/vendor/PDCurses/wingui/README.md +0 -93
- data/vendor/PDCurses/wingui/pdcclip.c +0 -174
- data/vendor/PDCurses/wingui/pdcdisp.c +0 -718
- data/vendor/PDCurses/wingui/pdcgetsc.c +0 -30
- data/vendor/PDCurses/wingui/pdckbd.c +0 -143
- data/vendor/PDCurses/wingui/pdcscrn.c +0 -2797
- data/vendor/PDCurses/wingui/pdcsetsc.c +0 -89
- data/vendor/PDCurses/wingui/pdcurses.ico +0 -0
- data/vendor/PDCurses/wingui/pdcurses.rc +0 -28
- data/vendor/PDCurses/wingui/pdcutil.c +0 -61
- data/vendor/PDCurses/wingui/pdcwin.h +0 -122
- data/vendor/PDCurses/x11/Makefile.in +0 -754
- data/vendor/PDCurses/x11/PDCurses.spec +0 -82
- data/vendor/PDCurses/x11/README.md +0 -62
- data/vendor/PDCurses/x11/ScrollBox.c +0 -319
- data/vendor/PDCurses/x11/ScrollBox.h +0 -51
- data/vendor/PDCurses/x11/ScrollBoxP.h +0 -70
- data/vendor/PDCurses/x11/aclocal.m4 +0 -994
- data/vendor/PDCurses/x11/big_icon.xbm +0 -46
- data/vendor/PDCurses/x11/compose.h +0 -201
- data/vendor/PDCurses/x11/config.guess +0 -1500
- data/vendor/PDCurses/x11/config.h.in +0 -100
- data/vendor/PDCurses/x11/config.sub +0 -1616
- data/vendor/PDCurses/x11/configure +0 -6700
- data/vendor/PDCurses/x11/configure.ac +0 -295
- data/vendor/PDCurses/x11/debian/changelog +0 -6
- data/vendor/PDCurses/x11/debian/compat +0 -1
- data/vendor/PDCurses/x11/debian/control +0 -11
- data/vendor/PDCurses/x11/debian/copyright +0 -27
- data/vendor/PDCurses/x11/debian/rules +0 -98
- data/vendor/PDCurses/x11/install-sh +0 -253
- data/vendor/PDCurses/x11/little_icon.xbm +0 -14
- data/vendor/PDCurses/x11/ncurses_cfg.h +0 -45
- data/vendor/PDCurses/x11/pdcclip.c +0 -173
- data/vendor/PDCurses/x11/pdcdisp.c +0 -85
- data/vendor/PDCurses/x11/pdcgetsc.c +0 -28
- data/vendor/PDCurses/x11/pdckbd.c +0 -104
- data/vendor/PDCurses/x11/pdcscrn.c +0 -258
- data/vendor/PDCurses/x11/pdcsetsc.c +0 -95
- data/vendor/PDCurses/x11/pdcutil.c +0 -52
- data/vendor/PDCurses/x11/pdcx11.c +0 -316
- data/vendor/PDCurses/x11/pdcx11.h +0 -191
- data/vendor/PDCurses/x11/sb.c +0 -155
- data/vendor/PDCurses/x11/x11.c +0 -3686
- data/vendor/PDCurses/x11/xcurses-config.in +0 -81
@@ -1,955 +0,0 @@
|
|
1
|
-
/******************************************************************************/
|
2
|
-
/* asciixmas */
|
3
|
-
/* December 1989 Larry Bartz Indianapolis, IN */
|
4
|
-
/* */
|
5
|
-
/* */
|
6
|
-
/* I'm dreaming of an ascii character-based monochrome Christmas, */
|
7
|
-
/* Just like the one's I used to know! */
|
8
|
-
/* Via a full duplex communications channel, */
|
9
|
-
/* At 9600 bits per second, */
|
10
|
-
/* Even though it's kinda slow. */
|
11
|
-
/* */
|
12
|
-
/* I'm dreaming of an ascii character-based monochrome Christmas, */
|
13
|
-
/* With ev'ry C program I write! */
|
14
|
-
/* May your screen be merry and bright! */
|
15
|
-
/* And may all your Christmases be amber or green, */
|
16
|
-
/* (for reduced eyestrain and improved visibility)! */
|
17
|
-
/* */
|
18
|
-
/* */
|
19
|
-
/* */
|
20
|
-
/* IMPLEMENTATION */
|
21
|
-
/* */
|
22
|
-
/* Feel free to modify the defined string FROMWHO to reflect you, your */
|
23
|
-
/* organization, your site, whatever. */
|
24
|
-
/* */
|
25
|
-
/* This looks a lot better if you can turn off your cursor before execution. */
|
26
|
-
/* The cursor is distracting but it doesn't really ruin the show. */
|
27
|
-
/* */
|
28
|
-
/* At our site, we invoke this for our users just after login and the */
|
29
|
-
/* determination of terminal type. */
|
30
|
-
/* */
|
31
|
-
/* */
|
32
|
-
/* PORTABILITY */
|
33
|
-
/* */
|
34
|
-
/* I wrote this using only the very simplest curses functions so that it */
|
35
|
-
/* might be the most portable. I was personally able to test on five */
|
36
|
-
/* different cpu/UNIX combinations. */
|
37
|
-
/* */
|
38
|
-
/* */
|
39
|
-
/* COMPILE */
|
40
|
-
/* */
|
41
|
-
/* usually this: */
|
42
|
-
/* */
|
43
|
-
/* cc -O xmas.c -lcurses -o xmas -s */
|
44
|
-
/* */
|
45
|
-
/******************************************************************************/
|
46
|
-
|
47
|
-
#include <curses.h>
|
48
|
-
#include <signal.h>
|
49
|
-
|
50
|
-
void lil(WINDOW *);
|
51
|
-
void midtop(WINDOW *);
|
52
|
-
void bigtop(WINDOW *);
|
53
|
-
void bigface(WINDOW *, chtype);
|
54
|
-
void legs1(WINDOW *);
|
55
|
-
void legs2(WINDOW *);
|
56
|
-
void legs3(WINDOW *);
|
57
|
-
void legs4(WINDOW *);
|
58
|
-
void initdeer(void);
|
59
|
-
void boxit(void);
|
60
|
-
void seas(void);
|
61
|
-
void greet(void);
|
62
|
-
void fromwho(void);
|
63
|
-
void del_msg(void);
|
64
|
-
void tree(void);
|
65
|
-
void balls(void);
|
66
|
-
void star(void);
|
67
|
-
void strng1(void);
|
68
|
-
void strng2(void);
|
69
|
-
void strng3(void);
|
70
|
-
void strng4(void);
|
71
|
-
void strng5(void);
|
72
|
-
void blinkit(void);
|
73
|
-
void reindeer(void);
|
74
|
-
|
75
|
-
#define FROMWHO "From Larry Bartz, Mark Hessling and William McBrine"
|
76
|
-
|
77
|
-
int y_pos, x_pos;
|
78
|
-
|
79
|
-
WINDOW *treescrn, *treescrn2, *treescrn3, *treescrn4, *treescrn5,
|
80
|
-
*treescrn6, *treescrn7, *treescrn8, *dotdeer0, *stardeer0,
|
81
|
-
*lildeer0, *lildeer1, *lildeer2, *lildeer3, *middeer0,
|
82
|
-
*middeer1, *middeer2, *middeer3, *bigdeer0, *bigdeer1,
|
83
|
-
*bigdeer2, *bigdeer3, *bigdeer4, *lookdeer0, *lookdeer1,
|
84
|
-
*lookdeer2, *lookdeer3, *lookdeer4, *w_holiday, *w_del_msg;
|
85
|
-
|
86
|
-
int main(int argc, char **argv)
|
87
|
-
{
|
88
|
-
int loopy;
|
89
|
-
|
90
|
-
#ifdef XCURSES
|
91
|
-
Xinitscr(argc, argv);
|
92
|
-
#else
|
93
|
-
initscr();
|
94
|
-
#endif
|
95
|
-
nodelay(stdscr, TRUE);
|
96
|
-
noecho();
|
97
|
-
nonl();
|
98
|
-
refresh();
|
99
|
-
|
100
|
-
#ifdef A_COLOR
|
101
|
-
if (has_colors())
|
102
|
-
start_color();
|
103
|
-
#endif
|
104
|
-
curs_set(0);
|
105
|
-
|
106
|
-
treescrn = newwin(16, 27, 3, 53);
|
107
|
-
treescrn2 = newwin(16, 27, 3, 53);
|
108
|
-
treescrn3 = newwin(16, 27, 3, 53);
|
109
|
-
treescrn4 = newwin(16, 27, 3, 53);
|
110
|
-
treescrn5 = newwin(16, 27, 3, 53);
|
111
|
-
treescrn6 = newwin(16, 27, 3, 53);
|
112
|
-
treescrn7 = newwin(16, 27, 3, 53);
|
113
|
-
treescrn8 = newwin(16, 27, 3, 53);
|
114
|
-
|
115
|
-
w_holiday = newwin(1, 26, 3, 27);
|
116
|
-
|
117
|
-
w_del_msg = newwin(1, 12, 23, 60);
|
118
|
-
|
119
|
-
mvwaddstr(w_holiday, 0, 0, "H A P P Y H O L I D A Y S");
|
120
|
-
|
121
|
-
initdeer();
|
122
|
-
|
123
|
-
clear();
|
124
|
-
werase(treescrn);
|
125
|
-
touchwin(treescrn);
|
126
|
-
werase(treescrn2);
|
127
|
-
touchwin(treescrn2);
|
128
|
-
werase(treescrn8);
|
129
|
-
touchwin(treescrn8);
|
130
|
-
refresh();
|
131
|
-
napms(1000);
|
132
|
-
|
133
|
-
boxit();
|
134
|
-
del_msg();
|
135
|
-
napms(1000);
|
136
|
-
|
137
|
-
seas();
|
138
|
-
del_msg();
|
139
|
-
napms(1000);
|
140
|
-
|
141
|
-
greet();
|
142
|
-
del_msg();
|
143
|
-
napms(1000);
|
144
|
-
|
145
|
-
fromwho();
|
146
|
-
del_msg();
|
147
|
-
napms(1000);
|
148
|
-
|
149
|
-
tree();
|
150
|
-
napms(1000);
|
151
|
-
|
152
|
-
balls();
|
153
|
-
napms(1000);
|
154
|
-
|
155
|
-
star();
|
156
|
-
napms(1000);
|
157
|
-
|
158
|
-
strng1();
|
159
|
-
strng2();
|
160
|
-
strng3();
|
161
|
-
strng4();
|
162
|
-
strng5();
|
163
|
-
|
164
|
-
/* set up the windows for our blinking trees */
|
165
|
-
/* **************************************** */
|
166
|
-
/* treescrn3 */
|
167
|
-
|
168
|
-
overlay(treescrn, treescrn3);
|
169
|
-
|
170
|
-
/* balls */
|
171
|
-
mvwaddch(treescrn3, 4, 18, ' ');
|
172
|
-
mvwaddch(treescrn3, 7, 6, ' ');
|
173
|
-
mvwaddch(treescrn3, 8, 19, ' ');
|
174
|
-
mvwaddch(treescrn3, 11, 22, ' ');
|
175
|
-
|
176
|
-
/* star */
|
177
|
-
mvwaddch(treescrn3, 0, 12, '*');
|
178
|
-
|
179
|
-
/* strng1 */
|
180
|
-
mvwaddch(treescrn3, 3, 11, ' ');
|
181
|
-
|
182
|
-
/* strng2 */
|
183
|
-
mvwaddch(treescrn3, 5, 13, ' ');
|
184
|
-
mvwaddch(treescrn3, 6, 10, ' ');
|
185
|
-
|
186
|
-
/* strng3 */
|
187
|
-
mvwaddch(treescrn3, 7, 16, ' ');
|
188
|
-
mvwaddch(treescrn3, 7, 14, ' ');
|
189
|
-
|
190
|
-
/* strng4 */
|
191
|
-
mvwaddch(treescrn3, 10, 13, ' ');
|
192
|
-
mvwaddch(treescrn3, 10, 10, ' ');
|
193
|
-
mvwaddch(treescrn3, 11, 8, ' ');
|
194
|
-
|
195
|
-
/* strng5 */
|
196
|
-
mvwaddch(treescrn3, 11, 18, ' ');
|
197
|
-
mvwaddch(treescrn3, 12, 13, ' ');
|
198
|
-
|
199
|
-
/* treescrn4 */
|
200
|
-
|
201
|
-
overlay(treescrn, treescrn4);
|
202
|
-
|
203
|
-
/* balls */
|
204
|
-
mvwaddch(treescrn4, 3, 9, ' ');
|
205
|
-
mvwaddch(treescrn4, 4, 16, ' ');
|
206
|
-
mvwaddch(treescrn4, 7, 6, ' ');
|
207
|
-
mvwaddch(treescrn4, 8, 19, ' ');
|
208
|
-
mvwaddch(treescrn4, 11, 2, ' ');
|
209
|
-
mvwaddch(treescrn4, 12, 23, ' ');
|
210
|
-
|
211
|
-
/* star */
|
212
|
-
mvwaddch(treescrn4, 0, 12, '*' | A_STANDOUT);
|
213
|
-
|
214
|
-
/* strng1 */
|
215
|
-
mvwaddch(treescrn4, 3, 13, ' ');
|
216
|
-
|
217
|
-
/* strng2 */
|
218
|
-
|
219
|
-
/* strng3 */
|
220
|
-
mvwaddch(treescrn4, 7, 15, ' ');
|
221
|
-
mvwaddch(treescrn4, 8, 11, ' ');
|
222
|
-
|
223
|
-
/* strng4 */
|
224
|
-
mvwaddch(treescrn4, 9, 16, ' ');
|
225
|
-
mvwaddch(treescrn4, 10, 12, ' ');
|
226
|
-
mvwaddch(treescrn4, 11, 8, ' ');
|
227
|
-
|
228
|
-
/* strng5 */
|
229
|
-
mvwaddch(treescrn4, 11, 18, ' ');
|
230
|
-
mvwaddch(treescrn4, 12, 14, ' ');
|
231
|
-
|
232
|
-
/* treescrn5 */
|
233
|
-
|
234
|
-
overlay(treescrn, treescrn5);
|
235
|
-
|
236
|
-
/* balls */
|
237
|
-
mvwaddch(treescrn5, 3, 15, ' ');
|
238
|
-
mvwaddch(treescrn5, 10, 20, ' ');
|
239
|
-
mvwaddch(treescrn5, 12, 1, ' ');
|
240
|
-
|
241
|
-
/* star */
|
242
|
-
mvwaddch(treescrn5, 0, 12, '*');
|
243
|
-
|
244
|
-
/* strng1 */
|
245
|
-
mvwaddch(treescrn5, 3, 11, ' ');
|
246
|
-
|
247
|
-
/* strng2 */
|
248
|
-
mvwaddch(treescrn5, 5, 12, ' ');
|
249
|
-
|
250
|
-
/* strng3 */
|
251
|
-
mvwaddch(treescrn5, 7, 14, ' ');
|
252
|
-
mvwaddch(treescrn5, 8, 10, ' ');
|
253
|
-
|
254
|
-
/* strng4 */
|
255
|
-
mvwaddch(treescrn5, 9, 15, ' ');
|
256
|
-
mvwaddch(treescrn5, 10, 11, ' ');
|
257
|
-
mvwaddch(treescrn5, 11, 7, ' ');
|
258
|
-
|
259
|
-
/* strng5 */
|
260
|
-
mvwaddch(treescrn5, 11, 17, ' ');
|
261
|
-
mvwaddch(treescrn5, 12, 13, ' ');
|
262
|
-
|
263
|
-
/* treescrn6 */
|
264
|
-
|
265
|
-
overlay(treescrn, treescrn6);
|
266
|
-
|
267
|
-
/* balls */
|
268
|
-
mvwaddch(treescrn6, 6, 7, ' ');
|
269
|
-
mvwaddch(treescrn6, 7, 18, ' ');
|
270
|
-
mvwaddch(treescrn6, 10, 4, ' ');
|
271
|
-
mvwaddch(treescrn6, 11, 23, ' ');
|
272
|
-
|
273
|
-
/* star */
|
274
|
-
mvwaddch(treescrn6, 0, 12, '*' | A_STANDOUT);
|
275
|
-
|
276
|
-
/* strng1 */
|
277
|
-
|
278
|
-
/* strng2 */
|
279
|
-
mvwaddch(treescrn6, 5, 11, ' ');
|
280
|
-
|
281
|
-
/* strng3 */
|
282
|
-
mvwaddch(treescrn6, 7, 13, ' ');
|
283
|
-
mvwaddch(treescrn6, 8, 9, ' ');
|
284
|
-
|
285
|
-
/* strng4 */
|
286
|
-
mvwaddch(treescrn6, 9, 14, ' ');
|
287
|
-
mvwaddch(treescrn6, 10, 10, ' ');
|
288
|
-
mvwaddch(treescrn6, 11, 6, ' ');
|
289
|
-
|
290
|
-
/* strng5 */
|
291
|
-
mvwaddch(treescrn6, 11, 16, ' ');
|
292
|
-
mvwaddch(treescrn6, 12, 12, ' ');
|
293
|
-
|
294
|
-
/* treescrn7 */
|
295
|
-
|
296
|
-
overlay(treescrn, treescrn7);
|
297
|
-
|
298
|
-
/* balls */
|
299
|
-
mvwaddch(treescrn7, 3, 15, ' ');
|
300
|
-
mvwaddch(treescrn7, 6, 7, ' ');
|
301
|
-
mvwaddch(treescrn7, 7, 18, ' ');
|
302
|
-
mvwaddch(treescrn7, 10, 4, ' ');
|
303
|
-
mvwaddch(treescrn7, 11, 22, ' ');
|
304
|
-
|
305
|
-
/* star */
|
306
|
-
mvwaddch(treescrn7, 0, 12, '*');
|
307
|
-
|
308
|
-
/* strng1 */
|
309
|
-
mvwaddch(treescrn7, 3, 12, ' ');
|
310
|
-
|
311
|
-
/* strng2 */
|
312
|
-
mvwaddch(treescrn7, 5, 13, ' ');
|
313
|
-
mvwaddch(treescrn7, 6, 9, ' ');
|
314
|
-
|
315
|
-
/* strng3 */
|
316
|
-
mvwaddch(treescrn7, 7, 15, ' ');
|
317
|
-
mvwaddch(treescrn7, 8, 11, ' ');
|
318
|
-
|
319
|
-
/* strng4 */
|
320
|
-
mvwaddch(treescrn7, 9, 16, ' ');
|
321
|
-
mvwaddch(treescrn7, 10, 12, ' ');
|
322
|
-
mvwaddch(treescrn7, 11, 8, ' ');
|
323
|
-
|
324
|
-
/* strng5 */
|
325
|
-
mvwaddch(treescrn7, 11, 18, ' ');
|
326
|
-
mvwaddch(treescrn7, 12, 14, ' ');
|
327
|
-
|
328
|
-
napms(1000);
|
329
|
-
reindeer();
|
330
|
-
|
331
|
-
touchwin(w_holiday);
|
332
|
-
wrefresh(w_holiday);
|
333
|
-
wrefresh(w_del_msg);
|
334
|
-
|
335
|
-
napms(1000);
|
336
|
-
|
337
|
-
for (loopy = 0; loopy < 50; loopy++)
|
338
|
-
blinkit();
|
339
|
-
|
340
|
-
clear();
|
341
|
-
refresh();
|
342
|
-
endwin();
|
343
|
-
|
344
|
-
return 0;
|
345
|
-
}
|
346
|
-
|
347
|
-
void lil(WINDOW *win)
|
348
|
-
{
|
349
|
-
mvwaddch(win, 0, 0, (chtype) 'V');
|
350
|
-
mvwaddch(win, 1, 0, (chtype) '@');
|
351
|
-
mvwaddch(win, 1, 3, (chtype) '~');
|
352
|
-
}
|
353
|
-
|
354
|
-
void midtop(WINDOW *win)
|
355
|
-
{
|
356
|
-
mvwaddstr(win, 0, 2, "yy");
|
357
|
-
mvwaddstr(win, 1, 2, "0(=)~");
|
358
|
-
}
|
359
|
-
|
360
|
-
void bigtop(WINDOW *win)
|
361
|
-
{
|
362
|
-
mvwaddstr(win, 0, 17, "\\/");
|
363
|
-
mvwaddstr(win, 0, 20, "\\/");
|
364
|
-
mvwaddch(win, 1, 18, (chtype) '\\');
|
365
|
-
mvwaddch(win, 1, 20, (chtype) '/');
|
366
|
-
mvwaddstr(win, 2, 19, "|_");
|
367
|
-
mvwaddstr(win, 3, 18, "/^0\\");
|
368
|
-
mvwaddstr(win, 4, 17, "//\\");
|
369
|
-
mvwaddch(win, 4, 22, (chtype) '\\');
|
370
|
-
mvwaddstr(win, 5, 7, "^~~~~~~~~// ~~U");
|
371
|
-
}
|
372
|
-
|
373
|
-
void bigface(WINDOW *win, chtype noseattr)
|
374
|
-
{
|
375
|
-
mvwaddstr(win, 0, 16, "\\/ \\/");
|
376
|
-
mvwaddstr(win, 1, 17, "\\Y/ \\Y/");
|
377
|
-
mvwaddstr(win, 2, 19, "\\=/");
|
378
|
-
mvwaddstr(win, 3, 17, "^\\o o/^");
|
379
|
-
mvwaddstr(win, 4, 17, "//( )");
|
380
|
-
mvwaddstr(win, 5, 7, "^~~~~~~~~// \\");
|
381
|
-
waddch(win, 'O' | noseattr);
|
382
|
-
waddstr(win, "/");
|
383
|
-
}
|
384
|
-
|
385
|
-
void legs1(WINDOW *win)
|
386
|
-
{
|
387
|
-
mvwaddstr(win, 6, 7, "( \\_____( /");
|
388
|
-
mvwaddstr(win, 7, 8, "( ) /");
|
389
|
-
mvwaddstr(win, 8, 9, "\\\\ /");
|
390
|
-
mvwaddstr(win, 9, 11, "\\>/>");
|
391
|
-
}
|
392
|
-
|
393
|
-
void legs2(WINDOW *win)
|
394
|
-
{
|
395
|
-
mvwaddstr(win, 6, 7, "(( )____( /");
|
396
|
-
mvwaddstr(win, 7, 7, "( / |");
|
397
|
-
mvwaddstr(win, 8, 8, "\\/ |");
|
398
|
-
mvwaddstr(win, 9, 9, "|> |>");
|
399
|
-
}
|
400
|
-
|
401
|
-
void legs3(WINDOW *win)
|
402
|
-
{
|
403
|
-
mvwaddstr(win, 6, 6, "( ()_____( /");
|
404
|
-
mvwaddstr(win, 7, 6, "/ / /");
|
405
|
-
mvwaddstr(win, 8, 5, "|/ \\");
|
406
|
-
mvwaddstr(win, 9, 5, "/> \\>");
|
407
|
-
}
|
408
|
-
|
409
|
-
void legs4(WINDOW *win)
|
410
|
-
{
|
411
|
-
mvwaddstr(win, 6, 6, "( )______( /");
|
412
|
-
mvwaddstr(win, 7, 5, "(/ \\");
|
413
|
-
mvwaddstr(win, 8, 0, "v___= ----^");
|
414
|
-
}
|
415
|
-
|
416
|
-
void initdeer(void)
|
417
|
-
{
|
418
|
-
chtype noseattr;
|
419
|
-
|
420
|
-
#ifdef A_COLOR
|
421
|
-
if (has_colors())
|
422
|
-
{
|
423
|
-
init_pair(31, COLOR_RED, COLOR_BLACK);
|
424
|
-
noseattr = COLOR_PAIR(31);
|
425
|
-
}
|
426
|
-
else
|
427
|
-
#endif
|
428
|
-
noseattr = A_NORMAL;
|
429
|
-
|
430
|
-
/* set up the windows for our various reindeer */
|
431
|
-
|
432
|
-
dotdeer0 = newwin(3, 71, 0, 8);
|
433
|
-
stardeer0 = newwin(4, 56, 0, 8);
|
434
|
-
lildeer0 = newwin(7, 54, 0, 8);
|
435
|
-
middeer0 = newwin(15, 42, 0, 8);
|
436
|
-
bigdeer0 = newwin(10, 23, 0, 0);
|
437
|
-
lookdeer0 = newwin(10, 25, 0, 0);
|
438
|
-
|
439
|
-
/* lildeer1 */
|
440
|
-
lildeer1 = newwin(2, 4, 0, 0);
|
441
|
-
lil(lildeer1);
|
442
|
-
mvwaddstr(lildeer1, 1, 1, "<>");
|
443
|
-
|
444
|
-
/* lildeer2 */
|
445
|
-
lildeer2 = newwin(2, 4, 0, 0);
|
446
|
-
lil(lildeer2);
|
447
|
-
mvwaddstr(lildeer2, 1, 1, "||");
|
448
|
-
|
449
|
-
/* lildeer3 */
|
450
|
-
lildeer3 = newwin(2, 4, 0, 0);
|
451
|
-
lil(lildeer3);
|
452
|
-
mvwaddstr(lildeer3, 1, 1, "><");
|
453
|
-
|
454
|
-
/* middeer1 */
|
455
|
-
middeer1 = newwin(3, 7, 0, 0);
|
456
|
-
midtop(middeer1);
|
457
|
-
mvwaddstr(middeer1, 2, 3, "\\/");
|
458
|
-
|
459
|
-
/* middeer2 */
|
460
|
-
middeer2 = newwin(3, 7, 0, 0);
|
461
|
-
midtop(middeer2);
|
462
|
-
mvwaddch(middeer2, 2, 3, (chtype) '|');
|
463
|
-
mvwaddch(middeer2, 2, 5, (chtype) '|');
|
464
|
-
|
465
|
-
/* middeer3 */
|
466
|
-
middeer3 = newwin(3, 7, 0, 0);
|
467
|
-
midtop(middeer3);
|
468
|
-
mvwaddch(middeer3, 2, 2, (chtype) '/');
|
469
|
-
mvwaddch(middeer3, 2, 6, (chtype) '\\');
|
470
|
-
|
471
|
-
/* bigdeer1 */
|
472
|
-
bigdeer1 = newwin(10, 23, 0, 0);
|
473
|
-
bigtop(bigdeer1);
|
474
|
-
legs1(bigdeer1);
|
475
|
-
|
476
|
-
/* bigdeer2 */
|
477
|
-
bigdeer2 = newwin(10, 23, 0, 0);
|
478
|
-
bigtop(bigdeer2);
|
479
|
-
legs2(bigdeer2);
|
480
|
-
|
481
|
-
/* bigdeer3 */
|
482
|
-
bigdeer3 = newwin(10, 23, 0, 0);
|
483
|
-
bigtop(bigdeer3);
|
484
|
-
legs3(bigdeer3);
|
485
|
-
|
486
|
-
/* bigdeer4 */
|
487
|
-
bigdeer4 = newwin(10, 23, 0, 0);
|
488
|
-
bigtop(bigdeer4);
|
489
|
-
legs4(bigdeer4);
|
490
|
-
|
491
|
-
/* lookdeer1 */
|
492
|
-
lookdeer1 = newwin(10, 25, 0, 0);
|
493
|
-
bigface(lookdeer1, noseattr);
|
494
|
-
legs1(lookdeer1);
|
495
|
-
|
496
|
-
/* lookdeer2 */
|
497
|
-
lookdeer2 = newwin(10, 25, 0, 0);
|
498
|
-
bigface(lookdeer2, noseattr);
|
499
|
-
legs2(lookdeer2);
|
500
|
-
|
501
|
-
/* lookdeer3 */
|
502
|
-
lookdeer3 = newwin(10, 25, 0, 0);
|
503
|
-
bigface(lookdeer3, noseattr);
|
504
|
-
legs3(lookdeer3);
|
505
|
-
|
506
|
-
/* lookdeer4 */
|
507
|
-
lookdeer4 = newwin(10, 25, 0, 0);
|
508
|
-
bigface(lookdeer4, noseattr);
|
509
|
-
legs4(lookdeer4);
|
510
|
-
}
|
511
|
-
|
512
|
-
void boxit(void)
|
513
|
-
{
|
514
|
-
int x;
|
515
|
-
|
516
|
-
for (x = 0; x < 20; ++x)
|
517
|
-
mvaddch(x, 7, '|');
|
518
|
-
|
519
|
-
for (x = 0; x < 80; ++x)
|
520
|
-
{
|
521
|
-
if (x > 7)
|
522
|
-
mvaddch(19, x, '_');
|
523
|
-
|
524
|
-
mvaddch(22, x, '_');
|
525
|
-
}
|
526
|
-
}
|
527
|
-
|
528
|
-
void seas(void)
|
529
|
-
{
|
530
|
-
mvaddch(4, 1, 'S');
|
531
|
-
mvaddch(6, 1, 'E');
|
532
|
-
mvaddch(8, 1, 'A');
|
533
|
-
mvaddch(10, 1, 'S');
|
534
|
-
mvaddch(12, 1, 'O');
|
535
|
-
mvaddch(14, 1, 'N');
|
536
|
-
mvaddch(16, 1, '`');
|
537
|
-
mvaddch(18, 1, 'S');
|
538
|
-
}
|
539
|
-
|
540
|
-
void greet(void)
|
541
|
-
{
|
542
|
-
mvaddch(3, 5, 'G');
|
543
|
-
mvaddch(5, 5, 'R');
|
544
|
-
mvaddch(7, 5, 'E');
|
545
|
-
mvaddch(9, 5, 'E');
|
546
|
-
mvaddch(11, 5, 'T');
|
547
|
-
mvaddch(13, 5, 'I');
|
548
|
-
mvaddch(15, 5, 'N');
|
549
|
-
mvaddch(17, 5, 'G');
|
550
|
-
mvaddch(19, 5, 'S');
|
551
|
-
}
|
552
|
-
|
553
|
-
void fromwho(void)
|
554
|
-
{
|
555
|
-
mvaddstr(21, 13, FROMWHO);
|
556
|
-
}
|
557
|
-
|
558
|
-
void del_msg(void)
|
559
|
-
{
|
560
|
-
refresh();
|
561
|
-
}
|
562
|
-
|
563
|
-
void tree(void)
|
564
|
-
{
|
565
|
-
#ifdef A_COLOR
|
566
|
-
if (has_colors())
|
567
|
-
{
|
568
|
-
init_pair(30, COLOR_GREEN, COLOR_BLACK);
|
569
|
-
wattrset(treescrn, COLOR_PAIR(30));
|
570
|
-
}
|
571
|
-
#endif
|
572
|
-
mvwaddch(treescrn, 1, 11, (chtype) '/');
|
573
|
-
mvwaddch(treescrn, 2, 11, (chtype) '/');
|
574
|
-
mvwaddch(treescrn, 3, 10, (chtype) '/');
|
575
|
-
mvwaddch(treescrn, 4, 9, (chtype) '/');
|
576
|
-
mvwaddch(treescrn, 5, 9, (chtype) '/');
|
577
|
-
mvwaddch(treescrn, 6, 8, (chtype) '/');
|
578
|
-
mvwaddch(treescrn, 7, 7, (chtype) '/');
|
579
|
-
mvwaddch(treescrn, 8, 6, (chtype) '/');
|
580
|
-
mvwaddch(treescrn, 9, 6, (chtype) '/');
|
581
|
-
mvwaddch(treescrn, 10, 5, (chtype) '/');
|
582
|
-
mvwaddch(treescrn, 11, 3, (chtype) '/');
|
583
|
-
mvwaddch(treescrn, 12, 2, (chtype) '/');
|
584
|
-
|
585
|
-
mvwaddch(treescrn, 1, 13, (chtype) '\\');
|
586
|
-
mvwaddch(treescrn, 2, 13, (chtype) '\\');
|
587
|
-
mvwaddch(treescrn, 3, 14, (chtype) '\\');
|
588
|
-
mvwaddch(treescrn, 4, 15, (chtype) '\\');
|
589
|
-
mvwaddch(treescrn, 5, 15, (chtype) '\\');
|
590
|
-
mvwaddch(treescrn, 6, 16, (chtype) '\\');
|
591
|
-
mvwaddch(treescrn, 7, 17, (chtype) '\\');
|
592
|
-
mvwaddch(treescrn, 8, 18, (chtype) '\\');
|
593
|
-
mvwaddch(treescrn, 9, 18, (chtype) '\\');
|
594
|
-
mvwaddch(treescrn, 10, 19, (chtype) '\\');
|
595
|
-
mvwaddch(treescrn, 11, 21, (chtype) '\\');
|
596
|
-
mvwaddch(treescrn, 12, 22, (chtype) '\\');
|
597
|
-
|
598
|
-
mvwaddch(treescrn, 4, 10, (chtype) '_');
|
599
|
-
mvwaddch(treescrn, 4, 14, (chtype) '_');
|
600
|
-
mvwaddch(treescrn, 8, 7, (chtype) '_');
|
601
|
-
mvwaddch(treescrn, 8, 17, (chtype) '_');
|
602
|
-
|
603
|
-
mvwaddstr(treescrn, 13, 0,
|
604
|
-
"//////////// \\\\\\\\\\\\\\\\\\\\\\\\");
|
605
|
-
|
606
|
-
#ifdef A_COLOR
|
607
|
-
if (has_colors())
|
608
|
-
{
|
609
|
-
init_pair(20, COLOR_YELLOW, COLOR_BLACK);
|
610
|
-
wattrset(treescrn, COLOR_PAIR(20));
|
611
|
-
}
|
612
|
-
#endif
|
613
|
-
mvwaddstr(treescrn, 14, 11, "| |");
|
614
|
-
mvwaddstr(treescrn, 15, 11, "|_|");
|
615
|
-
|
616
|
-
wrefresh(treescrn);
|
617
|
-
wrefresh(w_del_msg);
|
618
|
-
}
|
619
|
-
|
620
|
-
void balls(void)
|
621
|
-
{
|
622
|
-
chtype ball1, ball2, ball3, ball4, ball5, ball6;
|
623
|
-
|
624
|
-
overlay(treescrn, treescrn2);
|
625
|
-
|
626
|
-
#ifdef A_COLOR
|
627
|
-
if (has_colors())
|
628
|
-
{
|
629
|
-
init_pair(1, COLOR_BLUE, COLOR_BLACK);
|
630
|
-
init_pair(2, COLOR_RED, COLOR_BLACK);
|
631
|
-
init_pair(3, COLOR_MAGENTA, COLOR_BLACK);
|
632
|
-
init_pair(4, COLOR_CYAN, COLOR_BLACK);
|
633
|
-
init_pair(5, COLOR_YELLOW, COLOR_BLACK);
|
634
|
-
init_pair(6, COLOR_WHITE, COLOR_BLACK);
|
635
|
-
ball1 = COLOR_PAIR(1) | '@';
|
636
|
-
ball2 = COLOR_PAIR(2) | '@';
|
637
|
-
ball3 = COLOR_PAIR(3) | '@';
|
638
|
-
ball4 = COLOR_PAIR(4) | '@';
|
639
|
-
ball5 = COLOR_PAIR(5) | '@';
|
640
|
-
ball6 = COLOR_PAIR(6) | '@';
|
641
|
-
}
|
642
|
-
else
|
643
|
-
#endif
|
644
|
-
ball1 = ball2 = ball3 = ball4 = ball5 = ball6 = '@';
|
645
|
-
|
646
|
-
mvwaddch(treescrn2, 3, 9, ball1);
|
647
|
-
mvwaddch(treescrn2, 3, 15, ball2);
|
648
|
-
mvwaddch(treescrn2, 4, 8, ball3);
|
649
|
-
mvwaddch(treescrn2, 4, 16, ball4);
|
650
|
-
mvwaddch(treescrn2, 5, 7, ball5);
|
651
|
-
mvwaddch(treescrn2, 5, 17, ball6);
|
652
|
-
mvwaddch(treescrn2, 7, 6, ball1 | A_BOLD);
|
653
|
-
mvwaddch(treescrn2, 7, 18, ball2 | A_BOLD);
|
654
|
-
mvwaddch(treescrn2, 8, 5, ball3 | A_BOLD);
|
655
|
-
mvwaddch(treescrn2, 8, 19, ball4 | A_BOLD);
|
656
|
-
mvwaddch(treescrn2, 10, 4, ball5 | A_BOLD);
|
657
|
-
mvwaddch(treescrn2, 10, 20, ball6 | A_BOLD);
|
658
|
-
mvwaddch(treescrn2, 11, 2, ball1);
|
659
|
-
mvwaddch(treescrn2, 11, 22, ball2);
|
660
|
-
mvwaddch(treescrn2, 12, 1, ball3);
|
661
|
-
mvwaddch(treescrn2, 12, 23, ball4);
|
662
|
-
|
663
|
-
wrefresh(treescrn2);
|
664
|
-
wrefresh(w_del_msg);
|
665
|
-
}
|
666
|
-
|
667
|
-
void star(void)
|
668
|
-
{
|
669
|
-
mvwaddch(treescrn2, 0, 12, (chtype) '*' | A_STANDOUT);
|
670
|
-
|
671
|
-
wrefresh(treescrn2);
|
672
|
-
wrefresh(w_del_msg);
|
673
|
-
}
|
674
|
-
|
675
|
-
void strng1(void)
|
676
|
-
{
|
677
|
-
#ifdef A_COLOR
|
678
|
-
if (has_colors())
|
679
|
-
{
|
680
|
-
init_pair(10, COLOR_YELLOW, COLOR_BLACK);
|
681
|
-
wattrset(treescrn2, COLOR_PAIR(10) | A_BOLD);
|
682
|
-
}
|
683
|
-
#endif
|
684
|
-
mvwaddstr(treescrn2, 3, 11, ".:'");
|
685
|
-
|
686
|
-
wrefresh(treescrn2);
|
687
|
-
wrefresh(w_del_msg);
|
688
|
-
}
|
689
|
-
|
690
|
-
void strng2(void)
|
691
|
-
{
|
692
|
-
#ifdef A_COLOR
|
693
|
-
if (has_colors())
|
694
|
-
{
|
695
|
-
init_pair(11, COLOR_RED, COLOR_BLACK);
|
696
|
-
wattrset(treescrn2, COLOR_PAIR(11) | A_BOLD);
|
697
|
-
}
|
698
|
-
#endif
|
699
|
-
mvwaddstr(treescrn2, 5, 11, ",.:'");
|
700
|
-
mvwaddstr(treescrn2, 6, 9, ":'");
|
701
|
-
|
702
|
-
wrefresh(treescrn2);
|
703
|
-
wrefresh(w_del_msg);
|
704
|
-
}
|
705
|
-
|
706
|
-
void strng3(void)
|
707
|
-
{
|
708
|
-
#ifdef A_COLOR
|
709
|
-
if (has_colors())
|
710
|
-
{
|
711
|
-
init_pair(12, COLOR_GREEN, COLOR_BLACK);
|
712
|
-
wattrset(treescrn2, COLOR_PAIR(12) | A_BOLD);
|
713
|
-
}
|
714
|
-
#endif
|
715
|
-
mvwaddstr(treescrn2, 7, 13, ",.:'");
|
716
|
-
mvwaddstr(treescrn2, 8, 9, ",.:'");
|
717
|
-
|
718
|
-
wrefresh(treescrn2);
|
719
|
-
wrefresh(w_del_msg);
|
720
|
-
}
|
721
|
-
|
722
|
-
void strng4(void)
|
723
|
-
{
|
724
|
-
#ifdef A_COLOR
|
725
|
-
if (has_colors())
|
726
|
-
{
|
727
|
-
init_pair(13, COLOR_WHITE, COLOR_BLACK);
|
728
|
-
wattrset(treescrn2, COLOR_PAIR(13) | A_BOLD);
|
729
|
-
}
|
730
|
-
#endif
|
731
|
-
mvwaddstr(treescrn2, 9, 14, ",.:'");
|
732
|
-
mvwaddstr(treescrn2, 10, 10, ",.:'");
|
733
|
-
mvwaddstr(treescrn2, 11, 6, ",.:'");
|
734
|
-
mvwaddch(treescrn2, 12, 5, (chtype) '\'');
|
735
|
-
|
736
|
-
wrefresh(treescrn2);
|
737
|
-
wrefresh(w_del_msg);
|
738
|
-
}
|
739
|
-
|
740
|
-
void strng5(void)
|
741
|
-
{
|
742
|
-
#ifdef A_COLOR
|
743
|
-
if (has_colors())
|
744
|
-
{
|
745
|
-
init_pair(14, COLOR_CYAN, COLOR_BLACK);
|
746
|
-
wattrset(treescrn2, COLOR_PAIR(14) | A_BOLD);
|
747
|
-
}
|
748
|
-
#endif
|
749
|
-
mvwaddstr(treescrn2, 11, 16, ",.:'");
|
750
|
-
mvwaddstr(treescrn2, 12, 12, ",.:'");
|
751
|
-
|
752
|
-
/* save a fully lit tree */
|
753
|
-
overlay(treescrn2, treescrn);
|
754
|
-
|
755
|
-
wrefresh(treescrn2);
|
756
|
-
wrefresh(w_del_msg);
|
757
|
-
}
|
758
|
-
|
759
|
-
void blinkit(void)
|
760
|
-
{
|
761
|
-
static int cycle;
|
762
|
-
|
763
|
-
if (cycle > 4)
|
764
|
-
cycle = 0;
|
765
|
-
|
766
|
-
touchwin(treescrn8);
|
767
|
-
|
768
|
-
switch (cycle)
|
769
|
-
{
|
770
|
-
case 0:
|
771
|
-
overlay(treescrn3, treescrn8);
|
772
|
-
break;
|
773
|
-
|
774
|
-
case 1:
|
775
|
-
overlay(treescrn4, treescrn8);
|
776
|
-
break;
|
777
|
-
|
778
|
-
case 2:
|
779
|
-
overlay(treescrn5, treescrn8);
|
780
|
-
break;
|
781
|
-
|
782
|
-
case 3:
|
783
|
-
overlay(treescrn6, treescrn8);
|
784
|
-
break;
|
785
|
-
|
786
|
-
case 4:
|
787
|
-
overlay(treescrn7, treescrn8);
|
788
|
-
}
|
789
|
-
|
790
|
-
wrefresh(treescrn8);
|
791
|
-
wrefresh(w_del_msg);
|
792
|
-
|
793
|
-
napms(50);
|
794
|
-
touchwin(treescrn8);
|
795
|
-
|
796
|
-
/*ALL ON************************************************** */
|
797
|
-
|
798
|
-
overlay(treescrn, treescrn8);
|
799
|
-
wrefresh(treescrn8);
|
800
|
-
wrefresh(w_del_msg);
|
801
|
-
|
802
|
-
++cycle;
|
803
|
-
}
|
804
|
-
|
805
|
-
#define TSHOW(win, pause) touchwin(win); wrefresh(win); \
|
806
|
-
wrefresh(w_del_msg); napms(pause)
|
807
|
-
|
808
|
-
#define SHOW(win, pause) mvwin(win, y_pos, x_pos); wrefresh(win); \
|
809
|
-
wrefresh(w_del_msg); napms(pause)
|
810
|
-
|
811
|
-
void reindeer(void)
|
812
|
-
{
|
813
|
-
int looper;
|
814
|
-
|
815
|
-
y_pos = 0;
|
816
|
-
|
817
|
-
for (x_pos = 70; x_pos > 62; x_pos--)
|
818
|
-
{
|
819
|
-
if (x_pos < 62)
|
820
|
-
y_pos = 1;
|
821
|
-
|
822
|
-
for (looper = 0; looper < 4; looper++)
|
823
|
-
{
|
824
|
-
mvwaddch(dotdeer0, y_pos, x_pos, (chtype) '.');
|
825
|
-
wrefresh(dotdeer0);
|
826
|
-
wrefresh(w_del_msg);
|
827
|
-
werase(dotdeer0);
|
828
|
-
wrefresh(dotdeer0);
|
829
|
-
wrefresh(w_del_msg);
|
830
|
-
}
|
831
|
-
}
|
832
|
-
|
833
|
-
y_pos = 2;
|
834
|
-
|
835
|
-
for (; x_pos > 50; x_pos--)
|
836
|
-
{
|
837
|
-
for (looper = 0; looper < 4; looper++)
|
838
|
-
{
|
839
|
-
if (x_pos < 56)
|
840
|
-
{
|
841
|
-
y_pos = 3;
|
842
|
-
|
843
|
-
mvwaddch(stardeer0, y_pos, x_pos, (chtype) '*');
|
844
|
-
wrefresh(stardeer0);
|
845
|
-
wrefresh(w_del_msg);
|
846
|
-
werase(stardeer0);
|
847
|
-
wrefresh(stardeer0);
|
848
|
-
}
|
849
|
-
else
|
850
|
-
{
|
851
|
-
mvwaddch(dotdeer0, y_pos, x_pos, (chtype) '*');
|
852
|
-
wrefresh(dotdeer0);
|
853
|
-
wrefresh(w_del_msg);
|
854
|
-
werase(dotdeer0);
|
855
|
-
wrefresh(dotdeer0);
|
856
|
-
}
|
857
|
-
wrefresh(w_del_msg);
|
858
|
-
}
|
859
|
-
}
|
860
|
-
|
861
|
-
x_pos = 58;
|
862
|
-
|
863
|
-
for (y_pos = 2; y_pos < 5; y_pos++)
|
864
|
-
{
|
865
|
-
TSHOW(lildeer0, 50);
|
866
|
-
|
867
|
-
for (looper = 0; looper < 4; looper++)
|
868
|
-
{
|
869
|
-
SHOW(lildeer3, 50);
|
870
|
-
SHOW(lildeer2, 50);
|
871
|
-
SHOW(lildeer1, 50);
|
872
|
-
SHOW(lildeer2, 50);
|
873
|
-
SHOW(lildeer3, 50);
|
874
|
-
|
875
|
-
TSHOW(lildeer0, 50);
|
876
|
-
|
877
|
-
x_pos -= 2;
|
878
|
-
}
|
879
|
-
}
|
880
|
-
|
881
|
-
x_pos = 35;
|
882
|
-
|
883
|
-
for (y_pos = 5; y_pos < 10; y_pos++)
|
884
|
-
{
|
885
|
-
touchwin(middeer0);
|
886
|
-
wrefresh(middeer0);
|
887
|
-
wrefresh(w_del_msg);
|
888
|
-
|
889
|
-
for (looper = 0; looper < 2; looper++)
|
890
|
-
{
|
891
|
-
SHOW(middeer3, 50);
|
892
|
-
SHOW(middeer2, 50);
|
893
|
-
SHOW(middeer1, 50);
|
894
|
-
SHOW(middeer2, 50);
|
895
|
-
SHOW(middeer3, 50);
|
896
|
-
|
897
|
-
TSHOW(middeer0, 50);
|
898
|
-
|
899
|
-
x_pos -= 3;
|
900
|
-
}
|
901
|
-
}
|
902
|
-
|
903
|
-
napms(2000);
|
904
|
-
|
905
|
-
y_pos = 1;
|
906
|
-
|
907
|
-
for (x_pos = 8; x_pos < 16; x_pos++)
|
908
|
-
{
|
909
|
-
SHOW(bigdeer4, 30);
|
910
|
-
SHOW(bigdeer3, 30);
|
911
|
-
SHOW(bigdeer2, 30);
|
912
|
-
SHOW(bigdeer1, 30);
|
913
|
-
SHOW(bigdeer2, 30);
|
914
|
-
SHOW(bigdeer3, 30);
|
915
|
-
SHOW(bigdeer4, 30);
|
916
|
-
SHOW(bigdeer0, 30);
|
917
|
-
}
|
918
|
-
|
919
|
-
--x_pos;
|
920
|
-
|
921
|
-
for (looper = 0; looper < 6; looper++)
|
922
|
-
{
|
923
|
-
SHOW(lookdeer4, 40);
|
924
|
-
SHOW(lookdeer3, 40);
|
925
|
-
SHOW(lookdeer2, 40);
|
926
|
-
SHOW(lookdeer1, 40);
|
927
|
-
SHOW(lookdeer2, 40);
|
928
|
-
SHOW(lookdeer3, 40);
|
929
|
-
SHOW(lookdeer4, 40);
|
930
|
-
}
|
931
|
-
|
932
|
-
SHOW(lookdeer0, 40);
|
933
|
-
|
934
|
-
for (; y_pos < 10; y_pos++)
|
935
|
-
{
|
936
|
-
for (looper = 0; looper < 2; looper++)
|
937
|
-
{
|
938
|
-
SHOW(bigdeer4, 30);
|
939
|
-
SHOW(bigdeer3, 30);
|
940
|
-
SHOW(bigdeer2, 30);
|
941
|
-
SHOW(bigdeer1, 30);
|
942
|
-
SHOW(bigdeer2, 30);
|
943
|
-
SHOW(bigdeer3, 30);
|
944
|
-
SHOW(bigdeer4, 30);
|
945
|
-
}
|
946
|
-
|
947
|
-
SHOW(bigdeer0, 30);
|
948
|
-
}
|
949
|
-
|
950
|
-
--y_pos;
|
951
|
-
|
952
|
-
mvwin(lookdeer3, y_pos, x_pos);
|
953
|
-
wrefresh(lookdeer3);
|
954
|
-
wrefresh(w_del_msg);
|
955
|
-
}
|