From ca2edb5158e116a612f579ca1a64910d3613688f Mon Sep 17 00:00:00 2001 From: Tensuko Date: Thu, 27 Nov 2025 17:53:53 +0100 Subject: [PATCH 1/5] Add settings --- config/MasterTranslations.xml | 8 ++++++++ config/VehicleSettingsSetup.xml | 4 ++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/config/MasterTranslations.xml b/config/MasterTranslations.xml index a994e4a8..e4f83e8a 100644 --- a/config/MasterTranslations.xml +++ b/config/MasterTranslations.xml @@ -643,6 +643,14 @@ + + + + + + + + diff --git a/config/VehicleSettingsSetup.xml b/config/VehicleSettingsSetup.xml index ddf27c55..a83b9440 100644 --- a/config/VehicleSettingsSetup.xml +++ b/config/VehicleSettingsSetup.xml @@ -27,8 +27,8 @@ - - + + From a699c7bf5b31c6cda2756d1736ba1651c86370f7 Mon Sep 17 00:00:00 2001 From: Tensuko Date: Thu, 27 Nov 2025 16:54:09 +0000 Subject: [PATCH 2/5] Updated translations --- translations/translation_br.xml | 2 ++ translations/translation_cs.xml | 2 ++ translations/translation_ct.xml | 2 ++ translations/translation_cz.xml | 2 ++ translations/translation_da.xml | 2 ++ translations/translation_de.xml | 2 ++ translations/translation_ea.xml | 2 ++ translations/translation_en.xml | 2 ++ translations/translation_es.xml | 2 ++ translations/translation_fc.xml | 2 ++ translations/translation_fi.xml | 2 ++ translations/translation_fr.xml | 2 ++ translations/translation_hu.xml | 2 ++ translations/translation_id.xml | 2 ++ translations/translation_it.xml | 2 ++ translations/translation_jp.xml | 2 ++ translations/translation_kr.xml | 2 ++ translations/translation_nl.xml | 2 ++ translations/translation_no.xml | 2 ++ translations/translation_pl.xml | 2 ++ translations/translation_pt.xml | 2 ++ translations/translation_ro.xml | 2 ++ translations/translation_ru.xml | 2 ++ translations/translation_sv.xml | 2 ++ translations/translation_tr.xml | 2 ++ translations/translation_uk.xml | 2 ++ translations/translation_vi.xml | 2 ++ 27 files changed, 54 insertions(+) diff --git a/translations/translation_br.xml b/translations/translation_br.xml index eb47d733..9df72daa 100644 --- a/translations/translation_br.xml +++ b/translations/translation_br.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_cs.xml b/translations/translation_cs.xml index bfa0e9f7..660507ed 100644 --- a/translations/translation_cs.xml +++ b/translations/translation_cs.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_ct.xml b/translations/translation_ct.xml index 8bac7dd6..758651a3 100644 --- a/translations/translation_ct.xml +++ b/translations/translation_ct.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_cz.xml b/translations/translation_cz.xml index a9c3667b..836924a7 100644 --- a/translations/translation_cz.xml +++ b/translations/translation_cz.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_da.xml b/translations/translation_da.xml index 638f21bd..3a0d780b 100644 --- a/translations/translation_da.xml +++ b/translations/translation_da.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_de.xml b/translations/translation_de.xml index d9027a1b..c3b9c705 100644 --- a/translations/translation_de.xml +++ b/translations/translation_de.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_ea.xml b/translations/translation_ea.xml index 76b9b103..f47d4ee0 100644 --- a/translations/translation_ea.xml +++ b/translations/translation_ea.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_en.xml b/translations/translation_en.xml index 066cc0fb..29744c14 100644 --- a/translations/translation_en.xml +++ b/translations/translation_en.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_es.xml b/translations/translation_es.xml index 07500b06..aa3a6c79 100644 --- a/translations/translation_es.xml +++ b/translations/translation_es.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_fc.xml b/translations/translation_fc.xml index 4e7fb549..0d234c39 100644 --- a/translations/translation_fc.xml +++ b/translations/translation_fc.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_fi.xml b/translations/translation_fi.xml index d628ad2a..a68f1bc5 100644 --- a/translations/translation_fi.xml +++ b/translations/translation_fi.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_fr.xml b/translations/translation_fr.xml index 4d927f4a..231c759a 100644 --- a/translations/translation_fr.xml +++ b/translations/translation_fr.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_hu.xml b/translations/translation_hu.xml index 264bb5e1..276a80e6 100644 --- a/translations/translation_hu.xml +++ b/translations/translation_hu.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_id.xml b/translations/translation_id.xml index 224a85e2..87e37072 100644 --- a/translations/translation_id.xml +++ b/translations/translation_id.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_it.xml b/translations/translation_it.xml index 659059cc..5ec0c2b2 100644 --- a/translations/translation_it.xml +++ b/translations/translation_it.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_jp.xml b/translations/translation_jp.xml index 0ff706dc..7f5866c7 100644 --- a/translations/translation_jp.xml +++ b/translations/translation_jp.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_kr.xml b/translations/translation_kr.xml index 1f050732..4adf8048 100644 --- a/translations/translation_kr.xml +++ b/translations/translation_kr.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_nl.xml b/translations/translation_nl.xml index 5dcfeb99..1d96a2e6 100644 --- a/translations/translation_nl.xml +++ b/translations/translation_nl.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_no.xml b/translations/translation_no.xml index 0985d441..e440833d 100644 --- a/translations/translation_no.xml +++ b/translations/translation_no.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_pl.xml b/translations/translation_pl.xml index 4cec6056..b81c79d7 100644 --- a/translations/translation_pl.xml +++ b/translations/translation_pl.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_pt.xml b/translations/translation_pt.xml index c61ee1ec..02db1d7d 100644 --- a/translations/translation_pt.xml +++ b/translations/translation_pt.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_ro.xml b/translations/translation_ro.xml index ea287c67..e7d58090 100644 --- a/translations/translation_ro.xml +++ b/translations/translation_ro.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_ru.xml b/translations/translation_ru.xml index ad4aa25d..193b1bd5 100644 --- a/translations/translation_ru.xml +++ b/translations/translation_ru.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_sv.xml b/translations/translation_sv.xml index 5cb2e404..2d8ec05b 100644 --- a/translations/translation_sv.xml +++ b/translations/translation_sv.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_tr.xml b/translations/translation_tr.xml index 4ac20fd1..dfa9d97d 100644 --- a/translations/translation_tr.xml +++ b/translations/translation_tr.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_uk.xml b/translations/translation_uk.xml index c9473d94..3b6ed43f 100644 --- a/translations/translation_uk.xml +++ b/translations/translation_uk.xml @@ -201,6 +201,8 @@ + + diff --git a/translations/translation_vi.xml b/translations/translation_vi.xml index 66db3866..9811ca92 100644 --- a/translations/translation_vi.xml +++ b/translations/translation_vi.xml @@ -201,6 +201,8 @@ + + From 179f1e182cadca8112a792d75f1003abfccb9da4 Mon Sep 17 00:00:00 2001 From: Peter Vaiko Date: Fri, 28 Nov 2025 06:38:56 -0500 Subject: [PATCH 3/5] feat: restart course at the first waypoint --- .../strategies/AIDriveStrategyFieldWorkCourse.lua | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/scripts/ai/strategies/AIDriveStrategyFieldWorkCourse.lua b/scripts/ai/strategies/AIDriveStrategyFieldWorkCourse.lua index 28dfbf6b..dceee575 100644 --- a/scripts/ai/strategies/AIDriveStrategyFieldWorkCourse.lua +++ b/scripts/ai/strategies/AIDriveStrategyFieldWorkCourse.lua @@ -445,7 +445,8 @@ end --- State changes ----------------------------------------------------------------------------------------------------------------------- function AIDriveStrategyFieldWorkCourse:finishFieldWork() - if self.settings.returnToStart:getValue() and self.fieldWorkCourse:startsWithHeadland() then + if (self.settings.returnToStart:getValue() and self.fieldWorkCourse:startsWithHeadland()) or + self.settings.restartCourseAtEnd:getValue() then self:debug('Fieldwork ended, returning to first waypoint.') self.vehicle:prepareForAIDriving() self:returnToStartAfterDone() @@ -530,9 +531,15 @@ function AIDriveStrategyFieldWorkCourse:onPathfindingDoneToReturnToStart(path) self:debug('Pathfinding to return to start finished with %d waypoints (%d ms)', #path, g_currentMission.time - (self.pathfindingStartedAt or 0)) local returnCourse = Course(self.vehicle, CpMathUtil.pointsToGameInPlace(path), true) - self.state = self.states.RETURNING_TO_START - self.waitingForPrepare:set(true, 10000) - self:startCourse(returnCourse, 1) + if self.settings.restartCourseAtEnd:getValue() then + self:debug('Returning to the first waypoint and then restarting the fieldwork course') + self:startAlignmentTurn(self.fieldWorkCourse, 1, returnCourse) + else + self:debug('Returning to the first waypoint and stopping there') + self.state = self.states.RETURNING_TO_START + self.waitingForPrepare:set(true, 10000) + self:startCourse(returnCourse, 1) + end else self:debug('No path found to return to fieldwork start after work is done (%d ms), stopping job', g_currentMission.time - (self.pathfindingStartedAt or 0)) From 34b6c9b34d0bc7a6719a27dc4318e3f5ea3f33ed Mon Sep 17 00:00:00 2001 From: Tensuko Date: Fri, 28 Nov 2025 18:02:05 +0100 Subject: [PATCH 4/5] Translation fix --- config/MasterTranslations.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/MasterTranslations.xml b/config/MasterTranslations.xml index e4f83e8a..c9238e31 100644 --- a/config/MasterTranslations.xml +++ b/config/MasterTranslations.xml @@ -648,7 +648,7 @@ - + From abd5a1a9f966e71cfc48ad386586122682dde074 Mon Sep 17 00:00:00 2001 From: Tensuko Date: Fri, 28 Nov 2025 17:02:20 +0000 Subject: [PATCH 5/5] Updated translations --- translations/translation_de.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/translations/translation_de.xml b/translations/translation_de.xml index c3b9c705..6d6a9364 100644 --- a/translations/translation_de.xml +++ b/translations/translation_de.xml @@ -202,7 +202,7 @@ - +