The online racing simulator
Training Lesson Editor - Instructions
As many of you know, we released our simple training lesson editor in the 0.6K update. This is obviously not expected to have mass appeal, but some people would like to use it. We have recently had a technical support query from someone who wants to use it for educational purposes. They want to be able to edit lessons but don't know where to start.

I decided this afternoon to have a go at writing a short description / instruction manual for it. I don't want to go into great detail with it but thought it might point people in the right direction.

I thought I'd just attach it here, in case anyone with a vague interest could let me know if it reads OK or if any of it is unclear, before we send it out.

Thanks!

Quote :How to use the training lesson editor in Live for Speed


NOTE : The training lesson editor was not originally designed to be released, so it is not very user friendly or beautiful. However, the lessons are fairly simple so it is possible to get good results. This guide will help to point you in the right direction and further information can be found by looking into existing lessons using the editor. For many types of lesson you will need to create a layout. A layout is a collection of objects (such as tyres, cones and chalk arrows) and abstract objects (such as start positions and checkpoints). Layouts are created in the Layout Editor AKA Autocross Editor, which you can access by pressing SHIFT+U in game. Instructions are in the docs\Autocross.txt file.


To access the training lesson editors:

SHIFT+T on main entry screen to access Lesson Editor or List Editor.

- Lesson Editor is used to create or edit individual lessons
- List Editor is used to edit the list of lessons seen in game


How a training lesson is constructed:

A lesson consists of a few files in the data\training folder.

1) Every lesson needs a .lsn file (created in the lesson editor)

Select:

Car Name - self explanatory
Track Name - self explanatory
The number of the configuration (e.g. Blackwood GP track is 1, Rallycross is 2)
Layout name - see below
Image name - see below
Lesson Type - Overtaking / Test Drive / Timed Layout / Emergency Stop
Some other information depending on the type of lesson

The .lsn file is created when you click the save button at the bottom of the screen.

2) Description text file with the same name as the lesson but .txt instead of .lsn

The text file must be created in a text editor, e.g. Notepad. The Objective, Purpose and Tips sections are separated by a line containing only a backslash.

3) Many lessons use a layout. The layout can be loaded in the lesson editor.

If your lesson requires a layout, it must be edited in the autocross editor (also known as SHIFT+U mode or the layout editor) from where it will be saved in the data\layout folder. For your lesson to access the layout file, the .lyt file must be manually copied into the data\training folder.

4) A descriptive image in jpg format. The image can be loaded in the lesson editor.

The image is usually a screenshot of your car driving the lesson. It must be cropped to a square size e.g. 512x512 pixels and saved with a filename starting with "zzz_"


More information about layouts:

In order to have a look into the layouts used for the existing lessons, it may be a good idea to copy all the .lyt files from the data\training folder and paste them into the data\layout folder so you can easily load them in SHIFT+U mode and see what objects a lesson requires.


Testing a lesson:

After saving your lesson from the lesson editor, you will want to test it. Go back to the main entry screen and click on "Training". You will see the edited list of lessons but not the lesson you just created. You can press SHIFT+T to see your newly added lesson.


Editing the lesson list:

To make your lesson appear in the ordered list in the Training screen (without needing to press SHIFT+T) you will need to edit the Training List. This is simply done in the List Editor where you see "add" and "del" buttons and some arrows to move the selected lesson up or down the list. After adding your lesson or deleting any you don't want to see, click the "save" button at the bottom of the screen


www.lfs.net - 15 February 2016

My first thought (before we get into description) was that there should probably be a new Forum header for Training Lessons so that people who've made them can load for others to use. Either totally new or subset of Autocross layouts?

Your description. Likely it's me, but made little sense, and couldn't follow it.

After playing about for a while, tried making my own instructions, which were;

Design lesson layout in Autocross Editor (SHIFT U mode). Do not make layout in Rev, X or Y configurations.

Save layout.

Take screenshot of layout (preferable not with Editor enabled).

Layout will be saved in /data/layout. Manually copy and save into /data/lesson directory.

Edit screenshot and save as 512 x 512 jpg into /data/lesson directory. Saved file should start as zzz_ then 3 letter descripter, then 2 or 3 letter car type - no spaces, use underline (e.g. zzz_jum_rb4.jpg).

Make small instructions text file (.txt) explaining lesson, and save in /data/lesson directory. Where you want a line space (with no text), use slash (\), e.g.
Quote :When the lights go green, accelerate while heading for jump.
\
Have enough speed to jump the gap.
\
Lesson over when you cross the finish line.

Text file should have same name as layout name.

Select Lesson Editor (SHIFT T in main entry screen)

Click and choose from the various selections. You will need to choose;

Car Type
Track Name
Config
Layout Name
Image Name
Lesson Type

Depending on 'Lesson Type', there may be futher choices.

(Just an observation, but the black text for the various choices is almost unreadable).

This is where it all went wrong.

