<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ja">
	<id>https://ja.lfsmanual.net/index.php?action=history&amp;feed=atom&amp;title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90</id>
	<title>スクリプト作成 - 変更履歴</title>
	<link rel="self" type="application/atom+xml" href="https://ja.lfsmanual.net/index.php?action=history&amp;feed=atom&amp;title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90"/>
	<link rel="alternate" type="text/html" href="https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;action=history"/>
	<updated>2026-04-16T17:01:28Z</updated>
	<subtitle>このウィキのこのページに関する変更履歴</subtitle>
	<generator>MediaWiki 1.35.0</generator>
	<entry>
		<id>https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=2536&amp;oldid=prev</id>
		<title>Dankitk: DeepL で翻訳</title>
		<link rel="alternate" type="text/html" href="https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=2536&amp;oldid=prev"/>
		<updated>2022-07-30T13:26:39Z</updated>

		<summary type="html">&lt;p&gt;DeepL で翻訳&lt;/p&gt;
&lt;a href=&quot;https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;amp;diff=2536&amp;amp;oldid=2259&quot;&gt;差分を表示&lt;/a&gt;</summary>
		<author><name>Dankitk</name></author>
	</entry>
	<entry>
		<id>https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=2259&amp;oldid=prev</id>
		<title>Skylinekakkoii: 英最新版のコピー&amp;一部翻訳</title>
		<link rel="alternate" type="text/html" href="https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=2259&amp;oldid=prev"/>
		<updated>2017-02-23T14:06:35Z</updated>

		<summary type="html">&lt;p&gt;英最新版のコピー&amp;amp;一部翻訳&lt;/p&gt;
&lt;a href=&quot;https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;amp;diff=2259&amp;amp;oldid=1883&quot;&gt;差分を表示&lt;/a&gt;</summary>
		<author><name>Skylinekakkoii</name></author>
	</entry>
	<entry>
		<id>https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=1883&amp;oldid=prev</id>
		<title>2008年5月4日 (日) 03:38 における dankitk による編集</title>
		<link rel="alternate" type="text/html" href="https://ja.lfsmanual.net/index.php?title=%E3%82%B9%E3%82%AF%E3%83%AA%E3%83%97%E3%83%88%E4%BD%9C%E6%88%90&amp;diff=1883&amp;oldid=prev"/>
		<updated>2008-05-04T03:38:05Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新規ページ&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;#039;&amp;#039;by AndroidXP&amp;#039;&amp;#039;&lt;br /&gt;
