Commit Graph

52 Commits (daad83d316eec164d38ac076768285be5def37ca)

Author SHA1 Message Date
Per Inge Mathisen 015ed6d869 Fix problem that prevented multisync from working, and remove unused
related game parameters. Also fix savegame incompatibility introduced 
in a previous commit (will break savegames made in last few revisions).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3272 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-31 13:52:58 +00:00
Freddie Witherden 50506c390c Remove the number of packets which can be sent per second in an MP game. Also tune the max bytes per second to that of a 28.8KB/s modem.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3268 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-31 11:07:07 +00:00
Per Inge Mathisen cf9e866aaf A bit of cleanup in multisync.c, sprinkle some debug log calls, and ignore packet limits for ping checks.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3267 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-31 11:01:22 +00:00
Per Inge Mathisen d8c5f7ccd3 Clean up intdisplay and fix a bug where a factory that was destroyed
while viewing it made the game crash.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3264 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-31 00:20:37 +00:00
Per Inge Mathisen b4ef4d4349 Add new function attribute WZ_DECL_WARN_UNUSED_RETURN and use it on IdToDroid,
whose return must be checked, and fix one bug already detected by it.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3260 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 21:44:14 +00:00
Giel van Schijndel 05d14b995a * Move the send/recv-HappyVtol functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3243 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:13:23 +00:00
Giel van Schijndel 6d19aa6473 * Move the send/recv-GroupOrder functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3242 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:11:39 +00:00
Giel van Schijndel 352246e652 * Move the send/recv-DroidSecondaryAll functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3241 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:10:01 +00:00
Giel van Schijndel 204611ba6b * Move the send/recv-DroidSecondary functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3240 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:08:13 +00:00
Giel van Schijndel 8e1536d867 * Move the send/recv-DroidMove functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3239 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:07:11 +00:00
Giel van Schijndel ed2ac88c21 * Move the send/recv-DroidInfo functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3238 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:05:15 +00:00
Giel van Schijndel 498b6c4660 * Move the send/recv-DroidEmbark functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3237 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:02:53 +00:00
Giel van Schijndel 28f5f74aba * Move the send/recv-DroidDisEmbark functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3236 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 17:01:17 +00:00
Giel van Schijndel 7a0be7c719 * Move the send/recv-Droid functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3235 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 16:59:20 +00:00
Giel van Schijndel 66e3517354 * Move the send/recv-DestroyDroid functions over to the new net primitives API (patch #905 by myself)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3234 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-30 16:57:14 +00:00
Freddie Witherden 8f5fb1c714 Commit the final part of patch #897 (send/recvDestroyStructure)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3161 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-24 15:15:10 +00:00
Freddie Witherden ea9d378131 Commit part 3 of patch #897 (and there is still more to come!).
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3158 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-24 14:57:58 +00:00
Freddie Witherden 3bc0d30be1 Commit part two of patch #897 by Buginator along with some small changes by myself.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3156 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-24 14:47:44 +00:00
Freddie Witherden 838e9f6009 Commit the first patch of patch #897 by Buginator and myself with some additional changes by myself
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3155 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-24 14:41:25 +00:00
Giel van Schijndel e8be7978e6 * Make some functions const correct
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@3151 4a71c877-e1ca-e34f-864e-861f7616d084
2007-12-24 11:59:47 +00:00
Freddie Witherden f2e4a18d5f Merge 2877 and 2878 from the netcode branch into the trunk
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2879 4a71c877-e1ca-e34f-864e-861f7616d084
2007-11-25 20:27:50 +00:00
Giel van Schijndel 415ac4a437 * Fix readFXData to mark all the EFFECTs it loads as active
* Add a large amount of serializeX/deserializeX functions for the different savegame versions
 * Use uintX_t instead of the *WORD series of variables for structures that'll be saved out to disk (only those directly related to savegame code right now)
 * Make the save&load functions in game.c use the serialization and deserialization series of functions (this is also directly from a file rather than an intermediate in-memory buffer)
 * Remove function endian_SaveGameV since endian swapping is being dealt with by the (de)serialization functions
 * This commit changes the *.gam files from little endian to big endian, so expect loading of previous savegames to break

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2416 4a71c877-e1ca-e34f-864e-861f7616d084
2007-08-18 21:37:37 +00:00
Per Inge Mathisen f9a3adeaba Rename multiplayer game mode "Campaign" to "Mayhem" mode. Remove possibility
of alliances in this mode, and always add scavengers. Note that this mode
will not work if there are eight human players, and I do not know exactly
what will happen in this case. A check to remove scavengers has been added, 
but not tested. The problem is of course that scavengers need a player, too.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2158 4a71c877-e1ca-e34f-864e-861f7616d084
2007-07-21 16:44:38 +00:00
Per Inge Mathisen ac131d745f Remove separate "team play" game mode. We now have proper team play
functionality in the skirmish game mode, so it is not necessary.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2155 4a71c877-e1ca-e34f-864e-861f7616d084
2007-07-21 15:39:00 +00:00
Per Inge Mathisen 6a25589a62 Add network statistics logging, to figure out which parts of the code consume
the most network bandwidth. Look in in the netplay.log file for this info.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2113 4a71c877-e1ca-e34f-864e-861f7616d084
2007-07-15 15:26:23 +00:00
Per Inge Mathisen 851cd03367 Remove unused packet vtolrearm
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@2107 4a71c877-e1ca-e34f-864e-861f7616d084
2007-07-15 13:08:59 +00:00
Per Inge Mathisen 4390632ce8 Add missing header guards
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1962 4a71c877-e1ca-e34f-864e-861f7616d084
2007-06-24 21:51:29 +00:00
Giel van Schijndel 2d85204f13 Cleanup:
* remove commented out functions (which where only used by commented out code if they where used at all, removed that code as well)
 * movement stuff:
  - moveShuffleInit (// Initialize a droid for a shuffle move)
  - moveCalcVector (// Calculate the normalised vector between a droid and a point)
 * waypoint stuff:
  - orderAddWayPoint (// Append a new waypoint to a droid's list)
  - orderSelectedWaypoint (// Add a new waypoint to selected droid set)
  - SendSingleDroidWaypoint (// Occasionally need to send non selected waypoints ??)
  - recvDroidWayPoint (// recv)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1738 4a71c877-e1ca-e34f-864e-861f7616d084
2007-05-29 09:50:45 +00:00
Roman C 3dc727f709 - fix slider assert in multiplayer
- replace slider numbers spread out in the code with define

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1731 4a71c877-e1ca-e34f-864e-861f7616d084
2007-05-28 14:58:31 +00:00
Stefan Huehner f953bf0331 Small cleanup:
mark some char* vars and parameters as const.



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1255 4a71c877-e1ca-e34f-864e-861f7616d084
2007-03-16 20:26:40 +00:00
Dennis Schridde 2a74242eb3 - Replaced various vectors with Vector3i and Vector3f (idea by Watermelon)
- Vector3i from lib/ivis also used in lib/audio, maybe want to move it to some more generic place?
- Replace iPoint with Vector2i
- Remove additional integer type declarations from pietypes.h
- Rename all iSprite to iTexture
- Various warning fixes: Unsigned/signed comparisons, uninitialized variables, declared but not defined symbols
- Replace DEBUG_BLOCK with DEBUG_MALLOC (it was virtually the same)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1245 4a71c877-e1ca-e34f-864e-861f7616d084
2007-03-16 16:20:16 +00:00
Per Inge Mathisen 94446216f2 Remove last "gamespy" related code, and stop reloading the config file
so often (we keep it in memory, after all).


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1175 4a71c877-e1ca-e34f-864e-861f7616d084
2007-02-24 20:46:17 +00:00
Dennis Schridde 49ceba7503 Add GPL notices to all sourcecode files.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1014 4a71c877-e1ca-e34f-864e-861f7616d084
2007-01-15 20:09:25 +00:00
Stefan Huehner da14eaf2ad Add some more const to char* function parameters,
which aren't modified inside the called function.



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@853 4a71c877-e1ca-e34f-864e-861f7616d084
2006-11-23 13:28:38 +00:00
Dennis Schridde 770af57c20 Remove more extra types
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@812 4a71c877-e1ca-e34f-864e-861f7616d084
2006-11-04 23:16:51 +00:00
Dennis Schridde 67056c8d24 - Droped a lot of (nearly) unused types from lib/framework/types.h
- Remove lots of unused functions (Windows/DDraw related)
- Now store the used bitdepth in the config and thus make it configurable without having to modify the sourcecode


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@808 4a71c877-e1ca-e34f-864e-861f7616d084
2006-11-04 01:11:26 +00:00
Dennis Schridde d3cd44148d Patch by Gerard Krol: Replace STRING with char (STRING was confusingly defined to char)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@804 4a71c877-e1ca-e34f-864e-861f7616d084
2006-11-03 21:35:50 +00:00
Roman C 0aeea43f15 Changed scripting functions to use british spelling of "color"
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@781 4a71c877-e1ca-e34f-864e-861f7616d084
2006-10-08 14:08:53 +00:00
Roman C 7f143b5a48 New script callbacks are called delayed now, since there was a problem when forming alliance.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@775 4a71c877-e1ca-e34f-864e-861f7616d084
2006-10-04 02:54:24 +00:00
Roman C e34c09439c -New script callbacks
-Added ability to rename players through scripts
-New savegame version: 34 (as a result of the previous point)
-Fixed double messages in online games
-Minor cleanups

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@771 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-30 23:09:12 +00:00
Roman C 9aaae50baa Replaced 'Humans vs AIs' with 'Locked Teams' alliance mode.
Fixed difficulty slider applying settings to the wrong players.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@763 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-26 18:14:05 +00:00
Stefan Huehner 30f6dc392e mark some Strings an read-only by adding const.
On the way replace STRING with char



git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@756 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-24 19:11:34 +00:00
Roman C 741250cef3 -Added "Humans vs AIs" alliance mode: Humans and AIs make 2 teams, alliances cannot be created or broken
-Added now frontend texture to frend.img
-Disabled "Allied players send vision to each other automatically (only once)" for "Allow alliances" alliance mode, since (x allied y) is not a transitive relation in this mode

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@744 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-21 20:42:48 +00:00
Roman C 15b02fe669 Fixed script compilation bugs,
further scripting enhancements.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@729 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-19 16:07:06 +00:00
Dennis Schridde fc4ce66939 Patch "code cleanup: void 2" by Stefan Huehner
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@705 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-13 12:58:32 +00:00
Dennis Schridde 728b9a9913 - Commit patches "code cleanup: void" and "code cleanup: const" by Stefan Huehner
- Replace every occurence of VOID with void (and LPVOID with void*)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@703 4a71c877-e1ca-e34f-864e-861f7616d084
2006-09-13 09:09:05 +00:00
Roman C c1c801383e Fixed compilation on GCC
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@650 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-26 20:51:54 +00:00
Roman C a9a74444a1 Added beacons for skirmish and multiplayer, default key combination: Alt+H.
Allied players send vision to each other automatically (only once)
Fixed caching problems for variables of type GROUP
Some other scripting engine updates and cleanups

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@647 4a71c877-e1ca-e34f-864e-861f7616d084
2006-08-26 15:50:47 +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