My newly made layout does not appear as choice in 'Layout Name' list. In fact, there are 2 choices (AU1_test and AU1_MRT_AutoX), while the lesson directory contains 6 layouts (AU1_Fast Slalom, AU1_MRT_AutoX_1, AU1_Quick Chicane, AU1_Slow Slalom, AU1_testdrive and AU1_Throttle Control#2).

Does AU1_testdrive layout = AU1_test and AU1_MRT_AutoX_1 = AU1_MRT_AutoX?

Also, my newly made and saved zzz_jum_rb4.jpg does not appear in the 'Image Name' list. Tried copying and saving that image as AU1_JumpGap.jpg, but looks like image has to start 'zzz_'.

I assume, if I could edit the Lesson Type to suit my lesson layout, the file would be saved as .lsn file, with relevant info inside (car type, track abbreviation, layout name and image name)?

And it would be this file that would be needed for the List Editor?
Attached images
zzz_jum_rb4.jpg
Attached files
AU1_JumpGap.lyt - 236 B - 317 views
AU1_JumpGap.txt - 147 B - 208 views
Hi sinanju, thanks for the test.

First of all I see I made a mistake with the folder name. It's actually data\training and not data\lesson. So I've edited the first post with that correction. Hopefully that should solve the problem you found and you should see those files, ready to load.

I see what you mean that my description could be quite confusing. I've changed the "How a training lesson is constructed" section to be more informative.

It's interesting the way you have written your version, in a step by step way that is probably easier to understand. Anyway for now at least I have added a bit more info. I know it needs more, like a description of the format for the text file.

About your last question, yes, if you loaded the layout and image file into your lesson, then when you click "save" at the bottom of the screen, the saved file is a .lsn file, representing the lesson itself and that would be something you could add to the list.
Got it working now! Thanks.

"Editing the lesson list:"
Worth noting that AutoX automatically saved as Easy mode, although the difficulty can be changed to Easy, Medium or Hard by clicking the button under 'Difficulty'.

Also, AutoX automatically saved as S1 mode (no option to change). I assume because this is minimum license needed, and tracks will automatically save in mode reflecting minimum license needed, e.g. Rockingham will save as S3 mode.
I wrote my thoughts/problems with lessons editor here:
https://www.lfs.net/forum/post/1898333#post1898333

Another small problem I encountered is this:
https://www.lfs.net/forum/post/1900334#post1900334
I felt very clever for having figured out a trick to use open-config tracks. But it was too clever, those lessons gave error and skipped to next one. Looking
That was bit bummer because I had already made some pictures. (see attachments)

I think lessons can potentially be good for autocross/slalom because some layouts are confusing without a trackmap.
The description/image combination of lessons would be perfect.
Lessons also have a bronze/silver/gold target time, that makes it more interessting than just the layout itself because there is more of a 'challenge.'
It would just need a way to somehow pack all the files (picture, .lyt, .lsn file, entry in lessons.lll) for easy sharing on forum.
Attached images
s2.png
s1.png
Quote from Gutholz :I wrote my thoughts/problems with lessons editor here ...... Another small problem I encountered is ...

Wish I'd noticed your problem posts - you're way ahead in the use of the training lessons.

Quote from Gutholz :It would just need a way to somehow pack all the files (picture, .lyt, .lsn file, entry in lessons.lll) for easy sharing on forum.

As the .lyt, lsn, .txt and .jpg files will all be put in the \data\training folder, these could all just be zipped up, and downloader told where they should be placed.

The difficult part for most users, due to lack of knowledge / experience, will be the need to SHIFT T into List Editor mode, and then move this downloaded Lesson up the list to the top, so it becomes the first lesson.

Not sure uploaders of lessons should be supplying downloaders with uploaders own lessons.lll file as downloader may have already added one or more training lessons into their list, and uploaders file may have non-standard lessons in it too.

I still think a separate forum section for these 'extra' training lessons should be made, and the first couple of posts could be sticky's giving step by step instructions - one on how to make your own, another if downloading (where to put files, and SHIFT T list, etc). Possibly another section for 'real' training layouts, and another for autocross event training/competition layouts, like your images.

An aide-memoir for myself - if loading lessons onto forum, best to make clear in some way what license level is required (demo, S1, S2, S3) as not all layouts will be available for all license types (not much good demo user downloading S1, S2, or S3 lessons, or S1/S2 users loading S3, etc).
Quote :
Quote :It would just need a way to somehow pack all the files (picture, .lyt, .lsn file, entry in lessons.lll) for easy sharing on forum.

As the .lyt, lsn, .txt and .jpg files will all be put in the \data\training folder, these could all just be zipped up, and downloader told where they should be placed.

Yes, but with so many files there could be problems with duplicate filenames. And it is not userfriendly either.
There is also the problem of one lessons.lll, players would always have to manually use Shift-T editor to sort the order of every item and it is all rather confusing even with instructions.
Imagine having to manipulate lessons list every time you want to play some new ones, that would be no fun. Best instruction is no instructions required Smile

I really think an option to save multiple lessons and all their the files into a "lesson package" would be good. Each package with its own lessons.lll file.
Then in LFS have a menu "Play custom lessons package"
(No idea if that would be popular enough for the effort)
Interesting stuff. Must explore this later on. Perhaps can we make a manual together; "Lesson editor for crash test dummies".
Didn't get a chance to look into this, but will it be possible to do pacenotes for rally stages with this?
Not certain, but I don't think so.

You have to make a text file to go with your layout, etc, but that text is only shown when you get onto 1st screen.

Its only on checking that I realised that the hashes within the file, which I thought were to replace blank lines, are actually there to fit within the Objective / Purpose / Tips that appear when you get into 1st screen of training/lesson before you hit GO.

EDIT: If I'd ready the revised instructions properly then I'd have found this out.



Screenie shows 1st para is for the Objective, 2nd for Purpose and 3rd for Tips.
Attached images
LFS Training.png
May I suggest migrating these instructions to the LFS Wiki? The Wiki syntax allows for better text, image and code samples plus it's easier to collaborate while keeping the progress in-place.

(But don't look at me, I've done enough edits for a while Smile)
I've written an alternative, and very verbose description, using most of the 'blurb' put together by Scawen, but hopefully in a better way to make it more obvious in what order things should be done, and why.

In a Word document these instructions would fill about 3 x A4 pages.

Quote from felplacerad :May I suggest migrating these instructions to the LFS Wiki? The Wiki syntax allows for better text, image and code samples plus it's easier to collaborate while keeping the progress in-place.

http://en.lfsmanual.net/wiki/Training_Lesson_Editor, perhaps?

(But don't look at me, I've done enough edits for a while Smile)

Don't look at me either. I have no idea how to edit a wiki, and I don't have the necessary create privilages. Schwitz
Attached files
Training Lesson Instructions.txt - 5.6 KB - 275 views
Thank you all for the feedback and thanks sinanju for your version of the instructions.

I'd say better not put it on the wiki yet, as I'm going to make a few improvements in the editor. It's half term week here and I've just finished a big push, so I'm not getting stuck into serious work, but can do some simple updates.

Of course I want to make things easier to use and remove any pointless restrictions, if possible, as discussed.

Are there any completely different lesson types that should be added? Or types of lesson that would be good but the current modes do not support?
Quote from Scawen :Are there any completely different lesson types that should be added? Or types of lesson that would be good but the current modes do not support?

Would it be a crazy idea to suggest having a database of lessons and save the times in LFS website? A combination of the LFSWorld hotlap charts and the new setup database.

Each lesson has a unique hash, that then we could use in the leagues section, the game would download that lesson list, and save your runs.

I'm not sure how many people would use this mode, but it would allow to create small 'offline' tournaments. And may I say that I miss the official LX month we had several years ago?
I agree with Whiskey's idea! Big grin
Quote from Scawen :
Are there any completely different lesson types that should be added? Or types of lesson that would be good but the current modes do not support?

Do we have ability to make a parking lesson? So that we put a parking marker and then driver is required to park on it, so that we can score him on how precise he was :]
Quote from Scawen :Are there any completely different lesson types that should be added? Or types of lesson that would be good but the current modes do not support?