== Introduction ==&lt;br /&gt;
With the release of patch V in December 2006, the LFS developers introduced a new scripting system, quite similar to the implementation seen in most first person shooters. Generally, it allows the automation of common tasks, customisation of options on a per-car basis as well as simple toggles to change the binding of keys (and more). This guide is aimed to give you a general understanding of the LFS script system as well as a few examples for simple scripts.&lt;br /&gt;
&lt;br /&gt;
== How to use ==&lt;br /&gt;
=== Basics ===&lt;br /&gt;
Script files have the extension &amp;quot;.lfs&amp;quot; and can be found under &amp;lt;LFS install dir&amp;gt;\data\script. To edit these files, simply open them with a text editor of your choice (Notepad, etc). You can also create new script files, just make sure they have the right extension. If you want, you can even organize your scripts into subdirectories to keep the place clean.&lt;br /&gt;
&lt;br /&gt;
In general, each line in the script file represents a command that is executed by LFS, going from top to bottom. The only exception are empty lines, and lines that start with &amp;quot;//&amp;quot;, which are treated as comments and thus ignored. Basically you can imagine the system as LFS reading each line, writing it into the chat window and hitting return. Of course it is not &amp;#039;&amp;#039;exactly&amp;#039;&amp;#039; like that, but it should give you the general idea.&lt;br /&gt;
&lt;br /&gt;
=== Reserved filenames ===&lt;br /&gt;
While you can generally name new script files however you want, a few names have a special meaning to LFS. All affected files already exist in the script folder when you first install the patch, so as long as you don&amp;#039;t move or overwrite any files everything will be fine.&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;autoexec.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
: Like the name suggests, this script is executed automatically every time LFS starts and is thus the ideal place to initialize your scripts.&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;CAR.lfs&amp;#039;&amp;#039;&amp;#039;&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;CAR&amp;quot; being replaced with one of the three-letter car shortcuts (see [[Cars|here]] or below), these scripts are executed everytime the corresponding car is selected in the garage - for example if you select the XR GT Turbo, LFS will execute &amp;quot;XRT.lfs&amp;quot;. They are usually used for car specific settings, like a custom FOV or force feedback strength.&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;road.lfs, sequential.lfs, paddle.lfs&amp;#039;&amp;#039;&amp;#039;&amp;lt;br&amp;gt;&lt;br /&gt;
: Even though these filenames are neither reserved nor automatically executed, they are worth mentioning as by default they are run from inside the &amp;#039;&amp;#039;CAR.lfs&amp;#039;&amp;#039; scripts. Their main purpose are custom settings that should apply to cars with a certain shifter type. &amp;#039;&amp;#039;Road.lfs&amp;#039;&amp;#039; is the equivalent to cars with a H-gate shifter, &amp;#039;&amp;#039;sequential.lfs&amp;#039;&amp;#039; to a sequential stick shifter and &amp;#039;&amp;#039;paddle.lfs&amp;#039;&amp;#039; to having paddles. If you have a wheel that supports such shifter types (like the [[Wheels#Logitech_G25|Logitech G25]] for example), then these script files are handy to automatically change the shifter setup so it fits the currently selected car.&lt;br /&gt;
&lt;br /&gt;
: To match the cars to their gearbox, they should be assigned as following:&amp;lt;br&amp;gt;&lt;br /&gt;
{| style=&amp;quot;margin-left:23px&amp;quot;&lt;br /&gt;
|Road:||UF1, XFG, XRG, XRT, RB4, FXO, LX4, LX6, FZ5, FZR, UFR, XFR, RAC&lt;br /&gt;
|-&lt;br /&gt;
|Sequential:||FBM, FOX, FO8, MRT, XRR, FXR&lt;br /&gt;
|-&lt;br /&gt;
|Paddle:||BF1&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Commands ==&lt;br /&gt;
The following commands are just an excerpt of the more commonly used ones.&amp;lt;br&amp;gt;&lt;br /&gt;
A list of all commands can be found under &amp;lt;LFS install dir&amp;gt;\docs\Commands.txt.&lt;br /&gt;
&lt;br /&gt;
=== Options &amp;amp; Miscellaneous ===&lt;br /&gt;
 /run        [scriptname]    - run a script (data\script\scriptname.lfs), &lt;br /&gt;
                               e.g. &amp;quot;/run myScript&amp;quot; or &amp;quot;/run myFolder\myScript&amp;quot;&lt;br /&gt;
 /say        [message]       - same as typing a chat message&lt;br /&gt;
 /echo       [text]          - show text (only on local screen)&lt;br /&gt;
 /fov        [degrees]       - field of view&lt;br /&gt;
 /ff         [0-200]         - force feedback strength&lt;br /&gt;
 /wheel_turn [degrees]       - specify turn angle of controller&lt;br /&gt;
 /autoclutch [0-1]           - turn autoclutch off / on&lt;br /&gt;
 /gccut      [0-1]           - throttle cut on upshift&lt;br /&gt;
 /gcblip     [0-1]           - throttle blip on downshift&lt;br /&gt;
 /shifter    [auto/sequential/shifter]    - shift type&lt;br /&gt;
 /view       [fol/heli/cam/driver/custom] - select view&lt;br /&gt;
&lt;br /&gt;
=== Binding &amp;amp; Executing Commands ===&lt;br /&gt;
 &amp;#039;&amp;#039;&amp;#039;Binding&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /axis   [axis]   [function] - e.g. &amp;quot;/axis 2 throttle&amp;quot;   (to unbind, use -1)&lt;br /&gt;
 /invert [0/1]    [function] - e.g. &amp;quot;/invert 1 brake&amp;quot;    &lt;br /&gt;
 /button [button] [function] - e.g. &amp;quot;/button 5 shift_up&amp;quot; (to unbind, use -1)&lt;br /&gt;
 /key    [key]    [function] - e.g. &amp;quot;/key Q handbrake&amp;quot;&lt;br /&gt;
 /ctrlf  [num]    [text]     - change shortcut text, e.g. &amp;quot;/ctrlf 1 hello&amp;quot;&lt;br /&gt;
 /altf   [num]    [text]     - change shortcut text, e.g. &amp;quot;/altf 1 bye&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
 &amp;#039;&amp;#039;&amp;#039;Simulating key presses&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press [key]                - simulate key press&lt;br /&gt;
 /shift [key]                - SHIFT + key&lt;br /&gt;
 /ctrl  [key]                - CTRL + key&lt;br /&gt;
 /alt   [key]                - ALT + key&lt;br /&gt;
&lt;br /&gt;
=== Parameter reference ===&lt;br /&gt;
 &amp;#039;&amp;#039;&amp;#039;Function names for the /button and /key commands&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 steer_left, steer_right, steer_fast, steer_slow&lt;br /&gt;
 throttle, brake, shift_up, shift_down&lt;br /&gt;
 clutch, handbrake, left_view, right_view, rear_view&lt;br /&gt;
 horn, flash, reset, pit_speed, tc_disable, zoom_in, zoom_out&lt;br /&gt;
 reverse, gear_1 - gear_7, ctrl_f1 - ctrl_f12&lt;br /&gt;
 &amp;lt;span style=&amp;quot;color:gray&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;#039;&amp;#039;To find out the number for a controller button, go to Options &amp;gt; Controls&amp;#039;&amp;#039;&lt;br /&gt;
 &amp;#039;&amp;#039;and press the button in question. You will see the button # and currently&amp;#039;&amp;#039;&lt;br /&gt;
 &amp;#039;&amp;#039;assigned function in the middle right part of the screen.&amp;#039;&amp;#039;&lt;br /&gt;
 &amp;lt;/span&amp;gt;&lt;br /&gt;
 &amp;#039;&amp;#039;&amp;#039;Function names for the /axis and /invert commands&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 steer, combined, throttle, brake&lt;br /&gt;
 lookh, lookp, lookr&lt;br /&gt;
 clutch, handbrake, shiftx, shifty&lt;br /&gt;
 &lt;br /&gt;
 &amp;#039;&amp;#039;&amp;#039;Parameters for the key press commands (press / shift / ctrl / alt)&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 Letters A to Z&lt;br /&gt;
 Numbers 0 to 9&lt;br /&gt;
 F1 to F12&lt;br /&gt;
 up, down, left, right&lt;br /&gt;
 space, enter, esc, tab&lt;br /&gt;
 less, more &amp;lt;span style=&amp;quot;color:gray&amp;quot;&amp;gt;(&amp;lt;, &amp;gt;)&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
On a general note: as you might have noticed from the command listing, it is currently impossible to bind other script commands to a button; for example, &amp;quot;/button 1 /say hello&amp;quot; wouldn&amp;#039;t work. Luckily we can use the text shortcut keys (Ctrl+F1-F12, Alt+F1-F12) for this, so we can use &amp;quot;/ctrlf 1 /say hello&amp;quot; (which binds &amp;quot;/say hello&amp;quot; to Ctrl+F1) and then &amp;quot;/button 1 ctrl_f1&amp;quot; (binds the press of Ctrl+F1 to button #1). However, this also means that you have to give away a few of your shortcut keys for the scripts, which shouldn&amp;#039;t really be a problem, considering there are 32 available shortcuts total (24 bindable via scripts).&lt;br /&gt;
=== &amp;quot;F9 &amp;gt; F10 &amp;gt; F11 &amp;gt; F12 &amp;gt; Off&amp;quot; Toggle ===&lt;br /&gt;
The basic idea of this script is, that we want to have one button (for example on the wheel) cycling through the F9-F12 menus. To accomplish this, we need five scripts plus an entry in &amp;#039;&amp;#039;autoexec.lfs&amp;#039;&amp;#039;. &lt;br /&gt;
&lt;br /&gt;
For this script we will use the Ctrl+F12 text shortcut for our cycle, and bind button #0 (whichever button that is on your controller) to execute it. The multiple usage of the /press command ensures that the menu is properly displayed, in case a menu was already opened manually beforehand. For example, if the F11 menu is already open and we would run &amp;#039;&amp;#039;viewF11.lfs&amp;#039;&amp;#039; without pressing the F9 key in it, it would just close the F11 menu instead, which is something we definitely don&amp;#039;t want to happen in the heat of a race.&lt;br /&gt;
&lt;br /&gt;
It will work like this:&amp;lt;br&amp;gt;&lt;br /&gt;
#Button 0 -&amp;gt; Ctrl+F12 -&amp;gt; viewF9 -&amp;gt; press F9 + rebind Ctrl+F12 to run viewF10&amp;lt;br&amp;gt;&lt;br /&gt;
#Button 0 -&amp;gt; Ctrl+F12 -&amp;gt; viewF10 -&amp;gt; press F10 + rebind Ctrl+F12 to run viewF11&amp;lt;br&amp;gt;&lt;br /&gt;
#Button 0 -&amp;gt; Ctrl+F12 -&amp;gt; viewF11 -&amp;gt; press F11 + rebind Ctrl+F12 to run viewF12&amp;lt;br&amp;gt;&lt;br /&gt;
#Button 0 -&amp;gt; Ctrl+F12 -&amp;gt; viewF12 -&amp;gt; press F12 + rebind Ctrl+F12 to run viewOff&amp;lt;br&amp;gt;&lt;br /&gt;
#Button 0 -&amp;gt; Ctrl+F12 -&amp;gt; viewOff -&amp;gt; turn off menu + rebind Ctrl+F12 to run viewF9&amp;lt;br&amp;gt;&lt;br /&gt;
:...&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;viewF9.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press F10&lt;br /&gt;
 /press F9&lt;br /&gt;
 /ctrlf 12 /run viewF10&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;viewF10.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press F9&lt;br /&gt;
 /press F10&lt;br /&gt;
 /ctrlf 12 /run viewF11&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;viewF11.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press F9&lt;br /&gt;
 /press F11&lt;br /&gt;
 /ctrlf 12 /run viewF12&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;viewF12.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press F9&lt;br /&gt;
 /press F12&lt;br /&gt;
 /ctrlf 12 /run viewOff&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;viewOff.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press F10&lt;br /&gt;
 /press F9&lt;br /&gt;
 /press F9&lt;br /&gt;
 /ctrlf 12 /run viewF9&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;autoexec.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /button 0 ctrl_f12&lt;br /&gt;
 /ctrlf 12 /run viewF9&lt;br /&gt;
&lt;br /&gt;
=== Indicator Control ===&lt;br /&gt;
This example shows a simple way to comfortably control the indicators with two buttons. You need three scripts and a few entries to &amp;#039;&amp;#039;autoexec.lfs&amp;#039;&amp;#039;, shortcut keys used are Ctrl+F10 and F11. The indicators will work as follows; first press of left button activates left indicator, second press deactivates it. Vice versa for the right button. Switching between left and right is possible. For ease of use, the script will output green arrows indicating the currently selected mode into the chat area. &lt;br /&gt;
&lt;br /&gt;
By using the same logic and adding another script, it is also easy to implement the control of the hazards by a third button.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;indicateLeft.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press 7&lt;br /&gt;
 /ctrlf 11 /run indicateStop&lt;br /&gt;
 /ctrlf 10 /run indicateRight&lt;br /&gt;
 /echo ^2‹ ‹ ‹&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;indicateRight.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press 8&lt;br /&gt;
 /ctrlf 10 /run indicateStop&lt;br /&gt;
 /ctrlf 11 /run indicateLeft&lt;br /&gt;
 /echo ^2› › ›&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;indicateStop.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /press 0&lt;br /&gt;
 /ctrlf 10 /run indicateRight&lt;br /&gt;
 /ctrlf 11 /run indicateLeft&lt;br /&gt;
 /echo ^8Off&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;autoexec.lfs&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
 /button 16 ctrl_f11&lt;br /&gt;
 /button 18 ctrl_f10 &lt;br /&gt;
 /ctrlf 10 /run indicateRight&lt;br /&gt;
 /ctrlf 11 /run indicateLeft&lt;br /&gt;
&lt;br /&gt;
[[en:Script Guide]]&lt;/div&gt;</summary>
		<author><name>dankitk</name></author>
	</entry>
</feed>