Merge branch 'master' into newrenderer

This commit is contained in:
Christoph Oelckers 2021-04-25 11:33:47 +02:00
commit 8c379f7a44
6 changed files with 11 additions and 25 deletions

View file

@ -1072,6 +1072,7 @@ void getzrange(const vec3_t *pos, int16_t sectnum,
for (bssize_t i=0; i<clipsectnum; i++)
{
int j;
if (clipsectorlist[i] == MAXSECTORS) continue; // we got a deleted sprite in here somewhere. Skip this entry.
SectIterator it(clipsectorlist[i]);
while ((j = it.NextIndex()) >= 0)
{

View file

@ -460,6 +460,11 @@ int FKeyBindings::GetKeysForCommand (const char *cmd, int *first, int *second)
*first = *second = c = i = 0;
if (cmd[0] == '\0')
{
return 0;
}
while (i < NUM_KEYS && c < 2)
{
if (stricmp (cmd, Binds[i]) == 0)

View file

@ -1534,7 +1534,6 @@ bool FileSystem::CreatePathlessCopy(const char *name, int id, int /*flags*/)
auto oldlump = FileInfo[lump];
int slash = oldlump.longName.LastIndexOf('/');
// Note: already pathless entries must be duplica
if (slash == -1)
{

View file

@ -270,6 +270,8 @@ uint8_t *VkHardwareTexture::MapBuffer()
unsigned int VkHardwareTexture::CreateTexture(unsigned char * buffer, int w, int h, int texunit, bool mipmap, const char *name)
{
// CreateTexture is used by the software renderer to create a screen output but without any screen data.
if (buffer)
CreateTexture(w, h, mTexelsize, mTexelsize == 4 ? VK_FORMAT_B8G8R8A8_UNORM : VK_FORMAT_R8_UNORM, buffer, mipmap);
return 0;
}

View file

@ -28,27 +28,6 @@ extern int g_nextskill;
extern FMemArena dump; // this is for memory blocks than cannot be deallocated without some huge effort. Put them in here so that they do not register on shutdown.
int CONFIG_Init();
// I am not sure if anything below will survive for long...
#define MAXMOUSEAXES 2
#define MAXMOUSEDIGITAL (MAXMOUSEAXES*2)
// default mouse scale
#define DEFAULTMOUSEANALOGUESCALE 65536
// default joystick settings
#define DEFAULTJOYSTICKANALOGUESCALE 65536
#define DEFAULTJOYSTICKANALOGUEDEAD 1000
#define DEFAULTJOYSTICKANALOGUESATURATE 9500
void CONFIG_SetupJoystick(void);
void CONFIG_SetGameControllerDefaultsClear();
extern FStringCVar* const CombatMacros[];
void CONFIG_ReadCombatMacros();

View file

@ -386,9 +386,9 @@ public:
if (currentLevel->flags & MI_USERMAP)
gfx_offset = BONUSPIC01;
else if (!isRRRA())
gfx_offset = BONUSPIC01 + clamp((currentLevel->levelNumber / 100) * 7 + (currentLevel->levelNumber % 100), 0, 13);
gfx_offset = BONUSPIC01 + clamp((currentLevel->levelNumber / 1000) * 7 + (currentLevel->levelNumber % 1000), 0, 13);
else
gfx_offset = LEVELMAP01 + clamp((currentLevel->levelNumber / 100) * 7 + (currentLevel->levelNumber % 100), 0, 13);
gfx_offset = LEVELMAP01 + clamp((currentLevel->levelNumber / 1000) * 7 + (currentLevel->levelNumber % 1000), 0, 13);
lastmapname = currentLevel->DisplayName();