📄 menu6.c
字号:
/* 谋略菜单 */
void menu6(int x,int y)
{int size,buttons=0,temp,temp1,temp2;
char *buffer;
size=imagesize(352,315,402,405);
buffer=malloc(size);
cursoroff();
getimage(352,315,402,405,buffer);
putimage(352,315,buffer,XOR_PUT);
setcolor(WHITE);
rectangle(352,315,402,405);
paint(WHITE,360,350,1);
line(352,345,402,345);
line(352,375,402,375);
printxs(362,322,"反间?",YELLOW);
printxs(362,352,"流言",YELLOW);
printxs(362,382,"笼络",YELLOW);
for(;;)
{
mouse(&x,&y,&buttons);
if (buttons==1)
{
if (x>352 && x<402 && y>315 && y<345) {temp=heromenu(352,255,"笼络");if (temp!=0) {midtemp=temp;temp=housemenu(352,275,"对方");
if (temp!=0) {temp1=action;action=temp;temp=heromenu(352,255,"笼络");action=temp1;if (temp!=0) {herodat[midtemp].action=1;
temp1=herodat[midtemp].mental-herodat[temp].mental;viewfanjian(temp,temp1);}}}break;}
if (x>352 && x<402 && y>345 && y<375) {temp=heromenu(352,255,"笼络");if (temp!=0) {midtemp=temp;temp=housemenu(352,275,"对方");
if (temp!=0) {herodat[midtemp].action=1;temp1=herodat[midtemp].mental-housedat[temp].mingzhong;viewtalk(temp,temp1);}}break;}
if (x>352 && x<402 && y>375 && y<405) {temp=heromenu(352,255,"笼络");if (temp!=0) {midtemp=temp;temp=housemenu(352,275,"对方");
if (temp!=0) {temp1=action;action=temp;temp2=temp;temp=heromenu(352,255,"笼络");action=temp1;
if (temp!=0 && strcmp(herodat[temp].name,"刘备")!=0 && strcmp(herodat[temp].name,"孙权")!=0 && strcmp(herodat[temp].name,"曹操")!=0)
{herodat[midtemp].action=1;viewlongla(temp,temp2);}}}break;}
if (x<352 || x>402 || y<315 || y>455) break;
}
if (buttons==2) break;
}cursoroff();
putimage(352,315,buffer,COPY_PUT);
free(buffer);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -