Author Topic: Base Location Data ?  (Read 781 times)

Offline oneway

  • Silver Member
  • ****
  • Posts: 1385
Base Location Data ?
« on: September 14, 2009, 07:47:20 PM »
Edit: Found some of my answers on page 9 of the forum....

Does anyone have an OBA file they can link me to that has a fairly full set of objects and what not...

I want to look through that file and see what will be required to parse out the data...I have sent a request to Skuzzy to see if I can get the Rhine OBA...but in the mean time I would like to start coding my file reader...



I have never played with the TE...at all...

Does the TE have the ability to output the location and altitude of the bases and strat targets placed on the map as some sort of delimited file or text file?

In other words something like this:

A1,2,357,252,0800

Where this would be Airfield A1, country side 2, 357 pixels right, 252 pixels down, elevation 800 feet. Of course such an output would list all of the fields on the map.

I need the data for a mapping/planning program I am writing in C# NET. As it is now I have to manually enter the coordinates and altitude of each field in a base entry dialog before the GDI can paint the fields over the BMP...it sure would speed things up to have some sort of file I can read/parse and extract the needed data...

Oh...is there anyway to de-compile a terrain .res file back into a file that can be loaded into the TE?

Oneway
« Last Edit: September 14, 2009, 08:40:21 PM by oneway »

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Base Location Data ?
« Reply #1 on: September 14, 2009, 08:43:56 PM »
You want the .OBA file.....

Quote

F55VOD002,    mafld0,      5280.000,         0.000,    -21120.000, 0.0000, 0.0000, 0.0000,      3328,    0,    0,   -1.00,    -1.0,        -1,     2,    0,    0,    0,   -1

This is just a line from a test terrain for objects I have created but should give you an idea. It wont give you altitude as far as I know, only altitude above or below the terrain it sits on.

Edit:
X-axis coordinate
Y-axis coordinate
Z-axis coordinate over terrain, not AGL
Hardness
Point Value
Downtime
Rotation
Field Number
Zone number, starting from zero..

AH2 does not use the standard Cartesian coordinate system like you would normally think. In the Terrain Editor Y and Z are swapped, with Y being your altitude. I listed it this way because most software I have used uses the XYZ format with Z being altitude.

Oh...is there anyway to de-compile a terrain .res file back into a file that can be loaded into the TE?

No....


« Last Edit: September 14, 2009, 09:23:29 PM by Strip »

Offline Strip

  • Gold Member
  • *****
  • Posts: 3319
Re: Base Location Data ?
« Reply #2 on: September 14, 2009, 09:30:07 PM »
If its a SEA terrain you might have better luck with Dux, the Terrain Team Lead.

Offline Dux

  • Aces High CM Staff (Retired)
  • Platinum Member
  • ******
  • Posts: 7333
Re: Base Location Data ?
« Reply #3 on: September 15, 2009, 08:17:36 AM »
Heya oneway... sorry, but we're not going to give out source files for CM terrains. Maybe you can find another source.

You're asking for a way to output the OBA as a spreadsheet, I have an even better method for you... just open the OBA in Notepad or other text editor, or even directly into Excel. The OBA is already a text file so it's very easy to do, in fact, we actually do quite a bit of OBA editing in text mode, as it's much easier to find certain things. Just try not to have both the TE and the OBA text file open at the same time.
Rogue Squadron, CO
5th AF, FSO Squadron, Member

We all have a blind date with Destiny... and it looks like she's ordered the lobster.

Offline oneway

  • Silver Member
  • ****
  • Posts: 1385
Re: Base Location Data ?
« Reply #4 on: September 15, 2009, 06:44:13 PM »
Heya oneway... sorry, but we're not going to give out source files for CM terrains. Maybe you can find another source.

You're asking for a way to output the OBA as a spreadsheet, I have an even better method for you... just open the OBA in Notepad or other text editor, or even directly into Excel. The OBA is already a text file so it's very easy to do, in fact, we actually do quite a bit of OBA editing in text mode, as it's much easier to find certain things. Just try not to have both the TE and the OBA text file open at the same time.

Thanks...

The problem is the only oba data I am interested in is for current active in use SEA maps...I am not interested in offline maps created by other users, or some crude map I might possibly cobble together...

The application I am writing is for use in Scenarios. Currently to place a base on the map I have to manually enter the location of each field based on a guess as to the actual location; that location is obtained painstakingly by loading the AH terrain up in offline mode, zooming the map and basically jotting down as best I can the grid, keypad, sub keypad etc...then I parse that data into something my program can consume and store...

I am only looking/asking for the first 5 columns of the SEA oba data...either as a delimited text file or in excel...I have no intention of attempting to load up or edit the map...And in fact I am not interested in anything other than base and strat locations...the rest of the objects are irrelevant to me...

Seeing as you routinely edit in excel ... whats the chance I can get columns 0 through 4 of the Rhine oba data for: (city0, rdrfac0, aaafac0, fulfac0, amofac0, bacfac0 and lafld0, mafld0, safld0, port0, vfld0)....

I don't want the source code...just the data

Who do I have bribe?

Oneway