Commit Graph

1946 Commits (0fc9820f4a030a99d41861d089158427631f8e87)

Author SHA1 Message Date
Dennis Schridde ffcf206972 MSVC supports noreturn as well
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6780 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:52:22 +00:00
Dennis Schridde 58897d42be Report OpenGL 3.0 support during initialisation as well
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6779 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:40:27 +00:00
Dennis Schridde 6c1bafbf77 Use macro to check for MSVC .NET
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6778 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:40:19 +00:00
Dennis Schridde c0acc342bb Add more documentation to WZ_DECL_*, use __ attribute names as recommended by GNU for headers, reorder defintions logically
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6777 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:40:08 +00:00
Dennis Schridde 4c3053b3e1 "restrict" is a C99 feature, thus use the appropriate checks
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6776 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:39:59 +00:00
Dennis Schridde 8aacce716c Provide noreturn declaration macro (useful for exit-on-failure functions)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6775 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-06 14:39:19 +00:00
Per Inge Mathisen 28c7cb4abb Add new backdrop by B. V. Edwards <cathuria>
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6768 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-02 22:57:26 +00:00
Freddie Witherden 34323e368a Fix compilation of SQLite under OS X. Stats are still broken.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6758 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-01 13:06:59 +00:00
Dennis Schridde d8680df439 Bump internal copy of SQLite to 3.6.11
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6756 4a71c877-e1ca-e34f-864e-861f7616d084
2009-03-01 10:05:59 +00:00
Buginator fc8bbc5bd9 Feature fixes & enhancements.
*Adds LOG_FEATURE (--debug feature) so we can keep track of features.

*Disallow VTOLs from being able to poach features.

*Changes feature spawning from instant to a variable time period.

*When feature can't be placed, break out of routine instead of sending invalid data.

*Actually remove features, and notify others that the feature was removed. (AKA, actually sync between machines.)

ASSERT() when numNaybors is invalid.
Fix a spamming debug line mistakenly changed in r6677


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6737 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-28 03:36:26 +00:00
Buginator df0ada9a50 Fixes crash when certain scripts fail to compile, it don't allocate storage, so we shouldn't (try to) reference / free() it.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6736 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-28 02:17:20 +00:00
Buginator f0d0bd7ebe Fixes a dangling pointer issue with a global.
In certain circumstances, if you try to abort out of a MP game (maybe SP as well), it would crash after deleting the widget, since it was still referencing the pointer in the global.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6732 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-28 01:40:19 +00:00
Gerard Krol 10ce0cc72b Scale down textures used for 3D when they exceed the size specified with the textureSize option. Also add two assert statements to check for the correct handling of the parameters for glDrawRangeElements.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6720 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-23 18:56:41 +00:00
Buginator 9d868d4c0c Adds LOG_LIFE to track when units are created.
(We already had LOG_DEATH)

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6694 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-22 17:59:57 +00:00
Gerard Krol 5601741b95 Brace for impact, this is the new terrain renderer!
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6682 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-21 23:35:21 +00:00
Buginator e920507134 Change debug() output from gametime to real time.
In MP games, since gametime can vary so much between machines, needed a more reliable time source to sync up messages between them.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6679 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-21 22:24:02 +00:00
Buginator 9e0767ecfd * Fixes memory leak.
* Fixes eventFireCallbackTrigger which was called multiple times.

* LOG_NET is to *only* be used for network traffic, not for sync issues.

* Adds visual display about when player leaves/drops.

* Adds / cleans up debug messages concerning connection issues.

* Adds new message type NET_PLAYER_DROPPED, (as opposed to NET_PLAYER_LEAVING). One is when we lose a connection, the other is when a player quits 'normally'.


Will be adding icons from Ticket #247 done by Zarel soon.

