




SDL_GL_GetDrawableSize(m_pWindow, pCurrentWidth, pCurrentHeight);
fixes it
@TsFreddie did you not experience this when testing?
It's really weird that SDL2 is so inconsistent then








UnloadTextureNew





























































































mutable xd






src/game/client/components/chat.cpp
669: *(const_cast<char *>(pStr)) = 0;
674: *(const_cast<char *>(pEnd)) = 0;
677: char *p = const_cast<char *>(pLine);
src/game/server/gamecontext.cpp
1736: *(const_cast<char *>(p)) = 0;
1741: *(const_cast<char *>(pEnd)) = 0;
src/engine/shared/console.cpp
1088: str_copy(const_cast<char *>(pCommand->m_pName), pName, TEMPCMD_NAME_LENGTH);
1089: str_copy(const_cast<char *>(pCommand->m_pHelp), pHelp, TEMPCMD_HELP_LENGTH);
1090: str_copy(const_cast<char *>(pCommand->m_pParams), pParams, TEMPCMD_PARAMS_LENGTH);





c++
class CCommandInfo
{
protected:
int m_AccessLevel;
public:
CCommandInfo() { m_AccessLevel = ACCESS_LEVEL_ADMIN; }
virtual ~CCommandInfo() {}
const char *m_pName;
const char *m_pHelp;
const char *m_pParams;
virtual const CCommandInfo *NextCommandInfo(int AccessLevel, int FlagMask) const = 0;
int GetAccessLevel() const { return m_AccessLevel; }
};












p






























1































gsl::not_null doesn’t really seem viable, it’s a tad ugly imo










1










size_t fits? e.g. bool fits(char *b, char *e, size_t n)



e-b <= n? (edited)

size_t

(size_t)(e-b) >= n (edited)





(size_t)(e-b) >= n (edited)


b + n < e which leads to all sorts of interesting questions about pointer arithmetic and whether it's UB to even calculate an invalid pointer


(size_t)(end-start) >= size
e-b don't fit in a ptrdiff_t how would you take care of that one? 










































if (__glibc_unlikely (isless (x, M_LIT (0.0)))) __set_errno (EDOM);




square(int):
push rax
call __errno_location
mov DWORD PTR [rax], 33
#define __set_errno(e) (errno = (e)) mh
push rax do there?(*__errno_location())

extern int *__errno_location (void) __THROW __attribute_const__;
# define errno (*__errno_location ())




square(int):
push rax
call __errno_location
mov DWORD PTR [rax], 33 
errno = EDOM
OnConnect is not safe enough to request what mod type the server is?


OnConnect is not safe enough to request what mod type the server is? 






c++
if(m_GameInfo.m_EntitiesDDRace)
{
TuningList()[i].Set("gun_curvature", 0);
TuningList()[i].Set("gun_speed", 1400);
TuningList()[i].Set("shotgun_curvature", 0);
TuningList()[i].Set("shotgun_speed", 500);
TuningList()[i].Set("shotgun_speeddiff", 0);
}
simple patch like this


m_GameInfo.m_EntitiesDDRace doesn't imply anything other than show ddrace entities











CGameContext::SendTuningParams



m_Tuning variable oO






m_Tuning variable oO 



m_UseTuneZonesm_Tuning

m_Tuning is the default. so where do we get the discrepancy?
m_GameWorld.m_WorldConfig.m_UseTuneZones = m_GameInfo.m_PredictDDRaceTiles;

CGameClient::ConTuneZone in gameclient.cpp





!m_UseTuneZones tune zone 0 is set to the tunes received from the server




m_UseTuneZones






m_WorldConfig object came from the network, nvm

return






OnConnected happens immediately on CON_READY, which I think is before the first tunes are sent





















if(m_ReceivedSnapshots[g_Config.m_ClDummy] >= 3)
prevprevpos






bluesky branch










SnappingClient

















bluesky branch. Maps sent as a group of resources which are asynchronously loaded as they are sent. The loading screen is like instant on there
































































A



































































m_GameWorld.TuningList()[0] = m_Tuning[g_Config.m_ClDummy];


m_pLocalCharacter

















m_GameWorld.TuningList()[0] = m_Tuning[g_Config.m_ClDummy]; is just called even without char(top of the function)?















c++
if(!m_GameWorld.m_WorldConfig.m_UseTuneZones)
m_GameWorld.TuningList()[0] = m_Tuning[g_Config.m_ClDummy];
But this should have the same effect then



c++
if(!m_GameWorld.m_WorldConfig.m_UseTuneZones)
m_GameWorld.TuningList()[0] = m_Tuning[g_Config.m_ClDummy];
But this should have the same effect then 
