This patch will create crashes where the code expects FREE to set the pointer to NULL! (Those problems should be fixed anyway.)
The only occassion where I saw this is when quiting a game, so it is not too much of an issue.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1459 4a71c877-e1ca-e34f-864e-861f7616d084
Original patch by Watermelon (slightly modified).
Based on an idea by TheNoid and Kreuvf.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1457 4a71c877-e1ca-e34f-864e-861f7616d084
* `make -C po update-po`
* provide some translations for the Dutch translation
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1449 4a71c877-e1ca-e34f-864e-861f7616d084
- segfault occurred in map_Height(UDWORD x, UDWORD y) (map.c) when called by addLandingLights (mission.c), we now check whether our coordinates are negative (and as such invalid) before sending them to map_Height
* while at it clean up addLandingLights by splitting large pieces of code repetition into another (inline) function
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1447 4a71c877-e1ca-e34f-864e-861f7616d084
Not doing this leads to a "statement with no effect" warning in case NLS is disabled.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1445 4a71c877-e1ca-e34f-864e-861f7616d084
* AUDIO_SAMPLE
* remove unused variable iLoops from the struct
* rename bRemove to the more descriptive title of bFinishedPlaying
* change sound_SetupChannel to return a BOOL rather than be return void and throw its output value in a pointer
* make audio_Update() return void (instead of BOOL) since its output value was TRUE always anyway, plus all its callees ignored the output value
* increase readability of lots of functions in audio.c
* remove unused (and nothing doing) functions: audio_StopTrack, audio_SetTrackPan, audio_SetTrackVol and audio_SetTrackFreq
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1444 4a71c877-e1ca-e34f-864e-861f7616d084
* remove ptrlist.c from lib/gamelib/Makefile.raw
* some modifications of char* -> const char*
* modify typedef of audio callback function to take a parameter of `void *psObj` rather than `AUDIO_SAMPLE *psSample` to minimize exposure (psSample->psObj was the only thing used by all callback functions anyway)
* modify all callback functions to match the new typedef's signature
* modify all functions calling callbacks to match the new signature (I think I've got them all, but since passing a pointer to a void* parameter doesn't generate any compiler errors/warnings I might have missed one, which would lead to undefined behaviour)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1442 4a71c877-e1ca-e34f-864e-861f7616d084
The texture file in PIE files can now be up to MAX_PATH chars long.
- Find the reason for WZ discarding everything after the number in "page-123" styled texture references.
This led to the problem with Grim's mod referencing the skybox texture instead of his own wall texture.
- Beautify some code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1438 4a71c877-e1ca-e34f-864e-861f7616d084
- Remove "-%token <sval> TEXT" from audp_parser.y since it clashed with declarations in MinGW's Windows headers. It does still compile and run, but this may have harmed something anyway. Please check!
- Hack around DATADIR being defined by objbase.h in MinGW by undefining it before the inclusion of shlobj.h (incl. in main.c) This only works since the case that DATADIR is actually used on Windows is extremely rare.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1437 4a71c877-e1ca-e34f-864e-861f7616d084
* revert changes to po/Makefile.in.in from r1417
* add some makevars to raw makefile system
* add definitions of gettext macros P_ and NP_ to raw makefiles (and remove Q_ and Qn_)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1436 4a71c877-e1ca-e34f-864e-861f7616d084
enclosed by comments and have been since r1 (Initial Version)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1434 4a71c877-e1ca-e34f-864e-861f7616d084
in ram by storing a encrypted value and checking against
this.
It not of use anymore as the client is completely
open-sourced now...
Removing the module and all references
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1425 4a71c877-e1ca-e34f-864e-861f7616d084
* since gettext_noop is always defined, remove the conditional definition of N_ which checks whether it is or is not defined
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1420 4a71c877-e1ca-e34f-864e-861f7616d084
_GNU_SOURCE can take effect first, to silence stpcpy() warnings from
bison generated code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1416 4a71c877-e1ca-e34f-864e-861f7616d084
* `make -C po update-po`
PS The most feasible solution other than the above mentioned hack seems to me to use different gettext domains, I'm not sure how that should be implemented though
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1415 4a71c877-e1ca-e34f-864e-861f7616d084
* use it in src/droid.c
* throw some hardcoded strings (in a switch statement) in an array of strings instead (using N_ there as well)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1414 4a71c877-e1ca-e34f-864e-861f7616d084
* use proper constness:
* make some functions take arguments of `const char*` rather than just `char*` (also modified some functions' return values to return `const char*` where appropiate)
* modify rank retrieval functions to use a central array instead; currently ranklimits (i.e. the amount of kills required to promote) is hardcoded in switch statements, as is the case with the names of those ranks
* `make -C po update-po`
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1409 4a71c877-e1ca-e34f-864e-861f7616d084
* Fix a spelling error in a string in src/droid.c
* `make -C po update-po`
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1406 4a71c877-e1ca-e34f-864e-861f7616d084