mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-03-22 15:05:03 +01:00
35 lines
1.0 KiB
C++
35 lines
1.0 KiB
C++
//---------------------------------------------------------------------------
|
|
#ifndef MdlMngrH
|
|
#define MdlMngrH
|
|
|
|
|
|
#include "Model3d.h"
|
|
#include "usefull.h"
|
|
|
|
class TMdlContainer
|
|
{
|
|
friend class TModelsManager;
|
|
__fastcall TMdlContainer() { Name= NULL; Model= NULL; };
|
|
__fastcall ~TMdlContainer() { SafeDeleteArray(Name); SafeDelete(Model); };
|
|
TModel3d* __fastcall LoadModel(char *newName,bool dynamic);
|
|
TModel3d *Model;
|
|
char *Name;
|
|
};
|
|
|
|
class TModelsManager
|
|
{//klasa statyczna, nie ma obiektu
|
|
private:
|
|
static TMdlContainer *Models;
|
|
static int Count;
|
|
static TModel3d* __fastcall LoadModel(char *Name,bool dynamic);
|
|
public:
|
|
// __fastcall TModelsManager();
|
|
// __fastcall ~TModelsManager();
|
|
static void __fastcall Init();
|
|
static void __fastcall Free();
|
|
//McZapkie: dodalem sciezke, notabene Path!=Patch :)
|
|
static TModel3d* __fastcall GetModel(const char *Name,bool dynamic=false);
|
|
};
|
|
//---------------------------------------------------------------------------
|
|
#endif
|