//---------------------------------------------------------------------------- // File: E-Universe.h // Class: EUniverse // Type: 3D World Management. // Author: Ken Anderson // Date: 7/17/05 // OS dependant: Etherspace // Desc: A class specifically designed to manage the 3d Worlds of Etherspace. // Versions: // 1.0[7/17/05] -- Creation. // Required headers: // //---------------------------------------------------------------------------- #ifndef __EUNIVERSE__ #define __EUNIVERSE__ #include "ESCommon.h" #include "CRS.h" #include "ESCore.h" //////////////////////////////////REMOVABLES[3/5/5]///////////////////////////////// typedef enum UNIVERSAL_PACKET_TYPE { UPT_UNKNOWN, UPT_VERTEX, UPT_RENDERSTATE, UPT_TRANSFORM, UPT_MATRIX, UPT_LIGHT, UPT_MATERIAL, UPT_TEXTURE, UPT_OBJECT, } UPT; typedef struct UNIVERSAL_PACKET { void* pPacket; UPT type; } SC3DUniversal, *PSC3DUniversal, **HSC3DUniversal; //////////////////////////////////REMOVABLES[3/5/5]///////////////////////////////// class EUniverse { private: ESCore* m_pCore; //////////////////////////////////REMOVABLES[3/5/5]///////////////////////////////// C3DVertices* pSkyBox; C3DTextures* pSkyBoxTex; C3DIndices* pIndx; C3DQuad* pstar; C3DQuad* pWel; float lasttime; float fratelast; bool m_bReadyToDisplay; string m_err; CBank g_3DObjects; //////////////////////////////////REMOVABLES[3/5/5]///////////////////////////////// //Member Functions public: //Constructor & Destructors. EUniverse(); ~EUniverse(); //Methods ECTYPE Startup(); void Shutdown(); //Event Management void OnAppActivate(Dword dwActive); void OnPaint(); void OnQuit(); void OnMouseMove(int x, int y); void OnLButtonDown(int x, int y){}; void OnIdle(); void OnChar(Byte byChar); void OnKeyDown(Dword dwValue); void OnKeyUp(Dword dwValue); void OnCommand(Dword dwValue){}; private: void Create3DScene(); void Cleanup(); // Map file management // /* void LoadMapp(cstr pFileName, CBank* pBank); void LoadObjectFile(string sFileName, CBank* pBank); bool LoadObject(void** hvObject, UPT* pupt, CText text); bool Load3DFile(string sFileName, CTextPage* pP); */ void CleanMapp(CBank* pBank); // Map file management // // //////////////////////////////////REMOVABLES[3/5/5]///////////////////////////////// }; #endif