604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
|
}
}
}
SDL_LockSurface(screen);
}
static void pop_quiz(int x,int y,PopLine*li,Uint8 c,Uint8 v) {
}
void draw_popup(const unsigned char*txt) {
static colo[8]={1,144,188,173,83,98,218,15};
static PopLine li[64];
SDL_Rect r;
int bx,by,x,y,c;
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
|
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
|
}
}
}
SDL_LockSurface(screen);
}
static void pop_quiz(int x,int y,PopLine*li,Uint8 c,Uint8 v) {
SDL_Rect r;
Uint8*p=screen->pixels;
Uint16 pitch=screen->pitch;
int xx,yy;
const unsigned char*f=fontdata+(v<<3);
if(li->h>16) y+=(li->h-16)/2;
r.x=x;
r.y=y;
r.w=r.h=16;
SDL_FillRect(screen,&r,0x07);
if(y+16>=screen->h || x+24>=screen->w) return;
p+=(y+4)*pitch+x+4;
for(yy=0;yy<8;yy++) {
for(xx=0;xx<8;xx++) p[xx]=(*f<<xx)&128?c:0x07;
p+=pitch;
++f;
}
}
void draw_popup(const unsigned char*txt) {
static colo[8]={1,144,188,173,83,98,218,15};
static PopLine li[64];
SDL_Rect r;
int bx,by,x,y,c;
|