Authors & Administrative NotesEdit

This Tutorial was originally posted by Taskforce 58 on YS Pilots many years ago. Since then it was re-posted on YSFlight Headquarters and comments have been added by vandal. These comments are included below in parentheses and seperated for formatting.

The Tutorial was added to the YSFWiki on 5 August, 2013.

Starting to Use YSFlight Scenery EditorEdit

Some basics for the scenery editor: Holding down shift and both left and right mouse button, and slide the mouse up and down: zoom in and out shift and left mouse button: move the view around.

Now, start the editor. We are going to create a very simple scenery, with a large island and one runway, that's all.

Goto map->insert element. Select POLYGON on the drop down list. On the color palette (top right of window) select dark green. See the green box with the green lines on the screen? That's your plotting cursor. Drag it around, and hit enter. This will create the first point of the polygon. Drag the cursor around again, and hit enter again. Each time you hit enter you create the next point for the polygon. Once you have 5 or 6 points for your polygon, hit space. Now you have your island. Notice that you don't have to plot the last point of your polygon on the same location as the first one. Once you hit space the editor will close the polygon for you. Oh and the first time you create something in the editor, it will ask you if you want to create a new map. Just say yes.

(This is the common way of doing things in the editor. The Enter key to plot the points, and Space to
 finalize any changes/additions)

Next, the runway. We will create a east-west runway (i.e. Runway 09/27) with a rectangle. Creating a rectangle is a little different than a polygon. You have to specify 3 points. The first two defines the baseline of the rectangle. The third is the width.

(What will happen is that the rectangle will be aligned with one of the edges 
on the baseline you defined, then the editor will create the smallest rectangle
that includes the baseline and the third point you specified. The third point 
does not necessarily mean it is one of the corners of the rectangle, just that 
it will lie on the side opposite of the baseline.)

Zoom in until the blue grid just about covers the whole screen. Use map->insert element, and select RECTANGLE this time. On the color palette select dark grey. Drag the cursor around until it lines on the left edge of the blue grid. Take a look at the coordinate window. The first value (from the top) is the East-West coordinate, the second is the altitude (normally 0), the third is North-South. Now hit enter to create the first point, but don't drag the cursor around afterwards. 

Take a note of the coordinates of the cursor. Since we want a runway that is 3200m long, add 3200 the the East-West coordinate (i.e. click in the box and type in the actual value), and click SET. This will move the cursor exactly 3200m due east of the first location. Now follows one of the little quirks of the editor. Since we clicked in the coordinate window to enter the value, you have to click on the main editor window again. However, we don't want to accidentally move the cursor around, so click on the window title bar of the main editor window to select it. Hit enter, and you have entered the second point of the rectangle. 

(This is a more precise way of entering thing, when you need to draw something with a specific 
dimension, such as runways. By The Way 100 ft = 30.48m)

Once again look at the coordinate window, and this time add 42 to the North-South coordinate. Click set, select the main editor window, and hit enter. This will add the third point of the rectangle 42 meters due south of the first two. Hit space, and you should have a long thin rectangle in dark grey. This is your runway.

(HotelFox asked abour a runway of 3200x45m, hence the dimensions I used here.)

The third step of our simple scenery is to define the runway area. The method is almost identical to entering a rectangle. Select Edit->Insert->Rectangular Region. On the drop down list select 1 for runway. Now you need to enter a rectangle that is (roughly) identical in size and location as the grey rectangle we created to be the runway. You can use the precise coordinate method as we used for the runway, or you can just eyeball it. Once you are done you should have a blue rectangle surrounding where the runway is, with the tag "RGN ID=1 (Runway)" in the middle.

(The rectangle region is a very important element of YSFlight Scenery Editor. 
It is what defines a runway, taxiway, and viewpoints. Infact in our example you
don't even have to dway that grey rectangle for the runway. You can just put a
rectangle region down and set it as a runway and it will work. Of course a
10000ft grass strip in the middle of a lush green island 10 km wide is gonna 
make it very hard to find and land on!)

Go to File->Save FLD to save the scenery. Name it "myairport.fld" for our example here. Make sure you are saving it into YSFlight's scenery folder.

