Commit graph

2654 commits

Author SHA1 Message Date
ZsoltM
31fea24321 added mingw64 (msys2) platform support 2015-01-30 22:52:53 +01:00
Zack Middleton
4e029b1f6b Fix compiling lcc using mingw under cygwin
Also have 'make' under cygwin automatically use mingw.
2015-01-27 04:51:03 -06:00
Ensiform
43c7f1e734 Inform how many shader stages the max is in the warning message 2015-01-26 02:39:59 -06:00
Xycaleth
2742dfad26 Add arrow key support for win32 console 2015-01-26 02:39:59 -06:00
Ensiform
b9e97b3857 Move Event processor call down below the mouse checks.
Only send mouse events if both values are non-zero.

Hopefully this helps with the event overflow spam that can sometimes
happen on loads or laggy situations.
2015-01-26 02:39:58 -06:00
vloup
d7f00e2b65 Fix Team Arena tauntGauntlet command 2015-01-26 02:39:58 -06:00
Pan7
9c52d6c2bf SIGABRT is in ANSI and POSIX.1, and SIGIOT isn't. 2015-01-18 18:41:06 +01:00
Pan7
16c67b96c2 No unix memmove for msvc 2015-01-17 18:15:03 +01:00
Zack Middleton
10e2caad46 Fix crash in MSVC x64 qsnapvectorsse, bug #5905
Make MASM x64 qsnapvectorsse the same as the inline version.
Remove leftover OP code, see commit 8a500d71da.
2015-01-14 15:29:45 -06:00
Zack Middleton
af8acbd7a9 Make barrel/flash model name buffer safe 2015-01-12 22:35:20 -06:00
Zack Middleton
af617bc0e6 Fix possible levelPicNames buffer overflow in q3_ui 2015-01-12 21:28:03 -06:00
Zack Middleton
daa604ae9b Fix parsing bots in arena info with trailing spaces
q3_ui would shown bot at index of number of bots in list.
game would send empty name to addbot command and command would think skill
(i.e., 2.000000) was the bot name.
2015-01-12 21:28:03 -06:00
Zack Middleton
9c4b75c499 Remove logically dead code from UI_GetServerStatusInfo 2015-01-12 21:28:03 -06:00
Zack Middleton
78e7656900 Make Window_Paint check if w is NULL before dereference 2015-01-12 21:28:03 -06:00
Zack Middleton
84e792f453 Fix (unused) "orders" menu script logic
"orders" menu script is not used by Team Arena.

The same C format string was given an int or string argument depending on if
ordering a single person or everyone. Make it always use int.
2015-01-12 21:28:03 -06:00
Zack Middleton
f74479afe8 Fix handling too many characters or aliases in Team Arena UI 2015-01-12 21:28:02 -06:00
Zack Middleton
07eb0f6dc9 Fix possible string buffer overflows in Team Arena UI 2015-01-12 21:28:02 -06:00
Zack Middleton
5020361be4 Fix off-by-one range checks in Team Arena UI 2015-01-12 18:31:39 -06:00
Zack Middleton
d62dfd87f9 Set float rounding mode on non-Windows platforms
Sys_SetFloatEnv in sys_unix.c existed but was not called. It sets the
rounding mode to "to nearest" which is the default on Linux. Might be
required on other platforms, I don't know.
2015-01-12 17:03:13 -06:00
Zack Middleton
1ff28f2389 Merge pull request #22 from zturtleman/cvar_modified
Add cvar_modified command
2015-01-07 19:48:16 -06:00
Zack Middleton
e7c7ca1309 Merge pull request #100 from Pan7/q3lcc
q3lcc option -lcppdir and -lrccdir.

Enabled using `q3lcc -Wo-lrccdir=/path/to/dir -Wo-cppdir=/path/to/dir`.
2015-01-07 19:45:12 -06:00
Zack Middleton
bd2af6e4ea Use MSVC mode marcos for creat in q3cpp on Windows
Using unix mode 0666 for creat was causing crashes when compiled with MSVC.
So use the marcos recommended by MSDN. MinGW also has the marcos, so apply
to Windows builds in general.
2015-01-07 19:27:59 -06:00
Zack Middleton
aa1aad928e Merge pull request #98 from Pan7/lcc
Windows header files for q3lcc
2015-01-07 19:31:51 -06:00
Zack Middleton
010821384c Merge pull request #97 from Pan7/outp
Renaming outp to outbufp because outp() is an existing function
2015-01-07 19:27:53 -06:00
Zack Middleton
044060274e Merge pull request #104 from smcv/mbstowcs
Ensure that mbstowcs does not overflow its buffer
2015-01-07 18:10:17 -06:00
Simon McVittie
df7dab721f Don't crash if more than 128 modes are available 2015-01-07 23:39:12 +00:00
Simon McVittie
ff7ff32b0e Ensure that mbstowcs does not overflow its buffer
Similar to one of the changes by Tim Angus in fd986da: mbstowcs' third
argument is the number of wchar_t available in dest, not the number
of bytes.

This does not appear to be exploitable, because ioquake3 does
not actually call mumble_set_identity() or mumble_set_description()
anywhere, but it might be relevant to derivatives.

Spotted via compiler warnings.
2015-01-07 23:37:11 +00:00
Jun Woong
8469c40c2b Stop LCC from warning about null pointer conversion to function pointer
Fixed LCC to correctly diagnose expressions with NPC. It no longer reports messages such as

    warning: conversion from `pointer to void' to `pointer to void function(void)' is compiler dependent
