#include #include #include #include #include #include #include #include #include #include #include #define sp textheight("A")+1 int gposx=5,gposy=30,twidth=8,theight=10; int center (char *num){return (320-(textwidth(num)/2));} //int center (int fp,int lp,int num){return ((lp-fp)/2)-(textwidth(num)/2);//return (((lp-fp)/2)-((num/2)*8))+fp;} //int centery(int tp,int bt,int num){return (((bt-tp)/2)-(textheight(num)/2)+tp-3;} void gout(char *);void gout(int,int,char *);void gendl(); void gout(int nam){char namc[6];namc[0]='\0';itoa(nam,namc,10);char n[1];n[0]='\0';strcat(namc,n);gout(namc);} void gout(long nam){char namc[50];namc[0]='\0';ltoa(nam,namc,10);char n[1];n[0]='\0';strcat(namc,n);gout(namc);} void gout(int x,int y,int nam){char namc[6];namc[0]='\0';itoa(nam,namc,10);char n[1];n[0]='\0';strcat(namc,n);gout(x,y,namc);} void lgout(int x,int y,long nam){char namc[50];namc[0]='\0';ltoa(nam,namc,10);char n[1];n[0]='\0';strcat(namc,n);gout(x,y,namc);} void gout(char nam){char namc[2];namc[0]=nam;;namc[1]='\0';gout(namc);} void gout(int x,int y,char nam){char namc[2];namc[0]=nam;namc[1]='\0';gout(x,y,namc);} void gout(char *nam) // someday my son, you too will truly be recursive { setcolor(0); int ovr=0;int len=strlen(nam)*twidth; if(len+gposx>640) {ovr=(gposx+len)-640; outtextxy(gposx,gposy,nam); char mid[5000]; // ----> make me smrt!! <---- int y=0;for(int x=(len-ovr)/twidth;x"); gout(134,6,"-Stop-"); //138 205 gout(191,6,"Reload"); setlinestyle(0,1,3); line(618,5 ,631,14); line(618,14,631,5); settextstyle(2,HORIZ_DIR,1);setusercharsize(1,1,1,1); //cout<<"l:"<cx && xcy && ycx && xcy && ycx && xcy && ycx+cw || ycl){ HideMouse();setcolor(7);rectangle(cx,cy,cx+cw,cy+cl);ShowMouse();}; ox=x;oy=y; }; }; if(x>cx && xcy && yc*57+15 && x2 && y<15){if(click_butt(c*57+15,2,57,15,ha,c)==1){return 0;};};};}; ox=x;oy=y; if(kbhit()){ch=getch(); settextstyle(2,HORIZ_DIR,1);setusercharsize(1,1,1,1); setcolor(0); int grr=0; if(ch==13){savurl();return 1;} if(ch==27){return 0;} if(ch==71){grr=1;cpos=250;} if(ch==79){grr=1;cpos=500;} if(ch==75){grr=1;if(cpos>250){cpos-=textwidth("a");};} if(ch==79){grr=1;if(cpos<490){cpos+=textwidth("a");};} if(ch==80){//FILE *fout;if( //(fout=fopen("ce.cfg","rt")!=NULL){ //int i=0;while(!feof(fout)){cpos+=textwidth("a");;loc[i++]=getc(fout);}; //fclose(fout);loc[i]='\0'; } if(ch==8){grr=1;if(cpos>250){loc[--cur]='\0';cpos-=textwidth("a");HideMouse();setfillstyle(1,15);bar(cpos,7,cpos+textwidth("a"),16);ShowMouse();};} else if(grr==0){if(cpos<490){ char chs[2];chs[0]=ch;chs[1]='\0'; strcat(loc,chs);HideMouse(); setfillstyle(1,15);bar(cpos,7,cpos+textwidth("a"),16); gout(cpos,4,char(ch));ShowMouse();cpos+=textwidth("a");cur++;};}; }; ReadMouse(&y,&x,&b); }; return 0; } int ONEHUGE___MOTHA_____IF() // BITE ME MAN WITH NO TITLES!!!! {int x,y,b,ox,oy; ShowMouse(); ReadMouse(&y,&x,&b);int q=0; ox=x;oy=y;int ha=0,c=0;char ch=' '; while(ch!=27 && q==0){ ShowMouse(); if(kbhit()){ch=getch();if(ch==9){if(locbox()==1){openloc();};};}; ReadMouse(&y,&x,&b); //if(ox!=x || oy!=y){ for(c=0;c<4;c++){ReadMouse(&y,&x,&b);if(ha==0 && x>c*57+15 && x2 && y<15){if(click_butt(c*57+15,2,57,15,ha,c)==1){return 0;};};//}; ReadMouse(&y,&x,&b);if(ha==0 && x>615 && x<635 && y>2 && y<17){if(click_butt(615,2,20,15,ha,4)==1){return 0;};}; ReadMouse(&y,&x,&b);if(x>250 && x<500 && y>5 && y<17){ReadMouse(&y,&x,&b);if(b==1){if(locbox()==1){openloc();};};ShowMouse(); }; ha=0; }; ox=x;oy=y; }; return 0; } /* BLACK ³ 0 ³ Yes ³ Yes BLUE ³ 1 ³ Yes ³ Yes GREEN ³ 2 ³ Yes ³ Yes CYAN ³ 3 ³ Yes ³ Yes RED ³ 4 ³ Yes ³ Yes MAGENTA ³ 5 ³ Yes ³ Yes BROWN ³ 6 ³ Yes ³ Yes LIGHTGRAY ³ 7 ³ Yes ³ Yes DARKGRAY ³ 8 ³ No ³ Yes LIGHTBLUE ³ 9 ³ No ³ Yes LIGHTGREEN ³ 10 ³ No ³ Yes LIGHTCYAN ³ 11 ³ No ³ Yes LIGHTRED ³ 12 ³ No ³ Yes LIGHTMAGENTA ³ 13 ³ No ³ Yes YELLOW ³ 14 ³ No ³ Yes WHITE ³ 15 ³ No ³ Yes */ void main() { clrscr(); int gdriver = DETECT, gmode, errorcode; initgraph(&gdriver, &gmode, "c:\\tc\\bgi"); cleardevice(); setcolor(15); strnset(loc,'\0',1); gposx=0;gposy=23; intro(); /* line single; node *new_node; int x; int m=0,i=0; while(m!=9){ for (i=1; i <=20; i++) { new_node = new node; //this line actually goes to the memory stack and gets new_node -> value = i; //a node's worth of memory single.append_node (new_node); } node *n; */ ActivMouse();ResetMouse();HideMouse(); cleardevice(); initbutt(); ONEHUGE___MOTHA_____IF(); ResetMouse();HideMouse(); //getch(); }