Last thing is to create a start position. Goto StartPosition->Insert. Drag the cursor to the western end of the runway, and hit space. You will be presented with a popup window. On the ID Name box, enter "RWY_09". Initial Speed should be 0. Landing Gear box should be checked. Throttle is 0 percent. Click OK. You have created a start position, but it is pointing north. Now select StartPosition->Rotate. The start position we just entered is now circled, with a thicker green arc beneath it. Drag the green arc around and you can rotate the start position. Keep draging the green arc until the long green dash line (the heading) is pointing towards the right (east) down the length of the runway, and hit space to confirm the change. Goto File->Save STP to save the startposition. Name it "myairport.stp"

(When you enter a start position that is on the ground double check the 
coordinate window, make sure the altitude (second box) is 0. It you want an 
inflight start position, then you can set the altitude to something other than
0, but make sure that you have a reasonable initial speed, making the throttle
setting something other than 0 percent, and uncheck the landing gear box.)

Now we have the actual scenery and the start position(s) done, we just have to let YSFlight know about it. In YSFlight's Scenery folder, use a text editor (such as notepad) to open the scenery.lst file. Add this line to the end:

MY_AIRPORT scenery/myairport.fld scenery/myairport.stp

and save the file.

Next time you start YSFlight, you should have a new scenery called MY_AIRPORT with only one start position, RWY_09.

Elevation GridsEdit

Before we start, you need to know how to change the direction of the view point. By holding shift and right mouse button down and moving the mouse around, you can change the view direction. If you want to go back to the top-down view, just click on "Top View" on the view control panel.

(You can also use the view control panel to move, zoom, etc, but I think the
mouse is easier.) 

NOTE: New test versions do not include the view control panel. Use F1 thru F6
for different views i.e. top, bottom, left, right, front, back.

The elevation grid works like this: you define a rectangular area, which is sub-divided into a number of segments, like a gird on a spreadsheet program. At the corner of each grid square is a "node". By moving these nodes up and down to a different elevation than the ground, you create a three dimensional surface which (hopefully) is shaped like a mountain. If you still don't understand, imagine a piece of plywood, with nails of different lengths nailed on it in a grid like pattern. You then lay a sheet of cloth on top of this grid of nails. The effect is similar to our elevation grid.

OK, enough theories. Start the scenery editor and load up the map of your choice. You might want to zoom in a bit until the blue grid is a bit less then a quarter of the size of the screen. Goto Edit->Insert->Elevation Grid. You will be presented with the familiar green cursor. You now need to enter the base rectangle of the elevation grid, same way as you entered a rectangle before. However, before you hit space to finalize, take a look at the sub-window on the left. 

This defines how dense will the grid be sub-divided. When you change the numbers you should see the grid change on the screen also. Technically you can enter a 1x1 grid but this will be just a simple rectangle with a node on each of the four corners, and is not very useful. For our purpose, just put in a 5 x 5 grid. Click on Insert Elv Grid to lay down your grid. Once you are done use Edit->Clear Interface to clear away the Elv Grid dialog.

Now with our grid, you can try clicking on various nodes on the grid to highlight them (in light blue). You can also highlight entire polygons between notes, but that's not what we need right now. Press "U" to unselect all notes and polygons, then select just one single node near the center (anyone will do). Then select ElevationGrid->Move Node. 

