PnP TerrainCreator - Forum

Raw input plugin
Page 2 of 2

Author:  GameWizard [ Sat Dec 30, 2006 3:33 am ]
Post subject: 

Ralf wrote:
I can confirm this beeing a bug in the main program's sector management. Should be no problem to fix it.

Did these problems get fixed?

Author:  Ralf [ Thu Jan 04, 2007 12:17 pm ]
Post subject: 

It is fixed, and the next beta is almost ready. Just have to test a few things. I'll upload it within the next 3 days.

Author:  Ralf [ Sat Jan 06, 2007 1:32 am ]
Post subject: 

OK, just uploaded a new beta, which should fix this problem.
You have to download the new SDK too in order to compile your PlugIn.

Author:  GameWizard [ Sun Jan 07, 2007 6:37 am ]
Post subject: 

I'm really busy right now, but will attempt to check it out soon.

Author:  GameWizard [ Wed Feb 07, 2007 12:25 am ]
Post subject: 

Should this sequence now work in the raw input plugin

1. close any open sectors:

Sector.Save(); // but first save the currently open sector.

// and any adjacent sectors.

CIPnPTCSector01* neighbor_sector_p = Sector.GetNeighbourSector(NB_TOPLEFT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_TOP);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_TOPRIGHT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_RIGHT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_BOTTOMRIGHT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_BOTTOM);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_BOTTOMLEFT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}
neighbor_sector_p = Sector.GetNeighbourSector(NB_LEFT);
if(neighbor_sector_p) {neighbor_sector_p->Save();}

2. Iterate over all sectors: opening, setting the heightmap, and saving the sectors?

CIPnPTCSectorDefinition01* sector_def = Terrain.GetSectorDefinition(sector_x, sector_y);

CIPnPTCSector01* sector_det = sector_def->GetSectorDetail();

sector_det->SetHeight(x_pos, y_pos,raw_height*fFactor+fOffset);

ret = sector_det->Save();

Another question is: Does GetSectorDetail() open adjacent sectors?


Author:  Ralf [ Wed Feb 07, 2007 9:49 am ]
Post subject: 

1. Yes, that would be the right way of doing it.
2. GetSectorDetail only openes the sector on which it was invoked. Call OpenSurroundingSectors on that sector object to open its surrounding sectors.

3. Don't experiment with whole terrain import any longer :) Just download the current beta of the program and the SDK.

Author:  GameWizard [ Wed Feb 07, 2007 6:07 pm ]
Post subject: 

Thanks for the answers.

I assume your answer 3 means the whole terrain import is in the beta.

Author:  Ralf [ Wed Feb 07, 2007 6:54 pm ]
Post subject: 

right ;)

Page 2 of 2 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group