move kart hud stuff into k_hud

hope i got everything lol
This commit is contained in:
Alug committed 2025-07-01 18:26:54 +02:00
1 parent c78a33f66e
commit 2cd5d4f8a8
13 files changed
+4896 -4817

No files matched your search

+1
View File
@@ -79,6 +79,7 @@ p_tick.c
p_user.c
k_director.c
k_kart.c
k_hud.c
k_stats.c
lua_baselib.c
lua_blockmaplib.c
+1
View File
@@ -73,6 +73,7 @@
#include "d_protocol.h"
#include "m_perfstats.h"
#include "k_kart.h"
#include "k_hud.h"
#include "core/memory.h"
+1
View File
@@ -50,6 +50,7 @@
#include "s_sound.h" // song credits
#include "k_kart.h"
#include "k_hud.h"
#include "m_textinput.h"
+4800
View File
File diff suppressed because it is too large. Load diff
+81
View File
@@ -0,0 +1,81 @@
// SONIC ROBO BLAST 2 KART
//-----------------------------------------------------------------------------
// Copyright (C) 2018-2020 by Kart Krew
//
// This program is free software distributed under the
// terms of the GNU General Public License, version 2.
// See the 'LICENSE' file for more details.
//-----------------------------------------------------------------------------
/// \file k_hud.h
/// \brief HUD drawing functions exclusive to Kart
#ifndef __K_HUD__
#define __K_HUD__
#ifdef __cplusplus
extern "C" {
#endif
#include "doomdef.h"
#include "d_player.h" // Need for player_t
#include "command.h"
#include "r_defs.h"
UINT8 K_GetHudColor(void);
boolean K_UseColorHud(void);
boolean K_UseHighResPortraits(void);
patch_t *K_GetFacePrefix(player_t *player, INT32 skinnum);
void K_RegisterKartHudStuff(void);
extern consvar_t cv_colorizedhud,
cv_colorizeditembox,
cv_colorizedhudcolor;
extern consvar_t cv_darkitembox;
extern consvar_t cv_biglaps;
extern consvar_t cv_highresportrait;
extern consvar_t cv_stat_xoffset, cv_stat_yoffset;
extern consvar_t cv_showstats;
extern consvar_t cv_fancyroulette;
extern consvar_t cv_showlaptimes;
extern consvar_t cv_battlespeedo;
extern consvar_t cv_multiitemicon;
extern consvar_t cv_huditemamount;
#define NUMSPEEDOSTUFF 8
extern CV_PossibleValue_t speedo_cons_t[NUMSPEEDOSTUFF];
#define NUMDGAUGESTUFF 6
extern CV_PossibleValue_t driftgaugestyle_cons_t[NUMDGAUGESTUFF];
#define NUMINPUTDISPLAYSTUFF 5
extern CV_PossibleValue_t inputdisplay_cons_t[NUMINPUTDISPLAYSTUFF];
#define NUMMINIMAPDOTSTUFF 5
extern CV_PossibleValue_t minimapdot_cons_t[NUMMINIMAPDOTSTUFF];
const char *K_GetItemPatch(UINT8 item, boolean tiny);
INT32 K_calcSplitFlags(INT32 snapflags);
void K_LoadKartHUDGraphics(void);
void K_drawKartHUD(void);
void K_drawKartFreePlay(UINT32 flashtime);
void K_drawKartTimestamp(tic_t drawtime, INT32 TX, INT32 TY, INT16 emblemmap, UINT8 mode);
typedef struct
{
INT32 x;
INT32 y;
INT32 flags;
} drawinfo_t;
patch_t *K_getItemBoxPatch(boolean small, boolean dark);
patch_t *K_getItemMulPatch(boolean small);
void K_getItemBoxDrawinfo(drawinfo_t *out);
INT32 K_getMinimapTrans(void);
void K_getLapsDrawinfo(drawinfo_t *out);
void K_getMinimapDrawinfo(drawinfo_t *out);
#ifdef __cplusplus
} // extern "C"
#endif
// =========================================================================
#endif // __K_HUD__
+4 -4772
View File
File diff suppressed because it is too large. Load diff
+2 -45
View File
@@ -23,9 +23,6 @@ extern const UINT8 KartColor_Opposite[MAXSKINCOLORS*2];
void K_RainbowColormap(UINT8 *dest_colormap, UINT8 skincolor);
void K_GenerateKartColormap(UINT8 *dest_colormap, INT32 skinnum, UINT8 color, boolean local);
UINT8 K_GetKartColorByName(const char *name);
UINT8 K_GetHudColor(void);
boolean K_UseColorHud(void);
boolean K_UseHighResPortraits(void);
void K_RegisterServerKartStuff(void);
void K_RegisterClientKartStuff(void);
@@ -34,30 +31,11 @@ extern consvar_t cv_coloredspeedlines, cv_coloredsneakertrail;
extern consvar_t cv_bananajitter;
extern consvar_t cv_bananthrowroll;
extern consvar_t cv_airsparks;
extern consvar_t cv_colorizedhud, cv_colorizeditembox, cv_colorizedhudcolor;
extern consvar_t cv_darkitembox;
extern consvar_t cv_biglaps;
extern consvar_t cv_highresportrait;
extern consvar_t cv_stat_xoffset, cv_stat_yoffset;
extern consvar_t cv_showstats;
extern consvar_t cv_fancyroulette;
extern consvar_t cv_showlaptimes;
extern consvar_t cv_battlespeedo;
extern consvar_t cv_multiitemicon;
extern consvar_t cv_huditemamount;
#define NUMSPEEDOSTUFF 8
extern CV_PossibleValue_t speedo_cons_t[NUMSPEEDOSTUFF];
#define NUMDGAUGESTUFF 6
extern CV_PossibleValue_t driftgaugestyle_cons_t[NUMDGAUGESTUFF];
#define NUMINPUTDISPLAYSTUFF 5
extern CV_PossibleValue_t inputdisplay_cons_t[NUMINPUTDISPLAYSTUFF];
#define NUMMINIMAPDOTSTUFF 5
extern CV_PossibleValue_t minimapdot_cons_t[NUMMINIMAPDOTSTUFF];
boolean K_IsPlayerLosing(player_t *player);
boolean K_IsPlayerWanted(player_t *player);
INT32 K_KartGetItemOdds(UINT8 pos, SINT8 item, fixed_t mashed, boolean spbrush);
INT32 K_FindUseodds(player_t *player, fixed_t mashed, INT32 pingame, INT32 bestbumper, boolean spbrush, boolean dontforcespb);
void K_KartBouncing(mobj_t *mobj1, mobj_t *mobj2, boolean bounce, boolean solid);
void K_FlipFromObject(mobj_t *mo, mobj_t *master);
void K_MatchGenericExtraFlags(mobj_t *mo, mobj_t *master);
@@ -118,27 +96,6 @@ void K_PlayOvertakeSound(mobj_t *source);
void K_PlayHitEmSound(mobj_t *source, mobj_t *victim);
void K_PlayPowerGloatSound(mobj_t *source);
const char *K_GetItemPatch(UINT8 item, boolean tiny);
INT32 K_calcSplitFlags(INT32 snapflags);
void K_LoadKartHUDGraphics(void);
void K_drawKartHUD(void);
void K_drawKartFreePlay(UINT32 flashtime);
void K_drawKartTimestamp(tic_t drawtime, INT32 TX, INT32 TY, INT16 emblemmap, UINT8 mode);
typedef struct
{
INT32 x;
INT32 y;
INT32 flags;
} drawinfo_t;
patch_t *K_getItemBoxPatch(boolean small, boolean dark);
patch_t *K_getItemMulPatch(boolean small);
void K_getItemBoxDrawinfo(drawinfo_t *out);
INT32 K_getMinimapTrans(void);
void K_getLapsDrawinfo(drawinfo_t *out);
void K_getMinimapDrawinfo(drawinfo_t *out);
#ifdef __cplusplus
} // extern "C"
#endif
+1
View File
@@ -25,6 +25,7 @@
#include "hu_stuff.h" // HU_AddChatText
#include "console.h"
#include "k_kart.h" // SRB2Kart
#include "k_hud.h" // SRB2Kart
#include "d_netcmd.h" // IsPlayerAdmin
#include "d_main.h"
+1
View File
@@ -24,6 +24,7 @@
#include "w_wad.h"
#include "z_zone.h"
#include "k_kart.h"
#include "k_hud.h" // SRB2kart
#include "lua_script.h"
#include "lua_libs.h"
+1
View File
@@ -70,6 +70,7 @@
#include "st_stuff.h"
#include "i_sound.h"
#include "k_kart.h" // SRB2kart
#include "k_hud.h" // SRB2kart
#include "k_stats.h" // SRB2kart
#include "d_player.h" // KITEM_ constants
+1
View File
@@ -34,6 +34,7 @@
#include "i_time.h"
#include "k_kart.h" // SRB2kart
#include "k_hud.h"
//random index
#include "m_random.h"
+1
View File
@@ -65,6 +65,7 @@
#include "st_stuff.h"
#include "m_misc.h" // M_MapNumber
#include "p_setup.h" // P_PartialAddFile mayb
#include "k_hud.h"
#ifdef HWRENDER
#include "r_data.h"
+1
View File
@@ -40,6 +40,7 @@
#include "m_random.h" // M_RandomKey
#include "g_input.h" // PLAYER1INPUTDOWN
#include "k_kart.h" // colortranslations
#include "k_hud.h"
#include "console.h" // cons_menuhighlight
#include "lua_hook.h" // IntermissionThinker hook
#include "lua_hud.h" // intermission hud hook