Presumably a simple anti-cheat precaution to stop people running "strings"
on the binaries in the days before the source was available. The
de-obfuscated strings are sent over the wire in the net protocol anyway.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
The menu files hadn't been updated for the now expanded keysets.
Reported-by: Sander van Dijk <a.h.vandijk@gmail.com>
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Re-order things, and generally force this squarish peg into the round
hole. Will want to factor out some of the fundamental differences into
different files later to reduce the #ifdef tangles, but at least some
benefit to be gained by having the common code shared.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Re-arrange order of functions, where functions are similar add a few
ifdefs to share common code and then add the client/server independent
bits to each file.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
When using SDL video/input, the game hangs when we select "New Game" from
the menu and the "Are you sure you want to start a new game?" prompt is
displayed, because we stop processing input events.
This is a bit of a hackish workaround, but will try to untangle this a bit
more later.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Simplifies access to the player colors later. Update the sbar usage of
colors to be consistent between NQ/QW as well.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Used only during development of the game when working over slow
connections remotely - doesn't seem relevant to doing development
today.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
...which is a lot! This ended up touching a lot of code, especially
when it spread to Cmd_Argv, etc. Mostly just propogating the correct
const qualifiers on pointers, but in some cases it was appropriate to
copy the buffer to e.g. lowercase filename in SV_BeginDownload_f or
re-write parts of functions where the buffer modifications was not
strictly needed (e.g. the *Say* functions).
I guess of note is that I now accept a const pointer into Z_Free,
which shouldn't be a problem since it doesn't modify the data pointed
to at all, just marks it as free.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Make as many arguments to functions in common.h as possible const so
the compiler knows we shouldn't be modifying some buffers/strings
passed down here.
Also fixed (but not tested) the COM_BlockSequenceCheckByte function in
QW/common/common.c which has been #if 0'd for a while. Probably won't
keep it around, but fixed for completeness.
I skipped COM_Parse in this patch, will be constified in the following
patch.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Wrap the vector macros that don't return a value in do {} while (0)
and fix a couple of missing semicolons detected in the process.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Pass over the source and make as many references to entities as possible
const. This makes it much more obvious where we are actually making
modifications to the entity_t structure.
Mostly trivial, the only place where I did something other than add the
keyword "const" was in R_DrawBrushModel where we were working around the
reversed pitch bug.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
QW was saving the whole visedicts list to scan for origins of objects
during the previous frame so that particle trails can be placed correctly
behind rockets, grenades, etc.
Save the origins and keynums in a simpler struct and remove the double
buffering of the cl_visedicts array.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
oldscr_viewsize was a duplicated check for changes in the scr_viewsize
cvar. Remove it and make the check consistent across all screen.c files.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Have the helper struct do the renderer specific alias model skin
processing. Will probably want to relocate the code to a more appropraite
place later, but just get the factoring done for now.
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>
Create a model loader structure which can be used to pass callbacks down
from the renderer code. This will allow us to have the render do some
processing on the loaded data at appropriate points and let us make the
actual loading code generic.
In the first instance, pass down the aliashdr_t padding value required by
the renderer.
Note that to remove a circular dependency introduced in the headers, I had
to stop including render.h in model.h/gl_model.h and that change
propogated some more changes to includes across the tree...
Signed-off-by: Kevin Shanahan <kmshanah@disenchant.net>