Veinlook only needs base maps now.

develop
Petr Mrázek 2011-02-15 01:14:44 +01:00
parent 2d28d1aaf9
commit 4ead59e698
1 changed files with 35 additions and 19 deletions

@ -549,7 +549,6 @@ main(int argc, char *argv[])
{ {
pDF = DF = DFMgr.getSingleContext(); pDF = DF = DFMgr.getSingleContext();
DF->Attach(); DF->Attach();
Mats = DF->getMaterials();
Maps = DF->getMaps(); Maps = DF->getMaps();
} }
catch (exception& e) catch (exception& e)
@ -560,6 +559,15 @@ main(int argc, char *argv[])
#endif #endif
finish(0); finish(0);
} }
bool hasmats = true;
try
{
Mats = DF->getMaterials();
}
catch (exception& e)
{
hasmats = false;
}
Process* p = DF->getProcess(); Process* p = DF->getProcess();
// init the map // init the map
@ -574,17 +582,22 @@ main(int argc, char *argv[])
y_max = y_max_a; y_max = y_max_a;
z_max = z_max_a; z_max = z_max_a;
bool hasimats = 1; bool hasimats = false;
bool hascmats = 1; bool hascmats = false;
if(hasmats)
{
hascmats = true;
// get stone matgloss mapping // get stone matgloss mapping
if(!Mats->ReadInorganicMaterials()) if(Mats->ReadInorganicMaterials())
{ {
hasimats = 0; hasimats = true;
} }
if(!Mats->ReadCreatureTypes()) if(Mats->ReadCreatureTypes())
{ {
hascmats = 0; hascmats = true;
}
} }
/* /*
// get region geology // get region geology
@ -726,6 +739,8 @@ main(int argc, char *argv[])
DF->Suspend(); DF->Suspend();
// restart cleared modules // restart cleared modules
Maps->Start(); Maps->Start();
if(hasmats)
{
Mats->Start(); Mats->Start();
if(hasimats) if(hasimats)
{ {
@ -735,6 +750,7 @@ main(int argc, char *argv[])
{ {
Mats->ReadCreatureTypes(); Mats->ReadCreatureTypes();
} }
}
uint32_t effectnum; uint32_t effectnum;
/* /*
if(DF.InitReadEffects(effectnum)) if(DF.InitReadEffects(effectnum))