Remember how to rotate the view around? (The top of this message.) Do that now, rotate you view around a bit so that you are looking at the Elev Grid at an angle instead of straight down. Notice that you can drag the node that you just selected and slide it up and down. At the same time the second value on the Coordinate window (the Y-value i.e. height) will also change as you drag the node up and down. Drag the node up until it is about 600 meters (roughly 2000') above ground. Hit space to finalize, and you will see the area surrounding the node poking up from the ground. This node that we just raised will be the summit of our mountain, but right now the whole thing is not looking very mountainy yet.

(Remember that move node moves ALL the nodes that are selected. If you are doing a mountain with
 multiple peaks at different altitudes, make sure you only select the ones you really want to move.)

Make sure our summit node, and only that node, is still selected. Then select ElevationGrid->Laplacian Smoothing (or you can press "L" to do it). What this does, is that the editor will raise all the nodes in the current Elev Grid EXCEPT ANY NODES THAT ARE SELECTED so that the whole grid will look more smooth, less angular. Since only our summit node is selected, this has the effect of smoothing out the whole grid so that it looks like a mountain rasing from the edge of the grid to our summit. Note that I said "the edge of the grid", which is rectangular. Keep this little bit of info in your head.

The next thing you should know about elevation grid functions, and also the next thing we need to do here, is to select ElevationGrid->Apply Delaunay Triangulation. What this does is that it will rearrange all the triangular polygons that make up the entire grid so that, instead of cutting across the grid diagonally in the same direction (as it was when the grid was first laid down), they now go around like contours around a hill. By itself it does little to modify the look of the mountain, however it makes modifying the mountain a lot more easier (and logical).

Remember what I said about our mountain is rasing from the rectangular edge of the grid right now? Can you find any mountain on a real-life contour map that has a rectangular base? Not many, eh? So we need to flatten out the area around the mountain a little bit so that the mountain base looks more natural. First, click on Top View on the viewing control window so we can look straight down on the Elev Gird again. Select all the triangles surrounding the mountain so that THE UNSELECTEDportion of the grid (i.e. our mountain) looks roughly oval in shape. Now use ElevationGrid->Flatten Selected Face. Now our mountain should look more like it is raising from a more natual looking base.

(You can even select all the nodes along the base of the mountain, plus the summit node(s) and do 
another laplacian smoothing to smooth it out again.)

One final thing to our mountain. It is blue! So unless you are recreating the Blue Mountains let's fix that. Select ElevationGrid->Apply Color Gradation. You will be presented with a window which let you pick the peak and foot colors. What it will do is to apply the foot color at the lowest elevation of the grid, and gradually change to the peak color near the top. Usually you want the foot color to be the same as whatever the ground color is, so that the foot of the elevation grid will blend into the ground. Let's leave the peak color as is, and (if needed) just change the foot color to match your ground. Click OK, and your mountain is done!

So, to recap what tools we have used: i) Same method for laying down a rectangle to lay down the elevation grid. ii) Highlight notes and use Move Node to raise them, press U to unselect all nodes. iii) Laplacian Smoothing to smooth out the mountain. iv) Delaunay Triangulation to rearrange polygons along contour lines. v) Select faces to flatten them vi) Color Gradation to color the mountain.

FAQ SectionEdit

[ricm96]Q: Could somebody provide some insight into how you would go about making a simple building using the elevation grid ? I see that others have done this to make cities, and it works well. Whenever I try, the sides of the building end up sloped, like the software is trying to make a mountain instead of a building. [TF58]A: A simple rectangular building, you just create a 1x1 elevation grid. Raise all 4 nodes to the same height, use the show/hide sidewall function in the ElevationGrid menu to paint the sidewalls. 

A house type building with slope roof is a 2x1 elevation grid.

[ricm96]Q: Is it possible to create an elevation grid and then paint only certain faces ? I am not referring to the sides of a house built using an elevation grid.

What I want to do is create a hill with a plot of crops that are a different color than the rest of the hill. When I tried it the whole hill got painted a new color.

[ysmajor]A: Possible with Notepad I believe, but the tricky part is to figure out which lines in the Notepad file are which faces to paint. Might mean a lengthy process of trial and error.

Another option is to put two identical grids on top of each other. Then elevate some nodes and faces slightly higher than the lower grid, and hide any other faces. Paint all of them and it'll show up fine (this is how to make snow capped mountains as well).


1) I want to create an elevation grid, then have various copies of the SAME grid in a map.

2) I suspect I need to save an elevation grid (in what file format ? details ?), and then reload it.

3) I also want to be able to rotate and move around and reshape each different copy as needed.

So far I am unable to get very far with this. I can make the grid, I save it. I then can load it, but I have trouble just moving it around, much less modifying it.

[TF58]A: Duplicating elevation grids:

1) Create your elevation grid as normal. 2) While the grid is selected (it has a thick light blue bounding box), goto File->Export->Current item. It will ask to save the currently selected item (i.e. your grid) as a .ter file.  3) Now we can re-insert the grid. Goto File->Import->Elevation Grid. You will be presented with the familiar green line cursor. 4) Move the cursor to the position where you want the top left corner of your new grid to be (the top left corner is the first corner you plotted when you create the grid), press space, and you will be asked to select the .ter file that you want to import.  5) Once you imported your grid you can use Edit->Rotate->Current Item or Edit->Move->Current Item to move it.

[Flake]Q: Hi guys I'm having a probably easy to fix issue i can't get my head around.'Whenever i create a polygon, YSFlight renders it oddly, like so:


this isn't too much of a problem with small polys, just big ones. Is there something I'm doing wrong?

Maps like Hawaii and etc. can have very large polys but not have this "fog" that goes with it. If i fly on hawaii or etc, I don't get shading problems.

[TF58]A: That will always be a problem with large (measured in multiple miles) polys. Just cut it up into multiple smaller ones.