|
Krummen Hacker
InterPlanetary Airport How to integrate KIA with the planet of your choice. Krummen Hacker, a graph monkey of most extreme sort, has built some amazing things using MojoWorld's Pro UI. One of these things is an Airport, which I've christened the Krummen Hacker InterPlanetary Airport. In order for the airport to be truly interplanetary, however, it needs to be on a bunch of different planets! Krummen Hacker has made a .mjw file available that contains only the airport and it is into that file that you'll load your data. You can get the world file from the NightLanding page in the Pandromeda stills gallery or from the link below.
NOTE: Krummen Hacker found a bug in his airport, so if you got that file before March 10th, 2002, then you'll want to see the notes below about fixing the bug. While I made sure that the airport file linked above in the NightLanding image is the correct one, I also have a link here for the repaired airport .mjw file. (I'm so proud of myself, I found a bug in Krummen Hacker's repaired airport, and I fixed it! Yay!) Export From Your World Open the .mjw file onto which you want to put the airport. You won't actually be putting the airport onto your world, though, you'll be putting your world onto the airport. In 1.1, exporting the airport functions and re-importing them causes the duplication of shared nodes and that gets Ugly really fast! So, we'll do it the other way around. Export from your world all the elements which make it unique. This tutorial only covers the issue of the terrain texture and the planet material. Those are the only two elements which need to be integrated with the airport. You may also want to export your atmosphere, ocean material, moons and so forth. For this tutorial, I've put the airport onto my world Ishkarinda. Click the 't' hot button below the mountain icon in the Global Parameters hot buttons. Choose 'Save to Library' from the menu. I saved my terrain texture to the file IshkarindaTerrain.mjl. Close the texture editor. Click the 'm' hot button below the mountain icon to open the planet material editor. Choose 'Save to Library' from the menu. I saved my planet material to IshkarindaPlanetMat.mjl. Skip down to 'Load Into the Airport World File' if you've done all your exporting. If your terrain texture is a function - that is, if clicking on the 't' hot button below the mountain icon in Global Parameters opens the Pro UI graph editor instead of a 'normal' Generator UI texture editor - you'll need to convert it to a texture before you can export it. This will also make loading the terrain height easier. Open the Terrain Editor dialog (click on the mountain icon hot button). The mountain Height parameter will show an 'f' indicating it is a function. Change it to Texture. A new texture editor will open, showing a single-leaved texture where the first leaf is a function graph. Open that function graph and select the node that is immediatly above the brown root node. It doesn't matter what kind of node this is; give it an easily recognizable name so that you'll be able to find it in the node list later. Below, I'll refer to this node as ISHKARINDA. Close the function graph editor. Choose 'Save to Library' in the texture editor. You're now ready to continue. Load Into the Airport World File Open the Raw_Airport_co.mjw file. Pause the RTR as this gets pretty hairy. Terrain Texture Open the Terrain Texture editor. Note that the name of the texture is 'Main Planet Height' and that it consists of three texture leaves, all of which are function graphs. Choose 'Load from Library' off the menu and select your terrain texture. If your terrain is a 'normal texture,' close this texture editor. Open the 'Terrain Editor' (the mountain icon above the terrain texture editor icon). Note that the Mountain Height parameter is a 't' for texture. Change it from a texture to a function. In the function editor that opens, choose Auto-Layout. Select the node immediately above the root brown node. It doesn't matter what this node is, you just want to mark it with a unique name so you can find it in the node list in a few steps. I named mine ISHKARINDA. I like to use all upper-case letters so it's easy to spot in a node list of mostly lower-case-named nodes. Close the function graph editor. Back in the Terrain Editor, change the Mountain Height parameter back to a texture. This will open a texture editor where the texture is named the same as the name that you gave to that node in the graph. The texture has one leaf and it is a function graph. There's a small problem, though, and that is there are now two nodes with the same 'unique' name and we need to be able to tell the two apart. Change the name at the top of this texture editor to something else - I added a capital X to the end, ISHKARINDA X. If your terrain was a function graph and was exported as per the instructions above, simply load it from the library and continue from here -- In the ddlb in the upper left corner of the texture editor, select the original 'Main Planet Height' texture. Open the graph editor on the top-most texture leaf. This graph consists of two nodes, the brown root node, named 'Blend Low ...' and one named 'Default Planet Surface'. Create an Add node. The reason for this will become apparent later. Connect the output of the Add node to the second parameter of the 'Default Planet Surface' node. Choose 'Import Node From Other Graph' off the menu. In the alphabetical node list that comes up, select the name corresponding to the name you specified in your terrain texture graph, in my case, that's ISHKARINDA. When the node tree appears, drag the output of the bottom-most node (the one you named) to the first input of the Add node. Close the graph editor, close the terrain texture editor, close the terrain editor and unpause the RTR. OK! You should see the airport integrated with your terrain! (Well, alright, you'll need to move the time dials, 'cuz it's dark, and you'll need to move the camera, 'cuz it's too close to the airport to see the rest of the terrain...) Now is a good time to SAVE YOUR FILE. Lining Up The Terrain and Airport Depending on your terrain function, you may see any one of the following scenarios:
Of course, after this was all written, I thought to myself, "ya know, I'll bet there's an airport altitude adjustment in one of those graphs." And sure enough, in my email the next morning, Krummen Hacker had pointed out that there is in fact an airport altitude adjustment. It's named "- Airport Base Altitude" and it can be found in the second function graph leaf of the Main Planet Height texture, two nodes up and on the left above the brown root 'Add1' node. It's very easy to find! So, you can either adjust your terrain to line up with the airport, or adjust the airport to line up with your terrain, or do a little of both to make things "just so." Don't forget to Save again after you get that tweaked. Terrain Material To get your world's original material integrated with the airport, the first thing to do is to create a sphere. This temporary sphere will be used as a place to load in your planet material. Open the material editor for the sphere. Choose 'Load from Library' off the menu. Load in your planet's material, in my case, that's IshkarindaPlanetMat.mjl. Now is a good time to pause the RTR again. Bring the Global Parameters buttons back and click the 'm' for the planet material. Select the second material leaf, 'Airport Material Tree.' In the control stack on the right, click the arrow to the left of the name 'Airport Material.' This will open another material editor containing a four-leaved material. The second leaf in that material is called 'Airport Grass Material.' Select that leaf. Notice that it is a simple displacement material. Use the controller below the leaf to change it from 'Displacement Material' to 'Nested Material Tree.' The name of the leaf will change to 'Nested Material Tree' and the control stack on the right will show 'None' in the ddlb. Open that ddlb and choose your original planet material. It should be the first one on the list, as the materials are listed by what order they were created. If you'd like, change the name of that material leaf for good housekeeping purposes. Also for good housekeeping, select that temporary sphere and delete it. Unpause the RTR and admire your new airport! Don't forget to SAVE YOUR FILE again. Moving The Airport The Raw_Airport_co.mjw file has the airport positioned near the equator at around 90 degrees West longitude. But what if you wanted to have the airport somewhere else on your planet? A feature request that may be available as soon as 1.2 is editable latitude/longitude fields in the helper object editor, which would mean you'd select the helper associated with the airport and type in new values and the airport would go flying across the face of the planet to the new location. Simple! But that's not there yet, so it has to be done The Hard Way. As it turns out, Krummen Hacker is a very careful genius and The Hard Way is much easier than I thought it was going to be. First, name the camera near the airport something like "original airport camera." Then, create a new camera named something like "new airport camera." Move the new airport camera near where you want to put the airport. (As it turns out, there's a bunch of cameras in the Raw_Airport_co.mjw file, so you may want to resort to the all-upper-case trick.) Create a new square helper object. Open the editor for that helper and give it a name something like "new airport location." Set the X and Y size to 20000. (I'm not sure if that's required, but it seems safest!) Now for the fun part - dive into one of the airport function graphs. It doesn't matter which one (thank you, Krummen Hacker!). (Hmm, OK, not _all_ of the function graphs have an "Airport Helper Position" node.. but many of them do.) I chose the one attached to the middle function graph leaf of the 'Main Planet Height' texture. In the function graph editor, DO NOT choose 'Auto layout'. Instead, click in the graph editor window then type the , (comma) key a few times until the nodes shrink down. As soon as their labels disappear, type the . (period) key to expand them up once to bring the labels back. You'll want to maximize the graph editor window. Hold down the space bar and drag on any node. This will move the entire graph at once. Move the graph down and to the right. The node we're after is in the upper left region of the graph and it's named, "Airport Helper Position." Select this node. In the control stack on the right, there will be a ddlb showing the name "- Airport Helper". Open this ddlb and select your "new airport location" and then wait. It may take quite some time before the wait cursor goes away. I didn't time it on my machine, but it was somewhere around half an hour. It takes so long because it has to update not just the result of this graph, but also of many, many other graphs which are driven with the helper position, not just in the terrain texture, but also in the many nested materials which make up the coloring of the airport. After the airport moves, you may need to re-adjust the airport and/or terrain altitude to line the airport up with the terrain in its new location. One last Save, and you're done! Final Notes - Rendering The Airport This airport has some really cool features. One of those is that it has lights. The lights are ON in the Raw_Airport_co.mjw file, so it may not matter at all, unless you're annoyed by the lights being on in the daytime. Here's how to turn the lights OFF and ON:
Also note, that just like a real airport, the lights at the end of the runway, when viewed from an approaching angle, will be green and yellow -- but, if the camera / plane is on the runway, those same lights will be red! Krummen Hacker says he got that idea from an animation made by Eric DeGiuli in which the terrain shape was changed in relation to the camera's location. Did I mention that Krummen Hacker is an insane genius?! [When Krummen Hacker saw that comment, he said, "I feel that one the two words is more appropriate than the other. But I cannot decide if it is "genius" or "insane". :-)"] So then I thought that I should say, "insane, genius, demigod -- pick two!" |
Here are the instructions for repairing an Airport that was from the old file:
|