mirror of
https://github.com/abakh/nbsdgames.git
synced 2025-01-03 14:56:23 -05:00
fix PDCurses conflict
This commit is contained in:
parent
f27eb28a8c
commit
1d065062a6
1
nbsdgames
Submodule
1
nbsdgames
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit f27eb28a8c22aa899019d1ae194d4d0592317336
|
@ -46,7 +46,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(bool ingame){
|
||||
MEVENT minput;
|
||||
getmouse(&minput);
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if(minput.bstate & (BUTTON1_CLICKED|BUTTON1_RELEASED)){
|
||||
if( minput.y-4 < 10){
|
||||
if( (ingame && minput.x-23<20 && minput.x-23>=0 ) || (!ingame && minput.x-1<20) ){//it most be on the trackboard if ingame is true
|
||||
|
@ -440,7 +440,11 @@ void sigint_handler(int x){
|
||||
|
||||
void mouseinput(void){
|
||||
MEVENT minput;
|
||||
getmouse(&minput);
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4 <8 && minput.x-1<16){
|
||||
py=minput.y-4;
|
||||
px=(minput.x-1)/2;
|
||||
|
@ -135,7 +135,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(void){
|
||||
MEVENT minput;
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4<size && minput.x-1<size*2){
|
||||
py=minput.y-4;
|
||||
px=(minput.x-1)/2;
|
||||
|
@ -116,7 +116,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(void){
|
||||
MEVENT minput;
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4<size && minput.x-1<size2){
|
||||
py=minput.y-4;
|
||||
px=(minput.x-1);
|
||||
|
@ -148,7 +148,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(int sy, int sx){
|
||||
MEVENT minput;
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4-sy<len && minput.x-1-sx<wid*2){
|
||||
py=minput.y-4-sy;
|
||||
px=(minput.x-1-sx)/2;
|
||||
|
@ -277,7 +277,11 @@ void draw(bitbox board[len][wid]){
|
||||
|
||||
void mouseinput(void){
|
||||
MEVENT minput;
|
||||
getmouse(&minput);
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4 <len && minput.x-1<wid*2){
|
||||
py=minput.y-(1+SY);
|
||||
px=minput.x-(1+SX);
|
||||
|
@ -215,7 +215,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(void){
|
||||
MEVENT minput;
|
||||
getmouse(&minput);
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4 <8 && minput.x-1<16){
|
||||
py=minput.y-4;
|
||||
px=(minput.x-1)/2;
|
||||
|
@ -179,7 +179,11 @@ void sigint_handler(int x){
|
||||
}
|
||||
void mouseinput(int sy,int sx){
|
||||
MEVENT minput;
|
||||
getmouse(&minput);
|
||||
#ifdef PDCURSES
|
||||
nc_getmouse(&minput);
|
||||
#else
|
||||
getmouse(&minput);
|
||||
#endif
|
||||
if( minput.y-4-sy <len && minput.x-1-sx<wid*2){
|
||||
py=minput.y-4-sy;
|
||||
px=(minput.x-1-sx)/2;
|
||||
|
Loading…
Reference in New Issue
Block a user