Commit Graph

2120 Commits (75d615d1344a5904d06fbd42cd5a957b0351256d)

Author SHA1 Message Date
Roman C 433d707927 Fixed missing player names in multiplayer messages,
cleaned up Bison logs
enabled logs for loading .slo and .vlo files

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@597 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-21 09:34:42 +00:00
Dennis Schridde b6c5dd9eaa Clean last commit to compile on Linux/GCC
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@596 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-20 20:37:26 +00:00
Roman C e4883dabb9 Scripting engine update:
-added new scripting function
-added new callbacks
-added new member variables
-players controlled by AI now receive (and send) multiplayer messages and can process them

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@595 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-20 14:48:14 +00:00
Ari Johnson 8917cea6cb Runtime script parse errors now report a filename and line number rather
than just an inaccurate line number.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@591 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-20 11:15:55 +00:00
Roman C f286ffd1bf Fixed dependencies
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@585 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-19 14:37:36 +00:00
Roman C 92284dc7bc Scripting engine update:
-implemented string support
-functions can now have arguments, example:
function STRING myFunc(DROID myDroid, int myInt2){<code>}
-functions can have return values:
return <statement>;
or just "return;" for void functions
-function calls are made the normal c/c++ way (using the function from the first example):
myString = myFunc(myDroid, 156);

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@583 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-19 13:26:11 +00:00
Dennis Schridde 9c1755d1b0 When cleaning the search path:
First saving curSearchPath->higherPriority to tmpSearchPath and then freeing curSearchPath helps against stupidity and bug #6552 (0xfeeefeee).

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@580 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-17 22:29:49 +00:00
Dennis Schridde fe22ab0f64 Show whether this is a debug compile in mainmenu.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@575 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-16 20:51:45 +00:00
Per Inge Mathisen e4c4f4be6f Revert allied visibility patch. It needs more testing.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@573 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-16 20:07:24 +00:00
Per Inge Mathisen 6fa9777262 Comment out some anti-cheat checks for now.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@571 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-15 21:03:22 +00:00
Per Inge Mathisen 6d8b190950 Make SBYTE explicitly a signed char, not just a char. This would have broken
some things on platforms where 'just char' means unsigned char. Fix lots of
new signedness warnings resulting from that fix (which would have cropped
up on unsigned char platforms anyway). Also implement a small subset of
stdint.h for windows platform in frame.h, hope this does not create any
conflicts. This allows us to use types like uint64_t where relevant.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@569 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-15 18:20:36 +00:00
Per Inge Mathisen 2149739999 Almost all strings and buffers are now of type char. This fixes
more than half the warnings on gcc4, and makes sure we do not
get signedness problems between platforms where char is defined
with different signedness. Also set line-ending properites for
some bison/flex files that did not have it set.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@563 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-12 16:52:37 +00:00
Per Inge Mathisen 438868b7dc Fix two minor bugs
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@562 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-12 16:49:11 +00:00
Per Inge Mathisen cc6537bd4f Fix minor bugs and remove some unused code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@561 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-12 16:27:58 +00:00
Per Inge Mathisen 65175a10ca Add support for MacOSX and big endian platforms. Patch by
iamtheari@gmail.com with changes by me.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@558 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-12 10:45:49 +00:00
Per Inge Mathisen 8adf85a21b Remove obsolete file lib/ivis_opengl/vid.h
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@556 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-11 22:08:48 +00:00
Per Inge Mathisen 0d5f830342 Remove obsolete file src/ivis02.h
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@555 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-11 21:59:37 +00:00
Per Inge Mathisen 8771927ea3 Cleanup of cheat system. Fixed problem where keymap saved in non-cheat mode would
override cheat mode. Made cheat words unavailable unless '-cheat' option and cheat 
key combination are used. As usualy with changes to keys, deleting your keymap file
may be required for this to work as advertised. Added and changed some cheat words.
See wiki for documentation. 


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@554 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-10 16:39:09 +00:00
Per Inge Mathisen a3df2ad6c8 Another force fix. Remove more references to DirectX.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@552 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-10 13:53:26 +00:00
Per Inge Mathisen 5b84a97015 Remove remains of a previous iteration of the graphics layer.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@551 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-08 20:58:32 +00:00
Per Inge Mathisen 081ec89b32 Remove legacy graphics code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@550 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-08 20:03:05 +00:00
Per Inge Mathisen 17bc3e60b6 Some cleanup of graphics code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@549 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-08 18:48:06 +00:00
Per Inge Mathisen 518478f7cd Clean up cheat mode activation. To enter cheat mode, start the game with the
"-cheat" commmand line option, and then, in the game, press left shift and backspace 
simultaneously. This does not work in multiplayer games unless you have compiled 
the game with debug enabled. You must delete your keymap file for this to work as
described.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@548 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-07 15:06:05 +00:00
Roman C 0afa375e12 -testing commit: made a softer mouse wheel zoom in/out
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@543 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-06 11:49:39 +00:00
Per Inge Mathisen 8327ec1092 Fix bug#6531, crash on saving/loading forces. Also add better logging, and
fix some similar but unrelated bugs where the PHYSFS_close() return value is
misinterpreted. Can still not select forces from the multiplayer dialog,
but I also have no idea how this is supposed to work.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@542 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-06 10:23:39 +00:00
Dennis Schridde 9703a85970 Warzone wont compile in non-debug mode since ASSERT() was enabled for it.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@540 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 20:56:50 +00:00
Per Inge Mathisen 5467654a9d Add allied visibility. This is mostly untested and might need adjustment.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@539 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 20:45:37 +00:00
Per Inge Mathisen 88fb8b7727 Forward port Qamly's additional radar modes from Berlios. This allows you
to switch terrain radar off, and allies radar on. You must delete your
old keymap file before you can use this feature.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@537 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 19:53:57 +00:00
Per Inge Mathisen 40da012608 Improve error reporting for VLO files.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@535 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 18:02:52 +00:00
Per Inge Mathisen 9cb27d8729 Remove option to limit textures to 2mb of memory, which was unused.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@529 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 13:31:28 +00:00
Per Inge Mathisen 90da3e40c8 Comment out an ASSERT which triggers when the 'Fast Play' tutorial is run.
I think this tutorial is calling the wrong message function here, so this
is probably just a workaround. In any case, it is called to display video
we no longer have.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@527 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-05 12:17:58 +00:00
Per Inge Mathisen 4cc429e687 Fix assertion warning and erronous variable assignment inside an ASSERT()
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@526 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-04 20:03:26 +00:00
Per Inge Mathisen 5fce2d6c26 Add and fix a number of ASSERT() calls.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@524 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-04 19:52:38 +00:00
Dennis Schridde ba1eeeb37c Not finding any features of the wanted kind is not error, so dont return false.
Fixes bug #6516 where the AI stops searching for oil sources if it can't find them the first time.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@523 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-04 19:46:12 +00:00
Per Inge Mathisen 8dc0fc2878 Remove some remaining support for saving and loading binary scripts,
used only on the PSX.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@520 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-04 17:19:35 +00:00
Dennis Schridde 49df018649 - Output Version and Revision to log
- Fix a pointer warning


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@512 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-31 18:27:01 +00:00
Dennis Schridde 26143d082c - More debug() calls
- Platform dependend LDFLAGS change for Makefile.raw


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@511 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-31 17:57:06 +00:00
Dennis Schridde bb4b7e82b6 - Update versioninfo in configure.ac and warzone.rc
- Cosmetic change in debug.c (Mark begin of the log with "---")
- Fix bug where PhysFS said WriteDir "Warzone-2.0\" is insecure and refused to create it (bug#6466)

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@510 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-31 17:02:45 +00:00
Per Inge Mathisen 56279a0bb7 Remove more dead code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@506 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-24 20:12:36 +00:00
Per Inge Mathisen 6a42b3d07b Clean up display3d a bit, removing redundant or obsolete code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@505 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-24 19:42:30 +00:00
Per Inge Mathisen 2b0117a234 The new top secret password to make the game start in cheat mode is '-secret'!
To make the game enter cheat mode, start it as 'warzone -secret'.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@502 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 11:49:50 +00:00
Per Inge Mathisen ade47a9c36 Remove some now unused code used previously by software renderer only.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@501 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 11:31:51 +00:00
Per Inge Mathisen 3630fba539 Remove last remains of pie_hardware()
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@500 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 11:24:54 +00:00
Per Inge Mathisen 549c97d926 Remove even more pie_hardware() related stuff
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@499 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 11:09:10 +00:00
Per Inge Mathisen c28b3b0f10 Remove some more pie_hardware() code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@498 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 11:08:14 +00:00
Per Inge Mathisen 711ca1ff01 Remove a great deal of software renderer related code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@497 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-23 10:35:30 +00:00
Per Inge Mathisen a196f0af47 Clean up the texture loader, and removing software renderer code paths.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@496 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-22 23:35:48 +00:00
Dennis Schridde 5bdfeec464 Remove ivis02 (software renderer)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@494 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-22 22:23:43 +00:00
Dennis Schridde 3116f462fc New Makefile.raw system, works with MinGW/Windows environment and Linux also.
Uses a config.mk.tmpl file to set system dependend stuff, no bash required.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@490 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-21 21:48:55 +00:00
Dennis Schridde 07dcf43518 Fix deprecated function declaration
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@489 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-21 21:46:23 +00:00
Per Inge Mathisen 1fedb0895a Remove some dead code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@488 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-21 20:14:06 +00:00
Per Inge Mathisen 69f5d2e395 Fix some hairy if logic.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@485 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-21 18:49:00 +00:00
Per Inge Mathisen 258fa2ce9d Fix security bug in network code. Player could send a text message of size larger than receiving
buffer. Thanks to Luigi Auriemma <aluigi@autistici.org> for finding and reporting the problem.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@484 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-21 18:42:50 +00:00
Per Inge Mathisen 6606ccaf78 Fix second last warning in src/, which leaves only the probable bug in move.c
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@482 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 21:18:36 +00:00
Per Inge Mathisen 768e28914f Fix some more warnings in src/
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@481 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 21:04:01 +00:00
Per Inge Mathisen 84aed800b4 Add comment about possible bug in the waypoint code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@480 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 20:33:29 +00:00
Per Inge Mathisen 3ea637bc01 Fix warnings in game.c
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@479 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 20:15:20 +00:00
Per Inge Mathisen 48ad3e614a Change research count's variable type, since the type's maximum was lower than the defined limit.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@478 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 19:29:44 +00:00
Dennis Schridde dcf1b713ae Fix crash when using uppercase savegame names.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@477 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-20 08:47:18 +00:00
Dennis Schridde eda1fdc2a4 Make it possible for releases to define their own revision (for display in mainmenu).
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@472 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-17 20:04:27 +00:00
Dennis Schridde 941da64be3 - Document -mod enabling in -help
- Change framerate to 60


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@467 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-08 20:38:00 +00:00
Dennis Schridde 4297596af8 - Indent fixes
- More debug output.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@465 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-08 15:39:50 +00:00
Dennis Schridde f8c1cf3f7d - Fix searchpath priorities
- Also tried to fix memleaks


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@464 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-07 14:08:48 +00:00
Dennis Schridde 349b8de00e - AutoPackage download path change
configure.ac:
- Make OpenGL mandatory
- check for jpeg/png headers
- merge in my DEFAULT_DATADIR patch, because in the AutoConf manual it is listed as prefered
- Change YFLAGS/LFLAGS to make it easier for me to play with Bison/Flex
Others:
- Dont require -datadir to end with a dir separator
- Small PHYSFS fix

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@463 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-06 21:45:04 +00:00
Dennis Schridde db7b3190db - Fix the Makefile.am for SDL_framerate.c
- Fix a doubled dirSeparator in subdirs
- Fix accidential DLL creation on MSVC

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@459 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-05 22:19:23 +00:00
Dennis Schridde e9e58f3664 - Limit the framerate to 30 fps. Easily imported functionality from SDL_gfx project (http://www.ferzkopp.net/Software/SDL_gfx-2.0/).
- Fixed previous patch yet again.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@458 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-05 20:39:13 +00:00
Dennis Schridde 8160a01327 Nothing new, just fixes for last patch.
- Resolved a name conflict of SearchPath on Windows
- Cleaned up debugging messages
- Fixed illegal loading of empty path (root element of searchPathRegistry) (caused a bunch of indent changes)
- Always make WriteDir first entry in searchPath
- Fixed WZ_WRITEDIR for Windows

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@456 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-04 15:42:24 +00:00
Dennis Schridde eb7ba7e41d - Again revised the modloading(restrictions were stupid) (src/levels.c,src/init.[ch],src/multiint.c,src/main.c)
- Fixed case problem with noVideo.rpl (lib/sequence/sequence_stub.c)
- Fixed some G++ 4.1 compile problems (mostly invalid conversions) (lib/script/script_parser.y,lib/framework/frame.h,lib/framework/frameresource.c,lib/framework/frameresource.h,lib/framework/input.c,lib/framework/configfile.c,lib/framework/frame.c)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@455 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-04 13:35:01 +00:00
Dennis Schridde 6a96159075 - Again revised the way data paths are searched. See CHANGELOG for details.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@454 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-03 22:00:05 +00:00
Dennis Schridde 1b1a695684 - Fixed a HEAP error (Invalid Address specified to RtlFreeHeap) on Windows (MSVC compile) (src/data.c)
- Pointed out other locations where that error could occur (src/data.c, lib/ivis_common/pcx.c)
- Deprecated pie_ReloadTexPage, as it doesn't appear to be used (lib/ivis_opengl/tex.c)
- Made iSprite width and heigth unsigned (lib/ivis_common/pietypes.h)
- Added debugging for MSVC which doesn't understand the DB* redefines (lib/ivis_common/bitimage.c)
- Fixed deprecation for MSVC (lib/framework/macros.h

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@452 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-03 19:43:12 +00:00
Dennis Schridde 8627f307cc - Fixed crash due to freeing 2 times.
- Cleaned up unneeded frees from last memleak fix.
- Added debug info as allways.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@451 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-03 16:24:32 +00:00
Dennis Schridde ee8d18ef48 - Big memleak fixed
- DB* replaced by debug calls
- Added MSVCRT debugging flags for finding memleaks
- Added points to the TODO

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@450 4a71c877-e1ca-e34f-864e-861f7616d084
2006-07-01 19:11:05 +00:00
Dennis Schridde 37ccc21206 Fix a typo
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@442 4a71c877-e1ca-e34f-864e-861f7616d084
2006-06-21 16:02:56 +00:00
Dennis Schridde 03386361bb Readd a workaround for broken PhysFS
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@441 4a71c877-e1ca-e34f-864e-861f7616d084
2006-06-21 15:34:26 +00:00
Dennis Schridde 9c8165d360 Fix a missing '\0' which could prevent correct datadir recognition.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@439 4a71c877-e1ca-e34f-864e-861f7616d084
2006-06-21 10:00:06 +00:00
Dennis Schridde 194026f379 Rewritten mod loading
This patch includes:
- Strongly modified way of adding mods, maps and addons
- Make nearly everything use PhysFS (just netlog and debug stay)
- Convert several DBERRORs etc. to debug()

The new modloader works like this:
For every mod supplied on the commandline ("-mod") (maximum of MAX_MODS=100) keep it in mind (char * global_mods[]).
After initializing PhysFS do scanDataDirs(), which tries to register all possible paths, global_mods[] and maps with PhysFS. Dont check wether we succeed, only at the very end check if we got a "gamedesc.lev".

When we buildMapList(), mark "gamedesc.lev" as MOD_CAMPAIGN, "addon.lev" and every user supplied map as MOD_MULTIPLAY.

When we loadMods() modify the searchPath according to the supplied mods.
Note: T1 maps like Sk-Rush come from gamedesc.lev, are marked MOD_CAMPAIGN and thus wont load any multiplay_mods[], even if the user starts a multplayer game. Instead those maps are threated as campaignmode and will only load campaign_mods[].

This patch requires the "mp" patches to be either in ProgramDir/mp, in ProgramDir/data/mp or in ProgramDir/mp.wz
This is because one cannot add warzone.wz/mp to the search path if warzone.wz is an archive.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@436 4a71c877-e1ca-e34f-864e-861f7616d084
2006-06-16 19:10:23 +00:00
Dennis Schridde 5175535d9d Full pathname includes
Same as in r431, but now for lib/
- converted the sources in lib/ to use full path includes instead of just the filename.
- marked places where lib/ivis_*implementation* (eg opengl) is needed, because of incomplete lib/ivis_common.

Should improve the understanding of interfaces and code organization.

(Also fixed a double slash (//) include in src/multimenu.c)



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@432 4a71c877-e1ca-e34f-864e-861f7616d084
2006-06-02 19:34:58 +00:00
Dennis Schridde 27fadd14cf - converted the sources in src/ to use full path includes instead of just the filename.
- marked places where lib/ivis_*implementation* (eg opengl) is needed, because of incomplete lib/ivis_common.

Should improve the understanding of interfaces and code organization.



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@431 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-27 16:37:17 +00:00
Dennis Schridde f0f3709178 cleaned the buildfiles a bit up:
- removed Gentoo fix from autogen.sh as it doesn't seem to be needed anymore
- converted "ugly hack"(tm) to a .Phony target in src/Makefile.am

changed version and revision retrieval of Warzone (displayed in the mainmenu):
- Before:
    #define SVN_REVISION "..."
    - defined in src/revision.h, included and used in src/frontend.c
- Now:
    const char * version(); and const char * revision();
    - declared in src/version.h, defined in src/version.c, called in src/frontend.c



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@430 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-27 16:31:35 +00:00
Rodolphe Suescun 52c8e10ea4 Added event CALL_VIDEO_QUIT at end of intel map screen.
Should make that damn transport arrive.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@427 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-10 05:02:58 +00:00
Angus Lees b3522f3596 correct signedness of unused palette size parameter..
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@426 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-08 16:11:59 +00:00
Angus Lees c0a561cfb1 intelmap.c: Add new "seqtext" display for displaying the subtitles
from videos.  Will do until we get proper video support.
intelmap.c: Temporarily disable the Flic box, since it just loops on
	    noVideo.rpl until we have real video
intelmap.c: Hack displayImmediateMessage again to popup new
	    IntelScreen seqtext display
rpl_reader: Convert to PHYSFS calls
seqdisp.c:  Move "novideo.rpl" squashing to sequence_stub.c
seqdisp.c:  Fix seq_AddTextForVideo() prototype
scriptfuncs.c: Avoid race when winlose video callback needs to be called during		       displayImmediateMessage


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@425 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-08 15:10:45 +00:00
Angus Lees ef21733bf0 fix some simple compile warnings (some of them would be bugs on non-i386)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@424 4a71c877-e1ca-e34f-864e-861f7616d084
2006-05-03 23:10:36 +00:00
Rodolphe Suescun 71c79af87d Added code for modding.
Fixed Makefile.raw stuff.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@422 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-29 07:09:00 +00:00
Per Inge Mathisen e467933c79 Display scenario intelligence briefings as console messages. They are
often way too fast for users to read, but it is a step in the right
direction. Patch by Angus Lees.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@420 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-20 18:49:51 +00:00
Per Inge Mathisen 67d648a2a2 The research items rotate too quickly, so slow them down to one
full rotation every 2 seconds, independent of frame rate. Patch
by Angus Lees.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@419 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-20 18:43:08 +00:00
Per Inge Mathisen 9bb74458c8 When you load a savegame where two (enemy?) units are adjacent(?) to each other, its
possible to hit a div by zero bug in visibility.c:visibleObject().

Problem occurs when rayCast() calls rayLOSCallback() and the callback exits due to 
(distSq >= tarDist) being true, without ever having executed the following block that 
updates lastD. lastD remains 0 and the divide at the end of visibleObject throws a 
SIGFPE. On any later occasion, the last distance value from the last calculation will be 
reused in this case, which is still bogus but isn't fatal.

The fix is easy, just add "lastD = dist;" before the return in the (distSq >= tarDist) 
case.

Patch by Angus Lees <gus> in bug #5761.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@418 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-12 14:58:40 +00:00
Dennis Schridde 40090410ac - Cleaned up stubs
- Removed unused/outdated ivis02/Ivis02.dsp/.vcproj and  src/mpdpxtra.[ch]
- Replaced src/mplayer.c with a stub, containing only mplayerSubmit()
- Added DEPRECATED warnings
- Added documentation for WZ_DEPRECATED
One commit follows, to finish the move from ivis02/v4101_stub.c to ivis02/v4101.c



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@415 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-08 19:14:30 +00:00
Dennis Schridde b84d79a576 - Drastically simplyfied mouse-handling.
Patch by Cybersphinx

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@414 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-08 16:13:48 +00:00
Dennis Schridde daf32736ad - Remove CD handling code, which is not used anymore.
Patch by Cybersphinx.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@413 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-08 15:58:27 +00:00
Dennis Schridde 628a06067b lib/ivis_opengl/screen.c:
- G++ fix( PHYSFS_file ).

other:
 - Simplify sound code.
 - Make Warzone run with busy audio device (Linux).

All patches by cybersphinx.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@412 4a71c877-e1ca-e34f-864e-861f7616d084
2006-04-01 17:50:19 +00:00
Rodolphe Suescun 045755e9a3 Minor changes in menus (new audio config menu).
Prepared mod stuff.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@411 4a71c877-e1ca-e34f-864e-861f7616d084
2006-03-27 19:53:36 +00:00
Rodolphe Suescun e82eebdf07 Merged all (useless, wicked) patches into data/mp directory.
Fixed button highlight problem in the map selection GUI (was
a very funny bug :) ).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@410 4a71c877-e1ca-e34f-864e-861f7616d084
2006-03-27 11:03:10 +00:00
Dennis Schridde 06966cc158 Quick crashfix for Windows, regarding datadir recognition.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@403 4a71c877-e1ca-e34f-864e-861f7616d084
2006-03-05 14:29:32 +00:00
Rodolphe Suescun e36796f6ce Made necessary changes so that code can be compiled using g++.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@402 4a71c877-e1ca-e34f-864e-861f7616d084
2006-03-01 06:12:28 +00:00
Rodolphe Suescun aa3c7b4ff7 Added shadows as an option.
Alt-S (can be modified) to toggle.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@401 4a71c877-e1ca-e34f-864e-861f7616d084
2006-02-28 14:04:59 +00:00
Dennis Schridde 1e7edf9fa2 Fixes some minor memleaks and marks the source of the big one in pie_PNGLoadMem.
Also big amount of whitespace changes, sorry for the inconvenience...



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@400 4a71c877-e1ca-e34f-864e-861f7616d084
2006-02-18 18:54:37 +00:00
Rodolphe Suescun 984de8f9c2 Integrated new tileset from grimandmandy.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@397 4a71c877-e1ca-e34f-864e-861f7616d084
2006-02-16 07:32:34 +00:00
Rodolphe Suescun f35669c212 Fixed problem in data patch 05. Maybe all patches should be
merged...
Now filenames are case insensitive (will help using maps
created with Qamly's EditWorld).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@396 4a71c877-e1ca-e34f-864e-861f7616d084
2006-02-15 09:57:55 +00:00
Rodolphe Suescun d72f0cdc02 Fixed data directory problem.
Fixed sound source destruction problem.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@395 4a71c877-e1ca-e34f-864e-861f7616d084
2006-02-11 09:00:20 +00:00
Per Inge Mathisen 22a78c80bc Add helpful comments to command line parsing code.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@392 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-22 12:32:20 +00:00
Per Inge Mathisen 865ef8f633 Even more PSX code removed. Will the horror never end?
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@391 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-21 17:53:06 +00:00
Per Inge Mathisen 9aa3edda64 Fix data path problems under Windows created by previous autopackage patch. Make sure we
check for presence of gamedesc.lev before thinking a path is good. Add more data path 
checks, and gracefully drop paths that do not work.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@390 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-21 15:36:20 +00:00
Rodolphe Suescun 62b6055732 Small change in water rendering code (will require changes
in tilesets).
Fixed 2 memory leaks.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@389 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-19 10:09:20 +00:00
Per Inge Mathisen 45a97f4204 Reinstate patch loading on game start for now, so that people can play without crashing
on building limits menu. This should be fixed properly later. See bug#4968. Reported 
first by dpblnt <dpblnt>. Added FIXME comment.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@387 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-16 18:55:31 +00:00
Per Inge Mathisen 5b6b5ecf78 Add more info to command line option -help, patch by Christian Vest Hansen
<karmazilla@gmail.com>.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@385 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-16 18:48:03 +00:00
Dennis Schridde a166a71cc9 Commandline options changed:
-datapath is now named -datadir to match the internal variables again.
        Added -help to show all possible command line options.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@383 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-15 12:43:16 +00:00
Dennis Schridde 16fe51a87e Added AutoPackage (http://www.autopackage.org/) support.
Show version in mainmenu.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@381 4a71c877-e1ca-e34f-864e-861f7616d084
2006-01-15 11:40:43 +00:00
Rodolphe Suescun 9a6e9fa9e2 Changes in the map selection GUI.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@380 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-28 18:28:12 +00:00
Rodolphe Suescun 12ad64f101 Added support for *.addon.lev files in mods.
small fixes in the GUI (support for more maps etc.).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@379 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-28 16:19:33 +00:00
Rodolphe Suescun 7cbcd91f70 Added support for addons directory.
Small fixes in openGL renderer.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@377 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-27 06:12:51 +00:00
Rodolphe Suescun 458fa98415 Converted remaining pcx files.
Tried to fix the patches-loaded-in-campaign-mode problem.
  this fix must be tested now...
Fixed problem with pasting host address.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@376 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-22 14:33:32 +00:00
Per Inge Mathisen 5c9ab850c1 Remove unused file
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@375 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-10 15:51:19 +00:00
Rodolphe Suescun e2226d927d More Windows-related fixes.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@372 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-05 16:47:41 +00:00
Rodolphe Suescun 9b001a7131 Integrated master server patch from Henri Valta.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@370 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-02 21:45:42 +00:00
Per Inge Mathisen 8968b30363 Drop the use of soon-to-be-deprecated function PHYSFS_setSaneConfig() and make the
default write directory warzone-2.0 for Windows and .warzone-2.0 for Linux under the 
user's home directory.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@368 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-02 08:48:36 +00:00
Rodolphe Suescun d3629e24f9 Fixed various file loading/saving in windows version (related to
using PHYSFS_getDirSeparator() to build paths).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@367 4a71c877-e1ca-e34f-864e-861f7616d084
2005-12-01 20:22:35 +00:00
Rodolphe Suescun f780a15b6d Decreased min camera distance (will be useful for artists).
Fixed paths for savegames and screendumps.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@366 4a71c877-e1ca-e34f-864e-861f7616d084
2005-11-30 21:09:38 +00:00
Per Inge Mathisen 6778317ddf Try to fix path problems in Windows, and add more debug logging of path operations for
easier future debugging. Problem reported by Grim.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@364 4a71c877-e1ca-e34f-864e-861f7616d084
2005-11-28 11:07:02 +00:00
No Author 5ba7ddac6b Create final repository structure.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@362 4a71c877-e1ca-e34f-864e-861f7616d084
2007-06-28 17:47:08 +00:00