mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 03:00:46 +00:00
Fix for a problem with the automatic color selection setting for player color and add some additional informational text to the screen when someone has called a vote.
git-svn-id: https://svn.eduke32.com/eduke32@273 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
511a6517cb
commit
827eb34b95
2 changed files with 28 additions and 10 deletions
|
@ -76,6 +76,7 @@ static int netparamcount = 0;
|
||||||
static char **netparam = NULL;
|
static char **netparam = NULL;
|
||||||
|
|
||||||
int votes[MAXPLAYERS], gotvote[MAXPLAYERS], voting = -1;
|
int votes[MAXPLAYERS], gotvote[MAXPLAYERS], voting = -1;
|
||||||
|
int vote_map, vote_episode;
|
||||||
|
|
||||||
int recfilep,totalreccnt;
|
int recfilep,totalreccnt;
|
||||||
char debug_on = 0,actor_tog = 0,*rtsptr,memorycheckoveride=0;
|
char debug_on = 0,actor_tog = 0,*rtsptr,memorycheckoveride=0;
|
||||||
|
@ -533,6 +534,8 @@ if( !(ps[myconnectindex].gm&MODE_GAME) ) { OSD_DispatchQueued(); }
|
||||||
|
|
||||||
case 1: // call map vote
|
case 1: // call map vote
|
||||||
voting = packbuf[2];
|
voting = packbuf[2];
|
||||||
|
vote_episode = packbuf[3];
|
||||||
|
vote_map = packbuf[4];
|
||||||
Bsprintf(tempbuf,"%s HAS CALLED A VOTE TO CHANGE MAP TO %s (E%dL%d)",ud.user_name[packbuf[2]],level_names[packbuf[3]*11 + packbuf[4]],packbuf[3]+1,packbuf[4]+1);
|
Bsprintf(tempbuf,"%s HAS CALLED A VOTE TO CHANGE MAP TO %s (E%dL%d)",ud.user_name[packbuf[2]],level_names[packbuf[3]*11 + packbuf[4]],packbuf[3]+1,packbuf[4]+1);
|
||||||
adduserquote(tempbuf);
|
adduserquote(tempbuf);
|
||||||
Bsprintf(tempbuf,"PRESS F1 TO VOTE YES, F2 TO VOTE NO");
|
Bsprintf(tempbuf,"PRESS F1 TO VOTE YES, F2 TO VOTE NO");
|
||||||
|
@ -2098,8 +2101,16 @@ void tics(void)
|
||||||
j=(TICRATE*AVERAGEFRAMES)/(i-frameval[framecnt]);
|
j=(TICRATE*AVERAGEFRAMES)/(i-frameval[framecnt]);
|
||||||
if (ud.tickrate && !(ps[myconnectindex].gm&MODE_MENU))
|
if (ud.tickrate && !(ps[myconnectindex].gm&MODE_MENU))
|
||||||
{
|
{
|
||||||
|
int k = 1;
|
||||||
|
|
||||||
|
if(ud.screen_size != 0 && GTFLAGS(GAMETYPE_FLAG_FRAGBAR))
|
||||||
|
{
|
||||||
|
k += 8;
|
||||||
|
if(ud.multimode > 4)
|
||||||
|
k += 8;
|
||||||
|
}
|
||||||
Bsprintf(b,"%ld",j>0?j:0);
|
Bsprintf(b,"%ld",j>0?j:0);
|
||||||
minitext(320-strlen(b)*4,ud.screen_size!=0?(ud.multimode>1&&ud.multimode<5?9:(ud.multimode>4?17:1)):1,b,(TICRATE*AVERAGEFRAMES)/(i-frameval[framecnt]) < 40?2:0,26);
|
minitext(320-strlen(b)*4,k,b,(TICRATE*AVERAGEFRAMES)/(i-frameval[framecnt]) < 40?2:0,26);
|
||||||
}
|
}
|
||||||
framerate = j;
|
framerate = j;
|
||||||
frameval[framecnt] = i;
|
frameval[framecnt] = i;
|
||||||
|
@ -6836,8 +6847,7 @@ FOUNDCHEAT:
|
||||||
|
|
||||||
sprite[ps[myconnectindex].i].hitag = 0;
|
sprite[ps[myconnectindex].i].hitag = 0;
|
||||||
sprite[ps[myconnectindex].i].lotag = 0;
|
sprite[ps[myconnectindex].i].lotag = 0;
|
||||||
sprite[ps[myconnectindex].i].pal =
|
sprite[ps[myconnectindex].i].pal = ps[myconnectindex].palookup;
|
||||||
ps[myconnectindex].palookup;
|
|
||||||
|
|
||||||
FTA(17,&ps[myconnectindex]);
|
FTA(17,&ps[myconnectindex]);
|
||||||
}
|
}
|
||||||
|
@ -8853,7 +8863,6 @@ void updatenames(void)
|
||||||
ps[myconnectindex].auto_aim = AutoAim;
|
ps[myconnectindex].auto_aim = AutoAim;
|
||||||
ps[myconnectindex].weaponswitch = ud.weaponswitch;
|
ps[myconnectindex].weaponswitch = ud.weaponswitch;
|
||||||
ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = ud.color;
|
ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = ud.color;
|
||||||
|
|
||||||
j = ps[myconnectindex].team;
|
j = ps[myconnectindex].team;
|
||||||
ps[myconnectindex].team = ud.pteam[myconnectindex] = ud.team;
|
ps[myconnectindex].team = ud.pteam[myconnectindex] = ud.team;
|
||||||
|
|
||||||
|
@ -9272,7 +9281,10 @@ MAIN_LOOP_RESTART:
|
||||||
case 1: k = 21; break;
|
case 1: k = 21; break;
|
||||||
}
|
}
|
||||||
ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = k;
|
ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = k;
|
||||||
} else ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = ud.color;
|
} else {
|
||||||
|
if(ud.color) ps[myconnectindex].palookup = ud.pcolor[myconnectindex] = ud.color;
|
||||||
|
else ps[myconnectindex].palookup = ud.pcolor[myconnectindex];
|
||||||
|
}
|
||||||
|
|
||||||
ud.warp_on = 0;
|
ud.warp_on = 0;
|
||||||
KB_KeyDown[sc_Pause] = 0; // JBF: I hate the pause key
|
KB_KeyDown[sc_Pause] = 0; // JBF: I hate the pause key
|
||||||
|
@ -9352,7 +9364,13 @@ MAIN_LOOP_RESTART:
|
||||||
displayrest(i);
|
displayrest(i);
|
||||||
|
|
||||||
if(gotvote[myconnectindex] == 0 && voting != -1 && voting != myconnectindex)
|
if(gotvote[myconnectindex] == 0 && voting != -1 && voting != myconnectindex)
|
||||||
gametext(160,60,"PRESS F1 TO VOTE YES, F2 TO VOTE NO",0,2+8+16);
|
{
|
||||||
|
Bsprintf(tempbuf,"%s HAS CALLED A VOTE FOR MAP",ud.user_name[voting]);
|
||||||
|
gametext(160,40,tempbuf,0,2+8+16);
|
||||||
|
Bsprintf(tempbuf,"%s (E%dL%d)",level_names[vote_episode*11 + vote_map],vote_episode+1,vote_map+1);
|
||||||
|
gametext(160,48,tempbuf,0,2+8+16);
|
||||||
|
gametext(160,70,"PRESS F1 TO VOTE YES, F2 TO VOTE NO",0,2+8+16);
|
||||||
|
}
|
||||||
|
|
||||||
// if( KB_KeyPressed(sc_F) )
|
// if( KB_KeyPressed(sc_F) )
|
||||||
// {
|
// {
|
||||||
|
|
|
@ -1237,11 +1237,11 @@ void resetpspritevars(char g)
|
||||||
k=0;
|
k=0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
s->pal = ps[j].palookup = which_palookup++;
|
ud.pcolor[j] = s->pal = ps[j].palookup = which_palookup++;
|
||||||
if( which_palookup >= 17 )
|
if( which_palookup >= 17 )
|
||||||
which_palookup = 9;
|
which_palookup = 9;
|
||||||
}
|
}
|
||||||
else ps[j].palookup = s->pal;
|
else ud.pcolor[j] = ps[j].palookup = s->pal;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue