- Bumped netgame, demo and min demo version for the weapon slot changes.

- changed weapon slots to be stored per player. Information is now transmitted
  across the network so that all machines know each player's current weapon
  configuration so that it can be used by cheats or HUD display routines.


SVN r1430 (trunk)
This commit is contained in:
Christoph Oelckers 2009-02-20 22:28:48 +00:00
commit 4b723beddd
13 changed files with 218 additions and 71 deletions

View file

@ -735,14 +735,10 @@ void cht_Give (player_t *player, const char *name, int amount)
{
// Give the weapon only if it belongs to the current game or
// is in a weapon slot. Unfortunately this check only works in
// singleplayer games because the weapon slots are stored locally.
// In multiplayer games or demos all weapons must be given because the state of
// the weapon slots is not guaranteed to be the same when recording or playing back.
if (multiplayer || demorecording || demoplayback ||
type->ActorInfo->GameFilter == GAME_Any ||
// is in a weapon slot.
if (type->ActorInfo->GameFilter == GAME_Any ||
(type->ActorInfo->GameFilter & gameinfo.gametype) ||
LocalWeapons.LocateWeapon(type, NULL, NULL))
player->weapons.LocateWeapon(type, NULL, NULL))
{
AWeapon *def = (AWeapon*)GetDefaultByType (type);
if (!(def->WeaponFlags & WIF_CHEATNOTWEAPON))