Merge branch 'lua-battlefullscreen-expose' into v1-lua-stuff
This commit is contained in:
commit
55815eb829
14
src/k_kart.c
14
src/k_kart.c
|
@ -8180,6 +8180,11 @@ static void K_drawBattleFullscreen(void)
|
||||||
INT32 y = -64+(stplyr->kartstuff[k_cardanimation]); // card animation goes from 0 to 164, 164 is the middle of the screen
|
INT32 y = -64+(stplyr->kartstuff[k_cardanimation]); // card animation goes from 0 to 164, 164 is the middle of the screen
|
||||||
INT32 splitflags = V_SNAPTOTOP; // I don't feel like properly supporting non-green resolutions, so you can have a misuse of SNAPTO instead
|
INT32 splitflags = V_SNAPTOTOP; // I don't feel like properly supporting non-green resolutions, so you can have a misuse of SNAPTO instead
|
||||||
fixed_t scale = FRACUNIT;
|
fixed_t scale = FRACUNIT;
|
||||||
|
boolean drawcomebacktimer = true; // lazy hack because it's cleaner in the long run.
|
||||||
|
#ifdef HAVE_BLUA
|
||||||
|
if (!LUA_HudEnabled(hud_battlecomebacktimer))
|
||||||
|
drawcomebacktimer = false;
|
||||||
|
#endif
|
||||||
|
|
||||||
if (splitscreen)
|
if (splitscreen)
|
||||||
{
|
{
|
||||||
|
@ -8231,7 +8236,7 @@ static void K_drawBattleFullscreen(void)
|
||||||
else
|
else
|
||||||
K_drawKartFinish();
|
K_drawKartFinish();
|
||||||
}
|
}
|
||||||
else if (stplyr->kartstuff[k_bumper] <= 0 && stplyr->kartstuff[k_comebacktimer] && comeback && !stplyr->spectator)
|
else if (stplyr->kartstuff[k_bumper] <= 0 && stplyr->kartstuff[k_comebacktimer] && comeback && !stplyr->spectator && drawcomebacktimer)
|
||||||
{
|
{
|
||||||
UINT16 t = stplyr->kartstuff[k_comebacktimer]/(10*TICRATE);
|
UINT16 t = stplyr->kartstuff[k_comebacktimer]/(10*TICRATE);
|
||||||
INT32 txoff, adjust = (splitscreen > 1) ? 4 : 6; // normal string is 8, kart string is 12, half of that for ease
|
INT32 txoff, adjust = (splitscreen > 1) ? 4 : 6; // normal string is 8, kart string is 12, half of that for ease
|
||||||
|
@ -8789,8 +8794,15 @@ void K_drawKartHUD(void)
|
||||||
|
|
||||||
if (battlefullscreen)
|
if (battlefullscreen)
|
||||||
{
|
{
|
||||||
|
#ifdef HAVE_BLUA
|
||||||
|
if (LUA_HudEnabled(hud_battlefullscreen))
|
||||||
|
{
|
||||||
|
#endif
|
||||||
K_drawBattleFullscreen();
|
K_drawBattleFullscreen();
|
||||||
return;
|
return;
|
||||||
|
#ifdef HAVE_BLUA
|
||||||
|
} // yes we legit checked if we had lua to close a single bracket. Not my proudest code edit tbh.
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// Draw the item window
|
// Draw the item window
|
||||||
|
|
|
@ -21,6 +21,8 @@ enum hud {
|
||||||
hud_position,
|
hud_position,
|
||||||
hud_minirankings, // Rankings to the left
|
hud_minirankings, // Rankings to the left
|
||||||
hud_battlebumpers, // mini rankings battle bumpers.
|
hud_battlebumpers, // mini rankings battle bumpers.
|
||||||
|
hud_battlefullscreen, // battle huge text (WAIT, WIN, LOSE ...) + karma comeback time
|
||||||
|
hud_battlecomebacktimer, // comeback timer in battlefullscreen. separated for ease of use.
|
||||||
hud_wanted,
|
hud_wanted,
|
||||||
hud_speedometer,
|
hud_speedometer,
|
||||||
hud_freeplay,
|
hud_freeplay,
|
||||||
|
|
|
@ -48,6 +48,8 @@ static const char *const hud_disable_options[] = {
|
||||||
"position",
|
"position",
|
||||||
"minirankings", // Gametype rankings to the left
|
"minirankings", // Gametype rankings to the left
|
||||||
"battlerankingsbumpers", // bumper drawer for battle. Useful if you want to make a custom battle gamemode without bumpers being involved.
|
"battlerankingsbumpers", // bumper drawer for battle. Useful if you want to make a custom battle gamemode without bumpers being involved.
|
||||||
|
"battlefullscreen", // battlefullscreen func (WAIT, ATTACK OR PROTECT ...)
|
||||||
|
"battlecomebacktimer", // come back timer in battlefullscreen
|
||||||
"wanted",
|
"wanted",
|
||||||
"speedometer",
|
"speedometer",
|
||||||
"freeplay",
|
"freeplay",
|
||||||
|
|
Loading…
Reference in New Issue