Posts by Nabeel

    The issue is that cultivation only supports rectangular buildings, so you can't really make circular structures (this requires custom 3d scenery objects modelled). While you could place lots of rectangular buildings in the shape of a circle it wouldn't look good due to overlapping buildings flashing and different randomized textures.

    Any complex building in any DLC that doesn't look like the standard cultivation is a custom modelled building, it's not something this editor is capable of supporting (pretty much impossible as 3d models are encrypted so we can't read them outside the game).

    I've added a few changes in, didn't get the multi plant stuff or the cursor (the cursor is almost impossible with the mapping library as it sticks with the hand grab unfortunately).

    Anyhow, the changes are:

    • Selection will have a blue-ish color now to make it more obvious
    • Selection can be dragged around (you can end dragging by double clicking on the drag box, or hit ESC to cancel your drag movement to its original position)
    • Selection can be duplicated by hitting CTRL+V, this will then swap the dragging to the newly pasted objects (you can hit Backspace or right click delete to delete them if they were unintentional)
    • All of the above options are available via the right click menu when you have a selection
    • Some minor fixes to selection handler not respecting the proper coordinates on the map on certain angles.
    • Plant and Light icons have been made a bit smaller so it's easier to see where they are.
    • Option for a custom boundary box via the toolbar on the left, this will be a blue-ish, faded rectangle to indicate your custom boundary box. The format you enter this in is NW Lng, NW Lat, SE Lng, SE Lat (comma separated, spaces are truncated automatically so no need to worry).
    • Hotkeys for buildings and plants, ALT or SHIFT means holding either ALT or SHIFT as well with the number (a notification will tell your selection)
      • 1 - Broadleaf - ALT residential/gable - SHIFT residential/flat
      • 2 - Shrub - ALT commercial/gable - SHIFT commercial/flat
      • 3 - Conifer - ALT industrial/gable - SHIFT residential/flat
      • 4 - Palm
    • Multiple TOC loading, it will put you right in the middle of your loaded objects. The save will only output one file as it's not possible to know what's supposed to be separate without some logic.

    I may have forgotten something but I think that's it for now. Let me know if something breaks as I don't really have any unit testing (and unlikely to have any in the future)

    Defined by user or calculated from all current objects?

    I think hotkeys would probably be the fastest to do that, need to think a bit on which ones (as we don't want to cycle through them all either).

    Another suggestion to improve: Instead of the hand symbol as a cursor it would be better to have a pointer or a cross so we know where exactly we position the houses and trees.

    Also the symbols for the vegetation should have a pixel marked where the exact position of the tree is.

    If you try to move a plant or light, it should give you a proper texture to indicate where it lands. I agree though, the hand symbol might not be very easy to work with. I'll see what I can do about it, for now if you place it and then right click > edit it will allow you to do specific placements (due to the cross hair icon)

    I like the tool, one thing I would have to write, if you didn't. :)

    One add: I would like to load more than one toc file without deleting the old one from the first load.

    Also a nice feature like the one from scenproc: Define an area and fill it with random trees.

    I'm intending to do some new additions (and some changes) this Friday/Saturday or so, I'll include the option to load multiple TOC files at once (though that does mean that when you save it'll be one file only). Another much requested thing is creating multiple plants at once and a way to copy/paste/duplicate existing objects.

    I just noticed About Plant Cultivation thread, it appears you have to modify the "species" property to achieve the different trees (which is possible right now in the editor!)

    I've uploaded a small video to show how to change properties for existing objects and objects that you draw.

    I'll mess around with it a bit, trial and error. I'm only interested in adding lights to a few helipads and rooftops in NYC (for now). Nothing major.

    I appreciate your work, Thanks.

    I think that might be something that won't work right now, mainly because the lights assume a predefined altitude (from the ground I believe), though it is something you can fix. Once you add the lights, open the .toc file and edit the very last number under the light position that says 6.000000 to the height you want (I believe it's in meters). You should be able to do a search and replace on all instances assuming the light cultivation toc file for the helipad is separate from other cultivation lights that aren't related.

    I'll do something for the height in the next round of changes so you can configure the altitude on it.

    OK, but I have no experience with editing in AFS2, so I'm confused as to how I would add lights to them if they aren't visible.

    Any tips on where and how to begin adding lights (in the blind, without reference to the object)?


    I assume you know the approximate location of the helipad, if you go over there in the editor and add lights on the x and y axis, space them out a bit and make a lot of them in the form of a plus sign. Test it in game and see which light is approximately right, then edit it in the editor again from that light. It'll be a bit of trial and error. You can change time in game with T and Shift+T I believe if you want to see the lights illuminate (as they don't show during the day).

    Alternatively, you could take a top-down photo of the helipad in-game and estimate the approximate location of lights on the editor using that as reference and messing around.

    However, I might be confused with what you're trying to achieve exactly, did you want to add lights to all helipads? there's no way to automate that and you have to do it manually per helipad. If you want to add lights to helipads from IPACS and other DLC sceneries then that might be difficult as you would need a separate 'dummy' scenery/airport to overlay your cultivation file with lights only (something which isn't recommended generally, though it should be harmless for lights only).


    I should also add that there's a camera mode in AFS2 that will make testing this much easier if you didn't know about it. You will need to close and re-open your game after updating the .toc file (which is actually what made me develop the editor in the first place, but helipads aren't supported yet as that goes under scenery/airport rather than cultivation).

    Nothing seems to happen when I click on the SAVE icon. I reloaded and the SAVE function works as expected.


    I managed to pinpoint the bug and have fixed it, it was when you drew a building but double clicked (which created a building as a single vertex, something that shouldn't have been possible)

    If there's a way for that to be done through the SDK or such then that might be an option, but I guess they're supposed to private and only read in-memory during the game.

    Thanks - that should be fine, you won't see the helipad though (unless it's a ground texture on a satellite/aerial photo) but adding lights shouldn't be an issue.

    Nothing seems to happen when I click on the SAVE icon. I reloaded and the SAVE function works as expected.


    Odd, let me know if that happens again. I can't reproduce this on any browser right now at least.

    Do you plan on supporting additional browsers.? I do not use Chrome, I use Microsoft Edge, the default browser for Win10. Absolutely nothing shows up at the url when using Edge.



    I've updated it, the issue is that Edge doesn't support the new proposals for Javascript yet (which the other browsers do), so it required a polyfill to work.

    I've made a few additions/changes:

    • You can move both plants and lights (the marker changes to an X just to make it more clearer where it will "land"), you can end editing/moving by double clicking on it.
    • Visible layers have been introduced, you can toggle them on or off on the top right.
    • Deleting will not count against layers that are not visible (drawing still counts).
    • Draw mode will persist until you hit cancel, so you can spam multiple plants, lights, buildings.
    • A message is shown to notify if you're in draw or edit mode (hard to miss!).

    One thing I still need to do is the ability to create mass plants in a given area.

    Would it be possible to use 'Ctrl + right mouse' to select objects and then delete all selected with e.g. backspace. I would like to remove lights as there are too many. Outside of inhabited areas there are usually no lights. However ScenProc adds lights according the street classification.

    Not sure if I understood correctly, but selecting manual objects one by one rather than a huge selection? I plan on adding a visibility layer where you can toggle on and off models (such as buildings, plants and lights), which will ensure that objects selected are only applicable to the visible layer(s).

    Is it possible to create a function that can move a tree - instead of deleting and creating a new one?

    Is it possible to create a function that can create a forest: Choose an area, and a forest is automatically created within the area?

    The first one should be fairly simple. As far as the area selection goes, that could be a bit more difficult UI wise so I'll have a thought on how to do that nicely (as I need to think about creating a single plant vs multiple, plants respecting the area boundaries, the spread/size of plants, etc).

    Really a great tool, congratulations. Good to see such talented people on board.

    It reminds me of the autogen annotator for fs9/fsx. I would love to see mass selection/deletion option and a copy paste option.

    I've gone and added a mass selection option to delete for now, I'm not sure about copy and paste yet as that will need thinking on UI/UX side of things. It might easier having an option to create multiple plants (something like a spread/amount slider) so you can cluster them quickly in a location.

    As for mass selection, hold down CTRL and select your area, then hit backspace to remove. There's no undo right now so be careful!

    I'll see what I can do about the zooming thing, I can do a potential fix at least via a zoom slider. As far as compiled .TOCs go, I don't think I'm able to read or decode them, only plaintext. I assume they're compressed and encrypted versions.

    The technology to render everything is WebGL (using which is somewhat new and may have problems on some machines.

    I've added a band-aid fix for zooming in Firefox, you can now use D and F to zoom out and in respectively as well as use the zoom slider (if it doesn't appear you may need to do a hard refresh using CTRL+F5).

    I plan on putting the code on Github sometime next week, just need to get some refactoring done first. This will be something people can run off their machines (rather than needing a website), that will also help with any potential legalities of using Google tile sources.

    I've been working on a small side project this week as I've had some spare time and my goal was to create a scenery/cultivation editor for AFS2 with emphasis on easy to use (as I know it can be very difficult modifying/adding cultivation in the right places).

    This does require you to have some knowledge on how to load cultivation (you'll need to have an airport .tsc file that refers to the cultivation file).

    Here are the current features:

    • Add, edit or delete buildings, plants and lights,
    • Create multiple plants at once (1 to 2500)
    • Create multiple lights at once using a line draw tool
    • Colors and icons for both buildings, plants and lights (color scales for building usage, direct color mapping for lights and icons for plant groups).
    • 3D mode which allows you to see the building and give an indication of the # of floors (can be toggled off).
    • Set default properties via the settings cogwheel, these are used when you create new objects.
    • Modify or delete existing objects by right clicking on them.
    • Mass select objects, drag them, duplicate them or delete them
    • Toggle layer visibility, anything you delete will not count against hidden layers.
    • Tooltip information with the object properties (can be toggled off).
    • Multiple layer of tile sources (Google, Bing, OSM, CartoDB)
    • Load 1 or more existing .TOC files (they must be plaintext)
    • Save the output as .TOC (hidden layers are not included)
    • Unless otherwise stated, assume everything is in meters and uses longitude/latitude.


    • Q for creating a building,
    • W for creating a plant
    • E for creating a light
    • R for creating multiple plants
    • Backspace for deleting selected objects
    • CTRL+V for duplicating selected objects
    • Hotkeys for setting the default type (when drawing) for plant or building:
      • 1 - Broadleaf - ALT residential/gable - SHIFT residential/flat
      • 2 - Shrub - ALT commercial/gable - SHIFT commercial/flat
      • 3 - Conifer - ALT industrial/gable - SHIFT residential/flat
      • 4 - Palm
    • Numpad 1 to 5 can be used to change floors on the selection area if they contain buildings
    • F or D for zooming in and out (as it's broken in Firefox)
    • ESC to cancel all drawing or editing action
    • CTRL + Mouse to select objects (they are highlighted as blue after selection)

    When in draw mode:

    • Plant and Light objects are created by just double clicking anywhere
    • Building is created by clicking once to start the rectangle and then clicking again to finish
    • Mass plants are created in the shape of a polygon, keep clicking on your polygon boundaries and double click to finish.
    • Mass lights are created in the shape of a line, click on your line boundaries and double click to finish
    • If you made a mistake you can right click delete or mass select delete
    • AFS2 only supports rectangular buildings, so make sure they look somewhat rectangular, (they'll end up being rectangular anyhow).
    • Hold right mouse to shift your view at an angle

    Every time you load the editor you'll be placed near London (loading a .toc file will take the center of the cultivation data present and put you there). I plan on adding a local state to save your location/settings (but not data as that wouldn't be possible through browser's limited local storage).

    You are able to load any .toc file or alternatively just add buildings, plants and lights and save from scratch. If you want to give it a test run, I suggest loading the scenery by drassaud (such as Autogen Switzerland South Beta 0.1.0 and opening ch/places/Autogen ch South/fl_8-8 46-1_00.toc) or you can use my example.toc and load that (just a few buildings, plants and lights).

    Anyhow, without further ado, here's the link: AFS2 Cultivation Editor. The editor itself runs locally so it will depend on your resources (CPU/GPU) to process and render. Moreover I've only tested this on the latest Google Chrome (Firefox was a bit sluggish and I had issues zooming, other browsers untested).

    Looking forward to feedback! I can extend this to parse and work with .tsc files as well and add support for other things such as airports, xrefs, parking positions, runways, helipads, etc.

    I've actually seen this when playing VR, what I *think* is the cause is occlusion culling (game development term for not rendering something that isn't in your frustum) on the glass panes (it may have to do with your in-game view perhaps?).


    I am trying to look through the TSC files for scenery creation but have some questions:

    1. It looks like the default AFS2 scenery uses <[list_tmsimulator_scenery_object][objects][] but airports from FSCloudPort use <[tmsimulator_scenery_objecttmslist][objects][]. I take it they both work but is there some format that needs to be followed here?

    2. I can see a lot of attributes under some scenery files, is there a way (other than looking through all existing TSC files) to find out what each element can contain? Example: tmsimulator_scenery_object can have a type: ground, decal, object and even ground_mesh (which I found is seldomly used). It also seems that some other fields are optional (such as orientation). I've also noticed autoheight_override is set to -1, but if there is an override, how is this defined? what is that field and type?

    3. What are the default values if we don't specify something (such as <[string8][autoheight_method][smooth_elevation]>, but FSCloudport doesn't have this, so I wonder what the default is?). Do we know what the mandatory fields are?

    I've tried to Google but that didn't help much, would be awesome if there was some kind of schema or way of knowing.