Beginners tutorial how to make a map aka terrain for Farming Simulator 17 (FS17). I wrote this tutorial knowing absolutely nothing about map making so this should help all the beginners / newbies, just like me. I do not claim this is a good tutorial or a proper way to make FS17 map, but it is what I googled and learned.
With the game came GAMEDIR/sdk/moddingHandbook/FarmingSimulatorModding_en.pdf manual for basic mod making, it is very good read when getting started.
Giants Editor is used to edit FS17 maps. You need to register into Giants Developer Network to get the latest giant editor. Download and install the latest editor.
You should have some basic windows open in it, these include; scenegraph, terrain editing, attributes, user attributes and console.
Giants Editor camera movement;
RMB + WASD keys
LMB-Middle Mouse Button pans
ALT-LMB rotates the view
ALT-RMB moves camera back and forth
F key focuses / moves camera on selected object
Keyboard short cuts:
CTRL-D duplicate selected object(s)
CTRL-B then LMB duplicate selected object(s) where the mouse cursor is at LMB press moment.
PDA Camera. Create new scenegraph item of camera (Create -> Camera), in attributes window transform name it to PDAcamera or something. Use translate Y: 4000 and rotate X: -90. Translate Y is your map size, so for 2km maps use 2000, for 4km maps use 4000 and for 8km maps use 8000.
Huge maps: you need to run a script to allow the editor to display large terrains properly, download: Giants_Editor_Scripts_2018-07-11.7z.
Modding Handbook says you can create map from scratch or edit existing map. Seems like editing existing is no brainer, but when creating brand new map from zero it is not that easy to bring it in-game (game crashes or loads forever etc).
You should't edit default game maps (goldcrest valley and sosnovka) obviously as it breaks your default game. You can export these into your own map, but even then you should make YOUR own map and not edit someone elses, be original, man.
Something called "SampleMap" is good place to start for your initial map files. When googling there are several samplemap packages floating around, all from different devs and tastes, no idea which one is proper. Welcome to FS17 modding community
Create directory called "MyMap" and do not use illegal characters anywhere on the file name or numbers as first character, if you do the map wont load in FS17. If you are creating your own map from scratch, create sub dir called "maps" so its "MyMap\maps\" directory structure.
Unpack SampleMap archive there so the directory structure is MyMap\maps\
Unpack GAMEDIR/sdk/sampleMod.zip into MyMap\ directory. THIS IS NOT NEEDED IF YOU USE SAMPLEMAP DOWNLOAD.
Go to MyMap\maps\ directory and open map01.i3d file with Giants editor.
Delete scenegraph -> HelpIcons and placeholders.
You do not need to ZIP the MyMap because if you just copy the directory into FS17 mods dir, the game will read it fine.
Open ModDesc.xml file, edit maps -> map id to your own unique map name, do not use illegal characters like space etc.
Please forget that 2X, 4X etc map size nonsense, use kilmeters x kilometers (in short just km) instead. Simple example; goldcrest valley is 2km, north west texas is 4km, broad acres and cornbelt are 8km. As of 2018-08-05 nobody has released 16km map.
0,0 coordinates is upper left corner, max coords are lower right corner.
Map size is defined in MyMap\maps\map01\map01_dem.png and the *_weight.png images, more specifically in their resolution and in map01.xml file.
map01_dem.png image resolution, in-game coordinates, kilometers x kilometers size:
255 x 255 pixels.
513 x 513 pixels, 1535 x 1535.
1025 x 1025 pixels, 2048 x 2048, 2km x 2km (default size, goldscrest valley, sosnovka)
2049 x 2049 pixels, 4096 x 4096, 4km x 4km
4097 x 4097 pixels, 8192 x 8192, 8km x 8km
8193 x 8193 pixels, 16384 x 16384, 16km x 16km
16385 x 16385 pixels, 32768 x 32768, 32km x 32km
When you change map sizes, you need to edit all the *_weight.png images and map01_dem.png image. Please note that *_weight.png images are normal 1024, 2048 etc resolutions while map01_dem.png is one pixel larger, like 1025, 2049 etc. However this post says about some layer image, but I cant see one heh. Also this post, this post, this post, this post, this post about large maps.
Change resolution for pda_map_H.dds image in MyMap\maps\ dir.
Change config of MyMap\maps\map01.xml file, on the line: ingameMap filename="maps/pda_map_H.png" so the width and height matches your new map size.
After you've increased the png and dds sizes, you must load the map01.i3d in Giants Editor and save it, not sure what it changes but this is required (otherwise FS17 hangs on load).
Terrain foliage paint mode, this is the last of the modes in main header icons.
Channels 0, 1, 2, and 3 define the type of terrain detail you're painting. These are exclusive channels, meaning that you should enable only one of them at a time.
Foliage channels for the terrainDetail layer:
0, Cultivated land
1, Ploughed land
2, Seeded/planted land
3, Seeded/planted potatoes
Channels 4 through 6 aren't exclusive; you can mix them with each other as well as any of the other channels.
Control channels for the terrainDetail Foliage Layer:
4, Sprayed/fertilized land
5, Rotate detail texture 45 degrees clockwise
6, Rotate detail texture 90 degrees
5+6, Rotate detail texture 45 degrees counter clockwise
LMB paints, RMB erases.
You must have a existing working field on your map project. Look for this on the various sample map mods.
Select fields transformgroup, use scripts -> FS17 -> Map -> toggle render field areas, in few seconds blue shape should appear where your fields are.
Click open fields transformgroup, click on the existing field which in our example is "field01", CTRL-D to duplicate (copy automatically).
Rename the field to the next available digit, if the duplicated one was 01 like in our example then make the new one 02 so "field02".
Move field02 to items into the location on the map where you want this new field. Then move field02 -> fieldDimensions -> corner01_* points to match the area where you want this new field.
Select fields, use scripts -> FS17 -> Map -> Set field sizes.
Now switch to terrain foliage paint mode, select foliage layer painting -> foliage layer -> terrainDetail and tick 0 channel. Now just paint the blue shape of your new field.
If you load existing savegame for your map after you added new fields, they do not show any crops or soil state. What I understand, you must start fresh savegame after adding fields or changing their sizes.
If you cannot plough fields, check terrain -> attributes -> translate Y, it must be 0. Also fields need to be defined, obviously.
or plant life, the first four channels (0 through 3) control the type of plant. The next row of channels (4 through 7) dictates that plant's growth state. In the third row of channels, only channel 8 has any effect. It defines whether the crop is in a windrow (a row of cut vegetation, ready to be baled or stored) or not.
Foliage channel settings for various crops:
3, Sugar beet
0 + 1, Rape (canola)
0 + 2, Maize (corn)
1 + 2, Dry grass
1 + 2 + 3, Potato
Fortunately, GIANTS Editor helps you out a bit here. When choosing the crop you want from the Foliage Layer drop-down menu, it automatically sets the bitmask for the first four foliage channels.
Create transformgroups fields, attributes add onCreate "script callback", then on its attribute add FieldDefinition.onCreate value.
Under fields add transformgroup field01. Add attributes fieldAngle integer, fieldArea float, fieldPriceScale integer, npcIndex integer.
If you add ownedByPlayer boolean, tick it and player owns the field.
Under field01 add fieldBuyTrigger, fieldDimensions and fieldMapIndicator transformgroups.
Under fieldBuyTrigger add triggerIconBuyField transformgroup. And there add iconLight light source (create -> light).
Under fieldDimensions add corner01_1 transformgroup. And there add corner01_2 and corner01_3 transformgroups.
corner01_1 is NW corner, 01_2 is NE corner and 01_3 is SE corner of the field. This gets more complex when you have oddly shaped fields.
Scenegraph field01 selected, CTRL-C copies, CTRL-V pastes and CTRL-X cut pastes.
Under fields add as many fields as you need numbered 01, 02, 03 etc.
Select fields in the scenegraph, then Scripts -> FS17 -> Map -> Toggle Render Field Areas and you will see a blue polygon appear in the shape of your field.
Select fields in the scenegraph, then Scripts -> FS17 -> Map -> Set Field Sizes.
How to enable / disable the mission function for a field? Select the specific field and add the attribute fieldJobUsageAllowed and select boolean. Then you can turn it on / off.
After editing the field/crops you need to get rid of the following files that are in the corresponding save folder:
After you tested the map and saved again, those files are regenerated, with the crops and growth states you've set in GE.
Good game-play tip: Always place fieldBuyTrigger away from the map / terrain edge, like if your field is right on the western edge, dont place this trigger into west side of the field, instead put it on east side. If the trigger is very close to map edge the icon will not be displayed in PDA. Its recommended that you place all field buy triggers to the edge of the field which is closest to the map / terrain center, this way you automatically avoid the edges. Also on 8km or 16km terrains (and maybe even 4km not sure) do not place buy triggers close to each other as its hard to mouse click on them in-game due the map zoom levels.
Get it from Giants Developer Network. You should know that Giants Editor will convert PNG to proper either GRLE or GDM when saving a map file.
Convert GRLE (or GDM heh) are cultivator_density and fruit_density. Convert them to PNG and delete the original files, then load your map01 with Giants Editor and just save it, that generates new GRLE/GDM cultivator_density and fruit_density files.
the default size of the map01_dem.png is 1k: 1025x1025.
So for a 4km map you need to scale that file to 2k: 2049x2049 and for a 8km map to 4k: 4097x4097
To enlarge the map further you could increase the "unitsPerPixel" attribute of the terrain (which has to be adjusted using a texteditor)
unitsPerPixel has value of two by default. Edit the map with a texteditor and set it to 3 or 4, save it and open the Map in the GIANTS Editor. The world will be larger
german language forum post about some 8km map shaders.
Howto setup your map with default starter money? Doesn't appear to be any value in XML files to edit. Looks like only method is to lua script the changed money.
Howto setup your map with farm grain silos, this is important as after you harvest your field, where do you store the grain? Easiest way is to export the goldcrest valley farmSiloSystem transformgroup, then import it to your map.
You can edit silo capacity from map01.i3d search for capacityPerType or edit normally from giants editor. Below is example setup for 10 million liters.
Attribute name="capacityPerType" type="integer" value="10000000"
To change the name of station (the tipTrigger) you have to change a UserAttribute of the trigger. Then locate the trigger/station you want to change. Find the actual trigger which has all the attributes, like "appearsOnPDA", "isAreaTrigger", "onCreate", "stationName" etc. Now you just need to change the value of the attribute "stationName" to what ever you like. The value for "stationName" is a string, which is either directly used or it is used to find an i18n entry. An i18n value can be defined in the modDesc of your mod.
Howto setup your map with animals, chickens, sheep, pigs and cows. Basically copy the animals transformgroup from one of the good sample maps (sorry no idea which one) or just simply from goldcrest valley. To have animals in your map is simple as making the navigation mesh, all the rest is feeding, dirt, manure etc eye candy, all you need is navigation mesh and animals appear.
Info layer painting channels:
NavMesh for animals is created by painting info layer with proper channel selected, then using create -> navigation mesh, you must select terrain desselation -> culling info layer channels properly. Do not just type the number here even if you know it, use the ... button to actually select it.
Creating navigation mesh (navmesh)
In dialog terrain editing -> info layer painting -> info channels. Channel numbers are 0 cow, 1 sheep, 2 chickens and 3 pigs.
Select info channel (only one at the time), then select from main menu terrain info layer paint mode. Now paint white color where you want this specific animal type to graze.
Go to animals transformgroup (you should have already imported these from some sample map and they should be fully working), our transformgroup is named "animals" and has "cowsHusbandry" transformgroup, select this. Click open gameplay transformgroup and there select CowNavMesh.
From main menu create -> navigation mesh, click shape build mask three dots (opens a new dialog), click clear button and tick 0 channel, then click ok. Now back in build navigation mesh dialog click terrain tesselation -> culling info layer channels three dots, click clear button and tick 0 channel, then click ok. Again back in build navigation mesh dialog click Recreate button and your 0 cow navmesh is done.
Repeat the same for 1, 2 and 3 channels as well to finish all the animal navmeshes
PDA map markers for animals are setup in maps/map01.xml file. Use some transformgroup to move into the location where specific animals are located, then write down the attributes translate X and Z coordinates into the XML file.
Save game editing, open vehicles.xml and edit Animals_cow, Animals_pig and Animals_sheep to quickly add hundreds of animals for debug purposes so you dont have to go through buy menu in-game.
Howto setup your map with grain / crop sell points, in order to make money you need to sell crops so where to sell them. Simply place unloadingStationFarm transformgroup, add unique name for gameplay -> IN -> triggerPos -> index, change xmlFile to point maps/ instead of $data/maps/, then write the index name into maps/map01.xml file as show below.
tipTrigger index="PMC_Grain_Elevator" stationName="PMC Sell Point 1"
Each map square can only have four base detail textures.
Never ever import an object outside of your own MyMap directory!
Open the other map where you want to get the object from. Choose the object, make sure you get all the transform group if there several things, then use file -> export selection with files, then browse to your own MyMap\maps\objects\ directory, create new directory which easily identified this object, then finally save the i3d file. It asks do you want to get the parent directory structure, you must answer NO to this.
Place the object directory into your MyMap\maps\objects\ directory. Use file -> import and choose the file name.
Use create -> spline to create, well a spline. Then you can move and rotate it usually. If you hit INSERT key, new point in the spline is created which again can be moved around.
Map with huge fields have issue with courseplay, it wont generate courses. I tried it to 1565 hectare field and it refused to generate no matter what kind of settings. When you generate course for 1000 hectare field it freezes up your game so ALT-TAB is not working, it takes several seconds to save on i7 4790k with SSD.
Huge fields take a long time (real gaming time, not depending on time accelleration) for the the crops to grow, it takes several days for wheat harvest to grow. [at least I think this is abnormal behavior, usually it takes pretty much overnight to grow crops heh dunno cant remember].
Courseplay generates routes for 1008 hectare fields. Note: it takes several seconds when it does this while it freezes the game, be patient and WAIT. Also do not, I say again, do NOT save such insanely large courseplay route because next time you start the map it takes several minutes to start if not ultimately locking up your game. Do not save huge courseplay courses, no matter the field sizes.
Also purchasing huge fields seem to freeze the game, this is reproduceable on PMC 16384 terrain with the 1475 hectare field number 30. However this might have been some bug in the field too
Goldcrest Valley GRLE and GDM image file resolutions:
cultivator_density.gdm 4096 x 4096
forestGrass_density.gdm cant open, huh?
forestGrassDark_density.gdm 4096 x 4096
fruit_density.gdm 4096 x 4096
infoLayer.grle 1024 x 1024
seasons_mask.gdm 2048 x 2048
terrainDetailHeight_density.gdm 4096 x 4096
tipColInfoLayer.grle 2048 x 2048
townDecoGrass_density.gdm 4096 x 4096
map01_preview.png resolution is 2048 x 1024 pda_map_H.png resolution is what your terrain is, 2048, 4096, 8192. Or is it... 2048 seemed to work fine on larger terrains(?) map01_preview.png and pda_map_H.png need to be flipped vertically otherwise they are upside down in-game.
Sun / star light is not enough to cover whole massive 16384 x 16384 terrain area, so you must increase the sun settings. Open your map in giants editor, click the sun and change range to 16384. All done. For PMC 32768 Terrain I made the range to 32768.
I took the maps/sky/ directory from some sample map and edited maps/map01_environment.xml to read >environment filename="maps/sky/ instead of "$data/sky/
Open sky_day_night.i3d file in giants editor, select sky transformgroup, then change scale x, y and z to 8. Do the same for skyUS_day_night.i3d file too. Now your skybox is enough for 8192 maps as well. For PMC 32768 Terrain I made the scale 16.
Fences kill game-play.
For those dark nights put enough lights to your farm and especially on the grain silo area where trucks are coming in with high speed.
Make fields small but leave large open area around it so players can enlargen them by ploughing if they want.
Make fields small but symmetrical so players can merge them if they want mega large fields.
Place large enough hangars / shelters to store huge fleet of implements and vehicles, you dont want to end up all road side grass areas littlered with parked vehicles.
Decoration tips; few grain silos, maybe seed / fertilizer silos as well and then one barn or hangar type building just like parkers prairie near the animals.
Near fields its good to have small open areas so you can park your vehicles there, like when you are not taking them back to the farm shelters.
Nick Welker said that in real life fields do NOT have a 90 degree square corners, watch his comments on youtube video. So its more work for you as terrain dev but if you want realism, add round(er) corners for your fields.