http://www.ousob.com --- Legacy Redefined #include <extend50.h> int far *vidBuff = (int far *)0xB8000000; typedef struct { unsigned int ch_attr : 8; unsigned int foreGround : 3; unsigned int intensity : 1; unsigned int backGround : 3; unsigned int blink : 1; } ATTR; typedef union { struct { unsigned char character; unsigned char attribute; } c; ATTR a; } CHR; CHR ch; unsigned char mgc(int row, int col); CLIPPER b_shadow() { int t = _parni(1); int l = _parni(2); int b = _parni(3); int r = _parni(4); int row = _parni(1); int col = _parni(2); int ht = ( _parni(3) - _parni(1) ); int wd = ( _parni(4) - _parni(2) ); if( !ISNUM(1) && !ISNUM(2) && !ISNUM(3) && !ISNUM(4) ){ _ret(); return; } ch.a.foreGround = 8; ch.a.intensity = 1; ch.a.backGround = 0; col = (l + wd + 1); for(row=(t+1); row <=(t+1+ht); row++){ *(vidBuff + (row*80) + col) = mgc(row,col) | ch.c.attribute<<8; } row = (b+1); for(col=(l+2); col<(l+2+wd); col++){ *(vidBuff + (row*80) + col) = mgc(row,col) | ch.c.attribute<<8; } _ret(); } unsigned char mgc(int row, int col) { return *(vidBuff + (row * 80) + col); }