NOTE: please use --debug net if you have connection issues!


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6677 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-21 22:09:58 +00:00
Freddie Witherden 1d9dd3ea82 Fix a minor indentation issue in clipboard.h
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6663 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-19 20:43:42 +00:00
Per Inge Mathisen 3e96bd6b1d Clean up mapLoad(), using physfs to read directly from file instead of casting structs to a memory buffer. Closes ticket:274.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6662 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-19 20:35:43 +00:00
Per Inge Mathisen f002d651e7 Fix bug #273 - server crashes if more than 6 players join a game. Reviewed by devurandom.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6659 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-19 20:01:10 +00:00
Buginator 60dbe83260 Updates .diff file on what we changed from the 'clean' 5.4 to the version that we use.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6653 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 22:17:05 +00:00
Buginator e2cfc4cc32 This fixes version 5.4 of GLee so that it compiles cleanly on gcc again.
We need to change the Glee.diff file as well.

Closes ticket #262

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6642 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 06:17:47 +00:00
Buginator 2b350ea649 Updates GLee to 5.4
**NOTE**: this will break gcc compiles.  The fix is in the next commit, so we can get a clean diff from the "clean" 5.4 to the modified version that we require.

Change log:

    * OpenGL 3.0 support, and 41 new extensions.
    * 5.4 : fixes for GL_NV_gpu_program4, GL_EXT_shader_program4.
    * 5.4 : Added 5 new extensions :
          o GL_EXT_texture_swizzle
          o GL_NV_explicit_multisample
          o GL_NV_transform_feedback2
          o WGL_NV_gpu_affinity
          o GLX_ARB_create_context
    * 5.4 : Various dead/dummy extensions have been removed, including :
          o GL_NV_geometry_program4 (merged with GL_NV_gpu_program4)
          o GL_NV_vertex_program4 (merged with GL_NV_gpu_program4)
          o GL_NV_fragment_program4 (merged with GL_NV_gpu_program4)
          o WGL_NV_video_out (renamed to WGL_NV_video_output)
    * 5.33 : fixes some GCC warnings
    * 5.33 : fixes some conflicts with glext.h on OS X
    * 5.33 : fixes an issue where 2 extensions could go missing on some platforms
    * 5.32 : fixes a potential access violation in __GLeeGetExtensions - thanks to Jacques Beaurain for spotting this bug.
    * 5.31 : fixes a GLX compile error
    * 5.30 : Better Linux/Mac OS support


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6641 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 06:14:38 +00:00
Buginator ac9a882f07 Fixes #257
Can compile OK with MSVC once again.

Frame.h must be included before default system header #includes, so we don't have linker redefinitions & conflicts with the non C99 compliant routines that MSVC uses.
Or in other words, we want our C99 compliant routines to override the default routines that MSVC uses.



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6640 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 06:09:24 +00:00
Guangcong Luo 1f5ab803ed Updated MinGW32 makefiles; fix "multiple half-tracks" bug.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6639 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 05:49:09 +00:00
Buginator af112296c6 Updated MSVC project & solution file(s).
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6638 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 05:46:13 +00:00
Buginator 55d3044f15 Updated MSVC project & solution file(s).
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6637 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-15 05:42:09 +00:00
Dennis Schridde 9dae6df94c Safen includes
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6623 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-11 12:12:00 +00:00
Dennis Schridde c4e55e49a3 Include frame.h in stdio_ext.c, so that we get debug.h and its declarations
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6620 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-11 11:04:08 +00:00
Dennis Schridde aac41748dc Bump copyright
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6617 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 18:01:48 +00:00
Dennis Schridde fcca92459c We no longer need to respect 8-char filename limits, be clear in naming instead
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6616 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:23 +00:00
Dennis Schridde 52b07e9cf0 Move piefixedpoint.h and pievector.h out of ivis, since they are quite generic
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6615 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:18 +00:00
Dennis Schridde 0c5d56b35a Move endian_* functions into a dedicated header and do not include it from frame.h
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6614 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:14 +00:00
Dennis Schridde cbbc58d1e9 Move files which extend a c std library header to a filename of similar name
Extension functions dealing with ...
 * strings are in string_ext.h
 * stdio (namely printf variants) are in stdio_ext.h
 * math are in math_ext.h

