00001 /* 00002 CS Senior Project 2003 00003 Team : Leftfield 00004 Project : ModernWarfare 00005 Members : 00006 - Russ Christensen <rchriste@cs.utah.edu> 00007 - Todd Smith <tcsmith@cs.utah.edu> 00008 - Usit Duongsaa <duongsaa@cs.utah.edu> 00009 Copyright 2003 Russ Christensen, Usit Duongsaa, and Todd Smith. All rights reserved. 00010 00011 Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 00012 00013 Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 00014 Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 00015 THIS SOFTWARE IS PROVIDED BY RUSS CHRISTENSEN, USIT DUONGSAA, AND TODD SMITH ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL RUSS, USIT, TODD OR OTHER CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00016 */ 00017 00022 #ifndef INCLUDE_BATTLESTATE 00023 #define INCLUDE_BATTLESTATE 00024 00025 #include "..\AEngine\AEngine.h" 00026 #include "Globals.h" 00027 #include "BattleGroup.h" 00028 #include "BattleUnit.h" 00029 #include "BattleBullet.h" 00030 #include "BattleSprite.h" 00031 #include "BattleJets.h" 00032 #include "BattleDebris.h" 00033 00034 using namespace Globals; 00035 00036 const int MAX_BULLET = 1024; 00037 00038 //------------------------------------------------------------------------------------ 00040 class BattleState 00041 { 00042 public: 00043 BattleState() 00044 { 00045 bulletCount = 0; 00046 } 00047 00048 inline void addBullet( const BattleBullet b ) 00049 { 00050 if ( bulletCount < MAX_BULLET ) bullets[bulletCount++] = b; 00051 } 00052 00053 vector<BattleGroup> groups; 00054 vector<BattleJets> jets; 00055 list<BattleSprite> sprites; 00056 list<BattleDebris> debris; 00057 BattleBullet bullets[MAX_BULLET]; 00058 int bulletCount; 00059 ATerrain terrain; 00060 Vec3D teamAColor, teamBColor; 00061 00062 00063 // for synch checking purposed 00064 int synch_firstShotTick; 00065 int synch_firstKillTick; 00066 00067 // conditional voice 00068 // record time (in game ticks) when we last play voice of each type 00069 int m_cvLastContact; 00070 int m_cvLastStress; 00071 int m_cvLastPanick; 00072 00073 }; 00074 //------------------------------------------------------------------------------------ 00075 00076 #endif
1.3-rc2