Archive for the ‘Software’ Category

Lessons from the British East India Company, or How To Import/Export

Importing information into Universe is actually pretty easy once you figure out how it works.

The first step involves registering an IEL file. If I had to guess, I would guess it stands for Import Export Language or something, but I actually have no idea. What I do know is that IEL files define the format of the data you are importing or exporting. There are a number of sample files, but you can create a custom one for whatever needs you might have. I needed to create one since the default files didn’t have the name field long enough.

So I created an IEL file that corresponded with the data layout of my preferred .sec file format, using one of the samples as a template and modifying it accordingly. The IEL contains a header section, a section to define the length of the line, a definition of each field with starting character position and field length, and then various lines to define data cleanup options and some parameters. For example:

; IEL created 16-Jun-2010 by Chris

Header="#Version: 2.6"
DetailLine="                                      -                                                           "
Field=system_name,1,25
Field=sector_hex,27,4
Field=starport_code,32,1
Field=size_code,33,1
...

Once I had my IEL, I had to use Traveller Universe Manager to register the file and associate an extension with it, so that when in Traveller Universe I could choose it as my import template. It took some trial and error to get the name right and realize to not include the “.” when entering the extension, and instead just using “sec”. I ended up going into the registry to remove the bad registrations and editing the successful ones so that the extension read as “sec” instead of “SEC” (a personal preference).

HKEY_CURRENT_USER\Software\VB and VBA Program Settings\Traveller Universe\IELs

I ended up with six different IELs so that I could import from or export to the most popular formats for .sec files, in order to maximize my use of external tools with the most minimal effort.

Generation Gap

A while back, I started messing around with a script called SectorMaker I found in a thread on the Citizens of the Imperium forum. The script generates a whole sector at random based on user parameters (and creates a .sec file), or it uses an exisiting .sec file and produces a PDF. It’s a pretty fantastic script to say the least. It was written in Perl and had instructions to install and run on a Mac. Since I didn’t have one, I modified the script and the instructions to run on Ubuntu.

One of the software components the script uses when generating a random sector is called GenSec, which it uses to do what the name implies, and outputs a full .sec file, minus names (the names are “Unnamed”) and stellar data. It has been around for ages

At the time, I knew GenSec could use an additional mode where you could feed it the locations and names of systems, and it would generate the UWP, Base, Codes, Zone, and PBG information for them. So I rewrote the tool in C++, and added options to do just that, and versioned it GenSec4.

GenSec4 was exactly what I needed to generate the missing data for my new sector. I took the original .sec file I exported from Universe with the hex locations and hex number system names that looks like this:

0118                      0118                                             Na
0119                      0119                                             Na
0133                      0133                                             Na
...

and removed all other info from the file and saved it to a file called Sol_names.txt:

0118                      0118
0119                      0119
0133                      0133
...

Then I ran GenSec4 on my Ubuntu VM and it gave me a file called Sol.sec:

0118                      0118 B9B6631-9   Fl Ni                       803 Rg
0119                      0119 B371567-9   Ni                          212 Rg
0133                      0133 C560785-7 S De Ri                       512 Rg
...

All I had to do then was paste in the names and stellar data using the vertical pasting ability of Notepad++ :

Tau1 Eridani              0118 B9B6631-9   Fl Ni                       803 Rg F6 V
Alpha Fornacis            0119 B371567-9   Ni                          212 Rg F8 IV
HR 3018                   0133 C560785-7 S De Ri                       512 Rg G0 V DA 1
...

With that done, all that was left to do was import the .sec file into Universe.

The Best Tool for The Job

I began looking for and reviewing mapping programs a while back, even before I decided to actually create a map for Beyond Frontiers. I’ve always loved maps, and I love playing around with mapping software. There are tons of programs out there to do mapping, but I was looking for hex mapping software, which narrowed the field a bit. There were a good many programs focused specifically on Traveller that took existing .sec files and created or displayed a map, and there were other programs that focused on graphical mapping without Traveller style data in mind.

So when I decided the pencil and paper method wasn’t very efficient, I had a good idea of what was out there for me to use. Since I wanted to follow the Traveller style as I said before, I thought it best to use a Traveller focused program. Out of all the programs I had found, I narrowed it down to the big 3: Galactic, Heaven & Earth, or Traveller Universe. My main requirement was a GUI to plot systems, label them, and have their details generated randomly. I also wanted a way to keep everything in a database, and allow notes.

Galactic is an old DOS based program, so that was out right off the bat. Heaven & Earth was last touched in 2001, and wouldn’t even run in my XP VM, so I abandoned that idea. Universe remained, so that is what I used. Great way to pick software, eh? Just picking whatever is left over isn’t always the best solution, but through forum post discussions with other users and the author specifically, I determined it would work for me.

Universe couldn’t quite do exactly what I wanted, but it did have a maintenance mode to allow me to add systems manually to a subsector. So using the images of each subsector that I had created in Photoshop, I plotted each subsector until the entire sector was complete.

Universe Maintenance Mode

None of the systems had UWPs or names at this point, so the next step was to add them.

Categories
Archives