Category : Assembly Language Source Code
Archive   : VGAKIT60.ZIP
Filename : STICKS.C

 
Output of file : STICKS.C contained in archive : VGAKIT60.ZIP
/*
VGAKIT Version 6.0

Copyright 1988,89,90,91,92,93,94 John Bridges
Free for use in commercial, shareware or freeware applications

STICKS.C
*/


extern int maxx,maxy;

extern void bline(int x1,int y1,int x2,int y2,int color,void (*func)());
extern void xpoint(),xpoint13x();

#define KBHEAD (*(unsigned int far *)0x0040001al)
#define KBTAIL (*(unsigned int far *)0x0040001cl)

main(argc,argv)
int argc;
char **argv;
{
unsigned char palbuf[256][3];
int svga;
unsigned int color;
unsigned int x,y,mx;
void (*func)();

for(x=0;x<256;x++)
{
y=x&63;
if(x&64) y=63-y;
palbuf[x][0]=y;
palbuf[x][1]=y*y/63;
y=(x>>1)&63;
if(x&128) y=63-y;
palbuf[x][2]=y;
}
svga=whichvga();
if(svga)
{
svga640();
func=xpoint;
}
else
{
mode13x();
func=xpoint13x;
}
setmany(palbuf,0,256);
if(maxx>maxy)
mx=maxx;
else
mx=maxy;

for(x=0;x {
for(y=0;y {
bline(x,y,y,x,y&0xff,func);
if(KBHEAD!=KBTAIL)
goto done;
}
}
done: getch();
txtmode();
}




  3 Responses to “Category : Assembly Language Source Code
Archive   : VGAKIT60.ZIP
Filename : STICKS.C

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/