Certain types of competetion layouts such as this:

It is not possible to create routechecks for such tracks.

In LFS if a car drives drive through a checkpoint that is not the "next one" then there is "wrong route" penality.
That is a problem if the path crosses itself or a checkpoint is 'in the way' of path to next pylon.

If a checkpoint was crossed too early, that should maybe be ignored instead of penalized?
(Would that also help the 'no overlapping checkpoints' problem?)
The final check if all checkpoints were crossed could be at finish line.
Another nice addition would be checkpoints (or split-lines) that must be crossed in reverse, and checkpoints that require the car to come to complete stop in the circle.

Quote from Whiskey :Would it be a crazy idea to suggest having a database of lessons and save the times in LFS website? (...)
I'm not sure how many people would use this mode, but it would allow to create small 'offline' tournaments.

Would of course be cool as official feature, but is more or less possible with Insim. (There is lapper scripts for !top list and such.) Or a more crude way is to have a server run in qualification mode with long duration.
Currently the "VGP Hotlap Championship" is currently doing something similiar with ~60+ drivers per stage. Many more might be playing offline with layouts..I think timetrial/layouts is reasonably popular.
Does lessons editor support multiple languages? If I make lesson, with finnish translation, but going to translate it to english?

I have thought to make a proper one with complete tutorial, haven't simply started it... yet
EDIT: nvm


Ah, it says as recommendation as do not use open configurations or reversed configs... pity
Scawen, do you still have plans for this lesson editor?

I think what it needs the most is an easy way to share the lesson-files with others.
Currently it would requires users to download and unpack zip-archive and open the lessons in editor. That is okay for testing but I fear that is too complicated for normal players.
Also it only allows to select original LFS cars.

FGED GREDG RDFGDR GSFDG