These headers are no longer included by frame.h

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6613 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:09 +00:00
Dennis Schridde 8050b17162 Cleanup
Incl: Move MAX_STR_LENGTH out of wzglobal.h, since it is only used in src

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6612 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:23:03 +00:00
Dennis Schridde 16c9241fa2 Rename Vector*_New() to Vector*_Init(), since that seems less confusing
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6611 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-10 17:22:59 +00:00
Giel van Schijndel 516067dec0 Alter frandom's API such that it takes no parameters and returns a float ranging from 0.f to 1.f
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6608 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 22:51:41 +00:00
Dennis Schridde b49952ce1e New function: frandom(x,y)
Returns a random floating point number between x and y

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6604 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 21:53:25 +00:00
Dennis Schridde 0b09ace43a More compact versions of fminf() / fmaxf()
Includes a comment on what might appear as magic or
incomplete implementation at first sight.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6603 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 04:07:44 +00:00
Dennis Schridde df6bd00d7e Provide fmaxf() / fminf() for non C99 compilers
Fixes #234.
This is not the patch attached there, since that one was broken.

From the manpage:
DESCRIPTION
       These functions return the larger value of x and y.
RETURN VALUE
       These functions return the maximum of x and y.
       If one argument is a NaN, the other argument is returned.
       If both arguments are NaN, a NaN is returned.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6601 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 03:53:08 +00:00
Dennis Schridde 80e64617b2 Use faster float code for hypotf, instead of falling back to doubles
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6600 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 03:53:05 +00:00
Dennis Schridde 728c68b81e Use format strings where required (script parser)
Should fix #178

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6597 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-09 02:53:52 +00:00
Per Inge Mathisen 4cae3b8f1b Improve handling of an error in NETsendfile reported in issue #215. Add TODO about
rewriting this whole function and reference to ticket.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6580 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-03 17:02:17 +00:00
Giel van Schijndel 94cf481e0f Override operator<< for std::ostream (left operand) and PHYSFS_Version (right operand) instead of using a plain function to perform the version formatting
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6578 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-01 12:13:00 +00:00
Giel van Schijndel db0e543f40 * Fix warnings about "possibly dangerous code" added in r6570:
- Don't ignore write(2)'s return value, instead handle it properly to deal with the cases where write(2) gets interrupted (by a signal) or returns prematurely because of non-blocking I/O
  - Properly handle popen(3) returning NULL
 * Don't assume the data written to stdout by "which" will just fit in our buffer

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6577 4a71c877-e1ca-e34f-864e-861f7616d084
2009-02-01 11:54:25 +00:00
Dennis Schridde ed2a2011f6 Improve preprocessor checks for type definitions
* Check for C99 instead of !MSVC where we deal with C99 stuff
 * C++98 defines bool as well
 * Move BOOL after the bool checks, so we could define it to bool more easily

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6572 4a71c877-e1ca-e34f-864e-861f7616d084
2009-01-31 15:51:47 +00:00
Dennis Schridde e88fb88376 Detect C++98 and do not mix feature detection code with platform hacks (!!)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6571 4a71c877-e1ca-e34f-864e-861f7616d084
2009-01-31 15:51:43 +00:00
Dennis Schridde d585762747 Add a few warnings about possibly dangerous code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6570 4a71c877-e1ca-e34f-864e-861f7616d084
2009-01-31 15:51:39 +00:00
Dennis Schridde 98842001af Use bool instead of BOOL where the latter is not required
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6569 4a71c877-e1ca-e34f-864e-861f7616d084
2009-01-31 15:51:35 +00:00
Dennis Schridde f9ef8289a4 Bump SQLite3 to 3.6.10
An change was introduced on sqlite3_vfs which causes an incompatible
 pointer error when mixed with older sqlite versions. Thus bump the
 required version to 3.6.10 as well.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@6564 4a71c877-e1ca-e34f-864e-861f7616d084
2009-01-30 18:28:21 +00:00