[Gcblue-commits] gcb_wx/include/sim Game.h,1.44,1.45 tc3DViewer.h,1.26,1.27 tcGameObject.h,1.24,1.25
Status: Alpha
Brought to you by:
ddcforge
|
From: Dewitt C. <ddc...@us...> - 2004-09-06 01:08:15
|
Update of /cvsroot/gcblue/gcb_wx/include/sim In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11943/include/sim Modified Files: Game.h tc3DViewer.h tcGameObject.h tcGoalTracker.h tcPlatformObject.h tcSimState.h Log Message: Index: tcGameObject.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/tcGameObject.h,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** tcGameObject.h 8 Aug 2004 00:31:33 -0000 1.24 --- tcGameObject.h 6 Sep 2004 01:08:03 -0000 1.25 *************** *** 147,150 **** --- 147,151 ---- virtual void GetLauncherState(tcLauncherState*& pLauncherState) {pLauncherState = NULL;} virtual tcLauncher* GetLauncher(unsigned idx) {return 0;} + float GetSpan(); float GetTerrainElevation() {return mcTerrain.mfHeight_m;} virtual void Launch(tnPoolIndex& rnKey, unsigned& rnLauncher) {} Index: tcGoalTracker.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/tcGoalTracker.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** tcGoalTracker.h 5 Sep 2004 02:38:44 -0000 1.2 --- tcGoalTracker.h 6 Sep 2004 01:08:03 -0000 1.3 *************** *** 23,26 **** --- 23,27 ---- bool HasAllianceFailed(int alliance); bool HasAllianceSucceeded(int alliance); + bool HasStatusChanged(int alliance); void LogAllianceGoalStatus(std::string fileName, int alliance); void SetAllianceGoal(int alliance, tcGoal* goal); *************** *** 33,36 **** --- 34,38 ---- double lastUpdateTime; const double updateInterval; ///< game time between updates + std::map<int, int> previousGoalStatus; ///< status at last update }; Index: tcSimState.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/tcSimState.h,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** tcSimState.h 29 Jul 2004 00:14:16 -0000 1.27 --- tcSimState.h 6 Sep 2004 01:08:03 -0000 1.28 *************** *** 132,136 **** void GenerateRandomGoals(); int GetAllSensorPlatforms(long *apKeyList, int anMaxLength); ! unsigned GetAlliancePlatforms(tnPoolIndex *aaKeyList, unsigned anMaxLength, int anAlliance); int GetAllWeaponObjects(long *apKeyList,int anMaxLength); void GetDateZulu(DateZulu& dz) {dz = dateZulu;} --- 132,136 ---- void GenerateRandomGoals(); int GetAllSensorPlatforms(long *apKeyList, int anMaxLength); ! unsigned GetAlliancePlatforms(long *aaKeyList, unsigned anMaxLength, int anAlliance); int GetAllWeaponObjects(long *apKeyList,int anMaxLength); void GetDateZulu(DateZulu& dz) {dz = dateZulu;} Index: Game.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/Game.h,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** Game.h 16 Aug 2004 01:43:30 -0000 1.44 --- Game.h 6 Sep 2004 01:08:03 -0000 1.45 *************** *** 188,192 **** MODE3D_SMALL = 0, ///< corner view MODE3D_MEDIUM = 1, ///< size of tactical map ! MODE3D_FULL = 2 ///< full screen }; enum teTacticalMapSize --- 188,193 ---- MODE3D_SMALL = 0, ///< corner view MODE3D_MEDIUM = 1, ///< size of tactical map ! MODE3D_FULL = 2, ///< full screen ! MODE3D_START = 3 ///< mode for start screen display }; enum teTacticalMapSize *************** *** 208,216 **** --- 209,221 ---- wxPoint smallViewerPosition; wxSize smallViewerSize; + wxPoint startViewerPosition; + wxSize startViewerSize; int multiplayerMode; ///< 0 - single-player, 1 - client, 2 - server void Activate(); bool DirectoryExists(char *azDirectory); + void DisplayOutcomeDialog(bool playerWon); void EndGame(); + void EndGame(wxCommandEvent& event); bool Finish(); teMenuMode GetMenuMode(); *************** *** 221,225 **** void CheckGoals(); ///< checks if any win/loss goals satisfied void ConsoleMessage(const char *s); ///< print string to info console ! void HookSomethingFriendly(); ///< used to avoid blank 3D screen in rand scenario void NewGroupHook(wxCommandEvent& event); ///< event for group of units hooked void NewHook(wxCommandEvent& event); ///< event for single unit hooked (deprecated) --- 226,230 ---- void CheckGoals(); ///< checks if any win/loss goals satisfied void ConsoleMessage(const char *s); ///< print string to info console ! void HookRandomFriendly(); ///< hooks random friendly platform void NewGroupHook(wxCommandEvent& event); ///< event for group of units hooked void NewHook(wxCommandEvent& event); ///< event for single unit hooked (deprecated) Index: tcPlatformObject.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/tcPlatformObject.h,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** tcPlatformObject.h 8 Aug 2004 00:31:33 -0000 1.19 --- tcPlatformObject.h 6 Sep 2004 01:08:03 -0000 1.20 *************** *** 90,93 **** --- 90,94 ---- virtual void GetDatum(tsGeoPoint& p) {p=msTargetDatum;} virtual tcLauncher* GetLauncher(unsigned idx); + wxString GetLauncherDescription(); virtual int GetLauncherQuantity(unsigned anLauncher); virtual void GetLauncherState(tcLauncherState*& pLauncherState) {pLauncherState=&mcLauncherState;} *************** *** 101,104 **** --- 102,106 ---- //virtual std::vector<tcSensorState*>* GetSensorStateArray() {return &mapSensorState;} virtual const tcSensorState* GetSensor(unsigned idx); + wxString GetSensorDescription(); virtual tcSensorState* GetSensorMutable(unsigned idx); virtual void Launch(tnPoolIndex& rnKey, unsigned& rnLauncher); Index: tc3DViewer.h =================================================================== RCS file: /cvsroot/gcblue/gcb_wx/include/sim/tc3DViewer.h,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** tc3DViewer.h 9 Aug 2004 02:35:14 -0000 1.26 --- tc3DViewer.h 6 Sep 2004 01:08:03 -0000 1.27 *************** *** 40,43 **** --- 40,44 ---- class tcSimState; class tcGameObject; + class tc3DModel; class tc3DTerrain; class tc3DSky; *************** *** 67,71 **** osg::ref_ptr<osg::Group> rootnode; osg::ref_ptr<osgParticle::ParticleSystemUpdater> particleSystemUpdater; ! osgUtil::Optimizer optimizer; tc3DTerrain *terrainManager; --- 68,72 ---- osg::ref_ptr<osg::Group> rootnode; osg::ref_ptr<osgParticle::ParticleSystemUpdater> particleSystemUpdater; ! osgUtil::Optimizer optimizer; tc3DTerrain *terrainManager; *************** *** 91,97 **** --- 92,109 ---- void AttachSimState(tcSimState *ss) {simState = ss;} void SkipMouseEvent(wxMouseEvent& event); ///< adjusts position to parent frame + void AddText(osgText::Text *text); void RemoveText(osgText::Text *text); + void AddDefaultTextObjects(); + void ClearDefaultTextObjects(); + void AddTextObject(int key, const osg::Vec3& pos, float fontSize, + const osg::Vec4& color, + osgText::Text::AlignmentType alignment); + void ClearTextObject(int key); + void ClearTextObjects(); + bool TextObjectExists(int key); + void UpdateTextObject(int key, const std::string& text); + void CreateScene(); void CreateSky(); *************** *** 99,102 **** --- 111,117 ---- void Frame(); void Freeze(); + float GetCameraAz() {return cameraAz;} + float GetCameraEl() {return cameraEl;} + float GetCameraRange() {return cameraRange;} osg::Vec3 GetCameraPosition(); double GetGameTime() const {return gameTime;} *************** *** 104,109 **** --- 119,127 ---- bool IsActive() {return isActive;} void LoadModel(tcGameObject *obj); + void SetActive(bool b) {isActive = b;wxWindow::Enable(b);wxWindow::Show(b);} void SetCameraMode(bool lookAt, bool moveWith); + void SetClearMode(int modeCode); + void SetGameTime(double t); void SetGeoPosition(double lon_rad, double lat_rad, float alt_m); *************** *** 111,116 **** void SetLook(float az, float el); void SetCartesianOffset(float x, float y, float z); ! void SetPolarOffset(float az, float el, float range); void SetText(const char *s); void Swap(); void ToggleFog(); --- 129,142 ---- void SetLook(float az, float el); void SetCartesianOffset(float x, float y, float z); ! ! void SetPolarOffset(float az, float el, float range); ! ! void SetCameraAz(float az); ! void SetCameraEl(float el); ! void SetCameraRange(float range_m); ! ! void SetTerrainActive(bool state); void SetText(const char *s); + void SetTextPosition(int positionCode); void Swap(); void ToggleFog(); *************** *** 132,135 **** --- 158,163 ---- bool isFrozen; ///< set true if window has been frozen bool isActive; + bool isTerrainActive; + bool impostorModeActive; ///< true if 3D is in imposter mode bool viewWireframe; bool useRelativeChildPos; ///< true to add children as children of parent transform group *************** *** 171,174 **** --- 199,203 ---- float lookElStart; ///< camera look el start for mouse look bool isMouseDown; + std::map<int, osgText::Text*> textMap; void InitLight(); |