2015-01-06 23:43:04 -06:00
Pan7
c4f851668b q3lcc option -lcppdir and -lrccdir 2015-01-07 03:43:18 +01:00
Tim Angus
dd82b9d1a8 Fix case where interval overflows (thanks jackeri)
[17:58] <Jacker> hey, you might be interested in checking out this
4da5a397b5 (diff-acaedc9d8b492f9af8966ae68597392cR615)
[17:58] <Jacker> its related to the ddos protection code you wrote
[17:59] <Jacker> in continuation to:
ab9b08e584
[17:59] <Jacker> in a case if the client has in the past connected to
the server days/weeks earlier and time wraps the client wont be able to
connect
[18:00] <Jacker> since in that case if the bucket of that clients ip
still exists it wont get checked correctly
2014-12-29 19:08:42 +00:00
Zack Middleton
458ab7716c Make travis do all the builds again
Travis was only using the last env section, not merged them and was only doing
one build using gcc instead of six builds (gcc, clang, mingw, ..).
2014-12-28 15:38:22 -06:00
Zack Middleton
7de09c3490 Include stdint.h instead of inttypes.h in libmumblelink.c
MSVC 2010 has stdint.h but not inttypes.h.
Debian (GCC, MinGW) and OS X (Clang) can compile using stdint.h.
2014-12-28 15:08:02 -06:00
Zack Middleton
3cc16d6b92 Merge pull request #94 from wombat23/asmfix
Fix compile error with ml64 assembler
2014-12-28 15:06:29 -06:00
Tim Angus
a2bbb74cae Unfix warning 2014-12-28 15:47:40 +00:00
Tim Angus
4756826521 Fix warning 2014-12-28 12:44:59 +00:00
Zack Middleton
70e3d61006 Fix cg.intermissionStarted only being enabled at first intermission
Game sets CS_INTERMISSION to 1 at intermission, but does not clear it at
map_restart so it's only sent the first time. CG_MapRestart manually clears
cg.intermissionStarted (which is set to value of CS_INTERMISSION when it's
modified). So subsequent intermissions do not have cg.intermissionStarted
enabled.

Now CS_INTERMISSION is cleared and sent each time intermission is started
and cg.intermissionStarted is enabled each time.

This makes subsequent intermissions not play sounds in CG_CheckLocalSounds
during the 1 second between intermission starting and switching to scoreboard
(PM_INTERMISSION) and makes Team Arena voice chats not play.
2014-12-27 18:32:49 -06:00
Pan7
a82fb6d1b1 Windows header files for q3lcc 2014-12-26 23:33:52 +01:00
Pan7
6de3f51c23 Renaming outp to outbufp because outp() is an existing function 2014-12-26 12:52:10 +01:00
Zack Middleton
4463af85fb When player stops following a player, keep view angles
Now player keeps looking the same direction instead of facing somewhere else
which is slightly disorienting.
2014-12-19 22:09:26 -06:00
Zack Middleton
5cf45c5937 Don't use dead view angles after stop following a dead player
If ps.stats[STAT_HEALTH] is less or equal to 0, cgame uses fixed view angles.
When stop following a player, make sure health isn't less or equal to 0.
2014-12-19 22:08:06 -06:00
Zack Middleton
a700b76722 Fix reading 4 byte UTF-8 text input 2014-12-19 21:56:54 -06:00
Zack Middleton
65121c62c9 Add weapon barrel to gauntlet/mg/bfg items in baseq3 too 2014-12-10 19:29:36 -06:00
Zack Middleton
b0561e5fb4 Fix weapon barrel angle on Gauntlet and BFG items in Team Arena
The barrels were rotated 90 degrees from what they should be.
Used barrel code from CG_AddPlayerWeapon to fix them.
2014-12-10 19:23:35 -06:00
Michael Rieder
55c15e4466 Fix compile error with ml64 assembler 2014-12-07 03:40:52 +01:00
Zack Middleton
424122c366 Fix bot's teamleader name field being too short
Players using names with 32 to 35 characters could not be recognized as
the team leader.

Reported by Razor.
2014-12-04 16:50:28 -06:00
Zack Middleton
b21a59af8c Fix negative glyph index in Team Arena text functions
Team Arena's text functions cast signed char values to int and use as an array index.
This works fine for values 0 to 127, but not for -128 to -1 which are a negative array index.
Instead use "character & 255" like client and original Q3 ui/cgame string drawing code.
2014-12-01 22:14:58 -06:00
Zack Middleton
08ddb99732 Fix saving/loading glyph 255 in RegisterFont
The glyph for character 255 (lower case y with two dots above it) was
rendered, but it's glyph information was not stored in fontInfo_t and
not saved into .dat file (including the ones in Team Arena).

Attempting to load it from existing .dat font files is fine because
shader name is "" and gets 0 handle. The handle was already 0 anyway.
2014-12-01 22:04:40 -06:00
SmileTheory
8c7fedb1fe OpenGL2: Fix face culling. 2014-11-30 21:50:33 -08:00
SmileTheory
fd23249357 OpenGL2: Ensure tess VAO is bound before using it. 2014-11-21 16:12:53 -08:00
Zack Middleton
c787cf3aef Fix stencil shadows not drawing if has 500 or more vertexes
Stencil shadow is not drawn if a mesh, or multiple meshes with the same
entity and shader, have more than 500 vertexes. The issue is caused by storing
the projected positions in the tess vertex buffer. Use a new array instead.
2014-11-16 21:21:30 -06:00