Skip to content

Commit

Permalink
FS22 build 120
Browse files Browse the repository at this point in the history
  • Loading branch information
Mogli12 committed Nov 4, 2022
1 parent 345950f commit 2461b11
Show file tree
Hide file tree
Showing 6 changed files with 41 additions and 23 deletions.
Binary file modified FS22_VehicleControlAddon.zip
Binary file not shown.
Binary file removed FS22_VehicleControlAddon/dds/diff_wheels.dds
Binary file not shown.
1 change: 1 addition & 0 deletions FS22_VehicleControlAddon/l10n/modDesc_l10n_de.xml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@
<text name="input_vcaSNAPPREV" text="VCA: Vorherige Rasterbahn"/>
<text name="input_vcaSNAPNEXT" text="VCA: Nächste Rasterbahn"/>
<text name="input_vcaSNAPDIST" text="VCA: Arbeitsbreite für Fahrtrichtung ermitteln"/>
<text name="input_vcaWORKAREA" text="VCA: Markierungen für Arbeitsbreite"/>
<text name="input_vcaSnapUP" text="VCA: Raster nach links drehen"/>
<text name="input_vcaSnapDOWN" text="VCA: Raster nach rechts drehen"/>
<text name="input_vcaSnapLEFT" text="VCA: Raster links"/>
Expand Down
1 change: 1 addition & 0 deletions FS22_VehicleControlAddon/l10n/modDesc_l10n_en.xml
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
<text name="input_vcaSNAPCONT" text="VCA: reactivate guidance lane"/>
<text name="input_vcaSNAPRESET" text="VCA: reset lane guidance direction"/>
<text name="input_vcaSNAPDIST" text="VCA: determine working width of lane guidance"/>
<text name="input_vcaWORKAREA" text="VCA: work area marker"/>
<text name="input_vcaSnapUP" text="VCA: rotate lane guidance direction left"/>
<text name="input_vcaSnapDOWN" text="VCA: rotate lane guidance direction right"/>
<text name="input_vcaSnapLEFT" text="VCA: shift lane guidance left"/>
Expand Down
26 changes: 16 additions & 10 deletions FS22_VehicleControlAddon/modDesc.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="no" ?>
<modDesc descVersion="67">
<modDesc descVersion="71">
<author>mogli</author>
<title>
<en>Vehicle Control Addon</en>
Expand All @@ -22,10 +22,11 @@ Changelog version 1.1.0.0:
- Compatibility with ProSeed
- Additional adaptive steering (soft)
Changelog version 1.2.0.0:
- vehicle is too slow driving reverse
- improved idle throttle and manual clutch
- wheel slip and cruise control
- speed limiter]]></en>
- Vehicle is too slow driving reverse
- Improved idle throttle and manual clutch
- Wheel slip and cruise control
- Speed limiter
- Compatibility with CabView]]></en>
<de><![CDATA[Die Erweiterung zur Fahrzeugkontrolle (VCA) kombiniert viele Funktionen in einer Modifikation. Die meisten Funktionen sind standardmäßig ausgeschaltet. VCA kann die Kamerarichtung automatische dem Lenkwinkel und der Fahrtrichtung anpassen. So schaut man immer in die Richtung in die man fährt. Mit den Standardtastenkombinationen RShift und den Pfeiltasten kann man kurz in die entsprechende Richtung blicken. Die adaptive Lenkung ist gedacht für Tastaturspieler. VCA kann die Lenkgeschwindigkeit der Geschwindigkeit des Fahrzeugs anpassen.
Die Erweiterung zur Fahrzeugkontrolle beinhaltet auch eine einfache Spurführung. Drückt man Strg Links zusammen mit W, dann richtet sich die Fahrtrichtung an festen Richtungen aus.
Alle Funktionen lassen sich auch wieder ausschalten, und zwar mit folgenden Tasten:
Expand All @@ -44,7 +45,8 @@ Changelog version 1.2.0.0:
- Fahrzeug fährt nur langsam zurück
- Besserer Start mit manueller Kupplung
- Reifenschlupf und Tempomat
- Geschwindigkeitsbegrenzer]]></de>
- Geschwindigkeitsbegrenzer
- Kompatibilität mit CabView]]></de>
<fr><![CDATA[Le Vehicle Control Addon (VCA) est un ensemble d'améliorations destiné à améliorer votre expérience de conduite des véhicules. Par défaut, la plupart des fonctions sont désactivées. Le VCA peut ajuster automatiquement l'orientation la caméra intérieure et extérieure en fonction de l'angle du volant afin de toujours voir où vous vous dirigez. Vous pouvez également paramétrer des raccourcis pour des coups d'oeil rapides (par défaut Shift droit + flèches de direction). Vous pouvez aussi bloquer l'accélérateur, le limiteur de vitesse et le régime moteur à 75% avec la touche Shift droit.
Le Vehicle Control Addon intègre également un GPS très facilement utilisable. Il vous suffit de l'activer en appuyant sur Ctrl (gauche) + Z pour bloquer la direction du véhicule dans son couloir de travail.
Les fonction du GPS sont accessibles via les raccourcis par défaut suivants :
Expand Down Expand Up @@ -80,12 +82,12 @@ Změny ve verzi 1.1.0.0:
</description>
<multiplayer supported="true"/>
<iconFilename>modIcon.dds</iconFilename>
<version>9.1.1.9</version>
<version>9.1.2.0</version>
<l10n filenamePrefix="l10n/modDesc_l10n">
<text name="vcaVERSION">
<en>Vehicle Control Addon b119</en>
<de>Erweiterung Zur Fahrzeugkontrolle b119</de>
<tr>Araç Kontrol Eklentisi b119</tr>
<en>Vehicle Control Addon b120</en>
<de>Erweiterung Zur Fahrzeugkontrolle b120</de>
<tr>Araç Kontrol Eklentisi b120</tr>
</text>
</l10n>

Expand All @@ -108,6 +110,7 @@ Změny ve verzi 1.1.0.0:
<action name="vcaSNAPNEXT" category="VEHICLE" axisType="HALF"/>
<action name="vcaSNAPRESET" category="VEHICLE" axisType="HALF"/>
<action name="vcaSNAPDIST" category="VEHICLE" axisType="HALF"/>
<action name="vcaWORKAREA" category="VEHICLE" axisType="HALF"/>
<action name="vcaNO_ARB" category="VEHICLE" axisType="HALF"/>
<action name="vcaINCHING" category="VEHICLE" axisType="HALF"/>
<action name="vcaKEEPROT" category="VEHICLE" axisType="HALF"/>
Expand Down Expand Up @@ -183,6 +186,9 @@ Změny ve verzi 1.1.0.0:
<actionBinding action="vcaSNAPDIST">
<binding device="KB_MOUSE_DEFAULT" input="KEY_lctrl KEY_lalt KEY_w"/>
</actionBinding>
<actionBinding action="vcaWORKAREA">
<binding device="KB_MOUSE_DEFAULT" input="KEY_lctrl KEY_lalt KEY_s"/>
</actionBinding>
<actionBinding action="vcaINCHING">
<binding device="KB_MOUSE_DEFAULT" input="KEY_rshift"/>
</actionBinding>
Expand Down
36 changes: 23 additions & 13 deletions FS22_VehicleControlAddon/vehicleControlAddon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,7 @@ function vehicleControlAddon.createStates()
vehicleControlAddon.createState( "isEnteredMP" , nil , false, VCAValueType.bool , nil, false )
vehicleControlAddon.createState( "isBlocked" , nil , false, VCAValueType.bool , nil, false )
vehicleControlAddon.createState( "snapDraw" , nil , 1 , VCAValueType.int16 )
vehicleControlAddon.createState( "workAreaDraw" , nil , 0 , VCAValueType.int16 )
vehicleControlAddon.createState( "snapFactor" , nil , 0 , VCAValueType.float , nil, false )
vehicleControlAddon.createState( "hiredWorker2" , "hiredWorker2" , nil , VCAValueType.bool )
vehicleControlAddon.createState( "rotSpeedOut" , "rotSpeedOut" , nil , VCAValueType.float )
Expand Down Expand Up @@ -890,6 +891,7 @@ function vehicleControlAddon:onRegisterActionEvents(isSelected, isOnActiveVehicl
"vcaHandbrake",
"vcaLimitSpeed",
"vcaAutoShift",
-- "vcaWORKAREA",
}) do

local addThis = InputAction[actionName] ~= nil
Expand Down Expand Up @@ -1325,6 +1327,12 @@ function vehicleControlAddon:actionCallback(actionName, keyStatus, callbackState
self:vcaSetState( "warningText", string.format("%s: %4.0f %s", vehicleControlAddon.getText( "vcaHANDTHROTTLE", "" ), r, vehicleControlAddon.getText( "vcaValueRPM", "RPM" ) ) )
end
end
elseif actionName == "vcaWORKAREA" then
if self.spec_vca.workAreaDraw >= 2 then
self:vcaSetState( "workAreaDraw", 0 )
else
self:vcaSetState( "workAreaDraw", self.spec_vca.workAreaDraw + 1 )
end
elseif actionName == "vcaLowerF" then
self:vcaSetToolStateRec( true, false, true, false )
elseif actionName == "vcaLowerB" then
Expand Down Expand Up @@ -2029,20 +2037,10 @@ function vehicleControlAddon:onUpdate(dt, isActiveForInput, isActiveForInputIgno

local newRotCursorKey = self.spec_vca.newRotCursorKey
local i = self.spec_enterable.camIndex
local requestedBack = nil
local lastWorldRotation = self.spec_vca.camRotWorld

self.spec_vca.newRotCursorKey = nil
self.spec_vca.camRotWorld = nil

if newRotCursorKey ~= nil then
self.spec_enterable.cameras[i].rotY = vehicleControlAddon.normalizeAngleCam( self.spec_enterable.cameras[i].origRotY + newRotCursorKey )
if math.abs( newRotCursorKey ) < 1e-4 then
requestedBack = false
elseif math.abs( newRotCursorKey - math.pi ) < 1e-4 then
requestedBack = true
end
end

if self.spec_vca.inchingIsOn and self.spec_vca.isEntered and self.spec_drivable.cruiseControl.state == Drivable.CRUISECONTROL_STATE_ACTIVE then
local limitThrottleRatio = 0.75
Expand Down Expand Up @@ -2344,7 +2342,8 @@ function vehicleControlAddon:onUpdate(dt, isActiveForInput, isActiveForInputIgno
elseif rotIsOn > 0
or revIsOn
or self.spec_vca.keepCamRot
or lastWorldRotation ~= nil then
or lastWorldRotation ~= nil
or newRotCursorKey ~= nil then

local pi2 = math.pi / 2
local eps = 1e-6
Expand Down Expand Up @@ -2440,10 +2439,21 @@ function vehicleControlAddon:onUpdate(dt, isActiveForInput, isActiveForInputIgno
self.spec_vca.lastFactor = 0
end

if self.spec_cabView ~= nil and camera.isInside then
local spec_cabView = nil
if self["spec_FS22_CabView.cabView"] ~= nil then
spec_cabView = self["spec_FS22_CabView.cabView"]
elseif self.spec_cabView ~= nil then
spec_cabView = self.spec_cabView
end

if not ( type( spec_cabView ) == "table" and camera.isInside ) then
camera.rotY = vehicleControlAddon.normalizeAngleCam( newRotY )
elseif spec_cabView.rotationOffset == nil then
camera.rotY = math.max( 0, math.min( newRotY, math.pi+math.pi ))
else
camera.rotY = vehicleControlAddon.normalizeAngleCam( newRotY )
local minRot = -0.1 * math.pi+spec_cabView.rotationOffset
local maxRot = 2.1 * math.pi+spec_cabView.rotationOffset
camera.rotY = math.max( minRot, math.min( newRotY, maxRot ))
end
end

Expand Down

0 comments on commit 2461b11

Please sign in to comment.